Repository navigation
feat!: remove the no_map node mode so subjects and objects always resolve - #221
Merged
Merged
Conversation
…olve `no_map: true` on a statement subject or object (#219, released in 21.0.0) skipped fullmap entity resolution and emitted the cell value as the node id verbatim. It breaks the output: with no lookup there is no role to derive, so the build pinned every verbatim node's category to `biolink:NamedThing` and each edge derived from it degraded to `biolink:Association`, losing the typed predicate categories KGX consumers expect. The mode is removed rather than patched, restoring the 20.0.0 resolution path. - `NodeEncoding.no_map` is gone, along with the `no-map-dead-config` and `no-map-bad-curie` config validators, the `no-map-curie-violation` code, and the `CURIE_PATTERN`/`is_curie` helpers that only served them. - `lib.curie_audit` and its `Tcode._node_ops` verbatim branch are gone, so subject and object columns go back through the shared `resolve_batch`, plus the matching `PHASE_OF` and `runcache.OP_COST` entries. - CURIE-ranged qualifiers always resolve again: `Qualifier.resolved` is `vocabulary is None`, so enum-ranged qualifiers still pass their vocabulary tokens through verbatim and nothing else does. - The `no_map` row and the "No-map mode" section are removed from `docs/configuration/table.md`, and the tests written for the mode are gone. Migration: drop `no_map: true` from subject and object encodings. Terms resolve as they did before 21.0.0; tables that already carry CURIEs also resolve, since the fullmap indexes CURIEs and their equivalent identifiers as terms.
With `no_map` deleted from `NodeEncoding`, a table config written against 21.0.0 failed with pydantic's bare "Extra inputs are not permitted", which names no history and offers no migration step for an unattended pipeline run. `models.DEPRECATED_KEYS` is the repo's scaffold for exactly this: the before-hook warns, and `extra="forbid"` still rejects the key, so the config never builds the output the removal exists to prevent. - `no_map` is registered with a note that says the mode is gone, why (verbatim nodes pinned to `biolink:NamedThing` flattened edge typing), and what old configs should expect now: a CURIE cell resolves back to its own CURIE because the fullmap indexes CURIEs as terms, with the usual `taxon`, `prioritize`/`avoid`, and `exclude_*` rules still applying. - The key is rejected on presence, not truthiness, so `tests/test_models.py` pins the warn-then-reject path for both `no_map: false` and `no_map: true`. - The two existing deprecation tests' "registry is EMPTY" wording is corrected, since the registry now names one removed key.
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
SkyeAv
added a commit
that referenced
this pull request
Oct 16, 2026
SkyeAv
added a commit
that referenced
this pull request
Oct 16, 2026
Cut 22.0.0 and bump the package version in pyproject.toml, CITATION.cff, and uv.lock. Major: the no_map node mode added in 21.0.0 is removed because verbatim nodes cannot derive a role and collapsed to biolink:NamedThing with flattened biolink:Association edges; configs setting the key are told why, then rejected (#221). The user-facing docs are corrected against the live sources, the changelog is normalized to plain ASCII, and tests/test_docs_style.py now gates typography regressions (#222). Changelog: - Versioned the 22.0.0 section from the two merged PRs (no Unreleased section existed), added PR links to both entries, and added the migration note for the no_map removal. Docs: none needed here; the docs pages themselves were aligned in #222 and the new style gate covers the CHANGELOG edit in the test suite. Testing: - make check -> exit 0: ruff check "All checks passed!", ruff format "71 files already formatted", pyright "0 errors, 0 warnings, 0 informations", pytest "1222 passed, 1 skipped in 23.81s", cargo test 127 + 11 (1 ignored) + 17 + 1 passed, clippy -D warnings clean - uv run mkdocs build --strict -> exit 0
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.
Removes
no_map, the mode that let a statement subject or object skip fullmap entity resolution and emit its own CURIE verbatim. It broke emitted output: with no lookup there is no role to derive, so every verbatim node was pinned tobiolink:NamedThingand each edge derived from it flattened tobiolink:Association. The resolution path goes back to how it worked in 20.0.0, and configs that still set the key now fail with a message that says why.Removal
NodeEncoding.no_mapis gone fromsrc/tablassert/models.py, along with theno_map_rejects_explicit_taxon,no_map_rejects_resolution_knobs, andno_map_literal_must_be_curievalidators and theCURIE_PATTERN/is_curiehelpers that only served them.lib.curie_auditand theverbatimbranch ofTcode._node_opsare deleted, so subject and object go back through the sharedresolve_batch(src/tablassert/lib.py:1417). The op's matchingPHASE_OFandruncache.OP_COSTentries go with it, whichtests/test_run_cache.py:352requires.no-map-dead-config,no-map-bad-curie, andno-map-curie-violationare dropped fromTablassertErrorCodesinsrc/tablassert/errors.py.Qualifier.resolvedisvocabulary is Noneagain, so CURIE-ranged qualifiers always resolve while enum-ranged qualifiers still pass their vocabulary tokens through verbatim. The mode rode this one shared field, so its qualifier half is removed with it.Migration notice
DEPRECATED_KEYS:no_mapis registered insrc/tablassert/models.pyso the before-hook names the removal and the migration beforeextra="forbid"rejects the key. Warn, then fail: popping the key instead would build the broken output the removal exists to prevent.docs/cli.md:118,docs/api/fullmap.md:245). Resolution rules still apply:taxon,prioritize/avoid,exclude_prefixes/exclude_regex, and a blank cell still drops the row.Docs
docs/configuration/table.mdloses theno_maprow and theNo-map modesection.tests/test_docs_source_of_truth.py::test_config_model_fields_match_live_modelsbinds docs rows to live model fields in both directions, which is why code and docs land in one commit rather than two layers.CHANGELOG.mdis untouched: the release commit writes it, so 21.0.0's record stays as shipped and the breaking note belongs in the next release entry. Its 21.0.0 entry still namesno_mapandcurie_audit, which is shipped history, not a missed edit.Testing
uv run pytest -q --no-cov->1218 passed, 1 skipped(the skip is the opt-in corpus sweep attests/test_realworld_configs.py:236, which needsTABLASSERT_CONFIG_CORPUS)uv run ruff check .->All checks passed!;uv run ruff format --check .->70 files already formatteduv run pyright->0 errors, 0 warnings, 0 informationscargo test --manifest-path rust/Cargo.toml->127 passed,11 passed; 1 ignored,17 passed,1 passed;cargo clippy --all-targets -- -D warnings-> exit 0uv run mkdocs build --strict-> exit 0uv run tablassert validate <config with no_map: true> --schema table-> prints the removal note, thenstatement.subject.no_map: Extra inputs are not permitted [extra_forbidden], exit 1; the same run withno_map: falsefails identically, since the hook keys on presenceTcode._node_ops,PHASE_OF,class NodeEncoding..class Qualifier, andQualifier.resolvedare byte-identical togit show 32f4478~1:src/tablassert/{lib,models}.py, so the restored path is the 20.0.0 path.Risks
no_mapstops validating, at either value: the hook warns on key presence andextra="forbid"rejects the key regardless of what it is set to, so ano_map: falseconfig breaks too. A graph built with the mode under 21.0.0 emits different node categories and edge types once rebuilt. Deferred: no replacement "verbatim identifier" surface; the supported path is fullmap resolution.Questions for the reviewer
no_mapwas a single field shared by subject, object, and qualifier, and the verbatim branch is the same code for all three, so this also drops the CURIE-ranged qualifier opt-out. If that knob has a real use case, it wants its own field and its own finalize op rather than thebiolink:NamedThingcategory synthesis it inherited.