Repository navigation
fix: test the dependency floors, and import each adapter only when it is used - #89
Merged
Merged
Conversation
… is used The floors in pyproject were never installed together, and three were wrong: scipy 1.14.0 has no Python 3.13 wheel, anthropic before 0.77 lacks the structured output types, and typer before 0.16 breaks on click 8.2. They are now the oldest releases the suite passes on, the SDKs are capped below their next breaking series, httpx is dropped (nothing imported it), and a CI job runs the suite on the lowest direct resolution. The registry imported every adapter at startup, so one broken SDK took down the mock too. Built-ins are now imported on first create, and a failed import names the module and the adapter. Fixes #47. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
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 #47.
Floors. Each floor in pyproject is now the oldest release the whole suite passes on, found by bisecting PyPI and confirmed with a lowest-direct lock:
OutputConfigParamThe dev group gains
click>=8.2, which the CLI tests need to read stderr apart from stdout.CI. A new job, "the oldest dependencies pyproject allows", runs
uv lock --resolution lowest-direct, thenuv sync --frozen, then pytest on Python 3.12. It has to lock first:uv sync --resolutionkeeps an existing lockfile that already satisfies pyproject, so on its own it quietly installs the newest releases.Lazy adapters. Until now the registry imported all four adapters at startup, so a broken
anthropicinstall stopped the mock from working too. Now:create.PlumblineError, naming both the adapter and the missing module.available()lists every adapter without importing any of them.plumbline.adaptersloads its adapter classes on first access.A new test runs a subprocess with
anthropicblocked. In it the mock still works, andgenerativefails with a one-line error.Checks: ruff, format, mypy --strict and pytest all pass on the locked versions, and pytest passes on the lowest resolution (numpy 2.1.0, scipy 1.14.1, typer 0.16.0, click 8.2.0, typesafe-sdk 0.5.7, anthropic 0.77.0, pytest 8.3.0).
🤖 Generated with Claude Code