Skip to content

Skip overlay memory check for CodeQL 2.24.3 and later#3515

Merged
henrymercer merged 1 commit intomainfrom
henrymercer/drop-ram-limit
Feb 27, 2026
Merged

Skip overlay memory check for CodeQL 2.24.3 and later#3515
henrymercer merged 1 commit intomainfrom
henrymercer/drop-ram-limit

Conversation

@henrymercer
Copy link
Contributor

RAM usage with overlay analysis enabled should generally be no higher than it is without overlay analysis for these versions.

Risk assessment

For internal use only. Please select the risk level of this change:

  • Low risk: Changes are fully under feature flags, or have been fully tested and validated in pre-production environments and are highly observable, or are documentation or test only.

Which use cases does this change impact?

Workflow types:

  • Advanced setup - Impacts users who have custom CodeQL workflows.
  • Managed - Impacts users with dynamic workflows (Default Setup, Code Quality, ...).

Products:

  • Code Scanning - The changes impact analyses when analysis-kinds: code-scanning.

Environments:

  • Dotcom - Impacts CodeQL workflows on github.com and/or GitHub Enterprise Cloud with Data Residency.

How did/will you validate this change?

These changes will be validated as part of the next release process.

If something goes wrong after this change is released, what are the mitigation and rollback strategies?

Disable via broader overlay feature flags, or CodeQL version feature flags.

  • Feature flags - All new or changed code paths can be fully disabled with corresponding feature flags.

How will you know if something goes wrong after this change is released?

  • Telemetry - I rely on existing telemetry or have made changes to the telemetry.
    • Alerts - New or existing monitors will trip if something goes wrong with this change.

Are there any special considerations for merging or releasing this change?

  • No special considerations - This change can be merged at any time.

Merge / deployment checklist

  • Confirm this change is backwards compatible with existing workflows.
  • Consider adding a changelog entry for this change.
  • Confirm the readme and docs have been updated if necessary.

@henrymercer henrymercer requested a review from a team as a code owner February 25, 2026 19:09
@github-actions github-actions bot added the size/S Should be easy to review label Feb 25, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates overlay analysis resource checking so that the minimum-memory gating is skipped for CodeQL CLI versions where overlay no longer increases peak RAM usage (2.24.3+).

Changes:

  • Introduce a CodeQL version threshold (2.24.3) after which overlay’s minimum-memory check is skipped.
  • Refactor overlay resource checks into separate disk-space and memory helpers, with additional debug logging.
  • Add regression tests asserting overlay remains enabled on low-memory settings when CodeQL >= 2.24.3.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/config-utils.ts Skips overlay minimum-memory check for CodeQL >= 2.24.3 and refactors disk/memory resource checks.
src/config-utils.test.ts Adds test cases for the new version-gated memory-check behavior on default branch and PR runs.
lib/init-action.js Generated JS update corresponding to the TypeScript changes (not reviewed).

redsun82
redsun82 previously approved these changes Feb 26, 2026
Copy link
Contributor

@redsun82 redsun82 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

nickrolfe
nickrolfe previously approved these changes Feb 26, 2026
mbg
mbg previously approved these changes Feb 26, 2026
@henrymercer henrymercer force-pushed the henrymercer/overlay-repo-property branch from 03178ce to 4068616 Compare February 26, 2026 15:28
Base automatically changed from henrymercer/overlay-repo-property to main February 26, 2026 16:21
@henrymercer henrymercer dismissed stale reviews from mbg, nickrolfe, and redsun82 February 26, 2026 16:21

The base branch was changed.

@henrymercer henrymercer force-pushed the henrymercer/drop-ram-limit branch from ac5a1b9 to 29765a3 Compare February 26, 2026 16:53
@henrymercer
Copy link
Contributor Author

Rebased on main

@henrymercer henrymercer requested a review from mbg February 26, 2026 16:53
@henrymercer henrymercer added this pull request to the merge queue Feb 26, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 26, 2026
@henrymercer henrymercer added this pull request to the merge queue Feb 26, 2026
github-merge-queue bot pushed a commit that referenced this pull request Feb 26, 2026
Skip overlay memory check for CodeQL 2.24.3 and later
@mbg mbg removed this pull request from the merge queue due to the queue being cleared Feb 26, 2026
@henrymercer henrymercer added this pull request to the merge queue Feb 27, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 27, 2026
@henrymercer henrymercer merged commit adf58cf into main Feb 27, 2026
244 checks passed
@henrymercer henrymercer deleted the henrymercer/drop-ram-limit branch February 27, 2026 11:17
@github-actions github-actions bot mentioned this pull request Feb 27, 2026
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/S Should be easy to review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants