Skip to content

Fix sendspin serve crash on Python 3.12#252

Merged
maximmaxim345 merged 1 commit into
mainfrom
fix/serve-python-3.12-compat
May 12, 2026
Merged

Fix sendspin serve crash on Python 3.12#252
maximmaxim345 merged 1 commit into
mainfrom
fix/serve-python-3.12-compat

Conversation

@maximmaxim345
Copy link
Copy Markdown
Member

sendspin serve raised TypeError: type 'Synchronized' is not subscriptable at import time on Python 3.12 because multiprocessing.sharedctypes.Synchronized[int] only gained __class_getitem__ in 3.13.

@maximmaxim345 maximmaxim345 added the bugfix Fixes a bug label May 12, 2026
Copilot AI review requested due to automatic review settings May 12, 2026 07:21
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes an import-time crash of sendspin serve on Python 3.12 caused by subscripting multiprocessing.sharedctypes.Synchronized in a type annotation (which only becomes subscriptable in Python 3.13+).

Changes:

  • Enables postponed evaluation of annotations in the embedded server module by adding from __future__ import annotations.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@maximmaxim345 maximmaxim345 merged commit cdbc010 into main May 12, 2026
5 checks passed
@maximmaxim345 maximmaxim345 deleted the fix/serve-python-3.12-compat branch May 12, 2026 07:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix Fixes a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants