GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Fix build for Python 3.14 by graingert · Pull Request #638 · MagicStack/uvloop

Conversation

@graingert

@graingert graingert commented Oct 20, 2024 •
edited by fantix
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Fixes #637

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
graingert and others added 8 commits October 20, 2024 21:34
@graingert
test on 3.14
3dd22b3
@graingert
deal with removed AbstractChildWatcher
4eea005
@fantix
Merge remote-tracking branch 'origin/master' into 3-14
d8bc272
@fantix
Fix marginal case typing
79f008b
In extreme cases, isinstance(..., ()) may still
return False instead of raising a TypeError
@hroncok @fantix
Workaround missing BaseDefaultEventLoopPolicy in Python 3.14
74e109e
This uses private API now.

Proper fix pending discussion in python/cpython#131148
@paulocheque @fantix
include py 3.14 in CI scripts
06d4232
@fantix
CPython 3.14-3.16 compat
20241b0
* Add deprecation in docstring
* Stop using private API, refs python/cpython#131148
* Use AbstractEventLoop instead, after @Vizonex's suggestion
@fantix
Fix dunder in class
540e6ab
@fantix fantix changed the title test on 3.14 Fix build for Python 3.14 Sep 14, 2025
@fantix
Fix tests
ae50a8e
@fantix
fantix marked this pull request as ready for review September 14, 2025 22:12
@fantix
fantix requested a review from 1st1 September 14, 2025 22:12
@fantix
Define EventLoopPolicy lazily to avoid warning
d66df03
@paulocheque paulocheque mentioned this pull request Sep 14, 2025
More changes for Python 3.14 #688
Closed
@fantix
Add uvloop.run to uvloop.__all__
64e89ea
Vizonex
Vizonex reviewed Sep 15, 2025
View reviewed changes

@Vizonex Vizonex left a comment •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

@graingert @fantix
I like the fact that my approach from winloop is being utilized here but would it be smart if the install() function threw an error if 3.16+ is used?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@fantix

fantix commented Sep 15, 2025

Copy link
Copy Markdown
Member

I'm not sure, but I feel like it's fine that uvloop.install raises AttributeError on Python 3.16 after versions of deprecation, maybe with a proper error message. Let me add that!

Vizonex and paulocheque reacted with thumbs up emoji Vizonex and paulocheque reacted with heart emoji
All reactions
  • 👍 2 reactions
  • ❤️ 2 reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@fantix
Add error message for 3.16
93d25d2
Vizonex
Vizonex approved these changes Sep 18, 2025
View reviewed changes

@Vizonex Vizonex left a comment •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Looks good. I'll have to mirror some of this myself even though I don't agree with all of it but it works nevertheless. You'll have to let 1st1 review it since I'm not the deciding factor but wanted to provide input and feedback to the project since I run the windows version of it.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

fantix reacted with heart emoji
All reactions
  • ❤️ 1 reaction
1st1
1st1 reviewed Oct 1, 2025
View reviewed changes
Comment thread uvloop/includes/stdlib.pxi
cdef aio_set_running_loop = getattr(asyncio, '_set_running_loop', None)
cdef aio_debug_wrapper = getattr(asyncio.coroutines, 'debug_wrapper', None)
cdef aio_AbstractChildWatcher = asyncio.AbstractChildWatcher
cdef aio_AbstractChildWatcher = getattr(asyncio, "AbstractChildWatcher", ())

@1st1 1st1 Oct 1, 2025

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Why () and not just None?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@fantix fantix Oct 1, 2025

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

() is a type, but None is not. We have usages like isinstance(..., aio_AbstractChildWatcher) and () returns False instead of TypeError.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@jakirkham jakirkham Oct 10, 2025

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

() is shorthand for tuple()

Much like {} is shorthand for dict()

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
1st1
1st1 reviewed Oct 1, 2025
View reviewed changes
Comment thread uvloop/__init__.py
from ._version import __version__ # NOQA


__all__ = ('new_event_loop', 'install', 'EventLoopPolicy')

@1st1 1st1 Oct 1, 2025

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

is _typing.Tuple[str, ...] necessary here?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@fantix fantix Oct 10, 2025

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Yeah the later __all__ += (...) would break typing

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
1st1
1st1 approved these changes Oct 1, 2025
View reviewed changes

@1st1 1st1 left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Good stuff, i've only two nit comments

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@janbjorge janbjorge mentioned this pull request Oct 9, 2025
Add py314 to test matrix janbjorge/pgqueuer#467
Merged
@fantix
fantix merged commit 46456b6 into MagicStack:master Oct 10, 2025
fantix added a commit that referenced this pull request Oct 10, 2025
@fantix
uvloop 0.22.0
3ab519b
Changes
=======

