Skip to content

Python 3.14.1 incompatibility #9307

@adamjstewart

Description

@adamjstewart

🐛 Describe the bug

It appears that Python 3.14.1 contains a regression that breaks torchvision's Weights dataclass. This results in error messages in the TorchGeo CI like:

AttributeError: 'wrapper_descriptor' object has no attribute '__annotate__'. Did you mean: '__getstate__'?

The culprit appears to be python/cpython#142214. This was fixed in 3.14.2, but it may be worth marking 3.14.1 as an unsupported and incompatible version of Python.

Versions

> python3 collect_env.py 
Collecting environment information...
PyTorch version: 2.9.0
Is debug build: False
CUDA used to build PyTorch: None
ROCM used to build PyTorch: N/A

OS: macOS 26.1 (arm64)
GCC version: Could not collect
Clang version: 18.1.8
CMake version: version 3.31.9
Libc version: N/A

Python version: 3.14.1 (main, Oct 28 2025, 13:26:07) [Clang 17.0.0 (clang-1700.3.19.1)] (64-bit runtime)
Python platform: macOS-26.1-arm64-arm-64bit-Mach-O
Is CUDA available: False
CUDA runtime version: No CUDA
CUDA_MODULE_LOADING set to: N/A
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA
Is XPU available: False
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True
Caching allocator config: N/A

CPU:
Apple M2 Pro

Versions of relevant libraries:
[pip3] Could not collect
[conda] Could not collect

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions