Skip to content

Fix tests for Python 3.14#582

Merged
SergeyKanzhelev merged 4 commits into
w3c:mainfrom
martincostello:gh-581
Jun 29, 2026
Merged

Fix tests for Python 3.14#582
SergeyKanzhelev merged 4 commits into
w3c:mainfrom
martincostello:gh-581

Conversation

@martincostello

@martincostello martincostello commented Mar 15, 2026

Copy link
Copy Markdown
Contributor

Update asyncio event loop so it works on Python 3.14.

Fixes #581.

Depends on #580 to rebase.

- Update tests to run a matrix for 3.11-3.14.
- Update GitHub Actions to their latest versions.
- Disable until w3c#581 is fixed.
- Add job to meet the required statuses without needing to reconfigure the status checks.
Update asyncio event loop so it works on Python 3.14.
@w3cbot

w3cbot commented Mar 15, 2026

Copy link
Copy Markdown

martincostello marked as non substantive for IPR from ash-nazg.

Comment thread .github/workflows/self_test.yml

@dyladan dyladan left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this can be reviewed and merged separately from the other PR. You can just remove the changes you made to the self_test.yml and bump the version to latest.

@martincostello

Copy link
Copy Markdown
Contributor Author

I felt the approach of merging #581 then this one doesn't mean I fix my issue (3.14 not working) but causes an issue for someone else by accident.

@dyladan dyladan added the tooling This issue or PR affects tooling or processes and does not affect the specification itself label Apr 21, 2026
@maraisr

maraisr commented Jun 17, 2026

Copy link
Copy Markdown
Member

Ah thanks for this! Can't wait for this land. In tctx I had to wrap the harness in this:

https://github.com/maraisr/tctx/blob/b921308d1f2fa089f4b21714f36fd395e18360dc/validation/test.sh#L19-L24

import asyncio, runpy, sys

sys.path.insert(0, "w3c/test")
sys.argv = ["w3c/test/test.py", *sys.argv[1:]]
asyncio.set_event_loop(asyncio.new_event_loop())
runpy.run_path("w3c/test/test.py", run_name="__main__")

@dyladan dyladan marked this pull request as ready for review June 29, 2026 20:39

@zacharycmontoya zacharycmontoya left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@SergeyKanzhelev SergeyKanzhelev merged commit 9e4d52f into w3c:main Jun 29, 2026
6 checks passed
@martincostello martincostello deleted the gh-581 branch June 30, 2026 06:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tooling This issue or PR affects tooling or processes and does not affect the specification itself

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tests fail when using Python 3.14

6 participants