Stream: implementers
Topic: Fuzziness in semantic version declaration
Lloyd McKenzie (Apr 06 2020 at 15:35):
I've got a system where instances declare the profile (and profile version) they comply with. This information is used to dispatch the instance to appropriate processing and validation. We're trying to use semantic versioning (e.g. 0.1.2) where the lowest level indicates non-breaking changes. We don't really want to dispatch based on the lowest digit and want to have a single validator that checks the inbound content that uses the 'current' validation. E.g. if we receive 0.1.2 and the current version is 0.1.5, we'd validate using the 0.1.5 validator. However, that ends up yelling about 0.1.2 not being recognized. Is it legitimate to declare a profile like this: http://some.url.org/StructureDefinition/foo|0.1 when the formal version is actually 0.1.5? Other ideas about how to handle this scenario?
Grahame Grieve (Apr 06 2020 at 18:54):
I think that should work... maybe. In what context is it not?
Lloyd McKenzie (Apr 06 2020 at 21:54):
I haven't tried it. I haven't seen any documentation that it's allowed - wanted to check before telling my customer it should work. If we agree that it should work, then at least if it doesn't I can declare it a tooling issue and we can work on it.
Grahame Grieve (Apr 06 2020 at 21:54):
well, you could start with a test case for the validator
Lloyd McKenzie (Apr 08 2020 at 05:23):
https://github.com/FHIR/fhir-test-cases/pull/9
Lloyd McKenzie (Apr 08 2020 at 05:23):
It doesn't work :(
Brian Kaney (Jun 12 2020 at 15:52):
This just came up on a project I am working on. Should FHIR canonical URL resolution follow full semantic version resolution (https://semver.npmjs.com).. e.g. http://some.url.org/StructureDefinition/foo|~1.0.2
would match any patch .2 or greater?
Lloyd McKenzie (Jun 12 2020 at 16:28):
We have nothing in the spec right now that allows it. If you think we should allow it, you could submit a change request. (Note that FHIR doesn't demand semantic versioning is adhered to. The version element could say something like "2019" or "A5" or "Honeycomb".
Last updated: Apr 12 2022 at 19:14 UTC