-
Notifications
You must be signed in to change notification settings - Fork 0
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
Leave references untouched #1
base: master
Are you sure you want to change the base?
Conversation
@@ -183,7 +183,11 @@ public String getPath(String url, String def, String rt, String id) throws FHIRE | |||
} | |||
if (special != null) { | |||
switch (special) { | |||
case Simplifier: return "https://simplifier.net/resolve?scope="+pi.name()+"@"+pi.version()+"&canonical="+url; | |||
case Simplifier: if (url.contains("fhir.philips.com")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pi.license()
is available at this point, as a String (check for not-open-source
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better deal with this on line 428... (before Simplifier):
} else if (pi.license().equals(anObject:"not-open-source") ) {
res.special = SpecialPackageType.NotOpenSource;
}
plus a case
case NotOpenSource: return url;
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, that is option 1. We should in this case probably choose a license from https://spdx.org/licenses/ ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, we do in our sushi-config: not-open-source
license: not-open-source # https://www.hl7.org/fhir/valueset-spdx-license.html
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the package.json (what publisher uses) the documentation states:
license - optional. Follow the [spdx naming convention]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. https://www.hl7.org/fhir/valueset-spdx-license.html is an expansion of https://www.hl7.org/fhir/valueset-spdx-license.html
I guess the documentation should be adjusted
@@ -183,7 +183,11 @@ public String getPath(String url, String def, String rt, String id) throws FHIRE | |||
} | |||
if (special != null) { | |||
switch (special) { | |||
case Simplifier: return "https://simplifier.net/resolve?scope="+pi.name()+"@"+pi.version()+"&canonical="+url; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I also still like the idea to see if Simplifier can acually resolve the said query, and if not fall back to the plain url
.
Perhaps this can be tested as part of the line 428 - when deciding whether to assign special=Simplifier, or fall back to special=null.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note to self - this is primarily for urls from dependent packages, not the current IG package.
IG-Publisher manipulates found references, which exist in npm-packages.
These references are replaced by the Simplifier.resolve() function, except for some exceptions, as can be seen here
We as Philips want our (canonical) url's to be left untouched.
We have information about the npm-package available in which
license
is an optional element.Maybe it is an option to use this information, if available.
Another option can be to check if the npm-package is available on Simplifier and add a PackageType (representing npm-package not on Simplifier).