Skip to content

fix(ui): reinit Alpine.js on OOB-swapped pagination controls after fi… #8513

fix(ui): reinit Alpine.js on OOB-swapped pagination controls after fi…

fix(ui): reinit Alpine.js on OOB-swapped pagination controls after fi… #8513

Workflow file for this run

# ===============================================================
# Lint & Static Analysis - Code Quality Gate
# ===============================================================
#
# - Lints both mcpgateway/ and plugins/ in a unified workflow
# - Python linters run per-target; repo-wide checks run once
# - Each job installs the project in dev-editable mode
# ---------------------------------------------------------------
name: Lint & Static Analysis
on:
push:
branches: ["main"]
paths:
- "mcpgateway/**"
- "plugins/**"
- "pyproject.toml"
- ".github/workflows/lint.yml"
pull_request:
types: [opened, synchronize, ready_for_review]
branches: ["main"]
paths:
- "mcpgateway/**"
- "plugins/**"
- "pyproject.toml"
- ".github/workflows/lint.yml"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
# ---------------------------------------------------------------
# Python linters - run on both mcpgateway/ and plugins/
# ---------------------------------------------------------------
python-lint:
if: github.event_name != 'pull_request' || !github.event.pull_request.draft
strategy:
fail-fast: false
matrix:
target: [mcpgateway, plugins]
tool:
- id: flake8
setup: pip install flake8
cmd: "flake8 $TARGET"
- id: ruff
setup: pip install ruff
cmd: "ruff check $TARGET"
- id: unimport
setup: pip install unimport
cmd: "unimport $TARGET"
- id: vulture
setup: pip install vulture
cmd: 'vulture $TARGET --min-confidence 80 --exclude "*_pb2.py,*_pb2_grpc.py"'
- id: pylint
setup: "true"
cmd: "uv run pylint $TARGET --rcfile=.pylintrc.$TARGET --fail-on E --fail-under=10"
- id: interrogate
setup: pip install interrogate
cmd: "interrogate -vv $TARGET --fail-under 100"
- id: radon
setup: pip install radon
cmd: "radon cc $TARGET --min C --show-complexity && radon mi $TARGET --min B"
name: "${{ matrix.tool.id }} (${{ matrix.target }})"
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout source
uses: actions/checkout@v5
with:
fetch-depth: 1
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"
cache: pip
- name: Set up uv
uses: astral-sh/setup-uv@v6
- name: Install project (editable mode)
run: |
python3 -m pip install --upgrade pip
pip install -e .[dev]
- name: Install tool
run: ${{ matrix.tool.setup }}
- name: Run linter
env:
TARGET: ${{ matrix.target }}
run: ${{ matrix.tool.cmd }}
# ---------------------------------------------------------------
# Repo-wide syntax/format checkers (run once, not per-target)
# ---------------------------------------------------------------
syntax-check:
if: github.event_name != 'pull_request' || !github.event.pull_request.draft
strategy:
fail-fast: false
matrix:
include:
- id: yamllint
setup: pip install yamllint
cmd: yamllint -c .yamllint .
- id: jsonlint
setup: |
sudo apt-get update -qq
sudo apt-get install -y jq
cmd: |
find . -type f -name '*.json' -not -path './node_modules/*' -print0 |
xargs -0 -I{} jq empty "{}"
- id: tomllint
setup: pip install tomlcheck
cmd: |
find . -type f -name '*.toml' \
-not -path './plugin_templates/*' \
-not -path './mcp-servers/templates/*' \
-print0 |
xargs -0 -I{} tomlcheck "{}"
name: ${{ matrix.id }}
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout source
uses: actions/checkout@v5
with:
fetch-depth: 1
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"
cache: pip
- name: Install tool
run: ${{ matrix.setup }}
- name: Run check
run: ${{ matrix.cmd }}