Repository navigation
Stop the missing-token check reporting a header's own Number=. - #22
Merged
Merged
Conversation
preflight_missing_token_conformance looks for bare "." literals that should have been typed vcfc:Null. It already excluded vcfc:fieldNumber and vcfc:genotypeString, where the vocabulary requires a dot. The same token reaches the graph a third way: the structured-header layer carries every declaration's attributes verbatim as vcfc:HeaderAttribute resources, so Number=. becomes an attributeValue of "." on the attribute keyed "Number", and the core shapes require that value to be exactly xsd:string. On the v3.1.0 benchmark the narrowed check still returned ten rows on the 100,000-record HG005 cell, one per Number=. INFO declaration in its header, and reported them as EXPECTED_CONFORMANCE_FAILURE on every validation of that input. Exclude only the Number attribute's value, in both the sample query and its count, so a bare dot on any other attribute or field is still reported. It is written with OPTIONAL and BOUND rather than NOT EXISTS because those are already used by queries that pass on all four validation engines. test_missing_token_scope_unit.py runs both queries with rdflib over a graph from the real header emitter: Number=. declarations are not reported, while a bare dot on a record field and on a non-Number attribute still are. The behavioural tests fail against the previous queries. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Merged
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.
Problem
preflight_missing_token_conformanceflags bare"."literals that should have been typedvcfc:Null. It already excludedvcfc:fieldNumberandvcfc:genotypeString, where the vocabulary requires a dot.The same token reaches the graph a third way. The structured-header layer carries every declaration's attributes verbatim as
vcfc:HeaderAttributeresources, soNumber=.becomes avcfc:attributeValueof"."on the attribute keyedNumber. The core shapes require that value to be exactlyxsd:string, so it can never bevcfc:Null.On the v3.1.0 benchmark (vcf-bench-1,
13_query_cost, 100,000-recordHG005_GRCh38slice) the check still returned ten rows, one perNumber=.INFO declaration in the header. It reported them asEXPECTED_CONFORMANCE_FAILUREon all nine validations of that input.Change
_countform now exclude only the Number attribute's value. A bare dot on any other attribute or field is still reported.OPTIONAL+BOUNDrather thanNOT EXISTS.OPTIONALandBOUNDare already used by queries (q05, q07) that pass on all four validation engines;NOT EXISTSappears nowhere in the suite.docs/conversion.md§7 documents the three places a bare dot is conformant.Tests
test/test_missing_token_scope_unit.py(new, 5 tests) runs both queries with rdflib over a graph produced by the real header emitter:Number=.declarations are not reported, and the count is 0."."the test is about.Full suite: 865 tests, 864 pass. The one failure,
test_shacl_default_unit(the vendored vocabulary vs a sibling vocabulary checkout), also fails on an untouched checkout ofmain: the localvcf-rdfizer-vocabularycheckout is atd46fbdf, ahead of the vendored snapshot5bfd19d. It is unrelated to this change.Not yet checked on a live QLever/Comunica/HDT/COTTAS run; the next benchmark validation of the HG005 slice should show
PASSfor this preflight.🤖 Generated with Claude Code