From 76960a168d61befc9f4167ca77344512400467ce Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Wed, 10 Apr 2024 22:11:05 -0700 Subject: [PATCH 1/3] Use 'version: PATH' for pyright-action --- .github/workflows/meta_tests.yml | 8 +------- .github/workflows/tests.yml | 12 +++--------- 2 files changed, 4 insertions(+), 16 deletions(-) diff --git a/.github/workflows/meta_tests.yml b/.github/workflows/meta_tests.yml index cca055306b2a..8586ba4f4f0c 100644 --- a/.github/workflows/meta_tests.yml +++ b/.github/workflows/meta_tests.yml @@ -56,16 +56,10 @@ jobs: python-version: "3.11" - run: curl -LsSf https://astral.sh/uv/install.sh | sh - run: uv pip install -r requirements-tests.txt --system - - name: Get pyright version - id: pyright_version - run: | - PYRIGHT_VERSION=$(grep pyright== requirements-tests.txt | cut -d "#" -f 1 | cut -d \; -f 1 | cut -d = -f 3) - echo pyright version: "${PYRIGHT_VERSION}" - echo PYRIGHT_VERSION="${PYRIGHT_VERSION}" >> "${GITHUB_OUTPUT}" - name: Run pyright on typeshed uses: jakebailey/pyright-action@v2 with: - version: ${{ steps.pyright_version.outputs.PYRIGHT_VERSION }} + version: PATH python-platform: ${{ matrix.python-platform }} python-version: "3.9" # The Python version to test against. project: ./pyrightconfig.scripts_and_tests.json diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 096b38675524..9e01a33fef62 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -129,23 +129,17 @@ jobs: run: echo "$PWD/.venv/bin" >> $GITHUB_PATH - name: List 3rd-party stub dependencies installed run: uv pip freeze - - name: Get pyright version - id: pyright_version - run: | - PYRIGHT_VERSION=$(grep pyright== requirements-tests.txt | cut -d "#" -f 1 | cut -d \; -f 1 | cut -d = -f 3) - echo pyright version: "${PYRIGHT_VERSION}" - echo PYRIGHT_VERSION="${PYRIGHT_VERSION}" >> "${GITHUB_OUTPUT}" - name: Run pyright with basic settings on all the stubs uses: jakebailey/pyright-action@v2 with: - version: ${{ steps.pyright_version.outputs.PYRIGHT_VERSION }} + version: PATH python-platform: ${{ matrix.python-platform }} python-version: ${{ matrix.python-version }} annotate: ${{ matrix.python-version == '3.11' && matrix.python-platform == 'Linux' }} # Having each job create the same comment is too noisy. - name: Run pyright with stricter settings on some of the stubs uses: jakebailey/pyright-action@v2 with: - version: ${{ steps.pyright_version.outputs.PYRIGHT_VERSION }} + version: PATH python-platform: ${{ matrix.python-platform }} python-version: ${{ matrix.python-version }} annotate: ${{ matrix.python-version == '3.11' && matrix.python-platform == 'Linux' }} # Having each job create the same comment is too noisy. @@ -153,7 +147,7 @@ jobs: - name: Run pyright on the test cases uses: jakebailey/pyright-action@v2 with: - version: ${{ steps.pyright_version.outputs.PYRIGHT_VERSION }} + version: PATH python-platform: ${{ matrix.python-platform }} python-version: ${{ matrix.python-version }} annotate: ${{ matrix.python-version == '3.11' && matrix.python-platform == 'Linux' }} # Having each job create the same comment is too noisy. From 4cb769c11be02fc5cc92ad81aa0d1b2b25dc9765 Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Wed, 10 Apr 2024 22:37:15 -0700 Subject: [PATCH 2/3] A little debugging --- .github/workflows/meta_tests.yml | 1 + .github/workflows/tests.yml | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/workflows/meta_tests.yml b/.github/workflows/meta_tests.yml index 8586ba4f4f0c..5758ae424d6d 100644 --- a/.github/workflows/meta_tests.yml +++ b/.github/workflows/meta_tests.yml @@ -56,6 +56,7 @@ jobs: python-version: "3.11" - run: curl -LsSf https://astral.sh/uv/install.sh | sh - run: uv pip install -r requirements-tests.txt --system + - run: pyright --version - name: Run pyright on typeshed uses: jakebailey/pyright-action@v2 with: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9e01a33fef62..b09b31486465 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -129,6 +129,7 @@ jobs: run: echo "$PWD/.venv/bin" >> $GITHUB_PATH - name: List 3rd-party stub dependencies installed run: uv pip freeze + - run: pyright --version - name: Run pyright with basic settings on all the stubs uses: jakebailey/pyright-action@v2 with: From fb4a73d3033c8fd264460375cc2da7bb9b9141f1 Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Fri, 12 Apr 2024 10:11:48 -0700 Subject: [PATCH 3/3] Revert "A little debugging" This reverts commit 4cb769c11be02fc5cc92ad81aa0d1b2b25dc9765. --- .github/workflows/meta_tests.yml | 1 - .github/workflows/tests.yml | 1 - 2 files changed, 2 deletions(-) diff --git a/.github/workflows/meta_tests.yml b/.github/workflows/meta_tests.yml index 5758ae424d6d..8586ba4f4f0c 100644 --- a/.github/workflows/meta_tests.yml +++ b/.github/workflows/meta_tests.yml @@ -56,7 +56,6 @@ jobs: python-version: "3.11" - run: curl -LsSf https://astral.sh/uv/install.sh | sh - run: uv pip install -r requirements-tests.txt --system - - run: pyright --version - name: Run pyright on typeshed uses: jakebailey/pyright-action@v2 with: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b09b31486465..9e01a33fef62 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -129,7 +129,6 @@ jobs: run: echo "$PWD/.venv/bin" >> $GITHUB_PATH - name: List 3rd-party stub dependencies installed run: uv pip freeze - - run: pyright --version - name: Run pyright with basic settings on all the stubs uses: jakebailey/pyright-action@v2 with: