Skip to content

stubtest_stdlib.py: suppress output from pip #9807

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

Merged
merged 2 commits into from
Feb 26, 2023

Conversation

AlexWaygood
Copy link
Member

Following #9734, there's now some fairly noisy output from pip if you run stubtest_stdlib.py locally, which I do quite a lot. This makes the output of the script hard to read. This PR suppresses the output from pip.

Prior to this PR:

(.venv) C:\Users\alexw\coding\typeshed>python tests/stubtest_stdlib.py
Collecting mypy==1.0
  Using cached mypy-1.0.0-cp311-cp311-win_amd64.whl (8.8 MB)
Collecting typing-extensions>=3.10
  Using cached typing_extensions-4.5.0-py3-none-any.whl (27 kB)
Collecting mypy-extensions>=0.4.3
  Using cached mypy_extensions-1.0.0-py3-none-any.whl (4.7 kB)
Installing collected packages: typing-extensions, mypy-extensions, mypy
Successfully installed mypy-1.0.0 mypy-extensions-1.0.0 typing-extensions-4.5.0

[notice] A new release of pip available: 22.3.1 -> 23.0.1
[notice] To update, run: C:\Users\alexw\AppData\Local\Temp\tmp86thq0va\Scripts\python.exe -m pip install --upgrade pip
Found existing installation: setuptools 65.5.0
Uninstalling setuptools-65.5.0:
  Successfully uninstalled setuptools-65.5.0
C:\Users\alexw\AppData\Local\Temp\tmp86thq0va\Scripts\python.exe -m mypy.stubtest --check-typeshed --custom-typeshed-dir . --allowlist tests\stubtest_allowlists\py3_common.txt --allowlist tests\stubtest_allowlists\py311.txt --allowlist tests\stubtest_allowlists\win32.txt --allowlist tests\stubtest_allowlists\win32-py311.txt
Success: no issues found in 484 modules
stubtest succeeded

With this PR applied:

(.venv) C:\Users\alexw\coding\typeshed>python tests/stubtest_stdlib.py
Setting up an isolated virtual environment...
C:\Users\alexw\AppData\Local\Temp\tmp1bkull8d\Scripts\python.exe -m mypy.stubtest --check-typeshed --custom-typeshed-dir . --allowlist tests\stubtest_allowlists\py3_common.txt --allowlist tests\stubtest_allowlists\py311.txt --allowlist tests\stubtest_allowlists\win32.txt --allowlist tests\stubtest_allowlists\win32-py311.txt
Success: no issues found in 484 modules
stubtest succeeded

@hauntsaninja hauntsaninja merged commit 2daa07d into python:main Feb 26, 2023
@AlexWaygood AlexWaygood deleted the suppress-pip branch February 26, 2023 00:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants