Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into feat/9255-fixme
Browse files Browse the repository at this point in the history
  • Loading branch information
badsketch committed Sep 30, 2024
2 parents 1ffc033 + c0ecd70 commit 51a2a14
Show file tree
Hide file tree
Showing 198 changed files with 1,658 additions and 787 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
fetch-depth: 0
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down Expand Up @@ -92,7 +92,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down Expand Up @@ -133,7 +133,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down Expand Up @@ -161,7 +161,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/primer-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ jobs:
timeout-minutes: 5
strategy:
matrix:
python-version: [3.9, "3.10", "3.11", "3.12"]
python-version: [3.9, "3.10", "3.11", "3.12", "3.13-dev"]
outputs:
python-key: ${{ steps.generate-python-key.outputs.key }}
steps:
- name: Check out code from GitHub
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down Expand Up @@ -72,13 +72,13 @@ jobs:
needs: prepare-tests-linux
strategy:
matrix:
python-version: [3.9, "3.10", "3.11", "3.12"]
python-version: [3.9, "3.10", "3.11", "3.12", "3.13-dev"]
steps:
- name: Check out code from GitHub
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/primer_comment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down
31 changes: 25 additions & 6 deletions .github/workflows/primer_run_main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,15 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true

# Create a re-usable virtual environment
- name: Create Python virtual environment cache
- name: Restore Python virtual environment cache
id: cache-venv
uses: actions/[email protected]
uses: actions/cache/restore@v4.0.2
with:
path: venv
key:
Expand All @@ -60,6 +60,17 @@ jobs:
. venv/bin/activate
python -m pip install -U pip setuptools wheel
pip install -U -r requirements_test.txt
# Save cached Python environment (explicit because cancel-in-progress: true)
- name: Save Python virtual environment to cache
if: steps.cache-venv.outputs.cache-hit != 'true'
uses: actions/cache/[email protected]
with:
path: venv
key:
${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
env.KEY_PREFIX }}-${{ env.CACHE_VERSION }}-${{ hashFiles('pyproject.toml',
'requirements_test.txt', 'requirements_test_min.txt',
'requirements_test_pre_commit.txt') }}

# Cache primer packages
- name: Get commit string
Expand All @@ -71,7 +82,7 @@ jobs:
echo "commitstring=$output" >> $GITHUB_OUTPUT
- name: Restore projects cache
id: cache-projects
uses: actions/[email protected]
uses: actions/cache/restore@v4.0.2
with:
path: tests/.pylint_primer_tests/
key: >-
Expand All @@ -82,8 +93,16 @@ jobs:
run: |
. venv/bin/activate
python tests/primer/__main__.py prepare --clone
- name: Save projects cache
if: steps.cache-projects.outputs.cache-hit != 'true'
uses: actions/cache/[email protected]
with:
path: tests/.pylint_primer_tests/
key: >-
${{ runner.os }}-${{ matrix.python-version }}-${{
steps.commitstring.outputs.commitstring }}-primer
- name: Upload commit string
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
if: matrix.batchIdx == 0
with:
name: primer_commitstring_${{ matrix.python-version }}
Expand All @@ -104,7 +123,7 @@ jobs:
then echo "::warning ::$WARNINGS"
fi
- name: Upload output
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
with:
name:
primer_output_main_${{ matrix.python-version }}_batch${{ matrix.batchIdx }}
Expand Down
31 changes: 25 additions & 6 deletions .github/workflows/primer_run_pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,15 +48,15 @@ jobs:
fetch-depth: 0
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true

# Restore cached Python environment
- name: Restore Python virtual environment
id: cache-venv
uses: actions/[email protected]
uses: actions/cache/restore@v4.0.2
with:
path: venv
key:
Expand All @@ -72,6 +72,17 @@ jobs:
. venv/bin/activate
python -m pip install -U pip setuptools wheel
pip install -U -r requirements_test.txt
# Save cached Python environment (explicit because cancel-in-progress: true)
- name: Save Python virtual environment
if: steps.cache-venv.outputs.cache-hit != 'true'
uses: actions/cache/[email protected]
with:
path: venv
key:
${{ runner.os }}-${{ steps.python.outputs.python-version }}-${{
env.KEY_PREFIX }}-${{ env.CACHE_VERSION }}-${{ hashFiles('pyproject.toml',
'requirements_test.txt', 'requirements_test_min.txt',
'requirements_test_pre_commit.txt') }}

