-
Notifications
You must be signed in to change notification settings - Fork 622
Silence CodeQL JavaScript / TypeScript errors [VS-1777] #9304
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds a placeholder JavaScript file to satisfy CodeQL's JavaScript/TypeScript analyzer, which currently fails when no JavaScript/TypeScript code is present in the repository.
- Adds a single JavaScript file containing an explanatory comment as a string literal
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
src/main/resources/placate_codeql.js
Outdated
| const hush = ` | ||
|
|
||
| This file exists solely to prevent CodeQL from failing its "Analyze (javascript-typescript)" action with: | ||
|
|
||
| CodeQL detected code written in Java/Kotlin, Python and GitHub Actions, but not any written in JavaScript/TypeScript. Confirm that there is some source code for JavaScript/TypeScript in the project. | ||
|
|
||
| Because apart from the contents of this file, there is currently no JavaScript or TypeScript in the GATK repo. | ||
|
|
||
| `; |
Copilot
AI
Dec 8, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The variable 'hush' is declared but never used. Consider either using this variable or removing the const declaration and leaving just a comment block, which would better communicate that this file exists only for CodeQL detection purposes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
jonn-smith
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
* CodeQL was enabled on all public Broad repositories. Since this repository contains no JavaScript / TypeScript, CodeQL always fails. Because of this we have to add a workaround here so it does not fail and our checks all come up nice and green.
As currently configured in the GATK repo, CodeQL runs a JavaScript / TypeScript checker action on all PRs. This checker seems to assume that there should always be some JavaScript / TypeScript code to check, and that the absence of any code to check is an error. As of now there is currently no "real" JavaScript or TypeScript code to check, so this checker action always fails (example PR with the same content as current
master).This PR adds a dummy JavaScript file to placate the CodeQL checker.