tests: instead of false, use old feature flag with default value of false
This commit is contained in:
parent
e6dd4048e9
commit
5445a29a97
30 changed files with 118 additions and 40 deletions
8
lib/tools-download.js
generated
8
lib/tools-download.js
generated
|
|
@ -30,6 +30,7 @@ const perf_hooks_1 = require("perf_hooks");
|
|||
const toolcache = __importStar(require("@actions/tool-cache"));
|
||||
const follow_redirects_1 = require("follow-redirects");
|
||||
const uuid_1 = require("uuid");
|
||||
const feature_flags_1 = require("./feature-flags");
|
||||
const logging_1 = require("./logging");
|
||||
const tar = __importStar(require("./tar"));
|
||||
const util_1 = require("./util");
|
||||
|
|
@ -53,12 +54,13 @@ function makeStreamedToolsDownloadDurations(combinedDurationMs) {
|
|||
streamExtraction: true,
|
||||
};
|
||||
}
|
||||
async function downloadAndExtract(codeqlURL, authorization, headers, tarVersion, tempDir, logger) {
|
||||
async function downloadAndExtract(codeqlURL, authorization, headers, tarVersion, tempDir, features, logger) {
|
||||
logger.info(`Downloading CodeQL tools from ${codeqlURL} . This may take a while.`);
|
||||
const compressionMethod = tar.inferCompressionMethod(codeqlURL);
|
||||
// TODO: Re-enable streaming when we have a more reliable way to respect proxy settings.
|
||||
// eslint-disable-next-line no-constant-condition, no-constant-binary-expression
|
||||
if (false && compressionMethod === "zstd" && process.platform === "linux") {
|
||||
if ((await features.getValue(feature_flags_1.Feature.ZstdBundleStreamingExtraction)) &&
|
||||
compressionMethod === "zstd" &&
|
||||
process.platform === "linux") {
|
||||
logger.info(`Streaming the extraction of the CodeQL bundle.`);
|
||||
const toolsInstallStart = perf_hooks_1.performance.now();
|
||||
const extractedBundlePath = await downloadAndExtractZstdWithStreaming(codeqlURL, authorization, headers, tarVersion, logger);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue