chore: dependency refresh and compatibility/docs alignment (aiodns 4.x, tests, CI) #514
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
| # This workflow will install Python dependencies, run tests and lint with a variety of Python versions | |
| # Enhanced with modern ruff toolchain while preserving original matrix testing approach | |
| name: build & test | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: | |
| branches: [master] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] | |
| poetry-version: ["2.3.2"] | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Install and configure Poetry | |
| uses: snok/install-poetry@76e04a911780d5b312d89783f7b1cd627778900a # v1.4.1 | |
| with: | |
| version: ${{ matrix.poetry-version }} | |
| virtualenvs-in-project: true | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: 'poetry' | |
| - name: Install library | |
| run: poetry install --no-interaction | |
| - name: Lint with ruff (modern replacement for flake8) | |
| run: | | |
| # ruff is in the Poetry dev dependency group so it's already | |
| # installed by `poetry install` above — no ad-hoc pip install needed | |
| # stop the build if there are Python syntax errors or undefined names | |
| poetry run ruff check . --select=E9,F63,F7,F82 --output-format=github | |
| # comprehensive linting with GitHub integration | |
| poetry run ruff check . --output-format=github | |
| - name: Check code formatting with ruff | |
| run: | | |
| # Verify code is properly formatted (replaces black/isort) | |
| poetry run ruff format --check . | |
| - name: Test with pytest | |
| run: | | |
| # Run full test suite with coverage | |
| poetry run pytest tests/ -v --cov=proxybroker --cov-report=term-missing --cov-fail-under=60 |