-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Support external-dependencies in pyright #9434
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
AlexWaygood
merged 22 commits into
python:main
from
Avasam:support-non-type-dependency-pyright
Jan 3, 2023
Merged
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
2096d1e
Support external-dependencies in pyright
Avasam a2c3bfd
Conditional install
Avasam 66b8552
install tools first
Avasam 0682f43
Fallback to lru_cache
Avasam 0a81784
install typing_extensions
Avasam 1c05a35
pathspec + packaging
Avasam a7315e8
Fix pyright dep installs
Avasam dd9a512
Revert lru_cache shim
Avasam 557f871
Correctly de-duplicate requirements
Avasam fc61899
Merge branch 'main' into support-non-type-dependency-pyright
AlexWaygood 8766612
Update tests/utils.py
Avasam 87324d4
Revert if TYPE_CHECKING
Avasam f2f0b8d
Merge branch 'support-non-type-dependency-pyright' of https://github.…
Avasam 1ea0b23
Add doc about installing deps
Avasam 8dd53a2
Apply suggestions from code review
Avasam 807a8f4
Update tests/README.md
Avasam 1ff9c18
Update tests/README.md
Avasam 5abb5e1
Oops another typo
AlexWaygood dfa4085
Rename scripts
Avasam b5a2495
Add some random non-types dependencies to see what happens
AlexWaygood fad4c7c
Revert "Add some random non-types dependencies to see what happens"
AlexWaygood a89c681
Reflow docs to keep line length <90 characters where practical
AlexWaygood File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -112,6 +112,20 @@ jobs: | |
fail-fast: false | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: pip | ||
cache-dependency-path: requirements-tests.txt | ||
- name: Install 3rd-party dependencies for stubs packages | ||
run: | | ||
pip install -r requirements-tests.txt | ||
DEPENDENCIES=$(python tests/get_external_stub_requirements.py) | ||
if [ -n "$DEPENDENCIES" ]; then | ||
echo "Installing packages: $DEPENDENCIES" | ||
pip install $DEPENDENCIES | ||
fi | ||
- run: pip freeze --all | ||
- name: Get pyright version | ||
Avasam marked this conversation as resolved.
Show resolved
Hide resolved
|
||
uses: SebRollen/[email protected] | ||
id: pyright_version | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/env python3 | ||
from __future__ import annotations | ||
|
||
import os | ||
import sys | ||
|
||
from utils import read_dependencies | ||
|
||
distributions = sys.argv[1:] | ||
if not distributions: | ||
distributions = os.listdir("stubs") | ||
|
||
requirements = set[str]() | ||
for distribution in distributions: | ||
requirements.update(read_dependencies(distribution).external_pkgs) | ||
|
||
for requirement in sorted(requirements): | ||
print(requirement) |
0
tests/get_packages.py → tests/get_stubtest_system_requirements.py
100755 → 100644
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.