-
Notifications
You must be signed in to change notification settings - Fork 48
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add working_dir as a kwarg to GlobusComputeEngineBase
ThreadPoolEngine and ProcessPoolEngine now pass the working_dir: default "tasks_working_dir" to the GlobusComputeEngineBase, which makes the path absolute. When execute_task runs the working dir is set to this absolute path ensuring that tasks run in the same directory.
- Loading branch information
Showing
7 changed files
with
67 additions
and
9 deletions.
There are no files selected for viewing
20 changes: 20 additions & 0 deletions
20
changelog.d/20241023_095610_yadudoc1729_configure_tasks_working_dir.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
New Functionality | ||
^^^^^^^^^^^^^^^^^ | ||
|
||
- ``GlobusComputeEngine``, ``ThreadPoolEngine``, and ``ProcessPoolEngine`` can | ||
now be configured with ``working_dir`` to specify the tasks working directory. | ||
If a relative path is specified, it is set in relation to the endpoint | ||
run directory (usually ~/.globus_compute/<endpoint_name>). Here's an example | ||
config file: | ||
|
||
.. code-block:: yaml | ||
engine: | ||
type: GlobusComputeEngine | ||
working_dir: /dev/shm/tasks_working_dir | ||
Bug Fixes | ||
^^^^^^^^^ | ||
|
||
- Fixed a bug where functions run with ``ThreadPoolEngine`` and ``ProcessPoolEngine`` | ||
create and switch into the ``tasks_working_dir`` creating endless nesting. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -131,3 +131,9 @@ def get_env_vars(): | |
import os | ||
|
||
return os.environ | ||
|
||
|
||
def get_cwd(): | ||
import os | ||
|
||
return os.getcwd() |