fix: pin missing schema versions to their real version (Quantity, EnergyCustomerProfile) - #490
Merged
Conversation
Quantity and EnergyCustomerProfile were referenced with no version segment at all (e.g. schema.nfh.global/Quantity/context.jsonld) across 81 occurrences in 51 files. Pinned to their real, current version: Quantity -> v2.0, EnergyCustomerProfile -> v1.0. A version-less reference resolves to whatever the current latest happens to be, which isn't safe to depend on - versions here aren't guaranteed backward-compatible (PriceSpecification v2.0/v2.1/v2.2, TimePeriod, CategoryCode all have real field differences across versions). Pinning makes these references reproducible instead of a moving target that can silently change underneath callers.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes 81 document URLs (
context.jsonld/vocab.jsonld/etc.) across 51 files that referencedQuantityandEnergyCustomerProfilewith no version segment at all — e.g.schema.nfh.global/Quantity/context.jsonldinstead ofschema.nfh.global/Quantity/v2.0/context.jsonld.Quantity→ pinned tov2.0(79 occurrences — devkits/demand-flex examples, Postman collections, response fixtures, docs, examples/demand-flex)EnergyCustomerProfile→ pinned tov1.0(2 occurrences — inside this repo's own canonical schema definitions:specification/schema/EnergyBillingSummaryCredential/v1.0/context.jsonldand.../EnergyMeterDataGBCredential/v1.0/context.jsonld)A version-less reference resolves to "whatever the current latest happens to be," which isn't safe to depend on — schema versions here aren't guaranteed backward-compatible (e.g.
PriceSpecificationhas v2.0/v2.1/v2.2 with real field differences,TimePeriodandCategoryCodesimilarly). A$ref/@contextpointing at "latest" can silently start resolving to different, possibly incompatible content the moment a new version ships, with no change on the referencing side — the same failure mode dependency pinning innpm/pipexists to prevent. Pinning to the exact version actually being used makes these references reproducible instead of a moving target.Separate PR from #487 since this is a distinct problem: missing version entirely, vs. missing the
vprefix on an existing version number.Test plan
Quantity/v2.0orEnergyCustomerProfile/v1.0— no unrelated content touched🤖 Generated with Claude Code