Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The Postman payload violates the published Consent schema, and the shared mutable default remains unresolved.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Updates the Consent API specification and sandbox implementation for NPA-6176.
Changes:
- Removes deprecated
provision.actor. - Makes
policyRulerequired. - Updates response typing, defaults, and Postman examples.
File summaries
| File | Summary |
|---|---|
specification/validated-relationships-service-api.yaml |
Updates Consent schema and patch paths. |
sandbox/api/utils.py |
Updates response annotations and helper defaults. nit (3 votes): stale return documentation. moderate (2 votes): shared mutable dictionary default. |
sandbox/api/post_questionnaire_response.py |
Updates response typing. |
sandbox/api/post_consent.py |
Updates response typing. |
sandbox/api/patch_consent.py |
Updates response handling and annotations. |
sandbox/api/get_related_person.py |
Updates response typing. |
sandbox/api/get_questionnaire_response_by_path_id.py |
Updates response typing. |
sandbox/api/get_consent.py |
Updates response typing. |
sandbox/api/get_consent_by_id.py |
Updates response typing. |
sandbox/api/app.py |
Updates route response annotations. |
postman/validated_relationship_service.sandbox.postman_collection.json |
Removes deprecated actor data. critical (2 votes): policyRule is sent as an array instead of the schema-defined object. |
Review details
Suppressed comments (1)
sandbox/api/utils.py:106
- The annotation now says
Optional[Response], but this Returns entry still documents anOptional[tuple]and a status-code tuple. Update the docstring so callers are not given the old return contract.
def check_for_get_consent_errors(request: Request) -> Optional[Response]:
- Files reviewed: 11/12 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…e-provision-actor
This reverts commit a573eb3.
|
ehallam
approved these changes
Sep 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Pull Request
🧾 Ticket Link
https://nhsd-jira.digital.nhs.uk/browse/NPA-6176
📄 Description/Summary of Changes
🧪 Developer Testing Carried Out
📋 PR Principles
🏷️ Naming Conventions Reminder
Please ensure the following naming conventions are followed:
NPA-XXXX: <short-description><type>/NPA-XXXX/<short-description>NPA-XXXX: <short-description>