# Cache primer packages
- name: Download last 'main' run info
Expand Down Expand Up @@ -140,7 +151,7 @@ jobs:
echo "commitstring=$output" >> $GITHUB_OUTPUT
- name: Restore projects cache
id: cache-projects
uses: actions/[email protected]
uses: actions/cache/restore@v4.0.2
with:
path: tests/.pylint_primer_tests/
key: >-
Expand All @@ -151,6 +162,14 @@ jobs:
run: |
. venv/bin/activate
python tests/primer/__main__.py prepare --clone
- name: Save projects cache
if: steps.cache-projects.outputs.cache-hit != 'true'
uses: actions/cache/[email protected]
with:
path: tests/.pylint_primer_tests/
key: >-
${{ runner.os }}-${{ matrix.python-version }}-${{
steps.commitstring.outputs.commitstring }}-primer
- name: Check cache
run: |
. venv/bin/activate
Expand Down Expand Up @@ -178,15 +197,15 @@ jobs:
then echo "::warning ::$WARNINGS"
fi
- name: Upload output of PR
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
with:
name:
primer_output_pr_${{ matrix.python-version }}_batch${{ matrix.batchIdx }}
path:
tests/.pylint_primer_tests/output_${{ matrix.python-version }}_pr_batch${{
matrix.batchIdx }}.txt
- name: Upload output of 'main'
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
with:
name:
primer_output_main_${{ matrix.python-version }}_batch${{ matrix.batchIdx }}
Expand All @@ -199,7 +218,7 @@ jobs:
- name: Upload PR number
if:
startsWith(steps.python.outputs.python-version, '3.9') && matrix.batchIdx == 0
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
with:
name: pr_number
path: pr_number.txt
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
Expand Down
22 changes: 12 additions & 10 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.9, "3.10", "3.11", "3.12"]
python-version: [3.9, "3.10", "3.11", "3.12", "3.13-dev"]
outputs:
python-key: ${{ steps.generate-python-key.outputs.key }}
steps:
- name: Check out code from GitHub
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down Expand Up @@ -76,9 +76,10 @@ jobs:
pip list | grep 'astroid\|pylint'
python -m pytest -vv --minimal-messages-config tests/test_functional.py
- name: Upload coverage artifact
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
with:
name: coverage-${{ matrix.python-version }}
include-hidden-files: true
path: .coverage

coverage:
Expand All @@ -91,7 +92,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python 3.12
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: "3.12"
check-latest: true
Expand Down Expand Up @@ -131,7 +132,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down Expand Up @@ -160,11 +161,12 @@ jobs:
run: >-
echo "datetime="$(date "+%Y%m%d_%H%M") >> $GITHUB_OUTPUT
- name: Upload benchmark artifact
uses: actions/upload-artifact@v4.3.4
uses: actions/upload-artifact@v4.4.0
with:
name:
benchmark-${{ runner.os }}-${{ matrix.python-version }}_${{
steps.artifact-name-suffix.outputs.datetime }}
include-hidden-files: true
path: .benchmarks/

tests-windows:
Expand All @@ -175,7 +177,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.9, "3.10", "3.11", "3.12"]
python-version: [3.9, "3.10", "3.11", "3.12", "3.13-dev"]
steps:
- name: Set temp directory
run: echo "TEMP=$env:USERPROFILE\AppData\Local\Temp" >> $env:GITHUB_ENV
Expand All @@ -185,7 +187,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down Expand Up @@ -231,7 +233,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down Expand Up @@ -275,7 +277,7 @@ jobs:
uses: actions/[email protected]
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.1.1
uses: actions/setup-python@v5.2.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
Expand Down
Loading

0 comments on commit 51a2a14

Please sign in to comment.