Skip to content

Commit

Permalink
Make setuptools check on CI more precise
Browse files Browse the repository at this point in the history
This checks for setuptools as a full word at the very beginning of
a line of output from "pip freeze --all", to:

- Avoid the unlikely but possible case that setuptools is absent
  while something besides setuptools has "setuptools" in its line.

- Prevent "setuptools" from being passed to install multiple times.
  This causes no problems -- it's still only installed/upgraded at
  most once -- but it was making the GitHub Actions log confusing
  on Cygwin. (It could happen on other platforms, but hasn't been.)
  • Loading branch information
EliahKagan committed Dec 23, 2023
1 parent ad19912 commit ebacfd9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cygwin-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
- name: Update PyPA packages
run: |
# Get the latest pip, wheel, and prior to Python 3.12, setuptools.
python -m pip install -U pip $(pip freeze --all | grep -oF setuptools) wheel
python -m pip install -U pip $(pip freeze --all | grep -ow ^setuptools) wheel
- name: Install project and test dependencies
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pythonpackage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:
- name: Update PyPA packages
run: |
# Get the latest pip, wheel, and prior to Python 3.12, setuptools.
python -m pip install -U pip $(pip freeze --all | grep -oF setuptools) wheel
python -m pip install -U pip $(pip freeze --all | grep -ow ^setuptools) wheel
- name: Install project and test dependencies
run: |
Expand Down

0 comments on commit ebacfd9

Please sign in to comment.