Skip to content
SkilledDragonEngineering Intelligence
MinilabKeylessOctober 21, 2026

AdvisoryGate makes advisory scan findings block a merge at the severity you pick

AdvisoryGate merges code scanning alerts with shellcheck, hadolint and checkov SARIF into one required PR check. All 8 keyless scenarios hit their expected exit code. The AI-labelled alerts were synthetic.

By David Discua

Measured in the lab

8/8
scenarios at expected exit
21
raw results, alerts + scanners
20
after dedupe
9
blocking at high
alerts+scanners-highexit 19
scanners-only-highexit 17
alerts+scanners-tuned1 ignored5
alerts+scanners-criticalsynthetic alert1
scanners-only-criticalexit 00
  • policy read from the PR base commit, so a PR cannot loosen its own gate
  • committed .shellcheckrc, .hadolint.yaml and .checkov.yaml did not hide the six findings they targeted
  • a required source that cannot run exits 2
  • unknown config keys and invalid severities exit 64
  • Gemini labels are applied after the verdict and never change it

From reports/advisorygate.json · run on October 21, 2026. Bun 1.4.3, shellcheck 0.11.0, hadolint 2.15.1, checkov 3.3.30 on darwin-x64; 4 changed files; alerts replayed from fixtures, the AI-labelled ones synthetic

How it is wired

diffpr=NSARIFalertsverdictPull request4 changed filesScannersshellcheck, hadolintAlerts APIoptional sourceAdvisoryGatededupe + verdictRequired checkexit 0, 1 or 2

01/04A pull request changes four files.

GitHub's AI Scan for pull requests became generally available on October 15, 2026, and its findings are advisory. Per GitHub's changelog they cannot fail the code scanning check or block a merge through rulesets. AdvisoryGate is one required check that merges code scanning alerts for a PR with fresh SARIF from shellcheck, hadolint and checkov, dedupes them, and fails only on the severities the repo owner lists in .advisorygate.yml. We ran it keyless over eight scenarios, and every one ended with the exit code we expected. The catch is that GitHub does not document whether AI Scan findings come back through the alerts API at all, so the AI-labelled alerts in our run are synthetic.

The catch

AdvisoryGate reads alerts from GET /repos/{o}/{r}/code-scanning/alerts?pr=N. The changelog, the docs page and the REST reference never say that AI Scan findings show up there, and the alerts endpoints have no AI-specific field or filter. We could not test it either. Every repo this lab can read has AI Scan turned off (pr_scan: disabled), and turning it on would change repo settings. The alert fixture with the AI tool name is hand-built from the documented schema and marked "synthetic": true. The 403 and 404 fixtures are real api.github.com responses captured on October 21, 2026.

If the API never returns AI Scan findings, the gate still covers CodeQL, any uploaded SARIF and the three scanners. Dedupe is exact, so checkov CKV_AWS_24 and an AI alert about the same open SSH port stay as two findings. checkov 3.3.30 offline reports every failed check as SARIF error with no severity, which the default level map turns into high. The optional Gemini labelling path was not run in this lab. The reusable workflow and composite action have not run on GitHub yet.

What we ran (keyless)

bun install --frozen-lockfile
bun run tools
bun run advisorygate run --root fixtures/pr-repo --config fixtures/config/high.yml \
  --changed-files fixtures/pr-repo.changed-files.txt \
  --alerts-replay fixtures/alerts/synthetic-pr-alerts.json --out-dir out
bun run report

From reports/advisorygate.json, run on October 21, 2026 with the real pinned scanners over 4 changed files:

ScenarioConfigRawAfter dedupeBlockingExit
scanners-only-highhigh.yml161671
alerts+scanners-highhigh.yml212091
scanners-only-criticalcritical-only.yml161600
alerts+scanners-criticalcritical-only.yml212011
alerts+scanners-tunedtuned.yml212051
alerts+scanners-advisoryadvisory.yml212000
recorded-404-no-analysishigh.yml161671
recorded-403-requiredalerts-required.yml161672

The one duplicate merged in the alert runs is ShellCheck SC2045 at scripts/deploy.sh:5, reported both by code scanning and by the local shellcheck run. With critical-only.yml, the scanners alone pass, and adding alerts fails the check on one critical synthetic alert for SSH open to 0.0.0.0/0 at infra/main.tf:8. In the last row the policy marks the alerts API as required and the replayed 403 makes the gate exit 2. The local bun run check passed 57 tests across 7 files.

How it is wired

The action and reusable workflow read the policy from the PR base commit, so a PR cannot loosen its own gate. Scanners run from an empty temp directory with shellcheck --norc and hadolint --config <empty> --disable-ignore-pragma. An e2e test commits repo config that would hide six findings and asserts all six still appear. Severity comes from SARIF security-severity using GitHub's bands, then a level map, then per-rule overrides. The verdict is computed before any Gemini label is attached. Outputs are merged SARIF, JSON and a Markdown job summary.

Minilab (open source)

AdvisoryGate drives three upstream tools: koalaman/shellcheck (40,228 stars, GPL-3.0, Haskell), hadolint/hadolint (12,490 stars, GPL-3.0, Haskell) and bridgecrewio/checkov (9,098 stars, Apache-2.0, Python), all as of October 24, 2026. Run bun run report and compare reports/advisorygate.md with the table above. The README shows the same CLI on a real checkout, with --base origin/main, --repo and --pr, plus the reusable workflow to make it a required check.

Run it yourself

SkilledDragonCorp/advisorygate

Clone, install and run the report with no API keys. The numbers above are what that run writes.

bun install --frozen-lockfile && bun run tools && bun run report

SkilledDragon is not affiliated with GitHub, Google, Prisma Cloud, or the ShellCheck, Hadolint and Checkov projects. Numbers are from our own keyless lab run; re-run the report before relying on them. Marks belong to their owners.

All labs