Skip to content

Fix test runs on pytest 9.2 - #1025

Merged
tdalmia-aws merged 1 commit into
aws-neuron:mainfrom
tdalmia-aws:fix/pytest-9.2
Oct 30, 2026
Merged

tdalmia-aws merged 1 commit into
aws-neuron:mainfrom
tdalmia-aws:fix/pytest-9.2

Conversation

@tdalmia-aws

Copy link
Copy Markdown
Contributor

pytest 9.2 came out on 10/27 and breaks our test runs in two ways:

  • conftest.py adds a --json_report option. pytest 9.2 now errors when two options share a dest, and this one clashes with pytest-json-report's --json-report, so every run fails at startup. Nothing uses the option, so this removes it.
  • pytest-forked 1.7.5 can't serialize the new report fields in 9.2, so every --forked test fails with "EXITED with status 3". This pins pytest<9.2 until pytest-forked has a release with the fix (Fix report serialization with pytest 9.2. pytest-dev/pytest-forked#112).

This is what's breaking the nightly: https://github.com/aws-neuron/torch-neuronx/actions/runs/40642076637

Testing: we made the same two changes internally and the forked distributed tests pass again on pytest 9.1.1.

Remove the unused --json_report conftest option, which clashes with
pytest-json-report on pytest 9.2. Pin pytest<9.2 because pytest-forked
1.7.5 cannot serialize the new 9.2 report fields.
@github-actions github-actions Bot added the module:build Touches build system label Oct 28, 2026
@tdalmia-aws
tdalmia-aws marked this pull request as ready for review October 28, 2026 18:26
@tdalmia-aws
tdalmia-aws requested review from a team as code owners October 28, 2026 18:26
@tdalmia-aws
tdalmia-aws merged commit d9d8423 into aws-neuron:main Oct 30, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

module:build Touches build system

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants