pydicom / deid

best effort anonymization for medical images using python
https://pydicom.github.io/deid/
MIT License
140 stars 43 forks source link

Fix/empty values lists #145

Closed wetzelj closed 4 years ago

wetzelj commented 4 years ago

Description

Related issues: #144

Includes the fixes to ensure that empty values added to %values sections are ignored. Prior to this fix, empty values would insert an empty string into the values list, causing all fields to be removed from the header. This PR corrects these issues and introduces new unit tests for checking this issue.

Checklist

Open questions

Questions that require more discussion or to be addressed in future development:

vsoch commented 4 years ago

Looks good to me! We could still use an iterator for going through the values list (and checking for "" or None) but I think it works well as is too. Let's get this merged and released! And thank you as always for your careful, detailed work.