Skip to content

[AMD] fix: support Python 3.10#12

Open
XinyuJiangCMU wants to merge 2 commits into
radixark:bridgefrom
XinyuJiangCMU:relax-requires-python-py310-20260614
Open

[AMD] fix: support Python 3.10#12
XinyuJiangCMU wants to merge 2 commits into
radixark:bridgefrom
XinyuJiangCMU:relax-requires-python-py310-20260614

Conversation

@XinyuJiangCMU

Copy link
Copy Markdown

Co-authored-with: @JessicaJiang-123

Summary

Support running Megatron Bridge on Python 3.10.

Changes

  • Relax requires-python from >=3.12,<3.13 to >=3.10,<3.13.
  • Import override from typing_extensions because typing.override is unavailable on Python 3.10.

Validation

Verified installation and builder imports on Python 3.10. Also verified a Qwen2.5 Megatron to HF weight update through AutoBridge.from_hf_pretrained.

XinyuJiangCMU and others added 2 commits June 15, 2026 17:49
The package targets py3.10 already (ruff target-version = py310, and the
classifiers list Python :: 3.10), but requires-python pins >=3.12, which
blocks installation on a Python 3.10 base. Relax the lower bound to 3.10.

Co-authored-by: Zhiyao Jiang <jessicajiang324@gmail.com>
typing.override is Python 3.12+; on 3.10 it raises ImportError when these
builder modules are imported. typing_extensions (already a dependency) provides
an identical override decorator and re-exports the stdlib one on 3.12+, so NV
behavior is unchanged.

Co-authored-by: Zhiyao Jiang <jessicajiang324@gmail.com>

@guapisolo guapisolo 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.

from typing import Any, Callable, ClassVar, Literal, override
from typing import Any, Callable, ClassVar, Literal

from typing_extensions import override

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

will this break in 3.12?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Tested on Python 3.12. It works normally and does not break anything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants