Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI] Use Python 3.12 for third-party stubtest #12847

Open
wants to merge 14 commits into
base: main
Choose a base branch
from
4 changes: 1 addition & 3 deletions .github/workflows/daily.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
# TODO: Use Python 3.12. As of 2024-03-08, several third-party
# packages fail to install with Python 3.12.
python-version: "3.11"
python-version: "3.12"
cache: pip
cache-dependency-path: |
requirements-tests.txt
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/stubtest_third_party.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,7 @@ jobs:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
# TODO: Use Python 3.12. As of 2024-03-08, several third-party
# packages fail to install with Python 3.12.
python-version: "3.11"
python-version: "3.12"
cache: pip
cache-dependency-path: |
requirements-tests.txt
Expand Down
3 changes: 3 additions & 0 deletions stubs/atheris/METADATA.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@ partial_stub = true

[tool.stubtest]
ignore_missing_stub = true
# TODO: Does not compile with Python 3.12 as of 2024-10-18 (release 2.3.0).
# https://github.com/google/atheris/pull/60
skip = true
13 changes: 13 additions & 0 deletions stubs/gdb/METADATA.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,16 @@ extra_description = """\
[tool.stubtest]
platforms = ["linux"]
apt_dependencies = ["gdb"]
# stubtest fails for unknown reasons after upgrading to use Python 3.12:
#
# Traceback (most recent call last):
# File "/tmp/stubtest-4m851njl/gdb_stubtest.py", line 22, in <module>
# from mypy.stubtest import main
# File "/tmp/stubtest-4m851njl/lib/python3.12/site-packages/mypy/stubtest.py", line 30, in <module>
# from pathlib import Path
# File "/usr/lib/python3.12/pathlib.py", line 19, in <module>
# from urllib.parse import quote_from_bytes as urlquote_from_bytes
# File "/usr/lib/python3.12/urllib/parse.py", line 36, in <module>
# import math
# ModuleNotFoundError: No module named 'math'
skip = true
4 changes: 0 additions & 4 deletions stubs/openpyxl/@tests/stubtest_allowlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,3 @@ openpyxl.worksheet.smart_tag.CellSmartTagPr.__init__
openpyxl.worksheet.smart_tag.CellSmartTags.__init__
openpyxl.worksheet.table.TableColumn.__init__
openpyxl.worksheet.table.XMLColumnProps.__init__

# Inherited from the stdlib, where we lie about the presence
# of this method in order to mark it as deprecated.
openpyxl.xml.functions.Element.__bool__
3 changes: 0 additions & 3 deletions stubs/requests/@tests/stubtest_allowlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,3 @@
requests.packages.mod
requests.packages.package
requests.packages.target

# Alias for builtins.bytes
requests.compat.bytes.__buffer__
Loading