Skip to content

Commit 9a510d9

Browse files
committed
Rename new analysis summary feature flag
1 parent 2160dd3 commit 9a510d9

12 files changed

+28
-28
lines changed

lib/analyze.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/analyze.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/codeql.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/codeql.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/codeql.test.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/codeql.test.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/feature-flags.js

+8-8
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/feature-flags.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/analyze.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ export async function runQueries(
389389
}
390390

391391
if (
392-
!(await features.getValue(Feature.NewAnalysisSummaryEnabled, codeql))
392+
!(await features.getValue(Feature.AnalysisSummaryV2Enabled, codeql))
393393
) {
394394
await runPrintLinesOfCode(language);
395395
}

src/codeql.test.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1137,7 +1137,7 @@ for (const {
11371137
"-v",
11381138
"",
11391139
stubConfig,
1140-
createFeatures(featureEnabled ? [Feature.NewAnalysisSummaryEnabled] : []),
1140+
createFeatures(featureEnabled ? [Feature.AnalysisSummaryV2Enabled] : []),
11411141
getRunnerLogger(true),
11421142
);
11431143
t.is(

src/codeql.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import type { Config } from "./config-utils";
1111
import { EnvVar } from "./environment";
1212
import {
1313
CODEQL_VERSION_INTRA_LAYER_PARALLELISM,
14-
CODEQL_VERSION_NEW_ANALYSIS_SUMMARY,
14+
CODEQL_VERSION_ANALYSIS_SUMMARY_V2,
1515
CodeQLDefaultVersionInfo,
1616
Feature,
1717
FeatureEnablement,
@@ -856,10 +856,10 @@ export async function getCodeQLForCmd(
856856
} else if (await util.codeQlVersionAbove(this, "2.12.4")) {
857857
codeqlArgs.push("--no-sarif-include-diagnostics");
858858
}
859-
if (await features.getValue(Feature.NewAnalysisSummaryEnabled, this)) {
859+
if (await features.getValue(Feature.AnalysisSummaryV2Enabled, this)) {
860860
codeqlArgs.push("--new-analysis-summary");
861861
} else if (
862-
await util.codeQlVersionAbove(this, CODEQL_VERSION_NEW_ANALYSIS_SUMMARY)
862+
await util.codeQlVersionAbove(this, CODEQL_VERSION_ANALYSIS_SUMMARY_V2)
863863
) {
864864
codeqlArgs.push("--no-new-analysis-summary");
865865
}

src/feature-flags.ts

+7-7
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export const CODEQL_VERSION_BUNDLE_SEMANTICALLY_VERSIONED = "2.13.4";
2121
/**
2222
* Versions 2.14.0+ of the CodeQL CLI support new analysis summaries.
2323
*/
24-
export const CODEQL_VERSION_NEW_ANALYSIS_SUMMARY = "2.14.0";
24+
export const CODEQL_VERSION_ANALYSIS_SUMMARY_V2 = "2.14.0";
2525

2626
/**
2727
* Versions 2.14.0+ of the CodeQL CLI support intra-layer parallelism (aka fine-grained parallelism) options.
@@ -48,14 +48,14 @@ export interface FeatureEnablement {
4848
* Each value of this enum should end with `_enabled`.
4949
*/
5050
export enum Feature {
51+
AnalysisSummaryV2Enabled = "analysis_summary_v2_enabled",
5152
CliConfigFileEnabled = "cli_config_file_enabled",
5253
CodeqlJavaLombokEnabled = "codeql_java_lombok_enabled",
5354
DisableKotlinAnalysisEnabled = "disable_kotlin_analysis_enabled",
5455
DisablePythonDependencyInstallationEnabled = "disable_python_dependency_installation_enabled",
5556
EvaluatorIntraLayerParallelismEnabled = "evaluator_intra_layer_parallelism_enabled",
5657
ExportDiagnosticsEnabled = "export_diagnostics_enabled",
5758
MlPoweredQueriesEnabled = "ml_powered_queries_enabled",
58-
NewAnalysisSummaryEnabled = "new_analysis_summary_enabled",
5959
QaTelemetryEnabled = "qa_telemetry_enabled",
6060
ScalingReservedRamEnabled = "scaling_reserved_ram_enabled",
6161
UploadFailedSarifEnabled = "upload_failed_sarif_enabled",
@@ -65,6 +65,11 @@ export const featureConfig: Record<
6565
Feature,
6666
{ envVar: string; minimumVersion: string | undefined; defaultValue: boolean }
6767
> = {
68+
[Feature.AnalysisSummaryV2Enabled]: {
69+
envVar: "CODEQL_ACTION_ANALYSIS_SUMMARY_V2",
70+
minimumVersion: CODEQL_VERSION_ANALYSIS_SUMMARY_V2,
71+
defaultValue: false,
72+
},
6873
[Feature.CodeqlJavaLombokEnabled]: {
6974
envVar: "CODEQL_JAVA_LOMBOK",
7075
minimumVersion: "2.14.0",
@@ -95,11 +100,6 @@ export const featureConfig: Record<
95100
minimumVersion: undefined,
96101
defaultValue: false,
97102
},
98-
[Feature.NewAnalysisSummaryEnabled]: {
99-
envVar: "CODEQL_ACTION_NEW_ANALYSIS_SUMMARY",
100-
minimumVersion: CODEQL_VERSION_NEW_ANALYSIS_SUMMARY,
101-
defaultValue: false,
102-
},
103103
[Feature.QaTelemetryEnabled]: {
104104
envVar: "CODEQL_ACTION_QA_TELEMETRY",
105105
minimumVersion: undefined,

0 commit comments

Comments
 (0)