Title: improvement(ci): scan CodeQL PRs at the promotion boundary, refresh main daily by waleedlatif1 · Pull Request #7213 · simstudioai/sim · GitHub
Open Graph Title: improvement(ci): scan CodeQL PRs at the promotion boundary, refresh main daily by waleedlatif1 · Pull Request #7213 · simstudioai/sim
X Title: improvement(ci): scan CodeQL PRs at the promotion boundary, refresh main daily by waleedlatif1 · Pull Request #7213 · simstudioai/sim
Description: Summary
CodeQL runs ~3,090 times a month and costs ~$382/mo across both languages. 90 of the last 100 PRs target staging, and every one of those is scanned again — against the exact tree being promoted — when the staging→main PR opens.
PR scans restricted to main. This defers the signal to the promotion boundary rather than dropping it. Verified safe: no ruleset or branch protection requires a CodeQL status check (all four rulesets carry only pull_request/deletion/non_fast_forward), and the code-scanning alert view is fed by the push-to-main and scheduled analyses — PR analyses upload against refs/pull/N/merge and only ever surface as PR annotations.
Deliberately a branch cut, not an activity-type cut. Dropping synchronize would have cut a similar share, but it scans a PR's first commit and never its final state — backwards, since review fixups land in later pushes.
Scheduled scan weekly → daily. Pushes to main are rare, so with PR scans limited to main the alert view leans on the cron more than before. It also reseeds the overlay-base database (see below). Costs a few dollars a month.
Documented a trap in codeql-config.yml: adding queries:/packs:/query-filters: trips OverlayDisabledReason.NonDefaultQueries and permanently disables overlay analysis — trading a documented up-to-10x win for a few percent.
Follow-up, not fixed here
The scan is slow for a reason unrelated to scope: the overlay-base database uploads on every push to main and never restores on a PR run. Observed 4/4 misses against a byte-identical cache key:
Looking in Actions cache for overlay-base database with restore key
codeql-overlay-base-database-1-
Open Graph Description: Summary CodeQL runs ~3,090 times a month and costs ~$382/mo across both languages. 90 of the last 100 PRs target staging, and every one of those is scanned again — against the exact tree being prom...
X Description: Summary CodeQL runs ~3,090 times a month and costs ~$382/mo across both languages. 90 of the last 100 PRs target staging, and every one of those is scanned again — against the exact tree being prom...
Opengraph URL: https://github.com/simstudioai/sim/pull/7213
X: @github
Domain: github.com
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:f8556dd6-1018-b08c-f623-176019cae370 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | E43A:2BF3D1:95F484:D312D7:6AFB72CD |
| html-safe-nonce | 3e44a36b817dacf5dc6f72512ad909e09ee74a69fde5eb0a8acfacc0e8ea6a1f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNDNBOjJCRjNEMTo5NUY0ODQ6RDMxMkQ3OjZBRkI3MkNEIiwidmlzaXRvcl9pZCI6Ijc0NDcyMzExNjg1NzI1MTkxMTciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 63f37b186a3b5b88ed827289bc0499de59b87d54c30353e9e73213031f576320 |
| hovercard-subject-tag | pull_request:4383335123 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/simstudioai/sim/pull/7213/files |
| twitter:image | https://avatars.githubusercontent.com/u/40672544?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/40672544?s=400&v=4 |
| og:image:alt | Summary CodeQL runs ~3,090 times a month and costs ~$382/mo across both languages. 90 of the last 100 PRs target staging, and every one of those is scanned again — against the exact tree being prom... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 0e29e7974fdda2feeaf5c891efd4b23b0734b23480232b62c7bdef13f40b5b48 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/simstudioai/sim git https://github.com/simstudioai/sim.git |
| octolytics-dimension-user_id | 199344406 |
| octolytics-dimension-user_login | simstudioai |
| octolytics-dimension-repository_id | 912559512 |
| octolytics-dimension-repository_nwo | simstudioai/sim |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 912559512 |
| octolytics-dimension-repository_network_root_nwo | simstudioai/sim |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 2e8872b770cc4d5d0cc1f2026afab747a268e2ce |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width