Skip to content

Commit a97f67c

Browse files
authored
VED-1058 Minor improvement to record forwarder lambda logs (#1183)
1 parent f7979f0 commit a97f67c

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

lambdas/recordforwarder/src/repository/fhir_batch_repository.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ def delete_immunization(
189189
except botocore.exceptions.ClientError as error:
190190
# Either resource didn't exist or it has already been deleted. See ConditionExpression in the request
191191
if error.response["Error"]["Code"] == "ConditionalCheckFailedException":
192-
raise ResourceNotFoundError(resource_type="Immunization", resource_id=imms_id)
192+
raise ResourceNotFoundError(resource_type="Immunization", resource_id=identifier)
193193
else:
194194
raise UnhandledResponseError(
195195
message=f"Unhandled error from dynamodb: {error.response['Error']['Code']}",

lambdas/recordforwarder/tests/test_forwarding_batch_lambda.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ def test_forward_lambda_handler_multiple_scenarios(self):
385385
"diagnostics": create_diagnostics_dictionary(
386386
ResourceNotFoundError(
387387
resource_type="Immunization",
388-
resource_id="Immunization#4d2ac1eb-080f-4e54-9598-f2d53334681c",
388+
resource_id="https://www.ravs.england.nhs.uk/#RSV_002",
389389
)
390390
),
391391
},
@@ -415,7 +415,7 @@ def test_forward_lambda_handler_multiple_scenarios(self):
415415
"diagnostics": create_diagnostics_dictionary(
416416
ResourceNotFoundError(
417417
resource_type="Immunization",
418-
resource_id="Immunization#4d2ac1eb-080f-4e54-9598-f2d53334681c",
418+
resource_id="https://www.ravs.england.nhs.uk/#RSV_002",
419419
)
420420
),
421421
},
@@ -700,7 +700,7 @@ def test_forward_lambda_handler_update_scenarios(self):
700700
"diagnostics": create_diagnostics_dictionary(
701701
ResourceNotFoundError(
702702
resource_type="Immunization",
703-
resource_id="Immunization#4d2ac1eb-080f-4e54-9598-f2d53334687r",
703+
resource_id="https://www.ravs.england.nhs.uk/#UPDATE_TEST",
704704
)
705705
),
706706
},

0 commit comments

Comments
 (0)