You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
🤖 This PR was created by Repo Assist, an automated AI assistant.
Summary
This is Stage 3 of the test linting plan (see TEST_LINTING_PLAN.md): add pyright strict-mode type annotations to all 14 test files in tests/test_scheduler/ so the directory can be removed from pyright's exclude list.
Changes
14 test files annotated
Added -> None return types to all test methods and __init__ methods
Typed all handler(_) callbacks: (_: Exception) -> bool
Typed periodic action callbacks with appropriate state types
Added from typing import Any and from reactivex import abc imports where needed
Typed CatchSchedulerTestScheduler class attributes and overridden methods
Typed Timestamped helper class and module-level helper functions in test_historicalscheduler.py
Typed nested action functions throughout
pyproject.toml
Removed "tests/test_scheduler" from the [tool.pyright] exclude list
Added "tests/test_scheduler/test_mainloop" (GUI library tests stay excluded — they require external dependencies like tkinter, gtk, wx, etc.)
What's excluded and why
tests/test_scheduler/test_mainloop/ remains excluded — these tests require optional GUI libraries (tkinter, gtk, wx, qt, etc.) not available in CI, and fixing them would require conditional imports.
Testing
All 115 scheduler tests pass (16 skipped as expected for flaky CI tests). CI will run the full suite via uv run pytest and validate types with uv run pyright.
This was originally intended as a pull request, but the patch modifies protected files. These files may affect project dependencies, CI/CD pipelines, or agent behaviour. Please review the changes carefully before creating the pull request.
🤖 This PR was created by Repo Assist, an automated AI assistant.
Summary
This is Stage 3 of the test linting plan (see
TEST_LINTING_PLAN.md): add pyright strict-mode type annotations to all 14 test files intests/test_scheduler/so the directory can be removed from pyright'sexcludelist.Changes
14 test files annotated
-> Nonereturn types to all test methods and__init__methodsaction(scheduler, state)callbacks:(abc.SchedulerBase, Any) -> abc.DisposableBase | Nonehandler(_)callbacks:(_: Exception) -> boolfrom typing import Anyandfrom reactivex import abcimports where neededCatchSchedulerTestSchedulerclass attributes and overridden methodsTimestampedhelper class and module-level helper functions intest_historicalscheduler.pypyproject.toml"tests/test_scheduler"from the[tool.pyright]exclude list"tests/test_scheduler/test_mainloop"(GUI library tests stay excluded — they require external dependencies like tkinter, gtk, wx, etc.)What's excluded and why
tests/test_scheduler/test_mainloop/remains excluded — these tests require optional GUI libraries (tkinter,gtk,wx,qt, etc.) not available in CI, and fixing them would require conditional imports.Testing
All 115 scheduler tests pass (16 skipped as expected for flaky CI tests). CI will run the full suite via
uv run pytestand validate types withuv run pyright.Progress toward full test suite coverage:
Warning
Protected Files
This was originally intended as a pull request, but the patch modifies protected files. These files may affect project dependencies, CI/CD pipelines, or agent behaviour. Please review the changes carefully before creating the pull request.
Click here to create the pull request once you have reviewed the changes
Protected files
pyproject.tomlTo route changes like this to a review issue instead of blocking, configure
protected-files: fallback-to-issuein your workflow configuration.Note
🔒 Integrity filter blocked 8 items
The following items were blocked because they don't meet the GitHub integrity level.
list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".To allow these resources, lower
min-integrityin your GitHub frontmatter: