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

Release update error : MRCM range constraint not defined for attribute 1142139005 #325

Closed
Lotili opened this issue Oct 5, 2021 · 6 comments

Comments

@Lotili
Copy link

Lotili commented Oct 5, 2021

Hi there,
We've encountered an error while trying to import the Belgian release delta:
java.lang.IllegalStateException: No MRCM range constraint is defined for concrete attribute 1142139005
This attribute is from SNOMED international, not the Belgian extension. Note that in August, we updated the International version on our instance of snowstorm without any issue. We tried to manually check the RF2 files but weren't able to identify the source of this issue.
Any idea what can be done and if there is anything we can do on our side?
Thanks in advance,

@kaicode
Copy link
Member

kaicode commented Oct 5, 2021

Hi @Lotili,
Thanks for reaching out.

There are MRCM constraints defined for this concrete attribute, as seen in the MRCM browser.
Screenshot 2021-10-05 at 11 19 48

The reference set member containing the range constraint for that attribute should be available via the rest interface: GET /MAIN/2021-07-31/members/39f5f1fc-d2e4-45b0-9643-d6ce66a871d6. It's in the public Snowstorm instance here.

Support for concrete domains and updates to the MRCM endpoints to work with concrete attributes was added in Snowstorm 6.2.0. If the July 2021 International release was imported into an earlier version of Snowstorm the concrete attributes will not have imported correctly. Could that be the problem?

@Lotili
Copy link
Author

Lotili commented Oct 5, 2021

Hi Kai,
Thanks for your answer! We had updated Snowstorm right before importing the new release, so I doubt this is the issue. I tried to get 1142139005 from the MRCM attribute range international refset and I find it alright:

request URL :
https://$BASE_URL/MAIN/members?referenceSet=723562003&referencedComponentId=1142139005&offset=0&limit=50

response :

  "items": [
    {
      "active": true,
      "moduleId": "900000000000012004",
      "released": true,
      "releasedEffectiveTime": 20210731,
      "memberId": "39f5f1fc-d2e4-45b0-9643-d6ce66a871d6",
      "refsetId": "723562003",
      "referencedComponentId": "1142139005",
      "additionalFields": {
        "rangeConstraint": "int(>#0..)",
        "attributeRule": "<< 373873005 |Pharmaceutical / biologic product (product)|: [0..1] 1142139005 |Count of base of active ingredient| > #0",
        "contentTypeId": "723596005",
        "ruleStrengthId": "723597001"
      },
      "referencedComponent": {
        "conceptId": "1142139005",
        "active": true,
        "definitionStatus": "PRIMITIVE",
        "moduleId": "900000000000012004",
        "fsn": {
          "term": "Count of base of active ingredient (attribute)",
          "lang": "en"
        },
        "pt": {
          "term": "Count of base of active ingredient",
          "lang": "en"
        },
        "id": "1142139005"
      },
      "effectiveTime": "20210731"
    }
  ],
  "total": 1,
  "limit": 50,
  "offset": 0
} 

Is there anything I can query to give you more info ?

@CoderMChu
Copy link
Member

@Lotili Can you run the same request above on the branch path you tried to import please?

@Lotili
Copy link
Author

Lotili commented Oct 7, 2021

Hi Michael,
I tried and get nothing:

{
  "items": [],
  "total": 0,
  "limit": 50,
  "offset": 0
}

But I should note that the attribute 1142139005 was created in the July International release. We're trying to update the Belgian Extension, which is released in March and September. So the latest release we uploaded before was anterior to the International release where this attribute was created.

@CoderMChu
Copy link
Member

Hi @Lotili,

I don't know your extension set-up but it looks like the branch you are trying to import the latest BE extension into is not dependant on the International 20210731 release. If the branch you are importing into was created prior to the international 20210731 then you need to do a rebase on that branch so that it can pick up the latest content from MAIN. You can rebase via the following API via swagger:
swagger-ui.html#!/Branching/mergeBranchUsingPOST

Or you can create new branch under MAIN and import the latest BE September release.

Hope this helps.

@Lotili
Copy link
Author

Lotili commented Oct 7, 2021

Hi Micheal,
After a bit of investigation, it seems like we forgot a step necessary for extension updates, which is POST /codesystems/{shortName}/upgrade ! I made sure to update this and now the query above works, and the import of the extension release was successful.
Thanks for you time!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants