Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions cads_processing_api_service/adaptors.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,8 @@ def make_system_request(
except AttributeError:
entry_point = FALLBACK_ENTRY_POINT

try:
config = resource.config
except AttributeError:
config = resource.adaptor_configuration
if config is None:
config = FALLBACK_CONFIG.copy()
config["collection_id"] = process_id

Expand Down
5 changes: 4 additions & 1 deletion tests/test_20_adaptors.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,10 @@ def test_make_system_request_default() -> None:

exp_setup_code = adaptors.FALLBACK_SETUP_CODE
exp_entry_point = adaptors.FALLBACK_ENTRY_POINT
exp_kwargs = {"request": inputs, "config": adaptors.FALLBACK_CONFIG}
exp_kwargs = {
"request": inputs,
"config": adaptors.FALLBACK_CONFIG | {"collection_id": process_id},
}
exp_metadata = {"X-Forward-Process-ID": process_id}

request = adaptors.make_system_request(process_id, execution_content, resource)
Expand Down