* Fixes for Python 3.14 (#638)
  (by @graingert @hroncok @paulocheque @fantix in 46456b6 for #637)

Fixes
=====

* Use Cython `enum` for `__PREALLOCED_BUFS` (#634)
  (by @jakirkham in 7bb12a1 for #634)

* test: fix getaddrinfo test (#663)
  (by @fantix in 5680792 for #663)

* test: fix task name for Python 3.13.3/3.14 (#662)
  (by @cjwatson in 96b7ed3 for #662)
@fantix fantix mentioned this pull request Oct 10, 2025
uvloop 0.22.0 #692
Merged
@Ahajha

Ahajha commented Oct 11, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

It seems that the 3.14 tests are still failing on main, any idea what happened there? Or was the intention to just fix the build?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

fantix added a commit that referenced this pull request Oct 15, 2025
@fantix
uvloop 0.22.0
c660c77
Changes
=======

* Fixes for Python 3.14 (#638)
  (by @graingert @hroncok @paulocheque @fantix in 46456b6 for #637)

* Add free-threading support (#693)
  (by @kumaraditya303 in 286b370 for #642)

Fixes
=====

* Use Cython `enum` for `__PREALLOCED_BUFS` (#634)
  (by @jakirkham in 7bb12a1 for #634)

* test: fix getaddrinfo test (#663)
  (by @fantix in 5680792 for #663)

* test: fix task name for Python 3.13.3/3.14 (#662)
  (by @cjwatson in 96b7ed3 for #662)
fantix added a commit that referenced this pull request Oct 15, 2025
@fantix
uvloop 0.22.0
4106f7f
Changes
=======

* Fixes for Python 3.14 (#638)
  (by @graingert @hroncok @paulocheque @fantix in 46456b6 for #637)

* Add free-threading support (#693)
  (by @kumaraditya303 in 286b370 for #642)

Fixes
=====

* Use Cython `enum` for `__PREALLOCED_BUFS` (#634)
  (by @jakirkham in 7bb12a1 for #634)

* test: fix getaddrinfo test (#663)
  (by @fantix in 5680792 for #663)

* test: fix task name for Python 3.13.3/3.14 (#662)
  (by @cjwatson in 96b7ed3 for #662)
fantix added a commit that referenced this pull request Oct 16, 2025
@fantix
uvloop 0.22.0
5229115
Changes
=======

* Fixes for Python 3.14 (#638)
  (by @graingert @hroncok @paulocheque @fantix in 46456b6 for #637)

* Add free-threading support (#693)
  (by @kumaraditya303 in 286b370 for #642)

Fixes
=====

* Use Cython `enum` for `__PREALLOCED_BUFS` (#634)
  (by @jakirkham in 7bb12a1 for #634)

* test: fix getaddrinfo test (#663)
  (by @fantix in 5680792 d9fa054 for #663)

* test: fix task name for Python 3.13.3/3.14 (#662)
  (by @cjwatson in 96b7ed3 for #662)
fantix added a commit that referenced this pull request Oct 16, 2025
@fantix
uvloop 0.22.0
3cf6b44
Changes
=======

* Fixes for Python 3.14 (#638)
  (by @graingert @hroncok @paulocheque @fantix in 46456b6 for #637)

* Add free-threading support (#693)
  (by @kumaraditya303 in 286b370 for #642)

Fixes
=====

* Use Cython `enum` for `__PREALLOCED_BUFS` (#634)
  (by @jakirkham in 7bb12a1 for #634)

* test: fix getaddrinfo test (#663)
  (by @fantix in 5680792 d9fa054 for #663)

* test: fix task name for Python 3.13.3/3.14 (#662)
  (by @cjwatson in 96b7ed3 for #662)
@tekumara tekumara mentioned this pull request Nov 15, 2025
Transactions not propagating from middleware newrelic/newrelic-python-agent#1581
Closed
@tjkuson tjkuson mentioned this pull request Jan 26, 2026
Documented uvloop pattern is deprecated pytest-dev/pytest-asyncio#1346
Closed
@skynet-rw skynet-rw Bot mentioned this pull request May 28, 2026
chore(deps): update container image python to v3.14 anthony-spruyt/firemerge#303
Merged
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@fantix fantix fantix left review comments
@1st1 1st1 1st1 approved these changes
+2 more reviewers
@jakirkham jakirkham jakirkham left review comments
@Vizonex Vizonex Vizonex approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

uvloop fails on 3.14

Uh oh!

There was an error while loading. Please reload this page.

8 participants

@graingert @fantix @Ahajha @1st1 @jakirkham @Vizonex @hroncok @paulocheque
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.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.