-
Notifications
You must be signed in to change notification settings - Fork 157
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better error messages for bad conditional references #2556
Comments
…details Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
details Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
details Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
issue #2556 - add the conditional reference that failed to the error details
I thought about also adding the Bundle.entry[] prefix to the issues being returned, but for now I think this is a simple/safe step in the right direction. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
issue #2556 - add the entry index to the error message
Confirmed issues created for conditional references in a transaction bundle for the following cases:
in all cases the resulting issue contains an expression indicating the location (Bundle.entry[x]) example: |
Is your feature request related to a problem? Please describe.
Resolving conditional references as part of transaction bundle processing was implemented under #1329
When the conditional reference cannot be resolved (no matches) or resolves to multiple target resources, the server will now reject the create/update.
However, the error message is a fairly generic "conditional reference could not be resolved" or "conditional reference resolves to more than one resource" (or something like that).
Instead, it would be nice if we could include the path to the offending conditional reference (and/or the conditional reference’s value itself).
Describe the solution you'd like
At minimum: An expression in the OperationOutcomeIssue that specifies the path to the offending conditional reference
Bonus: the url of the conditional reference that failed in the detail message
Describe alternatives you've considered
Acceptance Criteria
GIVEN a transaction bundle with a condition reference
AND the conditional reference is bogus
WHEN the bundle is posted
THEN an operation outcome is returned
AND it contains an issue that includes a path to the bogus conditional reference
GIVEN a transaction bundle with a condition reference
AND the conditional reference resolves to multiple resources
WHEN the bundle is posted
THEN an operation outcome is returned
AND it contains an issue that includes a path to the bogus conditional reference
Additional context
The text was updated successfully, but these errors were encountered: