Skip to content

Update numpy version requirement for python 3.10+#101

Merged
guillon merged 1 commit into
xtc-tools:mainfrom
yadej:ci-python-version
Jun 29, 2026
Merged

Update numpy version requirement for python 3.10+#101
guillon merged 1 commit into
xtc-tools:mainfrom
yadej:ci-python-version

Conversation

@yadej

@yadej yadej commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

The current CI does not work anymore with the error

mypy
/opt/hostedtoolcache/Python/3.12.13/x64/lib/python3.12/site-packages/numpy/__init__.pyi:737: error: Type statement is only supported in Python 3.12 and greater  [syntax]
Found 1 error in 1 file (errors prevented further checking)
make: *** [Makefile:46: check-mypy] Error 2

Solution put the mypy python version to 3.12

@yadej yadej requested a review from guillon June 29, 2026 12:31
@codecov

codecov Bot commented Jun 29, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@guillon guillon left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Actually not the right solution, we require support for python 3.10+, hence the type checkers must assume python 3.10.

@guillon

guillon commented Jun 29, 2026

Copy link
Copy Markdown
Member

Actually not the right solution, we require support for python 3.10+, hence the type checkers must assume python 3.10.

Actually, the support for python 3.10 was dropped in numpy >=2.3, hence the right fix is to request numpy<2.3.

Can you test this, you will have to modify both pyproject.toml and requirements.txt?

@yadej yadej force-pushed the ci-python-version branch from 6b14a99 to 39a72ba Compare June 29, 2026 14:12
@yadej

yadej commented Jun 29, 2026

Copy link
Copy Markdown
Contributor Author

The CI passed with those changes

@guillon guillon added the bug Something isn't working label Jun 29, 2026
@guillon guillon changed the title Update mypy python version on pyproject to fix ci error Update numpy version requirement for python 3.10+ Jun 29, 2026
@guillon guillon self-requested a review June 29, 2026 15:06

@guillon guillon left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Great, thanks

@guillon guillon merged commit 442bdd3 into xtc-tools:main Jun 29, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants