{{ message }}
Repository navigation
Reduce duplication across JS bundles by creating one bundle with smaller entry point wrappers - #3899
Merged
Merged
Conversation
mbg
marked this pull request as ready for review
May 14, 2026 14:33
Contributor
There was a problem hiding this comment.
Pull request overview
This PR reworks the esbuild output structure to reduce duplicated bundled code across the action entrypoints by introducing a shared entry-points bundle and small per-action wrapper entry files that call into it.
Changes:
- Introduces
src/entry-points.tsas a shared bundle that imports all action implementations and exposesrun*functions. - Adds new
*-entry.tswrapper entrypoints for each action/post action, and updates eachaction.ymlto reference the new wrapper outputs inlib/. - Updates the build configuration (
build.mjs) to build the new entrypoints and mark./entry-pointsas external for wrapper bundles; updates analyze tests to invokerunWrapper()directly.
Show a summary per file
Copilot's findings
- Files reviewed: 33/55 changed files
- Comments generated: 3
henrymercer
reviewed
May 14, 2026
henrymercer
approved these changes
May 15, 2026
henrymercer
left a comment
Contributor
There was a problem hiding this comment.
I'd like to see a couple of things addressed, but it can be done as followup.
Member
Author
6 of 8 tasks
mbg
added a commit
that referenced
this pull request
May 15, 2026
16 of 18 tasks
pull Bot
pushed a commit
to ftos-forks/codeql-action
that referenced
this pull request
May 15, 2026
Address review comments for github#3899
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Currently, we have a lot of duplication across the JS bundles that esbuild produces for each entry point. This PR fundamentally changes this as follows:
entry-points.js. This avoids significant duplication across the individual bundles, since most of the Action's code is shared among the different actions.entry-pointsand call the relevantrunfunction.entry-pointsas external, so that it is not bundled up with the entry point wrappers.This reduces the size of the compressed repo. I tested the impact of this locally with a fresh, shallow checkout of the repo:
The resulting
.tar.gzfile is around ~2.9M. This is approximately a 70% reduction in archive size.Risk assessment
For internal use only. Please select the risk level of this change:
Which use cases does this change impact?
Workflow types:
dynamicworkflows (Default Setup, Code Quality, ...).Products:
analysis-kinds: code-scanning.analysis-kinds: code-quality.upload-sarifaction.Environments:
github.comand/or GitHub Enterprise Cloud with Data Residency.How did/will you validate this change?
.test.tsfiles).pr-checks).If something goes wrong after this change is released, what are the mitigation and rollback strategies?
How will you know if something goes wrong after this change is released?
Are there any special considerations for merging or releasing this change?
Merge / deployment checklist