fix(ci): add multi-language CodeQL analysis - #118
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool. What Enabling Code Scanning Means:
For more information about GitHub Code Scanning, check out the documentation. |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Codex review: needs maintainer review before merge. Reviewed August 29, 2026, 12:51 AM ET / 04:51 UTC. ClawSweeper reviewWhat this changesAdds a pinned GitHub CodeQL workflow for Actions, TypeScript, Go, and Swift, with a contract test for triggers, build modes, pins, and checkout permissions. Merge readinessThe prior changelog finding is resolved and no introduced correctness defect is evident. This member-authored CI PR remains necessary because its main-branch base has no CodeQL workflow; wait for the in-progress exact-head Swift and Worker checks before landing. Priority: P3 Review scores
Verification
How this fits togetherGitHub Actions runs repository automation on pull requests, main-branch pushes, schedules, and manual dispatch. This workflow scans the repository’s automation and source languages and uploads results to GitHub code scanning. flowchart LR
A[Pull request or main push] --> B[CodeQL workflow]
C[Weekly or manual trigger] --> B
B --> D[Language-specific analysis]
D --> E[GitHub code scanning results]
E --> F[Maintainer security review]
Before merge
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep the pinned three-job workflow and its contract test, then land after the exact-head Swift and Worker checks succeed. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR adds repository automation rather than repairing a runtime failure. Is this the best way to solve the issue? Yes: a pinned, least-privilege workflow with a focused contract test is a narrow maintainable way to add repository-owned scanning. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against a394179d28e1. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (7 earlier review cycles)
|
bb242be to
e073ca1
Compare
|
@clawsweeper re-review The branch was replayed from current |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
🦞👀 Pull request received. I will update this pull request when review starts. |
What Problem This Solves
Resolves a gap where Crabfleet's GitHub Actions, TypeScript, Go, and Swift code did not share one repository-owned CodeQL workflow with explicit first-party extraction.
Why This Change Was Made
Adds an immutable, least-privilege advanced CodeQL workflow. Actions and JavaScript/TypeScript use buildless analysis, Go uses the repository's
go.modtoolchain with CodeQL autobuild, and Swift uses an arm64 package build with scratch data underRUNNER_TEMP. The workflow runs for pull requests,main, a weekly schedule, and manual runs.The replay is based directly on
a394179d28e1c8d5fffe73ba624f5dd116de435f. It intentionally contains no changelog or runtime changes.User Impact
Maintainers get consistent code-scanning results for all four first-party language categories. There is no runtime, deployment, release, or persistence behavior change.
Evidence
e073ca175ff847bf3e4828ad4e4658e13c47d6fe(signed)actionlint .github/workflows/codeql.ymlnode --test --experimental-strip-types tests/codeql-workflow.test.ts(3 passed)pnpm checkpnpm test(1001 passed)pnpm buildgo test ./...go vet ./...swift build --package-path macos/CrabfleetMac --scratch-path "$RUNNER_TEMP/crabfleet-codeql-swift" --arch arm64pnpm macos:test(RoyalVNCKit 121 passed; CrabfleetMac 294 passed; integration gate 7 passed)git diff --check a394179d28e1c8d5fffe73ba624f5dd116de435f..HEADbf4eefc40562e021a1775bffba4065823290f3ae, with parentsa394179d28e1c8d5fffe73ba624f5dd116de435fande073ca175ff847bf3e4828ad4e4658e13c47d6fe; treeba3f081ab1c730b48ad2970f6fb710e8da3dbf00matches the reviewed head.src/**; Go extracted first-party commands and internals and reported success for its discovered project; Swift compiled the package underRUNNER_TEMPand reported 1,027,896 extracted AST nodes with zero unresolved.e073ca175ff847bf3e4828ad4e4658e13c47d6fe: no findings; its only landing condition was completion of exact-head Swift and Worker checks, which are now green.Action contracts were checked directly at the pinned revisions: checkout v7.0.1 uses
persist-credentials: false; CodeQL v4.37.9 owns autobuild throughinitand does not require a redundant autobuild action; setup-go v7.0.0 readsgo.modand caches fromgo.sum.Before the push, the repository was public, default setup was
not-configured, the default branch remained exactlya394179d28e1c8d5fffe73ba624f5dd116de435f, the PR head remained exactlybb242be0ec25ec8b5078d6e80f52a931d7638cae, and no open CodeQL alerts existed. No alert was dismissed.