diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt index fa7a910fa..a1c0c0ad1 100644 --- a/docs/CMakeLists.txt +++ b/docs/CMakeLists.txt @@ -58,7 +58,7 @@ add_custom_command( COMMAND ${CMAKE_COMMAND} -E rm -rf ${CMAKE_CURRENT_BINARY_DIR}/build_python_api/_build COMMAND - ${CMAKE_COMMAND} -E env "PYTHONPATH=${CMAKE_BINARY_DIR}/Pyext/python3" + ${CMAKE_COMMAND} -E env "PYTHONPATH=${CMAKE_BINARY_DIR}/libs/pyext/python3" ${SPHINX_EXECUTABLE} -M html ${CMAKE_CURRENT_SOURCE_DIR}/build_python_api ${CMAKE_CURRENT_BINARY_DIR}/build_python_api/_build @@ -88,7 +88,7 @@ add_custom_target(ecflow_python_docs DEPENDS generate_ecflow_python_docs) add_custom_command( OUTPUT generate_ecflow_docs COMMAND - ${CMAKE_COMMAND} -E env "PYTHONPATH=${CMAKE_BINARY_DIR}/Pyext/python3" + ${CMAKE_COMMAND} -E env "PYTHONPATH=${CMAKE_BINARY_DIR}/libs/pyext/python3" ${SPHINX_EXECUTABLE} -M html ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}/_build diff --git a/libs/pyext/migrate/py_u_TestMigrate.py b/libs/pyext/migrate/py_u_TestMigrate.py index 30993575c..13bf77047 100644 --- a/libs/pyext/migrate/py_u_TestMigrate.py +++ b/libs/pyext/migrate/py_u_TestMigrate.py @@ -22,7 +22,7 @@ def get_root_source_dir(): print(" Found Jamroot.jam in " + cwd) return cwd - if tail != "Pyext" and tail != "migrate": + if tail != "pyext" and tail != "migrate": # in cmake, we may be in the build directory, hence we need to determine source directory file = cwd + "/CTestTestfile.cmake" #print(" searching for " + file) @@ -59,7 +59,7 @@ def tearDown(self): pass def locate(self,file): - return self.workspace_dir + "/Pyext/" + file + return self.workspace_dir + "/libs/pyext/" + file def testMigrateVersionNumber(self): list_of_defs_lines =[ "# 3.1.2"] diff --git a/libs/pyext/samples/TestBench.py b/libs/pyext/samples/TestBench.py index e350fe8cf..a9ea690b4 100644 --- a/libs/pyext/samples/TestBench.py +++ b/libs/pyext/samples/TestBench.py @@ -42,7 +42,7 @@ def get_root_source_dir(): print(" Found Jamroot.jam in " + cwd) return cwd - if tail != "Pyext" and tail != "migrate": + if tail != "pyext" and tail != "migrate": # in cmake, we may be in the build directory, hence we need to determine source directory file = cwd + "/CTestTestfile.cmake" #print " searching for " + file @@ -121,7 +121,7 @@ def traverse_container(node_container): This programs assumes that ecflow module is accessible example: - python Pyext/samples/TestBench.py --port=3141 --verbose=True ANode/parser/test/data/good_defs/trigger/late.def + python libs/pyext/samples/TestBench.py --port=3141 --verbose=True ANode/parser/test/data/good_defs/trigger/late.def """ print("####################################################################") @@ -157,12 +157,12 @@ def traverse_container(node_container): ARGS.defs_file = os.path.expandvars(ARGS.defs_file) # expand references to any environment variables print(ARGS ) - # If running on local work space, use /Pyext/test/data/CUSTOMER/ECF_HOME as ecf_home + # If running on local work space, use /libs/pyext/test/data/CUSTOMER/ECF_HOME as ecf_home using_workspace = False; ecflow_source_dir = "" try: ecflow_source_dir = get_root_source_dir(); - ARGS.ecf_home = ecflow_source_dir + "/Pyext/test/data/CUSTOMER/ECF_HOME" + ARGS.ecf_home = ecflow_source_dir + "/libs/pyext/test/data/CUSTOMER/ECF_HOME" using_workspace = True if ARGS.verbose: print("Workspace is defined ecflow_source_dir: ",ecflow_source_dir) diff --git a/libs/pyext/samples/TestBenchConfluence.py b/libs/pyext/samples/TestBenchConfluence.py index 09cdb2f42..2e33b2793 100644 --- a/libs/pyext/samples/TestBenchConfluence.py +++ b/libs/pyext/samples/TestBenchConfluence.py @@ -105,7 +105,7 @@ def traverse_container(node_container): ARGS.defs_file = os.path.expandvars(ARGS.defs_file) # expand references to any environment variables print(ARGS) - # If running on local work space, use /Pyext/test/data/CUSTOMER/ECF_HOME as ecf_home + # If running on local work space, use /libs/pyext/test/data/CUSTOMER/ECF_HOME as ecf_home if ARGS.verbose: print("Using ECF_HOME=" + ARGS.ecf_home) diff --git a/libs/pyext/samples/TestGui.py b/libs/pyext/samples/TestGui.py index df1ba1a25..86f7c3eb5 100755 --- a/libs/pyext/samples/TestGui.py +++ b/libs/pyext/samples/TestGui.py @@ -58,7 +58,7 @@ def ecf_home(self): return os.getcwd() + "/test_gui/data/ecf_home_debug_" + str(self.port_) return os.getcwd() + "/test_gui/data/ecf_home_release_" + str(self.port_) - def ecf_includes(self) : return os.getcwd() + "/Pyext/test/data/includes" + def ecf_includes(self) : return os.getcwd() + "/libs/pyext/test/data/includes" def log_file_path(self): return "./" + gethostname() + "." + self.port_ + ".ecf.log" def checkpt_file_path(self): return "./" + gethostname() + "." + self.port_ + ".ecf.check" def backup_checkpt_file_path(self): return "./" + gethostname() + "." + self.port_ + ".ecf.check.b" @@ -1449,7 +1449,7 @@ def test_gui(self): This should allow GUI (1 second poll), to see the effects of this test. To debug this tests, just set sync_sleep = 0, this will also preserve the test data. - Test data is created in directory: test_gui, this will deleted at the end of the test. - - Assumes includes head.h and tail.h are in CWD + /Pyext/test/data/includes + - Assumes includes head.h and tail.h are in CWD + /libs/pyext/test/data/includes - We will look for the ecflow_client in the embedded child commands in the generated scripts, o first look in the current cmake build tree of the ecflow module(this may no longer exist) o Next will use /usr/local/apps/ecflow/ with same version as this ecflow python api *IF* it exists diff --git a/libs/pyext/samples/TestJobGenPerf.py b/libs/pyext/samples/TestJobGenPerf.py index 2e57b028e..9404caffa 100644 --- a/libs/pyext/samples/TestJobGenPerf.py +++ b/libs/pyext/samples/TestJobGenPerf.py @@ -88,7 +88,7 @@ def traverse_container(node_container): ARGS.defs_file = os.path.expandvars(ARGS.defs_file) # expand references to any environment variables print(ARGS) - # If running on local work space, use /Pyext/test/data/CUSTOMER/ECF_HOME as ecf_home + # If running on local work space, use /libs/pyext/test/data/CUSTOMER/ECF_HOME as ecf_home if not ARGS.ecf_home: if os.getenv("WK") is None: print("No ecf_home specified. Please specify a writable directory") @@ -153,4 +153,3 @@ def traverse_container(node_container): newDefs = ARGS.ecf_home + "/../" + os.path.basename(ARGS.defs_file) print("Saving modified defs as " + newDefs) DEFS.save_as_defs(newDefs) - diff --git a/libs/pyext/samples/confluence_add_attachment.py b/libs/pyext/samples/confluence_add_attachment.py index 68e96d58c..5d61d42a8 100644 --- a/libs/pyext/samples/confluence_add_attachment.py +++ b/libs/pyext/samples/confluence_add_attachment.py @@ -38,7 +38,7 @@ def test_add_attachment_id(self): print("space key:",space_key," page id:",page_id) comment = "production release" - file = "/var/tmp/ma0/workspace/ecflow/Pyext/samples/test.tar.gz" + file = "/var/tmp/ma0/workspace/ecflow/libs/pyext/samples/test.tar.gz" for space_key in space_key_list: page_id = self.c.get_page_id(space_key,title) @@ -52,4 +52,3 @@ def test_add_attachment_id(self): if __name__ == '__main__': unittest.main() print("All Tests pass") - diff --git a/libs/pyext/samples/mirror.py b/libs/pyext/samples/mirror.py index 9fce62412..8f1f8dada 100755 --- a/libs/pyext/samples/mirror.py +++ b/libs/pyext/samples/mirror.py @@ -967,7 +967,7 @@ def test_1(self, test_ok=1): export SUITE=mc ECF_HOST=localhost ECF_PORT=5001 ./mirror.py -p /mirror/mc -r # load mirror on source server # might be destination or another server yet # ImportError: No module named ecf # ecf shall be in the path, at least it can found in ecflow distrib as -# ecflow/Pyext/samples/api/ecf.py +# ecflow/libs/pyext/samples/api/ecf.py # ('#MSG: replacing /mirror/test in ', 'localhost', '5001', #5.7.0 # loading OK # begin mirror - # Script OK? mirror.py undef ECF_FILES directory? @@ -1030,5 +1030,5 @@ def test_1(self, test_ok=1): ECF_HOST=localhost ECF_PORT=31415 ./mirror.py -m localhost:31415 -p /mc -/tmp/map/work/git/ecflow/Pyext/samples/mirror.py +/tmp/map/work/git/ecflow/libs/pyext/samples/mirror.py """ diff --git a/libs/pyext/samples/run_batches_with_delay.py b/libs/pyext/samples/run_batches_with_delay.py index 772e6a1ab..135504b6b 100644 --- a/libs/pyext/samples/run_batches_with_delay.py +++ b/libs/pyext/samples/run_batches_with_delay.py @@ -59,9 +59,9 @@ def run_chunk(ci,list_of_task_paths): DESC = """ example: - python3 Pyext/samples/run_batches_with_delay.py -h polonius -p 4141 -b 4 -s 4 -n "/ecflow/cron /limit_basic" + python3 libs/pyext/samples/run_batches_with_delay.py -h polonius -p 4141 -b 4 -s 4 -n "/ecflow/cron /limit_basic" The list of paths can be obtained from the GUI, using: - sh $WK/Pyext/samples/run_batches_with_delay.sh -h %ECF_HOST% -p %ECF_PORT% -b 10 -s 2 -n '' + sh $WK/libs/pyext/samples/run_batches_with_delay.sh -h %ECF_HOST% -p %ECF_PORT% -b 10 -s 2 -n '' """ print("####################################################################") diff --git a/libs/pyext/samples/run_batches_with_delay.sh b/libs/pyext/samples/run_batches_with_delay.sh index aa6f6c526..68cb43593 100755 --- a/libs/pyext/samples/run_batches_with_delay.sh +++ b/libs/pyext/samples/run_batches_with_delay.sh @@ -14,7 +14,7 @@ # Example of running a shell command from the GUI. # Use the following in ecflowUI: -# sh $WK/Pyext/samples/run_batches_with_delay.sh -h %ECF_HOST% -p %ECF_PORT% -b 10 -s 2 -n '' +# sh $WK/libs/pyext/samples/run_batches_with_delay.sh -h %ECF_HOST% -p %ECF_PORT% -b 10 -s 2 -n '' # - sh at the front is required # - the tick quotes on are required # @@ -57,4 +57,4 @@ for path in $node_paths; do echo $path done -python3 /var/tmp/ma0/workspace/ecflow/Pyext/samples/run_batches_with_delay.py --host $host --port $port --batch_size $batch_size --sleep_between_batch $sleep_between_batch --paths "$node_paths" +python3 /var/tmp/ma0/workspace/ecflow/libs/pyext/samples/run_batches_with_delay.py --host $host --port $port --batch_size $batch_size --sleep_between_batch $sleep_between_batch --paths "$node_paths" diff --git a/libs/pyext/test/py_u_TestTraversal.py b/libs/pyext/test/py_u_TestTraversal.py index e2c788cb1..3b60fd88e 100644 --- a/libs/pyext/test/py_u_TestTraversal.py +++ b/libs/pyext/test/py_u_TestTraversal.py @@ -225,4 +225,4 @@ def all_files(root, patterns='*', single_level=False, yield_folders=False): # try the mega_def. Commented out since it takes to long #mega_def = os.path.join( os.path.dirname(cwd), "libs/node/parser/test/data/single_defs/mega.def") #check_traversal(mega_def) - print("All Tests pass") \ No newline at end of file + print("All Tests pass")