-
Notifications
You must be signed in to change notification settings - Fork 176
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
[MRG] Add UPS and BWM to qrscp and UPS to findscu #837
[MRG] Add UPS and BWM to qrscp and UPS to findscu #837
Conversation
…ontexts, bypassing query of database and returning empty list for MWL and UPS queries
previous commit fixed lack of UnifiedProcedurePresentationContexts but forgot to put in comment
added UPS SOP Classes/Presentation Contexts to test_findscu because they are showing up in qrscp now corrected search directory in test_storescu for it's recursive search for dicom files
… but with success)
When I use a lesser version of Sphinx, everything is fine in terms of building docs. |
but now I get: which is a bit more informative. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, that looks quite good to me! I will wait some time if somebody else will have a look (@darcymason ?), and for the linter issue to be handled before merging this.
pynetdicom/apps/qrscp/handlers.py
Outdated
yield 0xC322, None | ||
|
||
yield 0xFF00, response | ||
if model.name not in ['Unified Procedure Step - Pull SOP Class' ,'Modality Worklist Information Model - FIND'] : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably better to use the keyword, which will surely not change, e.g.
if model.keyword not in ("UnifiedProcedureStepPull", "ModalityWorklistInformationModelFind"):
and maybe revert the logic for readability - that else
branch is way down there
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great feedback. I am on it.
I've had a quick look without significant comments - will try to do a proper review in the next couple of days. |
using model.keyword rather than model.name, and inverted logic so that the action taken based on the truth of the conditional is immediately visible to the reviewer.
The lint failure is for long present spelling of these words, presumably following the dictate that the Kings English be used I tried using the --builtin 'en-GB_to_en-US' but that didn't work, so I just used the specific words and their spelling.
pydicom already has typing information in it
Codecov Report
@@ Coverage Diff @@
## master #837 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 28 28
Lines 8639 8639
=========================================
Hits 8639 8639 |
The checks now pass, only waiting for the review by @darcymason. |
In addition, the ``qrscp`` application implements a Service Class Provider (SCP) for the | ||
:dcm:`Basic Modality Worklist<part04/chapter_K.html>`, and :dcm:`Unified Procedure Step<part04/Chapter_CC>` | ||
service classes, but currently will only return empty results (0 records) | ||
|
||
.. warning:: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In reviewing again, I'm wondering about the 'safety' of returning empty results... I don't know much about DICOM communications (as opposed to files) and pynetdicom's internals, but is this a potential problem for another pynetdicom library user, who tries to use this service assuming it would work fully?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Empty results are a legitimate and frequent outcome when issuing a C-FIND-RQ
This happens alot in IHE-RO TDW-II profile because the SCU implementations often poll every five minutes and there isn't a match at the time.
It also happens for typical Q/R and for BWM/MWL.
However, I am intending to provide a means for the tester supplying UPS to provide responses to matching queries.
I was going to do that separately from qrscp, and do it in a personal but public repo with TDW-II plus examples.
The reason I put in the successful empty response was so there could be a basic communication test. There wasn't one for BWM/WLM. Which was already supported by findscu. If you want me to remove the minimal support for UPS CFIND from qrscp and will still approve the changes for findscu, I will create a new PR and cancel this one. But if I have to implement a fully functional example, then we should remove support for BWM/MWL from findscu until it too has a fully functional test available.
I will be happy to transfer any and all of my personal repo work on UPS to pynetdicom apps once I am happy with it. I realise that counts as big bang PRs, but it can be done one paired set of apps at a time (mutual testing... It takes two to tango). I have that minimal pair already for UPS Watch, although it is not "feature complete".
I'm also happy to maintain ownership of my TDW-II/UPS working examples.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you want me to remove the minimal support for UPS CFIND from qrscp and will still approve the changes for findscu, I will create a new PR and cancel this one.
Your first statement that this is legitimate and happens commonly is enough for me, especially with the additional abilities available soon. As to whether in your own repo, or contributed here, I'll let @mrbean-bremen comment on that one, I don't know enough to have an opinion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome.
There are a handful of RT 3rd party vendors eager to see the example of a findscu that supports UPS. Having this in the main (master) branch will make it easier for them.
Thank you
I'm fine with this - while I'm also not an expert in DICOM communication, I think it is a good addition - thank you! |
WooHoo! |
Reference issue
#835
Tasks