diff --git a/lib/init-action.js b/lib/init-action.js index 2f509ad0ee..c7419b09a3 100644 --- a/lib/init-action.js +++ b/lib/init-action.js @@ -87860,7 +87860,13 @@ async function getOverlayDatabaseMode(codeql, repository, features, languages, s return nonOverlayAnalysis; } if (buildMode !== "none" /* None */ && (await Promise.all( - languages.map(async (l) => await codeql.isTracedLanguage(l)) + languages.map( + async (l) => l !== "go" /* go */ && // Workaround to allow overlay analysis for Go with any build + // mode, since it does not yet support BMN. The Go autobuilder and/or extractor will + // ensure that overlay-base databases are only created for supported Go build setups, + // and that we'll fall back to full databases in other cases. + await codeql.isTracedLanguage(l) + ) )).some(Boolean)) { logger.warning( `Cannot build an ${overlayDatabaseMode} database because build-mode is set to "${buildMode}" instead of "none". Falling back to creating a normal full database instead.` diff --git a/src/config-utils.ts b/src/config-utils.ts index fe4b392ab2..e6c87bf5a6 100644 --- a/src/config-utils.ts +++ b/src/config-utils.ts @@ -723,7 +723,14 @@ export async function getOverlayDatabaseMode( buildMode !== BuildMode.None && ( await Promise.all( - languages.map(async (l) => await codeql.isTracedLanguage(l)), + languages.map( + async (l) => + l !== KnownLanguage.go && // Workaround to allow overlay analysis for Go with any build + // mode, since it does not yet support BMN. The Go autobuilder and/or extractor will + // ensure that overlay-base databases are only created for supported Go build setups, + // and that we'll fall back to full databases in other cases. + (await codeql.isTracedLanguage(l)), + ), ) ).some(Boolean) ) {