CI: apply Linux-only sitecustomize guard to linting.yaml, drop dead comment - #130
Merged
Merged
Conversation
…op dead comment Mirrors the windows-latest-safety change from testing.yaml (#129): - linting.yaml's "Remove sitecustomize.py" step is Ubuntu-specific (sudo rm), so it's now gated behind `if: runner.os == 'Linux'` and renamed for consistency, even though linting.yaml doesn't run a Windows job yet - keeps both workflows honest about the same assumption. - testing.yaml: remove the commented-out "Remove sitecustomize.py" block that's been dead since the live, guarded step was added right below it.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #130 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 4 4
Lines 83 83
Branches 4 4
=========================================
Hits 83 83
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
pyproject.toml classifies Operating System :: Microsoft :: Windows, but
testing.yaml's matrix only ran ubuntu-latest, and the one test that behaves
differently on Windows (test_autoread_dotenv_unreadable_file_warns, which
relies on chmod-based permission denial) is skipif'd there - so that path
was never actually exercised on the one platform it differs most on.
Adds a single windows-latest job (Python 3.14) via matrix.include, rather
than crossing all 7 Python versions with it, to keep the added job count
small; it's free either way since this is a public repo (GitHub Actions
minutes are unlimited for public repos on every runner OS).
Two changes were needed to make the job actually work rather than just
exist:
- The ubuntu-remove-global-sitecustomize step is Linux-specific (sudo rm),
so it's now gated behind `if: runner.os == 'Linux'`.
- The job now forces `shell: bash` as the default, so the existing
${VAR}-style run steps use Windows' bundled Git Bash instead of falling
back to pwsh's incompatible variable syntax.
Verified: zizmor and the YAML parses cleanly; the justfile's install/build
recipes already have [unix]/[windows] variants for the OS-sensitive steps
(symlink creation, dir creation), so no changes were needed there.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Small follow-up to #129 (the
windows-latestCI job).linting.yaml's "Remove sitecustomize.py" step runssudo rm -f ..., which is Ubuntu-only.It's now gated behind
if: runner.os == 'Linux'and renamed to matchtesting.yaml's step,for consistency - even though
linting.yamldoesn't run a Windows job itself yet.testing.yaml: removed the commented-out duplicate "Remove sitecustomize.py" block, deadsince the live, guarded step was added right below it.
Testing
zizmor(pedantic persona): no findings