Skip to content
This repository has been archived by the owner on Apr 8, 2024. It is now read-only.

Error "Getting datenZurGeburt failed" while creating a Patient without a birth date #353

Open
7 tasks
subigre opened this issue Jul 1, 2021 · 0 comments
Open
7 tasks
Labels
bug Something isn't working

Comments

@subigre
Copy link
Contributor

subigre commented Jul 1, 2021

Steps to reproduce

According to the profile https://simplifier.net/forschungsnetzcovid-19/patient, birthDate must be supported but it is not mandatory.

The current implementation returns an error when I try to create the following resource:

{
    "resourceType": "Patient",
    "meta": {
        "profile": [
            "https://www.netzwerk-universitaetsmedizin.de/fhir/StructureDefinition/Patient"
        ]
    },
    "extension": [
        {
            "url": "https://www.netzwerk-universitaetsmedizin.de/fhir/StructureDefinition/ethnic-group",
            "valueCoding": {
                "system": "http:https://snomed.info/sct",
                "code": "186019001",
                "display": "Other ethnic, mixed origin"
            }
        }
    ],
    "identifier": [
        {
            "system": "urn:ietf:rfc:4122",
            "value": "{{$guid}}"
        },
        {
            "system": "http:https://www.netzwerk-universitaetsmedizin.de/sid/crr-pseudonym",
            "value": "codex_123456"
        }
    ],
    "active": true,
    "name": [
        {
            "family": "{{$randomLastName}}",
            "given": [
                "{{$randomFirstName}}"
            ]
        }
    ]
}

Actual result

Status: 422 Unprocessable Entity

{
    "resourceType": "OperationOutcome",
    "issue": [
        {
            "severity": "error",
            "code": "processing",
            "diagnostics": "Getting datenZurGeburt failed: null"
        }
    ]
}

Expected result

Status: 201 Created

{
    "resourceType": "Patient",
    "id": "1199698d-5b41-4c3d-b34b-3cef3bf41494",
    "meta": {
        "versionId": "1",
        "lastUpdated": "2021-07-01T17:56:29.705+02:00",
        "profile": [
            "https://www.netzwerk-universitaetsmedizin.de/fhir/StructureDefinition/Patient"
        ]
    },
    "extension": [
        {
            "url": "https://www.netzwerk-universitaetsmedizin.de/fhir/StructureDefinition/ethnic-group",
            "valueCoding": {
                "system": "http:https://snomed.info/sct",
                "code": "186019001",
                "display": "Other ethnic, mixed origin"
            }
        }
    ],
    "identifier": [
        {
            "system": "urn:ietf:rfc:4122",
            "value": "adee8b85-a77f-40a5-8967-f9acac806695"
        },
        {
            "system": "http:https://www.netzwerk-universitaetsmedizin.de/sid/crr-pseudonym",
            "value": "codex_123456"
        }
    ],
    "active": true,
    "name": [
        {
            "family": "Glover",
            "given": [
                "Adolphus"
            ]
        }
    ]
}

Success criteria

  • The defect has been fixed
  • The defect is checked by an unit or an integration test (Robot)
  • Merge Request approved
  • Unit tests passed
  • Build without errors
  • Release notes prepared
  • Runtime warnings
@subigre subigre added the bug Something isn't working label Jul 1, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant