Skip to content
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

How to override validation #149

Open
mobolaji000 opened this issue Dec 20, 2023 · 2 comments
Open

How to override validation #149

mobolaji000 opened this issue Dec 20, 2023 · 2 comments

Comments

@mobolaji000
Copy link

  • fhir.resources version:
  • Python version: 3.9
  • Operating System: Mac OS

Description

Thanks for this really wonderful library. I have lots of dirty data, and I was looking for an option to turn off all validation when I try to create a resource (e.g. Condition, Resource) from a json. Could you please send an example?

What I Did

I create resources in the regular way and I run into tons of errors. I would rather just turn off all validation.

@vadi2
Copy link

vadi2 commented Mar 20, 2024

This is a issue pertinent to me as well - I'm building up FHIR resources from a spreadsheet and not all of the data is available at resource construction time - some will come later.

At the moment, I'm filling in the mandatory data as a hack to satisfy the validator, but this becomes tricky when you have a mandatory choice such as MedicationStatement.medication[x] - using a placeholder value at instantiation time doesn't work because as soon as you try to remove it to set the correct datatype, the validator complains.

@Healthedata1 how do you deal with this - as I understand you have a similar usecase?

@Healthedata1
Copy link

Healthedata1 commented Mar 20, 2024 via email

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

No branches or pull requests

3 participants