Skip to content

fix: propagate error message in diagnostics for resolver failures#77

Merged
mechanik-daniel merged 2 commits intoOutburn-IL:mainfrom
mechanik-daniel:fix/error-message-propagation
Apr 26, 2026
Merged

fix: propagate error message in diagnostics for resolver failures#77
mechanik-daniel merged 2 commits intoOutburn-IL:mainfrom
mechanik-daniel:fix/error-message-propagation

Conversation

@mechanik-daniel
Copy link
Copy Markdown
Contributor

This pull request improves error handling and diagnostics reporting, specifically ensuring that error messages are properly preserved and tested when diagnostics are collected and reported.

Diagnostics handling improvements:

  • Updated the push function in src/utils/diagnostics.js to ensure that if an Error object is passed (or an object with a string message property), its message is explicitly copied to the diagnostics entry. This helps preserve the error message for later reporting.

Testing enhancements:

  • Added a new test case in test/use-fhir-server.test.js to verify that the populated error message is preserved in the diagnostics when a resolver failure occurs in $useFhirServer, ensuring accurate error reporting in verbose evaluation.

@mechanik-daniel mechanik-daniel merged commit d19b30a into Outburn-IL:main Apr 26, 2026
3 checks passed
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.

1 participant