Skip to content

Conversation

@Akol125
Copy link
Contributor

@Akol125 Akol125 commented Sep 12, 2025

Summary

  • Routine Change
  • ❗ Breaking Change
  • 🤖 Operational or Infrastructure Change
  • ✨ New Feature
  • ⚠️ Potential issues that might be caused by this change

Add any other relevant notes or explanations here. Remove this line if you have nothing to add.

Reviews Required

  • Dev
  • Test
  • Tech Author
  • Product Owner

Review Checklist

ℹ️ This section is to be filled in by the reviewer.

  • I have reviewed the changes in this PR and they fill all or part of the acceptance criteria of the ticket, and the code is in a mergeable state.
  • If there were infrastructure, operational, or build changes, I have made sure there is sufficient evidence that the changes will work.
  • I have ensured the changelog has been updated by the submitter, if necessary.

@github-actions
Copy link
Contributor

This branch is working on a ticket in the NHS England VED JIRA Project. Here's a handy link to the ticket:

VED-755

@Akol125 Akol125 changed the title VED-755: Handling NHS confusions VED-755: Handling NHS Number confusions Sep 12, 2025
Copy link
Contributor

@dlzhry2nhs dlzhry2nhs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple of comments added. There are a couple of key comments we need to resolve regarding the ticket acceptance criteria e.g. business logic for applying updates.

if ieds_check_exist(nhs_number):
# Fetch PDS details for demographic comparison
try:
pds_details = pds_get_patient_details(nhs_number)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already have called pds_get_patient_id which calls this pds_get_patient_details function. This is a bit inefficient. Could just make 1 API call rather than 2 and get the relevant data that we need.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Discussed on call - optional. Can do if it does not take too much time, but is an existing issue. Would be nice as improves efficiency.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are still calling PDS twice in this flow. Both times we retrieve the full patient details. On the first call, we retrieve the details and then just obtain the ID/NHS Number.

On the second call we retrieve the full patient details again so we can use it to compare the demographic details etc.

It would be really nice if we could just perform the call once. Please confirm if you plan to do this or are leaving out of this PR.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have given this some more thought. Maybe it is too much for this ticket, but can we raise a ticket to remove to 2 calls to PDS and replace with 1. It is an external service that already faces a lot of traffic, so I would like to minimise this in future.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that would be nice, we could have another ticket to tighten up some other checks, including this and add backoffs and retries for the ieds_db operations. A ticket basically to make things more durable and cater for scenarios that might also come up in the test??

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good.

JamesW1-NHS
JamesW1-NHS previously approved these changes Sep 16, 2025
Copy link
Contributor

@dlzhry2nhs dlzhry2nhs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Request looking into the comments raised. Happy to jump on call if required.

@dlzhry2nhs dlzhry2nhs self-requested a review September 18, 2025 11:59
Copy link
Contributor

@dlzhry2nhs dlzhry2nhs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really good. All major concerns addressed. I've just added some comments which could be nice to fix - most are small/minor changes for readability. I'll approve after.

@dlzhry2nhs dlzhry2nhs self-requested a review September 18, 2025 15:28
@sonarqubecloud
Copy link

@Akol125 Akol125 merged commit 86f0a0c into master Sep 19, 2025
7 checks passed
@Akol125 Akol125 deleted the VED-755-Handling-NHS-Confusions branch September 19, 2025 09:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants