From 5ad8b4f69ab4fdf4d75f5a56fc72ef2988f1da1f Mon Sep 17 00:00:00 2001 From: Tomas Gavenciak Date: Sat, 18 Sep 2010 17:28:23 +0200 Subject: [PATCH] Fixed pipeline.insert args order --- t/moe/exts/dummy.py | 6 +++--- t/moe/tasktypes/dummy.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/t/moe/exts/dummy.py b/t/moe/exts/dummy.py index a0e2dab..7a070a2 100644 --- a/t/moe/exts/dummy.py +++ b/t/moe/exts/dummy.py @@ -9,14 +9,14 @@ def init(e): def hook_m_0(self): e.log.info('Hey! It\'s me, the dummy extension in your main pipeline! (at time 0)') - e.main_pipe.insert(hook_m_0, 'exts.dummy.hook_m_0', 0) + e.main_pipe.insert(0, 'exts.dummy.hook_m_0', hook_m_0) def hook_m_79(self): e.log.info('Me, the dummy extension, requies no cleanup! (at time 79)') - e.main_pipe.insert(hook_m_79, 'exts.dummy.hook_m_79', 79) + e.main_pipe.insert(79, 'exts.dummy.hook_m_79', hook_m_79) def hook_t_42(self): t = 'It\'s test %s and the dummy extension did nothing! (at time 42)' % e['TEST'] e.log.info(t) e.log.user.info(t) - e.test_pipe.insert(hook_t_42, 'exts.dummy.hook_t_42', 42) + e.test_pipe.insert(42, 'exts.dummy.hook_t_42', hook_t_42) diff --git a/t/moe/tasktypes/dummy.py b/t/moe/tasktypes/dummy.py index 20e3584..446c4e7 100644 --- a/t/moe/tasktypes/dummy.py +++ b/t/moe/tasktypes/dummy.py @@ -11,7 +11,7 @@ def init(e): def hook_m_50(self): e.log.info('Here should be compiling') - e.main_pipe.insert(hook_m_50, 'dummy tasktype hook_m_50', 50) + e.main_pipe.insert(50, 'dummy tasktype hook_m_50', hook_m_50) def hook_m_60(self): e.log.info('Here should be test pipeline running') @@ -27,9 +27,9 @@ def init(e): e.test_pipeline.run() testvar.remove_operation(op) - e.main_pipe.insert(hook_m_60, 'dummy tasktype hook_m_60', 60) + e.main_pipe.insert(60, 'dummy tasktype hook_m_60', hook_m_60) def hook_t_30(self): e.log.info("Maybe we should do something? Nah...") - e.test_pipe.insert(hook_t_30, 'dummy tasktype hook_t_30', 30) + e.test_pipe.insert(30, 'dummy tasktype hook_t_30', hook_t_30) -- 2.39.2