Bump click and linkml floors for click 8.3 compat#230
Merged
Conversation
Bumps click>=8.2 (which removed the CliRunner mix_stderr kwarg in favour of always-separate stdout/stderr) and linkml/linkml-runtime to >=1.11.0rc3 (which requires click>=8.2 itself). Drops the now-removed mix_stderr=False kwarg from the four CliRunner fixtures. linkml 1.11rc3 also tightens validate-spec's structural validation, which surfaced a latent data-model bug: ElementDerivation.is_a / mixins are looked up by string name at runtime (_find_class_derivation_by_name) but the generated JSON Schema required an inline ElementDerivation object. Switching ElementDerivation.name from key: true to identifier: true (matching linkml's own meta.yaml convention for Element) lets schema generation produce the string variant, aligning the validator with the runtime. The lock pulls in linkml/linkml-runtime 1.11.0rc3 explicitly so CI is green now; sit on the PR until 1.11.0 GA, then refresh the lock to the final release.
Contributor
There was a problem hiding this comment.
Pull request overview
Updates dependency minimums and related fixtures to stay compatible with newer click (8.3+) and linkml (1.11 validation behavior), and adjusts the LinkML-map transformer datamodel so validate-spec accepts the string-reference form the runtime already uses.
Changes:
- Bump dependency floors (
click>=8.2,linkml>=1.11.0rc3,linkml-runtime>=1.11.0rc3) and refreshuv.lockaccordingly. - Remove the now-unsupported
mix_stderr=Falsekwarg fromCliRunnerfixtures in CLI tests. - Update the transformer LinkML schema (
ElementDerivation.name) to be anidentifier, and bump the generated model’smetamodel_version.
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
pyproject.toml |
Raises minimum dependency versions for click/linkml/linkml-runtime. |
uv.lock |
Refreshes the resolved dependency set to include the new minimums/RCs. |
tests/test_cli/test_cli.py |
Drops mix_stderr=False from CliRunner() fixture. |
tests/test_cli/test_cli_validate.py |
Drops mix_stderr=False from CliRunner() fixture. |
tests/test_cli/test_cli_multi_spec.py |
Drops mix_stderr=False from CliRunner() fixture. |
tests/test_cli/test_cli_tabular.py |
Drops mix_stderr=False from CliRunner() fixture. |
src/linkml_map/datamodel/transformer_model.yaml |
Changes ElementDerivation.name from key: true to identifier: true for LinkML 1.11 structural validation compatibility. |
src/linkml_map/datamodel/transformer_model.py |
Regenerated; bumps metamodel_version to 1.11.0. |
tests/input/examples/personinfo_basic/transform/personinfo-to-agent.transform.yaml |
Adds a description to the Entity derivation. |
AGENTS.md |
Updates repo workflow notes to uv run … / make (removes stale just references). |
6 tasks
Contributor
Author
Final state
Description body intentionally preserved as written for history; this comment reflects the shipped state. |
This was referenced May 14, 2026
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.
Closes #218.
Summary
click>=8.2(which removedCliRunner(mix_stderr=...)in favour of always-separatestdout/stderr).linkml>=1.11.0rc3andlinkml-runtime>=1.11.0rc3(linkml 1.11 itself requiresclick>=8.2, so the floors move together).mix_stderr=Falsekwarg from the fourCliRunnerfixtures.Why the data-model change is in scope
linkml 1.11rc3 tightens
validate-spec's structural validation, which surfaced a latent inconsistency in linkml-map's data model:ClassDerivation.is_a/mixinsas string name references (_class_derivation_ancestorsintransformer/transformer.pycalls_find_class_derivation_by_name(parent);schema_mapper.pyassignscd.is_astraight intoClassDefinition.is_awhich is a string slot).is_awasanyOf: [{$ref: ElementDerivation}, null]— no string variant — becauseElementDerivationhad noidentifier: trueslot. linkml 1.10 didn't run this structural check; 1.11rc3 does, and rejects any stringis_a:value.Switching
ElementDerivation.namefromkey: truetoidentifier: truematches linkml's ownmeta.yamlconvention forElement(wherename: identifier: trueis the canonical pattern for schema elements) and lets the JSON Schema generator emit the string-reference variant. This brings the validator in line with how the runtime actually uses these slots.Regenerated
transformer_model.pyviamake. The only diff in the regenerated pydantic file is themetamodel_versionbump (1.7.0 → 1.11.0) — no class-shape changes.Other changes
tests/input/examples/personinfo_basic/transform/personinfo-to-agent.transform.yaml: added adescription:to the previously emptyEntity:derivation (cosmetic; not required after the data-model fix).AGENTS.md: removed stalejustreferences — the repo doesn't usejust, onlyuv run …andmaketargets.Lock file
The lock is refreshed against the prereleases (
uv lock --upgrade-package linkml --upgrade-package linkml-runtime --upgrade-package click --prerelease=allow) so CI passes now. Plan: sit on this PR until linkml 1.11.0 GA, thenuv lockagain to move from rc3 → 1.11.0 final before merging.Test plan
uv run pytest— 794 passed, 4 skipped locallyuv run pytest --doctest-modules src/linkml_map/— 18 passed locallyuv run ruff check .anduv run ruff format --check .— clean locally