From 8428d6da6ddbfdc1b27334fbd00c4c79b7e86f39 Mon Sep 17 00:00:00 2001 From: "Emma [it/its]@Rory&" Date: Tue, 29 Oct 2024 20:59:02 +0100 Subject: [PATCH] Run npm update, remove erlpack from package list --- flake.nix | 3 + hashes.json | 2 +- package-lock.json | Bin 381615 -> 381229 bytes package.json | 89 ++-- patches/ajv+8.17.1.patch | 892 +++++++++++++++++++++++++++++++++++++++ patches/ajv+8.6.2.patch | 249 ----------- 6 files changed, 940 insertions(+), 295 deletions(-) create mode 100644 patches/ajv+8.17.1.patch delete mode 100644 patches/ajv+8.6.2.patch diff --git a/flake.nix b/flake.nix index 5915e754..25251c02 100644 --- a/flake.nix +++ b/flake.nix @@ -88,6 +88,9 @@ buildInputs = with pkgs; [ nodejs nodePackages.typescript + nodePackages.ts-node + nodePackages.patch-package + nodePackages.prettier ]; }; } diff --git a/hashes.json b/hashes.json index 574d7295..952016d6 100644 --- a/hashes.json +++ b/hashes.json @@ -1,3 +1,3 @@ { - "npmDepsHash": "sha256-7fRfkqcmoaXtERi+XoPQnxhioMslTxm9PFD7C/5ZGZQ=" + "npmDepsHash": "sha256-iSz+FMfcmTj0STZOooftm0xFGia3Jq23/pzEeXqfbMg=" } diff --git a/package-lock.json b/package-lock.json index b62e96ce7bbefd4d9b1a3a19684e0be178d26946..61c5edc58c112f39b90dbe34fc88f87779f9f689 100644 GIT binary patch delta 14121 zcmc(Gd$8l?b>HAV_Mu%#yQ|ec^jxjpqI5wJ1OeERyaf0JNDw3e5};&R#Df6%06+o+ zN%$eHUyUU>S_!R@X<}P)lg6o?Sn|f*B$HUO<2vzui?q`1KdI?4fiT=Yr7{a1&?7JPT^#AtV5&xH;**p^euV03)jk5di zgviL)f6GSBDT`ef7*X`4MC#6+JEQ4^yNkQ z&w|I{1N*K*F7G$yKL?$>YPDA&z!nz0;{dsaq~aHU54th_^efPj=t~C}2#=owirGjl z!AKnZ?ay9y3c3;90t(ySjW-@zzK*WG1?XZczU?EMH(%rr{oocL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fv`p<`q(6XJ_P zj!*kl(cq-W#l5A%>mkdf+=V=pq_XTppvW;_4iqA^d&%pc0;~RwhqmrIkUa2ryO89# zv2`eU=bJ%b9hTd)FsLHwF-A}$Zd5b*YL+y3yWe9at^}9tG9VCTZfP1rtqPA@?8NGl z%htF!jA+@kJhf3#aD0*iGnLvwrb)M%2($yQy>Q;x%4Cv1-L<(tId>MA)c2m>xF)Ip zw~gyA-1#rJe(L1QC1>ZD parsingError(cxt, (0, codegen_1.str) `invalid timestamp`)); + break; + } ++ case "bigint": ++ parseBigInt(cxt); ++ break + case "float32": + case "float64": + parseNumber(cxt); +@@ -284,6 +287,15 @@ function parseNumber(cxt, maxDigits) { + skipWhitespace(cxt); + gen.if((0, codegen_1._) `"-0123456789".indexOf(${jsonSlice(1)}) < 0`, () => jsonSyntaxError(cxt), () => parseWith(cxt, parseJson_1.parseJsonNumber, maxDigits)); + } ++function parseBigInt(cxt, maxDigits) { ++ const {gen} = cxt ++ skipWhitespace(cxt) ++ gen.if( ++ _`"-0123456789".indexOf(${jsonSlice(1)}) < 0`, ++ () => jsonSyntaxError(cxt), ++ () => parseWith(cxt, parseJson_1.parseJsonBigInt, maxDigits) ++ ) ++} + function parseBooleanToken(bool, fail) { + return (cxt) => { + const { gen, data } = cxt; +diff --git a/node_modules/ajv/dist/compile/jtd/parse.js.orig b/node_modules/ajv/dist/compile/jtd/parse.js.orig +new file mode 100644 +index 0000000..8fc94fd +--- /dev/null ++++ b/node_modules/ajv/dist/compile/jtd/parse.js.orig +@@ -0,0 +1,350 @@ ++"use strict"; ++Object.defineProperty(exports, "__esModule", { value: true }); ++const types_1 = require("./types"); ++const __1 = require(".."); ++const codegen_1 = require("../codegen"); ++const ref_error_1 = require("../ref_error"); ++const names_1 = require("../names"); ++const code_1 = require("../../vocabularies/code"); ++const ref_1 = require("../../vocabularies/jtd/ref"); ++const type_1 = require("../../vocabularies/jtd/type"); ++const parseJson_1 = require("../../runtime/parseJson"); ++const util_1 = require("../util"); ++const timestamp_1 = require("../../runtime/timestamp"); ++const genParse = { ++ elements: parseElements, ++ values: parseValues, ++ discriminator: parseDiscriminator, ++ properties: parseProperties, ++ optionalProperties: parseProperties, ++ enum: parseEnum, ++ type: parseType, ++ ref: parseRef, ++}; ++function compileParser(sch, definitions) { ++ const _sch = __1.getCompilingSchema.call(this, sch); ++ if (_sch) ++ return _sch; ++ const { es5, lines } = this.opts.code; ++ const { ownProperties } = this.opts; ++ const gen = new codegen_1.CodeGen(this.scope, { es5, lines, ownProperties }); ++ const parseName = gen.scopeName("parse"); ++ const cxt = { ++ self: this, ++ gen, ++ schema: sch.schema, ++ schemaEnv: sch, ++ definitions, ++ data: names_1.default.data, ++ parseName, ++ char: gen.name("c"), ++ }; ++ let sourceCode; ++ try { ++ this._compilations.add(sch); ++ sch.parseName = parseName; ++ parserFunction(cxt); ++ gen.optimize(this.opts.code.optimize); ++ const parseFuncCode = gen.toString(); ++ sourceCode = `${gen.scopeRefs(names_1.default.scope)}return ${parseFuncCode}`; ++ const makeParse = new Function(`${names_1.default.scope}`, sourceCode); ++ const parse = makeParse(this.scope.get()); ++ this.scope.value(parseName, { ref: parse }); ++ sch.parse = parse; ++ } ++ catch (e) { ++ if (sourceCode) ++ this.logger.error("Error compiling parser, function code:", sourceCode); ++ delete sch.parse; ++ delete sch.parseName; ++ throw e; ++ } ++ finally { ++ this._compilations.delete(sch); ++ } ++ return sch; ++} ++exports.default = compileParser; ++const undef = (0, codegen_1._) `undefined`; ++function parserFunction(cxt) { ++ const { gen, parseName, char } = cxt; ++ gen.func(parseName, (0, codegen_1._) `${names_1.default.json}, ${names_1.default.jsonPos}, ${names_1.default.jsonPart}`, false, () => { ++ gen.let(names_1.default.data); ++ gen.let(char); ++ gen.assign((0, codegen_1._) `${parseName}.message`, undef); ++ gen.assign((0, codegen_1._) `${parseName}.position`, undef); ++ gen.assign(names_1.default.jsonPos, (0, codegen_1._) `${names_1.default.jsonPos} || 0`); ++ gen.const(names_1.default.jsonLen, (0, codegen_1._) `${names_1.default.json}.length`); ++ parseCode(cxt); ++ skipWhitespace(cxt); ++ gen.if(names_1.default.jsonPart, () => { ++ gen.assign((0, codegen_1._) `${parseName}.position`, names_1.default.jsonPos); ++ gen.return(names_1.default.data); ++ }); ++ gen.if((0, codegen_1._) `${names_1.default.jsonPos} === ${names_1.default.jsonLen}`, () => gen.return(names_1.default.data)); ++ jsonSyntaxError(cxt); ++ }); ++} ++function parseCode(cxt) { ++ let form; ++ for (const key of types_1.jtdForms) { ++ if (key in cxt.schema) { ++ form = key; ++ break; ++ } ++ } ++ if (form) ++ parseNullable(cxt, genParse[form]); ++ else ++ parseEmpty(cxt); ++} ++const parseBoolean = parseBooleanToken(true, parseBooleanToken(false, jsonSyntaxError)); ++function parseNullable(cxt, parseForm) { ++ const { gen, schema, data } = cxt; ++ if (!schema.nullable) ++ return parseForm(cxt); ++ tryParseToken(cxt, "null", parseForm, () => gen.assign(data, null)); ++} ++function parseElements(cxt) { ++ const { gen, schema, data } = cxt; ++ parseToken(cxt, "["); ++ const ix = gen.let("i", 0); ++ gen.assign(data, (0, codegen_1._) `[]`); ++ parseItems(cxt, "]", () => { ++ const el = gen.let("el"); ++ parseCode({ ...cxt, schema: schema.elements, data: el }); ++ gen.assign((0, codegen_1._) `${data}[${ix}++]`, el); ++ }); ++} ++function parseValues(cxt) { ++ const { gen, schema, data } = cxt; ++ parseToken(cxt, "{"); ++ gen.assign(data, (0, codegen_1._) `{}`); ++ parseItems(cxt, "}", () => parseKeyValue(cxt, schema.values)); ++} ++function parseItems(cxt, endToken, block) { ++ tryParseItems(cxt, endToken, block); ++ parseToken(cxt, endToken); ++} ++function tryParseItems(cxt, endToken, block) { ++ const { gen } = cxt; ++ gen.for((0, codegen_1._) `;${names_1.default.jsonPos}<${names_1.default.jsonLen} && ${jsonSlice(1)}!==${endToken};`, () => { ++ block(); ++ tryParseToken(cxt, ",", () => gen.break(), hasItem); ++ }); ++ function hasItem() { ++ tryParseToken(cxt, endToken, () => { }, jsonSyntaxError); ++ } ++} ++function parseKeyValue(cxt, schema) { ++ const { gen } = cxt; ++ const key = gen.let("key"); ++ parseString({ ...cxt, data: key }); ++ parseToken(cxt, ":"); ++ parsePropertyValue(cxt, key, schema); ++} ++function parseDiscriminator(cxt) { ++ const { gen, data, schema } = cxt; ++ const { discriminator, mapping } = schema; ++ parseToken(cxt, "{"); ++ gen.assign(data, (0, codegen_1._) `{}`); ++ const startPos = gen.const("pos", names_1.default.jsonPos); ++ const value = gen.let("value"); ++ const tag = gen.let("tag"); ++ tryParseItems(cxt, "}", () => { ++ const key = gen.let("key"); ++ parseString({ ...cxt, data: key }); ++ parseToken(cxt, ":"); ++ gen.if((0, codegen_1._) `${key} === ${discriminator}`, () => { ++ parseString({ ...cxt, data: tag }); ++ gen.assign((0, codegen_1._) `${data}[${key}]`, tag); ++ gen.break(); ++ }, () => parseEmpty({ ...cxt, data: value }) // can be discarded/skipped ++ ); ++ }); ++ gen.assign(names_1.default.jsonPos, startPos); ++ gen.if((0, codegen_1._) `${tag} === undefined`); ++ parsingError(cxt, (0, codegen_1.str) `discriminator tag not found`); ++ for (const tagValue in mapping) { ++ gen.elseIf((0, codegen_1._) `${tag} === ${tagValue}`); ++ parseSchemaProperties({ ...cxt, schema: mapping[tagValue] }, discriminator); ++ } ++ gen.else(); ++ parsingError(cxt, (0, codegen_1.str) `discriminator value not in schema`); ++ gen.endIf(); ++} ++function parseProperties(cxt) { ++ const { gen, data } = cxt; ++ parseToken(cxt, "{"); ++ gen.assign(data, (0, codegen_1._) `{}`); ++ parseSchemaProperties(cxt); ++} ++function parseSchemaProperties(cxt, discriminator) { ++ const { gen, schema, data } = cxt; ++ const { properties, optionalProperties, additionalProperties } = schema; ++ parseItems(cxt, "}", () => { ++ const key = gen.let("key"); ++ parseString({ ...cxt, data: key }); ++ parseToken(cxt, ":"); ++ gen.if(false); ++ parseDefinedProperty(cxt, key, properties); ++ parseDefinedProperty(cxt, key, optionalProperties); ++ if (discriminator) { ++ gen.elseIf((0, codegen_1._) `${key} === ${discriminator}`); ++ const tag = gen.let("tag"); ++ parseString({ ...cxt, data: tag }); // can be discarded, it is already assigned ++ } ++ gen.else(); ++ if (additionalProperties) { ++ parseEmpty({ ...cxt, data: (0, codegen_1._) `${data}[${key}]` }); ++ } ++ else { ++ parsingError(cxt, (0, codegen_1.str) `property ${key} not allowed`); ++ } ++ gen.endIf(); ++ }); ++ if (properties) { ++ const hasProp = (0, code_1.hasPropFunc)(gen); ++ const allProps = (0, codegen_1.and)(...Object.keys(properties).map((p) => (0, codegen_1._) `${hasProp}.call(${data}, ${p})`)); ++ gen.if((0, codegen_1.not)(allProps), () => parsingError(cxt, (0, codegen_1.str) `missing required properties`)); ++ } ++} ++function parseDefinedProperty(cxt, key, schemas = {}) { ++ const { gen } = cxt; ++ for (const prop in schemas) { ++ gen.elseIf((0, codegen_1._) `${key} === ${prop}`); ++ parsePropertyValue(cxt, key, schemas[prop]); ++ } ++} ++function parsePropertyValue(cxt, key, schema) { ++ parseCode({ ...cxt, schema, data: (0, codegen_1._) `${cxt.data}[${key}]` }); ++} ++function parseType(cxt) { ++ const { gen, schema, data, self } = cxt; ++ switch (schema.type) { ++ case "boolean": ++ parseBoolean(cxt); ++ break; ++ case "string": ++ parseString(cxt); ++ break; ++ case "timestamp": { ++ parseString(cxt); ++ const vts = (0, util_1.useFunc)(gen, timestamp_1.default); ++ const { allowDate, parseDate } = self.opts; ++ const notValid = allowDate ? (0, codegen_1._) `!${vts}(${data}, true)` : (0, codegen_1._) `!${vts}(${data})`; ++ const fail = parseDate ++ ? (0, codegen_1.or)(notValid, (0, codegen_1._) `(${data} = new Date(${data}), false)`, (0, codegen_1._) `isNaN(${data}.valueOf())`) ++ : notValid; ++ gen.if(fail, () => parsingError(cxt, (0, codegen_1.str) `invalid timestamp`)); ++ break; ++ } ++ case "float32": ++ case "float64": ++ parseNumber(cxt); ++ break; ++ default: { ++ const t = schema.type; ++ if (!self.opts.int32range && (t === "int32" || t === "uint32")) { ++ parseNumber(cxt, 16); // 2 ** 53 - max safe integer ++ if (t === "uint32") { ++ gen.if((0, codegen_1._) `${data} < 0`, () => parsingError(cxt, (0, codegen_1.str) `integer out of range`)); ++ } ++ } ++ else { ++ const [min, max, maxDigits] = type_1.intRange[t]; ++ parseNumber(cxt, maxDigits); ++ gen.if((0, codegen_1._) `${data} < ${min} || ${data} > ${max}`, () => parsingError(cxt, (0, codegen_1.str) `integer out of range`)); ++ } ++ } ++ } ++} ++function parseString(cxt) { ++ parseToken(cxt, '"'); ++ parseWith(cxt, parseJson_1.parseJsonString); ++} ++function parseEnum(cxt) { ++ const { gen, data, schema } = cxt; ++ const enumSch = schema.enum; ++ parseToken(cxt, '"'); ++ // TODO loopEnum ++ gen.if(false); ++ for (const value of enumSch) { ++ const valueStr = JSON.stringify(value).slice(1); // remove starting quote ++ gen.elseIf((0, codegen_1._) `${jsonSlice(valueStr.length)} === ${valueStr}`); ++ gen.assign(data, (0, codegen_1.str) `${value}`); ++ gen.add(names_1.default.jsonPos, valueStr.length); ++ } ++ gen.else(); ++ jsonSyntaxError(cxt); ++ gen.endIf(); ++} ++function parseNumber(cxt, maxDigits) { ++ const { gen } = cxt; ++ skipWhitespace(cxt); ++ gen.if((0, codegen_1._) `"-0123456789".indexOf(${jsonSlice(1)}) < 0`, () => jsonSyntaxError(cxt), () => parseWith(cxt, parseJson_1.parseJsonNumber, maxDigits)); ++} ++function parseBooleanToken(bool, fail) { ++ return (cxt) => { ++ const { gen, data } = cxt; ++ tryParseToken(cxt, `${bool}`, () => fail(cxt), () => gen.assign(data, bool)); ++ }; ++} ++function parseRef(cxt) { ++ const { gen, self, definitions, schema, schemaEnv } = cxt; ++ const { ref } = schema; ++ const refSchema = definitions[ref]; ++ if (!refSchema) ++ throw new ref_error_1.default(self.opts.uriResolver, "", ref, `No definition ${ref}`); ++ if (!(0, ref_1.hasRef)(refSchema)) ++ return parseCode({ ...cxt, schema: refSchema }); ++ const { root } = schemaEnv; ++ const sch = compileParser.call(self, new __1.SchemaEnv({ schema: refSchema, root }), definitions); ++ partialParse(cxt, getParser(gen, sch), true); ++} ++function getParser(gen, sch) { ++ return sch.parse ++ ? gen.scopeValue("parse", { ref: sch.parse }) ++ : (0, codegen_1._) `${gen.scopeValue("wrapper", { ref: sch })}.parse`; ++} ++function parseEmpty(cxt) { ++ parseWith(cxt, parseJson_1.parseJson); ++} ++function parseWith(cxt, parseFunc, args) { ++ partialParse(cxt, (0, util_1.useFunc)(cxt.gen, parseFunc), args); ++} ++function partialParse(cxt, parseFunc, args) { ++ const { gen, data } = cxt; ++ gen.assign(data, (0, codegen_1._) `${parseFunc}(${names_1.default.json}, ${names_1.default.jsonPos}${args ? (0, codegen_1._) `, ${args}` : codegen_1.nil})`); ++ gen.assign(names_1.default.jsonPos, (0, codegen_1._) `${parseFunc}.position`); ++ gen.if((0, codegen_1._) `${data} === undefined`, () => parsingError(cxt, (0, codegen_1._) `${parseFunc}.message`)); ++} ++function parseToken(cxt, tok) { ++ tryParseToken(cxt, tok, jsonSyntaxError); ++} ++function tryParseToken(cxt, tok, fail, success) { ++ const { gen } = cxt; ++ const n = tok.length; ++ skipWhitespace(cxt); ++ gen.if((0, codegen_1._) `${jsonSlice(n)} === ${tok}`, () => { ++ gen.add(names_1.default.jsonPos, n); ++ success === null || success === void 0 ? void 0 : success(cxt); ++ }, () => fail(cxt)); ++} ++function skipWhitespace({ gen, char: c }) { ++ gen.code((0, codegen_1._) `while((${c}=${names_1.default.json}[${names_1.default.jsonPos}],${c}===" "||${c}==="\\n"||${c}==="\\r"||${c}==="\\t"))${names_1.default.jsonPos}++;`); ++} ++function jsonSlice(len) { ++ return len === 1 ++ ? (0, codegen_1._) `${names_1.default.json}[${names_1.default.jsonPos}]` ++ : (0, codegen_1._) `${names_1.default.json}.slice(${names_1.default.jsonPos}, ${names_1.default.jsonPos}+${len})`; ++} ++function jsonSyntaxError(cxt) { ++ parsingError(cxt, (0, codegen_1._) `"unexpected token " + ${names_1.default.json}[${names_1.default.jsonPos}]`); ++} ++function parsingError({ gen, parseName }, msg) { ++ gen.assign((0, codegen_1._) `${parseName}.message`, msg); ++ gen.assign((0, codegen_1._) `${parseName}.position`, names_1.default.jsonPos); ++ gen.return(undef); ++} ++//# sourceMappingURL=parse.js.map +\ No newline at end of file +diff --git a/node_modules/ajv/dist/compile/rules.js b/node_modules/ajv/dist/compile/rules.js +index 82a591f..1ebd8fe 100644 +--- a/node_modules/ajv/dist/compile/rules.js ++++ b/node_modules/ajv/dist/compile/rules.js +@@ -1,7 +1,7 @@ + "use strict"; + Object.defineProperty(exports, "__esModule", { value: true }); + exports.getRules = exports.isJSONType = void 0; +-const _jsonTypes = ["string", "number", "integer", "boolean", "null", "object", "array"]; ++const _jsonTypes = ["string", "number", "integer", "boolean", "null", "object", "array","bigint"]; + const jsonTypes = new Set(_jsonTypes); + function isJSONType(x) { + return typeof x == "string" && jsonTypes.has(x); +@@ -13,10 +13,11 @@ function getRules() { + string: { type: "string", rules: [] }, + array: { type: "array", rules: [] }, + object: { type: "object", rules: [] }, ++ bigint: {type: "bigint", rules: []} + }; + return { +- types: { ...groups, integer: true, boolean: true, null: true }, +- rules: [{ rules: [] }, groups.number, groups.string, groups.array, groups.object], ++ types: { ...groups, integer: true, boolean: true, null: true, bigint: true }, ++ rules: [{ rules: [] }, groups.number, groups.string, groups.array, groups.object, groups.bigint], + post: { rules: [] }, + all: {}, + keywords: {}, +diff --git a/node_modules/ajv/dist/compile/validate/dataType.js b/node_modules/ajv/dist/compile/validate/dataType.js +index 6d03e0d..a35a428 100644 +--- a/node_modules/ajv/dist/compile/validate/dataType.js ++++ b/node_modules/ajv/dist/compile/validate/dataType.js +@@ -53,7 +53,7 @@ function coerceAndCheckDataType(it, types) { + return checkTypes; + } + exports.coerceAndCheckDataType = coerceAndCheckDataType; +-const COERCIBLE = new Set(["string", "number", "integer", "boolean", "null"]); ++const COERCIBLE = new Set(["string", "number", "integer", "boolean", "null","bigint"]); + function coerceToTypes(types, coerceTypes) { + return coerceTypes + ? types.filter((t) => COERCIBLE.has(t) || (coerceTypes === "array" && t === "array")) +@@ -84,6 +84,14 @@ function coerceData(it, types, coerceTo) { + }); + function coerceSpecificType(t) { + switch (t) { ++ case "bigint": ++ gen ++ .elseIf( ++ codegen_1._`${dataType} == "boolean" || ${data} === null ++ || (${dataType} == "string" && ${data} && ${data} == BigInt(${data}))` ++ ) ++ .assign(coerced, codegen_1._`BigInt(${data})`) ++ return + case "string": + gen + .elseIf((0, codegen_1._) `${dataType} == "number" || ${dataType} == "boolean"`) +@@ -144,6 +152,9 @@ function checkDataType(dataType, data, strictNums, correct = DataType.Correct) { + case "number": + cond = numCond(); + break; ++ case "bigint": ++ cond = codegen_1._`typeof ${data} == "bigint" && isFinite(${data})` ++ break + default: + return (0, codegen_1._) `typeof ${data} ${EQ} ${dataType}`; + } +diff --git a/node_modules/ajv/dist/compile/validate/dataType.js.orig b/node_modules/ajv/dist/compile/validate/dataType.js.orig +new file mode 100644 +index 0000000..6d03e0d +--- /dev/null ++++ b/node_modules/ajv/dist/compile/validate/dataType.js.orig +@@ -0,0 +1,203 @@ ++"use strict"; ++Object.defineProperty(exports, "__esModule", { value: true }); ++exports.reportTypeError = exports.checkDataTypes = exports.checkDataType = exports.coerceAndCheckDataType = exports.getJSONTypes = exports.getSchemaTypes = exports.DataType = void 0; ++const rules_1 = require("../rules"); ++const applicability_1 = require("./applicability"); ++const errors_1 = require("../errors"); ++const codegen_1 = require("../codegen"); ++const util_1 = require("../util"); ++var DataType; ++(function (DataType) { ++ DataType[DataType["Correct"] = 0] = "Correct"; ++ DataType[DataType["Wrong"] = 1] = "Wrong"; ++})(DataType || (exports.DataType = DataType = {})); ++function getSchemaTypes(schema) { ++ const types = getJSONTypes(schema.type); ++ const hasNull = types.includes("null"); ++ if (hasNull) { ++ if (schema.nullable === false) ++ throw new Error("type: null contradicts nullable: false"); ++ } ++ else { ++ if (!types.length && schema.nullable !== undefined) { ++ throw new Error('"nullable" cannot be used without "type"'); ++ } ++ if (schema.nullable === true) ++ types.push("null"); ++ } ++ return types; ++} ++exports.getSchemaTypes = getSchemaTypes; ++// eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents ++function getJSONTypes(ts) { ++ const types = Array.isArray(ts) ? ts : ts ? [ts] : []; ++ if (types.every(rules_1.isJSONType)) ++ return types; ++ throw new Error("type must be JSONType or JSONType[]: " + types.join(",")); ++} ++exports.getJSONTypes = getJSONTypes; ++function coerceAndCheckDataType(it, types) { ++ const { gen, data, opts } = it; ++ const coerceTo = coerceToTypes(types, opts.coerceTypes); ++ const checkTypes = types.length > 0 && ++ !(coerceTo.length === 0 && types.length === 1 && (0, applicability_1.schemaHasRulesForType)(it, types[0])); ++ if (checkTypes) { ++ const wrongType = checkDataTypes(types, data, opts.strictNumbers, DataType.Wrong); ++ gen.if(wrongType, () => { ++ if (coerceTo.length) ++ coerceData(it, types, coerceTo); ++ else ++ reportTypeError(it); ++ }); ++ } ++ return checkTypes; ++} ++exports.coerceAndCheckDataType = coerceAndCheckDataType; ++const COERCIBLE = new Set(["string", "number", "integer", "boolean", "null"]); ++function coerceToTypes(types, coerceTypes) { ++ return coerceTypes ++ ? types.filter((t) => COERCIBLE.has(t) || (coerceTypes === "array" && t === "array")) ++ : []; ++} ++function coerceData(it, types, coerceTo) { ++ const { gen, data, opts } = it; ++ const dataType = gen.let("dataType", (0, codegen_1._) `typeof ${data}`); ++ const coerced = gen.let("coerced", (0, codegen_1._) `undefined`); ++ if (opts.coerceTypes === "array") { ++ gen.if((0, codegen_1._) `${dataType} == 'object' && Array.isArray(${data}) && ${data}.length == 1`, () => gen ++ .assign(data, (0, codegen_1._) `${data}[0]`) ++ .assign(dataType, (0, codegen_1._) `typeof ${data}`) ++ .if(checkDataTypes(types, data, opts.strictNumbers), () => gen.assign(coerced, data))); ++ } ++ gen.if((0, codegen_1._) `${coerced} !== undefined`); ++ for (const t of coerceTo) { ++ if (COERCIBLE.has(t) || (t === "array" && opts.coerceTypes === "array")) { ++ coerceSpecificType(t); ++ } ++ } ++ gen.else(); ++ reportTypeError(it); ++ gen.endIf(); ++ gen.if((0, codegen_1._) `${coerced} !== undefined`, () => { ++ gen.assign(data, coerced); ++ assignParentData(it, coerced); ++ }); ++ function coerceSpecificType(t) { ++ switch (t) { ++ case "string": ++ gen ++ .elseIf((0, codegen_1._) `${dataType} == "number" || ${dataType} == "boolean"`) ++ .assign(coerced, (0, codegen_1._) `"" + ${data}`) ++ .elseIf((0, codegen_1._) `${data} === null`) ++ .assign(coerced, (0, codegen_1._) `""`); ++ return; ++ case "number": ++ gen ++ .elseIf((0, codegen_1._) `${dataType} == "boolean" || ${data} === null ++ || (${dataType} == "string" && ${data} && ${data} == +${data})`) ++ .assign(coerced, (0, codegen_1._) `+${data}`); ++ return; ++ case "integer": ++ gen ++ .elseIf((0, codegen_1._) `${dataType} === "boolean" || ${data} === null ++ || (${dataType} === "string" && ${data} && ${data} == +${data} && !(${data} % 1))`) ++ .assign(coerced, (0, codegen_1._) `+${data}`); ++ return; ++ case "boolean": ++ gen ++ .elseIf((0, codegen_1._) `${data} === "false" || ${data} === 0 || ${data} === null`) ++ .assign(coerced, false) ++ .elseIf((0, codegen_1._) `${data} === "true" || ${data} === 1`) ++ .assign(coerced, true); ++ return; ++ case "null": ++ gen.elseIf((0, codegen_1._) `${data} === "" || ${data} === 0 || ${data} === false`); ++ gen.assign(coerced, null); ++ return; ++ case "array": ++ gen ++ .elseIf((0, codegen_1._) `${dataType} === "string" || ${dataType} === "number" ++ || ${dataType} === "boolean" || ${data} === null`) ++ .assign(coerced, (0, codegen_1._) `[${data}]`); ++ } ++ } ++} ++function assignParentData({ gen, parentData, parentDataProperty }, expr) { ++ // TODO use gen.property ++ gen.if((0, codegen_1._) `${parentData} !== undefined`, () => gen.assign((0, codegen_1._) `${parentData}[${parentDataProperty}]`, expr)); ++} ++function checkDataType(dataType, data, strictNums, correct = DataType.Correct) { ++ const EQ = correct === DataType.Correct ? codegen_1.operators.EQ : codegen_1.operators.NEQ; ++ let cond; ++ switch (dataType) { ++ case "null": ++ return (0, codegen_1._) `${data} ${EQ} null`; ++ case "array": ++ cond = (0, codegen_1._) `Array.isArray(${data})`; ++ break; ++ case "object": ++ cond = (0, codegen_1._) `${data} && typeof ${data} == "object" && !Array.isArray(${data})`; ++ break; ++ case "integer": ++ cond = numCond((0, codegen_1._) `!(${data} % 1) && !isNaN(${data})`); ++ break; ++ case "number": ++ cond = numCond(); ++ break; ++ default: ++ return (0, codegen_1._) `typeof ${data} ${EQ} ${dataType}`; ++ } ++ return correct === DataType.Correct ? cond : (0, codegen_1.not)(cond); ++ function numCond(_cond = codegen_1.nil) { ++ return (0, codegen_1.and)((0, codegen_1._) `typeof ${data} == "number"`, _cond, strictNums ? (0, codegen_1._) `isFinite(${data})` : codegen_1.nil); ++ } ++} ++exports.checkDataType = checkDataType; ++function checkDataTypes(dataTypes, data, strictNums, correct) { ++ if (dataTypes.length === 1) { ++ return checkDataType(dataTypes[0], data, strictNums, correct); ++ } ++ let cond; ++ const types = (0, util_1.toHash)(dataTypes); ++ if (types.array && types.object) { ++ const notObj = (0, codegen_1._) `typeof ${data} != "object"`; ++ cond = types.null ? notObj : (0, codegen_1._) `!${data} || ${notObj}`; ++ delete types.null; ++ delete types.array; ++ delete types.object; ++ } ++ else { ++ cond = codegen_1.nil; ++ } ++ if (types.number) ++ delete types.integer; ++ for (const t in types) ++ cond = (0, codegen_1.and)(cond, checkDataType(t, data, strictNums, correct)); ++ return cond; ++} ++exports.checkDataTypes = checkDataTypes; ++const typeError = { ++ message: ({ schema }) => `must be ${schema}`, ++ params: ({ schema, schemaValue }) => typeof schema == "string" ? (0, codegen_1._) `{type: ${schema}}` : (0, codegen_1._) `{type: ${schemaValue}}`, ++}; ++function reportTypeError(it) { ++ const cxt = getTypeErrorContext(it); ++ (0, errors_1.reportError)(cxt, typeError); ++} ++exports.reportTypeError = reportTypeError; ++function getTypeErrorContext(it) { ++ const { gen, data, schema } = it; ++ const schemaCode = (0, util_1.schemaRefOrVal)(it, schema, "type"); ++ return { ++ gen, ++ keyword: "type", ++ data, ++ schema: schema.type, ++ schemaCode, ++ schemaValue: schemaCode, ++ parentSchema: schema, ++ params: {}, ++ it, ++ }; ++} ++//# sourceMappingURL=dataType.js.map +\ No newline at end of file +diff --git a/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json b/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json +index 7027a12..25679c8 100644 +--- a/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json ++++ b/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json +@@ -78,7 +78,7 @@ + "default": 0 + }, + "simpleTypes": { +- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] ++ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] + }, + "stringArray": { + "type": "array", +diff --git a/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json b/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json +index e0ae13d..57c9036 100644 +--- a/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json ++++ b/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json +@@ -78,7 +78,7 @@ + "default": 0 + }, + "simpleTypes": { +- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] ++ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] + }, + "stringArray": { + "type": "array", +diff --git a/node_modules/ajv/dist/refs/json-schema-draft-06.json b/node_modules/ajv/dist/refs/json-schema-draft-06.json +index 5410064..774435b 100644 +--- a/node_modules/ajv/dist/refs/json-schema-draft-06.json ++++ b/node_modules/ajv/dist/refs/json-schema-draft-06.json +@@ -16,7 +16,7 @@ + "allOf": [{"$ref": "#/definitions/nonNegativeInteger"}, {"default": 0}] + }, + "simpleTypes": { +- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] ++ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] + }, + "stringArray": { + "type": "array", +diff --git a/node_modules/ajv/dist/refs/json-schema-draft-07.json b/node_modules/ajv/dist/refs/json-schema-draft-07.json +index 6a74851..fc6dd7d 100644 +--- a/node_modules/ajv/dist/refs/json-schema-draft-07.json ++++ b/node_modules/ajv/dist/refs/json-schema-draft-07.json +@@ -16,7 +16,7 @@ + "allOf": [{"$ref": "#/definitions/nonNegativeInteger"}, {"default": 0}] + }, + "simpleTypes": { +- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] ++ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] + }, + "stringArray": { + "type": "array", +diff --git a/node_modules/ajv/dist/refs/jtd-schema.js b/node_modules/ajv/dist/refs/jtd-schema.js +index 1ee940a..1148887 100644 +--- a/node_modules/ajv/dist/refs/jtd-schema.js ++++ b/node_modules/ajv/dist/refs/jtd-schema.js +@@ -38,6 +38,7 @@ const typeForm = (root) => ({ + "uint16", + "int32", + "uint32", ++ "bigint", + ], + }, + }, +diff --git a/node_modules/ajv/dist/runtime/parseJson.js b/node_modules/ajv/dist/runtime/parseJson.js +index eaa2838..02ad708 100644 +--- a/node_modules/ajv/dist/runtime/parseJson.js ++++ b/node_modules/ajv/dist/runtime/parseJson.js +@@ -97,6 +97,71 @@ exports.parseJsonNumber = parseJsonNumber; + parseJsonNumber.message = undefined; + parseJsonNumber.position = 0; + parseJsonNumber.code = 'require("ajv/dist/runtime/parseJson").parseJsonNumber'; ++ ++function parseJsonBigInt(s, pos, maxDigits) { ++ let numStr = ""; ++ let c; ++ parseJsonBigInt.message = undefined; ++ if (s[pos] === "-") { ++ numStr += "-"; ++ pos++; ++ } ++ if (s[pos] === "0") { ++ numStr += "0"; ++ pos++; ++ } ++ else { ++ if (!parseDigits(maxDigits)) { ++ errorMessage(); ++ return undefined; ++ } ++ } ++ if (maxDigits) { ++ parseJsonBigInt.position = pos; ++ return BigInt(numStr); ++ } ++ if (s[pos] === ".") { ++ numStr += "."; ++ pos++; ++ if (!parseDigits()) { ++ errorMessage(); ++ return undefined; ++ } ++ } ++ if (((c = s[pos]), c === "e" || c === "E")) { ++ numStr += "e"; ++ pos++; ++ if (((c = s[pos]), c === "+" || c === "-")) { ++ numStr += c; ++ pos++; ++ } ++ if (!parseDigits()) { ++ errorMessage(); ++ return undefined; ++ } ++ } ++ parseJsonBigInt.position = pos; ++ return BigInt(numStr); ++ function parseDigits(maxLen) { ++ let digit = false; ++ while (((c = s[pos]), c >= "0" && c <= "9" && (maxLen === undefined || maxLen-- > 0))) { ++ digit = true; ++ numStr += c; ++ pos++; ++ } ++ return digit; ++ } ++ function errorMessage() { ++ parseJsonBigInt.position = pos; ++ parseJsonBigInt.message = pos < s.length ? `unexpected token ${s[pos]}` : "unexpected end"; ++ } ++} ++exports.parseJsonBigInt = parseJsonBigInt; ++parseJsonBigInt.message = undefined; ++parseJsonBigInt.position = 0; ++parseJsonBigInt.code = 'require("ajv/dist/runtime/parseJson").parseJsonBigInt'; ++ ++ + const escapedChars = { + b: "\b", + f: "\f", +diff --git a/node_modules/ajv/dist/vocabularies/jtd/type.js b/node_modules/ajv/dist/vocabularies/jtd/type.js +index 17a0b51..bc54aad 100644 +--- a/node_modules/ajv/dist/vocabularies/jtd/type.js ++++ b/node_modules/ajv/dist/vocabularies/jtd/type.js +@@ -45,6 +45,9 @@ const def = { + cond = timestampCode(cxt); + break; + } ++ case "bigint": ++ cond = codegen_1._`typeof ${data} == "bigint" || typeof ${data} == "string"` ++ break + case "float32": + case "float64": + cond = (0, codegen_1._) `typeof ${data} == "number"`; +diff --git a/node_modules/ajv/dist/vocabularies/jtd/type.js.orig b/node_modules/ajv/dist/vocabularies/jtd/type.js.orig +new file mode 100644 +index 0000000..17a0b51 +--- /dev/null ++++ b/node_modules/ajv/dist/vocabularies/jtd/type.js.orig +@@ -0,0 +1,69 @@ ++"use strict"; ++Object.defineProperty(exports, "__esModule", { value: true }); ++exports.intRange = void 0; ++const codegen_1 = require("../../compile/codegen"); ++const timestamp_1 = require("../../runtime/timestamp"); ++const util_1 = require("../../compile/util"); ++const metadata_1 = require("./metadata"); ++const error_1 = require("./error"); ++exports.intRange = { ++ int8: [-128, 127, 3], ++ uint8: [0, 255, 3], ++ int16: [-32768, 32767, 5], ++ uint16: [0, 65535, 5], ++ int32: [-2147483648, 2147483647, 10], ++ uint32: [0, 4294967295, 10], ++}; ++const error = { ++ message: (cxt) => (0, error_1.typeErrorMessage)(cxt, cxt.schema), ++ params: (cxt) => (0, error_1.typeErrorParams)(cxt, cxt.schema), ++}; ++function timestampCode(cxt) { ++ const { gen, data, it } = cxt; ++ const { timestamp, allowDate } = it.opts; ++ if (timestamp === "date") ++ return (0, codegen_1._) `${data} instanceof Date `; ++ const vts = (0, util_1.useFunc)(gen, timestamp_1.default); ++ const allowDateArg = allowDate ? (0, codegen_1._) `, true` : codegen_1.nil; ++ const validString = (0, codegen_1._) `typeof ${data} == "string" && ${vts}(${data}${allowDateArg})`; ++ return timestamp === "string" ? validString : (0, codegen_1.or)((0, codegen_1._) `${data} instanceof Date`, validString); ++} ++const def = { ++ keyword: "type", ++ schemaType: "string", ++ error, ++ code(cxt) { ++ (0, metadata_1.checkMetadata)(cxt); ++ const { data, schema, parentSchema, it } = cxt; ++ let cond; ++ switch (schema) { ++ case "boolean": ++ case "string": ++ cond = (0, codegen_1._) `typeof ${data} == ${schema}`; ++ break; ++ case "timestamp": { ++ cond = timestampCode(cxt); ++ break; ++ } ++ case "float32": ++ case "float64": ++ cond = (0, codegen_1._) `typeof ${data} == "number"`; ++ break; ++ default: { ++ const sch = schema; ++ cond = (0, codegen_1._) `typeof ${data} == "number" && isFinite(${data}) && !(${data} % 1)`; ++ if (!it.opts.int32range && (sch === "int32" || sch === "uint32")) { ++ if (sch === "uint32") ++ cond = (0, codegen_1._) `${cond} && ${data} >= 0`; ++ } ++ else { ++ const [min, max] = exports.intRange[sch]; ++ cond = (0, codegen_1._) `${cond} && ${data} >= ${min} && ${data} <= ${max}`; ++ } ++ } ++ } ++ cxt.pass(parentSchema.nullable ? (0, codegen_1.or)((0, codegen_1._) `${data} === null`, cond) : cond); ++ }, ++}; ++exports.default = def; ++//# sourceMappingURL=type.js.map +\ No newline at end of file diff --git a/patches/ajv+8.6.2.patch b/patches/ajv+8.6.2.patch deleted file mode 100644 index 3f54881b..00000000 --- a/patches/ajv+8.6.2.patch +++ /dev/null @@ -1,249 +0,0 @@ -diff --git a/node_modules/ajv/dist/compile/jtd/parse.js b/node_modules/ajv/dist/compile/jtd/parse.js -index 1eeb1be..7684121 100644 ---- a/node_modules/ajv/dist/compile/jtd/parse.js -+++ b/node_modules/ajv/dist/compile/jtd/parse.js -@@ -239,6 +239,9 @@ function parseType(cxt) { - gen.if(fail, () => parsingError(cxt, codegen_1.str `invalid timestamp`)); - break; - } -+ case "bigint": -+ parseBigInt(cxt); -+ break - case "float32": - case "float64": - parseNumber(cxt); -@@ -284,6 +287,15 @@ function parseNumber(cxt, maxDigits) { - skipWhitespace(cxt); - gen.if(codegen_1._ `"-0123456789".indexOf(${jsonSlice(1)}) < 0`, () => jsonSyntaxError(cxt), () => parseWith(cxt, parseJson_1.parseJsonNumber, maxDigits)); - } -+function parseBigInt(cxt, maxDigits) { -+ const {gen} = cxt -+ skipWhitespace(cxt) -+ gen.if( -+ _`"-0123456789".indexOf(${jsonSlice(1)}) < 0`, -+ () => jsonSyntaxError(cxt), -+ () => parseWith(cxt, parseJson_1.parseJsonBigInt, maxDigits) -+ ) -+} - function parseBooleanToken(bool, fail) { - return (cxt) => { - const { gen, data } = cxt; -diff --git a/node_modules/ajv/dist/compile/rules.js b/node_modules/ajv/dist/compile/rules.js -index 82a591f..1ebd8fe 100644 ---- a/node_modules/ajv/dist/compile/rules.js -+++ b/node_modules/ajv/dist/compile/rules.js -@@ -1,7 +1,7 @@ - "use strict"; - Object.defineProperty(exports, "__esModule", { value: true }); - exports.getRules = exports.isJSONType = void 0; --const _jsonTypes = ["string", "number", "integer", "boolean", "null", "object", "array"]; -+const _jsonTypes = ["string", "number", "integer", "boolean", "null", "object", "array","bigint"]; - const jsonTypes = new Set(_jsonTypes); - function isJSONType(x) { - return typeof x == "string" && jsonTypes.has(x); -@@ -13,10 +13,11 @@ function getRules() { - string: { type: "string", rules: [] }, - array: { type: "array", rules: [] }, - object: { type: "object", rules: [] }, -+ bigint: {type: "bigint", rules: []} - }; - return { -- types: { ...groups, integer: true, boolean: true, null: true }, -- rules: [{ rules: [] }, groups.number, groups.string, groups.array, groups.object], -+ types: { ...groups, integer: true, boolean: true, null: true, bigint: true }, -+ rules: [{ rules: [] }, groups.number, groups.string, groups.array, groups.object, groups.bigint], - post: { rules: [] }, - all: {}, - keywords: {}, -diff --git a/node_modules/ajv/dist/compile/validate/dataType.js b/node_modules/ajv/dist/compile/validate/dataType.js -index 6319e76..8b50b4c 100644 ---- a/node_modules/ajv/dist/compile/validate/dataType.js -+++ b/node_modules/ajv/dist/compile/validate/dataType.js -@@ -52,7 +52,7 @@ function coerceAndCheckDataType(it, types) { - return checkTypes; - } - exports.coerceAndCheckDataType = coerceAndCheckDataType; --const COERCIBLE = new Set(["string", "number", "integer", "boolean", "null"]); -+const COERCIBLE = new Set(["string", "number", "integer", "boolean", "null","bigint"]); - function coerceToTypes(types, coerceTypes) { - return coerceTypes - ? types.filter((t) => COERCIBLE.has(t) || (coerceTypes === "array" && t === "array")) -@@ -83,6 +83,14 @@ function coerceData(it, types, coerceTo) { - }); - function coerceSpecificType(t) { - switch (t) { -+ case "bigint": -+ gen -+ .elseIf( -+ codegen_1._`${dataType} == "boolean" || ${data} === null -+ || (${dataType} == "string" && ${data} && ${data} == BigInt(${data}))` -+ ) -+ .assign(coerced, codegen_1._`BigInt(${data})`) -+ return - case "string": - gen - .elseIf(codegen_1._ `${dataType} == "number" || ${dataType} == "boolean"`) -@@ -143,6 +151,9 @@ function checkDataType(dataType, data, strictNums, correct = DataType.Correct) { - case "number": - cond = numCond(); - break; -+ case "bigint": -+ cond = codegen_1._`typeof ${data} == "bigint" && isFinite(${data})` -+ break - default: - return codegen_1._ `typeof ${data} ${EQ} ${dataType}`; - } -diff --git a/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json b/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json -index 7027a12..25679c8 100644 ---- a/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json -+++ b/node_modules/ajv/dist/refs/json-schema-2019-09/meta/validation.json -@@ -78,7 +78,7 @@ - "default": 0 - }, - "simpleTypes": { -- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] -+ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] - }, - "stringArray": { - "type": "array", -diff --git a/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json b/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json -index e0ae13d..57c9036 100644 ---- a/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json -+++ b/node_modules/ajv/dist/refs/json-schema-2020-12/meta/validation.json -@@ -78,7 +78,7 @@ - "default": 0 - }, - "simpleTypes": { -- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] -+ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] - }, - "stringArray": { - "type": "array", -diff --git a/node_modules/ajv/dist/refs/json-schema-draft-06.json b/node_modules/ajv/dist/refs/json-schema-draft-06.json -index 5410064..774435b 100644 ---- a/node_modules/ajv/dist/refs/json-schema-draft-06.json -+++ b/node_modules/ajv/dist/refs/json-schema-draft-06.json -@@ -16,7 +16,7 @@ - "allOf": [{"$ref": "#/definitions/nonNegativeInteger"}, {"default": 0}] - }, - "simpleTypes": { -- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] -+ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] - }, - "stringArray": { - "type": "array", -diff --git a/node_modules/ajv/dist/refs/json-schema-draft-07.json b/node_modules/ajv/dist/refs/json-schema-draft-07.json -index 6a74851..fc6dd7d 100644 ---- a/node_modules/ajv/dist/refs/json-schema-draft-07.json -+++ b/node_modules/ajv/dist/refs/json-schema-draft-07.json -@@ -16,7 +16,7 @@ - "allOf": [{"$ref": "#/definitions/nonNegativeInteger"}, {"default": 0}] - }, - "simpleTypes": { -- "enum": ["array", "boolean", "integer", "null", "number", "object", "string"] -+ "enum": ["array", "boolean", "integer", "null", "number", "object", "string","bigint"] - }, - "stringArray": { - "type": "array", -diff --git a/node_modules/ajv/dist/refs/jtd-schema.js b/node_modules/ajv/dist/refs/jtd-schema.js -index 1ee940a..1148887 100644 ---- a/node_modules/ajv/dist/refs/jtd-schema.js -+++ b/node_modules/ajv/dist/refs/jtd-schema.js -@@ -38,6 +38,7 @@ const typeForm = (root) => ({ - "uint16", - "int32", - "uint32", -+ "bigint", - ], - }, - }, -diff --git a/node_modules/ajv/dist/runtime/parseJson.js b/node_modules/ajv/dist/runtime/parseJson.js -index 2576a6e..e7447b1 100644 ---- a/node_modules/ajv/dist/runtime/parseJson.js -+++ b/node_modules/ajv/dist/runtime/parseJson.js -@@ -97,6 +97,71 @@ exports.parseJsonNumber = parseJsonNumber; - parseJsonNumber.message = undefined; - parseJsonNumber.position = 0; - parseJsonNumber.code = 'require("ajv/dist/runtime/parseJson").parseJsonNumber'; -+ -+function parseJsonBigInt(s, pos, maxDigits) { -+ let numStr = ""; -+ let c; -+ parseJsonBigInt.message = undefined; -+ if (s[pos] === "-") { -+ numStr += "-"; -+ pos++; -+ } -+ if (s[pos] === "0") { -+ numStr += "0"; -+ pos++; -+ } -+ else { -+ if (!parseDigits(maxDigits)) { -+ errorMessage(); -+ return undefined; -+ } -+ } -+ if (maxDigits) { -+ parseJsonBigInt.position = pos; -+ return BigInt(numStr); -+ } -+ if (s[pos] === ".") { -+ numStr += "."; -+ pos++; -+ if (!parseDigits()) { -+ errorMessage(); -+ return undefined; -+ } -+ } -+ if (((c = s[pos]), c === "e" || c === "E")) { -+ numStr += "e"; -+ pos++; -+ if (((c = s[pos]), c === "+" || c === "-")) { -+ numStr += c; -+ pos++; -+ } -+ if (!parseDigits()) { -+ errorMessage(); -+ return undefined; -+ } -+ } -+ parseJsonBigInt.position = pos; -+ return BigInt(numStr); -+ function parseDigits(maxLen) { -+ let digit = false; -+ while (((c = s[pos]), c >= "0" && c <= "9" && (maxLen === undefined || maxLen-- > 0))) { -+ digit = true; -+ numStr += c; -+ pos++; -+ } -+ return digit; -+ } -+ function errorMessage() { -+ parseJsonBigInt.position = pos; -+ parseJsonBigInt.message = pos < s.length ? `unexpected token ${s[pos]}` : "unexpected end"; -+ } -+} -+exports.parseJsonBigInt = parseJsonBigInt; -+parseJsonBigInt.message = undefined; -+parseJsonBigInt.position = 0; -+parseJsonBigInt.code = 'require("ajv/dist/runtime/parseJson").parseJsonBigInt'; -+ -+ - const escapedChars = { - b: "\b", - f: "\f", -diff --git a/node_modules/ajv/dist/vocabularies/jtd/type.js b/node_modules/ajv/dist/vocabularies/jtd/type.js -index 428bddb..fbc3070 100644 ---- a/node_modules/ajv/dist/vocabularies/jtd/type.js -+++ b/node_modules/ajv/dist/vocabularies/jtd/type.js -@@ -45,6 +45,9 @@ const def = { - cond = timestampCode(cxt); - break; - } -+ case "bigint": -+ cond = codegen_1._`typeof ${data} == "bigint" || typeof ${data} == "string"` -+ break - case "float32": - case "float64": - cond = codegen_1._ `typeof ${data} == "number"`; \ No newline at end of file