mirror of
https://github.com/github/codeql-action.git
synced 2025-12-06 07:48:17 +08:00
Reorder components of overlay-base cache key postfix
This commit is contained in:
2
lib/analyze-action.js
generated
2
lib/analyze-action.js
generated
@@ -91082,7 +91082,7 @@ async function getCacheSaveKey(config, codeQlVersion, checkoutPath) {
|
||||
config,
|
||||
codeQlVersion
|
||||
);
|
||||
return `${restoreKeyPrefix}${runId}-${attemptId}-${sha}`;
|
||||
return `${restoreKeyPrefix}${sha}-${runId}-${attemptId}`;
|
||||
}
|
||||
async function getCacheRestoreKeyPrefix(config, codeQlVersion) {
|
||||
const languages = [...config.languages].sort().join("_");
|
||||
|
||||
@@ -276,7 +276,7 @@ test("overlay-base database cache keys remain stable", async (t) => {
|
||||
|
||||
const saveKey = await getCacheSaveKey(config, codeQlVersion, "checkout-path");
|
||||
const expectedSaveKey =
|
||||
"codeql-overlay-base-database-1-c5666c509a2d9895-javascript_python-2.23.0-12345-1-abc123def456";
|
||||
"codeql-overlay-base-database-1-c5666c509a2d9895-javascript_python-2.23.0-abc123def456-12345-1";
|
||||
t.is(
|
||||
saveKey,
|
||||
expectedSaveKey,
|
||||
|
||||
@@ -465,7 +465,7 @@ export async function getCacheSaveKey(
|
||||
config,
|
||||
codeQlVersion,
|
||||
);
|
||||
return `${restoreKeyPrefix}${runId}-${attemptId}-${sha}`;
|
||||
return `${restoreKeyPrefix}${sha}-${runId}-${attemptId}`;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user