mirror of
https://github.com/github/codeql-action.git
synced 2026-04-27 01:08:46 +00:00
Merge branch 'main' into henrymercer/http-error-handling
This commit is contained in:
Generated
+1326
-20
File diff suppressed because it is too large
Load Diff
Generated
+1321
-1312
File diff suppressed because it is too large
Load Diff
Generated
+1319
-13
File diff suppressed because it is too large
Load Diff
Generated
+1328
-1319
File diff suppressed because it is too large
Load Diff
Generated
+1538
-26
File diff suppressed because it is too large
Load Diff
Generated
+1319
-13
File diff suppressed because it is too large
Load Diff
Generated
+1310
-4
File diff suppressed because it is too large
Load Diff
Generated
+1326
-20
File diff suppressed because it is too large
Load Diff
Generated
+1316
-13
File diff suppressed because it is too large
Load Diff
Generated
+37
-28
@@ -20885,19 +20885,19 @@ var require_validator = __commonJS({
|
||||
var SchemaError = helpers.SchemaError;
|
||||
var SchemaContext = helpers.SchemaContext;
|
||||
var anonymousBase = "/";
|
||||
var Validator2 = function Validator3() {
|
||||
this.customFormats = Object.create(Validator3.prototype.customFormats);
|
||||
var Validator3 = function Validator4() {
|
||||
this.customFormats = Object.create(Validator4.prototype.customFormats);
|
||||
this.schemas = {};
|
||||
this.unresolvedRefs = [];
|
||||
this.types = Object.create(types);
|
||||
this.attributes = Object.create(attribute.validators);
|
||||
};
|
||||
Validator2.prototype.customFormats = {};
|
||||
Validator2.prototype.schemas = null;
|
||||
Validator2.prototype.types = null;
|
||||
Validator2.prototype.attributes = null;
|
||||
Validator2.prototype.unresolvedRefs = null;
|
||||
Validator2.prototype.addSchema = function addSchema(schema2, base) {
|
||||
Validator3.prototype.customFormats = {};
|
||||
Validator3.prototype.schemas = null;
|
||||
Validator3.prototype.types = null;
|
||||
Validator3.prototype.attributes = null;
|
||||
Validator3.prototype.unresolvedRefs = null;
|
||||
Validator3.prototype.addSchema = function addSchema(schema2, base) {
|
||||
var self2 = this;
|
||||
if (!schema2) {
|
||||
return null;
|
||||
@@ -20915,25 +20915,25 @@ var require_validator = __commonJS({
|
||||
});
|
||||
return this.schemas[ourUri];
|
||||
};
|
||||
Validator2.prototype.addSubSchemaArray = function addSubSchemaArray(baseuri, schemas) {
|
||||
Validator3.prototype.addSubSchemaArray = function addSubSchemaArray(baseuri, schemas) {
|
||||
if (!Array.isArray(schemas)) return;
|
||||
for (var i = 0; i < schemas.length; i++) {
|
||||
this.addSubSchema(baseuri, schemas[i]);
|
||||
}
|
||||
};
|
||||
Validator2.prototype.addSubSchemaObject = function addSubSchemaArray(baseuri, schemas) {
|
||||
Validator3.prototype.addSubSchemaObject = function addSubSchemaArray(baseuri, schemas) {
|
||||
if (!schemas || typeof schemas != "object") return;
|
||||
for (var p in schemas) {
|
||||
this.addSubSchema(baseuri, schemas[p]);
|
||||
}
|
||||
};
|
||||
Validator2.prototype.setSchemas = function setSchemas(schemas) {
|
||||
Validator3.prototype.setSchemas = function setSchemas(schemas) {
|
||||
this.schemas = schemas;
|
||||
};
|
||||
Validator2.prototype.getSchema = function getSchema(urn) {
|
||||
Validator3.prototype.getSchema = function getSchema(urn) {
|
||||
return this.schemas[urn];
|
||||
};
|
||||
Validator2.prototype.validate = function validate(instance, schema2, options, ctx) {
|
||||
Validator3.prototype.validate = function validate(instance, schema2, options, ctx) {
|
||||
if (typeof schema2 !== "boolean" && typeof schema2 !== "object" || schema2 === null) {
|
||||
throw new SchemaError("Expected `schema` to be an object or boolean");
|
||||
}
|
||||
@@ -20971,7 +20971,7 @@ var require_validator = __commonJS({
|
||||
if (typeof ref == "string") return ref;
|
||||
return false;
|
||||
}
|
||||
Validator2.prototype.validateSchema = function validateSchema(instance, schema2, options, ctx) {
|
||||
Validator3.prototype.validateSchema = function validateSchema(instance, schema2, options, ctx) {
|
||||
var result = new ValidatorResult(instance, schema2, options, ctx);
|
||||
if (typeof schema2 === "boolean") {
|
||||
if (schema2 === true) {
|
||||
@@ -21021,17 +21021,17 @@ var require_validator = __commonJS({
|
||||
}
|
||||
return result;
|
||||
};
|
||||
Validator2.prototype.schemaTraverser = function schemaTraverser(schemaobj, s) {
|
||||
Validator3.prototype.schemaTraverser = function schemaTraverser(schemaobj, s) {
|
||||
schemaobj.schema = helpers.deepMerge(schemaobj.schema, this.superResolve(s, schemaobj.ctx));
|
||||
};
|
||||
Validator2.prototype.superResolve = function superResolve(schema2, ctx) {
|
||||
Validator3.prototype.superResolve = function superResolve(schema2, ctx) {
|
||||
var ref = shouldResolve(schema2);
|
||||
if (ref) {
|
||||
return this.resolve(schema2, ref, ctx).subschema;
|
||||
}
|
||||
return schema2;
|
||||
};
|
||||
Validator2.prototype.resolve = function resolve6(schema2, switchSchema, ctx) {
|
||||
Validator3.prototype.resolve = function resolve6(schema2, switchSchema, ctx) {
|
||||
switchSchema = ctx.resolve(switchSchema);
|
||||
if (ctx.schemas[switchSchema]) {
|
||||
return { subschema: ctx.schemas[switchSchema], switchSchema };
|
||||
@@ -21048,7 +21048,7 @@ var require_validator = __commonJS({
|
||||
}
|
||||
return { subschema, switchSchema };
|
||||
};
|
||||
Validator2.prototype.testType = function validateType(instance, schema2, options, ctx, type2) {
|
||||
Validator3.prototype.testType = function validateType(instance, schema2, options, ctx, type2) {
|
||||
if (type2 === void 0) {
|
||||
return;
|
||||
} else if (type2 === null) {
|
||||
@@ -21063,7 +21063,7 @@ var require_validator = __commonJS({
|
||||
}
|
||||
return true;
|
||||
};
|
||||
var types = Validator2.prototype.types = {};
|
||||
var types = Validator3.prototype.types = {};
|
||||
types.string = function testString(instance) {
|
||||
return typeof instance == "string";
|
||||
};
|
||||
@@ -21091,7 +21091,7 @@ var require_validator = __commonJS({
|
||||
types.object = function testObject(instance) {
|
||||
return instance && typeof instance === "object" && !Array.isArray(instance) && !(instance instanceof Date);
|
||||
};
|
||||
module2.exports = Validator2;
|
||||
module2.exports = Validator3;
|
||||
}
|
||||
});
|
||||
|
||||
@@ -21099,7 +21099,7 @@ var require_validator = __commonJS({
|
||||
var require_lib2 = __commonJS({
|
||||
"node_modules/jsonschema/lib/index.js"(exports2, module2) {
|
||||
"use strict";
|
||||
var Validator2 = module2.exports.Validator = require_validator();
|
||||
var Validator3 = module2.exports.Validator = require_validator();
|
||||
module2.exports.ValidatorResult = require_helpers().ValidatorResult;
|
||||
module2.exports.ValidatorResultError = require_helpers().ValidatorResultError;
|
||||
module2.exports.ValidationError = require_helpers().ValidationError;
|
||||
@@ -21107,7 +21107,7 @@ var require_lib2 = __commonJS({
|
||||
module2.exports.SchemaScanResult = require_scan().SchemaScanResult;
|
||||
module2.exports.scan = require_scan().scan;
|
||||
module2.exports.validate = function(instance, schema2, options) {
|
||||
var v = new Validator2();
|
||||
var v = new Validator3();
|
||||
return v.validate(instance, schema2, options);
|
||||
};
|
||||
}
|
||||
@@ -33654,7 +33654,7 @@ var require_package = __commonJS({
|
||||
jsonschema: "1.4.1",
|
||||
long: "^5.3.2",
|
||||
"node-forge": "^1.3.1",
|
||||
octokit: "^5.0.3",
|
||||
octokit: "^5.0.4",
|
||||
semver: "^7.7.3",
|
||||
uuid: "^13.0.0"
|
||||
},
|
||||
@@ -33662,7 +33662,7 @@ var require_package = __commonJS({
|
||||
"@ava/typescript": "6.0.0",
|
||||
"@eslint/compat": "^1.4.0",
|
||||
"@eslint/eslintrc": "^3.3.1",
|
||||
"@eslint/js": "^9.37.0",
|
||||
"@eslint/js": "^9.38.0",
|
||||
"@microsoft/eslint-formatter-sarif": "^3.1.0",
|
||||
"@octokit/types": "^15.0.0",
|
||||
"@types/archiver": "^6.0.3",
|
||||
@@ -33673,10 +33673,10 @@ var require_package = __commonJS({
|
||||
"@types/node-forge": "^1.3.14",
|
||||
"@types/semver": "^7.7.1",
|
||||
"@types/sinon": "^17.0.4",
|
||||
"@typescript-eslint/eslint-plugin": "^8.46.0",
|
||||
"@typescript-eslint/eslint-plugin": "^8.46.1",
|
||||
"@typescript-eslint/parser": "^8.41.0",
|
||||
ava: "^6.4.1",
|
||||
esbuild: "^0.25.10",
|
||||
esbuild: "^0.25.11",
|
||||
eslint: "^8.57.1",
|
||||
"eslint-import-resolver-typescript": "^3.8.7",
|
||||
"eslint-plugin-filenames": "^1.3.2",
|
||||
@@ -84865,7 +84865,7 @@ var path14 = __toESM(require("path"));
|
||||
var url = __toESM(require("url"));
|
||||
var import_zlib = __toESM(require("zlib"));
|
||||
var core11 = __toESM(require_core());
|
||||
var jsonschema = __toESM(require_lib2());
|
||||
var jsonschema2 = __toESM(require_lib2());
|
||||
|
||||
// src/actions-util.ts
|
||||
var fs4 = __toESM(require("fs"));
|
||||
@@ -88957,6 +88957,9 @@ var cliErrorsConfig = {
|
||||
cliErrorMessageCandidates: [
|
||||
new RegExp(
|
||||
"Query pack .* cannot be found\\. Check the spelling of the pack\\."
|
||||
),
|
||||
new RegExp(
|
||||
"is not a .ql file, .qls file, a directory, or a query pack specification."
|
||||
)
|
||||
]
|
||||
},
|
||||
@@ -89035,6 +89038,7 @@ var path9 = __toESM(require("path"));
|
||||
var core6 = __toESM(require_core());
|
||||
|
||||
// src/config/db-config.ts
|
||||
var jsonschema = __toESM(require_lib2());
|
||||
var semver2 = __toESM(require_semver2());
|
||||
var PACK_IDENTIFIER_PATTERN = (function() {
|
||||
const alphaNumeric = "[a-z0-9]";
|
||||
@@ -89516,6 +89520,11 @@ var featureConfig = {
|
||||
defaultValue: false,
|
||||
envVar: "CODEQL_ACTION_JAVA_MINIMIZE_DEPENDENCY_JARS",
|
||||
minimumVersion: "2.23.0"
|
||||
},
|
||||
["validate_db_config" /* ValidateDbConfig */]: {
|
||||
defaultValue: false,
|
||||
envVar: "CODEQL_ACTION_VALIDATE_DB_CONFIG",
|
||||
minimumVersion: void 0
|
||||
}
|
||||
};
|
||||
|
||||
@@ -92638,7 +92647,7 @@ function validateSarifFileSchema(sarif, sarifFilePath, logger) {
|
||||
}
|
||||
logger.info(`Validating ${sarifFilePath}`);
|
||||
const schema2 = require_sarif_schema_2_1_0();
|
||||
const result = new jsonschema.Validator().validate(sarif, schema2);
|
||||
const result = new jsonschema2.Validator().validate(sarif, schema2);
|
||||
const warningAttributes = ["uri-reference", "uri"];
|
||||
const errors = (result.errors ?? []).filter(
|
||||
(err) => !(err.name === "format" && typeof err.argument === "string" && warningAttributes.includes(err.argument))
|
||||
|
||||
Generated
+1310
-4
File diff suppressed because it is too large
Load Diff
Generated
+37
-28
@@ -32357,7 +32357,7 @@ var require_package = __commonJS({
|
||||
jsonschema: "1.4.1",
|
||||
long: "^5.3.2",
|
||||
"node-forge": "^1.3.1",
|
||||
octokit: "^5.0.3",
|
||||
octokit: "^5.0.4",
|
||||
semver: "^7.7.3",
|
||||
uuid: "^13.0.0"
|
||||
},
|
||||
@@ -32365,7 +32365,7 @@ var require_package = __commonJS({
|
||||
"@ava/typescript": "6.0.0",
|
||||
"@eslint/compat": "^1.4.0",
|
||||
"@eslint/eslintrc": "^3.3.1",
|
||||
"@eslint/js": "^9.37.0",
|
||||
"@eslint/js": "^9.38.0",
|
||||
"@microsoft/eslint-formatter-sarif": "^3.1.0",
|
||||
"@octokit/types": "^15.0.0",
|
||||
"@types/archiver": "^6.0.3",
|
||||
@@ -32376,10 +32376,10 @@ var require_package = __commonJS({
|
||||
"@types/node-forge": "^1.3.14",
|
||||
"@types/semver": "^7.7.1",
|
||||
"@types/sinon": "^17.0.4",
|
||||
"@typescript-eslint/eslint-plugin": "^8.46.0",
|
||||
"@typescript-eslint/eslint-plugin": "^8.46.1",
|
||||
"@typescript-eslint/parser": "^8.41.0",
|
||||
ava: "^6.4.1",
|
||||
esbuild: "^0.25.10",
|
||||
esbuild: "^0.25.11",
|
||||
eslint: "^8.57.1",
|
||||
"eslint-import-resolver-typescript": "^3.8.7",
|
||||
"eslint-plugin-filenames": "^1.3.2",
|
||||
@@ -80374,19 +80374,19 @@ var require_validator2 = __commonJS({
|
||||
var SchemaError = helpers.SchemaError;
|
||||
var SchemaContext = helpers.SchemaContext;
|
||||
var anonymousBase = "/";
|
||||
var Validator2 = function Validator3() {
|
||||
this.customFormats = Object.create(Validator3.prototype.customFormats);
|
||||
var Validator3 = function Validator4() {
|
||||
this.customFormats = Object.create(Validator4.prototype.customFormats);
|
||||
this.schemas = {};
|
||||
this.unresolvedRefs = [];
|
||||
this.types = Object.create(types);
|
||||
this.attributes = Object.create(attribute.validators);
|
||||
};
|
||||
Validator2.prototype.customFormats = {};
|
||||
Validator2.prototype.schemas = null;
|
||||
Validator2.prototype.types = null;
|
||||
Validator2.prototype.attributes = null;
|
||||
Validator2.prototype.unresolvedRefs = null;
|
||||
Validator2.prototype.addSchema = function addSchema(schema2, base) {
|
||||
Validator3.prototype.customFormats = {};
|
||||
Validator3.prototype.schemas = null;
|
||||
Validator3.prototype.types = null;
|
||||
Validator3.prototype.attributes = null;
|
||||
Validator3.prototype.unresolvedRefs = null;
|
||||
Validator3.prototype.addSchema = function addSchema(schema2, base) {
|
||||
var self2 = this;
|
||||
if (!schema2) {
|
||||
return null;
|
||||
@@ -80404,25 +80404,25 @@ var require_validator2 = __commonJS({
|
||||
});
|
||||
return this.schemas[ourUri];
|
||||
};
|
||||
Validator2.prototype.addSubSchemaArray = function addSubSchemaArray(baseuri, schemas) {
|
||||
Validator3.prototype.addSubSchemaArray = function addSubSchemaArray(baseuri, schemas) {
|
||||
if (!Array.isArray(schemas)) return;
|
||||
for (var i = 0; i < schemas.length; i++) {
|
||||
this.addSubSchema(baseuri, schemas[i]);
|
||||
}
|
||||
};
|
||||
Validator2.prototype.addSubSchemaObject = function addSubSchemaArray(baseuri, schemas) {
|
||||
Validator3.prototype.addSubSchemaObject = function addSubSchemaArray(baseuri, schemas) {
|
||||
if (!schemas || typeof schemas != "object") return;
|
||||
for (var p in schemas) {
|
||||
this.addSubSchema(baseuri, schemas[p]);
|
||||
}
|
||||
};
|
||||
Validator2.prototype.setSchemas = function setSchemas(schemas) {
|
||||
Validator3.prototype.setSchemas = function setSchemas(schemas) {
|
||||
this.schemas = schemas;
|
||||
};
|
||||
Validator2.prototype.getSchema = function getSchema(urn) {
|
||||
Validator3.prototype.getSchema = function getSchema(urn) {
|
||||
return this.schemas[urn];
|
||||
};
|
||||
Validator2.prototype.validate = function validate(instance, schema2, options, ctx) {
|
||||
Validator3.prototype.validate = function validate(instance, schema2, options, ctx) {
|
||||
if (typeof schema2 !== "boolean" && typeof schema2 !== "object" || schema2 === null) {
|
||||
throw new SchemaError("Expected `schema` to be an object or boolean");
|
||||
}
|
||||
@@ -80460,7 +80460,7 @@ var require_validator2 = __commonJS({
|
||||
if (typeof ref == "string") return ref;
|
||||
return false;
|
||||
}
|
||||
Validator2.prototype.validateSchema = function validateSchema(instance, schema2, options, ctx) {
|
||||
Validator3.prototype.validateSchema = function validateSchema(instance, schema2, options, ctx) {
|
||||
var result = new ValidatorResult(instance, schema2, options, ctx);
|
||||
if (typeof schema2 === "boolean") {
|
||||
if (schema2 === true) {
|
||||
@@ -80510,17 +80510,17 @@ var require_validator2 = __commonJS({
|
||||
}
|
||||
return result;
|
||||
};
|
||||
Validator2.prototype.schemaTraverser = function schemaTraverser(schemaobj, s) {
|
||||
Validator3.prototype.schemaTraverser = function schemaTraverser(schemaobj, s) {
|
||||
schemaobj.schema = helpers.deepMerge(schemaobj.schema, this.superResolve(s, schemaobj.ctx));
|
||||
};
|
||||
Validator2.prototype.superResolve = function superResolve(schema2, ctx) {
|
||||
Validator3.prototype.superResolve = function superResolve(schema2, ctx) {
|
||||
var ref = shouldResolve(schema2);
|
||||
if (ref) {
|
||||
return this.resolve(schema2, ref, ctx).subschema;
|
||||
}
|
||||
return schema2;
|
||||
};
|
||||
Validator2.prototype.resolve = function resolve6(schema2, switchSchema, ctx) {
|
||||
Validator3.prototype.resolve = function resolve6(schema2, switchSchema, ctx) {
|
||||
switchSchema = ctx.resolve(switchSchema);
|
||||
if (ctx.schemas[switchSchema]) {
|
||||
return { subschema: ctx.schemas[switchSchema], switchSchema };
|
||||
@@ -80537,7 +80537,7 @@ var require_validator2 = __commonJS({
|
||||
}
|
||||
return { subschema, switchSchema };
|
||||
};
|
||||
Validator2.prototype.testType = function validateType(instance, schema2, options, ctx, type2) {
|
||||
Validator3.prototype.testType = function validateType(instance, schema2, options, ctx, type2) {
|
||||
if (type2 === void 0) {
|
||||
return;
|
||||
} else if (type2 === null) {
|
||||
@@ -80552,7 +80552,7 @@ var require_validator2 = __commonJS({
|
||||
}
|
||||
return true;
|
||||
};
|
||||
var types = Validator2.prototype.types = {};
|
||||
var types = Validator3.prototype.types = {};
|
||||
types.string = function testString(instance) {
|
||||
return typeof instance == "string";
|
||||
};
|
||||
@@ -80580,7 +80580,7 @@ var require_validator2 = __commonJS({
|
||||
types.object = function testObject(instance) {
|
||||
return instance && typeof instance === "object" && !Array.isArray(instance) && !(instance instanceof Date);
|
||||
};
|
||||
module2.exports = Validator2;
|
||||
module2.exports = Validator3;
|
||||
}
|
||||
});
|
||||
|
||||
@@ -80588,7 +80588,7 @@ var require_validator2 = __commonJS({
|
||||
var require_lib2 = __commonJS({
|
||||
"node_modules/jsonschema/lib/index.js"(exports2, module2) {
|
||||
"use strict";
|
||||
var Validator2 = module2.exports.Validator = require_validator2();
|
||||
var Validator3 = module2.exports.Validator = require_validator2();
|
||||
module2.exports.ValidatorResult = require_helpers3().ValidatorResult;
|
||||
module2.exports.ValidatorResultError = require_helpers3().ValidatorResultError;
|
||||
module2.exports.ValidationError = require_helpers3().ValidationError;
|
||||
@@ -80596,7 +80596,7 @@ var require_lib2 = __commonJS({
|
||||
module2.exports.SchemaScanResult = require_scan2().SchemaScanResult;
|
||||
module2.exports.scan = require_scan2().scan;
|
||||
module2.exports.validate = function(instance, schema2, options) {
|
||||
var v = new Validator2();
|
||||
var v = new Validator3();
|
||||
return v.validate(instance, schema2, options);
|
||||
};
|
||||
}
|
||||
@@ -89471,6 +89471,11 @@ var featureConfig = {
|
||||
defaultValue: false,
|
||||
envVar: "CODEQL_ACTION_JAVA_MINIMIZE_DEPENDENCY_JARS",
|
||||
minimumVersion: "2.23.0"
|
||||
},
|
||||
["validate_db_config" /* ValidateDbConfig */]: {
|
||||
defaultValue: false,
|
||||
envVar: "CODEQL_ACTION_VALIDATE_DB_CONFIG",
|
||||
minimumVersion: void 0
|
||||
}
|
||||
};
|
||||
var FEATURE_FLAGS_FILE_NAME = "cached-feature-flags.json";
|
||||
@@ -89751,6 +89756,7 @@ var path10 = __toESM(require("path"));
|
||||
var core8 = __toESM(require_core());
|
||||
|
||||
// src/config/db-config.ts
|
||||
var jsonschema = __toESM(require_lib2());
|
||||
var semver4 = __toESM(require_semver2());
|
||||
var PACK_IDENTIFIER_PATTERN = (function() {
|
||||
const alphaNumeric = "[a-z0-9]";
|
||||
@@ -90036,7 +90042,7 @@ var path15 = __toESM(require("path"));
|
||||
var url = __toESM(require("url"));
|
||||
var import_zlib = __toESM(require("zlib"));
|
||||
var core12 = __toESM(require_core());
|
||||
var jsonschema = __toESM(require_lib2());
|
||||
var jsonschema2 = __toESM(require_lib2());
|
||||
|
||||
// src/codeql.ts
|
||||
var fs12 = __toESM(require("fs"));
|
||||
@@ -90211,6 +90217,9 @@ var cliErrorsConfig = {
|
||||
cliErrorMessageCandidates: [
|
||||
new RegExp(
|
||||
"Query pack .* cannot be found\\. Check the spelling of the pack\\."
|
||||
),
|
||||
new RegExp(
|
||||
"is not a .ql file, .qls file, a directory, or a query pack specification."
|
||||
)
|
||||
]
|
||||
},
|
||||
@@ -93294,7 +93303,7 @@ function validateSarifFileSchema(sarif, sarifFilePath, logger) {
|
||||
}
|
||||
logger.info(`Validating ${sarifFilePath}`);
|
||||
const schema2 = require_sarif_schema_2_1_0();
|
||||
const result = new jsonschema.Validator().validate(sarif, schema2);
|
||||
const result = new jsonschema2.Validator().validate(sarif, schema2);
|
||||
const warningAttributes = ["uri-reference", "uri"];
|
||||
const errors = (result.errors ?? []).filter(
|
||||
(err) => !(err.name === "format" && typeof err.argument === "string" && warningAttributes.includes(err.argument))
|
||||
|
||||
Reference in New Issue
Block a user