Skip to content

Fix web analyzer feedback and Diameter identity display #108

Fix web analyzer feedback and Diameter identity display

Fix web analyzer feedback and Diameter identity display #108

Workflow file for this run

name: CI
on:
push:
pull_request:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Install project
run: |
python -m pip install --upgrade pip setuptools wheel build
python -m pip install -e .[dev]
- name: Ruff
run: ruff check .
- name: Bandit web hardening scan
run: bandit -r -ll src/pcap2llm/web/
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11", "3.12"]
steps:
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install tshark
run: |
sudo apt-get update
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y tshark
- name: Install project
run: |
python -m pip install --upgrade pip
python -m pip install -e .[dev,encrypt]
- name: Tests
run: pytest -q
- name: Web smoke test
if: matrix.python-version == '3.12'
run: bash scripts/smoke_test_web_gui.sh
- name: Upload failure artifacts
if: failure()
uses: actions/upload-artifact@v4
with:
name: test-debug-${{ matrix.python-version }}
path: |
tests/fixtures/golden/**/expected_*.json
artifacts/**
local-files-guard:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Block tracked .local/ sensitive files
run: |
tracked="$(git ls-files '.local' | grep -Ev '^\.local/(\.gitkeep|README\.md)$' || true)"
if [ -n "$tracked" ]; then
echo "ERROR: forbidden tracked files found under .local/:" >&2
printf '%s\n' "$tracked" | sed 's/^/ /' >&2
exit 1
fi
echo "OK: no disallowed files tracked under .local/"
packaging:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Install project
run: |
python -m pip install --upgrade pip setuptools wheel build
python -m pip install -e .[dev]
- name: Build package
run: python -m build --no-isolation
- name: Validate wheel metadata
run: python scripts/check_package_metadata.py dist/*.whl dist/*.tar.gz
- name: Upload packaging artifacts on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: packaging-debug
path: |
dist/**
pyproject.toml