onc-healthit / inferno-program

Archived source code for the Inferno Testing Tool and the Program Edition set of tests. No longer maintained.
https://inferno.healthit.gov/
Apache License 2.0
38 stars 12 forks source link

USCDR-05 Fails when category = unknown (data-absent-reason) #435

Closed bh021790 closed 2 years ago

bh021790 commented 2 years ago

Thank you for reporting a possible bug in Inferno! Please fill in as much of the template below as you can.

Subject of the issue This may be more of a question: Should data-absent-reason codes be included as supported search parameters for a given element?

Currently we have a test patient with a document that we populate with an 'unknown' DAR code since it is not populated. So when the earlier Inferno tests search by patient, the subsequent test then makes an attempt to search for that patient+category=unknown; DocumentReference?category=unknown&patient=12742542

I'm wondering if this is something we just need to enhance our APIs to support or if Inferno should really be testing these scenarios. Not sure if this was an intended workflow based on the US Core profiles (but can also see the value in us supportingif we need to)

Your environment

Steps to reproduce Tell us how to reproduce this issue.

Include:

Expected behavior This is more of my question: should we be supporting a search by a DAR code? And should Inferno test for this?

Actual behavior We do not support this today but Inferno tests for it.

yunwwang commented 2 years ago

My preference is that when server support DAR binding for an element, then server should support searching with DAR code. This is the same as using local coding. Assume a server supports local code "my-category" in additional to code "clinical-note". Server need to support searching with "my-category". Otherwise, client could not get resources with that category. DAR code, technically, falls into the same "extensive" codes beyond what specified in valueset. What if the client "wants" to see resources with DAR code so client can do something, for example fixing those.

As for Inferno testing, Inferno does not query DAR value intentionally. Inferno uses the category code from the first resource to build search query. Here, the first resource happened to have that DAR code.

We could add a logic to say that if the code is DAR then skip this resource and look next one.

bh021790 commented 2 years ago

You convinced me :) thanks for the guidance! Feel free to close!