cqframework / cqframework/sample-content-ig

_refresh produces errors

Open
#7 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
HTML
Stars
8
Forks
13
PR merge metrics
No merged PRs in 30d

Description

Taking a fresh clone, I ran _updateCQLTooling and then _refresh. The _refresh script failed with a few errors. It seems the big ones are:

  • Could not find input/resources/Library-FHIRHelpers.json
  • Could not resolve library url Library/phq-9-logic (probably related to above?)

I noticed that FHIRHelpers is not provided in the cql source or the libraries. Should it be?

Full log:

❯ ./_refresh.sh
Checking internet connection...
Online
-fs https://cds-sandbox.alphora.com/cqf-ruler-r4/fhir/
fhir-version was not specified in the ini file. Trying FHIR version 4.0.1
Core Package hl7.fhir.r4.core#4.0.1
Dependency 'example.fhir.uv.myig' has no id, so can't be referred to in markdown in the IG
Load u32113965f5e045b6842fd95fc812c9f6 (http://somewhere.org/fhir/uv/myig) from example.fhir.uv.myig#dev
Load cpg (http://hl7.org/fhir/uv/cpg) from hl7.fhir.uv.cpg#1.0.0
Load cqf (http://fhir.org/guides/cqf/common) from fhir.cqf.common#dev
[main] INFO ca.uhn.fhir.util.VersionUtil - HAPI FHIR version 5.6.3 - Rev b54b29145c
[main] INFO ca.uhn.fhir.context.FhirContext - Creating new FHIR context for FHIR version [R4]
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - IGProcessor.publishIG - refreshIG
fhir-version was not specified in the ini file. Trying FHIR version 4.0.1
Core Package hl7.fhir.r4.core#4.0.1
Dependency 'example.fhir.uv.myig' has no id, so can't be referred to in markdown in the IG
Load ub86c691957d44443965ba432e952c668 (http://somewhere.org/fhir/uv/myig) from example.fhir.uv.myig#dev
Load cpg (http://hl7.org/fhir/uv/cpg) from hl7.fhir.uv.cpg#1.0.0
Load cqf (http://fhir.org/guides/cqf/common) from fhir.cqf.common#dev
No directory found by convention for: cql
No directory found by convention for: library
No directory found by convention for: measure
No directory found by convention for: plandefinition
Refreshing libraries...
[main] INFO org.opencds.cqf.tooling.library.LibraryProcessor - No output directory found for libraries.  Any existing libraries will be overwritten.
[main] INFO ca.uhn.fhir.util.XmlUtil - Unable to determine StAX implementation: java.xml/META-INF/MANIFEST.MF not found
[main] WARN ca.uhn.fhir.parser.LenientErrorHandler - Found incorrect type for element subject - Expected OBJECT and found SCALAR (STRING)
Translating CQL source
Translating CQL source in folder /Users/cmoesel/git/cqframework/sample-content-ig/input/cql
cql-options loaded from: /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/cql-options.json
Translating CQL source in file /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/RetrieveExample.cql
CQL translation completed successfully.
Translating CQL source in file /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/DependencyExample.cql
CQL translation completed successfully.
Translating CQL source in file /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/ExtensionAndSlicingExample.cql
CQL translation completed successfully.
Translating CQL source in file /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/PHQ9Logic.cql
CQL translation completed successfully.
Translating CQL source in file /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/FirstExample.cql
CQL translation completed successfully.
Translating CQL source in file /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/QuestionnaireMeasure.cql
CQL translation completed successfully.
Refreshing measures...
Refreshing tests
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - IGProcessor.publishIG - bundleIg
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Size: 6
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Entry: http://somewhere.org/fhir/uv/mycontentig/Library/FirstExample
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Entry: http://somewhere.org/fhir/uv/mycontentig/Library/RetrieveExample
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Entry: http://somewhere.org/fhir/uv/mycontentig/Library/PHQ9Logic
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Entry: http://somewhere.org/fhir/uv/mycontentig/Library/DependencyExample
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Entry: http://somewhere.org/fhir/uv/mycontentig/Library/ExtensionAndSlicingExample
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - libraryUrlMap Entry: http://somewhere.org/fhir/uv/mycontentig/Library/QuestionnaireMeasure
cql-options loaded from: /Users/cmoesel/git/cqframework/sample-content-ig/input/cql/cql-options.json
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - Measure will not be bundled because ValueSet bundling failed.
java.lang.RuntimeException: Error reading resource from path /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Library-FHIRHelpers.json: /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Library-FHIRHelpers.json (No such file or directory)
	at org.opencds.cqf.tooling.utilities.IOUtils.readResource(IOUtils.java:259)
	at org.opencds.cqf.tooling.utilities.IOUtils.readResource(IOUtils.java:216)
	at org.opencds.cqf.tooling.utilities.ResourceUtils.getR4DepLibraryResources(ResourceUtils.java:226)
	at org.opencds.cqf.tooling.utilities.ResourceUtils.getDepLibraryResources(ResourceUtils.java:139)
	at org.opencds.cqf.tooling.library.LibraryProcessor.bundleLibraryDependencies(LibraryProcessor.java:96)
	at org.opencds.cqf.tooling.measure.MeasureProcessor.bundleMeasures(MeasureProcessor.java:124)
	at org.opencds.cqf.tooling.processor.IGBundleProcessor.bundleIg(IGBundleProcessor.java:28)
	at org.opencds.cqf.tooling.processor.IGProcessor.publishIG(IGProcessor.java:100)
	at org.opencds.cqf.tooling.operation.RefreshIGOperation.execute(RefreshIGOperation.java:41)
	at org.opencds.cqf.tooling.Main.main(Main.java:220)
Caused by: java.io.FileNotFoundException: /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Library-FHIRHelpers.json (No such file or directory)
	at java.base/java.io.FileInputStream.open0(Native Method)
	at java.base/java.io.FileInputStream.open(FileInputStream.java:219)
	at java.base/java.io.FileInputStream.<init>(FileInputStream.java:157)
	at java.base/java.io.FileReader.<init>(FileReader.java:75)
	at org.opencds.cqf.tooling.utilities.IOUtils.readResource(IOUtils.java:252)
	... 9 more
No paths found for the Directory /Users/cmoesel/git/cqframework/sample-content-ig/input/tests/measure/QuestionnaireMeasure:
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - Measure-QuestionnaireMeasure could not be processed:
          Resource could not be processed: QuestionnaireMeasure
                    1 included cql Libraries not found:
FHIRHelpers MISSING
          Resource could not be processed: Library-QuestionnaireMeasure
                    Error reading resource from path /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Library-FHIRHelpers.json: /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Library-FHIRHelpers.json (No such file or directory)
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils -
0 Measures successfully bundled:
0 Measures refreshed, but not bundled (due to issues):
1 Measures failed refresh:
     /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Measure-QuestionnaireMeasure.json FAILED
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils -
0 PlanDefinitions successfully bundled:
0 PlanDefinitions refreshed, but not bundled (due to issues):
0 PlanDefinitions failed refresh:
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - primaryLibraryUrl: Library/phq-9-logic
java.lang.IllegalArgumentException: Could not resolve library url Library/phq-9-logic
	at org.opencds.cqf.tooling.questionnaire.QuestionnaireProcessor.bundleQuestionnaires(QuestionnaireProcessor.java:64)
	at org.opencds.cqf.tooling.processor.IGBundleProcessor.bundleIg(IGBundleProcessor.java:34)
	at org.opencds.cqf.tooling.processor.IGProcessor.publishIG(IGProcessor.java:100)
	at org.opencds.cqf.tooling.operation.RefreshIGOperation.execute(RefreshIGOperation.java:41)
	at org.opencds.cqf.tooling.Main.main(Main.java:220)
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils - Questionnaire-phq-9-questionnaire could not be processed:
          Resource could not be processed: Questionnaire-phq-9-questionnaire
                    Could not resolve library url Library/phq-9-logic
[main] WARN org.opencds.cqf.tooling.utilities.LogUtils -
0 Questionnaires successfully bundled:
0 Questionnaires refreshed, but not bundled (due to issues):
1 Questionnaires failed refresh:
     /Users/cmoesel/git/cqframework/sample-content-ig/input/resources/Questionnaire-phq-9-questionnaire.json FAILED

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with _refresh.sh and the reported paths under input/resources, input/cql, and input/tests/measure. Reproduce the failure, then trace the missing FHIRHelpers dependency and the Library/phq-9-logic lookup using the full log. Done means _refresh completes without the reported measure and questionnaire failures.

Written by the indexing model from the issue text.

Assessment

Domain
build-system, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.