Skip to content

Commit

Permalink
ignore missing defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
morsecodist committed Jan 24, 2022
1 parent 4a4b91d commit 79c6e9c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,13 @@ def preprocess_sfn_input(sfn_state, aws_region, aws_account_id, state_machine_na
sfn_state[get_output_uri_key(stage)] = os.path.join(output_path, f"{xform_name(stage)}_output.json")
for compute_env in "SPOT", "EC2":
memory_key = stage + compute_env + "Memory"
sfn_state.setdefault(memory_key, int(os.environ[memory_key + "Default"]))
memory_default_key = memory_key + "Default"
if memory_default_key in os.environ:
sfn_state.setdefault(memory_key, int(os.environ[memory_default_key]))
vcpu_key = stage + compute_env + "Vcpu"
sfn_state.setdefault(vcpu_key, int(os.environ[vcpu_key + "Default"]))
vcpu_default_key = vcpu_key + "Default"
if vcpu_default_key in os.environ:
sfn_state.setdefault(vcpu_key, int(os.environ[vcpu_key + "Default"]))

link_outputs(sfn_state)

Expand Down
2 changes: 1 addition & 1 deletion version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v0.12.0-beta
v0.12.1-beta

0 comments on commit 79c6e9c

Please sign in to comment.