Repository navigation
MOTOR-1485 Fix startup failures due to tox and pytest updates - #432
Merged
Merged
Conversation
tox 4.67.5 added a package-staging permission check that fails on Evergreen hosts and aborted every Linux and macOS task before any test ran; pin tox to 4.67.6, which drops the check. pytest 9.2.0 applies warning filters during pytest_configure, turning pytest-asyncio's unset asyncio_default_fixture_loop_scope warning into an INTERNALERROR; pin pytest to 9.2.0 and set the option to session scope.
There was a problem hiding this comment.
🔵 Needs a closer look
The Evergreen-host-specific tox regression cannot be reproduced from this checkout, so approval should await verification that tox 4.67.6 completes the affected staging path.
No open issues 🎉
What changed in this PR
This pull request stabilizes Motor’s weekly build by pinning known-good tox and pytest versions and configuring pytest-asyncio to prevent a deprecation warning from failing test startup.
Changes:
- Pins pytest to
9.2.0in the test requirements. - Pins tox to
4.67.6in the Evergreen runner. - Sets pytest-asyncio’s default fixture loop scope to
session.
| File | Description |
|---|---|
requirements/test.txt |
Pins pytest to 9.2.0. |
pyproject.toml |
Configures pytest-asyncio’s default fixture loop scope. |
.evergreen/run-tox.sh |
Pins the Evergreen tox version to 4.67.6. |
Review effort: Lite
NoahStapp
approved these changes
Nov 3, 2026
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.
Summary
The 2026-10-31 weekly Motor Build failed all 617 tasks before a test ran, on breaking changes from tox 4.67.5 and pytest 9.2.0. Pins known-good versions to unblock the weekly build. Fixes MOTOR-1485.
Changes
asyncio_default_fixture_loop_scopetosessionso pytest-asyncio's configure-time deprecation warning cannot fail the run underfilterwarnings = ["error"].Testing
sessionset, the same run collects 415 tests cleanly.