Skip to content

Commit

Permalink
Include only inputs in staging manifest
Browse files Browse the repository at this point in the history
  • Loading branch information
mvdbeek committed Nov 13, 2024
1 parent e827a30 commit 511ee61
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
3 changes: 1 addition & 2 deletions pulsar/client/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -505,8 +505,7 @@ def launch(
MANIFEST_SCRIPT = importlib.resources.path(scripts, "collect_output_manifest.py")

with tempfile.NamedTemporaryFile(mode="w") as temp_fh:
fixed_manifest = [staging_manifest[0]]
temp_fh.write(json_dumps(fixed_manifest))
temp_fh.write(json_dumps(staging_manifest))
temp_fh.flush()
staging_process = subprocess.run([sys.executable, STAGING_SCRIPT, "--json", temp_fh.name], capture_output=True)
assert staging_process.returncode == 0, staging_process.stderr.decode()
Expand Down
11 changes: 6 additions & 5 deletions pulsar/client/staging/up.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,14 @@ def submit_job(client, client_job_description, job_config=None):
launch_kwds["token_endpoint"] = client.token_endpoint

# populate `to_path`
staging_manifest = []
for action in file_stager.action_mapper.actions:
name = basename(action.path)
input_type = "input"
path = file_stager.job_directory.calculate_path(name, input_type)
action.write_to_path(path)
if action.file_type not in ("output", "output_workdir"):
name = basename(action.path)
path = file_stager.job_directory.calculate_path(name, action.file_type)
action.write_to_path(path)
staging_manifest.append(action.finalize())

staging_manifest = file_stager.action_mapper.finalize()
if staging_manifest:
launch_kwds["staging_manifest"] = staging_manifest

Expand Down

0 comments on commit 511ee61

Please sign in to comment.