Skip to content

chore(deps): bump taiki-e/install-action from 2.75.18 to 2.75.22 #412

chore(deps): bump taiki-e/install-action from 2.75.18 to 2.75.22

chore(deps): bump taiki-e/install-action from 2.75.18 to 2.75.22 #412

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
name: Lint & Format
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Run Ruff linter
uses: astral-sh/ruff-action@0ce1b0bf8b818ef400413f810f8a11cdbda0034b # v4.0.0
with:
args: check --output-format=github .
- name: Run Ruff formatter check
uses: astral-sh/ruff-action@0ce1b0bf8b818ef400413f810f8a11cdbda0034b # v4.0.0
with:
args: format --check .
- name: Lint Dockerfile with hadolint
uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
with:
dockerfile: Dockerfile
failure-threshold: warning
type-check:
name: Type Check
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version-file: "pyproject.toml"
- name: Install uv
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
with:
enable-cache: true
- name: Install dependencies
run: uv sync --locked --no-dev --group typing
- name: Run mypy
run: uv run --no-dev --group typing mypy httptap
test:
name: Test / Python ${{ matrix.python-version }} / ${{ matrix.os }}
runs-on: ${{ matrix.os }}
timeout-minutes: 15
environment: ci
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
python-version:
- "3.10"
- "3.11"
- "3.12"
- "3.13"
- "3.14"
- "3.14t"
- "3.15"
- "3.15t"
steps:
- name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Install uv
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: uv sync --locked --no-dev --group test
- name: Run tests with coverage
run: uv run --no-dev --group test pytest --cov --cov-report=xml --cov-report=term
- name: Upload coverage to Codecov
if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.14' && github.actor != 'dependabot[bot]'
uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0
with:
files: ./coverage.xml
flags: unittests
name: httptap-coverage
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
- name: Upload test results to Codecov
if: ${{ !cancelled() && github.actor != 'dependabot[bot]' }}
uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0
with:
files: ./junit.xml
report_type: test_results
token: ${{ secrets.CODECOV_TOKEN }}
build:
name: Build Package
runs-on: ubuntu-latest
timeout-minutes: 5
needs:
- lint
- type-check
- test
steps:
- name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Install uv
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
- name: Build package
run: uv build
- name: Upload build artifacts
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: dist
path: dist/
retention-days: 7
compression-level: 6
if-no-files-found: error
container-build:
name: Container Build (${{ matrix.platform }})
runs-on: ubuntu-latest
timeout-minutes: 15
needs:
- lint
strategy:
fail-fast: false
matrix:
platform:
- linux/amd64
- linux/arm64
steps:
- name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Set up QEMU
if: matrix.platform != 'linux/amd64'
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4.0.0
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4.0.0
- name: Build and load image
uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f # v7.1.0
with:
context: .
platforms: ${{ matrix.platform }}
push: false
load: true
tags: httptap:ci-smoke
cache-from: type=gha,scope=${{ matrix.platform }}
cache-to: type=gha,mode=max,scope=${{ matrix.platform }}
- name: Smoke test (httptap --version)
env:
PLATFORM: ${{ matrix.platform }}
run: |
OUTPUT=$(docker run --rm --platform="$PLATFORM" httptap:ci-smoke --version)
echo "$OUTPUT"
echo "$OUTPUT" | grep -E '^httptap [0-9]+\.[0-9]+\.[0-9]+'
all-checks-pass:
name: All Checks Passed
if: ${{ !cancelled() }}
needs:
- lint
- type-check
- test
- build
- container-build
runs-on: ubuntu-latest
steps:
- name: Check all jobs
run: |
echo "lint: $LINT_RESULT"
echo "type-check: $TYPE_CHECK_RESULT"
echo "test: $TEST_RESULT"
echo "build: $BUILD_RESULT"
echo "container-build: $CONTAINER_BUILD_RESULT"
if [[ "$LINT_RESULT" != "success" ]] || \
[[ "$TYPE_CHECK_RESULT" != "success" ]] || \
[[ "$TEST_RESULT" != "success" ]] || \
[[ "$BUILD_RESULT" != "success" ]] || \
[[ "$CONTAINER_BUILD_RESULT" != "success" ]]; then
echo "One or more checks failed"
exit 1
fi
echo "All checks passed successfully!"
env:
LINT_RESULT: ${{ needs.lint.result }}
TYPE_CHECK_RESULT: ${{ needs.type-check.result }}
TEST_RESULT: ${{ needs.test.result }}
BUILD_RESULT: ${{ needs.build.result }}
CONTAINER_BUILD_RESULT: ${{ needs.container-build.result }}