Merge pull request #9186 from dhalbert/9.0.x-setuptools

9.0.x - Handle change in tar file name caused by setuptools update #9185
This commit is contained in:
Dan Halbert 2024-04-17 11:54:54 -04:00 committed by GitHub
commit c2caae71de
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 1 deletions

View file

@ -110,6 +110,12 @@ autoapi_template_dir = 'docs/autoapi/templates'
autoapi_python_class_content = "both"
autoapi_python_use_implicit_namespaces = True
autoapi_root = "shared-bindings"
# Suppress cache warnings to prevent "unpickable" [sic] warning
# about autoapi_prepare_jinja_env() from sphinx >= 7.3.0.
# See https://github.com/sphinx-doc/sphinx/issues/12300
suppress_warnings = ["config.cache"]
def autoapi_prepare_jinja_env(jinja_env):
jinja_env.globals['support_matrix_reverse'] = modules_support_matrix_reverse

View file

@ -5,7 +5,8 @@ python3 -m venv test-stubs
pip install mypy isort black adafruit-circuitpython-typing wheel build
rm -rf circuitpython-stubs .mypy_cache
make stubs
pip install --force-reinstall circuitpython-stubs/dist/circuitpython-stubs-*.tar.gz
# Allow either dash or underscore as separator. setuptools v69.3.0 changed from "-" to "_".
pip install --force-reinstall circuitpython-stubs/dist/circuitpython[-_]stubs-*.tar.gz
export MYPYPATH=circuitpython-stubs/
echo "The following test should pass:"
mypy -c 'import busio; b: busio.I2C; b.writeto(0x30, b"")'