Skip to content

Commit cb2cd7b

Browse files
authored
check for Python >= 3.10
1 parent 4dd963f commit cb2cd7b

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

builder/main.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,15 @@
3535
from platformio.package.version import pepver_to_semver
3636
from platformio.util import get_serial_ports
3737

38+
# Check Python version requirement
39+
if sys.version_info < (3, 10):
40+
sys.stderr.write(
41+
f"Error: Python 3.10 or higher is required. "
42+
f"Current version: {sys.version_info.major}.{sys.version_info.minor}.{sys.version_info.micro}\n"
43+
f"Please update your Python installation.\n"
44+
)
45+
sys.exit(1)
46+
3847
# Python dependencies required for the build process
3948
python_deps = {
4049
"uv": ">=0.1.0",

0 commit comments

Comments
 (0)