From bf9c54004eadb37a2cace9f5084c767292f96235 Mon Sep 17 00:00:00 2001 From: Julia Afeltra <30803904+jafeltra@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:36:31 -0400 Subject: [PATCH 1/2] Use FPL v0.5.0 (#1310) --- npm-shrinkwrap.json | 20 +++++++++----------- package.json | 2 +- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index dc766cdcb..f8db34e5c 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -15,7 +15,7 @@ "chalk": "^3.0.0", "commander": "^8.2.0", "fhir": "^4.9.0", - "fhir-package-loader": "^0.4.0", + "fhir-package-loader": "^0.5.0", "fs-extra": "^8.1.0", "html-minifier-terser": "5.1.1", "https-proxy-agent": "^5.0.0", @@ -3548,9 +3548,9 @@ } }, "node_modules/fhir-package-loader": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/fhir-package-loader/-/fhir-package-loader-0.4.0.tgz", - "integrity": "sha512-l7spvyZhSykRtcQkbmuZmsvqh+z31eyY1jVTW1dpE4gd6Ydk/0+rEt9imr2mvFPvRgneB0/GN2gOWfh0pxOoSQ==", + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/fhir-package-loader/-/fhir-package-loader-0.5.0.tgz", + "integrity": "sha512-Q+W+l0jNLkpC2lUCIbtJ76P7xUvU3Bady/dcHo6f45q/CpFtvE9DyfeSNIGJZwpI72IIVZe5lvZ+lA58CGoVuA==", "dependencies": { "axios": "^0.21.1", "chalk": "^4.1.2", @@ -3558,6 +3558,7 @@ "fs-extra": "^10.0.0", "https-proxy-agent": "^5.0.0", "lodash": "^4.17.21", + "semver": "^7.5.4", "tar": "^5.0.11", "temp": "^0.9.1", "winston": "^3.3.3" @@ -5624,7 +5625,6 @@ "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dev": true, "dependencies": { "yallist": "^4.0.0" }, @@ -6761,7 +6761,6 @@ "version": "7.5.4", "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", - "dev": true, "dependencies": { "lru-cache": "^6.0.0" }, @@ -10634,9 +10633,9 @@ } }, "fhir-package-loader": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/fhir-package-loader/-/fhir-package-loader-0.4.0.tgz", - "integrity": "sha512-l7spvyZhSykRtcQkbmuZmsvqh+z31eyY1jVTW1dpE4gd6Ydk/0+rEt9imr2mvFPvRgneB0/GN2gOWfh0pxOoSQ==", + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/fhir-package-loader/-/fhir-package-loader-0.5.0.tgz", + "integrity": "sha512-Q+W+l0jNLkpC2lUCIbtJ76P7xUvU3Bady/dcHo6f45q/CpFtvE9DyfeSNIGJZwpI72IIVZe5lvZ+lA58CGoVuA==", "requires": { "axios": "^0.21.1", "chalk": "^4.1.2", @@ -10644,6 +10643,7 @@ "fs-extra": "^10.0.0", "https-proxy-agent": "^5.0.0", "lodash": "^4.17.21", + "semver": "^7.5.4", "tar": "^5.0.11", "temp": "^0.9.1", "winston": "^3.3.3" @@ -12125,7 +12125,6 @@ "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "dev": true, "requires": { "yallist": "^4.0.0" } @@ -12955,7 +12954,6 @@ "version": "7.5.4", "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", - "dev": true, "requires": { "lru-cache": "^6.0.0" } diff --git a/package.json b/package.json index 6af5fcbe1..6ec807fed 100644 --- a/package.json +++ b/package.json @@ -87,7 +87,7 @@ "chalk": "^3.0.0", "commander": "^8.2.0", "fhir": "^4.9.0", - "fhir-package-loader": "^0.4.0", + "fhir-package-loader": "^0.5.0", "fs-extra": "^8.1.0", "html-minifier-terser": "5.1.1", "https-proxy-agent": "^5.0.0", From 8dc012964ec4b8937cea0fa363aed71c0e862820 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mikael=20Rinnetm=C3=A4ki?= Date: Mon, 24 Jul 2023 22:52:42 +0300 Subject: [PATCH 2/2] Log the name of the file that is not processed by SUSHI (#1307) * Log the name of the file that is not processed by SUSHI * Use debug level when logging invalid files Also inform about this in the info level summary message. --- src/fhirdefs/load.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/fhirdefs/load.ts b/src/fhirdefs/load.ts index a993c4171..55d7a97bb 100644 --- a/src/fhirdefs/load.ts +++ b/src/fhirdefs/load.ts @@ -68,6 +68,7 @@ export function loadCustomResources( resourceJSON = converter.xmlToObj(xml); } else { invalidFileCount++; + logger.debug(`File not processed by SUSHI: ${file}`); continue; } } catch (e) { @@ -98,8 +99,8 @@ export function loadCustomResources( if (invalidFileCount > 0) { logger.info( invalidFileCount > 1 - ? `Found ${invalidFileCount} files in input/* resource folders that were neither XML nor JSON. These files were not processed as resources by SUSHI.` - : `Found ${invalidFileCount} file in an input/* resource folder that was neither XML nor JSON. This file was not processed as a resource by SUSHI.` + ? `Found ${invalidFileCount} files in input/* resource folders that were neither XML nor JSON. These files were not processed as resources by SUSHI. To see the unprocessed files in the logs, run SUSHI with the "--log-level debug" flag.` + : `Found ${invalidFileCount} file in an input/* resource folder that was neither XML nor JSON. This file was not processed as a resource by SUSHI. To see the unprocessed file in the logs, run SUSHI with the "--log-level debug" flag.` ); } }