Skip to content

WIP: adding 500 exception error for the duplicate phone number condition #930

WIP: adding 500 exception error for the duplicate phone number condition

WIP: adding 500 exception error for the duplicate phone number condition #930

Triggered via push January 16, 2024 07:54
Status Success
Total duration 36s
Artifacts
This run and associated checks have been archived and are scheduled for deletion. Learn more about checks retention

test.yaml

on: push
Fit to window
Zoom out
Zoom in

Annotations

3 errors and 1 warning
patientsearch/api.py#L291
Continuation line missing indentation or outdented (E122)
/home/runner/work/cosri-patientsearch/cosri-patientsearch/patientsearch/api.py#L260
del params["inactive_search"] patient = None # If the resource is a patient, proceed with the active GET, if requested try: - if resource_type == "Patient" and active_patient_flag and not is_inactive_search: + if ( + resource_type == "Patient" + and active_patient_flag + and not is_inactive_search + ): params["active"] = "true" patient = HAPI_request( token=token, method="GET",
/home/runner/work/cosri-patientsearch/cosri-patientsearch/patientsearch/api.py#L277
# Check store for working patients with the same phone number if resource_type == "Patient" and is_inactive_search: try: # Look for the patient's telecom. If does not exist, bail - telecom = patient.get('telecom', []) + telecom = patient.get("telecom", []) if not telecom: return patient # Assuming there is always one telecom telecom_entry = telecom[0] - telecom_value = telecom_entry.get('value') + telecom_value = telecom_entry.get("value") params = { - 'telecom': telecom_value, + "telecom": telecom_value, } if active_patient_flag: params["active"] = "true"
test
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/setup-python@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/