Skip to content

Check all tests with pyright - #4424

Merged
r4victor merged 18 commits into
masterfrom
pr_pyright_all_tests
Oct 28, 2026
Merged

r4victor merged 18 commits into
masterfrom
pr_pyright_all_tests

Conversation

@r4victor

Copy link
Copy Markdown
Collaborator

Follow-up to #4418, which checked src/tests/_internal/core. Only tests and the pyright config change.

  • Check all of src/tests with pyright.
  • Narrow optional and union values in tests with asserts, isinstance, and get_or_error, adding shared get_verified_preset and get_fake_api helpers for the CLI preset tests.
  • Construct shorthand test inputs with model_validate and expected values with typed constructors.
  • Use replicas= and groups= instead of the legacy count= and list-valued replicas= in replica group tests.
  • Build AWS volumes with their configuration instead of mutating the volume configuration union.
  • Reach the optional fluentbit classes through the module instead of importing them conditionally.
  • Compare proxy repo listings as sorted lists, since pyright doesn't see frozen pydantic models as hashable.
  • Mock API clients with MagicMock in the run collection tests instead of hand-written fakes.
  • Use httpx2 in the model proxy test, as the installed openai client expects.
  • Ignore POSIX-only names in tests when pyright checks them for Windows.

@r4victor
r4victor merged commit d736e86 into master Oct 28, 2026
29 checks passed
@r4victor
r4victor deleted the pr_pyright_all_tests branch October 28, 2026 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant