name: Code Quality Check on: push: branches: [ main, develop ] pull_request: branches: [ main ] jobs: code-quality: name: Code Quality Analysis runs-on: ubuntu-latest steps: - name: Checkout Code uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v5 with: python-version: '3.13' - name: Install Dependencies run: | python -m pip install --upgrade pip pip install -r requirements-dev.txt - name: Code Formatting Check (Black) run: | black --check custom_components/ tests/ - name: Import Sorting Check (isort) run: | isort --check-only --diff custom_components/ tests/ - name: Linting (flake8) run: | flake8 custom_components/ tests/ - name: Type Checking (mypy) run: | mypy custom_components/adguard_hub/ --ignore-missing-imports continue-on-error: true security-scan: name: Security Analysis runs-on: ubuntu-latest steps: - name: Checkout Code uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v5 with: python-version: '3.13' - name: Install Security Tools run: | python -m pip install --upgrade pip pip install bandit safety - name: Security Check (Bandit) run: | bandit -r custom_components/ -ll - name: Dependency Security Check (Safety) run: | pip install -r requirements.txt safety check