We still support Python 2.7 #154
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
| name: ci | |
| on: [push, pull_request] | |
| jobs: | |
| ci: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: ["ubuntu-latest"] | |
| python-version: ["2.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.13t", "3.14", "3.14t"] | |
| include: | |
| - os: macos-latest | |
| python-version: "3.x" | |
| # - os: windows-latest # TODO: Fix the Windows test that runs in an infinite loop | |
| # python-version: '3.13' | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| if: matrix.python-version != '2.7' | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Set up Python 2 | |
| if: matrix.python-version == '2.7' | |
| run: | | |
| sudo rm -f $(which python) $(which pip) | |
| sudo apt-get install python2.7-dev | |
| curl https://bootstrap.pypa.io/pip/2.7/get-pip.py -o get-pip.py | |
| python2.7 get-pip.py | |
| sudo ln -sf "$(which python2.7)" "$(dirname $(which python2.7))/python" | |
| - run: pip install --upgrade pip | |
| - run: pip install --upgrade pytest | |
| - run: pip install --editable . | |
| - if: runner.os == 'macOS' | |
| run: brew install libmagic | |
| - if: runner.os == 'Windows' | |
| run: pip install python-magic-bin | |
| - run: LC_ALL=en_US.UTF-8 pytest | |
| shell: bash | |
| timeout-minutes: 15 # Limit Windows infinite loop. |