The issue
Both typescript and javascript-typescript are valid language options accepted by the official GitHub CodeQL analyze action.
However, due to how the upload-database action in this repository is written, using either of these language options causes that action to fail.
The error occurs because the upload-database action in this repo uses inputs.language for the CodeQL database path.
This results in the constructed path looking like codeql_databases/typescript (or codeql_databases/javascript-typescript).
However, when either of these language options are used, the correct path for the databases directory is codeql_databases/javascript.
The upload-database action fails with an error because of this incorrect path being used.
How to fix
To fix this, the upload-database action needs to be updated so that the correct codeql_databases/javascript path is used whenever inputs.language is set to typescript or javascript-typescript.
Additional notes
The project my team works on uses both TypeScript and JavaScript. So we would greatly appreciate if this bug was fixed so we can use the javascript-typescript language option.
I could potentially fork this repo and contribute a fix for this bug myself if y'all are willing to review and merge my PR. 🙂
The issue
Both
typescriptandjavascript-typescriptare valid language options accepted by the official GitHub CodeQL analyze action.However, due to how the
upload-databaseaction in this repository is written, using either of these language options causes that action to fail.The error occurs because the
upload-databaseaction in this repo usesinputs.languagefor the CodeQL database path.This results in the constructed path looking like
codeql_databases/typescript(orcodeql_databases/javascript-typescript).However, when either of these language options are used, the correct path for the databases directory is
codeql_databases/javascript.The
upload-databaseaction fails with an error because of this incorrect path being used.How to fix
To fix this, the
upload-databaseaction needs to be updated so that the correctcodeql_databases/javascriptpath is used wheneverinputs.languageis set totypescriptorjavascript-typescript.Additional notes
The project my team works on uses both TypeScript and JavaScript. So we would greatly appreciate if this bug was fixed so we can use the
javascript-typescriptlanguage option.I could potentially fork this repo and contribute a fix for this bug myself if y'all are willing to review and merge my PR. 🙂