8000 Merge main into releases/v2 by github-actions[bot] · Pull Request #1514 · github/codeql-action · GitHub
[go: up one dir, main page]

Skip to content

Merge main into releases/v2 #1514

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

Merged
merged 5 commits into from
Jan 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CodeQL Action Changelog

## 2.2.1 - 27 Jan 2023

No user facing changes.

## 2.2.0 - 26 Jan 2023

- Improve stability when choosing the default version of CodeQL to use in code scanning workflow runs on Actions on GitHub.com. [#1475](https://github.com/github/codeql-action/pull/1475)
Expand Down
12 changes: 6 additions & 6 deletions lib/codeql.test.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/codeql.test.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion lib/setup-codeql.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/setup-codeql.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion node_modules/.package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "codeql",
"version": "2.2.0",
"version": "2.2.1",
"private": true,
"description": "CodeQL action",
"scripts": {
Expand Down
12 changes: 6 additions & 6 deletions src/codeql.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ test("downloads and caches explicitly requested bundles that aren't in the toolc
t.assert(toolcache.find("CodeQL", `0.0.0-${version}`));
t.is(result.toolsVersion, `0.0.0-${version}`);
t.is(result.toolsSource, ToolsSource.Download);
t.is(typeof result.toolsDownloadDurationMs, "number");
t.assert(Number.isInteger(result.toolsDownloadDurationMs));
}

t.is(toolcache.findAllVersions("CodeQL").length, 2);
Expand Down Expand Up @@ -241,7 +241,7 @@ test("downloads an explicitly requested bundle even if a different version is ca
t.assert(toolcache.find("CodeQL", "0.0.0-20200610"));
t.deepEqual(result.toolsVersion, "0.0.0-20200610");
t.is(result.toolsSource, ToolsSource.Download);
t.not(result.toolsDownloadDurationMs, undefined);
t.assert(Number.isInteger(result.toolsDownloadDurationMs));
});
});

Expand Down Expand Up @@ -293,7 +293,7 @@ for (const {
t.assert(toolcache.find("CodeQL", expectedToolcacheVersion));
t.deepEqual(result.toolsVersion, cliVersion);
t.is(result.toolsSource, ToolsSource.Download);
t.not(result.toolsDownloadDurationMs, undefined);
t.assert(Number.isInteger(result.toolsDownloadDurationMs));
});
});
}
Expand Down Expand Up @@ -428,7 +428,7 @@ for (const variant of [util.GitHubVariant.GHAE, util.GitHubVariant.GHES]) {
);
t.deepEqual(result.toolsVersion, defaults.cliVersion);
t.is(result.toolsSource, ToolsSource.Download);
t.is(typeof result.toolsDownloadDurationMs, "number");
t.assert(Number.isInteger(result.toolsDownloadDurationMs));

const cachedVersions = toolcache.findAllVersions("CodeQL");
t.is(cachedVersions.length, 2);
Expand Down Expand Up @@ -461,7 +461,7 @@ test('downloads bundle if "latest" tools specified but not cached', async (t) =>
);
t.deepEqual(result.toolsVersion, defaults.cliVersion);
t.is(result.toolsSource, ToolsSource.Download);
t.is(typeof result.toolsDownloadDurationMs, "number");
t.assert(Number.isInteger(result.toolsDownloadDurationMs));

const cachedVersions = toolcache.findAllVersions("CodeQL");
t.is(cachedVersions.length, 2);
Expand Down Expand Up @@ -527,7 +527,7 @@ test("download codeql bundle from github ae endpoint", async (t) => {
);

t.is(result.toolsSource, ToolsSource.Download);
t.is(typeof result.toolsDownloadDurationMs, "number");
t.assert(Number.isInteger(result.toolsDownloadDurationMs));

const cachedVersions = toolcache.findAllVersions("CodeQL");
t.is(cachedVersions.length, 1);
Expand Down
4 changes: 3 additions & 1 deletion src/setup-codeql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,9 @@ export async function downloadCodeQL(
undefined,
finalHeaders
);
const toolsDownloadDurationMs = performance.now() - toolsDownloadStart;
const toolsDownloadDurationMs = Math.round(
performance.now() - toolsDownloadStart
);

logger.debug(`CodeQL bundle download to ${codeqlPath} complete.`);

Expand Down
0