Skip to content

Fix nushell deprecation warnings #732

Fix nushell deprecation warnings

Fix nushell deprecation warnings #732

Workflow file for this run

name: πŸ§ͺ check
on:
workflow_dispatch:
push:
branches: ["main"]
pull_request:
schedule:
- cron: "0 8 * * *"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: πŸ§ͺ test ${{ matrix.py }} - ${{ matrix.os }}
if: github.event_name != 'schedule' || github.repository_owner == 'pypa'
runs-on: ${{ matrix.os }}
timeout-minutes: 40
strategy:
fail-fast: false
matrix:
py:
- "3.13t"
- "3.13"
- "3.12"
- "3.11"
- "3.10"
- "3.9"
- "3.8"
- pypy-3.10
- pypy-3.9
- pypy-3.8
- graalpy-24.1
os:
- ubuntu-24.04
- macos-15
- windows-2025
include:
- { os: macos-15, py: "[email protected]" }
- { os: macos-15, py: "[email protected]" }
- { os: macos-15, py: "[email protected]" }
exclude:
- { os: windows-2025, py: "graalpy-24.1" }
- { os: windows-2025, py: "pypy-3.10" }
- { os: windows-2025, py: "pypy-3.9" }
- { os: windows-2025, py: "pypy-3.8" }
steps:
- name: πŸš€ Install uv
uses: astral-sh/setup-uv@v4
- name: πŸ“₯ Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 🐍 Setup Python for tox
uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: πŸ“¦ Install tox with this virtualenv
shell: bash
run: |
if [[ "${{ matrix.py }}" == "3.13t" ]]; then
uv tool install --no-managed-python --python 3.13 tox --with .
else
uv tool install --no-managed-python --python 3.13 tox --with tox-uv --with .
fi
- name: 🐍 Setup Python for test ${{ matrix.py }}
uses: actions/setup-python@v5
if: ${{ !startsWith(matrix.py, 'brew@') }}
with:
python-version: ${{ matrix.py }}
- name: πŸ› οΈ Install OS dependencies
shell: bash
run: |
if [ "${{ runner.os }}" = "Linux" ]; then
sudo apt-get install -y software-properties-common
sudo apt-add-repository ppa:fish-shell/release-4 -y
curl -fsSL https://apt.fury.io/nushell/gpg.key | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/fury-nushell.gpg
echo "deb https://apt.fury.io/nushell/ /" | sudo tee /etc/apt/sources.list.d/fury.list
sudo apt-get update -y
sudo apt-get install snapd fish csh nushell -y
elif [ "${{ runner.os }}" = "macOS" ]; then
if [[ "${{ matrix.py }}" == brew@* ]]; then
PY=$(echo '${{ matrix.py }}' | cut -c 6-)
brew install python@$PY || brew upgrade python@$PY
echo "/usr/local/opt/python@$PY/libexec/bin" >>"${GITHUB_PATH}"
fi
brew install fish tcsh nushell || brew upgrade fish tcsh nushell
elif [ "${{ runner.os }}" = "Windows" ]; then
choco install nushell
fi
- name: 🧬 Pick environment to run
shell: bash
run: |
py="${{ matrix.py }}"
if [[ "$py" == brew@* ]]; then
brew_version="${py#brew@}"
echo "TOX_DISCOVER=/opt/homebrew/bin/python${brew_version}" >> "$GITHUB_ENV"
py="$brew_version"
fi
[[ "$py" == graalpy-* ]] && py="graalpy"
echo "TOXENV=$py" >> "$GITHUB_ENV"
echo "Set TOXENV=$py"
- name: πŸ—οΈ Setup test suite
run: tox run -vvvv --notest --skip-missing-interpreters false
- name: πŸƒ Run test suite
run: tox run --skip-pkg-install
timeout-minutes: 20
env:
PYTEST_ADDOPTS: "-vv --durations=20"
CI_RUN: "yes"
DIFF_AGAINST: HEAD
check:
name: πŸ”Ž check ${{ matrix.tox_env }} - ${{ matrix.os }}
if: github.event_name != 'schedule' || github.repository_owner == 'pypa'
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-24.04
- windows-2025
tox_env:
- dev
- docs
- readme
- upgrade
- zipapp
exclude:
- { os: windows-2025, tox_env: readme }
- { os: windows-2025, tox_env: docs }
steps:
- name: πŸš€ Install uv
uses: astral-sh/setup-uv@v4
- name: πŸ“¦ Install tox
run: uv tool install --python-preference only-managed --python 3.13 tox --with tox-uv
- name: πŸ“₯ Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: πŸ—οΈ Setup check suite
run: tox run -vv --notest --skip-missing-interpreters false -e ${{ matrix.tox_env }}
- name: πŸƒ Run check for ${{ matrix.tox_env }}
run: tox run --skip-pkg-install -e ${{ matrix.tox_env }}