From bae29a7be8b459a9f80d153b66046c4bbf0c091f Mon Sep 17 00:00:00 2001 From: Alex Newman Date: Sat, 13 Dec 2025 23:33:45 -0500 Subject: [PATCH] Bump version to 7.1.13 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Enhanced error handling and logging improvements: - Standardized error messages across hooks and worker service - Platform-aware restart instructions (macOS, Linux, Windows) - Fixed false error logging from happy_path_error misuse - Timezone-aware logging (uses local machine timezone instead of UTC) - Comprehensive test coverage for error handling scenarios 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 --- .claude-plugin/marketplace.json | 2 +- CLAUDE.md | 2 +- package.json | 2 +- plugin/.claude-plugin/plugin.json | 2 +- plugin/package.json | 2 +- plugin/scripts/worker-service.cjs | 2 +- src/utils/logger.ts | 16 +++++++++++++++- 7 files changed, 21 insertions(+), 7 deletions(-) diff --git a/.claude-plugin/marketplace.json b/.claude-plugin/marketplace.json index b3f657f0..860ffb9d 100644 --- a/.claude-plugin/marketplace.json +++ b/.claude-plugin/marketplace.json @@ -10,7 +10,7 @@ "plugins": [ { "name": "claude-mem", - "version": "7.1.12", + "version": "7.1.13", "source": "./plugin", "description": "Persistent memory system for Claude Code - context compression across sessions" } diff --git a/CLAUDE.md b/CLAUDE.md index 9d85787c..4176c2b6 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -6,7 +6,7 @@ Claude-mem is a Claude Code plugin providing persistent memory across sessions. It captures tool usage, compresses observations using the Claude Agent SDK, and injects relevant context into future sessions. -**Current Version**: 7.1.12 +**Current Version**: 7.1.13 ## Architecture diff --git a/package.json b/package.json index bc15996d..5d40d039 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "claude-mem", - "version": "7.1.12", + "version": "7.1.13", "description": "Memory compression system for Claude Code - persist context across sessions", "keywords": [ "claude", diff --git a/plugin/.claude-plugin/plugin.json b/plugin/.claude-plugin/plugin.json index ade86f48..cbf46d5e 100644 --- a/plugin/.claude-plugin/plugin.json +++ b/plugin/.claude-plugin/plugin.json @@ -1,6 +1,6 @@ { "name": "claude-mem", - "version": "7.1.12", + "version": "7.1.13", "description": "Persistent memory system for Claude Code - seamlessly preserve context across sessions", "author": { "name": "Alex Newman" diff --git a/plugin/package.json b/plugin/package.json index 827c460e..7430e3e7 100644 --- a/plugin/package.json +++ b/plugin/package.json @@ -1,6 +1,6 @@ { "name": "claude-mem-plugin", - "version": "7.1.12", + "version": "7.1.13", "private": true, "description": "Runtime dependencies for claude-mem bundled hooks", "type": "module", diff --git a/plugin/scripts/worker-service.cjs b/plugin/scripts/worker-service.cjs index dcdc402c..1f329f04 100755 --- a/plugin/scripts/worker-service.cjs +++ b/plugin/scripts/worker-service.cjs @@ -50,7 +50,7 @@ Please see the 3.x to 4.x migration guide for details on how to update your app. `}function xD(){return function(){this.error(404)}}function _D(){return function(e){if(this.hasTrailingSlash()){this.error(404);return}var r=ed.original(this.req);r.path=null,r.pathname=yD(r.pathname+"/");var t=fD(vD.format(r)),s=bD("Redirecting","Redirecting to "+mD(t));e.statusCode=301,e.setHeader("Content-Type","text/html; charset=UTF-8"),e.setHeader("Content-Length",Buffer.byteLength(s)),e.setHeader("Content-Security-Policy","default-src 'none'"),e.setHeader("X-Content-Type-Options","nosniff"),e.setHeader("Location",t),e.end(s)}}});var $x=U((Ut,jx)=>{"use strict";var bc=sy(),SD=require("events").EventEmitter,Ax=iy(),Ix=qb(),ED=wp(),wD=Rp(),Dx=dx(),Nx=Ox();Ut=jx.exports=TD;function TD(){var a=function(e,r,t){a.handle(e,r,t)};return Ax(a,SD.prototype,!1),Ax(a,Ix,!1),a.request=Object.create(Dx,{app:{configurable:!0,enumerable:!0,writable:!0,value:a}}),a.response=Object.create(Nx,{app:{configurable:!0,enumerable:!0,writable:!0,value:a}}),a.init(),a}Ut.application=Ix;Ut.request=Dx;Ut.response=Nx;Ut.Route=ED;Ut.Router=wD;Ut.json=bc.json;Ut.query=Pp();Ut.raw=bc.raw;Ut.static=kx();Ut.text=bc.text;Ut.urlencoded=bc.urlencoded;var RD=["bodyParser","compress","cookieSession","session","logger","cookieParser","favicon","responseTime","errorHandler","timeout","methodOverride","vhost","csrf","directory","limit","multipart","staticCache"];RD.forEach(function(a){Object.defineProperty(Ut,a,{get:function(){throw new Error("Most middleware (like "+a+") is no longer bundled with Express and must be installed separately. Please see https://github.com/senchalabs/connect#middleware.")},configurable:!0})})});var rd=U((Zq,Mx)=>{"use strict";Mx.exports=$x()});var h0=U((Nc,m0)=>{(function(a,e){typeof Nc=="object"&&typeof m0<"u"?e(Nc):typeof define=="function"&&define.amd?define(["exports"],e):e(a.URI=a.URI||{})})(Nc,(function(a){"use strict";function e(){for(var L=arguments.length,I=Array(L),_=0;_1){I[0]=I[0].slice(0,-1);for(var x=I.length-1,R=1;R= 0x80 (not a basic code point)","invalid-input":"Invalid input"},A=d-v,$=Math.floor,D=String.fromCharCode;function C(L){throw new RangeError(N[L])}function O(L,I){for(var _=[],x=L.length;x--;)_[x]=I(L[x]);return _}function j(L,I){var _=L.split("@"),x="";_.length>1&&(x=_[0]+"@",L=_[1]),L=L.replace(k,".");var R=L.split("."),F=O(R,I).join(".");return x+F}function q(L){for(var I=[],_=0,x=L.length;_=55296&&R<=56319&&_>1,I+=$(I/_);I>A*h>>1;R+=d)I=$(I/A);return $(R+(A+1)*I/(I+f))},X=function(I){var _=[],x=I.length,R=0,F=b,B=g,J=I.lastIndexOf(w);J<0&&(J=0);for(var ue=0;ue=128&&C("not-basic"),_.push(I.charCodeAt(ue));for(var xe=J>0?J+1:0;xe=x&&C("invalid-input");var Ae=V(I.charCodeAt(xe++));(Ae>=d||Ae>$((m-R)/je))&&C("overflow"),R+=Ae*je;var Se=ye<=B?v:ye>=B+h?h:ye-B;if(Ae$(m/Ie)&&C("overflow"),je*=Ie}var he=_.length+1;B=Z(R-me,he,me==0),$(R/he)>m-F&&C("overflow"),F+=$(R/he),R%=he,_.splice(R++,0,F)}return String.fromCodePoint.apply(String,_)},se=function(I){var _=[];I=q(I);var x=I.length,R=b,F=0,B=g,J=!0,ue=!1,xe=void 0;try{for(var me=I[Symbol.iterator](),je;!(J=(je=me.next()).done);J=!0){var ye=je.value;ye<128&&_.push(D(ye))}}catch(Mt){ue=!0,xe=Mt}finally{try{!J&&me.return&&me.return()}finally{if(ue)throw xe}}var Ae=_.length,Se=Ae;for(Ae&&_.push(w);Se=R&&nt$((m-F)/He)&&C("overflow"),F+=(Ie-R)*He,R=Ie;var ot=!0,vt=!1,gt=void 0;try{for(var Zt=I[Symbol.iterator](),$t;!(ot=($t=Zt.next()).done);ot=!0){var Nr=$t.value;if(Nrm&&C("overflow"),Nr==R){for(var Er=F,wr=d;;wr+=d){var Ot=wr<=B?v:wr>=B+h?h:wr-B;if(Er>6|192).toString(16).toUpperCase()+"%"+(I&63|128).toString(16).toUpperCase():_="%"+(I>>12|224).toString(16).toUpperCase()+"%"+(I>>6&63|128).toString(16).toUpperCase()+"%"+(I&63|128).toString(16).toUpperCase(),_}function De(L){for(var I="",_=0,x=L.length;_=194&&R<224){if(x-_>=6){var F=parseInt(L.substr(_+4,2),16);I+=String.fromCharCode((R&31)<<6|F&63)}else I+=L.substr(_,6);_+=6}else if(R>=224){if(x-_>=9){var B=parseInt(L.substr(_+4,2),16),J=parseInt(L.substr(_+7,2),16);I+=String.fromCharCode((R&15)<<12|(B&63)<<6|J&63)}else I+=L.substr(_,9);_+=9}else I+=L.substr(_,3),_+=3}return I}function H(L,I){function _(x){var R=De(x);return R.match(I.UNRESERVED)?R:x}return L.scheme&&(L.scheme=String(L.scheme).replace(I.PCT_ENCODED,_).toLowerCase().replace(I.NOT_SCHEME,"")),L.userinfo!==void 0&&(L.userinfo=String(L.userinfo).replace(I.PCT_ENCODED,_).replace(I.NOT_USERINFO,we).replace(I.PCT_ENCODED,s)),L.host!==void 0&&(L.host=String(L.host).replace(I.PCT_ENCODED,_).toLowerCase().replace(I.NOT_HOST,we).replace(I.PCT_ENCODED,s)),L.path!==void 0&&(L.path=String(L.path).replace(I.PCT_ENCODED,_).replace(L.scheme?I.NOT_PATH:I.NOT_PATH_NOSCHEME,we).replace(I.PCT_ENCODED,s)),L.query!==void 0&&(L.query=String(L.query).replace(I.PCT_ENCODED,_).replace(I.NOT_QUERY,we).replace(I.PCT_ENCODED,s)),L.fragment!==void 0&&(L.fragment=String(L.fragment).replace(I.PCT_ENCODED,_).replace(I.NOT_FRAGMENT,we).replace(I.PCT_ENCODED,s)),L}function G(L){return L.replace(/^0*(.*)/,"$1")||"0"}function te(L,I){var _=L.match(I.IPV4ADDRESS)||[],x=u(_,2),R=x[1];return R?R.split(".").map(G).join("."):L}function le(L,I){var _=L.match(I.IPV6ADDRESS)||[],x=u(_,3),R=x[1],F=x[2];if(R){for(var B=R.toLowerCase().split("::").reverse(),J=u(B,2),ue=J[0],xe=J[1],me=xe?xe.split(":").map(G):[],je=ue.split(":").map(G),ye=I.IPV4ADDRESS.test(je[je.length-1]),Ae=ye?7:8,Se=je.length-Ae,Ie=Array(Ae),he=0;he1){var Ue=Ie.slice(0,Le.index),nt=Ie.slice(Le.index+Le.length);ht=Ue.join(":")+"::"+nt.join(":")}else ht=Ie.join(":");return F&&(ht+="%"+F),ht}else return L}var W=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,Q="".match(/(){0}/)[1]===void 0;function ne(L){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},_={},x=I.iri!==!1?c:l;I.reference==="suffix"&&(L=(I.scheme?I.scheme+":":"")+"//"+L);var R=L.match(W);if(R){Q?(_.scheme=R[1],_.userinfo=R[3],_.host=R[4],_.port=parseInt(R[5],10),_.path=R[6]||"",_.query=R[7],_.fragment=R[8],isNaN(_.port)&&(_.port=R[5])):(_.scheme=R[1]||void 0,_.userinfo=L.indexOf("@")!==-1?R[3]:void 0,_.host=L.indexOf("//")!==-1?R[4]:void 0,_.port=parseInt(R[5],10),_.path=R[6]||"",_.query=L.indexOf("?")!==-1?R[7]:void 0,_.fragment=L.indexOf("#")!==-1?R[8]:void 0,isNaN(_.port)&&(_.port=L.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?R[4]:void 0)),_.host&&(_.host=le(te(_.host,x),x)),_.scheme===void 0&&_.userinfo===void 0&&_.host===void 0&&_.port===void 0&&!_.path&&_.query===void 0?_.reference="same-document":_.scheme===void 0?_.reference="relative":_.fragment===void 0?_.reference="absolute":_.reference="uri",I.reference&&I.reference!=="suffix"&&I.reference!==_.reference&&(_.error=_.error||"URI is not a "+I.reference+" reference.");var F=Ee[(I.scheme||_.scheme||"").toLowerCase()];if(!I.unicodeSupport&&(!F||!F.unicodeSupport)){if(_.host&&(I.domainHost||F&&F.domainHost))try{_.host=fe.toASCII(_.host.replace(x.PCT_ENCODED,De).toLowerCase())}catch(B){_.error=_.error||"Host's domain name can not be converted to ASCII via punycode: "+B}H(_,l)}else H(_,x);F&&F.parse&&F.parse(_,I)}else _.error=_.error||"URI can not be parsed.";return _}function Te(L,I){var _=I.iri!==!1?c:l,x=[];return L.userinfo!==void 0&&(x.push(L.userinfo),x.push("@")),L.host!==void 0&&x.push(le(te(String(L.host),_),_).replace(_.IPV6ADDRESS,function(R,F,B){return"["+F+(B?"%25"+B:"")+"]"})),(typeof L.port=="number"||typeof L.port=="string")&&(x.push(":"),x.push(String(L.port))),x.length?x.join(""):void 0}var ce=/^\.\.?\//,$e=/^\/\.(\/|$)/,ze=/^\/\.\.(\/|$)/,_e=/^\/?(?:.|\n)*?(?=\/|$)/;function et(L){for(var I=[];L.length;)if(L.match(ce))L=L.replace(ce,"");else if(L.match($e))L=L.replace($e,"/");else if(L.match(ze))L=L.replace(ze,"/"),I.pop();else if(L==="."||L==="..")L="";else{var _=L.match(_e);if(_){var x=_[0];L=L.slice(x.length),I.push(x)}else throw new Error("Unexpected dot segment condition")}return I.join("")}function Ve(L){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},_=I.iri?c:l,x=[],R=Ee[(I.scheme||L.scheme||"").toLowerCase()];if(R&&R.serialize&&R.serialize(L,I),L.host&&!_.IPV6ADDRESS.test(L.host)){if(I.domainHost||R&&R.domainHost)try{L.host=I.iri?fe.toUnicode(L.host):fe.toASCII(L.host.replace(_.PCT_ENCODED,De).toLowerCase())}catch(J){L.error=L.error||"Host's domain name can not be converted to "+(I.iri?"Unicode":"ASCII")+" via punycode: "+J}}H(L,_),I.reference!=="suffix"&&L.scheme&&(x.push(L.scheme),x.push(":"));var F=Te(L,I);if(F!==void 0&&(I.reference!=="suffix"&&x.push("//"),x.push(F),L.path&&L.path.charAt(0)!=="/"&&x.push("/")),L.path!==void 0){var B=L.path;!I.absolutePath&&(!R||!R.absolutePath)&&(B=et(B)),F===void 0&&(B=B.replace(/^\/\//,"/%2F")),x.push(B)}return L.query!==void 0&&(x.push("?"),x.push(L.query)),L.fragment!==void 0&&(x.push("#"),x.push(L.fragment)),x.join("")}function Qe(L,I){var _=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},x=arguments[3],R={};return x||(L=ne(Ve(L,_),_),I=ne(Ve(I,_),_)),_=_||{},!_.tolerant&&I.scheme?(R.scheme=I.scheme,R.userinfo=I.userinfo,R.host=I.host,R.port=I.port,R.path=et(I.path||""),R.query=I.query):(I.userinfo!==void 0||I.host!==void 0||I.port!==void 0?(R.userinfo=I.userinfo,R.host=I.host,R.port=I.port,R.path=et(I.path||""),R.query=I.query):(I.path?(I.path.charAt(0)==="/"?R.path=et(I.path):((L.userinfo!==void 0||L.host!==void 0||L.port!==void 0)&&!L.path?R.path="/"+I.path:L.path?R.path=L.path.slice(0,L.path.lastIndexOf("/")+1)+I.path:R.path=I.path,R.path=et(R.path)),R.query=I.query):(R.path=L.path,I.query!==void 0?R.query=I.query:R.query=L.query),R.userinfo=L.userinfo,R.host=L.host,R.port=L.port),R.scheme=L.scheme),R.fragment=I.fragment,R}function Ze(L,I,_){var x=n({scheme:"null"},_);return Ve(Qe(ne(L,x),ne(I,x),x,!0),x)}function Ke(L,I){return typeof L=="string"?L=Ve(ne(L,I),I):t(L)==="object"&&(L=ne(Ve(L,I),I)),L}function St(L,I,_){return typeof L=="string"?L=Ve(ne(L,_),_):t(L)==="object"&&(L=Ve(L,_)),typeof I=="string"?I=Ve(ne(I,_),_):t(I)==="object"&&(I=Ve(I,_)),L===I}function Et(L,I){return L&&L.toString().replace(!I||!I.iri?l.ESCAPE:c.ESCAPE,we)}function Pt(L,I){return L&&L.toString().replace(!I||!I.iri?l.PCT_ENCODED:c.PCT_ENCODED,De)}var Qr={scheme:"http",domainHost:!0,parse:function(I,_){return I.host||(I.error=I.error||"HTTP URIs must have a host."),I},serialize:function(I,_){var x=String(I.scheme).toLowerCase()==="https";return(I.port===(x?443:80)||I.port==="")&&(I.port=void 0),I.path||(I.path="/"),I}},jt={scheme:"https",domainHost:Qr.domainHost,parse:Qr.parse,serialize:Qr.serialize};function ma(L){return typeof L.secure=="boolean"?L.secure:String(L.scheme).toLowerCase()==="wss"}var ha={scheme:"ws",domainHost:!0,parse:function(I,_){var x=I;return x.secure=ma(x),x.resourceName=(x.path||"/")+(x.query?"?"+x.query:""),x.path=void 0,x.query=void 0,x},serialize:function(I,_){if((I.port===(ma(I)?443:80)||I.port==="")&&(I.port=void 0),typeof I.secure=="boolean"&&(I.scheme=I.secure?"wss":"ws",I.secure=void 0),I.resourceName){var x=I.resourceName.split("?"),R=u(x,2),F=R[0],B=R[1];I.path=F&&F!=="/"?F:void 0,I.query=B,I.resourceName=void 0}return I.fragment=void 0,I}},ti={scheme:"wss",domainHost:ha.domainHost,parse:ha.parse,serialize:ha.serialize},qa={},io=!0,oo="[A-Za-z0-9\\-\\.\\_\\~"+(io?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",rr="[0-9A-Fa-f]",co=r(r("%[EFef]"+rr+"%"+rr+rr+"%"+rr+rr)+"|"+r("%[89A-Fa-f]"+rr+"%"+rr+rr)+"|"+r("%"+rr+rr)),ar="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Gl="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",Wl=e(Gl,'[\\"\\\\]'),Zl="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",Xl=new RegExp(oo,"g"),va=new RegExp(co,"g"),Kl=new RegExp(e("[^]",ar,"[\\.]",'[\\"]',Wl),"g"),Yr=new RegExp(e("[^]",oo,Zl),"g"),Ql=Yr;function Gs(L){var I=De(L);return I.match(Xl)?I:L}var lo={scheme:"mailto",parse:function(I,_){var x=I,R=x.to=x.path?x.path.split(","):[];if(x.path=void 0,x.query){for(var F=!1,B={},J=x.query.split("&"),ue=0,xe=J.length;ue{"use strict";v0.exports=function a(e,r){if(e===r)return!0;if(e&&r&&typeof e=="object"&&typeof r=="object"){if(e.constructor!==r.constructor)return!1;var t,s,i;if(Array.isArray(e)){if(t=e.length,t!=r.length)return!1;for(s=t;s--!==0;)if(!a(e[s],r[s]))return!1;return!0}if(e.constructor===RegExp)return e.source===r.source&&e.flags===r.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===r.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===r.toString();if(i=Object.keys(e),t=i.length,t!==Object.keys(r).length)return!1;for(s=t;s--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[s]))return!1;for(s=t;s--!==0;){var n=i[s];if(!a(e[n],r[n]))return!1}return!0}return e!==e&&r!==r}});var y0=U((D3,g0)=>{"use strict";g0.exports=function(e){for(var r=0,t=e.length,s=0,i;s=55296&&i<=56319&&s{"use strict";_0.exports={copy:D2,checkDataType:xd,checkDataTypes:N2,coerceToTypes:j2,toHash:Sd,getProperty:Ed,escapeQuotes:wd,equal:jc(),ucs2length:y0(),varOccurences:L2,varReplace:F2,schemaHasRules:q2,schemaHasRulesExcept:U2,schemaUnknownRules:H2,toQuotedString:_d,getPathExpr:B2,getPath:z2,getData:W2,unescapeFragment:Z2,unescapeJsonPointer:Rd,escapeFragment:X2,escapeJsonPointer:Td};function D2(a,e){e=e||{};for(var r in a)e[r]=a[r];return e}function xd(a,e,r,t){var s=t?" !== ":" === ",i=t?" || ":" && ",n=t?"!":"",o=t?"":"!";switch(a){case"null":return e+s+"null";case"array":return n+"Array.isArray("+e+")";case"object":return"("+n+e+i+"typeof "+e+s+'"object"'+i+o+"Array.isArray("+e+"))";case"integer":return"(typeof "+e+s+'"number"'+i+o+"("+e+" % 1)"+i+e+s+e+(r?i+n+"isFinite("+e+")":"")+")";case"number":return"(typeof "+e+s+'"'+a+'"'+(r?i+n+"isFinite("+e+")":"")+")";default:return"typeof "+e+s+'"'+a+'"'}}function N2(a,e,r){switch(a.length){case 1:return xd(a[0],e,r,!0);default:var t="",s=Sd(a);s.array&&s.object&&(t=s.null?"(":"(!"+e+" || ",t+="typeof "+e+' !== "object")',delete s.null,delete s.array,delete s.object),s.number&&delete s.integer;for(var i in s)t+=(t?" && ":"")+xd(i,e,r,!0);return t}}var b0=Sd(["string","number","integer","boolean","null"]);function j2(a,e){if(Array.isArray(e)){for(var r=[],t=0;t=e)throw new Error("Cannot access property/index "+t+" levels up, current level is "+e);return r[e-t]}if(t>e)throw new Error("Cannot access data "+t+" levels up, current level is "+e);if(i="data"+(e-t||""),!s)return i}for(var o=i,l=s.split("/"),c=0;c{"use strict";var K2=_s();S0.exports=Q2;function Q2(a){K2.copy(a,this)}});var w0=U(($3,E0)=>{"use strict";var Da=E0.exports=function(a,e,r){typeof e=="function"&&(r=e,e={}),r=e.cb||r;var t=typeof r=="function"?r:r.pre||function(){},s=r.post||function(){};$c(e,t,s,a,"",a)};Da.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0};Da.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Da.propsKeywords={definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Da.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function $c(a,e,r,t,s,i,n,o,l,c){if(t&&typeof t=="object"&&!Array.isArray(t)){e(t,s,i,n,o,l,c);for(var u in t){var p=t[u];if(Array.isArray(p)){if(u in Da.arrayKeywords)for(var m=0;m{"use strict";var Wi=h0(),T0=jc(),qc=_s(),Mc=Pd(),J2=w0();O0.exports=ja;ja.normalizeId=Na;ja.fullPath=Lc;ja.url=Fc;ja.ids=sj;ja.inlineRef=Od;ja.schema=Uc;function ja(a,e,r){var t=this._refs[r];if(typeof t=="string")if(this._refs[t])t=this._refs[t];else return ja.call(this,a,e,t);if(t=t||this._schemas[r],t instanceof Mc)return Od(t.schema,this._opts.inlineRefs)?t.schema:t.validate||this._compile(t);var s=Uc.call(this,e,r),i,n,o;return s&&(i=s.schema,e=s.root,o=s.baseId),i instanceof Mc?n=i.validate||a.call(this,i.schema,e,void 0,o):i!==void 0&&(n=Od(i,this._opts.inlineRefs)?i:a.call(this,i,e,void 0,o)),n}function Uc(a,e){var r=Wi.parse(e),t=P0(r),s=Lc(this._getId(a.schema));if(Object.keys(a.schema).length===0||t!==s){var i=Na(t),n=this._refs[i];if(typeof n=="string")return ej.call(this,a,n,r);if(n instanceof Mc)n.validate||this._compile(n),a=n;else if(n=this._schemas[i],n instanceof Mc){if(n.validate||this._compile(n),i==Na(e))return{schema:n,root:a,baseId:s};a=n}else return;if(!a.schema)return;s=Lc(this._getId(a.schema))}return R0.call(this,r,s,a.schema,a)}function ej(a,e,r){var t=Uc.call(this,a,e);if(t){var s=t.schema,i=t.baseId;a=t.root;var n=this._getId(s);return n&&(i=Fc(i,n)),R0.call(this,r,i,s,a)}}var tj=qc.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function R0(a,e,r,t){if(a.fragment=a.fragment||"",a.fragment.slice(0,1)=="/"){for(var s=a.fragment.split("/"),i=1;i{"use strict";var Ad=Hc();k0.exports={Validation:C0(nj),MissingRef:C0(Id)};function nj(a){this.message="validation failed",this.errors=a,this.ajv=this.validation=!0}Id.message=function(a,e){return"can't resolve reference "+e+" from id "+a};function Id(a,e,r){this.message=r||Id.message(a,e),this.missingRef=Ad.url(a,e),this.missingSchema=Ad.normalizeId(Ad.fullPath(this.missingRef))}function C0(a){return a.prototype=Object.create(Error.prototype),a.prototype.constructor=a,a}});var Dd=U((F3,A0)=>{"use strict";A0.exports=function(a,e){e||(e={}),typeof e=="function"&&(e={cmp:e});var r=typeof e.cycles=="boolean"?e.cycles:!1,t=e.cmp&&(function(i){return function(n){return function(o,l){var c={key:o,value:n[o]},u={key:l,value:n[l]};return i(c,u)}}})(e.cmp),s=[];return(function i(n){if(n&&n.toJSON&&typeof n.toJSON=="function"&&(n=n.toJSON()),n!==void 0){if(typeof n=="number")return isFinite(n)?""+n:"null";if(typeof n!="object")return JSON.stringify(n);var o,l;if(Array.isArray(n)){for(l="[",o=0;o{"use strict";I0.exports=function(e,r,t){var s="",i=e.schema.$async===!0,n=e.util.schemaHasRulesExcept(e.schema,e.RULES.all,"$ref"),o=e.self._getId(e.schema);if(e.opts.strictKeywords){var l=e.util.schemaUnknownRules(e.schema,e.RULES.keywords);if(l){var c="unknown keyword: "+l;if(e.opts.strictKeywords==="log")e.logger.warn(c);else throw new Error(c)}}if(e.isTop&&(s+=" var validate = ",i&&(e.async=!0,s+="async "),s+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ",o&&(e.opts.sourceCode||e.opts.processCode)&&(s+=" "+("/*# sourceURL="+o+" */")+" ")),typeof e.schema=="boolean"||!(n||e.schema.$ref)){var r="false schema",u=e.level,p=e.dataLevel,m=e.schema[r],d=e.schemaPath+e.util.getProperty(r),v=e.errSchemaPath+"/"+r,P=!e.opts.allErrors,N,h="data"+(p||""),w="valid"+u;if(e.schema===!1){e.isTop?P=!0:s+=" var "+w+" = false; ";var f=f||[];f.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(N||"false schema")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(v)+" , params: {} ",e.opts.messages!==!1&&(s+=" , message: 'boolean schema is false' "),e.opts.verbose&&(s+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),s+=" } "):s+=" {} ";var y=s;s=f.pop(),!e.compositeRule&&P?e.async?s+=" throw new ValidationError(["+y+"]); ":s+=" validate.errors = ["+y+"]; return false; ":s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else e.isTop?i?s+=" return data; ":s+=" validate.errors = null; return true; ":s+=" var "+w+" = true; ";return e.isTop&&(s+=" }; return validate; "),s}if(e.isTop){var g=e.isTop,u=e.level=0,p=e.dataLevel=0,h="data";if(e.rootId=e.resolve.fullPath(e.self._getId(e.root.schema)),e.baseId=e.baseId||e.rootId,delete e.isTop,e.dataPathArr=[""],e.schema.default!==void 0&&e.opts.useDefaults&&e.opts.strictDefaults){var b="default is ignored in the schema root";if(e.opts.strictDefaults==="log")e.logger.warn(b);else throw new Error(b)}s+=" var vErrors = null; ",s+=" var errors = 0; ",s+=" if (rootData === undefined) rootData = data; "}else{var u=e.level,p=e.dataLevel,h="data"+(p||"");if(o&&(e.baseId=e.resolve.url(e.baseId,o)),i&&!e.async)throw new Error("async schema in sync schema");s+=" var errs_"+u+" = errors;"}var w="valid"+u,P=!e.opts.allErrors,T="",k="",N,A=e.schema.type,$=Array.isArray(A);if(A&&e.opts.nullable&&e.schema.nullable===!0&&($?A.indexOf("null")==-1&&(A=A.concat("null")):A!="null"&&(A=[A,"null"],$=!0)),$&&A.length==1&&(A=A[0],$=!1),e.schema.$ref&&n){if(e.opts.extendRefs=="fail")throw new Error('$ref: validation keywords used in schema at path "'+e.errSchemaPath+'" (see option extendRefs)');e.opts.extendRefs!==!0&&(n=!1,e.logger.warn('$ref: keywords ignored in schema at path "'+e.errSchemaPath+'"'))}if(e.schema.$comment&&e.opts.$comment&&(s+=" "+e.RULES.all.$comment.code(e,"$comment")),A){if(e.opts.coerceTypes)var D=e.util.coerceToTypes(e.opts.coerceTypes,A);var C=e.RULES.types[A];if(D||$||C===!0||C&&!_e(C)){var d=e.schemaPath+".type",v=e.errSchemaPath+"/type",d=e.schemaPath+".type",v=e.errSchemaPath+"/type",O=$?"checkDataTypes":"checkDataType";if(s+=" if ("+e.util[O](A,h,e.opts.strictNumbers,!0)+") { ",D){var j="dataType"+u,q="coerced"+u;s+=" var "+j+" = typeof "+h+"; var "+q+" = undefined; ",e.opts.coerceTypes=="array"&&(s+=" if ("+j+" == 'object' && Array.isArray("+h+") && "+h+".length == 1) { "+h+" = "+h+"[0]; "+j+" = typeof "+h+"; if ("+e.util.checkDataType(e.schema.type,h,e.opts.strictNumbers)+") "+q+" = "+h+"; } "),s+=" if ("+q+" !== undefined) ; ";var z=D;if(z)for(var V,K=-1,Z=z.length-1;K{"use strict";var zc=Hc(),Gc=_s(),N0=Bc(),ij=Dd(),D0=Nd(),oj=Gc.ucs2length,cj=jc(),lj=N0.Validation;$0.exports=jd;function jd(a,e,r,t){var s=this,i=this._opts,n=[void 0],o={},l=[],c={},u=[],p={},m=[];e=e||{schema:a,refVal:n,refs:o};var d=uj.call(this,a,e,t),v=this._compilations[d.index];if(d.compiling)return v.callValidate=b;var h=this._formats,f=this.RULES;try{var y=w(a,e,r,t);v.validate=y;var g=v.callValidate;return g&&(g.schema=y.schema,g.errors=null,g.refs=y.refs,g.refVal=y.refVal,g.root=y.root,g.$async=y.$async,i.sourceCode&&(g.source=y.source)),y}finally{pj.call(this,a,e,t)}function b(){var O=v.validate,j=O.apply(this,arguments);return b.errors=O.errors,j}function w(O,j,q,z){var V=!j||j&&j.schema==O;if(j.schema!=e.schema)return jd.call(s,O,j,q,z);var K=O.$async===!0,Z=D0({isTop:!0,schema:O,isRoot:V,baseId:z,root:j,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:N0.MissingRef,RULES:f,validate:D0,util:Gc,resolve:zc,resolveRef:P,usePattern:$,useDefault:D,useCustomRule:C,opts:i,formats:h,logger:s.logger,self:s});Z=Vc(n,mj)+Vc(l,dj)+Vc(u,fj)+Vc(m,hj)+Z,i.processCode&&(Z=i.processCode(Z,O));var X;try{var se=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",Z);X=se(s,f,h,e,n,u,m,cj,oj,lj),n[0]=X}catch(Y){throw s.logger.error("Error compiling schema, function code:",Z),Y}return X.schema=O,X.errors=null,X.refs=o,X.refVal=n,X.root=V?X:j,K&&(X.$async=!0),i.sourceCode===!0&&(X.source={code:Z,patterns:l,defaults:u}),X}function P(O,j,q){j=zc.url(O,j);var z=o[j],V,K;if(z!==void 0)return V=n[z],K="refVal["+z+"]",A(V,K);if(!q&&e.refs){var Z=e.refs[j];if(Z!==void 0)return V=e.refVal[Z],K=T(j,V),A(V,K)}K=T(j);var X=zc.call(s,w,e,j);if(X===void 0){var se=r&&r[j];se&&(X=zc.inlineRef(se,i.inlineRefs)?se:jd.call(s,se,e,r,O))}if(X===void 0)k(j);else return N(j,X),A(X,K)}function T(O,j){var q=n.length;return n[q]=j,o[O]=q,"refVal"+q}function k(O){delete o[O]}function N(O,j){var q=o[O];n[q]=j}function A(O,j){return typeof O=="object"||typeof O=="boolean"?{code:j,schema:O,inline:!0}:{code:j,$async:O&&!!O.$async}}function $(O){var j=c[O];return j===void 0&&(j=c[O]=l.length,l[j]=O),"pattern"+j}function D(O){switch(typeof O){case"boolean":case"number":return""+O;case"string":return Gc.toQuotedString(O);case"object":if(O===null)return"null";var j=ij(O),q=p[j];return q===void 0&&(q=p[j]=u.length,u[q]=O),"default"+q}}function C(O,j,q,z){if(s._opts.validateSchema!==!1){var V=O.definition.dependencies;if(V&&!V.every(function(we){return Object.prototype.hasOwnProperty.call(q,we)}))throw new Error("parent schema must have all required keywords: "+V.join(","));var K=O.definition.validateSchema;if(K){var Z=K(j);if(!Z){var X="keyword schema is invalid: "+s.errorsText(K.errors);if(s._opts.validateSchema=="log")s.logger.error(X);else throw new Error(X)}}}var se=O.definition.compile,Y=O.definition.inline,Pe=O.definition.macro,fe;if(se)fe=se.call(s,j,q,z);else if(Pe)fe=Pe.call(s,j,q,z),i.validateSchema!==!1&&s.validateSchema(fe,!0);else if(Y)fe=Y.call(s,z,O.keyword,j,q);else if(fe=O.definition.validate,!fe)return;if(fe===void 0)throw new Error('custom keyword "'+O.keyword+'"failed to compile');var Ee=m.length;return m[Ee]=fe,{code:"customRule"+Ee,validate:fe}}}function uj(a,e,r){var t=j0.call(this,a,e,r);return t>=0?{index:t,compiling:!0}:(t=this._compilations.length,this._compilations[t]={schema:a,root:e,baseId:r},{index:t,compiling:!1})}function pj(a,e,r){var t=j0.call(this,a,e,r);t>=0&&this._compilations.splice(t,1)}function j0(a,e,r){for(var t=0;t{"use strict";var Wc=L0.exports=function(){this._cache={}};Wc.prototype.put=function(e,r){this._cache[e]=r};Wc.prototype.get=function(e){return this._cache[e]};Wc.prototype.del=function(e){delete this._cache[e]};Wc.prototype.clear=function(){this._cache={}}});var Q0=U((B3,K0)=>{"use strict";var vj=_s(),gj=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,yj=[0,31,28,31,30,31,30,31,31,30,31,30,31],bj=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i,q0=/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,xj=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,_j=/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,U0=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,H0=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i,B0=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,z0=/^(?:\/(?:[^~/]|~0|~1)*)*$/,V0=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,G0=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;K0.exports=Zc;function Zc(a){return a=a=="full"?"full":"fast",vj.copy(Zc[a])}Zc.fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":U0,url:H0,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:q0,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:X0,uuid:B0,"json-pointer":z0,"json-pointer-uri-fragment":V0,"relative-json-pointer":G0};Zc.full={date:W0,time:Z0,"date-time":wj,uri:Rj,"uri-reference":_j,"uri-template":U0,url:H0,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:q0,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:X0,uuid:B0,"json-pointer":z0,"json-pointer-uri-fragment":V0,"relative-json-pointer":G0};function Sj(a){return a%4===0&&(a%100!==0||a%400===0)}function W0(a){var e=a.match(gj);if(!e)return!1;var r=+e[1],t=+e[2],s=+e[3];return t>=1&&t<=12&&s>=1&&s<=(t==2&&Sj(r)?29:yj[t])}function Z0(a,e){var r=a.match(bj);if(!r)return!1;var t=r[1],s=r[2],i=r[3],n=r[5];return(t<=23&&s<=59&&i<=59||t==23&&s==59&&i==60)&&(!e||n)}var Ej=/t|\s/i;function wj(a){var e=a.split(Ej);return e.length==2&&W0(e[0])&&Z0(e[1],!0)}var Tj=/\/|:/;function Rj(a){return Tj.test(a)&&xj.test(a)}var Pj=/[^\\]\\Z/;function X0(a){if(Pj.test(a))return!1;try{return new RegExp(a),!0}catch{return!1}}});var J0=U((z3,Y0)=>{"use strict";Y0.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.errSchemaPath+"/"+r,c=!e.opts.allErrors,u="data"+(n||""),p="valid"+i,m,d;if(o=="#"||o=="#/")e.isRoot?(m=e.async,d="validate"):(m=e.root.schema.$async===!0,d="root.refVal[0]");else{var v=e.resolveRef(e.baseId,o,e.isRoot);if(v===void 0){var h=e.MissingRefError.message(e.baseId,o);if(e.opts.missingRefs=="fail"){e.logger.error(h);var f=f||[];f.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '$ref' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(l)+" , params: { ref: '"+e.util.escapeQuotes(o)+"' } ",e.opts.messages!==!1&&(s+=" , message: 'can\\'t resolve reference "+e.util.escapeQuotes(o)+"' "),e.opts.verbose&&(s+=" , schema: "+e.util.toQuotedString(o)+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+u+" "),s+=" } "):s+=" {} ";var y=s;s=f.pop(),!e.compositeRule&&c?e.async?s+=" throw new ValidationError(["+y+"]); ":s+=" validate.errors = ["+y+"]; return false; ":s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",c&&(s+=" if (false) { ")}else if(e.opts.missingRefs=="ignore")e.logger.warn(h),c&&(s+=" if (true) { ");else throw new e.MissingRefError(e.baseId,o,h)}else if(v.inline){var g=e.util.copy(e);g.level++;var b="valid"+g.level;g.schema=v.schema,g.schemaPath="",g.errSchemaPath=o;var w=e.validate(g).replace(/validate\.schema/g,v.code);s+=" "+w+" ",c&&(s+=" if ("+b+") { ")}else m=v.$async===!0||e.async&&v.$async!==!1,d=v.code}if(d){var f=f||[];f.push(s),s="",e.opts.passContext?s+=" "+d+".call(this, ":s+=" "+d+"( ",s+=" "+u+", (dataPath || '')",e.errorPath!='""'&&(s+=" + "+e.errorPath);var P=n?"data"+(n-1||""):"parentData",T=n?e.dataPathArr[n]:"parentDataProperty";s+=" , "+P+" , "+T+", rootData) ";var k=s;if(s=f.pop(),m){if(!e.async)throw new Error("async schema referenced by sync schema");c&&(s+=" var "+p+"; "),s+=" try { await "+k+"; ",c&&(s+=" "+p+" = true; "),s+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ",c&&(s+=" "+p+" = false; "),s+=" } ",c&&(s+=" if ("+p+") { ")}else s+=" if (!"+k+") { if (vErrors === null) vErrors = "+d+".errors; else vErrors = vErrors.concat("+d+".errors); errors = vErrors.length; } ",c&&(s+=" else { ")}return s}});var t_=U((V3,e_)=>{"use strict";e_.exports=function(e,r,t){var s=" ",i=e.schema[r],n=e.schemaPath+e.util.getProperty(r),o=e.errSchemaPath+"/"+r,l=!e.opts.allErrors,c=e.util.copy(e),u="";c.level++;var p="valid"+c.level,m=c.baseId,d=!0,v=i;if(v)for(var h,f=-1,y=v.length-1;f0||h===!1:e.util.schemaHasRules(h,e.RULES.all))&&(d=!1,c.schema=h,c.schemaPath=n+"["+f+"]",c.errSchemaPath=o+"/"+f,s+=" "+e.validate(c)+" ",c.baseId=m,l&&(s+=" if ("+p+") { ",u+="}"));return l&&(d?s+=" if (true) { ":s+=" "+u.slice(0,-1)+" "),s}});var a_=U((G3,r_)=>{"use strict";r_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d="errs__"+i,v=e.util.copy(e),h="";v.level++;var f="valid"+v.level,y=o.every(function(N){return e.opts.strictKeywords?typeof N=="object"&&Object.keys(N).length>0||N===!1:e.util.schemaHasRules(N,e.RULES.all)});if(y){var g=v.baseId;s+=" var "+d+" = errors; var "+m+" = false; ";var b=e.compositeRule;e.compositeRule=v.compositeRule=!0;var w=o;if(w)for(var P,T=-1,k=w.length-1;T{"use strict";s_.exports=function(e,r,t){var s=" ",i=e.schema[r],n=e.errSchemaPath+"/"+r,o=!e.opts.allErrors,l=e.util.toQuotedString(i);return e.opts.$comment===!0?s+=" console.log("+l+");":typeof e.opts.$comment=="function"&&(s+=" self._opts.$comment("+l+", "+e.util.toQuotedString(n)+", validate.root.schema);"),s}});var o_=U((Z3,i_)=>{"use strict";i_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d=e.opts.$data&&o&&o.$data,v;d?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",v="schema"+i):v=o,d||(s+=" var schema"+i+" = validate.schema"+l+";"),s+="var "+m+" = equal("+p+", schema"+i+"); if (!"+m+") { ";var h=h||[];h.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'const' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { allowedValue: schema"+i+" } ",e.opts.messages!==!1&&(s+=" , message: 'should be equal to constant' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var f=s;return s=h.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+f+"]); ":s+=" validate.errors = ["+f+"]; return false; ":s+=" var err = "+f+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" }",u&&(s+=" else { "),s}});var l_=U((X3,c_)=>{"use strict";c_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d="errs__"+i,v=e.util.copy(e),h="";v.level++;var f="valid"+v.level,y="i"+i,g=v.dataLevel=e.dataLevel+1,b="data"+g,w=e.baseId,P=e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all);if(s+="var "+d+" = errors;var "+m+";",P){var T=e.compositeRule;e.compositeRule=v.compositeRule=!0,v.schema=o,v.schemaPath=l,v.errSchemaPath=c,s+=" var "+f+" = false; for (var "+y+" = 0; "+y+" < "+p+".length; "+y+"++) { ",v.errorPath=e.util.getPathExpr(e.errorPath,y,e.opts.jsonPointers,!0);var k=p+"["+y+"]";v.dataPathArr[g]=y;var N=e.validate(v);v.baseId=w,e.util.varOccurences(N,b)<2?s+=" "+e.util.varReplace(N,b,k)+" ":s+=" var "+b+" = "+k+"; "+N+" ",s+=" if ("+f+") break; } ",e.compositeRule=v.compositeRule=T,s+=" "+h+" if (!"+f+") {"}else s+=" if ("+p+".length == 0) {";var A=A||[];A.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'contains' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: {} ",e.opts.messages!==!1&&(s+=" , message: 'should contain a valid item' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var $=s;return s=A.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+$+"]); ":s+=" validate.errors = ["+$+"]; return false; ":s+=" var err = "+$+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } else { ",P&&(s+=" errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; } "),e.opts.allErrors&&(s+=" } "),s}});var p_=U((K3,u_)=>{"use strict";u_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="errs__"+i,d=e.util.copy(e),v="";d.level++;var h="valid"+d.level,f={},y={},g=e.opts.ownProperties;for(T in o)if(T!="__proto__"){var b=o[T],w=Array.isArray(b)?y:f;w[T]=b}s+="var "+m+" = errors;";var P=e.errorPath;s+="var missing"+i+";";for(var T in y)if(w=y[T],w.length){if(s+=" if ( "+p+e.util.getProperty(T)+" !== undefined ",g&&(s+=" && Object.prototype.hasOwnProperty.call("+p+", '"+e.util.escapeQuotes(T)+"') "),u){s+=" && ( ";var k=w;if(k)for(var N,A=-1,$=k.length-1;A<$;){N=k[A+=1],A&&(s+=" || ");var D=e.util.getProperty(N),C=p+D;s+=" ( ( "+C+" === undefined ",g&&(s+=" || ! Object.prototype.hasOwnProperty.call("+p+", '"+e.util.escapeQuotes(N)+"') "),s+=") && (missing"+i+" = "+e.util.toQuotedString(e.opts.jsonPointers?N:D)+") ) "}s+=")) { ";var O="missing"+i,j="' + "+O+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(P,O,!0):P+" + "+O);var q=q||[];q.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { property: '"+e.util.escapeQuotes(T)+"', missingProperty: '"+j+"', depsCount: "+w.length+", deps: '"+e.util.escapeQuotes(w.length==1?w[0]:w.join(", "))+"' } ",e.opts.messages!==!1&&(s+=" , message: 'should have ",w.length==1?s+="property "+e.util.escapeQuotes(w[0]):s+="properties "+e.util.escapeQuotes(w.join(", ")),s+=" when property "+e.util.escapeQuotes(T)+" is present' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var z=s;s=q.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+z+"]); ":s+=" validate.errors = ["+z+"]; return false; ":s+=" var err = "+z+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else{s+=" ) { ";var V=w;if(V)for(var N,K=-1,Z=V.length-1;K0||b===!1:e.util.schemaHasRules(b,e.RULES.all))&&(s+=" "+h+" = true; if ( "+p+e.util.getProperty(T)+" !== undefined ",g&&(s+=" && Object.prototype.hasOwnProperty.call("+p+", '"+e.util.escapeQuotes(T)+"') "),s+=") { ",d.schema=b,d.schemaPath=l+e.util.getProperty(T),d.errSchemaPath=c+"/"+e.util.escapeFragment(T),s+=" "+e.validate(d)+" ",d.baseId=X,s+=" } ",u&&(s+=" if ("+h+") { ",v+="}"))}return u&&(s+=" "+v+" if ("+m+" == errors) {"),s}});var f_=U((Q3,d_)=>{"use strict";d_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d=e.opts.$data&&o&&o.$data,v;d?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",v="schema"+i):v=o;var h="i"+i,f="schema"+i;d||(s+=" var "+f+" = validate.schema"+l+";"),s+="var "+m+";",d&&(s+=" if (schema"+i+" === undefined) "+m+" = true; else if (!Array.isArray(schema"+i+")) "+m+" = false; else {"),s+=""+m+" = false;for (var "+h+"=0; "+h+"<"+f+".length; "+h+"++) if (equal("+p+", "+f+"["+h+"])) { "+m+" = true; break; }",d&&(s+=" } "),s+=" if (!"+m+") { ";var y=y||[];y.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'enum' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { allowedValues: schema"+i+" } ",e.opts.messages!==!1&&(s+=" , message: 'should be equal to one of the allowed values' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var g=s;return s=y.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+g+"]); ":s+=" validate.errors = ["+g+"]; return false; ":s+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" }",u&&(s+=" else { "),s}});var h_=U((Y3,m_)=>{"use strict";m_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||"");if(e.opts.format===!1)return u&&(s+=" if (true) { "),s;var m=e.opts.$data&&o&&o.$data,d;m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o;var v=e.opts.unknownFormats,h=Array.isArray(v);if(m){var f="format"+i,y="isObject"+i,g="formatType"+i;s+=" var "+f+" = formats["+d+"]; var "+y+" = typeof "+f+" == 'object' && !("+f+" instanceof RegExp) && "+f+".validate; var "+g+" = "+y+" && "+f+".type || 'string'; if ("+y+") { ",e.async&&(s+=" var async"+i+" = "+f+".async; "),s+=" "+f+" = "+f+".validate; } if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'string') || "),s+=" (",v!="ignore"&&(s+=" ("+d+" && !"+f+" ",h&&(s+=" && self._opts.unknownFormats.indexOf("+d+") == -1 "),s+=") || "),s+=" ("+f+" && "+g+" == '"+t+"' && !(typeof "+f+" == 'function' ? ",e.async?s+=" (async"+i+" ? await "+f+"("+p+") : "+f+"("+p+")) ":s+=" "+f+"("+p+") ",s+=" : "+f+".test("+p+"))))) {"}else{var f=e.formats[o];if(!f){if(v=="ignore")return e.logger.warn('unknown format "'+o+'" ignored in schema at path "'+e.errSchemaPath+'"'),u&&(s+=" if (true) { "),s;if(h&&v.indexOf(o)>=0)return u&&(s+=" if (true) { "),s;throw new Error('unknown format "'+o+'" is used in schema at path "'+e.errSchemaPath+'"')}var y=typeof f=="object"&&!(f instanceof RegExp)&&f.validate,g=y&&f.type||"string";if(y){var b=f.async===!0;f=f.validate}if(g!=t)return u&&(s+=" if (true) { "),s;if(b){if(!e.async)throw new Error("async format in sync schema");var w="formats"+e.util.getProperty(o)+".validate";s+=" if (!(await "+w+"("+p+"))) { "}else{s+=" if (! ";var w="formats"+e.util.getProperty(o);y&&(w+=".validate"),typeof f=="function"?s+=" "+w+"("+p+") ":s+=" "+w+".test("+p+") ",s+=") { "}}var P=P||[];P.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'format' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { format: ",m?s+=""+d:s+=""+e.util.toQuotedString(o),s+=" } ",e.opts.messages!==!1&&(s+=` , message: 'should match format "`,m?s+="' + "+d+" + '":s+=""+e.util.escapeQuotes(o),s+=`"' `),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+e.util.toQuotedString(o),s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var T=s;return s=P.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+T+"]); ":s+=" validate.errors = ["+T+"]; return false; ":s+=" var err = "+T+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } ",u&&(s+=" else { "),s}});var g_=U((J3,v_)=>{"use strict";v_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d="errs__"+i,v=e.util.copy(e);v.level++;var h="valid"+v.level,f=e.schema.then,y=e.schema.else,g=f!==void 0&&(e.opts.strictKeywords?typeof f=="object"&&Object.keys(f).length>0||f===!1:e.util.schemaHasRules(f,e.RULES.all)),b=y!==void 0&&(e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all)),w=v.baseId;if(g||b){var P;v.createErrors=!1,v.schema=o,v.schemaPath=l,v.errSchemaPath=c,s+=" var "+d+" = errors; var "+m+" = true; ";var T=e.compositeRule;e.compositeRule=v.compositeRule=!0,s+=" "+e.validate(v)+" ",v.baseId=w,v.createErrors=!0,s+=" errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; } ",e.compositeRule=v.compositeRule=T,g?(s+=" if ("+h+") { ",v.schema=e.schema.then,v.schemaPath=e.schemaPath+".then",v.errSchemaPath=e.errSchemaPath+"/then",s+=" "+e.validate(v)+" ",v.baseId=w,s+=" "+m+" = "+h+"; ",g&&b?(P="ifClause"+i,s+=" var "+P+" = 'then'; "):P="'then'",s+=" } ",b&&(s+=" else { ")):s+=" if (!"+h+") { ",b&&(v.schema=e.schema.else,v.schemaPath=e.schemaPath+".else",v.errSchemaPath=e.errSchemaPath+"/else",s+=" "+e.validate(v)+" ",v.baseId=w,s+=" "+m+" = "+h+"; ",g&&b?(P="ifClause"+i,s+=" var "+P+" = 'else'; "):P="'else'",s+=" } "),s+=" if (!"+m+") { var err = ",e.createErrors!==!1?(s+=" { keyword: 'if' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { failingKeyword: "+P+" } ",e.opts.messages!==!1&&(s+=` , message: 'should match "' + `+P+` + '" schema' `),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ",s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&u&&(e.async?s+=" throw new ValidationError(vErrors); ":s+=" validate.errors = vErrors; return false; "),s+=" } ",u&&(s+=" else { ")}else u&&(s+=" if (true) { ");return s}});var b_=U((eU,y_)=>{"use strict";y_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d="errs__"+i,v=e.util.copy(e),h="";v.level++;var f="valid"+v.level,y="i"+i,g=v.dataLevel=e.dataLevel+1,b="data"+g,w=e.baseId;if(s+="var "+d+" = errors;var "+m+";",Array.isArray(o)){var P=e.schema.additionalItems;if(P===!1){s+=" "+m+" = "+p+".length <= "+o.length+"; ";var T=c;c=e.errSchemaPath+"/additionalItems",s+=" if (!"+m+") { ";var k=k||[];k.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'additionalItems' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { limit: "+o.length+" } ",e.opts.messages!==!1&&(s+=" , message: 'should NOT have more than "+o.length+" items' "),e.opts.verbose&&(s+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var N=s;s=k.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+N+"]); ":s+=" validate.errors = ["+N+"]; return false; ":s+=" var err = "+N+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } ",c=T,u&&(h+="}",s+=" else { ")}var A=o;if(A){for(var $,D=-1,C=A.length-1;D0||$===!1:e.util.schemaHasRules($,e.RULES.all)){s+=" "+f+" = true; if ("+p+".length > "+D+") { ";var O=p+"["+D+"]";v.schema=$,v.schemaPath=l+"["+D+"]",v.errSchemaPath=c+"/"+D,v.errorPath=e.util.getPathExpr(e.errorPath,D,e.opts.jsonPointers,!0),v.dataPathArr[g]=D;var j=e.validate(v);v.baseId=w,e.util.varOccurences(j,b)<2?s+=" "+e.util.varReplace(j,b,O)+" ":s+=" var "+b+" = "+O+"; "+j+" ",s+=" } ",u&&(s+=" if ("+f+") { ",h+="}")}}if(typeof P=="object"&&(e.opts.strictKeywords?typeof P=="object"&&Object.keys(P).length>0||P===!1:e.util.schemaHasRules(P,e.RULES.all))){v.schema=P,v.schemaPath=e.schemaPath+".additionalItems",v.errSchemaPath=e.errSchemaPath+"/additionalItems",s+=" "+f+" = true; if ("+p+".length > "+o.length+") { for (var "+y+" = "+o.length+"; "+y+" < "+p+".length; "+y+"++) { ",v.errorPath=e.util.getPathExpr(e.errorPath,y,e.opts.jsonPointers,!0);var O=p+"["+y+"]";v.dataPathArr[g]=y;var j=e.validate(v);v.baseId=w,e.util.varOccurences(j,b)<2?s+=" "+e.util.varReplace(j,b,O)+" ":s+=" var "+b+" = "+O+"; "+j+" ",u&&(s+=" if (!"+f+") break; "),s+=" } } ",u&&(s+=" if ("+f+") { ",h+="}")}}else if(e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all)){v.schema=o,v.schemaPath=l,v.errSchemaPath=c,s+=" for (var "+y+" = 0; "+y+" < "+p+".length; "+y+"++) { ",v.errorPath=e.util.getPathExpr(e.errorPath,y,e.opts.jsonPointers,!0);var O=p+"["+y+"]";v.dataPathArr[g]=y;var j=e.validate(v);v.baseId=w,e.util.varOccurences(j,b)<2?s+=" "+e.util.varReplace(j,b,O)+" ":s+=" var "+b+" = "+O+"; "+j+" ",u&&(s+=" if (!"+f+") break; "),s+=" }"}return u&&(s+=" "+h+" if ("+d+" == errors) {"),s}});var $d=U((tU,x_)=>{"use strict";x_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,w,p="data"+(n||""),m=e.opts.$data&&o&&o.$data,d;m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o;var v=r=="maximum",h=v?"exclusiveMaximum":"exclusiveMinimum",f=e.schema[h],y=e.opts.$data&&f&&f.$data,g=v?"<":">",b=v?">":"<",w=void 0;if(!(m||typeof o=="number"||o===void 0))throw new Error(r+" must be number");if(!(y||f===void 0||typeof f=="number"||typeof f=="boolean"))throw new Error(h+" must be number or boolean");if(y){var P=e.util.getData(f.$data,n,e.dataPathArr),T="exclusive"+i,k="exclType"+i,N="exclIsNumber"+i,A="op"+i,$="' + "+A+" + '";s+=" var schemaExcl"+i+" = "+P+"; ",P="schemaExcl"+i,s+=" var "+T+"; var "+k+" = typeof "+P+"; if ("+k+" != 'boolean' && "+k+" != 'undefined' && "+k+" != 'number') { ";var w=h,D=D||[];D.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(w||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: {} ",e.opts.messages!==!1&&(s+=" , message: '"+h+" should be boolean' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var C=s;s=D.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+C+"]); ":s+=" validate.errors = ["+C+"]; return false; ":s+=" var err = "+C+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } else if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),s+=" "+k+" == 'number' ? ( ("+T+" = "+d+" === undefined || "+P+" "+g+"= "+d+") ? "+p+" "+b+"= "+P+" : "+p+" "+b+" "+d+" ) : ( ("+T+" = "+P+" === true) ? "+p+" "+b+"= "+d+" : "+p+" "+b+" "+d+" ) || "+p+" !== "+p+") { var op"+i+" = "+T+" ? '"+g+"' : '"+g+"='; ",o===void 0&&(w=h,c=e.errSchemaPath+"/"+h,d=P,m=y)}else{var N=typeof f=="number",$=g;if(N&&m){var A="'"+$+"'";s+=" if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),s+=" ( "+d+" === undefined || "+f+" "+g+"= "+d+" ? "+p+" "+b+"= "+f+" : "+p+" "+b+" "+d+" ) || "+p+" !== "+p+") { "}else{N&&o===void 0?(T=!0,w=h,c=e.errSchemaPath+"/"+h,d=f,b+="="):(N&&(d=Math[v?"min":"max"](f,o)),f===(N?d:!0)?(T=!0,w=h,c=e.errSchemaPath+"/"+h,b+="="):(T=!1,$+="="));var A="'"+$+"'";s+=" if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),s+=" "+p+" "+b+" "+d+" || "+p+" !== "+p+") { "}}w=w||r;var D=D||[];D.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(w||"_limit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { comparison: "+A+", limit: "+d+", exclusive: "+T+" } ",e.opts.messages!==!1&&(s+=" , message: 'should be "+$+" ",m?s+="' + "+d:s+=""+d+"'"),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+o,s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var C=s;return s=D.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+C+"]); ":s+=" validate.errors = ["+C+"]; return false; ":s+=" var err = "+C+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } ",u&&(s+=" else { "),s}});var Md=U((rU,__)=>{"use strict";__.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,h,p="data"+(n||""),m=e.opts.$data&&o&&o.$data,d;if(m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o,!(m||typeof o=="number"))throw new Error(r+" must be number");var v=r=="maxItems"?">":"<";s+="if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),s+=" "+p+".length "+v+" "+d+") { ";var h=r,f=f||[];f.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(h||"_limitItems")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { limit: "+d+" } ",e.opts.messages!==!1&&(s+=" , message: 'should NOT have ",r=="maxItems"?s+="more":s+="fewer",s+=" than ",m?s+="' + "+d+" + '":s+=""+o,s+=" items' "),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+o,s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var y=s;return s=f.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+y+"]); ":s+=" validate.errors = ["+y+"]; return false; ":s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+="} ",u&&(s+=" else { "),s}});var Ld=U((aU,S_)=>{"use strict";S_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,h,p="data"+(n||""),m=e.opts.$data&&o&&o.$data,d;if(m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o,!(m||typeof o=="number"))throw new Error(r+" must be number");var v=r=="maxLength"?">":"<";s+="if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),e.opts.unicode===!1?s+=" "+p+".length ":s+=" ucs2length("+p+") ",s+=" "+v+" "+d+") { ";var h=r,f=f||[];f.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(h||"_limitLength")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { limit: "+d+" } ",e.opts.messages!==!1&&(s+=" , message: 'should NOT be ",r=="maxLength"?s+="longer":s+="shorter",s+=" than ",m?s+="' + "+d+" + '":s+=""+o,s+=" characters' "),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+o,s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var y=s;return s=f.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+y+"]); ":s+=" validate.errors = ["+y+"]; return false; ":s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+="} ",u&&(s+=" else { "),s}});var Fd=U((sU,E_)=>{"use strict";E_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,h,p="data"+(n||""),m=e.opts.$data&&o&&o.$data,d;if(m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o,!(m||typeof o=="number"))throw new Error(r+" must be number");var v=r=="maxProperties"?">":"<";s+="if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),s+=" Object.keys("+p+").length "+v+" "+d+") { ";var h=r,f=f||[];f.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(h||"_limitProperties")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { limit: "+d+" } ",e.opts.messages!==!1&&(s+=" , message: 'should NOT have ",r=="maxProperties"?s+="more":s+="fewer",s+=" than ",m?s+="' + "+d+" + '":s+=""+o,s+=" properties' "),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+o,s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var y=s;return s=f.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+y+"]); ":s+=" validate.errors = ["+y+"]; return false; ":s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+="} ",u&&(s+=" else { "),s}});var T_=U((nU,w_)=>{"use strict";w_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m=e.opts.$data&&o&&o.$data,d;if(m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o,!(m||typeof o=="number"))throw new Error(r+" must be number");s+="var division"+i+";if (",m&&(s+=" "+d+" !== undefined && ( typeof "+d+" != 'number' || "),s+=" (division"+i+" = "+p+" / "+d+", ",e.opts.multipleOfPrecision?s+=" Math.abs(Math.round(division"+i+") - division"+i+") > 1e-"+e.opts.multipleOfPrecision+" ":s+=" division"+i+" !== parseInt(division"+i+") ",s+=" ) ",m&&(s+=" ) "),s+=" ) { ";var v=v||[];v.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'multipleOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { multipleOf: "+d+" } ",e.opts.messages!==!1&&(s+=" , message: 'should be multiple of ",m?s+="' + "+d:s+=""+d+"'"),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+o,s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var h=s;return s=v.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+h+"]); ":s+=" validate.errors = ["+h+"]; return false; ":s+=" var err = "+h+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+="} ",u&&(s+=" else { "),s}});var P_=U((iU,R_)=>{"use strict";R_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="errs__"+i,d=e.util.copy(e);d.level++;var v="valid"+d.level;if(e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all)){d.schema=o,d.schemaPath=l,d.errSchemaPath=c,s+=" var "+m+" = errors; ";var h=e.compositeRule;e.compositeRule=d.compositeRule=!0,d.createErrors=!1;var f;d.opts.allErrors&&(f=d.opts.allErrors,d.opts.allErrors=!1),s+=" "+e.validate(d)+" ",d.createErrors=!0,f&&(d.opts.allErrors=f),e.compositeRule=d.compositeRule=h,s+=" if ("+v+") { ";var y=y||[];y.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'not' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: {} ",e.opts.messages!==!1&&(s+=" , message: 'should NOT be valid' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var g=s;s=y.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+g+"]); ":s+=" validate.errors = ["+g+"]; return false; ":s+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } else { errors = "+m+"; if (vErrors !== null) { if ("+m+") vErrors.length = "+m+"; else vErrors = null; } ",e.opts.allErrors&&(s+=" } ")}else s+=" var err = ",e.createErrors!==!1?(s+=" { keyword: 'not' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: {} ",e.opts.messages!==!1&&(s+=" , message: 'should NOT be valid' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ",s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u&&(s+=" if (false) { ");return s}});var C_=U((oU,O_)=>{"use strict";O_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d="errs__"+i,v=e.util.copy(e),h="";v.level++;var f="valid"+v.level,y=v.baseId,g="prevValid"+i,b="passingSchemas"+i;s+="var "+d+" = errors , "+g+" = false , "+m+" = false , "+b+" = null; ";var w=e.compositeRule;e.compositeRule=v.compositeRule=!0;var P=o;if(P)for(var T,k=-1,N=P.length-1;k0||T===!1:e.util.schemaHasRules(T,e.RULES.all))?(v.schema=T,v.schemaPath=l+"["+k+"]",v.errSchemaPath=c+"/"+k,s+=" "+e.validate(v)+" ",v.baseId=y):s+=" var "+f+" = true; ",k&&(s+=" if ("+f+" && "+g+") { "+m+" = false; "+b+" = ["+b+", "+k+"]; } else { ",h+="}"),s+=" if ("+f+") { "+m+" = "+g+" = true; "+b+" = "+k+"; }";return e.compositeRule=v.compositeRule=w,s+=""+h+"if (!"+m+") { var err = ",e.createErrors!==!1?(s+=" { keyword: 'oneOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { passingSchemas: "+b+" } ",e.opts.messages!==!1&&(s+=" , message: 'should match exactly one schema in oneOf' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ",s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&u&&(e.async?s+=" throw new ValidationError(vErrors); ":s+=" validate.errors = vErrors; return false; "),s+="} else { errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; }",e.opts.allErrors&&(s+=" } "),s}});var A_=U((cU,k_)=>{"use strict";k_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m=e.opts.$data&&o&&o.$data,d;m?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",d="schema"+i):d=o;var v=m?"(new RegExp("+d+"))":e.usePattern(o);s+="if ( ",m&&(s+=" ("+d+" !== undefined && typeof "+d+" != 'string') || "),s+=" !"+v+".test("+p+") ) { ";var h=h||[];h.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'pattern' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { pattern: ",m?s+=""+d:s+=""+e.util.toQuotedString(o),s+=" } ",e.opts.messages!==!1&&(s+=` , message: 'should match pattern "`,m?s+="' + "+d+" + '":s+=""+e.util.escapeQuotes(o),s+=`"' `),e.opts.verbose&&(s+=" , schema: ",m?s+="validate.schema"+l:s+=""+e.util.toQuotedString(o),s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var f=s;return s=h.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+f+"]); ":s+=" validate.errors = ["+f+"]; return false; ":s+=" var err = "+f+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+="} ",u&&(s+=" else { "),s}});var D_=U((lU,I_)=>{"use strict";I_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="errs__"+i,d=e.util.copy(e),v="";d.level++;var h="valid"+d.level,f="key"+i,y="idx"+i,g=d.dataLevel=e.dataLevel+1,b="data"+g,w="dataProperties"+i,P=Object.keys(o||{}).filter(K),T=e.schema.patternProperties||{},k=Object.keys(T).filter(K),N=e.schema.additionalProperties,A=P.length||k.length,$=N===!1,D=typeof N=="object"&&Object.keys(N).length,C=e.opts.removeAdditional,O=$||D||C,j=e.opts.ownProperties,q=e.baseId,z=e.schema.required;if(z&&!(e.opts.$data&&z.$data)&&z.length8)s+=" || validate.schema"+l+".hasOwnProperty("+f+") ";else{var Z=P;if(Z)for(var X,se=-1,Y=Z.length-1;se0||_e===!1:e.util.schemaHasRules(_e,e.RULES.all)){var et=e.util.getProperty(X),Q=p+et,Ve=Te&&_e.default!==void 0;d.schema=_e,d.schemaPath=l+et,d.errSchemaPath=c+"/"+e.util.escapeFragment(X),d.errorPath=e.util.getPath(e.errorPath,X,e.opts.jsonPointers),d.dataPathArr[g]=e.util.toQuotedString(X);var ne=e.validate(d);if(d.baseId=q,e.util.varOccurences(ne,b)<2){ne=e.util.varReplace(ne,b,Q);var Qe=Q}else{var Qe=b;s+=" var "+b+" = "+Q+"; "}if(Ve)s+=" "+ne+" ";else{if(V&&V[X]){s+=" if ( "+Qe+" === undefined ",j&&(s+=" || ! Object.prototype.hasOwnProperty.call("+p+", '"+e.util.escapeQuotes(X)+"') "),s+=") { "+h+" = false; ";var De=e.errorPath,G=c,Ze=e.util.escapeQuotes(X);e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(De,X,e.opts.jsonPointers)),c=e.errSchemaPath+"/required";var te=te||[];te.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { missingProperty: '"+Ze+"' } ",e.opts.messages!==!1&&(s+=" , message: '",e.opts._errorDataPathProperty?s+="is a required property":s+="should have required property \\'"+Ze+"\\'",s+="' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var le=s;s=te.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+le+"]); ":s+=" validate.errors = ["+le+"]; return false; ":s+=" var err = "+le+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",c=G,e.errorPath=De,s+=" } else { "}else u?(s+=" if ( "+Qe+" === undefined ",j&&(s+=" || ! Object.prototype.hasOwnProperty.call("+p+", '"+e.util.escapeQuotes(X)+"') "),s+=") { "+h+" = true; } else { "):(s+=" if ("+Qe+" !== undefined ",j&&(s+=" && Object.prototype.hasOwnProperty.call("+p+", '"+e.util.escapeQuotes(X)+"') "),s+=" ) { ");s+=" "+ne+" } "}}u&&(s+=" if ("+h+") { ",v+="}")}}if(k.length){var Ke=k;if(Ke)for(var fe,St=-1,Et=Ke.length-1;St0||_e===!1:e.util.schemaHasRules(_e,e.RULES.all)){d.schema=_e,d.schemaPath=e.schemaPath+".patternProperties"+e.util.getProperty(fe),d.errSchemaPath=e.errSchemaPath+"/patternProperties/"+e.util.escapeFragment(fe),j?s+=" "+w+" = "+w+" || Object.keys("+p+"); for (var "+y+"=0; "+y+"<"+w+".length; "+y+"++) { var "+f+" = "+w+"["+y+"]; ":s+=" for (var "+f+" in "+p+") { ",s+=" if ("+e.usePattern(fe)+".test("+f+")) { ",d.errorPath=e.util.getPathExpr(e.errorPath,f,e.opts.jsonPointers);var Q=p+"["+f+"]";d.dataPathArr[g]=f;var ne=e.validate(d);d.baseId=q,e.util.varOccurences(ne,b)<2?s+=" "+e.util.varReplace(ne,b,Q)+" ":s+=" var "+b+" = "+Q+"; "+ne+" ",u&&(s+=" if (!"+h+") break; "),s+=" } ",u&&(s+=" else "+h+" = true; "),s+=" } ",u&&(s+=" if ("+h+") { ",v+="}")}}}return u&&(s+=" "+v+" if ("+m+" == errors) {"),s}});var j_=U((uU,N_)=>{"use strict";N_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="errs__"+i,d=e.util.copy(e),v="";d.level++;var h="valid"+d.level;if(s+="var "+m+" = errors;",e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all)){d.schema=o,d.schemaPath=l,d.errSchemaPath=c;var f="key"+i,y="idx"+i,g="i"+i,b="' + "+f+" + '",w=d.dataLevel=e.dataLevel+1,P="data"+w,T="dataProperties"+i,k=e.opts.ownProperties,N=e.baseId;k&&(s+=" var "+T+" = undefined; "),k?s+=" "+T+" = "+T+" || Object.keys("+p+"); for (var "+y+"=0; "+y+"<"+T+".length; "+y+"++) { var "+f+" = "+T+"["+y+"]; ":s+=" for (var "+f+" in "+p+") { ",s+=" var startErrs"+i+" = errors; ";var A=f,$=e.compositeRule;e.compositeRule=d.compositeRule=!0;var D=e.validate(d);d.baseId=N,e.util.varOccurences(D,P)<2?s+=" "+e.util.varReplace(D,P,A)+" ":s+=" var "+P+" = "+A+"; "+D+" ",e.compositeRule=d.compositeRule=$,s+=" if (!"+h+") { for (var "+g+"=startErrs"+i+"; "+g+"{"use strict";$_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d=e.opts.$data&&o&&o.$data,v;d?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",v="schema"+i):v=o;var h="schema"+i;if(!d)if(o.length0||P===!1:e.util.schemaHasRules(P,e.RULES.all))||(f[f.length]=g)}}else var f=o;if(d||f.length){var T=e.errorPath,k=d||f.length>=e.opts.loopRequired,N=e.opts.ownProperties;if(u)if(s+=" var missing"+i+"; ",k){d||(s+=" var "+h+" = validate.schema"+l+"; ");var A="i"+i,$="schema"+i+"["+A+"]",D="' + "+$+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(T,$,e.opts.jsonPointers)),s+=" var "+m+" = true; ",d&&(s+=" if (schema"+i+" === undefined) "+m+" = true; else if (!Array.isArray(schema"+i+")) "+m+" = false; else {"),s+=" for (var "+A+" = 0; "+A+" < "+h+".length; "+A+"++) { "+m+" = "+p+"["+h+"["+A+"]] !== undefined ",N&&(s+=" && Object.prototype.hasOwnProperty.call("+p+", "+h+"["+A+"]) "),s+="; if (!"+m+") break; } ",d&&(s+=" } "),s+=" if (!"+m+") { ";var C=C||[];C.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { missingProperty: '"+D+"' } ",e.opts.messages!==!1&&(s+=" , message: '",e.opts._errorDataPathProperty?s+="is a required property":s+="should have required property \\'"+D+"\\'",s+="' "),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var O=s;s=C.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+O+"]); ":s+=" validate.errors = ["+O+"]; return false; ":s+=" var err = "+O+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } else { "}else{s+=" if ( ";var j=f;if(j)for(var q,A=-1,z=j.length-1;A{"use strict";L_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p="data"+(n||""),m="valid"+i,d=e.opts.$data&&o&&o.$data,v;if(d?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",v="schema"+i):v=o,(o||d)&&e.opts.uniqueItems!==!1){d&&(s+=" var "+m+"; if ("+v+" === false || "+v+" === undefined) "+m+" = true; else if (typeof "+v+" != 'boolean') "+m+" = false; else { "),s+=" var i = "+p+".length , "+m+" = true , j; if (i > 1) { ";var h=e.schema.items&&e.schema.items.type,f=Array.isArray(h);if(!h||h=="object"||h=="array"||f&&(h.indexOf("object")>=0||h.indexOf("array")>=0))s+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+p+"[i], "+p+"[j])) { "+m+" = false; break outer; } } } ";else{s+=" var itemIndices = {}, item; for (;i--;) { var item = "+p+"[i]; ";var y="checkDataType"+(f?"s":"");s+=" if ("+e.util[y](h,"item",e.opts.strictNumbers,!0)+") continue; ",f&&(s+=` if (typeof item == 'string') item = '"' + item; `),s+=" if (typeof itemIndices[item] == 'number') { "+m+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}s+=" } ",d&&(s+=" } "),s+=" if (!"+m+") { ";var g=g||[];g.push(s),s="",e.createErrors!==!1?(s+=" { keyword: 'uniqueItems' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { i: i, j: j } ",e.opts.messages!==!1&&(s+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "),e.opts.verbose&&(s+=" , schema: ",d?s+="validate.schema"+l:s+=""+o,s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+p+" "),s+=" } "):s+=" {} ";var b=s;s=g.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+b+"]); ":s+=" validate.errors = ["+b+"]; return false; ":s+=" var err = "+b+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",s+=" } ",u&&(s+=" else { ")}else u&&(s+=" if (true) { ");return s}});var U_=U((fU,q_)=>{"use strict";q_.exports={$ref:J0(),allOf:t_(),anyOf:a_(),$comment:n_(),const:o_(),contains:l_(),dependencies:p_(),enum:f_(),format:h_(),if:g_(),items:b_(),maximum:$d(),minimum:$d(),maxItems:Md(),minItems:Md(),maxLength:Ld(),minLength:Ld(),maxProperties:Fd(),minProperties:Fd(),multipleOf:T_(),not:P_(),oneOf:C_(),pattern:A_(),properties:D_(),propertyNames:j_(),required:M_(),uniqueItems:F_(),validate:Nd()}});var z_=U((mU,B_)=>{"use strict";var H_=U_(),qd=_s().toHash;B_.exports=function(){var e=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}],r=["type","$comment"],t=["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"],s=["number","integer","string","array","object","boolean","null"];return e.all=qd(r),e.types=qd(s),e.forEach(function(i){i.rules=i.rules.map(function(n){var o;if(typeof n=="object"){var l=Object.keys(n)[0];o=n[l],n=l,o.forEach(function(u){r.push(u),e.all[u]=!0})}r.push(n);var c=e.all[n]={keyword:n,code:H_[n],implements:o};return c}),e.all.$comment={keyword:"$comment",code:H_.$comment},i.type&&(e.types[i.type]=i)}),e.keywords=qd(r.concat(t)),e.custom={},e}});var W_=U((hU,G_)=>{"use strict";var V_=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];G_.exports=function(a,e){for(var r=0;r{"use strict";var Oj=Bc().MissingRef;X_.exports=Z_;function Z_(a,e,r){var t=this;if(typeof this._opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");typeof e=="function"&&(r=e,e=void 0);var s=i(a).then(function(){var o=t._addSchema(a,void 0,e);return o.validate||n(o)});return r&&s.then(function(o){r(null,o)},r),s;function i(o){var l=o.$schema;return l&&!t.getSchema(l)?Z_.call(t,{$ref:l},!0):Promise.resolve()}function n(o){try{return t._compile(o)}catch(c){if(c instanceof Oj)return l(c);throw c}function l(c){var u=c.missingSchema;if(d(u))throw new Error("Schema "+u+" is loaded but "+c.missingRef+" cannot be resolved");var p=t._loadingSchemas[u];return p||(p=t._loadingSchemas[u]=t._opts.loadSchema(u),p.then(m,m)),p.then(function(v){if(!d(u))return i(v).then(function(){d(u)||t.addSchema(v,u,void 0,e)})}).then(function(){return n(o)});function m(){delete t._loadingSchemas[u]}function d(v){return t._refs[v]||t._schemas[v]}}}}});var Y_=U((gU,Q_)=>{"use strict";Q_.exports=function(e,r,t){var s=" ",i=e.level,n=e.dataLevel,o=e.schema[r],l=e.schemaPath+e.util.getProperty(r),c=e.errSchemaPath+"/"+r,u=!e.opts.allErrors,p,m="data"+(n||""),d="valid"+i,v="errs__"+i,h=e.opts.$data&&o&&o.$data,f;h?(s+=" var schema"+i+" = "+e.util.getData(o.$data,n,e.dataPathArr)+"; ",f="schema"+i):f=o;var y=this,g="definition"+i,b=y.definition,w="",P,T,k,N,A;if(h&&b.$data){A="keywordValidate"+i;var $=b.validateSchema;s+=" var "+g+" = RULES.custom['"+r+"'].definition; var "+A+" = "+g+".validate;"}else{if(N=e.useCustomRule(y,o,e.schema,e),!N)return;f="validate.schema"+l,A=N.code,P=b.compile,T=b.inline,k=b.macro}var D=A+".errors",C="i"+i,O="ruleErr"+i,j=b.async;if(j&&!e.async)throw new Error("async keyword in sync schema");if(T||k||(s+=""+D+" = null;"),s+="var "+v+" = errors;var "+d+";",h&&b.$data&&(w+="}",s+=" if ("+f+" === undefined) { "+d+" = true; } else { ",$&&(w+="}",s+=" "+d+" = "+g+".validateSchema("+f+"); if ("+d+") { ")),T)b.statements?s+=" "+N.validate+" ":s+=" "+d+" = "+N.validate+"; ";else if(k){var q=e.util.copy(e),w="";q.level++;var z="valid"+q.level;q.schema=N.validate,q.schemaPath="";var V=e.compositeRule;e.compositeRule=q.compositeRule=!0;var K=e.validate(q).replace(/validate\.schema/g,A);e.compositeRule=q.compositeRule=V,s+=" "+K}else{var Z=Z||[];Z.push(s),s="",s+=" "+A+".call( ",e.opts.passContext?s+="this":s+="self",P||b.schema===!1?s+=" , "+m+" ":s+=" , "+f+" , "+m+" , validate.schema"+e.schemaPath+" ",s+=" , (dataPath || '')",e.errorPath!='""'&&(s+=" + "+e.errorPath);var X=n?"data"+(n-1||""):"parentData",se=n?e.dataPathArr[n]:"parentDataProperty";s+=" , "+X+" , "+se+" , rootData ) ";var Y=s;s=Z.pop(),b.errors===!1?(s+=" "+d+" = ",j&&(s+="await "),s+=""+Y+"; "):j?(D="customErrors"+i,s+=" var "+D+" = null; try { "+d+" = await "+Y+"; } catch (e) { "+d+" = false; if (e instanceof ValidationError) "+D+" = e.errors; else throw e; } "):s+=" "+D+" = null; "+d+" = "+Y+"; "}if(b.modifying&&(s+=" if ("+X+") "+m+" = "+X+"["+se+"];"),s+=""+w,b.valid)u&&(s+=" if (true) { ");else{s+=" if ( ",b.valid===void 0?(s+=" !",k?s+=""+z:s+=""+d):s+=" "+!b.valid+" ",s+=") { ",p=y.keyword;var Z=Z||[];Z.push(s),s="";var Z=Z||[];Z.push(s),s="",e.createErrors!==!1?(s+=" { keyword: '"+(p||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(c)+" , params: { keyword: '"+y.keyword+"' } ",e.opts.messages!==!1&&(s+=` , message: 'should pass "`+y.keyword+`" keyword validation' `),e.opts.verbose&&(s+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+m+" "),s+=" } "):s+=" {} ";var Pe=s;s=Z.pop(),!e.compositeRule&&u?e.async?s+=" throw new ValidationError(["+Pe+"]); ":s+=" validate.errors = ["+Pe+"]; return false; ":s+=" var err = "+Pe+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";var fe=s;s=Z.pop(),T?b.errors?b.errors!="full"&&(s+=" for (var "+C+"="+v+"; "+C+"{Cj.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var tS=U((bU,eS)=>{"use strict";var J_=Ud();eS.exports={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:J_.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:J_.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}}});var aS=U((xU,rS)=>{"use strict";var kj=/^[a-z_$][a-z0-9_$-]*$/i,Aj=Y_(),Ij=tS();rS.exports={add:Dj,get:Nj,remove:jj,validate:Hd};function Dj(a,e){var r=this.RULES;if(r.keywords[a])throw new Error("Keyword "+a+" is already defined");if(!kj.test(a))throw new Error("Keyword "+a+" is not a valid identifier");if(e){this.validateKeyword(e,!0);var t=e.type;if(Array.isArray(t))for(var s=0;s{$j.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON Schema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var mS=U((SU,fS)=>{"use strict";var iS=M0(),Ss=Hc(),Mj=F0(),oS=Pd(),Lj=Dd(),Fj=Q0(),qj=z_(),cS=W_(),lS=_s();fS.exports=dt;dt.prototype.validate=Hj;dt.prototype.compile=Bj;dt.prototype.addSchema=zj;dt.prototype.addMetaSchema=Vj;dt.prototype.validateSchema=Gj;dt.prototype.getSchema=Zj;dt.prototype.removeSchema=Kj;dt.prototype.addFormat=s$;dt.prototype.errorsText=a$;dt.prototype._addSchema=Qj;dt.prototype._compile=Yj;dt.prototype.compileAsync=K_();var Qc=aS();dt.prototype.addKeyword=Qc.add;dt.prototype.getKeyword=Qc.get;dt.prototype.removeKeyword=Qc.remove;dt.prototype.validateKeyword=Qc.validate;var uS=Bc();dt.ValidationError=uS.Validation;dt.MissingRefError=uS.MissingRef;dt.$dataMetaSchema=cS;var Kc="http://json-schema.org/draft-07/schema",nS=["removeAdditional","useDefaults","coerceTypes","strictDefaults"],Uj=["/properties"];function dt(a){if(!(this instanceof dt))return new dt(a);a=this._opts=lS.copy(a)||{},u$(this),this._schemas={},this._refs={},this._fragments={},this._formats=Fj(a.format),this._cache=a.cache||new Mj,this._loadingSchemas={},this._compilations=[],this.RULES=qj(),this._getId=Jj(a),a.loopRequired=a.loopRequired||1/0,a.errorDataPath=="property"&&(a._errorDataPathProperty=!0),a.serialize===void 0&&(a.serialize=Lj),this._metaOpts=l$(this),a.formats&&o$(this),a.keywords&&c$(this),n$(this),typeof a.meta=="object"&&this.addMetaSchema(a.meta),a.nullable&&this.addKeyword("nullable",{metaSchema:{type:"boolean"}}),i$(this)}function Hj(a,e){var r;if(typeof a=="string"){if(r=this.getSchema(a),!r)throw new Error('no schema with key or ref "'+a+'"')}else{var t=this._addSchema(a);r=t.validate||this._compile(t)}var s=r(e);return r.$async!==!0&&(this.errors=r.errors),s}function Bj(a,e){var r=this._addSchema(a,void 0,e);return r.validate||this._compile(r)}function zj(a,e,r,t){if(Array.isArray(a)){for(var s=0;s{bS.exports=yS;yS.sync=d$;var vS=require("fs");function p$(a,e){var r=e.pathExt!==void 0?e.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var t=0;t{wS.exports=SS;SS.sync=f$;var _S=require("fs");function SS(a,e,r){_S.stat(a,function(t,s){r(t,t?!1:ES(s,e))})}function f$(a,e){return ES(_S.statSync(a),e)}function ES(a,e){return a.isFile()&&m$(a,e)}function m$(a,e){var r=a.mode,t=a.uid,s=a.gid,i=e.uid!==void 0?e.uid:process.getuid&&process.getuid(),n=e.gid!==void 0?e.gid:process.getgid&&process.getgid(),o=parseInt("100",8),l=parseInt("010",8),c=parseInt("001",8),u=o|l,p=r&c||r&l&&s===n||r&o&&t===i||r&u&&i===0;return p}});var PS=U((CU,RS)=>{var OU=require("fs"),Yc;process.platform==="win32"||global.TESTING_WINDOWS?Yc=xS():Yc=TS();RS.exports=zd;zd.sync=h$;function zd(a,e,r){if(typeof e=="function"&&(r=e,e={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(t,s){zd(a,e||{},function(i,n){i?s(i):t(n)})})}Yc(a,e||{},function(t,s){t&&(t.code==="EACCES"||e&&e.ignoreErrors)&&(t=null,s=!1),r(t,s)})}function h$(a,e){try{return Yc.sync(a,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var NS=U((kU,DS)=>{var In=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",OS=require("path"),v$=In?";":":",CS=PS(),kS=a=>Object.assign(new Error(`not found: ${a}`),{code:"ENOENT"}),AS=(a,e)=>{let r=e.colon||v$,t=a.match(/\//)||In&&a.match(/\\/)?[""]:[...In?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],s=In?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",i=In?s.split(r):[""];return In&&a.indexOf(".")!==-1&&i[0]!==""&&i.unshift(""),{pathEnv:t,pathExt:i,pathExtExe:s}},IS=(a,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:t,pathExt:s,pathExtExe:i}=AS(a,e),n=[],o=c=>new Promise((u,p)=>{if(c===t.length)return e.all&&n.length?u(n):p(kS(a));let m=t[c],d=/^".*"$/.test(m)?m.slice(1,-1):m,v=OS.join(d,a),h=!d&&/^\.[\\\/]/.test(a)?a.slice(0,2)+v:v;u(l(h,c,0))}),l=(c,u,p)=>new Promise((m,d)=>{if(p===s.length)return m(o(u+1));let v=s[p];CS(c+v,{pathExt:i},(h,f)=>{if(!h&&f)if(e.all)n.push(c+v);else return m(c+v);return m(l(c,u,p+1))})});return r?o(0).then(c=>r(null,c),r):o(0)},g$=(a,e)=>{e=e||{};let{pathEnv:r,pathExt:t,pathExtExe:s}=AS(a,e),i=[];for(let n=0;n{"use strict";var jS=(a={})=>{let e=a.env||process.env;return(a.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(t=>t.toUpperCase()==="PATH")||"Path"};Vd.exports=jS;Vd.exports.default=jS});var qS=U((IU,FS)=>{"use strict";var MS=require("path"),y$=NS(),b$=$S();function LS(a,e){let r=a.options.env||process.env,t=process.cwd(),s=a.options.cwd!=null,i=s&&process.chdir!==void 0&&!process.chdir.disabled;if(i)try{process.chdir(a.options.cwd)}catch{}let n;try{n=y$.sync(a.command,{path:r[b$({env:r})],pathExt:e?MS.delimiter:void 0})}catch{}finally{i&&process.chdir(t)}return n&&(n=MS.resolve(s?a.options.cwd:"",n)),n}function x$(a){return LS(a)||LS(a,!0)}FS.exports=x$});var US=U((DU,Wd)=>{"use strict";var Gd=/([()\][%!^"`<>&|;, *?])/g;function _$(a){return a=a.replace(Gd,"^$1"),a}function S$(a,e){return a=`${a}`,a=a.replace(/(?=(\\+?)?)\1"/g,'$1$1\\"'),a=a.replace(/(?=(\\+?)?)\1$/,"$1$1"),a=`"${a}"`,a=a.replace(Gd,"^$1"),e&&(a=a.replace(Gd,"^$1")),a}Wd.exports.command=_$;Wd.exports.argument=S$});var BS=U((NU,HS)=>{"use strict";HS.exports=/^#!(.*)/});var VS=U((jU,zS)=>{"use strict";var E$=BS();zS.exports=(a="")=>{let e=a.match(E$);if(!e)return null;let[r,t]=e[0].replace(/#! ?/,"").split(" "),s=r.split("/").pop();return s==="env"?t:t?`${s} ${t}`:s}});var WS=U(($U,GS)=>{"use strict";var Zd=require("fs"),w$=VS();function T$(a){let r=Buffer.alloc(150),t;try{t=Zd.openSync(a,"r"),Zd.readSync(t,r,0,150,0),Zd.closeSync(t)}catch{}return w$(r.toString())}GS.exports=T$});var QS=U((MU,KS)=>{"use strict";var R$=require("path"),ZS=qS(),XS=US(),P$=WS(),O$=process.platform==="win32",C$=/\.(?:com|exe)$/i,k$=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function A$(a){a.file=ZS(a);let e=a.file&&P$(a.file);return e?(a.args.unshift(a.file),a.command=e,ZS(a)):a.file}function I$(a){if(!O$)return a;let e=A$(a),r=!C$.test(e);if(a.options.forceShell||r){let t=k$.test(e);a.command=R$.normalize(a.command),a.command=XS.command(a.command),a.args=a.args.map(i=>XS.argument(i,t));let s=[a.command].concat(a.args).join(" ");a.args=["/d","/s","/c",`"${s}"`],a.command=process.env.comspec||"cmd.exe",a.options.windowsVerbatimArguments=!0}return a}function D$(a,e,r){e&&!Array.isArray(e)&&(r=e,e=null),e=e?e.slice(0):[],r=Object.assign({},r);let t={command:a,args:e,options:r,file:void 0,original:{command:a,args:e}};return r.shell?t:I$(t)}KS.exports=D$});var eE=U((LU,JS)=>{"use strict";var Xd=process.platform==="win32";function Kd(a,e){return Object.assign(new Error(`${e} ${a.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${e} ${a.command}`,path:a.command,spawnargs:a.args})}function N$(a,e){if(!Xd)return;let r=a.emit;a.emit=function(t,s){if(t==="exit"){let i=YS(s,e);if(i)return r.call(a,"error",i)}return r.apply(a,arguments)}}function YS(a,e){return Xd&&a===1&&!e.file?Kd(e.original,"spawn"):null}function j$(a,e){return Xd&&a===1&&!e.file?Kd(e.original,"spawnSync"):null}JS.exports={hookChildProcess:N$,verifyENOENT:YS,verifyENOENTSync:j$,notFoundError:Kd}});var aE=U((FU,Dn)=>{"use strict";var tE=require("child_process"),Qd=QS(),Yd=eE();function rE(a,e,r){let t=Qd(a,e,r),s=tE.spawn(t.command,t.args,t.options);return Yd.hookChildProcess(s,t),s}function $$(a,e,r){let t=Qd(a,e,r),s=tE.spawnSync(t.command,t.args,t.options);return s.error=s.error||Yd.verifyENOENTSync(s.status,t),s}Dn.exports=rE;Dn.exports.spawn=rE;Dn.exports.sync=$$;Dn.exports._parse=Qd;Dn.exports._enoent=Yd});var jn,$n,oE,cE,lE,uE,el=Zs(()=>{"use strict";jn=["bugfix","feature","refactor","discovery","decision","change"],$n=["how-it-works","why-it-exists","what-changed","problem-solution","gotcha","pattern","trade-off"],oE={bugfix:"\u{1F534}",feature:"\u{1F7E3}",refactor:"\u{1F504}",change:"\u2705",discovery:"\u{1F535}",decision:"\u2696\uFE0F","session-request":"\u{1F3AF}"},cE={discovery:"\u{1F50D}",change:"\u{1F6E0}\uFE0F",feature:"\u{1F6E0}\uFE0F",bugfix:"\u{1F6E0}\uFE0F",refactor:"\u{1F6E0}\uFE0F",decision:"\u2696\uFE0F"},lE=jn.join(","),uE=$n.join(",")});var Mn,pE,dE,lt,oa=Zs(()=>{"use strict";Mn=require("fs"),pE=require("path"),dE=require("os");el();ft();lt=class{static DEFAULTS={CLAUDE_MEM_MODEL:"claude-haiku-4-5",CLAUDE_MEM_CONTEXT_OBSERVATIONS:"50",CLAUDE_MEM_WORKER_PORT:"37777",CLAUDE_MEM_WORKER_HOST:"127.0.0.1",CLAUDE_MEM_SKIP_TOOLS:"ListMcpResourcesTool,SlashCommand,Skill,TodoWrite,AskUserQuestion",CLAUDE_MEM_DATA_DIR:(0,pE.join)((0,dE.homedir)(),".claude-mem"),CLAUDE_MEM_LOG_LEVEL:"INFO",CLAUDE_MEM_PYTHON_VERSION:"3.13",CLAUDE_CODE_PATH:"",CLAUDE_MEM_CONTEXT_SHOW_READ_TOKENS:"true",CLAUDE_MEM_CONTEXT_SHOW_WORK_TOKENS:"true",CLAUDE_MEM_CONTEXT_SHOW_SAVINGS_AMOUNT:"true",CLAUDE_MEM_CONTEXT_SHOW_SAVINGS_PERCENT:"true",CLAUDE_MEM_CONTEXT_OBSERVATION_TYPES:lE,CLAUDE_MEM_CONTEXT_OBSERVATION_CONCEPTS:uE,CLAUDE_MEM_CONTEXT_FULL_COUNT:"5",CLAUDE_MEM_CONTEXT_FULL_FIELD:"narrative",CLAUDE_MEM_CONTEXT_SESSION_COUNT:"10",CLAUDE_MEM_CONTEXT_SHOW_LAST_SUMMARY:"true",CLAUDE_MEM_CONTEXT_SHOW_LAST_MESSAGE:"false"};static getAllDefaults(){return{...this.DEFAULTS}}static get(e){return this.DEFAULTS[e]}static getInt(e){let r=this.get(e);return parseInt(r,10)}static getBool(e){return this.get(e)==="true"}static loadFromFile(e){if(!(0,Mn.existsSync)(e))return this.getAllDefaults();let r=(0,Mn.readFileSync)(e,"utf-8"),t=JSON.parse(r),s=t;if(t.env&&typeof t.env=="object"){s=t.env;try{(0,Mn.writeFileSync)(e,JSON.stringify(s,null,2),"utf-8"),M.info("SETTINGS","Migrated settings file from nested to flat schema",{settingsPath:e})}catch(n){M.warn("SETTINGS","Failed to auto-migrate settings file",{settingsPath:e},n)}}let i={...this.DEFAULTS};for(let n of Object.keys(this.DEFAULTS))s[n]!==void 0&&(i[n]=s[n]);return i}}});var Jd,ef,M,ft=Zs(()=>{"use strict";oa();Jd=(i=>(i[i.DEBUG=0]="DEBUG",i[i.INFO=1]="INFO",i[i.WARN=2]="WARN",i[i.ERROR=3]="ERROR",i[i.SILENT=4]="SILENT",i))(Jd||{}),ef=class{level=null;useColor;constructor(){this.useColor=process.stdout.isTTY??!1}getLevel(){if(this.level===null){let e=lt.get("CLAUDE_MEM_LOG_LEVEL").toUpperCase();this.level=Jd[e]??1}return this.level}correlationId(e,r){return`obs-${e}-${r}`}sessionId(e){return`session-${e}`}formatData(e){if(e==null)return"";if(typeof e=="string")return e;if(typeof e=="number"||typeof e=="boolean")return e.toString();if(typeof e=="object"){if(e instanceof Error)return this.getLevel()===0?`${e.message} -${e.stack}`:e.message;if(Array.isArray(e))return`[${e.length} items]`;let r=Object.keys(e);return r.length===0?"{}":r.length<=3?JSON.stringify(e):`{${r.length} keys: ${r.slice(0,3).join(", ")}...}`}return String(e)}formatTool(e,r){if(!r)return e;try{let t=typeof r=="string"?JSON.parse(r):r;if(e==="Bash"&&t.command){let s=t.command.length>50?t.command.substring(0,50)+"...":t.command;return`${e}(${s})`}if(e==="Read"&&t.file_path){let s=t.file_path.split("/").pop()||t.file_path;return`${e}(${s})`}if(e==="Edit"&&t.file_path){let s=t.file_path.split("/").pop()||t.file_path;return`${e}(${s})`}if(e==="Write"&&t.file_path){let s=t.file_path.split("/").pop()||t.file_path;return`${e}(${s})`}return e}catch{return e}}log(e,r,t,s,i){if(e50?t.command.substring(0,50)+"...":t.command;return`${e}(${s})`}if(e==="Read"&&t.file_path){let s=t.file_path.split("/").pop()||t.file_path;return`${e}(${s})`}if(e==="Edit"&&t.file_path){let s=t.file_path.split("/").pop()||t.file_path;return`${e}(${s})`}if(e==="Write"&&t.file_path){let s=t.file_path.split("/").pop()||t.file_path;return`${e}(${s})`}return e}catch{return e}}formatTimestamp(e){let r=e.getFullYear(),t=String(e.getMonth()+1).padStart(2,"0"),s=String(e.getDate()).padStart(2,"0"),i=String(e.getHours()).padStart(2,"0"),n=String(e.getMinutes()).padStart(2,"0"),o=String(e.getSeconds()).padStart(2,"0"),l=String(e.getMilliseconds()).padStart(3,"0");return`${r}-${t}-${s} ${i}:${n}:${o}.${l}`}log(e,r,t,s,i){if(e0&&(p=` {${Object.entries(f).map(([g,b])=>`${g}=${b}`).join(", ")}}`)}let m=`[${n}] [${o}] [${l}] ${c}${t}${p}${u}`;e===3?console.error(m):console.log(m)}debug(e,r,t,s){this.log(0,e,r,t,s)}info(e,r,t,s){this.log(1,e,r,t,s)}warn(e,r,t,s){this.log(2,e,r,t,s)}error(e,r,t,s){this.log(3,e,r,t,s)}dataIn(e,r,t,s){this.info(e,`\u2192 ${r}`,t,s)}dataOut(e,r,t,s){this.info(e,`\u2190 ${r}`,t,s)}success(e,r,t,s){this.info(e,`\u2713 ${r}`,t,s)}failure(e,r,t,s){this.error(e,`\u2717 ${r}`,t,s)}timing(e,r,t,s){this.info(e,`\u23F1 ${r}`,s,{duration:`${t}ms`})}},M=new ef});function U$(){return typeof __dirname<"u"?__dirname:(0,kt.dirname)((0,vE.fileURLToPath)(B$.url))}function rl(a){(0,hE.mkdirSync)(a,{recursive:!0})}function ca(){return(0,kt.join)(H$,"..","..")}var kt,mE,hE,vE,B$,H$,Vt,rf,eH,tH,rH,aH,Ln,tl,sH,nH,iH,oH,Ar=Zs(()=>{"use strict";kt=require("path"),mE=require("os"),hE=require("fs"),vE=require("url");oa();B$={};H$=U$(),Vt=lt.get("CLAUDE_MEM_DATA_DIR"),rf=process.env.CLAUDE_CONFIG_DIR||(0,kt.join)((0,mE.homedir)(),".claude"),eH=(0,kt.join)(Vt,"archives"),tH=(0,kt.join)(Vt,"logs"),rH=(0,kt.join)(Vt,"trash"),aH=(0,kt.join)(Vt,"backups"),Ln=(0,kt.join)(Vt,"settings.json"),tl=(0,kt.join)(Vt,"claude-mem.db"),sH=(0,kt.join)(Vt,"vector-db"),nH=(0,kt.join)(rf,"settings.json"),iH=(0,kt.join)(rf,"commands"),oH=(0,kt.join)(rf,"CLAUDE.md")});var xE,$a,nl=Zs(()=>{"use strict";xE=require("bun:sqlite");Ar();ft();$a=class{db;constructor(){rl(Vt),this.db=new xE.Database(tl),this.db.run("PRAGMA journal_mode = WAL"),this.db.run("PRAGMA synchronous = NORMAL"),this.db.run("PRAGMA foreign_keys = ON"),this.initializeSchema(),this.ensureWorkerPortColumn(),this.ensurePromptTrackingColumns(),this.removeSessionSummariesUniqueConstraint(),this.addObservationHierarchicalFields(),this.makeObservationsTextNullable(),this.createUserPromptsTable(),this.ensureDiscoveryTokensColumn()}initializeSchema(){try{this.db.run(` CREATE TABLE IF NOT EXISTS schema_versions ( id INTEGER PRIMARY KEY, diff --git a/src/utils/logger.ts b/src/utils/logger.ts index 834063c0..ebd1f60b 100644 --- a/src/utils/logger.ts +++ b/src/utils/logger.ts @@ -131,6 +131,20 @@ class Logger { } } + /** + * Format timestamp in local timezone (YYYY-MM-DD HH:MM:SS.mmm) + */ + private formatTimestamp(date: Date): string { + const year = date.getFullYear(); + const month = String(date.getMonth() + 1).padStart(2, '0'); + const day = String(date.getDate()).padStart(2, '0'); + const hours = String(date.getHours()).padStart(2, '0'); + const minutes = String(date.getMinutes()).padStart(2, '0'); + const seconds = String(date.getSeconds()).padStart(2, '0'); + const ms = String(date.getMilliseconds()).padStart(3, '0'); + return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}.${ms}`; + } + /** * Core logging method */ @@ -143,7 +157,7 @@ class Logger { ): void { if (level < this.getLevel()) return; - const timestamp = new Date().toISOString().replace('T', ' ').substring(0, 23); + const timestamp = this.formatTimestamp(new Date()); const levelStr = LogLevel[level].padEnd(5); const componentStr = component.padEnd(6);