mirror of
https://github.com/pnpm/action-setup.git
synced 2024-12-23 00:06:30 +08:00
d8ea532ac4
close #22
1 line
430 KiB
JavaScript
1 line
430 KiB
JavaScript
module.exports=(()=>{var __webpack_modules__={2492:e=>{"use strict";e.exports=JSON.parse('{"anyOf":[{"$ref":"#/definitions/RunInstall"},{"type":"array","items":{"$ref":"#/definitions/RunInstall"}},{"type":["null","boolean"]}],"definitions":{"RunInstall":{"type":"object","properties":{"recursive":{"type":"boolean"},"cwd":{"type":"string"},"args":{"type":"array","items":{"type":"string"}}}}},"$schema":"http://json-schema.org/draft-07/schema#"}')},6152:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});const i=r(6105);const f=s(r(539));const l=s(r(7701));const t=s(r(9875));const o=s(r(4882));const c=s(r(4424));async function main(){const e=(0,f.default)();const n=(0,i.getState)("is_post");if(n==="true")return(0,c.default)(e);(0,i.saveState)("is_post","true");await(0,t.default)(e);console.log("Installation Completed!");(0,l.default)(e);(0,o.default)(e)}main().catch(e=>{console.error(e);(0,i.setFailed)(e)})},539:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.getInputs=void 0;const i=r(6105);const f=s(r(9413));const l=r(4019);const t={required:true};const o=e=>(0,f.default)((0,i.getInput)(e,t));const c=()=>({version:(0,i.getInput)("version",t),dest:o("dest"),runInstall:(0,l.parseRunInstall)("run_install")});n.getInputs=c;n.default=n.getInputs},4019:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.parseRunInstall=void 0;const i=s(r(1765));const f=r(6070);const l=s(r(6562));const t=r(6105);const o=s(r(2492));const c={required:true};function parseRunInstall(e){const n=(0,f.load)((0,t.getInput)(e,c));const r=new l.default({allErrors:true});const s=r.compile(o.default);if(!s(n)){for(const e of s.errors){(0,t.error)(`with.run_install${e.dataPath}: ${e.message}`)}return i.default.exit(1)}if(!n)return[];if(n===true)return[{recursive:true}];if(Array.isArray(n))return n;return[n]}n.parseRunInstall=parseRunInstall},9875:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.install=n.runSelfInstaller=void 0;const i=r(6105);const f=s(r(7529));n.runSelfInstaller=f.default;async function install(e){(0,i.startGroup)("Running self-installer...");const n=await(0,f.default)(e);(0,i.endGroup)();if(n){return(0,i.setFailed)(`Something went wrong, self-installer exits with code ${n}`)}}n.install=install;n.default=install},7529:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.runSelfInstaller=void 0;const i=r(6105);const f=r(3129);const l=r(1765);const t=s(r(5622));const o=r(4982);const c=s(r(1868));async function runSelfInstaller(e){const{version:n,dest:r}=e;const s=n?`pnpm@${n}`:"pnpm";const a=t.default.join(r,"package.json");await(0,o.remove)(r);await(0,o.ensureFile)(a);await(0,o.writeFile)(a,JSON.stringify({private:true}));const d=(0,f.spawn)(l.execPath,["-","install",s,"--no-lockfile"],{cwd:r,stdio:["pipe","inherit","inherit"]});const p=await(0,c.default)("https://get.pnpm.io/v6.16.js");if(!p.body)throw new Error("Did not receive response body");p.body.pipe(d.stdin);const u=await new Promise((e,n)=>{d.on("error",n);d.on("close",e)});if(u===0){const e=t.default.join(r,"node_modules/.bin");(0,i.addPath)(e);(0,i.exportVariable)("PNPM_HOME",e)}return u}n.runSelfInstaller=runSelfInstaller;n.default=runSelfInstaller},7701:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.setOutputs=void 0;const s=r(6105);const i=r(6656);function setOutputs(e){const n=(0,i.getBinDest)(e);(0,s.addPath)(n);(0,s.setOutput)("dest",e.dest);(0,s.setOutput)("bin_dest",n)}n.setOutputs=setOutputs;n.default=setOutputs},4882:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.runPnpmInstall=void 0;const s=r(3129);const i=r(6105);const f=r(6656);function runPnpmInstall(e){const n=(0,f.patchPnpmEnv)(e);for(const r of e.runInstall){const e=["install"];if(r.recursive)e.unshift("recursive");if(r.args)e.push(...r.args);const f=["pnpm",...e].join(" ");(0,i.startGroup)(`Running ${f}...`);const{error:l,status:t}=(0,s.spawnSync)("pnpm",e,{stdio:"inherit",cwd:r.cwd,shell:true,env:n});(0,i.endGroup)();if(l){(0,i.setFailed)(l);continue}if(t){(0,i.setFailed)(`Command ${f} (cwd: ${r.cwd}) exits with status ${t}`);continue}}}n.runPnpmInstall=runPnpmInstall;n.default=runPnpmInstall},4424:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.pruneStore=void 0;const s=r(3129);const i=r(6105);const f=r(6656);function pruneStore(e){if(e.runInstall.length===0){console.log("Pruning is unnecessary.");return}(0,i.startGroup)("Running pnpm store prune...");const{error:n,status:r}=(0,s.spawnSync)("pnpm",["store","prune"],{stdio:"inherit",shell:true,env:(0,f.patchPnpmEnv)(e)});(0,i.endGroup)();if(n){(0,i.warning)(n);return}if(r){(0,i.warning)(`command pnpm store prune exits with code ${r}`);return}}n.pruneStore=pruneStore;n.default=pruneStore},6656:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.patchPnpmEnv=n.getBinDest=void 0;const i=s(r(1765));const f=s(r(5622));const l=e=>f.default.join(e.dest,"node_modules",".bin");n.getBinDest=l;const t=e=>({...i.default.env,PATH:(0,n.getBinDest)(e)+f.default.delimiter+i.default.env.PATH});n.patchPnpmEnv=t},5791:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:true,value:n})}:function(e,n){e["default"]=n});var f=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(n,e,r);i(n,e);return n};Object.defineProperty(n,"__esModule",{value:true});n.issue=n.issueCommand=void 0;const l=f(r(2087));const t=r(1831);function issueCommand(e,n,r){const s=new Command(e,n,r);process.stdout.write(s.toString()+l.EOL)}n.issueCommand=issueCommand;function issue(e,n=""){issueCommand(e,{},n)}n.issue=issue;const o="::";class Command{constructor(e,n,r){if(!e){e="missing.command"}this.command=e;this.properties=n;this.message=r}toString(){let e=o+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let n=true;for(const r in this.properties){if(this.properties.hasOwnProperty(r)){const s=this.properties[r];if(s){if(n){n=false}else{e+=","}e+=`${r}=${escapeProperty(s)}`}}}}e+=`${o}${escapeData(this.message)}`;return e}}function escapeData(e){return t.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return t.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},6105:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:true,value:n})}:function(e,n){e["default"]=n});var f=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(n,e,r);i(n,e);return n};var l=this&&this.__awaiter||function(e,n,r,s){function adopt(e){return e instanceof r?e:new r(function(n){n(e)})}return new(r||(r=Promise))(function(r,i){function fulfilled(e){try{step(s.next(e))}catch(e){i(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,n||[])).next())})};Object.defineProperty(n,"__esModule",{value:true});n.getIDToken=n.getState=n.saveState=n.group=n.endGroup=n.startGroup=n.info=n.notice=n.warning=n.error=n.debug=n.isDebug=n.setFailed=n.setCommandEcho=n.setOutput=n.getBooleanInput=n.getMultilineInput=n.getInput=n.addPath=n.setSecret=n.exportVariable=n.ExitCode=void 0;const t=r(5791);const o=r(9111);const c=r(1831);const a=f(r(2087));const d=f(r(5622));const p=r(441);var u;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(u=n.ExitCode||(n.ExitCode={}));function exportVariable(e,n){const r=c.toCommandValue(n);process.env[e]=r;const s=process.env["GITHUB_ENV"]||"";if(s){const n="_GitHubActionsFileCommandDelimeter_";const s=`${e}<<${n}${a.EOL}${r}${a.EOL}${n}`;o.issueCommand("ENV",s)}else{t.issueCommand("set-env",{name:e},r)}}n.exportVariable=exportVariable;function setSecret(e){t.issueCommand("add-mask",{},e)}n.setSecret=setSecret;function addPath(e){const n=process.env["GITHUB_PATH"]||"";if(n){o.issueCommand("PATH",e)}else{t.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${d.delimiter}${process.env["PATH"]}`}n.addPath=addPath;function getInput(e,n){const r=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(n&&n.required&&!r){throw new Error(`Input required and not supplied: ${e}`)}if(n&&n.trimWhitespace===false){return r}return r.trim()}n.getInput=getInput;function getMultilineInput(e,n){const r=getInput(e,n).split("\n").filter(e=>e!=="");return r}n.getMultilineInput=getMultilineInput;function getBooleanInput(e,n){const r=["true","True","TRUE"];const s=["false","False","FALSE"];const i=getInput(e,n);if(r.includes(i))return true;if(s.includes(i))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}n.getBooleanInput=getBooleanInput;function setOutput(e,n){process.stdout.write(a.EOL);t.issueCommand("set-output",{name:e},n)}n.setOutput=setOutput;function setCommandEcho(e){t.issue("echo",e?"on":"off")}n.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=u.Failure;error(e)}n.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}n.isDebug=isDebug;function debug(e){t.issueCommand("debug",{},e)}n.debug=debug;function error(e,n={}){t.issueCommand("error",c.toCommandProperties(n),e instanceof Error?e.toString():e)}n.error=error;function warning(e,n={}){t.issueCommand("warning",c.toCommandProperties(n),e instanceof Error?e.toString():e)}n.warning=warning;function notice(e,n={}){t.issueCommand("notice",c.toCommandProperties(n),e instanceof Error?e.toString():e)}n.notice=notice;function info(e){process.stdout.write(e+a.EOL)}n.info=info;function startGroup(e){t.issue("group",e)}n.startGroup=startGroup;function endGroup(){t.issue("endgroup")}n.endGroup=endGroup;function group(e,n){return l(this,void 0,void 0,function*(){startGroup(e);let r;try{r=yield n()}finally{endGroup()}return r})}n.group=group;function saveState(e,n){t.issueCommand("save-state",{name:e},n)}n.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}n.getState=getState;function getIDToken(e){return l(this,void 0,void 0,function*(){return yield p.OidcClient.getIDToken(e)})}n.getIDToken=getIDToken},9111:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:true,value:n})}:function(e,n){e["default"]=n});var f=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r in e)if(r!=="default"&&Object.hasOwnProperty.call(e,r))s(n,e,r);i(n,e);return n};Object.defineProperty(n,"__esModule",{value:true});n.issueCommand=void 0;const l=f(r(5747));const t=f(r(2087));const o=r(1831);function issueCommand(e,n){const r=process.env[`GITHUB_${e}`];if(!r){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!l.existsSync(r)){throw new Error(`Missing file at path: ${r}`)}l.appendFileSync(r,`${o.toCommandValue(n)}${t.EOL}`,{encoding:"utf8"})}n.issueCommand=issueCommand},441:function(e,n,r){"use strict";var s=this&&this.__awaiter||function(e,n,r,s){function adopt(e){return e instanceof r?e:new r(function(n){n(e)})}return new(r||(r=Promise))(function(r,i){function fulfilled(e){try{step(s.next(e))}catch(e){i(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,n||[])).next())})};Object.defineProperty(n,"__esModule",{value:true});n.OidcClient=void 0;const i=r(8389);const f=r(1960);const l=r(6105);class OidcClient{static createHttpClient(e=true,n=10){const r={allowRetries:e,maxRetries:n};return new i.HttpClient("actions/oidc-client",[new f.BearerCredentialHandler(OidcClient.getRequestToken())],r)}static getRequestToken(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable")}return e}static getIDTokenUrl(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable")}return e}static getCall(e){var n;return s(this,void 0,void 0,function*(){const r=OidcClient.createHttpClient();const s=yield r.getJson(e).catch(e=>{throw new Error(`Failed to get ID Token. \n \n Error Code : ${e.statusCode}\n \n Error Message: ${e.result.message}`)});const i=(n=s.result)===null||n===void 0?void 0:n.value;if(!i){throw new Error("Response json body do not have ID Token field")}return i})}static getIDToken(e){return s(this,void 0,void 0,function*(){try{let n=OidcClient.getIDTokenUrl();if(e){const r=encodeURIComponent(e);n=`${n}&audience=${r}`}l.debug(`ID token url is ${n}`);const r=yield OidcClient.getCall(n);l.setSecret(r);return r}catch(e){throw new Error(`Error message: ${e.message}`)}})}}n.OidcClient=OidcClient},1831:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.toCommandProperties=n.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}n.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}n.toCommandProperties=toCommandProperties},1960:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});class BasicCredentialHandler{constructor(e,n){this.username=e;this.password=n}prepareRequest(e){e.headers["Authorization"]="Basic "+Buffer.from(this.username+":"+this.password).toString("base64")}canHandleAuthentication(e){return false}handleAuthentication(e,n,r){return null}}n.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){e.headers["Authorization"]="Bearer "+this.token}canHandleAuthentication(e){return false}handleAuthentication(e,n,r){return null}}n.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){e.headers["Authorization"]="Basic "+Buffer.from("PAT:"+this.token).toString("base64")}canHandleAuthentication(e){return false}handleAuthentication(e,n,r){return null}}n.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},8389:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});const s=r(8605);const i=r(7211);const f=r(9242);let l;var t;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(t=n.HttpCodes||(n.HttpCodes={}));var o;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(o=n.Headers||(n.Headers={}));var c;(function(e){e["ApplicationJson"]="application/json"})(c=n.MediaTypes||(n.MediaTypes={}));function getProxyUrl(e){let n=f.getProxyUrl(new URL(e));return n?n.href:""}n.getProxyUrl=getProxyUrl;const a=[t.MovedPermanently,t.ResourceMoved,t.SeeOther,t.TemporaryRedirect,t.PermanentRedirect];const d=[t.BadGateway,t.ServiceUnavailable,t.GatewayTimeout];const p=["OPTIONS","GET","DELETE","HEAD"];const u=10;const h=5;class HttpClientError extends Error{constructor(e,n){super(e);this.name="HttpClientError";this.statusCode=n;Object.setPrototypeOf(this,HttpClientError.prototype)}}n.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return new Promise(async(e,n)=>{let r=Buffer.alloc(0);this.message.on("data",e=>{r=Buffer.concat([r,e])});this.message.on("end",()=>{e(r.toString())})})}}n.HttpClientResponse=HttpClientResponse;function isHttps(e){let n=new URL(e);return n.protocol==="https:"}n.isHttps=isHttps;class HttpClient{constructor(e,n,r){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=n||[];this.requestOptions=r;if(r){if(r.ignoreSslError!=null){this._ignoreSslError=r.ignoreSslError}this._socketTimeout=r.socketTimeout;if(r.allowRedirects!=null){this._allowRedirects=r.allowRedirects}if(r.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=r.allowRedirectDowngrade}if(r.maxRedirects!=null){this._maxRedirects=Math.max(r.maxRedirects,0)}if(r.keepAlive!=null){this._keepAlive=r.keepAlive}if(r.allowRetries!=null){this._allowRetries=r.allowRetries}if(r.maxRetries!=null){this._maxRetries=r.maxRetries}}}options(e,n){return this.request("OPTIONS",e,null,n||{})}get(e,n){return this.request("GET",e,null,n||{})}del(e,n){return this.request("DELETE",e,null,n||{})}post(e,n,r){return this.request("POST",e,n,r||{})}patch(e,n,r){return this.request("PATCH",e,n,r||{})}put(e,n,r){return this.request("PUT",e,n,r||{})}head(e,n){return this.request("HEAD",e,null,n||{})}sendStream(e,n,r,s){return this.request(e,n,r,s)}async getJson(e,n={}){n[o.Accept]=this._getExistingOrDefaultHeader(n,o.Accept,c.ApplicationJson);let r=await this.get(e,n);return this._processResponse(r,this.requestOptions)}async postJson(e,n,r={}){let s=JSON.stringify(n,null,2);r[o.Accept]=this._getExistingOrDefaultHeader(r,o.Accept,c.ApplicationJson);r[o.ContentType]=this._getExistingOrDefaultHeader(r,o.ContentType,c.ApplicationJson);let i=await this.post(e,s,r);return this._processResponse(i,this.requestOptions)}async putJson(e,n,r={}){let s=JSON.stringify(n,null,2);r[o.Accept]=this._getExistingOrDefaultHeader(r,o.Accept,c.ApplicationJson);r[o.ContentType]=this._getExistingOrDefaultHeader(r,o.ContentType,c.ApplicationJson);let i=await this.put(e,s,r);return this._processResponse(i,this.requestOptions)}async patchJson(e,n,r={}){let s=JSON.stringify(n,null,2);r[o.Accept]=this._getExistingOrDefaultHeader(r,o.Accept,c.ApplicationJson);r[o.ContentType]=this._getExistingOrDefaultHeader(r,o.ContentType,c.ApplicationJson);let i=await this.patch(e,s,r);return this._processResponse(i,this.requestOptions)}async request(e,n,r,s){if(this._disposed){throw new Error("Client has already been disposed.")}let i=new URL(n);let f=this._prepareRequest(e,i,s);let l=this._allowRetries&&p.indexOf(e)!=-1?this._maxRetries+1:1;let o=0;let c;while(o<l){c=await this.requestRaw(f,r);if(c&&c.message&&c.message.statusCode===t.Unauthorized){let e;for(let n=0;n<this.handlers.length;n++){if(this.handlers[n].canHandleAuthentication(c)){e=this.handlers[n];break}}if(e){return e.handleAuthentication(this,f,r)}else{return c}}let n=this._maxRedirects;while(a.indexOf(c.message.statusCode)!=-1&&this._allowRedirects&&n>0){const l=c.message.headers["location"];if(!l){break}let t=new URL(l);if(i.protocol=="https:"&&i.protocol!=t.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}await c.readBody();if(t.hostname!==i.hostname){for(let e in s){if(e.toLowerCase()==="authorization"){delete s[e]}}}f=this._prepareRequest(e,t,s);c=await this.requestRaw(f,r);n--}if(d.indexOf(c.message.statusCode)==-1){return c}o+=1;if(o<l){await c.readBody();await this._performExponentialBackoff(o)}}return c}dispose(){if(this._agent){this._agent.destroy()}this._disposed=true}requestRaw(e,n){return new Promise((r,s)=>{let i=function(e,n){if(e){s(e)}r(n)};this.requestRawWithCallback(e,n,i)})}requestRawWithCallback(e,n,r){let s;if(typeof n==="string"){e.options.headers["Content-Length"]=Buffer.byteLength(n,"utf8")}let i=false;let f=(e,n)=>{if(!i){i=true;r(e,n)}};let l=e.httpModule.request(e.options,e=>{let n=new HttpClientResponse(e);f(null,n)});l.on("socket",e=>{s=e});l.setTimeout(this._socketTimeout||3*6e4,()=>{if(s){s.end()}f(new Error("Request timeout: "+e.options.path),null)});l.on("error",function(e){f(e,null)});if(n&&typeof n==="string"){l.write(n,"utf8")}if(n&&typeof n!=="string"){n.on("close",function(){l.end()});n.pipe(l)}else{l.end()}}getAgent(e){let n=new URL(e);return this._getAgent(n)}_prepareRequest(e,n,r){const f={};f.parsedUrl=n;const l=f.parsedUrl.protocol==="https:";f.httpModule=l?i:s;const t=l?443:80;f.options={};f.options.host=f.parsedUrl.hostname;f.options.port=f.parsedUrl.port?parseInt(f.parsedUrl.port):t;f.options.path=(f.parsedUrl.pathname||"")+(f.parsedUrl.search||"");f.options.method=e;f.options.headers=this._mergeHeaders(r);if(this.userAgent!=null){f.options.headers["user-agent"]=this.userAgent}f.options.agent=this._getAgent(f.parsedUrl);if(this.handlers){this.handlers.forEach(e=>{e.prepareRequest(f.options)})}return f}_mergeHeaders(e){const n=e=>Object.keys(e).reduce((n,r)=>(n[r.toLowerCase()]=e[r],n),{});if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},n(this.requestOptions.headers),n(e))}return n(e||{})}_getExistingOrDefaultHeader(e,n,r){const s=e=>Object.keys(e).reduce((n,r)=>(n[r.toLowerCase()]=e[r],n),{});let i;if(this.requestOptions&&this.requestOptions.headers){i=s(this.requestOptions.headers)[n]}return e[n]||i||r}_getAgent(e){let n;let t=f.getProxyUrl(e);let o=t&&t.hostname;if(this._keepAlive&&o){n=this._proxyAgent}if(this._keepAlive&&!o){n=this._agent}if(!!n){return n}const c=e.protocol==="https:";let a=100;if(!!this.requestOptions){a=this.requestOptions.maxSockets||s.globalAgent.maxSockets}if(o){if(!l){l=r(3695)}const e={maxSockets:a,keepAlive:this._keepAlive,proxy:{...(t.username||t.password)&&{proxyAuth:`${t.username}:${t.password}`},host:t.hostname,port:t.port}};let s;const i=t.protocol==="https:";if(c){s=i?l.httpsOverHttps:l.httpsOverHttp}else{s=i?l.httpOverHttps:l.httpOverHttp}n=s(e);this._proxyAgent=n}if(this._keepAlive&&!n){const e={keepAlive:this._keepAlive,maxSockets:a};n=c?new i.Agent(e):new s.Agent(e);this._agent=n}if(!n){n=c?i.globalAgent:s.globalAgent}if(c&&this._ignoreSslError){n.options=Object.assign(n.options||{},{rejectUnauthorized:false})}return n}_performExponentialBackoff(e){e=Math.min(u,e);const n=h*Math.pow(2,e);return new Promise(e=>setTimeout(()=>e(),n))}static dateTimeDeserializer(e,n){if(typeof n==="string"){let e=new Date(n);if(!isNaN(e.valueOf())){return e}}return n}async _processResponse(e,n){return new Promise(async(r,s)=>{const i=e.message.statusCode;const f={statusCode:i,result:null,headers:{}};if(i==t.NotFound){r(f)}let l;let o;try{o=await e.readBody();if(o&&o.length>0){if(n&&n.deserializeDates){l=JSON.parse(o,HttpClient.dateTimeDeserializer)}else{l=JSON.parse(o)}f.result=l}f.headers=e.message.headers}catch(e){}if(i>299){let e;if(l&&l.message){e=l.message}else if(o&&o.length>0){e=o}else{e="Failed request: ("+i+")"}let n=new HttpClientError(e,i);n.result=f.result;s(n)}else{r(f)}})}}n.HttpClient=HttpClient},9242:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});function getProxyUrl(e){let n=e.protocol==="https:";let r;if(checkBypass(e)){return r}let s;if(n){s=process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{s=process.env["http_proxy"]||process.env["HTTP_PROXY"]}if(s){r=new URL(s)}return r}n.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}let n=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!n){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}let s=[e.hostname.toUpperCase()];if(typeof r==="number"){s.push(`${s[0]}:${r}`)}for(let e of n.split(",").map(e=>e.trim().toUpperCase()).filter(e=>e)){if(s.some(n=>n===e)){return true}}return false}n.checkBypass=checkBypass},6453:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__exportStar||function(e,n){for(var r in e)if(r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r))s(n,e,r)};Object.defineProperty(n,"__esModule",{value:true});i(r(7950),n);i(r(1586),n);i(r(537),n);i(r(3375),n);i(r(9307),n);i(r(8444),n);i(r(8785),n);i(r(1949),n);i(r(728),n);i(r(8436),n);i(r(7868),n);i(r(1615),n);i(r(1571),n);i(r(3485),n);i(r(9465),n);i(r(5773),n);i(r(5339),n);i(r(2048),n);i(r(941),n);i(r(2723),n);i(r(8789),n)},7950:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.contextLogger=void 0;const i=s(r(690));n.contextLogger=(0,i.default)("context")},1586:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.deprecationLogger=void 0;const i=s(r(690));n.deprecationLogger=(0,i.default)("deprecation")},537:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.fetchingProgressLogger=void 0;const i=s(r(690));n.fetchingProgressLogger=(0,i.default)("fetching-progress")},3375:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.hookLogger=void 0;const i=s(r(690));n.hookLogger=(0,i.default)("hook")},8962:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__exportStar||function(e,n){for(var r in e)if(r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r))s(n,e,r)};Object.defineProperty(n,"__esModule",{value:true});i(r(6453),n)},9307:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.installCheckLogger=void 0;const i=s(r(690));n.installCheckLogger=(0,i.default)("install-check")},8444:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.lifecycleLogger=void 0;const i=s(r(690));n.lifecycleLogger=(0,i.default)("lifecycle")},8785:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.linkLogger=void 0;const i=s(r(690));n.linkLogger=(0,i.default)("link")},1949:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.packageImportMethodLogger=void 0;const i=s(r(690));n.packageImportMethodLogger=(0,i.default)("package-import-method")},728:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.packageManifestLogger=void 0;const i=s(r(690));n.packageManifestLogger=(0,i.default)("package-manifest")},8436:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.peerDependencyIssuesLogger=void 0;const i=s(r(690));n.peerDependencyIssuesLogger=(0,i.default)("peer-dependency-issues")},7868:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.progressLogger=void 0;const i=s(r(690));n.progressLogger=(0,i.default)("progress")},1615:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true})},1571:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.removalLogger=void 0;const i=s(r(690));n.removalLogger=(0,i.default)("removal")},3485:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.requestRetryLogger=void 0;const i=s(r(690));n.requestRetryLogger=(0,i.default)("request-retry")},9465:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.rootLogger=void 0;const i=s(r(690));n.rootLogger=(0,i.default)("root")},5773:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.scopeLogger=void 0;const i=s(r(690));n.scopeLogger=(0,i.default)("scope")},5339:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.skippedOptionalDependencyLogger=void 0;const i=s(r(690));n.skippedOptionalDependencyLogger=(0,i.default)("skipped-optional-dependency")},2048:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.stageLogger=void 0;const i=s(r(690));n.stageLogger=(0,i.default)("stage")},941:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.statsLogger=void 0;const i=s(r(690));n.statsLogger=(0,i.default)("stats")},2723:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.summaryLogger=void 0;const i=s(r(690));n.summaryLogger=(0,i.default)("summary")},8789:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.updateCheckLogger=void 0;const i=s(r(690));n.updateCheckLogger=(0,i.default)("update-check")},1046:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:true,value:n})}:function(e,n){e["default"]=n});var f=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(n,e,r);i(n,e);return n};Object.defineProperty(n,"__esModule",{value:true});n.ResponseError=n.isRedirect=n.Response=void 0;const l=r(8962);const t=r(8983);const o=f(r(5999));Object.defineProperty(n,"Response",{enumerable:true,get:function(){return o.Response}});n.isRedirect=o.default.isRedirect;async function fetchRetry(e,n={}){var r,s,i,f,c;const a=(r=n.retry)!==null&&r!==void 0?r:{};const d=(s=a.retries)!==null&&s!==void 0?s:2;const p=(0,t.operation)({factor:(i=a.factor)!==null&&i!==void 0?i:10,maxTimeout:(f=a.maxTimeout)!==null&&f!==void 0?f:6e4,minTimeout:(c=a.minTimeout)!==null&&c!==void 0?c:1e4,randomize:false,retries:d});try{return await new Promise((r,s)=>p.attempt(async i=>{var f;try{const t=await(0,o.default)(e,n);if(t.status>=500&&t.status<600||[408,409,420,429].includes(t.status)){throw new ResponseError(t)}else{r(t);return}}catch(r){const t=p.retry(r);if(t===false){s(p.mainError());return}l.requestRetryLogger.debug({attempt:i,error:r,maxRetries:d,method:(f=n.method)!==null&&f!==void 0?f:"GET",timeout:t,url:e.toString()})}}))}catch(e){if(e instanceof ResponseError){return e.res}throw e}}n.default=fetchRetry;class ResponseError extends Error{constructor(e){super(e.statusText);if(Error.captureStackTrace){Error.captureStackTrace(this,ResponseError)}this.name=this.constructor.name;this.res=e;this.code=this.status=this.statusCode=e.status;this.url=e.url}}n.ResponseError=ResponseError},7640:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:true,value:n})}:function(e,n){e["default"]=n});var f=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(n,e,r);i(n,e);return n};var l=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.fetchWithAgent=void 0;const t=r(8835);const o=l(r(4167));const c=f(r(1046));const a="pnpm";const d="application/vnd.npm.install-v1+json; q=1.0, application/json; q=0.8, */*";const p="application/json";const u=20;function fetchWithAgent(e,n){var r,s;const i=(0,o.default)(e.toString(),{...n.agentOptions,strictSsl:(r=n.agentOptions.strictSsl)!==null&&r!==void 0?r:true});const f=(s=n.headers)!==null&&s!==void 0?s:{};f["connection"]=i?"keep-alive":"close";return(0,c.default)(e,{...n,agent:i})}n.fetchWithAgent=fetchWithAgent;function default_1(e){return async(n,r)=>{var s,i,f;const l={"user-agent":a,...getHeaders({auth:r===null||r===void 0?void 0:r.authHeaderValue,fullMetadata:e.fullMetadata,userAgent:e.userAgent})};let o=0;let d=new t.URL(n);const p=d.host;while(true){const n={...e,...r,strictSsl:(s=e.strictSsl)!==null&&s!==void 0?s:true};const a=await fetchWithAgent(d,{agentOptions:n,compress:(i=r===null||r===void 0?void 0:r.compress)!==null&&i!==void 0?i:false,headers:l,redirect:"manual",retry:r===null||r===void 0?void 0:r.retry,timeout:(f=r===null||r===void 0?void 0:r.timeout)!==null&&f!==void 0?f:6e4});if(!(0,c.isRedirect)(a.status)||o>=u){return a}o++;d=new t.URL(a.headers.get("location"));if(!l["authorization"]||p===d.host)continue;delete l.authorization}}}n.default=default_1;function getHeaders(e){const n={accept:e.fullMetadata===true?p:d};if(e.auth){n["authorization"]=e.auth}if(e.userAgent){n["user-agent"]=e.userAgent}return n}},1868:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__setModuleDefault||(Object.create?function(e,n){Object.defineProperty(e,"default",{enumerable:true,value:n})}:function(e,n){e["default"]=n});var f=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))s(n,e,r);i(n,e);return n};var l=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});n.fetchWithAgent=n.createFetchFromRegistry=void 0;const t=l(r(1046));const o=f(r(7640));n.createFetchFromRegistry=o.default;Object.defineProperty(n,"fetchWithAgent",{enumerable:true,get:function(){return o.fetchWithAgent}});n.default=t.default},690:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.writeToConsole=n.createStreamParser=n.streamParser=n.globalWarn=n.globalInfo=void 0;const s=r(2824);Object.defineProperty(n,"globalInfo",{enumerable:true,get:function(){return s.globalInfo}});Object.defineProperty(n,"globalWarn",{enumerable:true,get:function(){return s.globalWarn}});const i=r(1906);n.streamParser=i.default;Object.defineProperty(n,"createStreamParser",{enumerable:true,get:function(){return i.createStreamParser}});const f=r(1554);n.writeToConsole=f.default;n.default=s.default},2824:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.globalInfo=n.globalWarn=void 0;const s=r(3802);s.setFastTime();n.default=s("pnpm");const i=s("pnpm:global");function globalWarn(e){i.warn(e)}n.globalWarn=globalWarn;function globalInfo(e){i.info(e)}n.globalInfo=globalInfo},1906:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.createStreamParser=void 0;const s=r(3802);const i=r(3290);n.default=createStreamParser();function createStreamParser(){const e=i.parse();s.output([{level:"debug",stream:e}]);return e}n.createStreamParser=createStreamParser},1554:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});const s=r(3802);function default_1(){s.output([{level:"debug",stream:process.stdout}])}n.default=default_1},4167:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});const i=r(8835);const f=s(r(9838));const l=s(r(5865));const t=s(r(7052));const o=s(r(7140));const c=s(r(7039));const a=f.default.HttpsAgent;const d=50;const p=new o.default({max:50});function getAgent(e,n){var r,s,l;const t=new i.URL(e);const o=t.protocol==="https:";const c=getProxyUri(e,n);const u=[`https:${o.toString()}`,c?`proxy:${c.protocol}//${c.username}:${c.password}@${c.host}:${c.port}`:">no-proxy<",`local-address:${(r=n.localAddress)!==null&&r!==void 0?r:">no-local-address<"}`,`strict-ssl:${o?Boolean(n.strictSsl).toString():">no-strict-ssl<"}`,`ca:${o&&n.ca||">no-ca<"}`,`cert:${o&&n.cert||">no-cert<"}`,`key:${o&&n.key||">no-key<"}`].join(":");if(p.peek(u)){return p.get(u)}if(c){const e=getProxy(c,n,o);p.set(u,e);return e}const h=typeof n.timeout!=="number"||n.timeout===0?0:n.timeout+1;const v=o?new a({ca:n.ca,cert:n.cert,key:n.key,localAddress:n.localAddress,maxSockets:(s=n.maxSockets)!==null&&s!==void 0?s:d,rejectUnauthorized:n.strictSsl,timeout:h}):new f.default({localAddress:n.localAddress,maxSockets:(l=n.maxSockets)!==null&&l!==void 0?l:d,timeout:h});p.set(u,v);return v}n.default=getAgent;function checkNoProxy(e,n){const r=new i.URL(e).hostname.split(".").filter(e=>e).reverse();if(typeof n.noProxy==="string"){const e=n.noProxy.split(/\s*,\s*/g);return e.some(e=>{const n=e.split(".").filter(e=>e).reverse();if(n.length===0){return false}for(let e=0;e<n.length;e++){if(r[e]!==n[e]){return false}}return true})}return n.noProxy}function getProxyUri(e,n){const{protocol:r}=new i.URL(e);let s;switch(r){case"http:":{s=n.httpProxy;break}case"https:":{s=n.httpsProxy;break}}if(!s){return null}if(!s.includes("://")){s=`${r}//${s}`}const f=typeof s==="string"?new i.URL(s):s;return!checkNoProxy(e,n)&&f}function getProxy(e,n,r){var s,i;const f={auth:getAuth(e),ca:n.ca,cert:n.cert,host:e.hostname,key:n.key,localAddress:n.localAddress,maxSockets:(s=n.maxSockets)!==null&&s!==void 0?s:d,path:e.pathname,port:e.port,protocol:e.protocol,rejectUnauthorized:n.strictSsl,timeout:typeof n.timeout!=="number"||n.timeout===0?0:n.timeout+1};if(e.protocol==="http:"||e.protocol==="https:"){if(!r){return(0,l.default)(f)}else{return(0,t.default)(f)}}if((i=e.protocol)===null||i===void 0?void 0:i.startsWith("socks")){return new c.default(f)}}function getAuth(e){if(!e.username){return undefined}let n=e.username;if(e.password){n+=`:${e.password}`}return decodeURIComponent(n)}},3210:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});function once(e,n,{signal:r}={}){return new Promise((s,i)=>{function cleanup(){r===null||r===void 0?void 0:r.removeEventListener("abort",cleanup);e.removeListener(n,onEvent);e.removeListener("error",onError)}function onEvent(...e){cleanup();s(e)}function onError(e){cleanup();i(e)}r===null||r===void 0?void 0:r.addEventListener("abort",cleanup);e.on(n,onEvent);e.on("error",onError)})}n.default=once},8983:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.createTimeout=n.createTimeouts=n.operation=void 0;const s=r(6352);function operation(e){var n=createTimeouts(e);return new s.default(n,{maxRetryTime:e&&e.maxRetryTime})}n.operation=operation;function createTimeouts(e){var n={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:Infinity,randomize:false,...e};if(n.minTimeout>n.maxTimeout){throw new Error("minTimeout is greater than maxTimeout")}var r=[];for(var s=0;s<n.retries;s++){r.push(createTimeout(s,n))}r.sort(function(e,n){return e-n});return r}n.createTimeouts=createTimeouts;function createTimeout(e,n){var r=n.randomize?Math.random()+1:1;var s=Math.round(r*n.minTimeout*Math.pow(n.factor,e));s=Math.min(s,n.maxTimeout);return s}n.createTimeout=createTimeout},6352:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});class RetryOperation{constructor(e,n){var r;this._originalTimeouts=[...e];this._timeouts=e;this._maxRetryTime=(r=n===null||n===void 0?void 0:n.maxRetryTime)!==null&&r!==void 0?r:Infinity;this._fn=null;this._errors=[];this._attempts=1;this._operationStart=null;this._timer=null}reset(){this._attempts=1;this._timeouts=this._originalTimeouts}stop(){if(this._timer){clearTimeout(this._timer)}this._timeouts=[]}retry(e){if(!e){return false}var n=(new Date).getTime();if(e&&n-this._operationStart>=this._maxRetryTime){this._errors.unshift(new Error("RetryOperation timeout occurred"));return false}this._errors.push(e);var r=this._timeouts.shift();if(r===undefined){return false}this._timer=setTimeout(()=>this._fn(++this._attempts),r);return r}attempt(e){this._fn=e;this._operationStart=(new Date).getTime();this._fn(this._attempts)}errors(){return this._errors}attempts(){return this._attempts}mainError(){if(this._errors.length===0){return null}var e={};var n=null;var r=0;for(var s=0;s<this._errors.length;s++){var i=this._errors[s];var f=i.message;var l=(e[f]||0)+1;e[f]=l;if(l>=r){n=i;r=l}}return n}}n.default=RetryOperation},44:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};const i=r(8614);const f=s(r(6782));const l=s(r(1197));const t=f.default("agent-base");function isAgent(e){return Boolean(e)&&typeof e.addRequest==="function"}function isSecureEndpoint(){const{stack:e}=new Error;if(typeof e!=="string")return false;return e.split("\n").some(e=>e.indexOf("(https.js:")!==-1||e.indexOf("node:https:")!==-1)}function createAgent(e,n){return new createAgent.Agent(e,n)}(function(e){class Agent extends i.EventEmitter{constructor(e,n){super();let r=n;if(typeof e==="function"){this.callback=e}else if(e){r=e}this.timeout=null;if(r&&typeof r.timeout==="number"){this.timeout=r.timeout}this.maxFreeSockets=1;this.maxSockets=1;this.maxTotalSockets=Infinity;this.sockets={};this.freeSockets={};this.requests={};this.options={}}get defaultPort(){if(typeof this.explicitDefaultPort==="number"){return this.explicitDefaultPort}return isSecureEndpoint()?443:80}set defaultPort(e){this.explicitDefaultPort=e}get protocol(){if(typeof this.explicitProtocol==="string"){return this.explicitProtocol}return isSecureEndpoint()?"https:":"http:"}set protocol(e){this.explicitProtocol=e}callback(e,n,r){throw new Error('"agent-base" has no default implementation, you must subclass and override `callback()`')}addRequest(e,n){const r=Object.assign({},n);if(typeof r.secureEndpoint!=="boolean"){r.secureEndpoint=isSecureEndpoint()}if(r.host==null){r.host="localhost"}if(r.port==null){r.port=r.secureEndpoint?443:80}if(r.protocol==null){r.protocol=r.secureEndpoint?"https:":"http:"}if(r.host&&r.path){delete r.path}delete r.agent;delete r.hostname;delete r._defaultAgent;delete r.defaultPort;delete r.createConnection;e._last=true;e.shouldKeepAlive=false;let s=false;let i=null;const f=r.timeout||this.timeout;const o=n=>{if(e._hadError)return;e.emit("error",n);e._hadError=true};const c=()=>{i=null;s=true;const e=new Error(`A "socket" was not created for HTTP request before ${f}ms`);e.code="ETIMEOUT";o(e)};const a=e=>{if(s)return;if(i!==null){clearTimeout(i);i=null}o(e)};const d=n=>{if(s)return;if(i!=null){clearTimeout(i);i=null}if(isAgent(n)){t("Callback returned another Agent instance %o",n.constructor.name);n.addRequest(e,r);return}if(n){n.once("free",()=>{this.freeSocket(n,r)});e.onSocket(n);return}const f=new Error(`no Duplex stream was returned to agent-base for \`${e.method} ${e.path}\``);o(f)};if(typeof this.callback!=="function"){o(new Error("`callback` is not defined"));return}if(!this.promisifiedCallback){if(this.callback.length>=3){t("Converting legacy callback function to promise");this.promisifiedCallback=l.default(this.callback)}else{this.promisifiedCallback=this.callback}}if(typeof f==="number"&&f>0){i=setTimeout(c,f)}if("port"in r&&typeof r.port!=="number"){r.port=Number(r.port)}try{t("Resolving socket for %o request: %o",r.protocol,`${e.method} ${e.path}`);Promise.resolve(this.promisifiedCallback(e,r)).then(d,a)}catch(e){Promise.reject(e).catch(a)}}freeSocket(e,n){t("Freeing socket %o %o",e.constructor.name,n);e.destroy()}destroy(){t("Destroying agent %o",this.constructor.name)}}e.Agent=Agent;e.prototype=e.Agent.prototype})(createAgent||(createAgent={}));e.exports=createAgent},1197:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});function promisify(e){return function(n,r){return new Promise((s,i)=>{e.call(this,n,r,(e,n)=>{if(e){i(e)}else{s(n)}})})}}n.default=promisify},9838:(e,n,r)=>{"use strict";e.exports=r(3734);e.exports.HttpsAgent=r(6310);e.exports.constants=r(6071)},3734:(e,n,r)=>{"use strict";const s=r(8605).Agent;const i=r(3499);const f=r(6782)("agentkeepalive");const l=r(2527)("agentkeepalive");const{INIT_SOCKET:t,CURRENT_ID:o,CREATE_ID:c,SOCKET_CREATED_TIME:a,SOCKET_NAME:d,SOCKET_REQUEST_COUNT:p,SOCKET_REQUEST_FINISHED_COUNT:u}=r(6071);let h=1;const v=parseInt(process.version.split(".",1)[0].substring(1));if(v>=11&&v<=12){h=2}else if(v>=13){h=3}class Agent extends s{constructor(e){e=e||{};e.keepAlive=e.keepAlive!==false;if(e.freeSocketTimeout===undefined){e.freeSocketTimeout=4e3}if(e.keepAliveTimeout){l("options.keepAliveTimeout is deprecated, please use options.freeSocketTimeout instead");e.freeSocketTimeout=e.keepAliveTimeout;delete e.keepAliveTimeout}if(e.freeSocketKeepAliveTimeout){l("options.freeSocketKeepAliveTimeout is deprecated, please use options.freeSocketTimeout instead");e.freeSocketTimeout=e.freeSocketKeepAliveTimeout;delete e.freeSocketKeepAliveTimeout}if(e.timeout===undefined){e.timeout=Math.max(e.freeSocketTimeout*2,8e3)}e.timeout=i(e.timeout);e.freeSocketTimeout=i(e.freeSocketTimeout);e.socketActiveTTL=e.socketActiveTTL?i(e.socketActiveTTL):0;super(e);this[o]=0;this.createSocketCount=0;this.createSocketCountLastCheck=0;this.createSocketErrorCount=0;this.createSocketErrorCountLastCheck=0;this.closeSocketCount=0;this.closeSocketCountLastCheck=0;this.errorSocketCount=0;this.errorSocketCountLastCheck=0;this.requestCount=0;this.requestCountLastCheck=0;this.timeoutSocketCount=0;this.timeoutSocketCountLastCheck=0;this.on("free",e=>{const n=this.calcSocketTimeout(e);if(n>0&&e.timeout!==n){e.setTimeout(n)}})}get freeSocketKeepAliveTimeout(){l("agent.freeSocketKeepAliveTimeout is deprecated, please use agent.options.freeSocketTimeout instead");return this.options.freeSocketTimeout}get timeout(){l("agent.timeout is deprecated, please use agent.options.timeout instead");return this.options.timeout}get socketActiveTTL(){l("agent.socketActiveTTL is deprecated, please use agent.options.socketActiveTTL instead");return this.options.socketActiveTTL}calcSocketTimeout(e){let n=this.options.freeSocketTimeout;const r=this.options.socketActiveTTL;if(r){const s=Date.now()-e[a];const i=r-s;if(i<=0){return i}if(n&&i<n){n=i}}if(n){const r=e.freeSocketTimeout||e.freeSocketKeepAliveTimeout;return r||n}}keepSocketAlive(e){const n=super.keepSocketAlive(e);if(!n)return n;const r=this.calcSocketTimeout(e);if(typeof r==="undefined"){return true}if(r<=0){f("%s(requests: %s, finished: %s) free but need to destroy by TTL, request count %s, diff is %s",e[d],e[p],e[u],r);return false}if(e.timeout!==r){e.setTimeout(r)}return true}reuseSocket(...e){super.reuseSocket(...e);const n=e[0];const r=e[1];r.reusedSocket=true;const s=this.options.timeout;if(getSocketTimeout(n)!==s){n.setTimeout(s);f("%s reset timeout to %sms",n[d],s)}n[p]++;f("%s(requests: %s, finished: %s) reuse on addRequest, timeout %sms",n[d],n[p],n[u],getSocketTimeout(n))}[c](){const e=this[o]++;if(this[o]===Number.MAX_SAFE_INTEGER)this[o]=0;return e}[t](e,n){if(n.timeout){const r=getSocketTimeout(e);if(!r){e.setTimeout(n.timeout)}}if(this.options.keepAlive){e.setNoDelay(true)}this.createSocketCount++;if(this.options.socketActiveTTL){e[a]=Date.now()}e[d]=`sock[${this[c]()}#${n._agentKey}]`.split("-----BEGIN",1)[0];e[p]=1;e[u]=0;installListeners(this,e,n)}createConnection(e,n){let r=false;const s=(s,i)=>{if(r)return;r=true;if(s){this.createSocketErrorCount++;return n(s)}this[t](i,e);n(s,i)};const i=super.createConnection(e,s);if(i)s(null,i)}get statusChanged(){const e=this.createSocketCount!==this.createSocketCountLastCheck||this.createSocketErrorCount!==this.createSocketErrorCountLastCheck||this.closeSocketCount!==this.closeSocketCountLastCheck||this.errorSocketCount!==this.errorSocketCountLastCheck||this.timeoutSocketCount!==this.timeoutSocketCountLastCheck||this.requestCount!==this.requestCountLastCheck;if(e){this.createSocketCountLastCheck=this.createSocketCount;this.createSocketErrorCountLastCheck=this.createSocketErrorCount;this.closeSocketCountLastCheck=this.closeSocketCount;this.errorSocketCountLastCheck=this.errorSocketCount;this.timeoutSocketCountLastCheck=this.timeoutSocketCount;this.requestCountLastCheck=this.requestCount}return e}getCurrentStatus(){return{createSocketCount:this.createSocketCount,createSocketErrorCount:this.createSocketErrorCount,closeSocketCount:this.closeSocketCount,errorSocketCount:this.errorSocketCount,timeoutSocketCount:this.timeoutSocketCount,requestCount:this.requestCount,freeSockets:inspect(this.freeSockets),sockets:inspect(this.sockets),requests:inspect(this.requests)}}}function getSocketTimeout(e){return e.timeout||e._idleTimeout}function installListeners(e,n,r){f("%s create, timeout %sms",n[d],getSocketTimeout(n));function onFree(){if(!n._httpMessage&&n[p]===1)return;n[u]++;e.requestCount++;f("%s(requests: %s, finished: %s) free",n[d],n[p],n[u]);const s=e.getName(r);if(n.writable&&e.requests[s]&&e.requests[s].length){n[p]++;f("%s(requests: %s, finished: %s) will be reuse on agent free event",n[d],n[p],n[u])}}n.on("free",onFree);function onClose(r){f("%s(requests: %s, finished: %s) close, isError: %s",n[d],n[p],n[u],r);e.closeSocketCount++}n.on("close",onClose);function onTimeout(){const s=n.listeners("timeout").length;const i=getSocketTimeout(n);const l=n._httpMessage;const t=l&&l.listeners("timeout").length||0;f("%s(requests: %s, finished: %s) timeout after %sms, listeners %s, defaultTimeoutListenerCount %s, hasHttpRequest %s, HttpRequest timeoutListenerCount %s",n[d],n[p],n[u],i,s,h,!!l,t);if(f.enabled){f("timeout listeners: %s",n.listeners("timeout").map(e=>e.name).join(", "))}e.timeoutSocketCount++;const o=e.getName(r);if(e.freeSockets[o]&&e.freeSockets[o].indexOf(n)!==-1){n.destroy();e.removeSocket(n,r);f("%s is free, destroy quietly",n[d])}else{if(t===0){const s=new Error("Socket timeout");s.code="ERR_SOCKET_TIMEOUT";s.timeout=i;n.destroy(s);e.removeSocket(n,r);f("%s destroy with timeout error",n[d])}}}n.on("timeout",onTimeout);function onError(r){const s=n.listeners("error").length;f("%s(requests: %s, finished: %s) error: %s, listenerCount: %s",n[d],n[p],n[u],r,s);e.errorSocketCount++;if(s===1){f("%s emit uncaught error event",n[d]);n.removeListener("error",onError);n.emit("error",r)}}n.on("error",onError);function onRemove(){f("%s(requests: %s, finished: %s) agentRemove",n[d],n[p],n[u]);n.removeListener("close",onClose);n.removeListener("error",onError);n.removeListener("free",onFree);n.removeListener("timeout",onTimeout);n.removeListener("agentRemove",onRemove)}n.on("agentRemove",onRemove)}e.exports=Agent;function inspect(e){const n={};for(const r in e){n[r]=e[r].length}return n}},6071:e=>{"use strict";e.exports={CURRENT_ID:Symbol("agentkeepalive#currentId"),CREATE_ID:Symbol("agentkeepalive#createId"),INIT_SOCKET:Symbol("agentkeepalive#initSocket"),CREATE_HTTPS_CONNECTION:Symbol("agentkeepalive#createHttpsConnection"),SOCKET_CREATED_TIME:Symbol("agentkeepalive#socketCreatedTime"),SOCKET_NAME:Symbol("agentkeepalive#socketName"),SOCKET_REQUEST_COUNT:Symbol("agentkeepalive#socketRequestCount"),SOCKET_REQUEST_FINISHED_COUNT:Symbol("agentkeepalive#socketRequestFinishedCount")}},6310:(e,n,r)=>{"use strict";const s=r(7211).Agent;const i=r(3734);const{INIT_SOCKET:f,CREATE_HTTPS_CONNECTION:l}=r(6071);class HttpsAgent extends i{constructor(e){super(e);this.defaultPort=443;this.protocol="https:";this.maxCachedSessions=this.options.maxCachedSessions;if(this.maxCachedSessions===undefined){this.maxCachedSessions=100}this._sessionCache={map:{},list:[]}}createConnection(e){const n=this[l](e);this[f](n,e);return n}}HttpsAgent.prototype[l]=s.prototype.createConnection;["getName","_getSession","_cacheSession","_evictSession"].forEach(function(e){if(typeof s.prototype[e]==="function"){HttpsAgent.prototype[e]=s.prototype[e]}});e.exports=HttpsAgent},6562:(e,n,r)=>{"use strict";var s=r(8077),i=r(3664),f=r(7647),l=r(7721),t=r(7692),o=r(1538),c=r(2170),a=r(4178),d=r(2657);e.exports=Ajv;Ajv.prototype.validate=validate;Ajv.prototype.compile=compile;Ajv.prototype.addSchema=addSchema;Ajv.prototype.addMetaSchema=addMetaSchema;Ajv.prototype.validateSchema=validateSchema;Ajv.prototype.getSchema=getSchema;Ajv.prototype.removeSchema=removeSchema;Ajv.prototype.addFormat=addFormat;Ajv.prototype.errorsText=errorsText;Ajv.prototype._addSchema=_addSchema;Ajv.prototype._compile=_compile;Ajv.prototype.compileAsync=r(9533);var p=r(5413);Ajv.prototype.addKeyword=p.add;Ajv.prototype.getKeyword=p.get;Ajv.prototype.removeKeyword=p.remove;Ajv.prototype.validateKeyword=p.validate;var u=r(3023);Ajv.ValidationError=u.Validation;Ajv.MissingRefError=u.MissingRef;Ajv.$dataMetaSchema=a;var h="http://json-schema.org/draft-07/schema";var v=["removeAdditional","useDefaults","coerceTypes","strictDefaults"];var g=["/properties"];function Ajv(e){if(!(this instanceof Ajv))return new Ajv(e);e=this._opts=d.copy(e)||{};setLogger(this);this._schemas={};this._refs={};this._fragments={};this._formats=o(e.format);this._cache=e.cache||new f;this._loadingSchemas={};this._compilations=[];this.RULES=c();this._getId=chooseGetId(e);e.loopRequired=e.loopRequired||Infinity;if(e.errorDataPath=="property")e._errorDataPathProperty=true;if(e.serialize===undefined)e.serialize=t;this._metaOpts=getMetaSchemaOptions(this);if(e.formats)addInitialFormats(this);if(e.keywords)addInitialKeywords(this);addDefaultMetaSchema(this);if(typeof e.meta=="object")this.addMetaSchema(e.meta);if(e.nullable)this.addKeyword("nullable",{metaSchema:{type:"boolean"}});addInitialSchemas(this)}function validate(e,n){var r;if(typeof e=="string"){r=this.getSchema(e);if(!r)throw new Error('no schema with key or ref "'+e+'"')}else{var s=this._addSchema(e);r=s.validate||this._compile(s)}var i=r(n);if(r.$async!==true)this.errors=r.errors;return i}function compile(e,n){var r=this._addSchema(e,undefined,n);return r.validate||this._compile(r)}function addSchema(e,n,r,s){if(Array.isArray(e)){for(var f=0;f<e.length;f++)this.addSchema(e[f],undefined,r,s);return this}var l=this._getId(e);if(l!==undefined&&typeof l!="string")throw new Error("schema id must be string");n=i.normalizeId(n||l);checkUnique(this,n);this._schemas[n]=this._addSchema(e,r,s,true);return this}function addMetaSchema(e,n,r){this.addSchema(e,n,r,true);return this}function validateSchema(e,n){var r=e.$schema;if(r!==undefined&&typeof r!="string")throw new Error("$schema must be a string");r=r||this._opts.defaultMeta||defaultMeta(this);if(!r){this.logger.warn("meta-schema not available");this.errors=null;return true}var s=this.validate(r,e);if(!s&&n){var i="schema is invalid: "+this.errorsText();if(this._opts.validateSchema=="log")this.logger.error(i);else throw new Error(i)}return s}function defaultMeta(e){var n=e._opts.meta;e._opts.defaultMeta=typeof n=="object"?e._getId(n)||n:e.getSchema(h)?h:undefined;return e._opts.defaultMeta}function getSchema(e){var n=_getSchemaObj(this,e);switch(typeof n){case"object":return n.validate||this._compile(n);case"string":return this.getSchema(n);case"undefined":return _getSchemaFragment(this,e)}}function _getSchemaFragment(e,n){var r=i.schema.call(e,{schema:{}},n);if(r){var f=r.schema,t=r.root,o=r.baseId;var c=s.call(e,f,t,undefined,o);e._fragments[n]=new l({ref:n,fragment:true,schema:f,root:t,baseId:o,validate:c});return c}}function _getSchemaObj(e,n){n=i.normalizeId(n);return e._schemas[n]||e._refs[n]||e._fragments[n]}function removeSchema(e){if(e instanceof RegExp){_removeAllSchemas(this,this._schemas,e);_removeAllSchemas(this,this._refs,e);return this}switch(typeof e){case"undefined":_removeAllSchemas(this,this._schemas);_removeAllSchemas(this,this._refs);this._cache.clear();return this;case"string":var n=_getSchemaObj(this,e);if(n)this._cache.del(n.cacheKey);delete this._schemas[e];delete this._refs[e];return this;case"object":var r=this._opts.serialize;var s=r?r(e):e;this._cache.del(s);var f=this._getId(e);if(f){f=i.normalizeId(f);delete this._schemas[f];delete this._refs[f]}}return this}function _removeAllSchemas(e,n,r){for(var s in n){var i=n[s];if(!i.meta&&(!r||r.test(s))){e._cache.del(i.cacheKey);delete n[s]}}}function _addSchema(e,n,r,s){if(typeof e!="object"&&typeof e!="boolean")throw new Error("schema should be object or boolean");var f=this._opts.serialize;var t=f?f(e):e;var o=this._cache.get(t);if(o)return o;s=s||this._opts.addUsedSchema!==false;var c=i.normalizeId(this._getId(e));if(c&&s)checkUnique(this,c);var a=this._opts.validateSchema!==false&&!n;var d;if(a&&!(d=c&&c==i.normalizeId(e.$schema)))this.validateSchema(e,true);var p=i.ids.call(this,e);var u=new l({id:c,schema:e,localRefs:p,cacheKey:t,meta:r});if(c[0]!="#"&&s)this._refs[c]=u;this._cache.put(t,u);if(a&&d)this.validateSchema(e,true);return u}function _compile(e,n){if(e.compiling){e.validate=callValidate;callValidate.schema=e.schema;callValidate.errors=null;callValidate.root=n?n:callValidate;if(e.schema.$async===true)callValidate.$async=true;return callValidate}e.compiling=true;var r;if(e.meta){r=this._opts;this._opts=this._metaOpts}var i;try{i=s.call(this,e.schema,n,e.localRefs)}catch(n){delete e.validate;throw n}finally{e.compiling=false;if(e.meta)this._opts=r}e.validate=i;e.refs=i.refs;e.refVal=i.refVal;e.root=i.root;return i;function callValidate(){var n=e.validate;var r=n.apply(this,arguments);callValidate.errors=n.errors;return r}}function chooseGetId(e){switch(e.schemaId){case"auto":return _get$IdOrId;case"id":return _getId;default:return _get$Id}}function _getId(e){if(e.$id)this.logger.warn("schema $id ignored",e.$id);return e.id}function _get$Id(e){if(e.id)this.logger.warn("schema id ignored",e.id);return e.$id}function _get$IdOrId(e){if(e.$id&&e.id&&e.$id!=e.id)throw new Error("schema $id is different from id");return e.$id||e.id}function errorsText(e,n){e=e||this.errors;if(!e)return"No errors";n=n||{};var r=n.separator===undefined?", ":n.separator;var s=n.dataVar===undefined?"data":n.dataVar;var i="";for(var f=0;f<e.length;f++){var l=e[f];if(l)i+=s+l.dataPath+" "+l.message+r}return i.slice(0,-r.length)}function addFormat(e,n){if(typeof n=="string")n=new RegExp(n);this._formats[e]=n;return this}function addDefaultMetaSchema(e){var n;if(e._opts.$data){n=r(2706);e.addMetaSchema(n,n.$id,true)}if(e._opts.meta===false)return;var s=r(1742);if(e._opts.$data)s=a(s,g);e.addMetaSchema(s,h,true);e._refs["http://json-schema.org/schema"]=h}function addInitialSchemas(e){var n=e._opts.schemas;if(!n)return;if(Array.isArray(n))e.addSchema(n);else for(var r in n)e.addSchema(n[r],r)}function addInitialFormats(e){for(var n in e._opts.formats){var r=e._opts.formats[n];e.addFormat(n,r)}}function addInitialKeywords(e){for(var n in e._opts.keywords){var r=e._opts.keywords[n];e.addKeyword(n,r)}}function checkUnique(e,n){if(e._schemas[n]||e._refs[n])throw new Error('schema with key or id "'+n+'" already exists')}function getMetaSchemaOptions(e){var n=d.copy(e._opts);for(var r=0;r<v.length;r++)delete n[v[r]];return n}function setLogger(e){var n=e._opts.logger;if(n===false){e.logger={log:noop,warn:noop,error:noop}}else{if(n===undefined)n=console;if(!(typeof n=="object"&&n.log&&n.warn&&n.error))throw new Error("logger must implement log, warn and error methods");e.logger=n}}function noop(){}},7647:e=>{"use strict";var n=e.exports=function Cache(){this._cache={}};n.prototype.put=function Cache_put(e,n){this._cache[e]=n};n.prototype.get=function Cache_get(e){return this._cache[e]};n.prototype.del=function Cache_del(e){delete this._cache[e]};n.prototype.clear=function Cache_clear(){this._cache={}}},9533:(e,n,r)=>{"use strict";var s=r(3023).MissingRef;e.exports=compileAsync;function compileAsync(e,n,r){var i=this;if(typeof this._opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");if(typeof n=="function"){r=n;n=undefined}var f=loadMetaSchemaOf(e).then(function(){var r=i._addSchema(e,undefined,n);return r.validate||_compileAsync(r)});if(r){f.then(function(e){r(null,e)},r)}return f;function loadMetaSchemaOf(e){var n=e.$schema;return n&&!i.getSchema(n)?compileAsync.call(i,{$ref:n},true):Promise.resolve()}function _compileAsync(e){try{return i._compile(e)}catch(e){if(e instanceof s)return loadMissingSchema(e);throw e}function loadMissingSchema(r){var s=r.missingSchema;if(added(s))throw new Error("Schema "+s+" is loaded but "+r.missingRef+" cannot be resolved");var f=i._loadingSchemas[s];if(!f){f=i._loadingSchemas[s]=i._opts.loadSchema(s);f.then(removePromise,removePromise)}return f.then(function(e){if(!added(s)){return loadMetaSchemaOf(e).then(function(){if(!added(s))i.addSchema(e,s,undefined,n)})}}).then(function(){return _compileAsync(e)});function removePromise(){delete i._loadingSchemas[s]}function added(e){return i._refs[e]||i._schemas[e]}}}}},3023:(e,n,r)=>{"use strict";var s=r(3664);e.exports={Validation:errorSubclass(ValidationError),MissingRef:errorSubclass(MissingRefError)};function ValidationError(e){this.message="validation failed";this.errors=e;this.ajv=this.validation=true}MissingRefError.message=function(e,n){return"can't resolve reference "+n+" from id "+e};function MissingRefError(e,n,r){this.message=r||MissingRefError.message(e,n);this.missingRef=s.url(e,n);this.missingSchema=s.normalizeId(s.fullPath(this.missingRef))}function errorSubclass(e){e.prototype=Object.create(Error.prototype);e.prototype.constructor=e;return e}},1538:(e,n,r)=>{"use strict";var s=r(2657);var i=/^(\d\d\d\d)-(\d\d)-(\d\d)$/;var f=[0,31,28,31,30,31,30,31,31,30,31,30,31];var l=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;var t=/^(?=.{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;var o=/^(?:[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;var c=/^(?:[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;var a=/^(?:(?:[^\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;var d=/^(?:(?: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;var p=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i;var u=/^(?:\/(?:[^~/]|~0|~1)*)*$/;var h=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i;var v=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;e.exports=formats;function formats(e){e=e=="full"?"full":"fast";return s.copy(formats[e])}formats.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":a,url:d,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:t,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:regex,uuid:p,"json-pointer":u,"json-pointer-uri-fragment":h,"relative-json-pointer":v};formats.full={date:date,time:time,"date-time":date_time,uri:uri,"uri-reference":c,"uri-template":a,url:d,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:t,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:regex,uuid:p,"json-pointer":u,"json-pointer-uri-fragment":h,"relative-json-pointer":v};function isLeapYear(e){return e%4===0&&(e%100!==0||e%400===0)}function date(e){var n=e.match(i);if(!n)return false;var r=+n[1];var s=+n[2];var l=+n[3];return s>=1&&s<=12&&l>=1&&l<=(s==2&&isLeapYear(r)?29:f[s])}function time(e,n){var r=e.match(l);if(!r)return false;var s=r[1];var i=r[2];var f=r[3];var t=r[5];return(s<=23&&i<=59&&f<=59||s==23&&i==59&&f==60)&&(!n||t)}var g=/t|\s/i;function date_time(e){var n=e.split(g);return n.length==2&&date(n[0])&&time(n[1],true)}var b=/\/|:/;function uri(e){return b.test(e)&&o.test(e)}var w=/[^\\]\\Z/;function regex(e){if(w.test(e))return false;try{new RegExp(e);return true}catch(e){return false}}},8077:(e,n,r)=>{"use strict";var s=r(3664),i=r(2657),f=r(3023),l=r(7692);var t=r(7752);var o=i.ucs2length;var c=r(7988);var a=f.Validation;e.exports=compile;function compile(e,n,r,d){var p=this,u=this._opts,h=[undefined],v={},g=[],b={},w=[],y={},m=[];n=n||{schema:e,refVal:h,refs:v};var E=checkCompiling.call(this,e,n,d);var S=this._compilations[E.index];if(E.compiling)return S.callValidate=callValidate;var C=this._formats;var O=this.RULES;try{var A=localCompile(e,n,r,d);S.validate=A;var R=S.callValidate;if(R){R.schema=A.schema;R.errors=null;R.refs=A.refs;R.refVal=A.refVal;R.root=A.root;R.$async=A.$async;if(u.sourceCode)R.source=A.source}return A}finally{endCompiling.call(this,e,n,d)}function callValidate(){var e=S.validate;var n=e.apply(this,arguments);callValidate.errors=e.errors;return n}function localCompile(e,r,l,d){var b=!r||r&&r.schema==e;if(r.schema!=n.schema)return compile.call(p,e,r,l,d);var y=e.$async===true;var E=t({isTop:true,schema:e,isRoot:b,baseId:d,root:r,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:f.MissingRef,RULES:O,validate:t,util:i,resolve:s,resolveRef:resolveRef,usePattern:usePattern,useDefault:useDefault,useCustomRule:useCustomRule,opts:u,formats:C,logger:p.logger,self:p});E=vars(h,refValCode)+vars(g,patternCode)+vars(w,defaultCode)+vars(m,customRuleCode)+E;if(u.processCode)E=u.processCode(E,e);var S;try{var A=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",E);S=A(p,O,C,n,h,w,m,c,o,a);h[0]=S}catch(e){p.logger.error("Error compiling schema, function code:",E);throw e}S.schema=e;S.errors=null;S.refs=v;S.refVal=h;S.root=b?S:r;if(y)S.$async=true;if(u.sourceCode===true){S.source={code:E,patterns:g,defaults:w}}return S}function resolveRef(e,i,f){i=s.url(e,i);var l=v[i];var t,o;if(l!==undefined){t=h[l];o="refVal["+l+"]";return resolvedRef(t,o)}if(!f&&n.refs){var c=n.refs[i];if(c!==undefined){t=n.refVal[c];o=addLocalRef(i,t);return resolvedRef(t,o)}}o=addLocalRef(i);var a=s.call(p,localCompile,n,i);if(a===undefined){var d=r&&r[i];if(d){a=s.inlineRef(d,u.inlineRefs)?d:compile.call(p,d,n,r,e)}}if(a===undefined){removeLocalRef(i)}else{replaceLocalRef(i,a);return resolvedRef(a,o)}}function addLocalRef(e,n){var r=h.length;h[r]=n;v[e]=r;return"refVal"+r}function removeLocalRef(e){delete v[e]}function replaceLocalRef(e,n){var r=v[e];h[r]=n}function resolvedRef(e,n){return typeof e=="object"||typeof e=="boolean"?{code:n,schema:e,inline:true}:{code:n,$async:e&&!!e.$async}}function usePattern(e){var n=b[e];if(n===undefined){n=b[e]=g.length;g[n]=e}return"pattern"+n}function useDefault(e){switch(typeof e){case"boolean":case"number":return""+e;case"string":return i.toQuotedString(e);case"object":if(e===null)return"null";var n=l(e);var r=y[n];if(r===undefined){r=y[n]=w.length;w[r]=e}return"default"+r}}function useCustomRule(e,n,r,s){if(p._opts.validateSchema!==false){var i=e.definition.dependencies;if(i&&!i.every(function(e){return Object.prototype.hasOwnProperty.call(r,e)}))throw new Error("parent schema must have all required keywords: "+i.join(","));var f=e.definition.validateSchema;if(f){var l=f(n);if(!l){var t="keyword schema is invalid: "+p.errorsText(f.errors);if(p._opts.validateSchema=="log")p.logger.error(t);else throw new Error(t)}}}var o=e.definition.compile,c=e.definition.inline,a=e.definition.macro;var d;if(o){d=o.call(p,n,r,s)}else if(a){d=a.call(p,n,r,s);if(u.validateSchema!==false)p.validateSchema(d,true)}else if(c){d=c.call(p,s,e.keyword,n,r)}else{d=e.definition.validate;if(!d)return}if(d===undefined)throw new Error('custom keyword "'+e.keyword+'"failed to compile');var h=m.length;m[h]=d;return{code:"customRule"+h,validate:d}}}function checkCompiling(e,n,r){var s=compIndex.call(this,e,n,r);if(s>=0)return{index:s,compiling:true};s=this._compilations.length;this._compilations[s]={schema:e,root:n,baseId:r};return{index:s,compiling:false}}function endCompiling(e,n,r){var s=compIndex.call(this,e,n,r);if(s>=0)this._compilations.splice(s,1)}function compIndex(e,n,r){for(var s=0;s<this._compilations.length;s++){var i=this._compilations[s];if(i.schema==e&&i.root==n&&i.baseId==r)return s}return-1}function patternCode(e,n){return"var pattern"+e+" = new RegExp("+i.toQuotedString(n[e])+");"}function defaultCode(e){return"var default"+e+" = defaults["+e+"];"}function refValCode(e,n){return n[e]===undefined?"":"var refVal"+e+" = refVal["+e+"];"}function customRuleCode(e){return"var customRule"+e+" = customRules["+e+"];"}function vars(e,n){if(!e.length)return"";var r="";for(var s=0;s<e.length;s++)r+=n(s,e);return r}},3664:(e,n,r)=>{"use strict";var s=r(3786),i=r(7988),f=r(2657),l=r(7721),t=r(7438);e.exports=resolve;resolve.normalizeId=normalizeId;resolve.fullPath=getFullPath;resolve.url=resolveUrl;resolve.ids=resolveIds;resolve.inlineRef=inlineRef;resolve.schema=resolveSchema;function resolve(e,n,r){var s=this._refs[r];if(typeof s=="string"){if(this._refs[s])s=this._refs[s];else return resolve.call(this,e,n,s)}s=s||this._schemas[r];if(s instanceof l){return inlineRef(s.schema,this._opts.inlineRefs)?s.schema:s.validate||this._compile(s)}var i=resolveSchema.call(this,n,r);var f,t,o;if(i){f=i.schema;n=i.root;o=i.baseId}if(f instanceof l){t=f.validate||e.call(this,f.schema,n,undefined,o)}else if(f!==undefined){t=inlineRef(f,this._opts.inlineRefs)?f:e.call(this,f,n,undefined,o)}return t}function resolveSchema(e,n){var r=s.parse(n),i=_getFullPath(r),f=getFullPath(this._getId(e.schema));if(Object.keys(e.schema).length===0||i!==f){var t=normalizeId(i);var o=this._refs[t];if(typeof o=="string"){return resolveRecursive.call(this,e,o,r)}else if(o instanceof l){if(!o.validate)this._compile(o);e=o}else{o=this._schemas[t];if(o instanceof l){if(!o.validate)this._compile(o);if(t==normalizeId(n))return{schema:o,root:e,baseId:f};e=o}else{return}}if(!e.schema)return;f=getFullPath(this._getId(e.schema))}return getJsonPointer.call(this,r,f,e.schema,e)}function resolveRecursive(e,n,r){var s=resolveSchema.call(this,e,n);if(s){var i=s.schema;var f=s.baseId;e=s.root;var l=this._getId(i);if(l)f=resolveUrl(f,l);return getJsonPointer.call(this,r,f,i,e)}}var o=f.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function getJsonPointer(e,n,r,s){e.fragment=e.fragment||"";if(e.fragment.slice(0,1)!="/")return;var i=e.fragment.split("/");for(var l=1;l<i.length;l++){var t=i[l];if(t){t=f.unescapeFragment(t);r=r[t];if(r===undefined)break;var c;if(!o[t]){c=this._getId(r);if(c)n=resolveUrl(n,c);if(r.$ref){var a=resolveUrl(n,r.$ref);var d=resolveSchema.call(this,s,a);if(d){r=d.schema;s=d.root;n=d.baseId}}}}}if(r!==undefined&&r!==s.schema)return{schema:r,root:s,baseId:n}}var c=f.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function inlineRef(e,n){if(n===false)return false;if(n===undefined||n===true)return checkNoRef(e);else if(n)return countKeys(e)<=n}function checkNoRef(e){var n;if(Array.isArray(e)){for(var r=0;r<e.length;r++){n=e[r];if(typeof n=="object"&&!checkNoRef(n))return false}}else{for(var s in e){if(s=="$ref")return false;n=e[s];if(typeof n=="object"&&!checkNoRef(n))return false}}return true}function countKeys(e){var n=0,r;if(Array.isArray(e)){for(var s=0;s<e.length;s++){r=e[s];if(typeof r=="object")n+=countKeys(r);if(n==Infinity)return Infinity}}else{for(var i in e){if(i=="$ref")return Infinity;if(c[i]){n++}else{r=e[i];if(typeof r=="object")n+=countKeys(r)+1;if(n==Infinity)return Infinity}}}return n}function getFullPath(e,n){if(n!==false)e=normalizeId(e);var r=s.parse(e);return _getFullPath(r)}function _getFullPath(e){return s.serialize(e).split("#")[0]+"#"}var a=/#\/?$/;function normalizeId(e){return e?e.replace(a,""):""}function resolveUrl(e,n){n=normalizeId(n);return s.resolve(e,n)}function resolveIds(e){var n=normalizeId(this._getId(e));var r={"":n};var l={"":getFullPath(n,false)};var o={};var c=this;t(e,{allKeys:true},function(e,n,t,a,d,p,u){if(n==="")return;var h=c._getId(e);var v=r[a];var g=l[a]+"/"+d;if(u!==undefined)g+="/"+(typeof u=="number"?u:f.escapeFragment(u));if(typeof h=="string"){h=v=normalizeId(v?s.resolve(v,h):h);var b=c._refs[h];if(typeof b=="string")b=c._refs[b];if(b&&b.schema){if(!i(e,b.schema))throw new Error('id "'+h+'" resolves to more than one schema')}else if(h!=normalizeId(g)){if(h[0]=="#"){if(o[h]&&!i(e,o[h]))throw new Error('id "'+h+'" resolves to more than one schema');o[h]=e}else{c._refs[h]=g}}}r[n]=v;l[n]=g});return o}},2170:(e,n,r)=>{"use strict";var s=r(1676),i=r(2657).toHash;e.exports=function rules(){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"]}];var n=["type","$comment"];var r=["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"];var f=["number","integer","string","array","object","boolean","null"];e.all=i(n);e.types=i(f);e.forEach(function(r){r.rules=r.rules.map(function(r){var i;if(typeof r=="object"){var f=Object.keys(r)[0];i=r[f];r=f;i.forEach(function(r){n.push(r);e.all[r]=true})}n.push(r);var l=e.all[r]={keyword:r,code:s[r],implements:i};return l});e.all.$comment={keyword:"$comment",code:s.$comment};if(r.type)e.types[r.type]=r});e.keywords=i(n.concat(r));e.custom={};return e}},7721:(e,n,r)=>{"use strict";var s=r(2657);e.exports=SchemaObject;function SchemaObject(e){s.copy(e,this)}},5584:e=>{"use strict";e.exports=function ucs2length(e){var n=0,r=e.length,s=0,i;while(s<r){n++;i=e.charCodeAt(s++);if(i>=55296&&i<=56319&&s<r){i=e.charCodeAt(s);if((i&64512)==56320)s++}}return n}},2657:(e,n,r)=>{"use strict";e.exports={copy:copy,checkDataType:checkDataType,checkDataTypes:checkDataTypes,coerceToTypes:coerceToTypes,toHash:toHash,getProperty:getProperty,escapeQuotes:escapeQuotes,equal:r(7988),ucs2length:r(5584),varOccurences:varOccurences,varReplace:varReplace,schemaHasRules:schemaHasRules,schemaHasRulesExcept:schemaHasRulesExcept,schemaUnknownRules:schemaUnknownRules,toQuotedString:toQuotedString,getPathExpr:getPathExpr,getPath:getPath,getData:getData,unescapeFragment:unescapeFragment,unescapeJsonPointer:unescapeJsonPointer,escapeFragment:escapeFragment,escapeJsonPointer:escapeJsonPointer};function copy(e,n){n=n||{};for(var r in e)n[r]=e[r];return n}function checkDataType(e,n,r,s){var i=s?" !== ":" === ",f=s?" || ":" && ",l=s?"!":"",t=s?"":"!";switch(e){case"null":return n+i+"null";case"array":return l+"Array.isArray("+n+")";case"object":return"("+l+n+f+"typeof "+n+i+'"object"'+f+t+"Array.isArray("+n+"))";case"integer":return"(typeof "+n+i+'"number"'+f+t+"("+n+" % 1)"+f+n+i+n+(r?f+l+"isFinite("+n+")":"")+")";case"number":return"(typeof "+n+i+'"'+e+'"'+(r?f+l+"isFinite("+n+")":"")+")";default:return"typeof "+n+i+'"'+e+'"'}}function checkDataTypes(e,n,r){switch(e.length){case 1:return checkDataType(e[0],n,r,true);default:var s="";var i=toHash(e);if(i.array&&i.object){s=i.null?"(":"(!"+n+" || ";s+="typeof "+n+' !== "object")';delete i.null;delete i.array;delete i.object}if(i.number)delete i.integer;for(var f in i)s+=(s?" && ":"")+checkDataType(f,n,r,true);return s}}var s=toHash(["string","number","integer","boolean","null"]);function coerceToTypes(e,n){if(Array.isArray(n)){var r=[];for(var i=0;i<n.length;i++){var f=n[i];if(s[f])r[r.length]=f;else if(e==="array"&&f==="array")r[r.length]=f}if(r.length)return r}else if(s[n]){return[n]}else if(e==="array"&&n==="array"){return["array"]}}function toHash(e){var n={};for(var r=0;r<e.length;r++)n[e[r]]=true;return n}var i=/^[a-z$_][a-z$_0-9]*$/i;var f=/'|\\/g;function getProperty(e){return typeof e=="number"?"["+e+"]":i.test(e)?"."+e:"['"+escapeQuotes(e)+"']"}function escapeQuotes(e){return e.replace(f,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function varOccurences(e,n){n+="[^0-9]";var r=e.match(new RegExp(n,"g"));return r?r.length:0}function varReplace(e,n,r){n+="([^0-9])";r=r.replace(/\$/g,"$$$$");return e.replace(new RegExp(n,"g"),r+"$1")}function schemaHasRules(e,n){if(typeof e=="boolean")return!e;for(var r in e)if(n[r])return true}function schemaHasRulesExcept(e,n,r){if(typeof e=="boolean")return!e&&r!="not";for(var s in e)if(s!=r&&n[s])return true}function schemaUnknownRules(e,n){if(typeof e=="boolean")return;for(var r in e)if(!n[r])return r}function toQuotedString(e){return"'"+escapeQuotes(e)+"'"}function getPathExpr(e,n,r,s){var i=r?"'/' + "+n+(s?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):s?"'[' + "+n+" + ']'":"'[\\'' + "+n+" + '\\']'";return joinPaths(e,i)}function getPath(e,n,r){var s=r?toQuotedString("/"+escapeJsonPointer(n)):toQuotedString(getProperty(n));return joinPaths(e,s)}var l=/^\/(?:[^~]|~0|~1)*$/;var t=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function getData(e,n,r){var s,i,f,o;if(e==="")return"rootData";if(e[0]=="/"){if(!l.test(e))throw new Error("Invalid JSON-pointer: "+e);i=e;f="rootData"}else{o=e.match(t);if(!o)throw new Error("Invalid JSON-pointer: "+e);s=+o[1];i=o[2];if(i=="#"){if(s>=n)throw new Error("Cannot access property/index "+s+" levels up, current level is "+n);return r[n-s]}if(s>n)throw new Error("Cannot access data "+s+" levels up, current level is "+n);f="data"+(n-s||"");if(!i)return f}var c=f;var a=i.split("/");for(var d=0;d<a.length;d++){var p=a[d];if(p){f+=getProperty(unescapeJsonPointer(p));c+=" && "+f}}return c}function joinPaths(e,n){if(e=='""')return n;return(e+" + "+n).replace(/([^\\])' \+ '/g,"$1")}function unescapeFragment(e){return unescapeJsonPointer(decodeURIComponent(e))}function escapeFragment(e){return encodeURIComponent(escapeJsonPointer(e))}function escapeJsonPointer(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}function unescapeJsonPointer(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}},4178:e=>{"use strict";var n=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];e.exports=function(e,r){for(var s=0;s<r.length;s++){e=JSON.parse(JSON.stringify(e));var i=r[s].split("/");var f=e;var l;for(l=1;l<i.length;l++)f=f[i[l]];for(l=0;l<n.length;l++){var t=n[l];var o=f[t];if(o){f[t]={anyOf:[o,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}}}}return e}},2059:(e,n,r)=>{"use strict";var s=r(1742);e.exports={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:s.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:s.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"}]}}}},5702:e=>{"use strict";e.exports=function generate__limit(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a;var d="data"+(f||"");var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}var h=n=="maximum",v=h?"exclusiveMaximum":"exclusiveMinimum",g=e.schema[v],b=e.opts.$data&&g&&g.$data,w=h?"<":">",y=h?">":"<",a=undefined;if(!(p||typeof l=="number"||l===undefined)){throw new Error(n+" must be number")}if(!(b||g===undefined||typeof g=="number"||typeof g=="boolean")){throw new Error(v+" must be number or boolean")}if(b){var m=e.util.getData(g.$data,f,e.dataPathArr),E="exclusive"+i,S="exclType"+i,C="exclIsNumber"+i,O="op"+i,A="' + "+O+" + '";s+=" var schemaExcl"+i+" = "+m+"; ";m="schemaExcl"+i;s+=" var "+E+"; var "+S+" = typeof "+m+"; if ("+S+" != 'boolean' && "+S+" != 'undefined' && "+S+" != 'number') { ";var a=v;var R=R||[];R.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(a||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: {} ";if(e.opts.messages!==false){s+=" , message: '"+v+" should be boolean' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}var k=s;s=R.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+k+"]); "}else{s+=" validate.errors = ["+k+"]; return false; "}}else{s+=" var err = "+k+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } else if ( ";if(p){s+=" ("+u+" !== undefined && typeof "+u+" != 'number') || "}s+=" "+S+" == 'number' ? ( ("+E+" = "+u+" === undefined || "+m+" "+w+"= "+u+") ? "+d+" "+y+"= "+m+" : "+d+" "+y+" "+u+" ) : ( ("+E+" = "+m+" === true) ? "+d+" "+y+"= "+u+" : "+d+" "+y+" "+u+" ) || "+d+" !== "+d+") { var op"+i+" = "+E+" ? '"+w+"' : '"+w+"='; ";if(l===undefined){a=v;o=e.errSchemaPath+"/"+v;u=m;p=b}}else{var C=typeof g=="number",A=w;if(C&&p){var O="'"+A+"'";s+=" if ( ";if(p){s+=" ("+u+" !== undefined && typeof "+u+" != 'number') || "}s+=" ( "+u+" === undefined || "+g+" "+w+"= "+u+" ? "+d+" "+y+"= "+g+" : "+d+" "+y+" "+u+" ) || "+d+" !== "+d+") { "}else{if(C&&l===undefined){E=true;a=v;o=e.errSchemaPath+"/"+v;u=g;y+="="}else{if(C)u=Math[h?"min":"max"](g,l);if(g===(C?u:true)){E=true;a=v;o=e.errSchemaPath+"/"+v;y+="="}else{E=false;A+="="}}var O="'"+A+"'";s+=" if ( ";if(p){s+=" ("+u+" !== undefined && typeof "+u+" != 'number') || "}s+=" "+d+" "+y+" "+u+" || "+d+" !== "+d+") { "}}a=a||n;var R=R||[];R.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(a||"_limit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { comparison: "+O+", limit: "+u+", exclusive: "+E+" } ";if(e.opts.messages!==false){s+=" , message: 'should be "+A+" ";if(p){s+="' + "+u}else{s+=""+u+"'"}}if(e.opts.verbose){s+=" , schema: ";if(p){s+="validate.schema"+t}else{s+=""+l}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}var k=s;s=R.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+k+"]); "}else{s+=" validate.errors = ["+k+"]; return false; "}}else{s+=" var err = "+k+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } ";if(c){s+=" else { "}return s}},2931:e=>{"use strict";e.exports=function generate__limitItems(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a;var d="data"+(f||"");var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}if(!(p||typeof l=="number")){throw new Error(n+" must be number")}var h=n=="maxItems"?">":"<";s+="if ( ";if(p){s+=" ("+u+" !== undefined && typeof "+u+" != 'number') || "}s+=" "+d+".length "+h+" "+u+") { ";var a=n;var v=v||[];v.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(a||"_limitItems")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { limit: "+u+" } ";if(e.opts.messages!==false){s+=" , message: 'should NOT have ";if(n=="maxItems"){s+="more"}else{s+="fewer"}s+=" than ";if(p){s+="' + "+u+" + '"}else{s+=""+l}s+=" items' "}if(e.opts.verbose){s+=" , schema: ";if(p){s+="validate.schema"+t}else{s+=""+l}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}var g=s;s=v.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+g+"]); "}else{s+=" validate.errors = ["+g+"]; return false; "}}else{s+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+="} ";if(c){s+=" else { "}return s}},4583:e=>{"use strict";e.exports=function generate__limitLength(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a;var d="data"+(f||"");var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}if(!(p||typeof l=="number")){throw new Error(n+" must be number")}var h=n=="maxLength"?">":"<";s+="if ( ";if(p){s+=" ("+u+" !== undefined && typeof "+u+" != 'number') || "}if(e.opts.unicode===false){s+=" "+d+".length "}else{s+=" ucs2length("+d+") "}s+=" "+h+" "+u+") { ";var a=n;var v=v||[];v.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(a||"_limitLength")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { limit: "+u+" } ";if(e.opts.messages!==false){s+=" , message: 'should NOT be ";if(n=="maxLength"){s+="longer"}else{s+="shorter"}s+=" than ";if(p){s+="' + "+u+" + '"}else{s+=""+l}s+=" characters' "}if(e.opts.verbose){s+=" , schema: ";if(p){s+="validate.schema"+t}else{s+=""+l}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}var g=s;s=v.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+g+"]); "}else{s+=" validate.errors = ["+g+"]; return false; "}}else{s+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+="} ";if(c){s+=" else { "}return s}},1679:e=>{"use strict";e.exports=function generate__limitProperties(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a;var d="data"+(f||"");var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}if(!(p||typeof l=="number")){throw new Error(n+" must be number")}var h=n=="maxProperties"?">":"<";s+="if ( ";if(p){s+=" ("+u+" !== undefined && typeof "+u+" != 'number') || "}s+=" Object.keys("+d+").length "+h+" "+u+") { ";var a=n;var v=v||[];v.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(a||"_limitProperties")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { limit: "+u+" } ";if(e.opts.messages!==false){s+=" , message: 'should NOT have ";if(n=="maxProperties"){s+="more"}else{s+="fewer"}s+=" than ";if(p){s+="' + "+u+" + '"}else{s+=""+l}s+=" properties' "}if(e.opts.verbose){s+=" , schema: ";if(p){s+="validate.schema"+t}else{s+=""+l}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}var g=s;s=v.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+g+"]); "}else{s+=" validate.errors = ["+g+"]; return false; "}}else{s+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+="} ";if(c){s+=" else { "}return s}},6981:e=>{"use strict";e.exports=function generate_allOf(e,n,r){var s=" ";var i=e.schema[n];var f=e.schemaPath+e.util.getProperty(n);var l=e.errSchemaPath+"/"+n;var t=!e.opts.allErrors;var o=e.util.copy(e);var c="";o.level++;var a="valid"+o.level;var d=o.baseId,p=true;var u=i;if(u){var h,v=-1,g=u.length-1;while(v<g){h=u[v+=1];if(e.opts.strictKeywords?typeof h=="object"&&Object.keys(h).length>0||h===false:e.util.schemaHasRules(h,e.RULES.all)){p=false;o.schema=h;o.schemaPath=f+"["+v+"]";o.errSchemaPath=l+"/"+v;s+=" "+e.validate(o)+" ";o.baseId=d;if(t){s+=" if ("+a+") { ";c+="}"}}}}if(t){if(p){s+=" if (true) { "}else{s+=" "+c.slice(0,-1)+" "}}return s}},8138:e=>{"use strict";e.exports=function generate_anyOf(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p="errs__"+i;var u=e.util.copy(e);var h="";u.level++;var v="valid"+u.level;var g=l.every(function(n){return e.opts.strictKeywords?typeof n=="object"&&Object.keys(n).length>0||n===false:e.util.schemaHasRules(n,e.RULES.all)});if(g){var b=u.baseId;s+=" var "+p+" = errors; var "+d+" = false; ";var w=e.compositeRule;e.compositeRule=u.compositeRule=true;var y=l;if(y){var m,E=-1,S=y.length-1;while(E<S){m=y[E+=1];u.schema=m;u.schemaPath=t+"["+E+"]";u.errSchemaPath=o+"/"+E;s+=" "+e.validate(u)+" ";u.baseId=b;s+=" "+d+" = "+d+" || "+v+"; if (!"+d+") { ";h+="}"}}e.compositeRule=u.compositeRule=w;s+=" "+h+" if (!"+d+") { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"anyOf"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: {} ";if(e.opts.messages!==false){s+=" , message: 'should match some schema in anyOf' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(vErrors); "}else{s+=" validate.errors = vErrors; return false; "}}s+=" } else { errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; } ";if(e.opts.allErrors){s+=" } "}}else{if(c){s+=" if (true) { "}}return s}},3090:e=>{"use strict";e.exports=function generate_comment(e,n,r){var s=" ";var i=e.schema[n];var f=e.errSchemaPath+"/"+n;var l=!e.opts.allErrors;var t=e.util.toQuotedString(i);if(e.opts.$comment===true){s+=" console.log("+t+");"}else if(typeof e.opts.$comment=="function"){s+=" self._opts.$comment("+t+", "+e.util.toQuotedString(f)+", validate.root.schema);"}return s}},2645:e=>{"use strict";e.exports=function generate_const(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}if(!p){s+=" var schema"+i+" = validate.schema"+t+";"}s+="var "+d+" = equal("+a+", schema"+i+"); if (!"+d+") { ";var h=h||[];h.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"const"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { allowedValue: schema"+i+" } ";if(e.opts.messages!==false){s+=" , message: 'should be equal to constant' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var v=s;s=h.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+v+"]); "}else{s+=" validate.errors = ["+v+"]; return false; "}}else{s+=" var err = "+v+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" }";if(c){s+=" else { "}return s}},640:e=>{"use strict";e.exports=function generate_contains(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p="errs__"+i;var u=e.util.copy(e);var h="";u.level++;var v="valid"+u.level;var g="i"+i,b=u.dataLevel=e.dataLevel+1,w="data"+b,y=e.baseId,m=e.opts.strictKeywords?typeof l=="object"&&Object.keys(l).length>0||l===false:e.util.schemaHasRules(l,e.RULES.all);s+="var "+p+" = errors;var "+d+";";if(m){var E=e.compositeRule;e.compositeRule=u.compositeRule=true;u.schema=l;u.schemaPath=t;u.errSchemaPath=o;s+=" var "+v+" = false; for (var "+g+" = 0; "+g+" < "+a+".length; "+g+"++) { ";u.errorPath=e.util.getPathExpr(e.errorPath,g,e.opts.jsonPointers,true);var S=a+"["+g+"]";u.dataPathArr[b]=g;var C=e.validate(u);u.baseId=y;if(e.util.varOccurences(C,w)<2){s+=" "+e.util.varReplace(C,w,S)+" "}else{s+=" var "+w+" = "+S+"; "+C+" "}s+=" if ("+v+") break; } ";e.compositeRule=u.compositeRule=E;s+=" "+h+" if (!"+v+") {"}else{s+=" if ("+a+".length == 0) {"}var O=O||[];O.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"contains"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: {} ";if(e.opts.messages!==false){s+=" , message: 'should contain a valid item' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var A=s;s=O.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+A+"]); "}else{s+=" validate.errors = ["+A+"]; return false; "}}else{s+=" var err = "+A+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } else { ";if(m){s+=" errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; } "}if(e.opts.allErrors){s+=" } "}return s}},4741:e=>{"use strict";e.exports=function generate_custom(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a;var d="data"+(f||"");var p="valid"+i;var u="errs__"+i;var h=e.opts.$data&&l&&l.$data,v;if(h){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";v="schema"+i}else{v=l}var g=this,b="definition"+i,w=g.definition,y="";var m,E,S,C,O;if(h&&w.$data){O="keywordValidate"+i;var A=w.validateSchema;s+=" var "+b+" = RULES.custom['"+n+"'].definition; var "+O+" = "+b+".validate;"}else{C=e.useCustomRule(g,l,e.schema,e);if(!C)return;v="validate.schema"+t;O=C.code;m=w.compile;E=w.inline;S=w.macro}var R=O+".errors",k="i"+i,I="ruleErr"+i,T=w.async;if(T&&!e.async)throw new Error("async keyword in sync schema");if(!(E||S)){s+=""+R+" = null;"}s+="var "+u+" = errors;var "+p+";";if(h&&w.$data){y+="}";s+=" if ("+v+" === undefined) { "+p+" = true; } else { ";if(A){y+="}";s+=" "+p+" = "+b+".validateSchema("+v+"); if ("+p+") { "}}if(E){if(w.statements){s+=" "+C.validate+" "}else{s+=" "+p+" = "+C.validate+"; "}}else if(S){var x=e.util.copy(e);var y="";x.level++;var F="valid"+x.level;x.schema=C.validate;x.schemaPath="";var j=e.compositeRule;e.compositeRule=x.compositeRule=true;var B=e.validate(x).replace(/validate\.schema/g,O);e.compositeRule=x.compositeRule=j;s+=" "+B}else{var L=L||[];L.push(s);s="";s+=" "+O+".call( ";if(e.opts.passContext){s+="this"}else{s+="self"}if(m||w.schema===false){s+=" , "+d+" "}else{s+=" , "+v+" , "+d+" , validate.schema"+e.schemaPath+" "}s+=" , (dataPath || '')";if(e.errorPath!='""'){s+=" + "+e.errorPath}var M=f?"data"+(f-1||""):"parentData",U=f?e.dataPathArr[f]:"parentDataProperty";s+=" , "+M+" , "+U+" , rootData ) ";var D=s;s=L.pop();if(w.errors===false){s+=" "+p+" = ";if(T){s+="await "}s+=""+D+"; "}else{if(T){R="customErrors"+i;s+=" var "+R+" = null; try { "+p+" = await "+D+"; } catch (e) { "+p+" = false; if (e instanceof ValidationError) "+R+" = e.errors; else throw e; } "}else{s+=" "+R+" = null; "+p+" = "+D+"; "}}}if(w.modifying){s+=" if ("+M+") "+d+" = "+M+"["+U+"];"}s+=""+y;if(w.valid){if(c){s+=" if (true) { "}}else{s+=" if ( ";if(w.valid===undefined){s+=" !";if(S){s+=""+F}else{s+=""+p}}else{s+=" "+!w.valid+" "}s+=") { ";a=g.keyword;var L=L||[];L.push(s);s="";var L=L||[];L.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(a||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { keyword: '"+g.keyword+"' } ";if(e.opts.messages!==false){s+=" , message: 'should pass \""+g.keyword+"\" keyword validation' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}var N=s;s=L.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+N+"]); "}else{s+=" validate.errors = ["+N+"]; return false; "}}else{s+=" var err = "+N+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}var q=s;s=L.pop();if(E){if(w.errors){if(w.errors!="full"){s+=" for (var "+k+"="+u+"; "+k+"<errors; "+k+"++) { var "+I+" = vErrors["+k+"]; if ("+I+".dataPath === undefined) "+I+".dataPath = (dataPath || '') + "+e.errorPath+"; if ("+I+".schemaPath === undefined) { "+I+'.schemaPath = "'+o+'"; } ';if(e.opts.verbose){s+=" "+I+".schema = "+v+"; "+I+".data = "+d+"; "}s+=" } "}}else{if(w.errors===false){s+=" "+q+" "}else{s+=" if ("+u+" == errors) { "+q+" } else { for (var "+k+"="+u+"; "+k+"<errors; "+k+"++) { var "+I+" = vErrors["+k+"]; if ("+I+".dataPath === undefined) "+I+".dataPath = (dataPath || '') + "+e.errorPath+"; if ("+I+".schemaPath === undefined) { "+I+'.schemaPath = "'+o+'"; } ';if(e.opts.verbose){s+=" "+I+".schema = "+v+"; "+I+".data = "+d+"; "}s+=" } } "}}}else if(S){s+=" var err = ";if(e.createErrors!==false){s+=" { keyword: '"+(a||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { keyword: '"+g.keyword+"' } ";if(e.opts.messages!==false){s+=" , message: 'should pass \""+g.keyword+"\" keyword validation' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+d+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(vErrors); "}else{s+=" validate.errors = vErrors; return false; "}}}else{if(w.errors===false){s+=" "+q+" "}else{s+=" if (Array.isArray("+R+")) { if (vErrors === null) vErrors = "+R+"; else vErrors = vErrors.concat("+R+"); errors = vErrors.length; for (var "+k+"="+u+"; "+k+"<errors; "+k+"++) { var "+I+" = vErrors["+k+"]; if ("+I+".dataPath === undefined) "+I+".dataPath = (dataPath || '') + "+e.errorPath+"; "+I+'.schemaPath = "'+o+'"; ';if(e.opts.verbose){s+=" "+I+".schema = "+v+"; "+I+".data = "+d+"; "}s+=" } } else { "+q+" } "}}s+=" } ";if(c){s+=" else { "}}return s}},9466:e=>{"use strict";e.exports=function generate_dependencies(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="errs__"+i;var p=e.util.copy(e);var u="";p.level++;var h="valid"+p.level;var v={},g={},b=e.opts.ownProperties;for(E in l){if(E=="__proto__")continue;var w=l[E];var y=Array.isArray(w)?g:v;y[E]=w}s+="var "+d+" = errors;";var m=e.errorPath;s+="var missing"+i+";";for(var E in g){y=g[E];if(y.length){s+=" if ( "+a+e.util.getProperty(E)+" !== undefined ";if(b){s+=" && Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(E)+"') "}if(c){s+=" && ( ";var S=y;if(S){var C,O=-1,A=S.length-1;while(O<A){C=S[O+=1];if(O){s+=" || "}var R=e.util.getProperty(C),k=a+R;s+=" ( ( "+k+" === undefined ";if(b){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(C)+"') "}s+=") && (missing"+i+" = "+e.util.toQuotedString(e.opts.jsonPointers?C:R)+") ) "}}s+=")) { ";var I="missing"+i,T="' + "+I+" + '";if(e.opts._errorDataPathProperty){e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(m,I,true):m+" + "+I}var x=x||[];x.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"dependencies"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { property: '"+e.util.escapeQuotes(E)+"', missingProperty: '"+T+"', depsCount: "+y.length+", deps: '"+e.util.escapeQuotes(y.length==1?y[0]:y.join(", "))+"' } ";if(e.opts.messages!==false){s+=" , message: 'should have ";if(y.length==1){s+="property "+e.util.escapeQuotes(y[0])}else{s+="properties "+e.util.escapeQuotes(y.join(", "))}s+=" when property "+e.util.escapeQuotes(E)+" is present' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var F=s;s=x.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+F+"]); "}else{s+=" validate.errors = ["+F+"]; return false; "}}else{s+=" var err = "+F+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}}else{s+=" ) { ";var j=y;if(j){var C,B=-1,L=j.length-1;while(B<L){C=j[B+=1];var R=e.util.getProperty(C),T=e.util.escapeQuotes(C),k=a+R;if(e.opts._errorDataPathProperty){e.errorPath=e.util.getPath(m,C,e.opts.jsonPointers)}s+=" if ( "+k+" === undefined ";if(b){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(C)+"') "}s+=") { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"dependencies"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { property: '"+e.util.escapeQuotes(E)+"', missingProperty: '"+T+"', depsCount: "+y.length+", deps: '"+e.util.escapeQuotes(y.length==1?y[0]:y.join(", "))+"' } ";if(e.opts.messages!==false){s+=" , message: 'should have ";if(y.length==1){s+="property "+e.util.escapeQuotes(y[0])}else{s+="properties "+e.util.escapeQuotes(y.join(", "))}s+=" when property "+e.util.escapeQuotes(E)+" is present' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}}s+=" } ";if(c){u+="}";s+=" else { "}}}e.errorPath=m;var M=p.baseId;for(var E in v){var w=v[E];if(e.opts.strictKeywords?typeof w=="object"&&Object.keys(w).length>0||w===false:e.util.schemaHasRules(w,e.RULES.all)){s+=" "+h+" = true; if ( "+a+e.util.getProperty(E)+" !== undefined ";if(b){s+=" && Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(E)+"') "}s+=") { ";p.schema=w;p.schemaPath=t+e.util.getProperty(E);p.errSchemaPath=o+"/"+e.util.escapeFragment(E);s+=" "+e.validate(p)+" ";p.baseId=M;s+=" } ";if(c){s+=" if ("+h+") { ";u+="}"}}}if(c){s+=" "+u+" if ("+d+" == errors) {"}return s}},4684:e=>{"use strict";e.exports=function generate_enum(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}var h="i"+i,v="schema"+i;if(!p){s+=" var "+v+" = validate.schema"+t+";"}s+="var "+d+";";if(p){s+=" if (schema"+i+" === undefined) "+d+" = true; else if (!Array.isArray(schema"+i+")) "+d+" = false; else {"}s+=""+d+" = false;for (var "+h+"=0; "+h+"<"+v+".length; "+h+"++) if (equal("+a+", "+v+"["+h+"])) { "+d+" = true; break; }";if(p){s+=" } "}s+=" if (!"+d+") { ";var g=g||[];g.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"enum"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { allowedValues: schema"+i+" } ";if(e.opts.messages!==false){s+=" , message: 'should be equal to one of the allowed values' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var b=s;s=g.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+b+"]); "}else{s+=" validate.errors = ["+b+"]; return false; "}}else{s+=" var err = "+b+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" }";if(c){s+=" else { "}return s}},924:e=>{"use strict";e.exports=function generate_format(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");if(e.opts.format===false){if(c){s+=" if (true) { "}return s}var d=e.opts.$data&&l&&l.$data,p;if(d){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";p="schema"+i}else{p=l}var u=e.opts.unknownFormats,h=Array.isArray(u);if(d){var v="format"+i,g="isObject"+i,b="formatType"+i;s+=" var "+v+" = formats["+p+"]; var "+g+" = typeof "+v+" == 'object' && !("+v+" instanceof RegExp) && "+v+".validate; var "+b+" = "+g+" && "+v+".type || 'string'; if ("+g+") { ";if(e.async){s+=" var async"+i+" = "+v+".async; "}s+=" "+v+" = "+v+".validate; } if ( ";if(d){s+=" ("+p+" !== undefined && typeof "+p+" != 'string') || "}s+=" (";if(u!="ignore"){s+=" ("+p+" && !"+v+" ";if(h){s+=" && self._opts.unknownFormats.indexOf("+p+") == -1 "}s+=") || "}s+=" ("+v+" && "+b+" == '"+r+"' && !(typeof "+v+" == 'function' ? ";if(e.async){s+=" (async"+i+" ? await "+v+"("+a+") : "+v+"("+a+")) "}else{s+=" "+v+"("+a+") "}s+=" : "+v+".test("+a+"))))) {"}else{var v=e.formats[l];if(!v){if(u=="ignore"){e.logger.warn('unknown format "'+l+'" ignored in schema at path "'+e.errSchemaPath+'"');if(c){s+=" if (true) { "}return s}else if(h&&u.indexOf(l)>=0){if(c){s+=" if (true) { "}return s}else{throw new Error('unknown format "'+l+'" is used in schema at path "'+e.errSchemaPath+'"')}}var g=typeof v=="object"&&!(v instanceof RegExp)&&v.validate;var b=g&&v.type||"string";if(g){var w=v.async===true;v=v.validate}if(b!=r){if(c){s+=" if (true) { "}return s}if(w){if(!e.async)throw new Error("async format in sync schema");var y="formats"+e.util.getProperty(l)+".validate";s+=" if (!(await "+y+"("+a+"))) { "}else{s+=" if (! ";var y="formats"+e.util.getProperty(l);if(g)y+=".validate";if(typeof v=="function"){s+=" "+y+"("+a+") "}else{s+=" "+y+".test("+a+") "}s+=") { "}}var m=m||[];m.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"format"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { format: ";if(d){s+=""+p}else{s+=""+e.util.toQuotedString(l)}s+=" } ";if(e.opts.messages!==false){s+=" , message: 'should match format \"";if(d){s+="' + "+p+" + '"}else{s+=""+e.util.escapeQuotes(l)}s+="\"' "}if(e.opts.verbose){s+=" , schema: ";if(d){s+="validate.schema"+t}else{s+=""+e.util.toQuotedString(l)}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var E=s;s=m.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+E+"]); "}else{s+=" validate.errors = ["+E+"]; return false; "}}else{s+=" var err = "+E+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } ";if(c){s+=" else { "}return s}},3973:e=>{"use strict";e.exports=function generate_if(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p="errs__"+i;var u=e.util.copy(e);u.level++;var h="valid"+u.level;var v=e.schema["then"],g=e.schema["else"],b=v!==undefined&&(e.opts.strictKeywords?typeof v=="object"&&Object.keys(v).length>0||v===false:e.util.schemaHasRules(v,e.RULES.all)),w=g!==undefined&&(e.opts.strictKeywords?typeof g=="object"&&Object.keys(g).length>0||g===false:e.util.schemaHasRules(g,e.RULES.all)),y=u.baseId;if(b||w){var m;u.createErrors=false;u.schema=l;u.schemaPath=t;u.errSchemaPath=o;s+=" var "+p+" = errors; var "+d+" = true; ";var E=e.compositeRule;e.compositeRule=u.compositeRule=true;s+=" "+e.validate(u)+" ";u.baseId=y;u.createErrors=true;s+=" errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; } ";e.compositeRule=u.compositeRule=E;if(b){s+=" if ("+h+") { ";u.schema=e.schema["then"];u.schemaPath=e.schemaPath+".then";u.errSchemaPath=e.errSchemaPath+"/then";s+=" "+e.validate(u)+" ";u.baseId=y;s+=" "+d+" = "+h+"; ";if(b&&w){m="ifClause"+i;s+=" var "+m+" = 'then'; "}else{m="'then'"}s+=" } ";if(w){s+=" else { "}}else{s+=" if (!"+h+") { "}if(w){u.schema=e.schema["else"];u.schemaPath=e.schemaPath+".else";u.errSchemaPath=e.errSchemaPath+"/else";s+=" "+e.validate(u)+" ";u.baseId=y;s+=" "+d+" = "+h+"; ";if(b&&w){m="ifClause"+i;s+=" var "+m+" = 'else'; "}else{m="'else'"}s+=" } "}s+=" if (!"+d+") { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"if"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { failingKeyword: "+m+" } ";if(e.opts.messages!==false){s+=" , message: 'should match \"' + "+m+" + '\" schema' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(vErrors); "}else{s+=" validate.errors = vErrors; return false; "}}s+=" } ";if(c){s+=" else { "}}else{if(c){s+=" if (true) { "}}return s}},1676:(e,n,r)=>{"use strict";e.exports={$ref:r(9873),allOf:r(6981),anyOf:r(8138),$comment:r(3090),const:r(2645),contains:r(640),dependencies:r(9466),enum:r(4684),format:r(924),if:r(3973),items:r(5136),maximum:r(5702),minimum:r(5702),maxItems:r(2931),minItems:r(2931),maxLength:r(4583),minLength:r(4583),maxProperties:r(1679),minProperties:r(1679),multipleOf:r(9467),not:r(6223),oneOf:r(61),pattern:r(1819),properties:r(3548),propertyNames:r(2379),required:r(7805),uniqueItems:r(447),validate:r(7752)}},5136:e=>{"use strict";e.exports=function generate_items(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p="errs__"+i;var u=e.util.copy(e);var h="";u.level++;var v="valid"+u.level;var g="i"+i,b=u.dataLevel=e.dataLevel+1,w="data"+b,y=e.baseId;s+="var "+p+" = errors;var "+d+";";if(Array.isArray(l)){var m=e.schema.additionalItems;if(m===false){s+=" "+d+" = "+a+".length <= "+l.length+"; ";var E=o;o=e.errSchemaPath+"/additionalItems";s+=" if (!"+d+") { ";var S=S||[];S.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"additionalItems"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { limit: "+l.length+" } ";if(e.opts.messages!==false){s+=" , message: 'should NOT have more than "+l.length+" items' "}if(e.opts.verbose){s+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var C=s;s=S.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+C+"]); "}else{s+=" validate.errors = ["+C+"]; return false; "}}else{s+=" var err = "+C+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } ";o=E;if(c){h+="}";s+=" else { "}}var O=l;if(O){var A,R=-1,k=O.length-1;while(R<k){A=O[R+=1];if(e.opts.strictKeywords?typeof A=="object"&&Object.keys(A).length>0||A===false:e.util.schemaHasRules(A,e.RULES.all)){s+=" "+v+" = true; if ("+a+".length > "+R+") { ";var I=a+"["+R+"]";u.schema=A;u.schemaPath=t+"["+R+"]";u.errSchemaPath=o+"/"+R;u.errorPath=e.util.getPathExpr(e.errorPath,R,e.opts.jsonPointers,true);u.dataPathArr[b]=R;var T=e.validate(u);u.baseId=y;if(e.util.varOccurences(T,w)<2){s+=" "+e.util.varReplace(T,w,I)+" "}else{s+=" var "+w+" = "+I+"; "+T+" "}s+=" } ";if(c){s+=" if ("+v+") { ";h+="}"}}}}if(typeof m=="object"&&(e.opts.strictKeywords?typeof m=="object"&&Object.keys(m).length>0||m===false:e.util.schemaHasRules(m,e.RULES.all))){u.schema=m;u.schemaPath=e.schemaPath+".additionalItems";u.errSchemaPath=e.errSchemaPath+"/additionalItems";s+=" "+v+" = true; if ("+a+".length > "+l.length+") { for (var "+g+" = "+l.length+"; "+g+" < "+a+".length; "+g+"++) { ";u.errorPath=e.util.getPathExpr(e.errorPath,g,e.opts.jsonPointers,true);var I=a+"["+g+"]";u.dataPathArr[b]=g;var T=e.validate(u);u.baseId=y;if(e.util.varOccurences(T,w)<2){s+=" "+e.util.varReplace(T,w,I)+" "}else{s+=" var "+w+" = "+I+"; "+T+" "}if(c){s+=" if (!"+v+") break; "}s+=" } } ";if(c){s+=" if ("+v+") { ";h+="}"}}}else if(e.opts.strictKeywords?typeof l=="object"&&Object.keys(l).length>0||l===false:e.util.schemaHasRules(l,e.RULES.all)){u.schema=l;u.schemaPath=t;u.errSchemaPath=o;s+=" for (var "+g+" = "+0+"; "+g+" < "+a+".length; "+g+"++) { ";u.errorPath=e.util.getPathExpr(e.errorPath,g,e.opts.jsonPointers,true);var I=a+"["+g+"]";u.dataPathArr[b]=g;var T=e.validate(u);u.baseId=y;if(e.util.varOccurences(T,w)<2){s+=" "+e.util.varReplace(T,w,I)+" "}else{s+=" var "+w+" = "+I+"; "+T+" "}if(c){s+=" if (!"+v+") break; "}s+=" }"}if(c){s+=" "+h+" if ("+p+" == errors) {"}return s}},9467:e=>{"use strict";e.exports=function generate_multipleOf(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d=e.opts.$data&&l&&l.$data,p;if(d){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";p="schema"+i}else{p=l}if(!(d||typeof l=="number")){throw new Error(n+" must be number")}s+="var division"+i+";if (";if(d){s+=" "+p+" !== undefined && ( typeof "+p+" != 'number' || "}s+=" (division"+i+" = "+a+" / "+p+", ";if(e.opts.multipleOfPrecision){s+=" Math.abs(Math.round(division"+i+") - division"+i+") > 1e-"+e.opts.multipleOfPrecision+" "}else{s+=" division"+i+" !== parseInt(division"+i+") "}s+=" ) ";if(d){s+=" ) "}s+=" ) { ";var u=u||[];u.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"multipleOf"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { multipleOf: "+p+" } ";if(e.opts.messages!==false){s+=" , message: 'should be multiple of ";if(d){s+="' + "+p}else{s+=""+p+"'"}}if(e.opts.verbose){s+=" , schema: ";if(d){s+="validate.schema"+t}else{s+=""+l}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var h=s;s=u.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+h+"]); "}else{s+=" validate.errors = ["+h+"]; return false; "}}else{s+=" var err = "+h+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+="} ";if(c){s+=" else { "}return s}},6223:e=>{"use strict";e.exports=function generate_not(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="errs__"+i;var p=e.util.copy(e);p.level++;var u="valid"+p.level;if(e.opts.strictKeywords?typeof l=="object"&&Object.keys(l).length>0||l===false:e.util.schemaHasRules(l,e.RULES.all)){p.schema=l;p.schemaPath=t;p.errSchemaPath=o;s+=" var "+d+" = errors; ";var h=e.compositeRule;e.compositeRule=p.compositeRule=true;p.createErrors=false;var v;if(p.opts.allErrors){v=p.opts.allErrors;p.opts.allErrors=false}s+=" "+e.validate(p)+" ";p.createErrors=true;if(v)p.opts.allErrors=v;e.compositeRule=p.compositeRule=h;s+=" if ("+u+") { ";var g=g||[];g.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"not"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: {} ";if(e.opts.messages!==false){s+=" , message: 'should NOT be valid' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var b=s;s=g.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+b+"]); "}else{s+=" validate.errors = ["+b+"]; return false; "}}else{s+=" var err = "+b+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } else { errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; } ";if(e.opts.allErrors){s+=" } "}}else{s+=" var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"not"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: {} ";if(e.opts.messages!==false){s+=" , message: 'should NOT be valid' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(c){s+=" if (false) { "}}return s}},61:e=>{"use strict";e.exports=function generate_oneOf(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p="errs__"+i;var u=e.util.copy(e);var h="";u.level++;var v="valid"+u.level;var g=u.baseId,b="prevValid"+i,w="passingSchemas"+i;s+="var "+p+" = errors , "+b+" = false , "+d+" = false , "+w+" = null; ";var y=e.compositeRule;e.compositeRule=u.compositeRule=true;var m=l;if(m){var E,S=-1,C=m.length-1;while(S<C){E=m[S+=1];if(e.opts.strictKeywords?typeof E=="object"&&Object.keys(E).length>0||E===false:e.util.schemaHasRules(E,e.RULES.all)){u.schema=E;u.schemaPath=t+"["+S+"]";u.errSchemaPath=o+"/"+S;s+=" "+e.validate(u)+" ";u.baseId=g}else{s+=" var "+v+" = true; "}if(S){s+=" if ("+v+" && "+b+") { "+d+" = false; "+w+" = ["+w+", "+S+"]; } else { ";h+="}"}s+=" if ("+v+") { "+d+" = "+b+" = true; "+w+" = "+S+"; }"}}e.compositeRule=u.compositeRule=y;s+=""+h+"if (!"+d+") { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"oneOf"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { passingSchemas: "+w+" } ";if(e.opts.messages!==false){s+=" , message: 'should match exactly one schema in oneOf' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(vErrors); "}else{s+=" validate.errors = vErrors; return false; "}}s+="} else { errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; }";if(e.opts.allErrors){s+=" } "}return s}},1819:e=>{"use strict";e.exports=function generate_pattern(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d=e.opts.$data&&l&&l.$data,p;if(d){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";p="schema"+i}else{p=l}var u=d?"(new RegExp("+p+"))":e.usePattern(l);s+="if ( ";if(d){s+=" ("+p+" !== undefined && typeof "+p+" != 'string') || "}s+=" !"+u+".test("+a+") ) { ";var h=h||[];h.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"pattern"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { pattern: ";if(d){s+=""+p}else{s+=""+e.util.toQuotedString(l)}s+=" } ";if(e.opts.messages!==false){s+=" , message: 'should match pattern \"";if(d){s+="' + "+p+" + '"}else{s+=""+e.util.escapeQuotes(l)}s+="\"' "}if(e.opts.verbose){s+=" , schema: ";if(d){s+="validate.schema"+t}else{s+=""+e.util.toQuotedString(l)}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var v=s;s=h.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+v+"]); "}else{s+=" validate.errors = ["+v+"]; return false; "}}else{s+=" var err = "+v+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+="} ";if(c){s+=" else { "}return s}},3548:e=>{"use strict";e.exports=function generate_properties(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="errs__"+i;var p=e.util.copy(e);var u="";p.level++;var h="valid"+p.level;var v="key"+i,g="idx"+i,b=p.dataLevel=e.dataLevel+1,w="data"+b,y="dataProperties"+i;var m=Object.keys(l||{}).filter(notProto),E=e.schema.patternProperties||{},S=Object.keys(E).filter(notProto),C=e.schema.additionalProperties,O=m.length||S.length,A=C===false,R=typeof C=="object"&&Object.keys(C).length,k=e.opts.removeAdditional,I=A||R||k,T=e.opts.ownProperties,x=e.baseId;var F=e.schema.required;if(F&&!(e.opts.$data&&F.$data)&&F.length<e.opts.loopRequired){var j=e.util.toHash(F)}function notProto(e){return e!=="__proto__"}s+="var "+d+" = errors;var "+h+" = true;";if(T){s+=" var "+y+" = undefined;"}if(I){if(T){s+=" "+y+" = "+y+" || Object.keys("+a+"); for (var "+g+"=0; "+g+"<"+y+".length; "+g+"++) { var "+v+" = "+y+"["+g+"]; "}else{s+=" for (var "+v+" in "+a+") { "}if(O){s+=" var isAdditional"+i+" = !(false ";if(m.length){if(m.length>8){s+=" || validate.schema"+t+".hasOwnProperty("+v+") "}else{var B=m;if(B){var L,M=-1,U=B.length-1;while(M<U){L=B[M+=1];s+=" || "+v+" == "+e.util.toQuotedString(L)+" "}}}}if(S.length){var D=S;if(D){var N,q=-1,z=D.length-1;while(q<z){N=D[q+=1];s+=" || "+e.usePattern(N)+".test("+v+") "}}}s+=" ); if (isAdditional"+i+") { "}if(k=="all"){s+=" delete "+a+"["+v+"]; "}else{var H=e.errorPath;var W="' + "+v+" + '";if(e.opts._errorDataPathProperty){e.errorPath=e.util.getPathExpr(e.errorPath,v,e.opts.jsonPointers)}if(A){if(k){s+=" delete "+a+"["+v+"]; "}else{s+=" "+h+" = false; ";var Y=o;o=e.errSchemaPath+"/additionalProperties";var G=G||[];G.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"additionalProperties"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { additionalProperty: '"+W+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is an invalid additional property"}else{s+="should NOT have additional properties"}s+="' "}if(e.opts.verbose){s+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var Q=s;s=G.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+Q+"]); "}else{s+=" validate.errors = ["+Q+"]; return false; "}}else{s+=" var err = "+Q+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}o=Y;if(c){s+=" break; "}}}else if(R){if(k=="failing"){s+=" var "+d+" = errors; ";var J=e.compositeRule;e.compositeRule=p.compositeRule=true;p.schema=C;p.schemaPath=e.schemaPath+".additionalProperties";p.errSchemaPath=e.errSchemaPath+"/additionalProperties";p.errorPath=e.opts._errorDataPathProperty?e.errorPath:e.util.getPathExpr(e.errorPath,v,e.opts.jsonPointers);var X=a+"["+v+"]";p.dataPathArr[b]=v;var Z=e.validate(p);p.baseId=x;if(e.util.varOccurences(Z,w)<2){s+=" "+e.util.varReplace(Z,w,X)+" "}else{s+=" var "+w+" = "+X+"; "+Z+" "}s+=" if (!"+h+") { errors = "+d+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+a+"["+v+"]; } ";e.compositeRule=p.compositeRule=J}else{p.schema=C;p.schemaPath=e.schemaPath+".additionalProperties";p.errSchemaPath=e.errSchemaPath+"/additionalProperties";p.errorPath=e.opts._errorDataPathProperty?e.errorPath:e.util.getPathExpr(e.errorPath,v,e.opts.jsonPointers);var X=a+"["+v+"]";p.dataPathArr[b]=v;var Z=e.validate(p);p.baseId=x;if(e.util.varOccurences(Z,w)<2){s+=" "+e.util.varReplace(Z,w,X)+" "}else{s+=" var "+w+" = "+X+"; "+Z+" "}if(c){s+=" if (!"+h+") break; "}}}e.errorPath=H}if(O){s+=" } "}s+=" } ";if(c){s+=" if ("+h+") { ";u+="}"}}var V=e.opts.useDefaults&&!e.compositeRule;if(m.length){var K=m;if(K){var L,P=-1,_=K.length-1;while(P<_){L=K[P+=1];var $=l[L];if(e.opts.strictKeywords?typeof $=="object"&&Object.keys($).length>0||$===false:e.util.schemaHasRules($,e.RULES.all)){var ee=e.util.getProperty(L),X=a+ee,ne=V&&$.default!==undefined;p.schema=$;p.schemaPath=t+ee;p.errSchemaPath=o+"/"+e.util.escapeFragment(L);p.errorPath=e.util.getPath(e.errorPath,L,e.opts.jsonPointers);p.dataPathArr[b]=e.util.toQuotedString(L);var Z=e.validate(p);p.baseId=x;if(e.util.varOccurences(Z,w)<2){Z=e.util.varReplace(Z,w,X);var re=X}else{var re=w;s+=" var "+w+" = "+X+"; "}if(ne){s+=" "+Z+" "}else{if(j&&j[L]){s+=" if ( "+re+" === undefined ";if(T){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(L)+"') "}s+=") { "+h+" = false; ";var H=e.errorPath,Y=o,se=e.util.escapeQuotes(L);if(e.opts._errorDataPathProperty){e.errorPath=e.util.getPath(H,L,e.opts.jsonPointers)}o=e.errSchemaPath+"/required";var G=G||[];G.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { missingProperty: '"+se+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is a required property"}else{s+="should have required property \\'"+se+"\\'"}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var Q=s;s=G.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+Q+"]); "}else{s+=" validate.errors = ["+Q+"]; return false; "}}else{s+=" var err = "+Q+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}o=Y;e.errorPath=H;s+=" } else { "}else{if(c){s+=" if ( "+re+" === undefined ";if(T){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(L)+"') "}s+=") { "+h+" = true; } else { "}else{s+=" if ("+re+" !== undefined ";if(T){s+=" && Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(L)+"') "}s+=" ) { "}}s+=" "+Z+" } "}}if(c){s+=" if ("+h+") { ";u+="}"}}}}if(S.length){var ie=S;if(ie){var N,fe=-1,le=ie.length-1;while(fe<le){N=ie[fe+=1];var $=E[N];if(e.opts.strictKeywords?typeof $=="object"&&Object.keys($).length>0||$===false:e.util.schemaHasRules($,e.RULES.all)){p.schema=$;p.schemaPath=e.schemaPath+".patternProperties"+e.util.getProperty(N);p.errSchemaPath=e.errSchemaPath+"/patternProperties/"+e.util.escapeFragment(N);if(T){s+=" "+y+" = "+y+" || Object.keys("+a+"); for (var "+g+"=0; "+g+"<"+y+".length; "+g+"++) { var "+v+" = "+y+"["+g+"]; "}else{s+=" for (var "+v+" in "+a+") { "}s+=" if ("+e.usePattern(N)+".test("+v+")) { ";p.errorPath=e.util.getPathExpr(e.errorPath,v,e.opts.jsonPointers);var X=a+"["+v+"]";p.dataPathArr[b]=v;var Z=e.validate(p);p.baseId=x;if(e.util.varOccurences(Z,w)<2){s+=" "+e.util.varReplace(Z,w,X)+" "}else{s+=" var "+w+" = "+X+"; "+Z+" "}if(c){s+=" if (!"+h+") break; "}s+=" } ";if(c){s+=" else "+h+" = true; "}s+=" } ";if(c){s+=" if ("+h+") { ";u+="}"}}}}}if(c){s+=" "+u+" if ("+d+" == errors) {"}return s}},2379:e=>{"use strict";e.exports=function generate_propertyNames(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="errs__"+i;var p=e.util.copy(e);var u="";p.level++;var h="valid"+p.level;s+="var "+d+" = errors;";if(e.opts.strictKeywords?typeof l=="object"&&Object.keys(l).length>0||l===false:e.util.schemaHasRules(l,e.RULES.all)){p.schema=l;p.schemaPath=t;p.errSchemaPath=o;var v="key"+i,g="idx"+i,b="i"+i,w="' + "+v+" + '",y=p.dataLevel=e.dataLevel+1,m="data"+y,E="dataProperties"+i,S=e.opts.ownProperties,C=e.baseId;if(S){s+=" var "+E+" = undefined; "}if(S){s+=" "+E+" = "+E+" || Object.keys("+a+"); for (var "+g+"=0; "+g+"<"+E+".length; "+g+"++) { var "+v+" = "+E+"["+g+"]; "}else{s+=" for (var "+v+" in "+a+") { "}s+=" var startErrs"+i+" = errors; ";var O=v;var A=e.compositeRule;e.compositeRule=p.compositeRule=true;var R=e.validate(p);p.baseId=C;if(e.util.varOccurences(R,m)<2){s+=" "+e.util.varReplace(R,m,O)+" "}else{s+=" var "+m+" = "+O+"; "+R+" "}e.compositeRule=p.compositeRule=A;s+=" if (!"+h+") { for (var "+b+"=startErrs"+i+"; "+b+"<errors; "+b+"++) { vErrors["+b+"].propertyName = "+v+"; } var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"propertyNames"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { propertyName: '"+w+"' } ";if(e.opts.messages!==false){s+=" , message: 'property name \\'"+w+"\\' is invalid' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(vErrors); "}else{s+=" validate.errors = vErrors; return false; "}}if(c){s+=" break; "}s+=" } }"}if(c){s+=" "+u+" if ("+d+" == errors) {"}return s}},9873:e=>{"use strict";e.exports=function generate_ref(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.errSchemaPath+"/"+n;var o=!e.opts.allErrors;var c="data"+(f||"");var a="valid"+i;var d,p;if(l=="#"||l=="#/"){if(e.isRoot){d=e.async;p="validate"}else{d=e.root.schema.$async===true;p="root.refVal[0]"}}else{var u=e.resolveRef(e.baseId,l,e.isRoot);if(u===undefined){var h=e.MissingRefError.message(e.baseId,l);if(e.opts.missingRefs=="fail"){e.logger.error(h);var v=v||[];v.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"$ref"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(t)+" , params: { ref: '"+e.util.escapeQuotes(l)+"' } ";if(e.opts.messages!==false){s+=" , message: 'can\\'t resolve reference "+e.util.escapeQuotes(l)+"' "}if(e.opts.verbose){s+=" , schema: "+e.util.toQuotedString(l)+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+c+" "}s+=" } "}else{s+=" {} "}var g=s;s=v.pop();if(!e.compositeRule&&o){if(e.async){s+=" throw new ValidationError(["+g+"]); "}else{s+=" validate.errors = ["+g+"]; return false; "}}else{s+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}if(o){s+=" if (false) { "}}else if(e.opts.missingRefs=="ignore"){e.logger.warn(h);if(o){s+=" if (true) { "}}else{throw new e.MissingRefError(e.baseId,l,h)}}else if(u.inline){var b=e.util.copy(e);b.level++;var w="valid"+b.level;b.schema=u.schema;b.schemaPath="";b.errSchemaPath=l;var y=e.validate(b).replace(/validate\.schema/g,u.code);s+=" "+y+" ";if(o){s+=" if ("+w+") { "}}else{d=u.$async===true||e.async&&u.$async!==false;p=u.code}}if(p){var v=v||[];v.push(s);s="";if(e.opts.passContext){s+=" "+p+".call(this, "}else{s+=" "+p+"( "}s+=" "+c+", (dataPath || '')";if(e.errorPath!='""'){s+=" + "+e.errorPath}var m=f?"data"+(f-1||""):"parentData",E=f?e.dataPathArr[f]:"parentDataProperty";s+=" , "+m+" , "+E+", rootData) ";var S=s;s=v.pop();if(d){if(!e.async)throw new Error("async schema referenced by sync schema");if(o){s+=" var "+a+"; "}s+=" try { await "+S+"; ";if(o){s+=" "+a+" = 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; ";if(o){s+=" "+a+" = false; "}s+=" } ";if(o){s+=" if ("+a+") { "}}else{s+=" if (!"+S+") { if (vErrors === null) vErrors = "+p+".errors; else vErrors = vErrors.concat("+p+".errors); errors = vErrors.length; } ";if(o){s+=" else { "}}}return s}},7805:e=>{"use strict";e.exports=function generate_required(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}var h="schema"+i;if(!p){if(l.length<e.opts.loopRequired&&e.schema.properties&&Object.keys(e.schema.properties).length){var v=[];var g=l;if(g){var b,w=-1,y=g.length-1;while(w<y){b=g[w+=1];var m=e.schema.properties[b];if(!(m&&(e.opts.strictKeywords?typeof m=="object"&&Object.keys(m).length>0||m===false:e.util.schemaHasRules(m,e.RULES.all)))){v[v.length]=b}}}}else{var v=l}}if(p||v.length){var E=e.errorPath,S=p||v.length>=e.opts.loopRequired,C=e.opts.ownProperties;if(c){s+=" var missing"+i+"; ";if(S){if(!p){s+=" var "+h+" = validate.schema"+t+"; "}var O="i"+i,A="schema"+i+"["+O+"]",R="' + "+A+" + '";if(e.opts._errorDataPathProperty){e.errorPath=e.util.getPathExpr(E,A,e.opts.jsonPointers)}s+=" var "+d+" = true; ";if(p){s+=" if (schema"+i+" === undefined) "+d+" = true; else if (!Array.isArray(schema"+i+")) "+d+" = false; else {"}s+=" for (var "+O+" = 0; "+O+" < "+h+".length; "+O+"++) { "+d+" = "+a+"["+h+"["+O+"]] !== undefined ";if(C){s+=" && Object.prototype.hasOwnProperty.call("+a+", "+h+"["+O+"]) "}s+="; if (!"+d+") break; } ";if(p){s+=" } "}s+=" if (!"+d+") { ";var k=k||[];k.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { missingProperty: '"+R+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is a required property"}else{s+="should have required property \\'"+R+"\\'"}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var I=s;s=k.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+I+"]); "}else{s+=" validate.errors = ["+I+"]; return false; "}}else{s+=" var err = "+I+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } else { "}else{s+=" if ( ";var T=v;if(T){var x,O=-1,F=T.length-1;while(O<F){x=T[O+=1];if(O){s+=" || "}var j=e.util.getProperty(x),B=a+j;s+=" ( ( "+B+" === undefined ";if(C){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(x)+"') "}s+=") && (missing"+i+" = "+e.util.toQuotedString(e.opts.jsonPointers?x:j)+") ) "}}s+=") { ";var A="missing"+i,R="' + "+A+" + '";if(e.opts._errorDataPathProperty){e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(E,A,true):E+" + "+A}var k=k||[];k.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { missingProperty: '"+R+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is a required property"}else{s+="should have required property \\'"+R+"\\'"}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var I=s;s=k.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+I+"]); "}else{s+=" validate.errors = ["+I+"]; return false; "}}else{s+=" var err = "+I+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } else { "}}else{if(S){if(!p){s+=" var "+h+" = validate.schema"+t+"; "}var O="i"+i,A="schema"+i+"["+O+"]",R="' + "+A+" + '";if(e.opts._errorDataPathProperty){e.errorPath=e.util.getPathExpr(E,A,e.opts.jsonPointers)}if(p){s+=" if ("+h+" && !Array.isArray("+h+")) { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { missingProperty: '"+R+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is a required property"}else{s+="should have required property \\'"+R+"\\'"}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+h+" !== undefined) { "}s+=" for (var "+O+" = 0; "+O+" < "+h+".length; "+O+"++) { if ("+a+"["+h+"["+O+"]] === undefined ";if(C){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", "+h+"["+O+"]) "}s+=") { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { missingProperty: '"+R+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is a required property"}else{s+="should have required property \\'"+R+"\\'"}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ";if(p){s+=" } "}}else{var L=v;if(L){var x,M=-1,U=L.length-1;while(M<U){x=L[M+=1];var j=e.util.getProperty(x),R=e.util.escapeQuotes(x),B=a+j;if(e.opts._errorDataPathProperty){e.errorPath=e.util.getPath(E,x,e.opts.jsonPointers)}s+=" if ( "+B+" === undefined ";if(C){s+=" || ! Object.prototype.hasOwnProperty.call("+a+", '"+e.util.escapeQuotes(x)+"') "}s+=") { var err = ";if(e.createErrors!==false){s+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { missingProperty: '"+R+"' } ";if(e.opts.messages!==false){s+=" , message: '";if(e.opts._errorDataPathProperty){s+="is a required property"}else{s+="should have required property \\'"+R+"\\'"}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}}}e.errorPath=E}else if(c){s+=" if (true) {"}return s}},447:e=>{"use strict";e.exports=function generate_uniqueItems(e,n,r){var s=" ";var i=e.level;var f=e.dataLevel;var l=e.schema[n];var t=e.schemaPath+e.util.getProperty(n);var o=e.errSchemaPath+"/"+n;var c=!e.opts.allErrors;var a="data"+(f||"");var d="valid"+i;var p=e.opts.$data&&l&&l.$data,u;if(p){s+=" var schema"+i+" = "+e.util.getData(l.$data,f,e.dataPathArr)+"; ";u="schema"+i}else{u=l}if((l||p)&&e.opts.uniqueItems!==false){if(p){s+=" var "+d+"; if ("+u+" === false || "+u+" === undefined) "+d+" = true; else if (typeof "+u+" != 'boolean') "+d+" = false; else { "}s+=" var i = "+a+".length , "+d+" = true , j; if (i > 1) { ";var h=e.schema.items&&e.schema.items.type,v=Array.isArray(h);if(!h||h=="object"||h=="array"||v&&(h.indexOf("object")>=0||h.indexOf("array")>=0)){s+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+a+"[i], "+a+"[j])) { "+d+" = false; break outer; } } } "}else{s+=" var itemIndices = {}, item; for (;i--;) { var item = "+a+"[i]; ";var g="checkDataType"+(v?"s":"");s+=" if ("+e.util[g](h,"item",e.opts.strictNumbers,true)+") continue; ";if(v){s+=" if (typeof item == 'string') item = '\"' + item; "}s+=" if (typeof itemIndices[item] == 'number') { "+d+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}s+=" } ";if(p){s+=" } "}s+=" if (!"+d+") { ";var b=b||[];b.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+"uniqueItems"+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(o)+" , params: { i: i, j: j } ";if(e.opts.messages!==false){s+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "}if(e.opts.verbose){s+=" , schema: ";if(p){s+="validate.schema"+t}else{s+=""+l}s+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+a+" "}s+=" } "}else{s+=" {} "}var w=s;s=b.pop();if(!e.compositeRule&&c){if(e.async){s+=" throw new ValidationError(["+w+"]); "}else{s+=" validate.errors = ["+w+"]; return false; "}}else{s+=" var err = "+w+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } ";if(c){s+=" else { "}}else{if(c){s+=" if (true) { "}}return s}},7752:e=>{"use strict";e.exports=function generate_validate(e,n,r){var s="";var i=e.schema.$async===true,f=e.util.schemaHasRulesExcept(e.schema,e.RULES.all,"$ref"),l=e.self._getId(e.schema);if(e.opts.strictKeywords){var t=e.util.schemaUnknownRules(e.schema,e.RULES.keywords);if(t){var o="unknown keyword: "+t;if(e.opts.strictKeywords==="log")e.logger.warn(o);else throw new Error(o)}}if(e.isTop){s+=" var validate = ";if(i){e.async=true;s+="async "}s+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ";if(l&&(e.opts.sourceCode||e.opts.processCode)){s+=" "+("/*# sourceURL="+l+" */")+" "}}if(typeof e.schema=="boolean"||!(f||e.schema.$ref)){var n="false schema";var c=e.level;var a=e.dataLevel;var d=e.schema[n];var p=e.schemaPath+e.util.getProperty(n);var u=e.errSchemaPath+"/"+n;var h=!e.opts.allErrors;var v;var g="data"+(a||"");var b="valid"+c;if(e.schema===false){if(e.isTop){h=true}else{s+=" var "+b+" = false; "}var w=w||[];w.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(v||"false schema")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(u)+" , params: {} ";if(e.opts.messages!==false){s+=" , message: 'boolean schema is false' "}if(e.opts.verbose){s+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+g+" "}s+=" } "}else{s+=" {} "}var y=s;s=w.pop();if(!e.compositeRule&&h){if(e.async){s+=" throw new ValidationError(["+y+"]); "}else{s+=" validate.errors = ["+y+"]; return false; "}}else{s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}}else{if(e.isTop){if(i){s+=" return data; "}else{s+=" validate.errors = null; return true; "}}else{s+=" var "+b+" = true; "}}if(e.isTop){s+=" }; return validate; "}return s}if(e.isTop){var m=e.isTop,c=e.level=0,a=e.dataLevel=0,g="data";e.rootId=e.resolve.fullPath(e.self._getId(e.root.schema));e.baseId=e.baseId||e.rootId;delete e.isTop;e.dataPathArr=[""];if(e.schema.default!==undefined&&e.opts.useDefaults&&e.opts.strictDefaults){var E="default is ignored in the schema root";if(e.opts.strictDefaults==="log")e.logger.warn(E);else throw new Error(E)}s+=" var vErrors = null; ";s+=" var errors = 0; ";s+=" if (rootData === undefined) rootData = data; "}else{var c=e.level,a=e.dataLevel,g="data"+(a||"");if(l)e.baseId=e.resolve.url(e.baseId,l);if(i&&!e.async)throw new Error("async schema in sync schema");s+=" var errs_"+c+" = errors;"}var b="valid"+c,h=!e.opts.allErrors,S="",C="";var v;var O=e.schema.type,A=Array.isArray(O);if(O&&e.opts.nullable&&e.schema.nullable===true){if(A){if(O.indexOf("null")==-1)O=O.concat("null")}else if(O!="null"){O=[O,"null"];A=true}}if(A&&O.length==1){O=O[0];A=false}if(e.schema.$ref&&f){if(e.opts.extendRefs=="fail"){throw new Error('$ref: validation keywords used in schema at path "'+e.errSchemaPath+'" (see option extendRefs)')}else if(e.opts.extendRefs!==true){f=false;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")}if(O){if(e.opts.coerceTypes){var R=e.util.coerceToTypes(e.opts.coerceTypes,O)}var k=e.RULES.types[O];if(R||A||k===true||k&&!$shouldUseGroup(k)){var p=e.schemaPath+".type",u=e.errSchemaPath+"/type";var p=e.schemaPath+".type",u=e.errSchemaPath+"/type",I=A?"checkDataTypes":"checkDataType";s+=" if ("+e.util[I](O,g,e.opts.strictNumbers,true)+") { ";if(R){var T="dataType"+c,x="coerced"+c;s+=" var "+T+" = typeof "+g+"; var "+x+" = undefined; ";if(e.opts.coerceTypes=="array"){s+=" if ("+T+" == 'object' && Array.isArray("+g+") && "+g+".length == 1) { "+g+" = "+g+"[0]; "+T+" = typeof "+g+"; if ("+e.util.checkDataType(e.schema.type,g,e.opts.strictNumbers)+") "+x+" = "+g+"; } "}s+=" if ("+x+" !== undefined) ; ";var F=R;if(F){var j,B=-1,L=F.length-1;while(B<L){j=F[B+=1];if(j=="string"){s+=" else if ("+T+" == 'number' || "+T+" == 'boolean') "+x+" = '' + "+g+"; else if ("+g+" === null) "+x+" = ''; "}else if(j=="number"||j=="integer"){s+=" else if ("+T+" == 'boolean' || "+g+" === null || ("+T+" == 'string' && "+g+" && "+g+" == +"+g+" ";if(j=="integer"){s+=" && !("+g+" % 1)"}s+=")) "+x+" = +"+g+"; "}else if(j=="boolean"){s+=" else if ("+g+" === 'false' || "+g+" === 0 || "+g+" === null) "+x+" = false; else if ("+g+" === 'true' || "+g+" === 1) "+x+" = true; "}else if(j=="null"){s+=" else if ("+g+" === '' || "+g+" === 0 || "+g+" === false) "+x+" = null; "}else if(e.opts.coerceTypes=="array"&&j=="array"){s+=" else if ("+T+" == 'string' || "+T+" == 'number' || "+T+" == 'boolean' || "+g+" == null) "+x+" = ["+g+"]; "}}}s+=" else { ";var w=w||[];w.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(v||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(u)+" , params: { type: '";if(A){s+=""+O.join(",")}else{s+=""+O}s+="' } ";if(e.opts.messages!==false){s+=" , message: 'should be ";if(A){s+=""+O.join(",")}else{s+=""+O}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+p+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+g+" "}s+=" } "}else{s+=" {} "}var y=s;s=w.pop();if(!e.compositeRule&&h){if(e.async){s+=" throw new ValidationError(["+y+"]); "}else{s+=" validate.errors = ["+y+"]; return false; "}}else{s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } if ("+x+" !== undefined) { ";var M=a?"data"+(a-1||""):"parentData",U=a?e.dataPathArr[a]:"parentDataProperty";s+=" "+g+" = "+x+"; ";if(!a){s+="if ("+M+" !== undefined)"}s+=" "+M+"["+U+"] = "+x+"; } "}else{var w=w||[];w.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(v||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(u)+" , params: { type: '";if(A){s+=""+O.join(",")}else{s+=""+O}s+="' } ";if(e.opts.messages!==false){s+=" , message: 'should be ";if(A){s+=""+O.join(",")}else{s+=""+O}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+p+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+g+" "}s+=" } "}else{s+=" {} "}var y=s;s=w.pop();if(!e.compositeRule&&h){if(e.async){s+=" throw new ValidationError(["+y+"]); "}else{s+=" validate.errors = ["+y+"]; return false; "}}else{s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}}s+=" } "}}if(e.schema.$ref&&!f){s+=" "+e.RULES.all.$ref.code(e,"$ref")+" ";if(h){s+=" } if (errors === ";if(m){s+="0"}else{s+="errs_"+c}s+=") { ";C+="}"}}else{var D=e.RULES;if(D){var k,N=-1,q=D.length-1;while(N<q){k=D[N+=1];if($shouldUseGroup(k)){if(k.type){s+=" if ("+e.util.checkDataType(k.type,g,e.opts.strictNumbers)+") { "}if(e.opts.useDefaults){if(k.type=="object"&&e.schema.properties){var d=e.schema.properties,z=Object.keys(d);var H=z;if(H){var W,Y=-1,G=H.length-1;while(Y<G){W=H[Y+=1];var Q=d[W];if(Q.default!==undefined){var J=g+e.util.getProperty(W);if(e.compositeRule){if(e.opts.strictDefaults){var E="default is ignored for: "+J;if(e.opts.strictDefaults==="log")e.logger.warn(E);else throw new Error(E)}}else{s+=" if ("+J+" === undefined ";if(e.opts.useDefaults=="empty"){s+=" || "+J+" === null || "+J+" === '' "}s+=" ) "+J+" = ";if(e.opts.useDefaults=="shared"){s+=" "+e.useDefault(Q.default)+" "}else{s+=" "+JSON.stringify(Q.default)+" "}s+="; "}}}}}else if(k.type=="array"&&Array.isArray(e.schema.items)){var X=e.schema.items;if(X){var Q,B=-1,Z=X.length-1;while(B<Z){Q=X[B+=1];if(Q.default!==undefined){var J=g+"["+B+"]";if(e.compositeRule){if(e.opts.strictDefaults){var E="default is ignored for: "+J;if(e.opts.strictDefaults==="log")e.logger.warn(E);else throw new Error(E)}}else{s+=" if ("+J+" === undefined ";if(e.opts.useDefaults=="empty"){s+=" || "+J+" === null || "+J+" === '' "}s+=" ) "+J+" = ";if(e.opts.useDefaults=="shared"){s+=" "+e.useDefault(Q.default)+" "}else{s+=" "+JSON.stringify(Q.default)+" "}s+="; "}}}}}}var V=k.rules;if(V){var K,P=-1,_=V.length-1;while(P<_){K=V[P+=1];if($shouldUseRule(K)){var $=K.code(e,K.keyword,k.type);if($){s+=" "+$+" ";if(h){S+="}"}}}}}if(h){s+=" "+S+" ";S=""}if(k.type){s+=" } ";if(O&&O===k.type&&!R){s+=" else { ";var p=e.schemaPath+".type",u=e.errSchemaPath+"/type";var w=w||[];w.push(s);s="";if(e.createErrors!==false){s+=" { keyword: '"+(v||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(u)+" , params: { type: '";if(A){s+=""+O.join(",")}else{s+=""+O}s+="' } ";if(e.opts.messages!==false){s+=" , message: 'should be ";if(A){s+=""+O.join(",")}else{s+=""+O}s+="' "}if(e.opts.verbose){s+=" , schema: validate.schema"+p+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+g+" "}s+=" } "}else{s+=" {} "}var y=s;s=w.pop();if(!e.compositeRule&&h){if(e.async){s+=" throw new ValidationError(["+y+"]); "}else{s+=" validate.errors = ["+y+"]; return false; "}}else{s+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}s+=" } "}}if(h){s+=" if (errors === ";if(m){s+="0"}else{s+="errs_"+c}s+=") { ";C+="}"}}}}}if(h){s+=" "+C+" "}if(m){if(i){s+=" if (errors === 0) return data; ";s+=" else throw new ValidationError(vErrors); "}else{s+=" validate.errors = vErrors; ";s+=" return errors === 0; "}s+=" }; return validate;"}else{s+=" var "+b+" = errors === errs_"+c+";"}function $shouldUseGroup(e){var n=e.rules;for(var r=0;r<n.length;r++)if($shouldUseRule(n[r]))return true}function $shouldUseRule(n){return e.schema[n.keyword]!==undefined||n.implements&&$ruleImplementsSomeKeyword(n)}function $ruleImplementsSomeKeyword(n){var r=n.implements;for(var s=0;s<r.length;s++)if(e.schema[r[s]]!==undefined)return true}return s}},5413:(e,n,r)=>{"use strict";var s=/^[a-z_$][a-z0-9_$-]*$/i;var i=r(4741);var f=r(2059);e.exports={add:addKeyword,get:getKeyword,remove:removeKeyword,validate:validateKeyword};function addKeyword(e,n){var r=this.RULES;if(r.keywords[e])throw new Error("Keyword "+e+" is already defined");if(!s.test(e))throw new Error("Keyword "+e+" is not a valid identifier");if(n){this.validateKeyword(n,true);var f=n.type;if(Array.isArray(f)){for(var l=0;l<f.length;l++)_addRule(e,f[l],n)}else{_addRule(e,f,n)}var t=n.metaSchema;if(t){if(n.$data&&this._opts.$data){t={anyOf:[t,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}}n.validateSchema=this.compile(t,true)}}r.keywords[e]=r.all[e]=true;function _addRule(e,n,s){var f;for(var l=0;l<r.length;l++){var t=r[l];if(t.type==n){f=t;break}}if(!f){f={type:n,rules:[]};r.push(f)}var o={keyword:e,definition:s,custom:true,code:i,implements:s.implements};f.rules.push(o);r.custom[e]=o}return this}function getKeyword(e){var n=this.RULES.custom[e];return n?n.definition:this.RULES.keywords[e]||false}function removeKeyword(e){var n=this.RULES;delete n.keywords[e];delete n.all[e];delete n.custom[e];for(var r=0;r<n.length;r++){var s=n[r].rules;for(var i=0;i<s.length;i++){if(s[i].keyword==e){s.splice(i,1);break}}}return this}function validateKeyword(e,n){validateKeyword.errors=null;var r=this._validateKeyword=this._validateKeyword||this.compile(f,true);if(r(e))return true;validateKeyword.errors=r.errors;if(n)throw new Error("custom keyword definition is invalid: "+this.errorsText(r.errors));else return false}},7762:e=>{e.exports=(e=>{const n=process.versions.node.split(".").map(e=>parseInt(e,10));e=e.split(".").map(e=>parseInt(e,10));return n[0]>e[0]||n[0]===e[0]&&(n[1]>e[1]||n[1]===e[1]&&n[2]>=e[2])})},3802:(e,n,r)=>{"use strict";const s=r(1338);const i=r(4455)("$$bole",{fastTime:false});const f=r(4658);const l="debug info warn error".split(" ");const t=r(2087).hostname();const o=s(t);const c=process.pid;let a=false;const d=[];for(const e of l){d[e]=',"hostname":'+o+',"pid":'+c+',"level":"'+e;Number(d[e]);if(!Array.isArray(i[e])){i[e]=[]}}function stackToString(e){let n=e.stack;let r;if(typeof e.cause==="function"&&(r=e.cause())){n+="\nCaused by: "+stackToString(r)}return n}function errorToOut(e,n){n.err={name:e.name,message:e.message,code:e.code,stack:stackToString(e)}}function requestToOut(e,n){n.req={method:e.method,url:e.url,headers:e.headers,remoteAddress:e.connection.remoteAddress,remotePort:e.connection.remotePort}}function objectToOut(e,n){for(const r in e){if(Object.prototype.hasOwnProperty.call(e,r)&&e[r]!==undefined){n[r]=e[r]}}}function objectMode(e){return e._writableState&&e._writableState.objectMode===true}function stringify(e,n,r,f){let l='{"time":'+(i.fastTime?Date.now():'"'+(new Date).toISOString()+'"')+d[e]+'","name":'+n+(r!==undefined?',"message":'+s(r):"");for(const e in f){l+=","+s(e)+":"+s(f[e])}l+="}";Number(l);return l}function extend(e,n,r,s){const f={time:i.fastTime?Date.now():(new Date).toISOString(),hostname:t,pid:c,level:e,name:n};if(r!==undefined){s.message=r}for(const e in s){f[e]=s[e]}return f}function levelLogger(e,n){const r=i[e];const l=s(n);return function namedLevelLogger(s,i,t,o,c,d,p,u,h,v,g,b,w,y,m,E){if(r.length===0){return}const S={};let C;let O=0;const A=r.length;let R;let k;if(typeof s==="string"||s==null){if(!(k=f(s,i,t,o,c,d,p,u,h,v,g,b,w,y,m,E))){k=undefined}}else{if(s instanceof Error){if(typeof i==="object"){objectToOut(i,S);errorToOut(s,S);if(!(k=f(t,o,c,d,p,u,h,v,g,b,w,y,m,E))){k=undefined}}else{errorToOut(s,S);if(!(k=f(i,t,o,c,d,p,u,h,v,g,b,w,y,m,E))){k=undefined}}}else{if(!(k=f(i,t,o,c,d,p,u,h,v,g,b,w,y,m,E))){k=undefined}}if(typeof s==="boolean"){k=String(s)}else if(typeof s==="object"&&!(s instanceof Error)){if(s.method&&s.url&&s.headers&&s.socket){requestToOut(s,S)}else{objectToOut(s,S)}}}if(A===1&&!a){r[0].write(Buffer.from(stringify(e,l,k,S)+"\n"));return}for(;O<A;O++){if(objectMode(r[O])){if(C===undefined){C=extend(e,n,k,S)}r[O].write(C)}else{if(R===undefined){R=Buffer.from(stringify(e,l,k,S)+"\n")}r[O].write(R)}}}}function bole(e){function boleLogger(n){return bole(e+":"+n)}function makeLogger(n,r){n[r]=levelLogger(r,e);return n}return l.reduce(makeLogger,boleLogger)}bole.output=function output(e){let n=false;if(Array.isArray(e)){e.forEach(bole.output);return bole}if(typeof e.level!=="string"){throw new TypeError('Must provide a "level" option')}for(const r of l){if(!n&&r===e.level){n=true}if(n){if(e.stream&&objectMode(e.stream)){a=true}i[r].push(e.stream)}}return bole};bole.reset=function reset(){for(const e of l){i[e].splice(0,i[e].length)}i.fastTime=false;return bole};bole.setFastTime=function setFastTime(e){if(!arguments.length){i.fastTime=true}else{i.fastTime=e}return bole};e.exports=bole},4658:(e,n,r)=>{var s=r(1669).format;function format(e,n,r,i,f,l,t,o,c,a,d,p,u,h,v,g){if(g!==undefined){return s(e,n,r,i,f,l,t,o,c,a,d,p,u,h,v,g)}if(v!==undefined){return s(e,n,r,i,f,l,t,o,c,a,d,p,u,h,v)}if(h!==undefined){return s(e,n,r,i,f,l,t,o,c,a,d,p,u,h)}if(u!==undefined){return s(e,n,r,i,f,l,t,o,c,a,d,p,u)}if(p!==undefined){return s(e,n,r,i,f,l,t,o,c,a,d,p)}if(d!==undefined){return s(e,n,r,i,f,l,t,o,c,a,d)}if(a!==undefined){return s(e,n,r,i,f,l,t,o,c,a)}if(c!==undefined){return s(e,n,r,i,f,l,t,o,c)}if(o!==undefined){return s(e,n,r,i,f,l,t,o)}if(t!==undefined){return s(e,n,r,i,f,l,t)}if(l!==undefined){return s(e,n,r,i,f,l)}if(f!==undefined){return s(e,n,r,i,f)}if(i!==undefined){return s(e,n,r,i)}if(r!==undefined){return s(e,n,r)}if(n!==undefined){return s(e,n)}return e}e.exports=format},6551:e=>{"use strict";function dataUriToBuffer(e){if(!/^data:/i.test(e)){throw new TypeError('`uri` does not appear to be a Data URI (must begin with "data:")')}e=e.replace(/\r?\n/g,"");const n=e.indexOf(",");if(n===-1||n<=4){throw new TypeError("malformed data: URI")}const r=e.substring(5,n).split(";");let s="";let i=false;const f=r[0]||"text/plain";let l=f;for(let e=1;e<r.length;e++){if(r[e]==="base64"){i=true}else{l+=`;${r[e]}`;if(r[e].indexOf("charset=")===0){s=r[e].substring(8)}}}if(!r[0]&&!s.length){l+=";charset=US-ASCII";s="US-ASCII"}const t=i?"base64":"ascii";const o=unescape(e.substring(n+1));const c=Buffer.from(o,t);c.type=f;c.typeFull=l;c.charset=s;return c}e.exports=dataUriToBuffer},4631:(e,n,r)=>{n.formatArgs=formatArgs;n.save=save;n.load=load;n.useColors=useColors;n.storage=localstorage();n.destroy=(()=>{let e=false;return()=>{if(!e){e=true;console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}}})();n.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function useColors(){if(typeof window!=="undefined"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)){return true}if(typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)){return false}return typeof document!=="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!=="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!=="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function formatArgs(n){n[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+n[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff);if(!this.useColors){return}const r="color: "+this.color;n.splice(1,0,r,"color: inherit");let s=0;let i=0;n[0].replace(/%[a-zA-Z%]/g,e=>{if(e==="%%"){return}s++;if(e==="%c"){i=s}});n.splice(i,0,r)}n.log=console.debug||console.log||(()=>{});function save(e){try{if(e){n.storage.setItem("debug",e)}else{n.storage.removeItem("debug")}}catch(e){}}function load(){let e;try{e=n.storage.getItem("debug")}catch(e){}if(!e&&typeof process!=="undefined"&&"env"in process){e=process.env.DEBUG}return e}function localstorage(){try{return localStorage}catch(e){}}e.exports=r(5994)(n);const{formatters:s}=e.exports;s.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},5994:(e,n,r)=>{function setup(e){createDebug.debug=createDebug;createDebug.default=createDebug;createDebug.coerce=coerce;createDebug.disable=disable;createDebug.enable=enable;createDebug.enabled=enabled;createDebug.humanize=r(892);createDebug.destroy=destroy;Object.keys(e).forEach(n=>{createDebug[n]=e[n]});createDebug.names=[];createDebug.skips=[];createDebug.formatters={};function selectColor(e){let n=0;for(let r=0;r<e.length;r++){n=(n<<5)-n+e.charCodeAt(r);n|=0}return createDebug.colors[Math.abs(n)%createDebug.colors.length]}createDebug.selectColor=selectColor;function createDebug(e){let n;let r=null;let s;let i;function debug(...e){if(!debug.enabled){return}const r=debug;const s=Number(new Date);const i=s-(n||s);r.diff=i;r.prev=n;r.curr=s;n=s;e[0]=createDebug.coerce(e[0]);if(typeof e[0]!=="string"){e.unshift("%O")}let f=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(n,s)=>{if(n==="%%"){return"%"}f++;const i=createDebug.formatters[s];if(typeof i==="function"){const s=e[f];n=i.call(r,s);e.splice(f,1);f--}return n});createDebug.formatArgs.call(r,e);const l=r.log||createDebug.log;l.apply(r,e)}debug.namespace=e;debug.useColors=createDebug.useColors();debug.color=createDebug.selectColor(e);debug.extend=extend;debug.destroy=createDebug.destroy;Object.defineProperty(debug,"enabled",{enumerable:true,configurable:false,get:()=>{if(r!==null){return r}if(s!==createDebug.namespaces){s=createDebug.namespaces;i=createDebug.enabled(e)}return i},set:e=>{r=e}});if(typeof createDebug.init==="function"){createDebug.init(debug)}return debug}function extend(e,n){const r=createDebug(this.namespace+(typeof n==="undefined"?":":n)+e);r.log=this.log;return r}function enable(e){createDebug.save(e);createDebug.namespaces=e;createDebug.names=[];createDebug.skips=[];let n;const r=(typeof e==="string"?e:"").split(/[\s,]+/);const s=r.length;for(n=0;n<s;n++){if(!r[n]){continue}e=r[n].replace(/\*/g,".*?");if(e[0]==="-"){createDebug.skips.push(new RegExp("^"+e.substr(1)+"$"))}else{createDebug.names.push(new RegExp("^"+e+"$"))}}}function disable(){const e=[...createDebug.names.map(toNamespace),...createDebug.skips.map(toNamespace).map(e=>"-"+e)].join(",");createDebug.enable("");return e}function enabled(e){if(e[e.length-1]==="*"){return true}let n;let r;for(n=0,r=createDebug.skips.length;n<r;n++){if(createDebug.skips[n].test(e)){return false}}for(n=0,r=createDebug.names.length;n<r;n++){if(createDebug.names[n].test(e)){return true}}return false}function toNamespace(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}function coerce(e){if(e instanceof Error){return e.stack||e.message}return e}function destroy(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}createDebug.enable(createDebug.load());return createDebug}e.exports=setup},6782:(e,n,r)=>{if(typeof process==="undefined"||process.type==="renderer"||process.browser===true||process.__nwjs){e.exports=r(4631)}else{e.exports=r(6752)}},6752:(e,n,r)=>{const s=r(3867);const i=r(1669);n.init=init;n.log=log;n.formatArgs=formatArgs;n.save=save;n.load=load;n.useColors=useColors;n.destroy=i.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");n.colors=[6,2,3,4,5,1];try{const e=r(1415);if(e&&(e.stderr||e).level>=2){n.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}}catch(e){}n.inspectOpts=Object.keys(process.env).filter(e=>{return/^debug_/i.test(e)}).reduce((e,n)=>{const r=n.substring(6).toLowerCase().replace(/_([a-z])/g,(e,n)=>{return n.toUpperCase()});let s=process.env[n];if(/^(yes|on|true|enabled)$/i.test(s)){s=true}else if(/^(no|off|false|disabled)$/i.test(s)){s=false}else if(s==="null"){s=null}else{s=Number(s)}e[r]=s;return e},{});function useColors(){return"colors"in n.inspectOpts?Boolean(n.inspectOpts.colors):s.isatty(process.stderr.fd)}function formatArgs(n){const{namespace:r,useColors:s}=this;if(s){const s=this.color;const i="[3"+(s<8?s:"8;5;"+s);const f=` ${i};1m${r} [0m`;n[0]=f+n[0].split("\n").join("\n"+f);n.push(i+"m+"+e.exports.humanize(this.diff)+"[0m")}else{n[0]=getDate()+r+" "+n[0]}}function getDate(){if(n.inspectOpts.hideDate){return""}return(new Date).toISOString()+" "}function log(...e){return process.stderr.write(i.format(...e)+"\n")}function save(e){if(e){process.env.DEBUG=e}else{delete process.env.DEBUG}}function load(){return process.env.DEBUG}function init(e){e.inspectOpts={};const r=Object.keys(n.inspectOpts);for(let s=0;s<r.length;s++){e.inspectOpts[r[s]]=n.inspectOpts[r[s]]}}e.exports=r(5994)(n);const{formatters:f}=e.exports;f.o=function(e){this.inspectOpts.colors=this.useColors;return i.inspect(e,this.inspectOpts).split("\n").map(e=>e.trim()).join(" ")};f.O=function(e){this.inspectOpts.colors=this.useColors;return i.inspect(e,this.inspectOpts)}},2527:(module,__unused_webpack_exports,__nccwpck_require__)=>{var callSiteToString=__nccwpck_require__(5809).callSiteToString;var eventListenerCount=__nccwpck_require__(5809).eventListenerCount;var relative=__nccwpck_require__(5622).relative;module.exports=depd;var basePath=process.cwd();function containsNamespace(e,n){var r=e.split(/[ ,]+/);var s=String(n).toLowerCase();for(var i=0;i<r.length;i++){var f=r[i];if(f&&(f==="*"||f.toLowerCase()===s)){return true}}return false}function convertDataDescriptorToAccessor(e,n,r){var s=Object.getOwnPropertyDescriptor(e,n);var i=s.value;s.get=function getter(){return i};if(s.writable){s.set=function setter(e){return i=e}}delete s.value;delete s.writable;Object.defineProperty(e,n,s);return s}function createArgumentsString(e){var n="";for(var r=0;r<e;r++){n+=", arg"+r}return n.substr(2)}function createStackString(e){var n=this.name+": "+this.namespace;if(this.message){n+=" deprecated "+this.message}for(var r=0;r<e.length;r++){n+="\n at "+callSiteToString(e[r])}return n}function depd(e){if(!e){throw new TypeError("argument namespace is required")}var n=getStack();var r=callSiteLocation(n[1]);var s=r[0];function deprecate(e){log.call(deprecate,e)}deprecate._file=s;deprecate._ignored=isignored(e);deprecate._namespace=e;deprecate._traced=istraced(e);deprecate._warned=Object.create(null);deprecate.function=wrapfunction;deprecate.property=wrapproperty;return deprecate}function isignored(e){if(process.noDeprecation){return true}var n=process.env.NO_DEPRECATION||"";return containsNamespace(n,e)}function istraced(e){if(process.traceDeprecation){return true}var n=process.env.TRACE_DEPRECATION||"";return containsNamespace(n,e)}function log(e,n){var r=eventListenerCount(process,"deprecation")!==0;if(!r&&this._ignored){return}var s;var i;var f;var l;var t=0;var o=false;var c=getStack();var a=this._file;if(n){l=n;f=callSiteLocation(c[1]);f.name=l.name;a=f[0]}else{t=2;l=callSiteLocation(c[t]);f=l}for(;t<c.length;t++){s=callSiteLocation(c[t]);i=s[0];if(i===a){o=true}else if(i===this._file){a=this._file}else if(o){break}}var d=s?l.join(":")+"__"+s.join(":"):undefined;if(d!==undefined&&d in this._warned){return}this._warned[d]=true;var p=e;if(!p){p=f===l||!f.name?defaultMessage(l):defaultMessage(f)}if(r){var u=DeprecationError(this._namespace,p,c.slice(t));process.emit("deprecation",u);return}var h=process.stderr.isTTY?formatColor:formatPlain;var v=h.call(this,p,s,c.slice(t));process.stderr.write(v+"\n","utf8")}function callSiteLocation(e){var n=e.getFileName()||"<anonymous>";var r=e.getLineNumber();var s=e.getColumnNumber();if(e.isEval()){n=e.getEvalOrigin()+", "+n}var i=[n,r,s];i.callSite=e;i.name=e.getFunctionName();return i}function defaultMessage(e){var n=e.callSite;var r=e.name;if(!r){r="<anonymous@"+formatLocation(e)+">"}var s=n.getThis();var i=s&&n.getTypeName();if(i==="Object"){i=undefined}if(i==="Function"){i=s.name||i}return i&&n.getMethodName()?i+"."+r:r}function formatPlain(e,n,r){var s=(new Date).toUTCString();var i=s+" "+this._namespace+" deprecated "+e;if(this._traced){for(var f=0;f<r.length;f++){i+="\n at "+callSiteToString(r[f])}return i}if(n){i+=" at "+formatLocation(n)}return i}function formatColor(e,n,r){var s="[36;1m"+this._namespace+"[22;39m"+" [33;1mdeprecated[22;39m"+" [0m"+e+"[39m";if(this._traced){for(var i=0;i<r.length;i++){s+="\n [36mat "+callSiteToString(r[i])+"[39m"}return s}if(n){s+=" [36m"+formatLocation(n)+"[39m"}return s}function formatLocation(e){return relative(basePath,e[0])+":"+e[1]+":"+e[2]}function getStack(){var e=Error.stackTraceLimit;var n={};var r=Error.prepareStackTrace;Error.prepareStackTrace=prepareObjectStackTrace;Error.stackTraceLimit=Math.max(10,e);Error.captureStackTrace(n);var s=n.stack.slice(1);Error.prepareStackTrace=r;Error.stackTraceLimit=e;return s}function prepareObjectStackTrace(e,n){return n}function wrapfunction(fn,message){if(typeof fn!=="function"){throw new TypeError("argument fn must be a function")}var args=createArgumentsString(fn.length);var deprecate=this;var stack=getStack();var site=callSiteLocation(stack[1]);site.name=fn.name;var deprecatedfn=eval("(function ("+args+") {\n"+'"use strict"\n'+"log.call(deprecate, message, site)\n"+"return fn.apply(this, arguments)\n"+"})");return deprecatedfn}function wrapproperty(e,n,r){if(!e||typeof e!=="object"&&typeof e!=="function"){throw new TypeError("argument obj must be object")}var s=Object.getOwnPropertyDescriptor(e,n);if(!s){throw new TypeError("must call property on owner object")}if(!s.configurable){throw new TypeError("property must be configurable")}var i=this;var f=getStack();var l=callSiteLocation(f[1]);l.name=n;if("value"in s){s=convertDataDescriptorToAccessor(e,n,r)}var t=s.get;var o=s.set;if(typeof t==="function"){s.get=function getter(){log.call(i,r,l);return t.apply(this,arguments)}}if(typeof o==="function"){s.set=function setter(){log.call(i,r,l);return o.apply(this,arguments)}}Object.defineProperty(e,n,s)}function DeprecationError(e,n,r){var s=new Error;var i;Object.defineProperty(s,"constructor",{value:DeprecationError});Object.defineProperty(s,"message",{configurable:true,enumerable:false,value:n,writable:true});Object.defineProperty(s,"name",{enumerable:false,configurable:true,value:"DeprecationError",writable:true});Object.defineProperty(s,"namespace",{configurable:true,enumerable:false,value:e,writable:true});Object.defineProperty(s,"stack",{configurable:true,enumerable:false,get:function(){if(i!==undefined){return i}return i=createStackString.call(this,r)},set:function setter(e){i=e}});return s}},997:e=>{"use strict";e.exports=callSiteToString;function callSiteFileLocation(e){var n;var r="";if(e.isNative()){r="native"}else if(e.isEval()){n=e.getScriptNameOrSourceURL();if(!n){r=e.getEvalOrigin()}}else{n=e.getFileName()}if(n){r+=n;var s=e.getLineNumber();if(s!=null){r+=":"+s;var i=e.getColumnNumber();if(i){r+=":"+i}}}return r||"unknown source"}function callSiteToString(e){var n=true;var r=callSiteFileLocation(e);var s=e.getFunctionName();var i=e.isConstructor();var f=!(e.isToplevel()||i);var l="";if(f){var t=e.getMethodName();var o=getConstructorName(e);if(s){if(o&&s.indexOf(o)!==0){l+=o+"."}l+=s;if(t&&s.lastIndexOf("."+t)!==s.length-t.length-1){l+=" [as "+t+"]"}}else{l+=o+"."+(t||"<anonymous>")}}else if(i){l+="new "+(s||"<anonymous>")}else if(s){l+=s}else{n=false;l+=r}if(n){l+=" ("+r+")"}return l}function getConstructorName(e){var n=e.receiver;return n.constructor&&n.constructor.name||null}},8731:e=>{"use strict";e.exports=eventListenerCount;function eventListenerCount(e,n){return e.listeners(n).length}},5809:(e,n,r)=>{"use strict";var s=r(8614).EventEmitter;lazyProperty(e.exports,"callSiteToString",function callSiteToString(){var e=Error.stackTraceLimit;var n={};var s=Error.prepareStackTrace;function prepareObjectStackTrace(e,n){return n}Error.prepareStackTrace=prepareObjectStackTrace;Error.stackTraceLimit=2;Error.captureStackTrace(n);var i=n.stack.slice();Error.prepareStackTrace=s;Error.stackTraceLimit=e;return i[0].toString?toString:r(997)});lazyProperty(e.exports,"eventListenerCount",function eventListenerCount(){return s.listenerCount||r(8731)});function lazyProperty(e,n,r){function get(){var s=r();Object.defineProperty(e,n,{configurable:true,enumerable:true,value:s});return s}Object.defineProperty(e,n,{configurable:true,enumerable:true,get:get})}function toString(e){return e.toString()}},9413:(e,n,r)=>{var s=r(8915);var i=r(5622);e.exports=function expandTilde(e){var n=s();if(e.charCodeAt(0)===126){if(e.charCodeAt(1)===43){return i.join(process.cwd(),e.slice(2))}return n?i.join(n,e.slice(1)):e}return e}},7988:e=>{"use strict";e.exports=function equal(e,n){if(e===n)return true;if(e&&n&&typeof e=="object"&&typeof n=="object"){if(e.constructor!==n.constructor)return false;var r,s,i;if(Array.isArray(e)){r=e.length;if(r!=n.length)return false;for(s=r;s--!==0;)if(!equal(e[s],n[s]))return false;return true}if(e.constructor===RegExp)return e.source===n.source&&e.flags===n.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===n.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===n.toString();i=Object.keys(e);r=i.length;if(r!==Object.keys(n).length)return false;for(s=r;s--!==0;)if(!Object.prototype.hasOwnProperty.call(n,i[s]))return false;for(s=r;s--!==0;){var f=i[s];if(!equal(e[f],n[f]))return false}return true}return e!==e&&n!==n}},7692:e=>{"use strict";e.exports=function(e,n){if(!n)n={};if(typeof n==="function")n={cmp:n};var r=typeof n.cycles==="boolean"?n.cycles:false;var s=n.cmp&&function(e){return function(n){return function(r,s){var i={key:r,value:n[r]};var f={key:s,value:n[s]};return e(i,f)}}}(n.cmp);var i=[];return function stringify(e){if(e&&e.toJSON&&typeof e.toJSON==="function"){e=e.toJSON()}if(e===undefined)return;if(typeof e=="number")return isFinite(e)?""+e:"null";if(typeof e!=="object")return JSON.stringify(e);var n,f;if(Array.isArray(e)){f="[";for(n=0;n<e.length;n++){if(n)f+=",";f+=stringify(e[n])||"null"}return f+"]"}if(e===null)return"null";if(i.indexOf(e)!==-1){if(r)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var l=i.push(e)-1;var t=Object.keys(e).sort(s&&s(e));f="";for(n=0;n<t.length;n++){var o=t[n];var c=stringify(e[o]);if(!c)continue;if(f)f+=",";f+=JSON.stringify(o)+":"+c}i.splice(l,1);return"{"+f+"}"}(e)}},1338:e=>{e.exports=stringify;stringify.default=stringify;stringify.stable=deterministicStringify;stringify.stableStringify=deterministicStringify;var n="[...]";var r="[Circular]";var s=[];var i=[];function defaultOptions(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function stringify(e,n,r,f){if(typeof f==="undefined"){f=defaultOptions()}decirc(e,"",0,[],undefined,0,f);var l;try{if(i.length===0){l=JSON.stringify(e,n,r)}else{l=JSON.stringify(e,replaceGetterValues(n),r)}}catch(e){return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{while(s.length!==0){var t=s.pop();if(t.length===4){Object.defineProperty(t[0],t[1],t[3])}else{t[0][t[1]]=t[2]}}}return l}function setReplace(e,n,r,f){var l=Object.getOwnPropertyDescriptor(f,r);if(l.get!==undefined){if(l.configurable){Object.defineProperty(f,r,{value:e});s.push([f,r,n,l])}else{i.push([n,r,e])}}else{f[r]=e;s.push([f,r,n])}}function decirc(e,s,i,f,l,t,o){t+=1;var c;if(typeof e==="object"&&e!==null){for(c=0;c<f.length;c++){if(f[c]===e){setReplace(r,e,s,l);return}}if(typeof o.depthLimit!=="undefined"&&t>o.depthLimit){setReplace(n,e,s,l);return}if(typeof o.edgesLimit!=="undefined"&&i+1>o.edgesLimit){setReplace(n,e,s,l);return}f.push(e);if(Array.isArray(e)){for(c=0;c<e.length;c++){decirc(e[c],c,c,f,e,t,o)}}else{var a=Object.keys(e);for(c=0;c<a.length;c++){var d=a[c];decirc(e[d],d,c,f,e,t,o)}}f.pop()}}function compareFunction(e,n){if(e<n){return-1}if(e>n){return 1}return 0}function deterministicStringify(e,n,r,f){if(typeof f==="undefined"){f=defaultOptions()}var l=deterministicDecirc(e,"",0,[],undefined,0,f)||e;var t;try{if(i.length===0){t=JSON.stringify(l,n,r)}else{t=JSON.stringify(l,replaceGetterValues(n),r)}}catch(e){return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{while(s.length!==0){var o=s.pop();if(o.length===4){Object.defineProperty(o[0],o[1],o[3])}else{o[0][o[1]]=o[2]}}}return t}function deterministicDecirc(e,i,f,l,t,o,c){o+=1;var a;if(typeof e==="object"&&e!==null){for(a=0;a<l.length;a++){if(l[a]===e){setReplace(r,e,i,t);return}}try{if(typeof e.toJSON==="function"){return}}catch(e){return}if(typeof c.depthLimit!=="undefined"&&o>c.depthLimit){setReplace(n,e,i,t);return}if(typeof c.edgesLimit!=="undefined"&&f+1>c.edgesLimit){setReplace(n,e,i,t);return}l.push(e);if(Array.isArray(e)){for(a=0;a<e.length;a++){deterministicDecirc(e[a],a,a,l,e,o,c)}}else{var d={};var p=Object.keys(e).sort(compareFunction);for(a=0;a<p.length;a++){var u=p[a];deterministicDecirc(e[u],u,a,l,e,o,c);d[u]=e[u]}if(typeof t!=="undefined"){s.push([t,i,e]);t[i]=d}else{return d}}l.pop()}}function replaceGetterValues(e){e=typeof e!=="undefined"?e:function(e,n){return n};return function(n,r){if(i.length>0){for(var s=0;s<i.length;s++){var f=i[s];if(f[1]===n&&f[0]===r){r=f[2];i.splice(s,1);break}}}return e.call(this,n,r)}}},5835:(e,n,r)=>{const{Readable:s}=r(2413);const i=new WeakMap;async function*read(e){for(const n of e){if("stream"in n){yield*n.stream()}else{yield n}}}class Blob{constructor(e=[],n={}){let r=0;const s=e.map(e=>{let n;if(e instanceof Buffer){n=e}else if(ArrayBuffer.isView(e)){n=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}else if(e instanceof ArrayBuffer){n=Buffer.from(e)}else if(e instanceof Blob){n=e}else{n=Buffer.from(typeof e==="string"?e:String(e))}r+=n.length||n.size||0;return n});const f=n.type===undefined?"":String(n.type).toLowerCase();i.set(this,{type:/[^\u0020-\u007E]/.test(f)?"":f,size:r,parts:s})}get size(){return i.get(this).size}get type(){return i.get(this).type}async text(){return Buffer.from(await this.arrayBuffer()).toString()}async arrayBuffer(){const e=new Uint8Array(this.size);let n=0;for await(const r of this.stream()){e.set(r,n);n+=r.length}return e.buffer}stream(){return s.from(read(i.get(this).parts))}slice(e=0,n=this.size,r=""){const{size:s}=this;let f=e<0?Math.max(s+e,0):Math.min(e,s);let l=n<0?Math.max(s+n,0):Math.min(n,s);const t=Math.max(l-f,0);const o=i.get(this).parts.values();const c=[];let a=0;for(const e of o){const n=ArrayBuffer.isView(e)?e.byteLength:e.size;if(f&&n<=f){f-=n;l-=n}else{const r=e.slice(f,Math.min(n,l));c.push(r);a+=ArrayBuffer.isView(r)?r.byteLength:r.size;f=0;if(a>=t){break}}}const d=new Blob([],{type:String(r).toLowerCase()});Object.assign(i.get(d),{size:t,parts:c});return d}get[Symbol.toStringTag](){return"Blob"}static[Symbol.hasInstance](e){return e&&typeof e==="object"&&typeof e.stream==="function"&&e.stream.length===0&&typeof e.constructor==="function"&&/^(Blob|File)$/.test(e[Symbol.toStringTag])}}Object.defineProperties(Blob.prototype,{size:{enumerable:true},type:{enumerable:true},slice:{enumerable:true}});e.exports=Blob},212:(e,n,r)=>{"use strict";const s=r(4742);const i=r(5622);const f=r(664).mkdirsSync;const l=r(9056).utimesMillisSync;const t=r(1757);function copySync(e,n,r){if(typeof r==="function"){r={filter:r}}r=r||{};r.clobber="clobber"in r?!!r.clobber:true;r.overwrite="overwrite"in r?!!r.overwrite:r.clobber;if(r.preserveTimestamps&&process.arch==="ia32"){console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\n\n see https://github.com/jprichardson/node-fs-extra/issues/269`)}const{srcStat:s,destStat:i}=t.checkPathsSync(e,n,"copy");t.checkParentPathsSync(e,s,n,"copy");return handleFilterAndCopy(i,e,n,r)}function handleFilterAndCopy(e,n,r,l){if(l.filter&&!l.filter(n,r))return;const t=i.dirname(r);if(!s.existsSync(t))f(t);return startCopy(e,n,r,l)}function startCopy(e,n,r,s){if(s.filter&&!s.filter(n,r))return;return getStats(e,n,r,s)}function getStats(e,n,r,i){const f=i.dereference?s.statSync:s.lstatSync;const l=f(n);if(l.isDirectory())return onDir(l,e,n,r,i);else if(l.isFile()||l.isCharacterDevice()||l.isBlockDevice())return onFile(l,e,n,r,i);else if(l.isSymbolicLink())return onLink(e,n,r,i)}function onFile(e,n,r,s,i){if(!n)return copyFile(e,r,s,i);return mayCopyFile(e,r,s,i)}function mayCopyFile(e,n,r,i){if(i.overwrite){s.unlinkSync(r);return copyFile(e,n,r,i)}else if(i.errorOnExist){throw new Error(`'${r}' already exists`)}}function copyFile(e,n,r,i){s.copyFileSync(n,r);if(i.preserveTimestamps)handleTimestamps(e.mode,n,r);return setDestMode(r,e.mode)}function handleTimestamps(e,n,r){if(fileIsNotWritable(e))makeFileWritable(r,e);return setDestTimestamps(n,r)}function fileIsNotWritable(e){return(e&128)===0}function makeFileWritable(e,n){return setDestMode(e,n|128)}function setDestMode(e,n){return s.chmodSync(e,n)}function setDestTimestamps(e,n){const r=s.statSync(e);return l(n,r.atime,r.mtime)}function onDir(e,n,r,s,i){if(!n)return mkDirAndCopy(e.mode,r,s,i);if(n&&!n.isDirectory()){throw new Error(`Cannot overwrite non-directory '${s}' with directory '${r}'.`)}return copyDir(r,s,i)}function mkDirAndCopy(e,n,r,i){s.mkdirSync(r);copyDir(n,r,i);return setDestMode(r,e)}function copyDir(e,n,r){s.readdirSync(e).forEach(s=>copyDirItem(s,e,n,r))}function copyDirItem(e,n,r,s){const f=i.join(n,e);const l=i.join(r,e);const{destStat:o}=t.checkPathsSync(f,l,"copy");return startCopy(o,f,l,s)}function onLink(e,n,r,f){let l=s.readlinkSync(n);if(f.dereference){l=i.resolve(process.cwd(),l)}if(!e){return s.symlinkSync(l,r)}else{let e;try{e=s.readlinkSync(r)}catch(e){if(e.code==="EINVAL"||e.code==="UNKNOWN")return s.symlinkSync(l,r);throw e}if(f.dereference){e=i.resolve(process.cwd(),e)}if(t.isSrcSubdir(l,e)){throw new Error(`Cannot copy '${l}' to a subdirectory of itself, '${e}'.`)}if(s.statSync(r).isDirectory()&&t.isSrcSubdir(e,l)){throw new Error(`Cannot overwrite '${e}' with '${l}'.`)}return copyLink(l,r)}}function copyLink(e,n){s.unlinkSync(n);return s.symlinkSync(e,n)}e.exports=copySync},3890:(e,n,r)=>{"use strict";e.exports={copySync:r(212)}},1448:(e,n,r)=>{"use strict";const s=r(4742);const i=r(5622);const f=r(664).mkdirs;const l=r(6564).pathExists;const t=r(9056).utimesMillis;const o=r(1757);function copy(e,n,r,s){if(typeof r==="function"&&!s){s=r;r={}}else if(typeof r==="function"){r={filter:r}}s=s||function(){};r=r||{};r.clobber="clobber"in r?!!r.clobber:true;r.overwrite="overwrite"in r?!!r.overwrite:r.clobber;if(r.preserveTimestamps&&process.arch==="ia32"){console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\n\n see https://github.com/jprichardson/node-fs-extra/issues/269`)}o.checkPaths(e,n,"copy",(i,f)=>{if(i)return s(i);const{srcStat:l,destStat:t}=f;o.checkParentPaths(e,l,n,"copy",i=>{if(i)return s(i);if(r.filter)return handleFilter(checkParentDir,t,e,n,r,s);return checkParentDir(t,e,n,r,s)})})}function checkParentDir(e,n,r,s,t){const o=i.dirname(r);l(o,(i,l)=>{if(i)return t(i);if(l)return startCopy(e,n,r,s,t);f(o,i=>{if(i)return t(i);return startCopy(e,n,r,s,t)})})}function handleFilter(e,n,r,s,i,f){Promise.resolve(i.filter(r,s)).then(l=>{if(l)return e(n,r,s,i,f);return f()},e=>f(e))}function startCopy(e,n,r,s,i){if(s.filter)return handleFilter(getStats,e,n,r,s,i);return getStats(e,n,r,s,i)}function getStats(e,n,r,i,f){const l=i.dereference?s.stat:s.lstat;l(n,(s,l)=>{if(s)return f(s);if(l.isDirectory())return onDir(l,e,n,r,i,f);else if(l.isFile()||l.isCharacterDevice()||l.isBlockDevice())return onFile(l,e,n,r,i,f);else if(l.isSymbolicLink())return onLink(e,n,r,i,f)})}function onFile(e,n,r,s,i,f){if(!n)return copyFile(e,r,s,i,f);return mayCopyFile(e,r,s,i,f)}function mayCopyFile(e,n,r,i,f){if(i.overwrite){s.unlink(r,s=>{if(s)return f(s);return copyFile(e,n,r,i,f)})}else if(i.errorOnExist){return f(new Error(`'${r}' already exists`))}else return f()}function copyFile(e,n,r,i,f){s.copyFile(n,r,s=>{if(s)return f(s);if(i.preserveTimestamps)return handleTimestampsAndMode(e.mode,n,r,f);return setDestMode(r,e.mode,f)})}function handleTimestampsAndMode(e,n,r,s){if(fileIsNotWritable(e)){return makeFileWritable(r,e,i=>{if(i)return s(i);return setDestTimestampsAndMode(e,n,r,s)})}return setDestTimestampsAndMode(e,n,r,s)}function fileIsNotWritable(e){return(e&128)===0}function makeFileWritable(e,n,r){return setDestMode(e,n|128,r)}function setDestTimestampsAndMode(e,n,r,s){setDestTimestamps(n,r,n=>{if(n)return s(n);return setDestMode(r,e,s)})}function setDestMode(e,n,r){return s.chmod(e,n,r)}function setDestTimestamps(e,n,r){s.stat(e,(e,s)=>{if(e)return r(e);return t(n,s.atime,s.mtime,r)})}function onDir(e,n,r,s,i,f){if(!n)return mkDirAndCopy(e.mode,r,s,i,f);if(n&&!n.isDirectory()){return f(new Error(`Cannot overwrite non-directory '${s}' with directory '${r}'.`))}return copyDir(r,s,i,f)}function mkDirAndCopy(e,n,r,i,f){s.mkdir(r,s=>{if(s)return f(s);copyDir(n,r,i,n=>{if(n)return f(n);return setDestMode(r,e,f)})})}function copyDir(e,n,r,i){s.readdir(e,(s,f)=>{if(s)return i(s);return copyDirItems(f,e,n,r,i)})}function copyDirItems(e,n,r,s,i){const f=e.pop();if(!f)return i();return copyDirItem(e,f,n,r,s,i)}function copyDirItem(e,n,r,s,f,l){const t=i.join(r,n);const c=i.join(s,n);o.checkPaths(t,c,"copy",(n,i)=>{if(n)return l(n);const{destStat:o}=i;startCopy(o,t,c,f,n=>{if(n)return l(n);return copyDirItems(e,r,s,f,l)})})}function onLink(e,n,r,f,l){s.readlink(n,(n,t)=>{if(n)return l(n);if(f.dereference){t=i.resolve(process.cwd(),t)}if(!e){return s.symlink(t,r,l)}else{s.readlink(r,(n,c)=>{if(n){if(n.code==="EINVAL"||n.code==="UNKNOWN")return s.symlink(t,r,l);return l(n)}if(f.dereference){c=i.resolve(process.cwd(),c)}if(o.isSrcSubdir(t,c)){return l(new Error(`Cannot copy '${t}' to a subdirectory of itself, '${c}'.`))}if(e.isDirectory()&&o.isSrcSubdir(c,t)){return l(new Error(`Cannot overwrite '${c}' with '${t}'.`))}return copyLink(t,r,l)})}})}function copyLink(e,n,r){s.unlink(n,i=>{if(i)return r(i);return s.symlink(e,n,r)})}e.exports=copy},6774:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;e.exports={copy:s(r(1448))}},944:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(4742);const f=r(5622);const l=r(664);const t=r(6944);const o=s(function emptyDir(e,n){n=n||function(){};i.readdir(e,(r,s)=>{if(r)return l.mkdirs(e,n);s=s.map(n=>f.join(e,n));deleteItem();function deleteItem(){const e=s.pop();if(!e)return n();t.remove(e,e=>{if(e)return n(e);deleteItem()})}})});function emptyDirSync(e){let n;try{n=i.readdirSync(e)}catch{return l.mkdirsSync(e)}n.forEach(n=>{n=f.join(e,n);t.removeSync(n)})}e.exports={emptyDirSync:emptyDirSync,emptydirSync:emptyDirSync,emptyDir:o,emptydir:o}},5080:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(5622);const f=r(4742);const l=r(664);function createFile(e,n){function makeFile(){f.writeFile(e,"",e=>{if(e)return n(e);n()})}f.stat(e,(r,s)=>{if(!r&&s.isFile())return n();const t=i.dirname(e);f.stat(t,(e,r)=>{if(e){if(e.code==="ENOENT"){return l.mkdirs(t,e=>{if(e)return n(e);makeFile()})}return n(e)}if(r.isDirectory())makeFile();else{f.readdir(t,e=>{if(e)return n(e)})}})})}function createFileSync(e){let n;try{n=f.statSync(e)}catch{}if(n&&n.isFile())return;const r=i.dirname(e);try{if(!f.statSync(r).isDirectory()){f.readdirSync(r)}}catch(e){if(e&&e.code==="ENOENT")l.mkdirsSync(r);else throw e}f.writeFileSync(e,"")}e.exports={createFile:s(createFile),createFileSync:createFileSync}},6037:(e,n,r)=>{"use strict";const s=r(5080);const i=r(3921);const f=r(8073);e.exports={createFile:s.createFile,createFileSync:s.createFileSync,ensureFile:s.createFile,ensureFileSync:s.createFileSync,createLink:i.createLink,createLinkSync:i.createLinkSync,ensureLink:i.createLink,ensureLinkSync:i.createLinkSync,createSymlink:f.createSymlink,createSymlinkSync:f.createSymlinkSync,ensureSymlink:f.createSymlink,ensureSymlinkSync:f.createSymlinkSync}},3921:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(5622);const f=r(4742);const l=r(664);const t=r(6564).pathExists;function createLink(e,n,r){function makeLink(e,n){f.link(e,n,e=>{if(e)return r(e);r(null)})}t(n,(s,o)=>{if(s)return r(s);if(o)return r(null);f.lstat(e,s=>{if(s){s.message=s.message.replace("lstat","ensureLink");return r(s)}const f=i.dirname(n);t(f,(s,i)=>{if(s)return r(s);if(i)return makeLink(e,n);l.mkdirs(f,s=>{if(s)return r(s);makeLink(e,n)})})})})}function createLinkSync(e,n){const r=f.existsSync(n);if(r)return undefined;try{f.lstatSync(e)}catch(e){e.message=e.message.replace("lstat","ensureLink");throw e}const s=i.dirname(n);const t=f.existsSync(s);if(t)return f.linkSync(e,n);l.mkdirsSync(s);return f.linkSync(e,n)}e.exports={createLink:s(createLink),createLinkSync:createLinkSync}},7056:(e,n,r)=>{"use strict";const s=r(5622);const i=r(4742);const f=r(6564).pathExists;function symlinkPaths(e,n,r){if(s.isAbsolute(e)){return i.lstat(e,n=>{if(n){n.message=n.message.replace("lstat","ensureSymlink");return r(n)}return r(null,{toCwd:e,toDst:e})})}else{const l=s.dirname(n);const t=s.join(l,e);return f(t,(n,f)=>{if(n)return r(n);if(f){return r(null,{toCwd:t,toDst:e})}else{return i.lstat(e,n=>{if(n){n.message=n.message.replace("lstat","ensureSymlink");return r(n)}return r(null,{toCwd:e,toDst:s.relative(l,e)})})}})}}function symlinkPathsSync(e,n){let r;if(s.isAbsolute(e)){r=i.existsSync(e);if(!r)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{const f=s.dirname(n);const l=s.join(f,e);r=i.existsSync(l);if(r){return{toCwd:l,toDst:e}}else{r=i.existsSync(e);if(!r)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:s.relative(f,e)}}}}e.exports={symlinkPaths:symlinkPaths,symlinkPathsSync:symlinkPathsSync}},6003:(e,n,r)=>{"use strict";const s=r(4742);function symlinkType(e,n,r){r=typeof n==="function"?n:r;n=typeof n==="function"?false:n;if(n)return r(null,n);s.lstat(e,(e,s)=>{if(e)return r(null,"file");n=s&&s.isDirectory()?"dir":"file";r(null,n)})}function symlinkTypeSync(e,n){let r;if(n)return n;try{r=s.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}e.exports={symlinkType:symlinkType,symlinkTypeSync:symlinkTypeSync}},8073:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(5622);const f=r(4742);const l=r(664);const t=l.mkdirs;const o=l.mkdirsSync;const c=r(7056);const a=c.symlinkPaths;const d=c.symlinkPathsSync;const p=r(6003);const u=p.symlinkType;const h=p.symlinkTypeSync;const v=r(6564).pathExists;function createSymlink(e,n,r,s){s=typeof r==="function"?r:s;r=typeof r==="function"?false:r;v(n,(l,o)=>{if(l)return s(l);if(o)return s(null);a(e,n,(l,o)=>{if(l)return s(l);e=o.toDst;u(o.toCwd,r,(r,l)=>{if(r)return s(r);const o=i.dirname(n);v(o,(r,i)=>{if(r)return s(r);if(i)return f.symlink(e,n,l,s);t(o,r=>{if(r)return s(r);f.symlink(e,n,l,s)})})})})})}function createSymlinkSync(e,n,r){const s=f.existsSync(n);if(s)return undefined;const l=d(e,n);e=l.toDst;r=h(l.toCwd,r);const t=i.dirname(n);const c=f.existsSync(t);if(c)return f.symlinkSync(e,n,r);o(t);return f.symlinkSync(e,n,r)}e.exports={createSymlink:s(createSymlink),createSymlinkSync:createSymlinkSync}},3858:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(4742);const f=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(e=>{return typeof i[e]==="function"});Object.keys(i).forEach(e=>{if(e==="promises"){return}n[e]=i[e]});f.forEach(e=>{n[e]=s(i[e])});n.exists=function(e,n){if(typeof n==="function"){return i.exists(e,n)}return new Promise(n=>{return i.exists(e,n)})};n.read=function(e,n,r,s,f,l){if(typeof l==="function"){return i.read(e,n,r,s,f,l)}return new Promise((l,t)=>{i.read(e,n,r,s,f,(e,n,r)=>{if(e)return t(e);l({bytesRead:n,buffer:r})})})};n.write=function(e,n,...r){if(typeof r[r.length-1]==="function"){return i.write(e,n,...r)}return new Promise((s,f)=>{i.write(e,n,...r,(e,n,r)=>{if(e)return f(e);s({bytesWritten:n,buffer:r})})})};if(typeof i.writev==="function"){n.writev=function(e,n,...r){if(typeof r[r.length-1]==="function"){return i.writev(e,n,...r)}return new Promise((s,f)=>{i.writev(e,n,...r,(e,n,r)=>{if(e)return f(e);s({bytesWritten:n,buffers:r})})})}}if(typeof i.realpath.native==="function"){n.realpath.native=s(i.realpath.native)}},4982:(e,n,r)=>{"use strict";e.exports={...r(3858),...r(3890),...r(6774),...r(944),...r(6037),...r(7488),...r(664),...r(3740),...r(1365),...r(5181),...r(6564),...r(6944)};const s=r(5747);if(Object.getOwnPropertyDescriptor(s,"promises")){Object.defineProperty(e.exports,"promises",{get(){return s.promises}})}},7488:(e,n,r)=>{"use strict";const s=r(8522).fromPromise;const i=r(5570);i.outputJson=s(r(1452));i.outputJsonSync=r(153);i.outputJSON=i.outputJson;i.outputJSONSync=i.outputJsonSync;i.writeJSON=i.writeJson;i.writeJSONSync=i.writeJsonSync;i.readJSON=i.readJson;i.readJSONSync=i.readJsonSync;e.exports=i},5570:(e,n,r)=>{"use strict";const s=r(5221);e.exports={readJson:s.readFile,readJsonSync:s.readFileSync,writeJson:s.writeFile,writeJsonSync:s.writeFileSync}},153:(e,n,r)=>{"use strict";const{stringify:s}=r(1266);const{outputFileSync:i}=r(5181);function outputJsonSync(e,n,r){const f=s(n,r);i(e,f,r)}e.exports=outputJsonSync},1452:(e,n,r)=>{"use strict";const{stringify:s}=r(1266);const{outputFile:i}=r(5181);async function outputJson(e,n,r={}){const f=s(n,r);await i(e,f,r)}e.exports=outputJson},664:(e,n,r)=>{"use strict";const s=r(8522).fromPromise;const{makeDir:i,makeDirSync:f}=r(5193);const l=s(i);e.exports={mkdirs:l,mkdirsSync:f,mkdirp:l,mkdirpSync:f,ensureDir:l,ensureDirSync:f}},5193:(e,n,r)=>{"use strict";const s=r(3858);const i=r(5622);const f=r(7762);const l=f("10.12.0");const t=e=>{if(process.platform==="win32"){const n=/[<>:"|?*]/.test(e.replace(i.parse(e).root,""));if(n){const n=new Error(`Path contains invalid characters: ${e}`);n.code="EINVAL";throw n}}};const o=e=>{const n={mode:511};if(typeof e==="number")e={mode:e};return{...n,...e}};const c=e=>{const n=new Error(`operation not permitted, mkdir '${e}'`);n.code="EPERM";n.errno=-4048;n.path=e;n.syscall="mkdir";return n};e.exports.makeDir=(async(e,n)=>{t(e);n=o(n);if(l){const r=i.resolve(e);return s.mkdir(r,{mode:n.mode,recursive:true})}const r=async e=>{try{await s.mkdir(e,n.mode)}catch(n){if(n.code==="EPERM"){throw n}if(n.code==="ENOENT"){if(i.dirname(e)===e){throw c(e)}if(n.message.includes("null bytes")){throw n}await r(i.dirname(e));return r(e)}try{const r=await s.stat(e);if(!r.isDirectory()){throw new Error("The path is not a directory")}}catch{throw n}}};return r(i.resolve(e))});e.exports.makeDirSync=((e,n)=>{t(e);n=o(n);if(l){const r=i.resolve(e);return s.mkdirSync(r,{mode:n.mode,recursive:true})}const r=e=>{try{s.mkdirSync(e,n.mode)}catch(n){if(n.code==="EPERM"){throw n}if(n.code==="ENOENT"){if(i.dirname(e)===e){throw c(e)}if(n.message.includes("null bytes")){throw n}r(i.dirname(e));return r(e)}try{if(!s.statSync(e).isDirectory()){throw new Error("The path is not a directory")}}catch{throw n}}};return r(i.resolve(e))})},3740:(e,n,r)=>{"use strict";e.exports={moveSync:r(763)}},763:(e,n,r)=>{"use strict";const s=r(4742);const i=r(5622);const f=r(3890).copySync;const l=r(6944).removeSync;const t=r(664).mkdirpSync;const o=r(1757);function moveSync(e,n,r){r=r||{};const s=r.overwrite||r.clobber||false;const{srcStat:f}=o.checkPathsSync(e,n,"move");o.checkParentPathsSync(e,f,n,"move");t(i.dirname(n));return doRename(e,n,s)}function doRename(e,n,r){if(r){l(n);return rename(e,n,r)}if(s.existsSync(n))throw new Error("dest already exists.");return rename(e,n,r)}function rename(e,n,r){try{s.renameSync(e,n)}catch(s){if(s.code!=="EXDEV")throw s;return moveAcrossDevice(e,n,r)}}function moveAcrossDevice(e,n,r){const s={overwrite:r,errorOnExist:true};f(e,n,s);return l(e)}e.exports=moveSync},1365:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;e.exports={move:s(r(2750))}},2750:(e,n,r)=>{"use strict";const s=r(4742);const i=r(5622);const f=r(6774).copy;const l=r(6944).remove;const t=r(664).mkdirp;const o=r(6564).pathExists;const c=r(1757);function move(e,n,r,s){if(typeof r==="function"){s=r;r={}}const f=r.overwrite||r.clobber||false;c.checkPaths(e,n,"move",(r,l)=>{if(r)return s(r);const{srcStat:o}=l;c.checkParentPaths(e,o,n,"move",r=>{if(r)return s(r);t(i.dirname(n),r=>{if(r)return s(r);return doRename(e,n,f,s)})})})}function doRename(e,n,r,s){if(r){return l(n,i=>{if(i)return s(i);return rename(e,n,r,s)})}o(n,(i,f)=>{if(i)return s(i);if(f)return s(new Error("dest already exists."));return rename(e,n,r,s)})}function rename(e,n,r,i){s.rename(e,n,s=>{if(!s)return i();if(s.code!=="EXDEV")return i(s);return moveAcrossDevice(e,n,r,i)})}function moveAcrossDevice(e,n,r,s){const i={overwrite:r,errorOnExist:true};f(e,n,i,n=>{if(n)return s(n);return l(e,s)})}e.exports=move},5181:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(4742);const f=r(5622);const l=r(664);const t=r(6564).pathExists;function outputFile(e,n,r,s){if(typeof r==="function"){s=r;r="utf8"}const o=f.dirname(e);t(o,(f,t)=>{if(f)return s(f);if(t)return i.writeFile(e,n,r,s);l.mkdirs(o,f=>{if(f)return s(f);i.writeFile(e,n,r,s)})})}function outputFileSync(e,...n){const r=f.dirname(e);if(i.existsSync(r)){return i.writeFileSync(e,...n)}l.mkdirsSync(r);i.writeFileSync(e,...n)}e.exports={outputFile:s(outputFile),outputFileSync:outputFileSync}},6564:(e,n,r)=>{"use strict";const s=r(8522).fromPromise;const i=r(3858);function pathExists(e){return i.access(e).then(()=>true).catch(()=>false)}e.exports={pathExists:s(pathExists),pathExistsSync:i.existsSync}},6944:(e,n,r)=>{"use strict";const s=r(8522).fromCallback;const i=r(5824);e.exports={remove:s(i),removeSync:i.sync}},5824:(e,n,r)=>{"use strict";const s=r(4742);const i=r(5622);const f=r(2357);const l=process.platform==="win32";function defaults(e){const n=["unlink","chmod","stat","lstat","rmdir","readdir"];n.forEach(n=>{e[n]=e[n]||s[n];n=n+"Sync";e[n]=e[n]||s[n]});e.maxBusyTries=e.maxBusyTries||3}function rimraf(e,n,r){let s=0;if(typeof n==="function"){r=n;n={}}f(e,"rimraf: missing path");f.strictEqual(typeof e,"string","rimraf: path should be a string");f.strictEqual(typeof r,"function","rimraf: callback function required");f(n,"rimraf: invalid options argument provided");f.strictEqual(typeof n,"object","rimraf: options should be object");defaults(n);rimraf_(e,n,function CB(i){if(i){if((i.code==="EBUSY"||i.code==="ENOTEMPTY"||i.code==="EPERM")&&s<n.maxBusyTries){s++;const r=s*100;return setTimeout(()=>rimraf_(e,n,CB),r)}if(i.code==="ENOENT")i=null}r(i)})}function rimraf_(e,n,r){f(e);f(n);f(typeof r==="function");n.lstat(e,(s,i)=>{if(s&&s.code==="ENOENT"){return r(null)}if(s&&s.code==="EPERM"&&l){return fixWinEPERM(e,n,s,r)}if(i&&i.isDirectory()){return rmdir(e,n,s,r)}n.unlink(e,s=>{if(s){if(s.code==="ENOENT"){return r(null)}if(s.code==="EPERM"){return l?fixWinEPERM(e,n,s,r):rmdir(e,n,s,r)}if(s.code==="EISDIR"){return rmdir(e,n,s,r)}}return r(s)})})}function fixWinEPERM(e,n,r,s){f(e);f(n);f(typeof s==="function");n.chmod(e,438,i=>{if(i){s(i.code==="ENOENT"?null:r)}else{n.stat(e,(i,f)=>{if(i){s(i.code==="ENOENT"?null:r)}else if(f.isDirectory()){rmdir(e,n,r,s)}else{n.unlink(e,s)}})}})}function fixWinEPERMSync(e,n,r){let s;f(e);f(n);try{n.chmodSync(e,438)}catch(e){if(e.code==="ENOENT"){return}else{throw r}}try{s=n.statSync(e)}catch(e){if(e.code==="ENOENT"){return}else{throw r}}if(s.isDirectory()){rmdirSync(e,n,r)}else{n.unlinkSync(e)}}function rmdir(e,n,r,s){f(e);f(n);f(typeof s==="function");n.rmdir(e,i=>{if(i&&(i.code==="ENOTEMPTY"||i.code==="EEXIST"||i.code==="EPERM")){rmkids(e,n,s)}else if(i&&i.code==="ENOTDIR"){s(r)}else{s(i)}})}function rmkids(e,n,r){f(e);f(n);f(typeof r==="function");n.readdir(e,(s,f)=>{if(s)return r(s);let l=f.length;let t;if(l===0)return n.rmdir(e,r);f.forEach(s=>{rimraf(i.join(e,s),n,s=>{if(t){return}if(s)return r(t=s);if(--l===0){n.rmdir(e,r)}})})})}function rimrafSync(e,n){let r;n=n||{};defaults(n);f(e,"rimraf: missing path");f.strictEqual(typeof e,"string","rimraf: path should be a string");f(n,"rimraf: missing options");f.strictEqual(typeof n,"object","rimraf: options should be object");try{r=n.lstatSync(e)}catch(r){if(r.code==="ENOENT"){return}if(r.code==="EPERM"&&l){fixWinEPERMSync(e,n,r)}}try{if(r&&r.isDirectory()){rmdirSync(e,n,null)}else{n.unlinkSync(e)}}catch(r){if(r.code==="ENOENT"){return}else if(r.code==="EPERM"){return l?fixWinEPERMSync(e,n,r):rmdirSync(e,n,r)}else if(r.code!=="EISDIR"){throw r}rmdirSync(e,n,r)}}function rmdirSync(e,n,r){f(e);f(n);try{n.rmdirSync(e)}catch(s){if(s.code==="ENOTDIR"){throw r}else if(s.code==="ENOTEMPTY"||s.code==="EEXIST"||s.code==="EPERM"){rmkidsSync(e,n)}else if(s.code!=="ENOENT"){throw s}}}function rmkidsSync(e,n){f(e);f(n);n.readdirSync(e).forEach(r=>rimrafSync(i.join(e,r),n));if(l){const r=Date.now();do{try{const r=n.rmdirSync(e,n);return r}catch{}}while(Date.now()-r<500)}else{const r=n.rmdirSync(e,n);return r}}e.exports=rimraf;rimraf.sync=rimrafSync},1757:(e,n,r)=>{"use strict";const s=r(3858);const i=r(5622);const f=r(1669);const l=r(7762);const t=l("10.5.0");const o=e=>t?s.stat(e,{bigint:true}):s.stat(e);const c=e=>t?s.statSync(e,{bigint:true}):s.statSync(e);function getStats(e,n){return Promise.all([o(e),o(n).catch(e=>{if(e.code==="ENOENT")return null;throw e})]).then(([e,n])=>({srcStat:e,destStat:n}))}function getStatsSync(e,n){let r;const s=c(e);try{r=c(n)}catch(e){if(e.code==="ENOENT")return{srcStat:s,destStat:null};throw e}return{srcStat:s,destStat:r}}function checkPaths(e,n,r,s){f.callbackify(getStats)(e,n,(i,f)=>{if(i)return s(i);const{srcStat:l,destStat:t}=f;if(t&&areIdentical(l,t)){return s(new Error("Source and destination must not be the same."))}if(l.isDirectory()&&isSrcSubdir(e,n)){return s(new Error(errMsg(e,n,r)))}return s(null,{srcStat:l,destStat:t})})}function checkPathsSync(e,n,r){const{srcStat:s,destStat:i}=getStatsSync(e,n);if(i&&areIdentical(s,i)){throw new Error("Source and destination must not be the same.")}if(s.isDirectory()&&isSrcSubdir(e,n)){throw new Error(errMsg(e,n,r))}return{srcStat:s,destStat:i}}function checkParentPaths(e,n,r,f,l){const o=i.resolve(i.dirname(e));const c=i.resolve(i.dirname(r));if(c===o||c===i.parse(c).root)return l();const a=(s,i)=>{if(s){if(s.code==="ENOENT")return l();return l(s)}if(areIdentical(n,i)){return l(new Error(errMsg(e,r,f)))}return checkParentPaths(e,n,c,f,l)};if(t)s.stat(c,{bigint:true},a);else s.stat(c,a)}function checkParentPathsSync(e,n,r,s){const f=i.resolve(i.dirname(e));const l=i.resolve(i.dirname(r));if(l===f||l===i.parse(l).root)return;let t;try{t=c(l)}catch(e){if(e.code==="ENOENT")return;throw e}if(areIdentical(n,t)){throw new Error(errMsg(e,r,s))}return checkParentPathsSync(e,n,l,s)}function areIdentical(e,n){if(n.ino&&n.dev&&n.ino===e.ino&&n.dev===e.dev){if(t||n.ino<Number.MAX_SAFE_INTEGER){return true}if(n.size===e.size&&n.mode===e.mode&&n.nlink===e.nlink&&n.atimeMs===e.atimeMs&&n.mtimeMs===e.mtimeMs&&n.ctimeMs===e.ctimeMs&&n.birthtimeMs===e.birthtimeMs){return true}}return false}function isSrcSubdir(e,n){const r=i.resolve(e).split(i.sep).filter(e=>e);const s=i.resolve(n).split(i.sep).filter(e=>e);return r.reduce((e,n,r)=>e&&s[r]===n,true)}function errMsg(e,n,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${n}'.`}e.exports={checkPaths:checkPaths,checkPathsSync:checkPathsSync,checkParentPaths:checkParentPaths,checkParentPathsSync:checkParentPathsSync,isSrcSubdir:isSrcSubdir}},9056:(e,n,r)=>{"use strict";const s=r(4742);function utimesMillis(e,n,r,i){s.open(e,"r+",(e,f)=>{if(e)return i(e);s.futimes(f,n,r,e=>{s.close(f,n=>{if(i)i(e||n)})})})}function utimesMillisSync(e,n,r){const i=s.openSync(e,"r+");s.futimesSync(i,n,r);return s.closeSync(i)}e.exports={utimesMillis:utimesMillis,utimesMillisSync:utimesMillisSync}},4823:e=>{"use strict";e.exports=clone;var n=Object.getPrototypeOf||function(e){return e.__proto__};function clone(e){if(e===null||typeof e!=="object")return e;if(e instanceof Object)var r={__proto__:n(e)};else var r=Object.create(null);Object.getOwnPropertyNames(e).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(e,n))});return r}},4742:(e,n,r)=>{var s=r(5747);var i=r(7136);var f=r(865);var l=r(4823);var t=r(1669);var o;var c;if(typeof Symbol==="function"&&typeof Symbol.for==="function"){o=Symbol.for("graceful-fs.queue");c=Symbol.for("graceful-fs.previous")}else{o="___graceful-fs.queue";c="___graceful-fs.previous"}function noop(){}function publishQueue(e,n){Object.defineProperty(e,o,{get:function(){return n}})}var a=noop;if(t.debuglog)a=t.debuglog("gfs4");else if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||""))a=function(){var e=t.format.apply(t,arguments);e="GFS4: "+e.split(/\n/).join("\nGFS4: ");console.error(e)};if(!s[o]){var d=global[o]||[];publishQueue(s,d);s.close=function(e){function close(n,r){return e.call(s,n,function(e){if(!e){resetQueue()}if(typeof r==="function")r.apply(this,arguments)})}Object.defineProperty(close,c,{value:e});return close}(s.close);s.closeSync=function(e){function closeSync(n){e.apply(s,arguments);resetQueue()}Object.defineProperty(closeSync,c,{value:e});return closeSync}(s.closeSync);if(/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")){process.on("exit",function(){a(s[o]);r(2357).equal(s[o].length,0)})}}if(!global[o]){publishQueue(global,s[o])}e.exports=patch(l(s));if(process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!s.__patched){e.exports=patch(s);s.__patched=true}function patch(e){i(e);e.gracefulify=patch;e.createReadStream=createReadStream;e.createWriteStream=createWriteStream;var n=e.readFile;e.readFile=readFile;function readFile(e,r,s){if(typeof r==="function")s=r,r=null;return go$readFile(e,r,s);function go$readFile(e,r,s,i){return n(e,r,function(n){if(n&&(n.code==="EMFILE"||n.code==="ENFILE"))enqueue([go$readFile,[e,r,s],n,i||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}})}}var r=e.writeFile;e.writeFile=writeFile;function writeFile(e,n,s,i){if(typeof s==="function")i=s,s=null;return go$writeFile(e,n,s,i);function go$writeFile(e,n,s,i,f){return r(e,n,s,function(r){if(r&&(r.code==="EMFILE"||r.code==="ENFILE"))enqueue([go$writeFile,[e,n,s,i],r,f||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}})}}var s=e.appendFile;if(s)e.appendFile=appendFile;function appendFile(e,n,r,i){if(typeof r==="function")i=r,r=null;return go$appendFile(e,n,r,i);function go$appendFile(e,n,r,i,f){return s(e,n,r,function(s){if(s&&(s.code==="EMFILE"||s.code==="ENFILE"))enqueue([go$appendFile,[e,n,r,i],s,f||Date.now(),Date.now()]);else{if(typeof i==="function")i.apply(this,arguments)}})}}var l=e.copyFile;if(l)e.copyFile=copyFile;function copyFile(e,n,r,s){if(typeof r==="function"){s=r;r=0}return go$copyFile(e,n,r,s);function go$copyFile(e,n,r,s,i){return l(e,n,r,function(f){if(f&&(f.code==="EMFILE"||f.code==="ENFILE"))enqueue([go$copyFile,[e,n,r,s],f,i||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}})}}var t=e.readdir;e.readdir=readdir;function readdir(e,n,r){if(typeof n==="function")r=n,n=null;return go$readdir(e,n,r);function go$readdir(e,n,r,s){return t(e,n,function(i,f){if(i&&(i.code==="EMFILE"||i.code==="ENFILE"))enqueue([go$readdir,[e,n,r],i,s||Date.now(),Date.now()]);else{if(f&&f.sort)f.sort();if(typeof r==="function")r.call(this,i,f)}})}}if(process.version.substr(0,4)==="v0.8"){var o=f(e);ReadStream=o.ReadStream;WriteStream=o.WriteStream}var c=e.ReadStream;if(c){ReadStream.prototype=Object.create(c.prototype);ReadStream.prototype.open=ReadStream$open}var a=e.WriteStream;if(a){WriteStream.prototype=Object.create(a.prototype);WriteStream.prototype.open=WriteStream$open}Object.defineProperty(e,"ReadStream",{get:function(){return ReadStream},set:function(e){ReadStream=e},enumerable:true,configurable:true});Object.defineProperty(e,"WriteStream",{get:function(){return WriteStream},set:function(e){WriteStream=e},enumerable:true,configurable:true});var d=ReadStream;Object.defineProperty(e,"FileReadStream",{get:function(){return d},set:function(e){d=e},enumerable:true,configurable:true});var p=WriteStream;Object.defineProperty(e,"FileWriteStream",{get:function(){return p},set:function(e){p=e},enumerable:true,configurable:true});function ReadStream(e,n){if(this instanceof ReadStream)return c.apply(this,arguments),this;else return ReadStream.apply(Object.create(ReadStream.prototype),arguments)}function ReadStream$open(){var e=this;open(e.path,e.flags,e.mode,function(n,r){if(n){if(e.autoClose)e.destroy();e.emit("error",n)}else{e.fd=r;e.emit("open",r);e.read()}})}function WriteStream(e,n){if(this instanceof WriteStream)return a.apply(this,arguments),this;else return WriteStream.apply(Object.create(WriteStream.prototype),arguments)}function WriteStream$open(){var e=this;open(e.path,e.flags,e.mode,function(n,r){if(n){e.destroy();e.emit("error",n)}else{e.fd=r;e.emit("open",r)}})}function createReadStream(n,r){return new e.ReadStream(n,r)}function createWriteStream(n,r){return new e.WriteStream(n,r)}var u=e.open;e.open=open;function open(e,n,r,s){if(typeof r==="function")s=r,r=null;return go$open(e,n,r,s);function go$open(e,n,r,s,i){return u(e,n,r,function(f,l){if(f&&(f.code==="EMFILE"||f.code==="ENFILE"))enqueue([go$open,[e,n,r,s],f,i||Date.now(),Date.now()]);else{if(typeof s==="function")s.apply(this,arguments)}})}}return e}function enqueue(e){a("ENQUEUE",e[0].name,e[1]);s[o].push(e);retry()}var p;function resetQueue(){var e=Date.now();for(var n=0;n<s[o].length;++n){if(s[o][n].length>2){s[o][n][3]=e;s[o][n][4]=e}}retry()}function retry(){clearTimeout(p);p=undefined;if(s[o].length===0)return;var e=s[o].shift();var n=e[0];var r=e[1];var i=e[2];var f=e[3];var l=e[4];if(f===undefined){a("RETRY",n.name,r);n.apply(null,r)}else if(Date.now()-f>=6e4){a("TIMEOUT",n.name,r);var t=r.pop();if(typeof t==="function")t.call(null,i)}else{var c=Date.now()-l;var d=Math.max(l-f,1);var u=Math.min(d*1.2,100);if(c>=u){a("RETRY",n.name,r);n.apply(null,r.concat([f]))}else{s[o].push(e)}}if(p===undefined){p=setTimeout(retry,0)}}},865:(e,n,r)=>{var s=r(2413).Stream;e.exports=legacy;function legacy(e){return{ReadStream:ReadStream,WriteStream:WriteStream};function ReadStream(n,r){if(!(this instanceof ReadStream))return new ReadStream(n,r);s.call(this);var i=this;this.path=n;this.fd=null;this.readable=true;this.paused=false;this.flags="r";this.mode=438;this.bufferSize=64*1024;r=r||{};var f=Object.keys(r);for(var l=0,t=f.length;l<t;l++){var o=f[l];this[o]=r[o]}if(this.encoding)this.setEncoding(this.encoding);if(this.start!==undefined){if("number"!==typeof this.start){throw TypeError("start must be a Number")}if(this.end===undefined){this.end=Infinity}else if("number"!==typeof this.end){throw TypeError("end must be a Number")}if(this.start>this.end){throw new Error("start must be <= end")}this.pos=this.start}if(this.fd!==null){process.nextTick(function(){i._read()});return}e.open(this.path,this.flags,this.mode,function(e,n){if(e){i.emit("error",e);i.readable=false;return}i.fd=n;i.emit("open",n);i._read()})}function WriteStream(n,r){if(!(this instanceof WriteStream))return new WriteStream(n,r);s.call(this);this.path=n;this.fd=null;this.writable=true;this.flags="w";this.encoding="binary";this.mode=438;this.bytesWritten=0;r=r||{};var i=Object.keys(r);for(var f=0,l=i.length;f<l;f++){var t=i[f];this[t]=r[t]}if(this.start!==undefined){if("number"!==typeof this.start){throw TypeError("start must be a Number")}if(this.start<0){throw new Error("start must be >= zero")}this.pos=this.start}this.busy=false;this._queue=[];if(this.fd===null){this._open=e.open;this._queue.push([this._open,this.path,this.flags,this.mode,undefined]);this.flush()}}}},7136:(e,n,r)=>{var s=r(7619);var i=process.cwd;var f=null;var l=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){if(!f)f=i.call(process);return f};try{process.cwd()}catch(e){}if(typeof process.chdir==="function"){var t=process.chdir;process.chdir=function(e){f=null;t.call(process,e)};if(Object.setPrototypeOf)Object.setPrototypeOf(process.chdir,t)}e.exports=patch;function patch(e){if(s.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)){patchLchmod(e)}if(!e.lutimes){patchLutimes(e)}e.chown=chownFix(e.chown);e.fchown=chownFix(e.fchown);e.lchown=chownFix(e.lchown);e.chmod=chmodFix(e.chmod);e.fchmod=chmodFix(e.fchmod);e.lchmod=chmodFix(e.lchmod);e.chownSync=chownFixSync(e.chownSync);e.fchownSync=chownFixSync(e.fchownSync);e.lchownSync=chownFixSync(e.lchownSync);e.chmodSync=chmodFixSync(e.chmodSync);e.fchmodSync=chmodFixSync(e.fchmodSync);e.lchmodSync=chmodFixSync(e.lchmodSync);e.stat=statFix(e.stat);e.fstat=statFix(e.fstat);e.lstat=statFix(e.lstat);e.statSync=statFixSync(e.statSync);e.fstatSync=statFixSync(e.fstatSync);e.lstatSync=statFixSync(e.lstatSync);if(!e.lchmod){e.lchmod=function(e,n,r){if(r)process.nextTick(r)};e.lchmodSync=function(){}}if(!e.lchown){e.lchown=function(e,n,r,s){if(s)process.nextTick(s)};e.lchownSync=function(){}}if(l==="win32"){e.rename=function(n){return function(r,s,i){var f=Date.now();var l=0;n(r,s,function CB(t){if(t&&(t.code==="EACCES"||t.code==="EPERM")&&Date.now()-f<6e4){setTimeout(function(){e.stat(s,function(e,f){if(e&&e.code==="ENOENT")n(r,s,CB);else i(t)})},l);if(l<100)l+=10;return}if(i)i(t)})}}(e.rename)}e.read=function(n){function read(r,s,i,f,l,t){var o;if(t&&typeof t==="function"){var c=0;o=function(a,d,p){if(a&&a.code==="EAGAIN"&&c<10){c++;return n.call(e,r,s,i,f,l,o)}t.apply(this,arguments)}}return n.call(e,r,s,i,f,l,o)}if(Object.setPrototypeOf)Object.setPrototypeOf(read,n);return read}(e.read);e.readSync=function(n){return function(r,s,i,f,l){var t=0;while(true){try{return n.call(e,r,s,i,f,l)}catch(e){if(e.code==="EAGAIN"&&t<10){t++;continue}throw e}}}}(e.readSync);function patchLchmod(e){e.lchmod=function(n,r,i){e.open(n,s.O_WRONLY|s.O_SYMLINK,r,function(n,s){if(n){if(i)i(n);return}e.fchmod(s,r,function(n){e.close(s,function(e){if(i)i(n||e)})})})};e.lchmodSync=function(n,r){var i=e.openSync(n,s.O_WRONLY|s.O_SYMLINK,r);var f=true;var l;try{l=e.fchmodSync(i,r);f=false}finally{if(f){try{e.closeSync(i)}catch(e){}}else{e.closeSync(i)}}return l}}function patchLutimes(e){if(s.hasOwnProperty("O_SYMLINK")){e.lutimes=function(n,r,i,f){e.open(n,s.O_SYMLINK,function(n,s){if(n){if(f)f(n);return}e.futimes(s,r,i,function(n){e.close(s,function(e){if(f)f(n||e)})})})};e.lutimesSync=function(n,r,i){var f=e.openSync(n,s.O_SYMLINK);var l;var t=true;try{l=e.futimesSync(f,r,i);t=false}finally{if(t){try{e.closeSync(f)}catch(e){}}else{e.closeSync(f)}}return l}}else{e.lutimes=function(e,n,r,s){if(s)process.nextTick(s)};e.lutimesSync=function(){}}}function chmodFix(n){if(!n)return n;return function(r,s,i){return n.call(e,r,s,function(e){if(chownErOk(e))e=null;if(i)i.apply(this,arguments)})}}function chmodFixSync(n){if(!n)return n;return function(r,s){try{return n.call(e,r,s)}catch(e){if(!chownErOk(e))throw e}}}function chownFix(n){if(!n)return n;return function(r,s,i,f){return n.call(e,r,s,i,function(e){if(chownErOk(e))e=null;if(f)f.apply(this,arguments)})}}function chownFixSync(n){if(!n)return n;return function(r,s,i){try{return n.call(e,r,s,i)}catch(e){if(!chownErOk(e))throw e}}}function statFix(n){if(!n)return n;return function(r,s,i){if(typeof s==="function"){i=s;s=null}function callback(e,n){if(n){if(n.uid<0)n.uid+=4294967296;if(n.gid<0)n.gid+=4294967296}if(i)i.apply(this,arguments)}return s?n.call(e,r,s,callback):n.call(e,r,callback)}}function statFixSync(n){if(!n)return n;return function(r,s){var i=s?n.call(e,r,s):n.call(e,r);if(i){if(i.uid<0)i.uid+=4294967296;if(i.gid<0)i.gid+=4294967296}return i}}function chownErOk(e){if(!e)return true;if(e.code==="ENOSYS")return true;var n=!process.getuid||process.getuid()!==0;if(n){if(e.code==="EINVAL"||e.code==="EPERM")return true}return false}}},8915:(e,n,r)=>{"use strict";var s=r(2087);if(typeof s.homedir!=="undefined"){e.exports=s.homedir}else{e.exports=r(5662)}},5662:(e,n,r)=>{"use strict";var s=r(5747);var i=r(7795);function homedir(){if(process.platform==="win32"){if(process.env.USERPROFILE){return process.env.USERPROFILE}if(process.env.HOMEDRIVE&&process.env.HOMEPATH){return process.env.HOMEDRIVE+process.env.HOMEPATH}if(process.env.HOME){return process.env.HOME}return null}if(process.env.HOME){return process.env.HOME}var e=tryReadFileSync("/etc/passwd");var n=find(i(e),getuid());if(n){return n}var r=process.env.LOGNAME||process.env.USER||process.env.LNAME||process.env.USERNAME;if(!r){return null}if(process.platform==="darwin"){return"/Users/"+r}return"/home/"+r}function find(e,n){var r=e.length;for(var s=0;s<r;s++){if(+e[s].uid===n){return e[s].homedir}}}function getuid(){if(typeof process.geteuid==="function"){return process.geteuid()}return process.getuid()}function tryReadFileSync(e){try{return s.readFileSync(e,"utf8")}catch(e){return""}}e.exports=homedir},2872:function(e,n,r){"use strict";var s=this&&this.__awaiter||function(e,n,r,s){function adopt(e){return e instanceof r?e:new r(function(n){n(e)})}return new(r||(r=Promise))(function(r,i){function fulfilled(e){try{step(s.next(e))}catch(e){i(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,n||[])).next())})};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});const f=i(r(1631));const l=i(r(4016));const t=i(r(8835));const o=i(r(6782));const c=i(r(3210));const a=r(44);const d=(0,o.default)("http-proxy-agent");function isHTTPS(e){return typeof e==="string"?/^https:?$/i.test(e):false}class HttpProxyAgent extends a.Agent{constructor(e){let n;if(typeof e==="string"){n=t.default.parse(e)}else{n=e}if(!n){throw new Error("an HTTP(S) proxy server `host` and `port` must be specified!")}d("Creating new HttpProxyAgent instance: %o",n);super(n);const r=Object.assign({},n);this.secureProxy=n.secureProxy||isHTTPS(r.protocol);r.host=r.hostname||r.host;if(typeof r.port==="string"){r.port=parseInt(r.port,10)}if(!r.port&&r.host){r.port=this.secureProxy?443:80}if(r.host&&r.path){delete r.path;delete r.pathname}this.proxy=r}callback(e,n){return s(this,void 0,void 0,function*(){const{proxy:r,secureProxy:s}=this;const i=t.default.parse(e.path);if(!i.protocol){i.protocol="http:"}if(!i.hostname){i.hostname=n.hostname||n.host||null}if(i.port==null&&typeof n.port){i.port=String(n.port)}if(i.port==="80"){i.port=""}e.path=t.default.format(i);if(r.auth){e.setHeader("Proxy-Authorization",`Basic ${Buffer.from(r.auth).toString("base64")}`)}let o;if(s){d("Creating `tls.Socket`: %o",r);o=l.default.connect(r)}else{d("Creating `net.Socket`: %o",r);o=f.default.connect(r)}if(e._header){let n;let r;d("Regenerating stored HTTP header string for request");e._header=null;e._implicitHeader();if(e.output&&e.output.length>0){d("Patching connection write() output buffer with updated header");n=e.output[0];r=n.indexOf("\r\n\r\n")+4;e.output[0]=e._header+n.substring(r);d("Output buffer: %o",e.output)}else if(e.outputData&&e.outputData.length>0){d("Patching connection write() output buffer with updated header");n=e.outputData[0].data;r=n.indexOf("\r\n\r\n")+4;e.outputData[0].data=e._header+n.substring(r);d("Output buffer: %o",e.outputData[0].data)}}yield(0,c.default)(o,"connect");return o})}}n.default=HttpProxyAgent},5865:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};const i=s(r(2872));function createHttpProxyAgent(e){return new i.default(e)}(function(e){e.HttpProxyAgent=i.default;e.prototype=i.default.prototype})(createHttpProxyAgent||(createHttpProxyAgent={}));e.exports=createHttpProxyAgent},8756:function(e,n,r){"use strict";var s=this&&this.__awaiter||function(e,n,r,s){function adopt(e){return e instanceof r?e:new r(function(n){n(e)})}return new(r||(r=Promise))(function(r,i){function fulfilled(e){try{step(s.next(e))}catch(e){i(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,n||[])).next())})};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});const f=i(r(1631));const l=i(r(4016));const t=i(r(8835));const o=i(r(2357));const c=i(r(6782));const a=r(44);const d=i(r(6733));const p=c.default("https-proxy-agent:agent");class HttpsProxyAgent extends a.Agent{constructor(e){let n;if(typeof e==="string"){n=t.default.parse(e)}else{n=e}if(!n){throw new Error("an HTTP(S) proxy server `host` and `port` must be specified!")}p("creating new HttpsProxyAgent instance: %o",n);super(n);const r=Object.assign({},n);this.secureProxy=n.secureProxy||isHTTPS(r.protocol);r.host=r.hostname||r.host;if(typeof r.port==="string"){r.port=parseInt(r.port,10)}if(!r.port&&r.host){r.port=this.secureProxy?443:80}if(this.secureProxy&&!("ALPNProtocols"in r)){r.ALPNProtocols=["http 1.1"]}if(r.host&&r.path){delete r.path;delete r.pathname}this.proxy=r}callback(e,n){return s(this,void 0,void 0,function*(){const{proxy:r,secureProxy:s}=this;let i;if(s){p("Creating `tls.Socket`: %o",r);i=l.default.connect(r)}else{p("Creating `net.Socket`: %o",r);i=f.default.connect(r)}const t=Object.assign({},r.headers);const c=`${n.host}:${n.port}`;let a=`CONNECT ${c} HTTP/1.1\r\n`;if(r.auth){t["Proxy-Authorization"]=`Basic ${Buffer.from(r.auth).toString("base64")}`}let{host:u,port:h,secureEndpoint:v}=n;if(!isDefaultPort(h,v)){u+=`:${h}`}t.Host=u;t.Connection="close";for(const e of Object.keys(t)){a+=`${e}: ${t[e]}\r\n`}const g=d.default(i);i.write(`${a}\r\n`);const{statusCode:b,buffered:w}=yield g;if(b===200){e.once("socket",resume);if(n.secureEndpoint){const e=n.servername||n.host;if(!e){throw new Error('Could not determine "servername"')}p("Upgrading socket connection to TLS");return l.default.connect(Object.assign(Object.assign({},omit(n,"host","hostname","path","port")),{socket:i,servername:e}))}return i}i.destroy();const y=new f.default.Socket;y.readable=true;e.once("socket",e=>{p("replaying proxy buffer for failed request");o.default(e.listenerCount("data")>0);e.push(w);e.push(null)});return y})}}n.default=HttpsProxyAgent;function resume(e){e.resume()}function isDefaultPort(e,n){return Boolean(!n&&e===80||n&&e===443)}function isHTTPS(e){return typeof e==="string"?/^https:?$/i.test(e):false}function omit(e,...n){const r={};let s;for(s in e){if(!n.includes(s)){r[s]=e[s]}}return r}},7052:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};const i=s(r(8756));function createHttpsProxyAgent(e){return new i.default(e)}(function(e){e.HttpsProxyAgent=i.default;e.prototype=i.default.prototype})(createHttpsProxyAgent||(createHttpsProxyAgent={}));e.exports=createHttpsProxyAgent},6733:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});const i=s(r(6782));const f=i.default("https-proxy-agent:parse-proxy-response");function parseProxyResponse(e){return new Promise((n,r)=>{let s=0;const i=[];function read(){const n=e.read();if(n)ondata(n);else e.once("readable",read)}function cleanup(){e.removeListener("end",onend);e.removeListener("error",onerror);e.removeListener("close",onclose);e.removeListener("readable",read)}function onclose(e){f("onclose had error %o",e)}function onend(){f("onend")}function onerror(e){cleanup();f("onerror %o",e);r(e)}function ondata(e){i.push(e);s+=e.length;const r=Buffer.concat(i,s);const l=r.indexOf("\r\n\r\n");if(l===-1){f("have not received end of HTTP headers yet...");read();return}const t=r.toString("ascii",0,r.indexOf("\r\n"));const o=+t.split(" ")[1];f("got proxy server response: %o",t);n({statusCode:o,buffered:r})}e.on("error",onerror);e.on("close",onclose);e.on("end",onend);read()})}n.default=parseProxyResponse},3499:(e,n,r)=>{"use strict";var s=r(1669);var i=r(9474);e.exports=function(e){if(typeof e==="number")return e;var n=i(e);if(n===undefined){var r=new Error(s.format("humanize-ms(%j) result undefined",e));console.warn(r.stack)}return n}},4455:e=>{"use strict";var n=typeof window!=="undefined"?window:typeof global!=="undefined"?global:{};e.exports=Individual;function Individual(e,r){if(e in n){return n[e]}n[e]=r;return r}},3655:(e,n,r)=>{try{var s=r(1669);if(typeof s.inherits!=="function")throw"";e.exports=s.inherits}catch(n){e.exports=r(9857)}},9857:e=>{if(typeof Object.create==="function"){e.exports=function inherits(e,n){if(n){e.super_=n;e.prototype=Object.create(n.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}}}else{e.exports=function inherits(e,n){if(n){e.super_=n;var r=function(){};r.prototype=n.prototype;e.prototype=new r;e.prototype.constructor=e}}}},5316:(e,n,r)=>{"use strict";var s=n;var i=r(4293).Buffer;var f=r(2087);s.toBuffer=function(e,n,r){r=~~r;var s;if(this.isV4Format(e)){s=n||new i(r+4);e.split(/\./g).map(function(e){s[r++]=parseInt(e,10)&255})}else if(this.isV6Format(e)){var f=e.split(":",8);var l;for(l=0;l<f.length;l++){var t=this.isV4Format(f[l]);var o;if(t){o=this.toBuffer(f[l]);f[l]=o.slice(0,2).toString("hex")}if(o&&++l<8){f.splice(l,0,o.slice(2,4).toString("hex"))}}if(f[0]===""){while(f.length<8)f.unshift("0")}else if(f[f.length-1]===""){while(f.length<8)f.push("0")}else if(f.length<8){for(l=0;l<f.length&&f[l]!=="";l++);var c=[l,1];for(l=9-f.length;l>0;l--){c.push("0")}f.splice.apply(f,c)}s=n||new i(r+16);for(l=0;l<f.length;l++){var a=parseInt(f[l],16);s[r++]=a>>8&255;s[r++]=a&255}}if(!s){throw Error("Invalid ip address: "+e)}return s};s.toString=function(e,n,r){n=~~n;r=r||e.length-n;var s=[];if(r===4){for(var i=0;i<r;i++){s.push(e[n+i])}s=s.join(".")}else if(r===16){for(var i=0;i<r;i+=2){s.push(e.readUInt16BE(n+i).toString(16))}s=s.join(":");s=s.replace(/(^|:)0(:0)*:0(:|$)/,"$1::$3");s=s.replace(/:{3,4}/,"::")}return s};var l=/^(\d{1,3}\.){3,3}\d{1,3}$/;var t=/^(::)?(((\d{1,3}\.){3}(\d{1,3}){1})?([0-9a-f]){0,4}:{0,2}){1,8}(::)?$/i;s.isV4Format=function(e){return l.test(e)};s.isV6Format=function(e){return t.test(e)};function _normalizeFamily(e){return e?e.toLowerCase():"ipv4"}s.fromPrefixLen=function(e,n){if(e>32){n="ipv6"}else{n=_normalizeFamily(n)}var r=4;if(n==="ipv6"){r=16}var f=new i(r);for(var l=0,t=f.length;l<t;++l){var o=8;if(e<8){o=e}e-=o;f[l]=~(255>>o)&255}return s.toString(f)};s.mask=function(e,n){e=s.toBuffer(e);n=s.toBuffer(n);var r=new i(Math.max(e.length,n.length));var f=0;if(e.length===n.length){for(f=0;f<e.length;f++){r[f]=e[f]&n[f]}}else if(n.length===4){for(f=0;f<n.length;f++){r[f]=e[e.length-4+f]&n[f]}}else{for(var f=0;f<r.length-6;f++){r[f]=0}r[10]=255;r[11]=255;for(f=0;f<e.length;f++){r[f+12]=e[f]&n[f+12]}f=f+12}for(;f<r.length;f++)r[f]=0;return s.toString(r)};s.cidr=function(e){var n=e.split("/");var r=n[0];if(n.length!==2)throw new Error("invalid CIDR subnet: "+r);var i=s.fromPrefixLen(parseInt(n[1],10));return s.mask(r,i)};s.subnet=function(e,n){var r=s.toLong(s.mask(e,n));var i=s.toBuffer(n);var f=0;for(var l=0;l<i.length;l++){if(i[l]===255){f+=8}else{var t=i[l]&255;while(t){t=t<<1&255;f++}}}var o=Math.pow(2,32-f);return{networkAddress:s.fromLong(r),firstAddress:o<=2?s.fromLong(r):s.fromLong(r+1),lastAddress:o<=2?s.fromLong(r+o-1):s.fromLong(r+o-2),broadcastAddress:s.fromLong(r+o-1),subnetMask:n,subnetMaskLength:f,numHosts:o<=2?o:o-2,length:o,contains:function(e){return r===s.toLong(s.mask(e,n))}}};s.cidrSubnet=function(e){var n=e.split("/");var r=n[0];if(n.length!==2)throw new Error("invalid CIDR subnet: "+r);var i=s.fromPrefixLen(parseInt(n[1],10));return s.subnet(r,i)};s.not=function(e){var n=s.toBuffer(e);for(var r=0;r<n.length;r++){n[r]=255^n[r]}return s.toString(n)};s.or=function(e,n){e=s.toBuffer(e);n=s.toBuffer(n);if(e.length===n.length){for(var r=0;r<e.length;++r){e[r]|=n[r]}return s.toString(e)}else{var i=e;var f=n;if(n.length>e.length){i=n;f=e}var l=i.length-f.length;for(var r=l;r<i.length;++r){i[r]|=f[r-l]}return s.toString(i)}};s.isEqual=function(e,n){e=s.toBuffer(e);n=s.toBuffer(n);if(e.length===n.length){for(var r=0;r<e.length;r++){if(e[r]!==n[r])return false}return true}if(n.length===4){var i=n;n=e;e=i}for(var r=0;r<10;r++){if(n[r]!==0)return false}var f=n.readUInt16BE(10);if(f!==0&&f!==65535)return false;for(var r=0;r<4;r++){if(e[r]!==n[r+12])return false}return true};s.isPrivate=function(e){return/^(::f{4}:)?10\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?192\.168\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?172\.(1[6-9]|2\d|30|31)\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?127\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?169\.254\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^f[cd][0-9a-f]{2}:/i.test(e)||/^fe80:/i.test(e)||/^::1$/.test(e)||/^::$/.test(e)};s.isPublic=function(e){return!s.isPrivate(e)};s.isLoopback=function(e){return/^(::f{4}:)?127\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})/.test(e)||/^fe80::1$/.test(e)||/^::1$/.test(e)||/^::$/.test(e)};s.loopback=function(e){e=_normalizeFamily(e);if(e!=="ipv4"&&e!=="ipv6"){throw new Error("family must be ipv4 or ipv6")}return e==="ipv4"?"127.0.0.1":"fe80::1"};s.address=function(e,n){var r=f.networkInterfaces();var i;n=_normalizeFamily(n);if(e&&e!=="private"&&e!=="public"){var l=r[e].filter(function(e){var r=e.family.toLowerCase();return r===n});if(l.length===0)return undefined;return l[0].address}var i=Object.keys(r).map(function(i){var f=r[i].filter(function(r){r.family=r.family.toLowerCase();if(r.family!==n||s.isLoopback(r.address)){return false}else if(!e){return true}return e==="public"?s.isPrivate(r.address):s.isPublic(r.address)});return f.length?f[0].address:undefined}).filter(Boolean);return!i.length?s.loopback(n):i[0]};s.toLong=function(e){var n=0;e.split(".").forEach(function(e){n<<=8;n+=parseInt(e)});return n>>>0};s.fromLong=function(e){return(e>>>24)+"."+(e>>16&255)+"."+(e>>8&255)+"."+(e&255)}},6070:(e,n,r)=>{"use strict";var s=r(7372);var i=r(319);function renamed(e,n){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. "+"Use yaml."+n+" instead, which is now safe by default.")}}e.exports.Type=r(7060);e.exports.Schema=r(6435);e.exports.FAILSAFE_SCHEMA=r(7947);e.exports.JSON_SCHEMA=r(6918);e.exports.CORE_SCHEMA=r(6670);e.exports.DEFAULT_SCHEMA=r(3498);e.exports.load=s.load;e.exports.loadAll=s.loadAll;e.exports.dump=i.dump;e.exports.YAMLException=r(6141);e.exports.types={binary:r(2410),float:r(3760),map:r(5113),null:r(5711),pairs:r(8851),set:r(7282),timestamp:r(3637),bool:r(4719),int:r(436),merge:r(4789),omap:r(4189),seq:r(7331),str:r(1299)};e.exports.safeLoad=renamed("safeLoad","load");e.exports.safeLoadAll=renamed("safeLoadAll","loadAll");e.exports.safeDump=renamed("safeDump","dump")},130:e=>{"use strict";function isNothing(e){return typeof e==="undefined"||e===null}function isObject(e){return typeof e==="object"&&e!==null}function toArray(e){if(Array.isArray(e))return e;else if(isNothing(e))return[];return[e]}function extend(e,n){var r,s,i,f;if(n){f=Object.keys(n);for(r=0,s=f.length;r<s;r+=1){i=f[r];e[i]=n[i]}}return e}function repeat(e,n){var r="",s;for(s=0;s<n;s+=1){r+=e}return r}function isNegativeZero(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}e.exports.isNothing=isNothing;e.exports.isObject=isObject;e.exports.toArray=toArray;e.exports.repeat=repeat;e.exports.isNegativeZero=isNegativeZero;e.exports.extend=extend},319:(e,n,r)=>{"use strict";var s=r(130);var i=r(6141);var f=r(3498);var l=Object.prototype.toString;var t=Object.prototype.hasOwnProperty;var o=65279;var c=9;var a=10;var d=13;var p=32;var u=33;var h=34;var v=35;var g=37;var b=38;var w=39;var y=42;var m=44;var E=45;var S=58;var C=61;var O=62;var A=63;var R=64;var k=91;var I=93;var T=96;var x=123;var F=124;var j=125;var B={};B[0]="\\0";B[7]="\\a";B[8]="\\b";B[9]="\\t";B[10]="\\n";B[11]="\\v";B[12]="\\f";B[13]="\\r";B[27]="\\e";B[34]='\\"';B[92]="\\\\";B[133]="\\N";B[160]="\\_";B[8232]="\\L";B[8233]="\\P";var L=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];var M=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function compileStyleMap(e,n){var r,s,i,f,l,o,c;if(n===null)return{};r={};s=Object.keys(n);for(i=0,f=s.length;i<f;i+=1){l=s[i];o=String(n[l]);if(l.slice(0,2)==="!!"){l="tag:yaml.org,2002:"+l.slice(2)}c=e.compiledTypeMap["fallback"][l];if(c&&t.call(c.styleAliases,o)){o=c.styleAliases[o]}r[l]=o}return r}function encodeHex(e){var n,r,f;n=e.toString(16).toUpperCase();if(e<=255){r="x";f=2}else if(e<=65535){r="u";f=4}else if(e<=4294967295){r="U";f=8}else{throw new i("code point within a string may not be greater than 0xFFFFFFFF")}return"\\"+r+s.repeat("0",f-n.length)+n}var U=1,D=2;function State(e){this.schema=e["schema"]||f;this.indent=Math.max(1,e["indent"]||2);this.noArrayIndent=e["noArrayIndent"]||false;this.skipInvalid=e["skipInvalid"]||false;this.flowLevel=s.isNothing(e["flowLevel"])?-1:e["flowLevel"];this.styleMap=compileStyleMap(this.schema,e["styles"]||null);this.sortKeys=e["sortKeys"]||false;this.lineWidth=e["lineWidth"]||80;this.noRefs=e["noRefs"]||false;this.noCompatMode=e["noCompatMode"]||false;this.condenseFlow=e["condenseFlow"]||false;this.quotingType=e["quotingType"]==='"'?D:U;this.forceQuotes=e["forceQuotes"]||false;this.replacer=typeof e["replacer"]==="function"?e["replacer"]:null;this.implicitTypes=this.schema.compiledImplicit;this.explicitTypes=this.schema.compiledExplicit;this.tag=null;this.result="";this.duplicates=[];this.usedDuplicates=null}function indentString(e,n){var r=s.repeat(" ",n),i=0,f=-1,l="",t,o=e.length;while(i<o){f=e.indexOf("\n",i);if(f===-1){t=e.slice(i);i=o}else{t=e.slice(i,f+1);i=f+1}if(t.length&&t!=="\n")l+=r;l+=t}return l}function generateNextLine(e,n){return"\n"+s.repeat(" ",e.indent*n)}function testImplicitResolving(e,n){var r,s,i;for(r=0,s=e.implicitTypes.length;r<s;r+=1){i=e.implicitTypes[r];if(i.resolve(n)){return true}}return false}function isWhitespace(e){return e===p||e===c}function isPrintable(e){return 32<=e&&e<=126||161<=e&&e<=55295&&e!==8232&&e!==8233||57344<=e&&e<=65533&&e!==o||65536<=e&&e<=1114111}function isNsCharOrWhitespace(e){return isPrintable(e)&&e!==o&&e!==d&&e!==a}function isPlainSafe(e,n,r){var s=isNsCharOrWhitespace(e);var i=s&&!isWhitespace(e);return(r?s:s&&e!==m&&e!==k&&e!==I&&e!==x&&e!==j)&&e!==v&&!(n===S&&!i)||isNsCharOrWhitespace(n)&&!isWhitespace(n)&&e===v||n===S&&i}function isPlainSafeFirst(e){return isPrintable(e)&&e!==o&&!isWhitespace(e)&&e!==E&&e!==A&&e!==S&&e!==m&&e!==k&&e!==I&&e!==x&&e!==j&&e!==v&&e!==b&&e!==y&&e!==u&&e!==F&&e!==C&&e!==O&&e!==w&&e!==h&&e!==g&&e!==R&&e!==T}function isPlainSafeLast(e){return!isWhitespace(e)&&e!==S}function codePointAt(e,n){var r=e.charCodeAt(n),s;if(r>=55296&&r<=56319&&n+1<e.length){s=e.charCodeAt(n+1);if(s>=56320&&s<=57343){return(r-55296)*1024+s-56320+65536}}return r}function needIndentIndicator(e){var n=/^\n* /;return n.test(e)}var N=1,q=2,z=3,H=4,W=5;function chooseScalarStyle(e,n,r,s,i,f,l,t){var o;var c=0;var d=null;var p=false;var u=false;var h=s!==-1;var v=-1;var g=isPlainSafeFirst(codePointAt(e,0))&&isPlainSafeLast(codePointAt(e,e.length-1));if(n||l){for(o=0;o<e.length;c>=65536?o+=2:o++){c=codePointAt(e,o);if(!isPrintable(c)){return W}g=g&&isPlainSafe(c,d,t);d=c}}else{for(o=0;o<e.length;c>=65536?o+=2:o++){c=codePointAt(e,o);if(c===a){p=true;if(h){u=u||o-v-1>s&&e[v+1]!==" ";v=o}}else if(!isPrintable(c)){return W}g=g&&isPlainSafe(c,d,t);d=c}u=u||h&&(o-v-1>s&&e[v+1]!==" ")}if(!p&&!u){if(g&&!l&&!i(e)){return N}return f===D?W:q}if(r>9&&needIndentIndicator(e)){return W}if(!l){return u?H:z}return f===D?W:q}function writeScalar(e,n,r,s,f){e.dump=function(){if(n.length===0){return e.quotingType===D?'""':"''"}if(!e.noCompatMode){if(L.indexOf(n)!==-1||M.test(n)){return e.quotingType===D?'"'+n+'"':"'"+n+"'"}}var l=e.indent*Math.max(1,r);var t=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-l);var o=s||e.flowLevel>-1&&r>=e.flowLevel;function testAmbiguity(n){return testImplicitResolving(e,n)}switch(chooseScalarStyle(n,o,e.indent,t,testAmbiguity,e.quotingType,e.forceQuotes&&!s,f)){case N:return n;case q:return"'"+n.replace(/'/g,"''")+"'";case z:return"|"+blockHeader(n,e.indent)+dropEndingNewline(indentString(n,l));case H:return">"+blockHeader(n,e.indent)+dropEndingNewline(indentString(foldString(n,t),l));case W:return'"'+escapeString(n,t)+'"';default:throw new i("impossible error: invalid scalar style")}}()}function blockHeader(e,n){var r=needIndentIndicator(e)?String(n):"";var s=e[e.length-1]==="\n";var i=s&&(e[e.length-2]==="\n"||e==="\n");var f=i?"+":s?"":"-";return r+f+"\n"}function dropEndingNewline(e){return e[e.length-1]==="\n"?e.slice(0,-1):e}function foldString(e,n){var r=/(\n+)([^\n]*)/g;var s=function(){var s=e.indexOf("\n");s=s!==-1?s:e.length;r.lastIndex=s;return foldLine(e.slice(0,s),n)}();var i=e[0]==="\n"||e[0]===" ";var f;var l;while(l=r.exec(e)){var t=l[1],o=l[2];f=o[0]===" ";s+=t+(!i&&!f&&o!==""?"\n":"")+foldLine(o,n);i=f}return s}function foldLine(e,n){if(e===""||e[0]===" ")return e;var r=/ [^ ]/g;var s;var i=0,f,l=0,t=0;var o="";while(s=r.exec(e)){t=s.index;if(t-i>n){f=l>i?l:t;o+="\n"+e.slice(i,f);i=f+1}l=t}o+="\n";if(e.length-i>n&&l>i){o+=e.slice(i,l)+"\n"+e.slice(l+1)}else{o+=e.slice(i)}return o.slice(1)}function escapeString(e){var n="";var r=0;var s;for(var i=0;i<e.length;r>=65536?i+=2:i++){r=codePointAt(e,i);s=B[r];if(!s&&isPrintable(r)){n+=e[i];if(r>=65536)n+=e[i+1]}else{n+=s||encodeHex(r)}}return n}function writeFlowSequence(e,n,r){var s="",i=e.tag,f,l,t;for(f=0,l=r.length;f<l;f+=1){t=r[f];if(e.replacer){t=e.replacer.call(r,String(f),t)}if(writeNode(e,n,t,false,false)||typeof t==="undefined"&&writeNode(e,n,null,false,false)){if(s!=="")s+=","+(!e.condenseFlow?" ":"");s+=e.dump}}e.tag=i;e.dump="["+s+"]"}function writeBlockSequence(e,n,r,s){var i="",f=e.tag,l,t,o;for(l=0,t=r.length;l<t;l+=1){o=r[l];if(e.replacer){o=e.replacer.call(r,String(l),o)}if(writeNode(e,n+1,o,true,true,false,true)||typeof o==="undefined"&&writeNode(e,n+1,null,true,true,false,true)){if(!s||i!==""){i+=generateNextLine(e,n)}if(e.dump&&a===e.dump.charCodeAt(0)){i+="-"}else{i+="- "}i+=e.dump}}e.tag=f;e.dump=i||"[]"}function writeFlowMapping(e,n,r){var s="",i=e.tag,f=Object.keys(r),l,t,o,c,a;for(l=0,t=f.length;l<t;l+=1){a="";if(s!=="")a+=", ";if(e.condenseFlow)a+='"';o=f[l];c=r[o];if(e.replacer){c=e.replacer.call(r,o,c)}if(!writeNode(e,n,o,false,false)){continue}if(e.dump.length>1024)a+="? ";a+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" ");if(!writeNode(e,n,c,false,false)){continue}a+=e.dump;s+=a}e.tag=i;e.dump="{"+s+"}"}function writeBlockMapping(e,n,r,s){var f="",l=e.tag,t=Object.keys(r),o,c,d,p,u,h;if(e.sortKeys===true){t.sort()}else if(typeof e.sortKeys==="function"){t.sort(e.sortKeys)}else if(e.sortKeys){throw new i("sortKeys must be a boolean or a function")}for(o=0,c=t.length;o<c;o+=1){h="";if(!s||f!==""){h+=generateNextLine(e,n)}d=t[o];p=r[d];if(e.replacer){p=e.replacer.call(r,d,p)}if(!writeNode(e,n+1,d,true,true,true)){continue}u=e.tag!==null&&e.tag!=="?"||e.dump&&e.dump.length>1024;if(u){if(e.dump&&a===e.dump.charCodeAt(0)){h+="?"}else{h+="? "}}h+=e.dump;if(u){h+=generateNextLine(e,n)}if(!writeNode(e,n+1,p,true,u)){continue}if(e.dump&&a===e.dump.charCodeAt(0)){h+=":"}else{h+=": "}h+=e.dump;f+=h}e.tag=l;e.dump=f||"{}"}function detectType(e,n,r){var s,f,o,c,a,d;f=r?e.explicitTypes:e.implicitTypes;for(o=0,c=f.length;o<c;o+=1){a=f[o];if((a.instanceOf||a.predicate)&&(!a.instanceOf||typeof n==="object"&&n instanceof a.instanceOf)&&(!a.predicate||a.predicate(n))){if(r){if(a.multi&&a.representName){e.tag=a.representName(n)}else{e.tag=a.tag}}else{e.tag="?"}if(a.represent){d=e.styleMap[a.tag]||a.defaultStyle;if(l.call(a.represent)==="[object Function]"){s=a.represent(n,d)}else if(t.call(a.represent,d)){s=a.represent[d](n,d)}else{throw new i("!<"+a.tag+'> tag resolver accepts not "'+d+'" style')}e.dump=s}return true}}return false}function writeNode(e,n,r,s,f,t,o){e.tag=null;e.dump=r;if(!detectType(e,r,false)){detectType(e,r,true)}var c=l.call(e.dump);var a=s;var d;if(s){s=e.flowLevel<0||e.flowLevel>n}var p=c==="[object Object]"||c==="[object Array]",u,h;if(p){u=e.duplicates.indexOf(r);h=u!==-1}if(e.tag!==null&&e.tag!=="?"||h||e.indent!==2&&n>0){f=false}if(h&&e.usedDuplicates[u]){e.dump="*ref_"+u}else{if(p&&h&&!e.usedDuplicates[u]){e.usedDuplicates[u]=true}if(c==="[object Object]"){if(s&&Object.keys(e.dump).length!==0){writeBlockMapping(e,n,e.dump,f);if(h){e.dump="&ref_"+u+e.dump}}else{writeFlowMapping(e,n,e.dump);if(h){e.dump="&ref_"+u+" "+e.dump}}}else if(c==="[object Array]"){if(s&&e.dump.length!==0){if(e.noArrayIndent&&!o&&n>0){writeBlockSequence(e,n-1,e.dump,f)}else{writeBlockSequence(e,n,e.dump,f)}if(h){e.dump="&ref_"+u+e.dump}}else{writeFlowSequence(e,n,e.dump);if(h){e.dump="&ref_"+u+" "+e.dump}}}else if(c==="[object String]"){if(e.tag!=="?"){writeScalar(e,e.dump,n,t,a)}}else if(c==="[object Undefined]"){return false}else{if(e.skipInvalid)return false;throw new i("unacceptable kind of an object to dump "+c)}if(e.tag!==null&&e.tag!=="?"){d=encodeURI(e.tag[0]==="!"?e.tag.slice(1):e.tag).replace(/!/g,"%21");if(e.tag[0]==="!"){d="!"+d}else if(d.slice(0,18)==="tag:yaml.org,2002:"){d="!!"+d.slice(18)}else{d="!<"+d+">"}e.dump=d+" "+e.dump}}return true}function getDuplicateReferences(e,n){var r=[],s=[],i,f;inspectNode(e,r,s);for(i=0,f=s.length;i<f;i+=1){n.duplicates.push(r[s[i]])}n.usedDuplicates=new Array(f)}function inspectNode(e,n,r){var s,i,f;if(e!==null&&typeof e==="object"){i=n.indexOf(e);if(i!==-1){if(r.indexOf(i)===-1){r.push(i)}}else{n.push(e);if(Array.isArray(e)){for(i=0,f=e.length;i<f;i+=1){inspectNode(e[i],n,r)}}else{s=Object.keys(e);for(i=0,f=s.length;i<f;i+=1){inspectNode(e[s[i]],n,r)}}}}}function dump(e,n){n=n||{};var r=new State(n);if(!r.noRefs)getDuplicateReferences(e,r);var s=e;if(r.replacer){s=r.replacer.call({"":s},"",s)}if(writeNode(r,0,s,true,true))return r.dump+"\n";return""}e.exports.dump=dump},6141:e=>{"use strict";function formatError(e,n){var r="",s=e.reason||"(unknown reason)";if(!e.mark)return s;if(e.mark.name){r+='in "'+e.mark.name+'" '}r+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")";if(!n&&e.mark.snippet){r+="\n\n"+e.mark.snippet}return s+" "+r}function YAMLException(e,n){Error.call(this);this.name="YAMLException";this.reason=e;this.mark=n;this.message=formatError(this,false);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}else{this.stack=(new Error).stack||""}}YAMLException.prototype=Object.create(Error.prototype);YAMLException.prototype.constructor=YAMLException;YAMLException.prototype.toString=function toString(e){return this.name+": "+formatError(this,e)};e.exports=YAMLException},7372:(e,n,r)=>{"use strict";var s=r(130);var i=r(6141);var f=r(163);var l=r(3498);var t=Object.prototype.hasOwnProperty;var o=1;var c=2;var a=3;var d=4;var p=1;var u=2;var h=3;var v=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/;var g=/[\x85\u2028\u2029]/;var b=/[,\[\]\{\}]/;var w=/^(?:!|!!|![a-z\-]+!)$/i;var y=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function _class(e){return Object.prototype.toString.call(e)}function is_EOL(e){return e===10||e===13}function is_WHITE_SPACE(e){return e===9||e===32}function is_WS_OR_EOL(e){return e===9||e===32||e===10||e===13}function is_FLOW_INDICATOR(e){return e===44||e===91||e===93||e===123||e===125}function fromHexCode(e){var n;if(48<=e&&e<=57){return e-48}n=e|32;if(97<=n&&n<=102){return n-97+10}return-1}function escapedHexLen(e){if(e===120){return 2}if(e===117){return 4}if(e===85){return 8}return 0}function fromDecimalCode(e){if(48<=e&&e<=57){return e-48}return-1}function simpleEscapeSequence(e){return e===48?"\0":e===97?"":e===98?"\b":e===116?"\t":e===9?"\t":e===110?"\n":e===118?"\v":e===102?"\f":e===114?"\r":e===101?"":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"
":e===95?" ":e===76?"\u2028":e===80?"\u2029":""}function charFromCodepoint(e){if(e<=65535){return String.fromCharCode(e)}return String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}var m=new Array(256);var E=new Array(256);for(var S=0;S<256;S++){m[S]=simpleEscapeSequence(S)?1:0;E[S]=simpleEscapeSequence(S)}function State(e,n){this.input=e;this.filename=n["filename"]||null;this.schema=n["schema"]||l;this.onWarning=n["onWarning"]||null;this.legacy=n["legacy"]||false;this.json=n["json"]||false;this.listener=n["listener"]||null;this.implicitTypes=this.schema.compiledImplicit;this.typeMap=this.schema.compiledTypeMap;this.length=e.length;this.position=0;this.line=0;this.lineStart=0;this.lineIndent=0;this.firstTabInLine=-1;this.documents=[]}function generateError(e,n){var r={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};r.snippet=f(r);return new i(n,r)}function throwError(e,n){throw generateError(e,n)}function throwWarning(e,n){if(e.onWarning){e.onWarning.call(null,generateError(e,n))}}var C={YAML:function handleYamlDirective(e,n,r){var s,i,f;if(e.version!==null){throwError(e,"duplication of %YAML directive")}if(r.length!==1){throwError(e,"YAML directive accepts exactly one argument")}s=/^([0-9]+)\.([0-9]+)$/.exec(r[0]);if(s===null){throwError(e,"ill-formed argument of the YAML directive")}i=parseInt(s[1],10);f=parseInt(s[2],10);if(i!==1){throwError(e,"unacceptable YAML version of the document")}e.version=r[0];e.checkLineBreaks=f<2;if(f!==1&&f!==2){throwWarning(e,"unsupported YAML version of the document")}},TAG:function handleTagDirective(e,n,r){var s,i;if(r.length!==2){throwError(e,"TAG directive accepts exactly two arguments")}s=r[0];i=r[1];if(!w.test(s)){throwError(e,"ill-formed tag handle (first argument) of the TAG directive")}if(t.call(e.tagMap,s)){throwError(e,'there is a previously declared suffix for "'+s+'" tag handle')}if(!y.test(i)){throwError(e,"ill-formed tag prefix (second argument) of the TAG directive")}try{i=decodeURIComponent(i)}catch(n){throwError(e,"tag prefix is malformed: "+i)}e.tagMap[s]=i}};function captureSegment(e,n,r,s){var i,f,l,t;if(n<r){t=e.input.slice(n,r);if(s){for(i=0,f=t.length;i<f;i+=1){l=t.charCodeAt(i);if(!(l===9||32<=l&&l<=1114111)){throwError(e,"expected valid JSON character")}}}else if(v.test(t)){throwError(e,"the stream contains non-printable characters")}e.result+=t}}function mergeMappings(e,n,r,i){var f,l,o,c;if(!s.isObject(r)){throwError(e,"cannot merge mappings; the provided source object is unacceptable")}f=Object.keys(r);for(o=0,c=f.length;o<c;o+=1){l=f[o];if(!t.call(n,l)){n[l]=r[l];i[l]=true}}}function storeMappingPair(e,n,r,s,i,f,l,o,c){var a,d;if(Array.isArray(i)){i=Array.prototype.slice.call(i);for(a=0,d=i.length;a<d;a+=1){if(Array.isArray(i[a])){throwError(e,"nested arrays are not supported inside keys")}if(typeof i==="object"&&_class(i[a])==="[object Object]"){i[a]="[object Object]"}}}if(typeof i==="object"&&_class(i)==="[object Object]"){i="[object Object]"}i=String(i);if(n===null){n={}}if(s==="tag:yaml.org,2002:merge"){if(Array.isArray(f)){for(a=0,d=f.length;a<d;a+=1){mergeMappings(e,n,f[a],r)}}else{mergeMappings(e,n,f,r)}}else{if(!e.json&&!t.call(r,i)&&t.call(n,i)){e.line=l||e.line;e.lineStart=o||e.lineStart;e.position=c||e.position;throwError(e,"duplicated mapping key")}if(i==="__proto__"){Object.defineProperty(n,i,{configurable:true,enumerable:true,writable:true,value:f})}else{n[i]=f}delete r[i]}return n}function readLineBreak(e){var n;n=e.input.charCodeAt(e.position);if(n===10){e.position++}else if(n===13){e.position++;if(e.input.charCodeAt(e.position)===10){e.position++}}else{throwError(e,"a line break is expected")}e.line+=1;e.lineStart=e.position;e.firstTabInLine=-1}function skipSeparationSpace(e,n,r){var s=0,i=e.input.charCodeAt(e.position);while(i!==0){while(is_WHITE_SPACE(i)){if(i===9&&e.firstTabInLine===-1){e.firstTabInLine=e.position}i=e.input.charCodeAt(++e.position)}if(n&&i===35){do{i=e.input.charCodeAt(++e.position)}while(i!==10&&i!==13&&i!==0)}if(is_EOL(i)){readLineBreak(e);i=e.input.charCodeAt(e.position);s++;e.lineIndent=0;while(i===32){e.lineIndent++;i=e.input.charCodeAt(++e.position)}}else{break}}if(r!==-1&&s!==0&&e.lineIndent<r){throwWarning(e,"deficient indentation")}return s}function testDocumentSeparator(e){var n=e.position,r;r=e.input.charCodeAt(n);if((r===45||r===46)&&r===e.input.charCodeAt(n+1)&&r===e.input.charCodeAt(n+2)){n+=3;r=e.input.charCodeAt(n);if(r===0||is_WS_OR_EOL(r)){return true}}return false}function writeFoldedLines(e,n){if(n===1){e.result+=" "}else if(n>1){e.result+=s.repeat("\n",n-1)}}function readPlainScalar(e,n,r){var s,i,f,l,t,o,c,a,d=e.kind,p=e.result,u;u=e.input.charCodeAt(e.position);if(is_WS_OR_EOL(u)||is_FLOW_INDICATOR(u)||u===35||u===38||u===42||u===33||u===124||u===62||u===39||u===34||u===37||u===64||u===96){return false}if(u===63||u===45){i=e.input.charCodeAt(e.position+1);if(is_WS_OR_EOL(i)||r&&is_FLOW_INDICATOR(i)){return false}}e.kind="scalar";e.result="";f=l=e.position;t=false;while(u!==0){if(u===58){i=e.input.charCodeAt(e.position+1);if(is_WS_OR_EOL(i)||r&&is_FLOW_INDICATOR(i)){break}}else if(u===35){s=e.input.charCodeAt(e.position-1);if(is_WS_OR_EOL(s)){break}}else if(e.position===e.lineStart&&testDocumentSeparator(e)||r&&is_FLOW_INDICATOR(u)){break}else if(is_EOL(u)){o=e.line;c=e.lineStart;a=e.lineIndent;skipSeparationSpace(e,false,-1);if(e.lineIndent>=n){t=true;u=e.input.charCodeAt(e.position);continue}else{e.position=l;e.line=o;e.lineStart=c;e.lineIndent=a;break}}if(t){captureSegment(e,f,l,false);writeFoldedLines(e,e.line-o);f=l=e.position;t=false}if(!is_WHITE_SPACE(u)){l=e.position+1}u=e.input.charCodeAt(++e.position)}captureSegment(e,f,l,false);if(e.result){return true}e.kind=d;e.result=p;return false}function readSingleQuotedScalar(e,n){var r,s,i;r=e.input.charCodeAt(e.position);if(r!==39){return false}e.kind="scalar";e.result="";e.position++;s=i=e.position;while((r=e.input.charCodeAt(e.position))!==0){if(r===39){captureSegment(e,s,e.position,true);r=e.input.charCodeAt(++e.position);if(r===39){s=e.position;e.position++;i=e.position}else{return true}}else if(is_EOL(r)){captureSegment(e,s,i,true);writeFoldedLines(e,skipSeparationSpace(e,false,n));s=i=e.position}else if(e.position===e.lineStart&&testDocumentSeparator(e)){throwError(e,"unexpected end of the document within a single quoted scalar")}else{e.position++;i=e.position}}throwError(e,"unexpected end of the stream within a single quoted scalar")}function readDoubleQuotedScalar(e,n){var r,s,i,f,l,t;t=e.input.charCodeAt(e.position);if(t!==34){return false}e.kind="scalar";e.result="";e.position++;r=s=e.position;while((t=e.input.charCodeAt(e.position))!==0){if(t===34){captureSegment(e,r,e.position,true);e.position++;return true}else if(t===92){captureSegment(e,r,e.position,true);t=e.input.charCodeAt(++e.position);if(is_EOL(t)){skipSeparationSpace(e,false,n)}else if(t<256&&m[t]){e.result+=E[t];e.position++}else if((l=escapedHexLen(t))>0){i=l;f=0;for(;i>0;i--){t=e.input.charCodeAt(++e.position);if((l=fromHexCode(t))>=0){f=(f<<4)+l}else{throwError(e,"expected hexadecimal character")}}e.result+=charFromCodepoint(f);e.position++}else{throwError(e,"unknown escape sequence")}r=s=e.position}else if(is_EOL(t)){captureSegment(e,r,s,true);writeFoldedLines(e,skipSeparationSpace(e,false,n));r=s=e.position}else if(e.position===e.lineStart&&testDocumentSeparator(e)){throwError(e,"unexpected end of the document within a double quoted scalar")}else{e.position++;s=e.position}}throwError(e,"unexpected end of the stream within a double quoted scalar")}function readFlowCollection(e,n){var r=true,s,i,f,l=e.tag,t,c=e.anchor,a,d,p,u,h,v=Object.create(null),g,b,w,y;y=e.input.charCodeAt(e.position);if(y===91){d=93;h=false;t=[]}else if(y===123){d=125;h=true;t={}}else{return false}if(e.anchor!==null){e.anchorMap[e.anchor]=t}y=e.input.charCodeAt(++e.position);while(y!==0){skipSeparationSpace(e,true,n);y=e.input.charCodeAt(e.position);if(y===d){e.position++;e.tag=l;e.anchor=c;e.kind=h?"mapping":"sequence";e.result=t;return true}else if(!r){throwError(e,"missed comma between flow collection entries")}else if(y===44){throwError(e,"expected the node content, but found ','")}b=g=w=null;p=u=false;if(y===63){a=e.input.charCodeAt(e.position+1);if(is_WS_OR_EOL(a)){p=u=true;e.position++;skipSeparationSpace(e,true,n)}}s=e.line;i=e.lineStart;f=e.position;composeNode(e,n,o,false,true);b=e.tag;g=e.result;skipSeparationSpace(e,true,n);y=e.input.charCodeAt(e.position);if((u||e.line===s)&&y===58){p=true;y=e.input.charCodeAt(++e.position);skipSeparationSpace(e,true,n);composeNode(e,n,o,false,true);w=e.result}if(h){storeMappingPair(e,t,v,b,g,w,s,i,f)}else if(p){t.push(storeMappingPair(e,null,v,b,g,w,s,i,f))}else{t.push(g)}skipSeparationSpace(e,true,n);y=e.input.charCodeAt(e.position);if(y===44){r=true;y=e.input.charCodeAt(++e.position)}else{r=false}}throwError(e,"unexpected end of the stream within a flow collection")}function readBlockScalar(e,n){var r,i,f=p,l=false,t=false,o=n,c=0,a=false,d,v;v=e.input.charCodeAt(e.position);if(v===124){i=false}else if(v===62){i=true}else{return false}e.kind="scalar";e.result="";while(v!==0){v=e.input.charCodeAt(++e.position);if(v===43||v===45){if(p===f){f=v===43?h:u}else{throwError(e,"repeat of a chomping mode identifier")}}else if((d=fromDecimalCode(v))>=0){if(d===0){throwError(e,"bad explicit indentation width of a block scalar; it cannot be less than one")}else if(!t){o=n+d-1;t=true}else{throwError(e,"repeat of an indentation width identifier")}}else{break}}if(is_WHITE_SPACE(v)){do{v=e.input.charCodeAt(++e.position)}while(is_WHITE_SPACE(v));if(v===35){do{v=e.input.charCodeAt(++e.position)}while(!is_EOL(v)&&v!==0)}}while(v!==0){readLineBreak(e);e.lineIndent=0;v=e.input.charCodeAt(e.position);while((!t||e.lineIndent<o)&&v===32){e.lineIndent++;v=e.input.charCodeAt(++e.position)}if(!t&&e.lineIndent>o){o=e.lineIndent}if(is_EOL(v)){c++;continue}if(e.lineIndent<o){if(f===h){e.result+=s.repeat("\n",l?1+c:c)}else if(f===p){if(l){e.result+="\n"}}break}if(i){if(is_WHITE_SPACE(v)){a=true;e.result+=s.repeat("\n",l?1+c:c)}else if(a){a=false;e.result+=s.repeat("\n",c+1)}else if(c===0){if(l){e.result+=" "}}else{e.result+=s.repeat("\n",c)}}else{e.result+=s.repeat("\n",l?1+c:c)}l=true;t=true;c=0;r=e.position;while(!is_EOL(v)&&v!==0){v=e.input.charCodeAt(++e.position)}captureSegment(e,r,e.position,false)}return true}function readBlockSequence(e,n){var r,s=e.tag,i=e.anchor,f=[],l,t=false,o;if(e.firstTabInLine!==-1)return false;if(e.anchor!==null){e.anchorMap[e.anchor]=f}o=e.input.charCodeAt(e.position);while(o!==0){if(e.firstTabInLine!==-1){e.position=e.firstTabInLine;throwError(e,"tab characters must not be used in indentation")}if(o!==45){break}l=e.input.charCodeAt(e.position+1);if(!is_WS_OR_EOL(l)){break}t=true;e.position++;if(skipSeparationSpace(e,true,-1)){if(e.lineIndent<=n){f.push(null);o=e.input.charCodeAt(e.position);continue}}r=e.line;composeNode(e,n,a,false,true);f.push(e.result);skipSeparationSpace(e,true,-1);o=e.input.charCodeAt(e.position);if((e.line===r||e.lineIndent>n)&&o!==0){throwError(e,"bad indentation of a sequence entry")}else if(e.lineIndent<n){break}}if(t){e.tag=s;e.anchor=i;e.kind="sequence";e.result=f;return true}return false}function readBlockMapping(e,n,r){var s,i,f,l,t,o,a=e.tag,p=e.anchor,u={},h=Object.create(null),v=null,g=null,b=null,w=false,y=false,m;if(e.firstTabInLine!==-1)return false;if(e.anchor!==null){e.anchorMap[e.anchor]=u}m=e.input.charCodeAt(e.position);while(m!==0){if(!w&&e.firstTabInLine!==-1){e.position=e.firstTabInLine;throwError(e,"tab characters must not be used in indentation")}s=e.input.charCodeAt(e.position+1);f=e.line;if((m===63||m===58)&&is_WS_OR_EOL(s)){if(m===63){if(w){storeMappingPair(e,u,h,v,g,null,l,t,o);v=g=b=null}y=true;w=true;i=true}else if(w){w=false;i=true}else{throwError(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line")}e.position+=1;m=s}else{l=e.line;t=e.lineStart;o=e.position;if(!composeNode(e,r,c,false,true)){break}if(e.line===f){m=e.input.charCodeAt(e.position);while(is_WHITE_SPACE(m)){m=e.input.charCodeAt(++e.position)}if(m===58){m=e.input.charCodeAt(++e.position);if(!is_WS_OR_EOL(m)){throwError(e,"a whitespace character is expected after the key-value separator within a block mapping")}if(w){storeMappingPair(e,u,h,v,g,null,l,t,o);v=g=b=null}y=true;w=false;i=false;v=e.tag;g=e.result}else if(y){throwError(e,"can not read an implicit mapping pair; a colon is missed")}else{e.tag=a;e.anchor=p;return true}}else if(y){throwError(e,"can not read a block mapping entry; a multiline key may not be an implicit key")}else{e.tag=a;e.anchor=p;return true}}if(e.line===f||e.lineIndent>n){if(w){l=e.line;t=e.lineStart;o=e.position}if(composeNode(e,n,d,true,i)){if(w){g=e.result}else{b=e.result}}if(!w){storeMappingPair(e,u,h,v,g,b,l,t,o);v=g=b=null}skipSeparationSpace(e,true,-1);m=e.input.charCodeAt(e.position)}if((e.line===f||e.lineIndent>n)&&m!==0){throwError(e,"bad indentation of a mapping entry")}else if(e.lineIndent<n){break}}if(w){storeMappingPair(e,u,h,v,g,null,l,t,o)}if(y){e.tag=a;e.anchor=p;e.kind="mapping";e.result=u}return y}function readTagProperty(e){var n,r=false,s=false,i,f,l;l=e.input.charCodeAt(e.position);if(l!==33)return false;if(e.tag!==null){throwError(e,"duplication of a tag property")}l=e.input.charCodeAt(++e.position);if(l===60){r=true;l=e.input.charCodeAt(++e.position)}else if(l===33){s=true;i="!!";l=e.input.charCodeAt(++e.position)}else{i="!"}n=e.position;if(r){do{l=e.input.charCodeAt(++e.position)}while(l!==0&&l!==62);if(e.position<e.length){f=e.input.slice(n,e.position);l=e.input.charCodeAt(++e.position)}else{throwError(e,"unexpected end of the stream within a verbatim tag")}}else{while(l!==0&&!is_WS_OR_EOL(l)){if(l===33){if(!s){i=e.input.slice(n-1,e.position+1);if(!w.test(i)){throwError(e,"named tag handle cannot contain such characters")}s=true;n=e.position+1}else{throwError(e,"tag suffix cannot contain exclamation marks")}}l=e.input.charCodeAt(++e.position)}f=e.input.slice(n,e.position);if(b.test(f)){throwError(e,"tag suffix cannot contain flow indicator characters")}}if(f&&!y.test(f)){throwError(e,"tag name cannot contain such characters: "+f)}try{f=decodeURIComponent(f)}catch(n){throwError(e,"tag name is malformed: "+f)}if(r){e.tag=f}else if(t.call(e.tagMap,i)){e.tag=e.tagMap[i]+f}else if(i==="!"){e.tag="!"+f}else if(i==="!!"){e.tag="tag:yaml.org,2002:"+f}else{throwError(e,'undeclared tag handle "'+i+'"')}return true}function readAnchorProperty(e){var n,r;r=e.input.charCodeAt(e.position);if(r!==38)return false;if(e.anchor!==null){throwError(e,"duplication of an anchor property")}r=e.input.charCodeAt(++e.position);n=e.position;while(r!==0&&!is_WS_OR_EOL(r)&&!is_FLOW_INDICATOR(r)){r=e.input.charCodeAt(++e.position)}if(e.position===n){throwError(e,"name of an anchor node must contain at least one character")}e.anchor=e.input.slice(n,e.position);return true}function readAlias(e){var n,r,s;s=e.input.charCodeAt(e.position);if(s!==42)return false;s=e.input.charCodeAt(++e.position);n=e.position;while(s!==0&&!is_WS_OR_EOL(s)&&!is_FLOW_INDICATOR(s)){s=e.input.charCodeAt(++e.position)}if(e.position===n){throwError(e,"name of an alias node must contain at least one character")}r=e.input.slice(n,e.position);if(!t.call(e.anchorMap,r)){throwError(e,'unidentified alias "'+r+'"')}e.result=e.anchorMap[r];skipSeparationSpace(e,true,-1);return true}function composeNode(e,n,r,s,i){var f,l,p,u=1,h=false,v=false,g,b,w,y,m,E;if(e.listener!==null){e.listener("open",e)}e.tag=null;e.anchor=null;e.kind=null;e.result=null;f=l=p=d===r||a===r;if(s){if(skipSeparationSpace(e,true,-1)){h=true;if(e.lineIndent>n){u=1}else if(e.lineIndent===n){u=0}else if(e.lineIndent<n){u=-1}}}if(u===1){while(readTagProperty(e)||readAnchorProperty(e)){if(skipSeparationSpace(e,true,-1)){h=true;p=f;if(e.lineIndent>n){u=1}else if(e.lineIndent===n){u=0}else if(e.lineIndent<n){u=-1}}else{p=false}}}if(p){p=h||i}if(u===1||d===r){if(o===r||c===r){m=n}else{m=n+1}E=e.position-e.lineStart;if(u===1){if(p&&(readBlockSequence(e,E)||readBlockMapping(e,E,m))||readFlowCollection(e,m)){v=true}else{if(l&&readBlockScalar(e,m)||readSingleQuotedScalar(e,m)||readDoubleQuotedScalar(e,m)){v=true}else if(readAlias(e)){v=true;if(e.tag!==null||e.anchor!==null){throwError(e,"alias node should not have any properties")}}else if(readPlainScalar(e,m,o===r)){v=true;if(e.tag===null){e.tag="?"}}if(e.anchor!==null){e.anchorMap[e.anchor]=e.result}}}else if(u===0){v=p&&readBlockSequence(e,E)}}if(e.tag===null){if(e.anchor!==null){e.anchorMap[e.anchor]=e.result}}else if(e.tag==="?"){if(e.result!==null&&e.kind!=="scalar"){throwError(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"')}for(g=0,b=e.implicitTypes.length;g<b;g+=1){y=e.implicitTypes[g];if(y.resolve(e.result)){e.result=y.construct(e.result);e.tag=y.tag;if(e.anchor!==null){e.anchorMap[e.anchor]=e.result}break}}}else if(e.tag!=="!"){if(t.call(e.typeMap[e.kind||"fallback"],e.tag)){y=e.typeMap[e.kind||"fallback"][e.tag]}else{y=null;w=e.typeMap.multi[e.kind||"fallback"];for(g=0,b=w.length;g<b;g+=1){if(e.tag.slice(0,w[g].tag.length)===w[g].tag){y=w[g];break}}}if(!y){throwError(e,"unknown tag !<"+e.tag+">")}if(e.result!==null&&y.kind!==e.kind){throwError(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+y.kind+'", not "'+e.kind+'"')}if(!y.resolve(e.result,e.tag)){throwError(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}else{e.result=y.construct(e.result,e.tag);if(e.anchor!==null){e.anchorMap[e.anchor]=e.result}}}if(e.listener!==null){e.listener("close",e)}return e.tag!==null||e.anchor!==null||v}function readDocument(e){var n=e.position,r,s,i,f=false,l;e.version=null;e.checkLineBreaks=e.legacy;e.tagMap=Object.create(null);e.anchorMap=Object.create(null);while((l=e.input.charCodeAt(e.position))!==0){skipSeparationSpace(e,true,-1);l=e.input.charCodeAt(e.position);if(e.lineIndent>0||l!==37){break}f=true;l=e.input.charCodeAt(++e.position);r=e.position;while(l!==0&&!is_WS_OR_EOL(l)){l=e.input.charCodeAt(++e.position)}s=e.input.slice(r,e.position);i=[];if(s.length<1){throwError(e,"directive name must not be less than one character in length")}while(l!==0){while(is_WHITE_SPACE(l)){l=e.input.charCodeAt(++e.position)}if(l===35){do{l=e.input.charCodeAt(++e.position)}while(l!==0&&!is_EOL(l));break}if(is_EOL(l))break;r=e.position;while(l!==0&&!is_WS_OR_EOL(l)){l=e.input.charCodeAt(++e.position)}i.push(e.input.slice(r,e.position))}if(l!==0)readLineBreak(e);if(t.call(C,s)){C[s](e,s,i)}else{throwWarning(e,'unknown document directive "'+s+'"')}}skipSeparationSpace(e,true,-1);if(e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45){e.position+=3;skipSeparationSpace(e,true,-1)}else if(f){throwError(e,"directives end mark is expected")}composeNode(e,e.lineIndent-1,d,false,true);skipSeparationSpace(e,true,-1);if(e.checkLineBreaks&&g.test(e.input.slice(n,e.position))){throwWarning(e,"non-ASCII line breaks are interpreted as content")}e.documents.push(e.result);if(e.position===e.lineStart&&testDocumentSeparator(e)){if(e.input.charCodeAt(e.position)===46){e.position+=3;skipSeparationSpace(e,true,-1)}return}if(e.position<e.length-1){throwError(e,"end of the stream or a document separator is expected")}else{return}}function loadDocuments(e,n){e=String(e);n=n||{};if(e.length!==0){if(e.charCodeAt(e.length-1)!==10&&e.charCodeAt(e.length-1)!==13){e+="\n"}if(e.charCodeAt(0)===65279){e=e.slice(1)}}var r=new State(e,n);var s=e.indexOf("\0");if(s!==-1){r.position=s;throwError(r,"null byte is not allowed in input")}r.input+="\0";while(r.input.charCodeAt(r.position)===32){r.lineIndent+=1;r.position+=1}while(r.position<r.length-1){readDocument(r)}return r.documents}function loadAll(e,n,r){if(n!==null&&typeof n==="object"&&typeof r==="undefined"){r=n;n=null}var s=loadDocuments(e,r);if(typeof n!=="function"){return s}for(var i=0,f=s.length;i<f;i+=1){n(s[i])}}function load(e,n){var r=loadDocuments(e,n);if(r.length===0){return undefined}else if(r.length===1){return r[0]}throw new i("expected a single document in the stream, but found more")}e.exports.loadAll=loadAll;e.exports.load=load},6435:(e,n,r)=>{"use strict";var s=r(6141);var i=r(7060);function compileList(e,n){var r=[];e[n].forEach(function(e){var n=r.length;r.forEach(function(r,s){if(r.tag===e.tag&&r.kind===e.kind&&r.multi===e.multi){n=s}});r[n]=e});return r}function compileMap(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},n,r;function collectType(n){if(n.multi){e.multi[n.kind].push(n);e.multi["fallback"].push(n)}else{e[n.kind][n.tag]=e["fallback"][n.tag]=n}}for(n=0,r=arguments.length;n<r;n+=1){arguments[n].forEach(collectType)}return e}function Schema(e){return this.extend(e)}Schema.prototype.extend=function extend(e){var n=[];var r=[];if(e instanceof i){r.push(e)}else if(Array.isArray(e)){r=r.concat(e)}else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit))){if(e.implicit)n=n.concat(e.implicit);if(e.explicit)r=r.concat(e.explicit)}else{throw new s("Schema.extend argument should be a Type, [ Type ], "+"or a schema definition ({ implicit: [...], explicit: [...] })")}n.forEach(function(e){if(!(e instanceof i)){throw new s("Specified list of YAML types (or a single Type object) contains a non-Type object.")}if(e.loadKind&&e.loadKind!=="scalar"){throw new s("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}if(e.multi){throw new s("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}});r.forEach(function(e){if(!(e instanceof i)){throw new s("Specified list of YAML types (or a single Type object) contains a non-Type object.")}});var f=Object.create(Schema.prototype);f.implicit=(this.implicit||[]).concat(n);f.explicit=(this.explicit||[]).concat(r);f.compiledImplicit=compileList(f,"implicit");f.compiledExplicit=compileList(f,"explicit");f.compiledTypeMap=compileMap(f.compiledImplicit,f.compiledExplicit);return f};e.exports=Schema},6670:(e,n,r)=>{"use strict";e.exports=r(6918)},3498:(e,n,r)=>{"use strict";e.exports=r(6670).extend({implicit:[r(3637),r(4789)],explicit:[r(2410),r(4189),r(8851),r(7282)]})},7947:(e,n,r)=>{"use strict";var s=r(6435);e.exports=new s({explicit:[r(1299),r(7331),r(5113)]})},6918:(e,n,r)=>{"use strict";e.exports=r(7947).extend({implicit:[r(5711),r(4719),r(436),r(3760)]})},163:(e,n,r)=>{"use strict";var s=r(130);function getLine(e,n,r,s,i){var f="";var l="";var t=Math.floor(i/2)-1;if(s-n>t){f=" ... ";n=s-t+f.length}if(r-s>t){l=" ...";r=s+t-l.length}return{str:f+e.slice(n,r).replace(/\t/g,"→")+l,pos:s-n+f.length}}function padStart(e,n){return s.repeat(" ",n-e.length)+e}function makeSnippet(e,n){n=Object.create(n||null);if(!e.buffer)return null;if(!n.maxLength)n.maxLength=79;if(typeof n.indent!=="number")n.indent=1;if(typeof n.linesBefore!=="number")n.linesBefore=3;if(typeof n.linesAfter!=="number")n.linesAfter=2;var r=/\r?\n|\r|\0/g;var i=[0];var f=[];var l;var t=-1;while(l=r.exec(e.buffer)){f.push(l.index);i.push(l.index+l[0].length);if(e.position<=l.index&&t<0){t=i.length-2}}if(t<0)t=i.length-1;var o="",c,a;var d=Math.min(e.line+n.linesAfter,f.length).toString().length;var p=n.maxLength-(n.indent+d+3);for(c=1;c<=n.linesBefore;c++){if(t-c<0)break;a=getLine(e.buffer,i[t-c],f[t-c],e.position-(i[t]-i[t-c]),p);o=s.repeat(" ",n.indent)+padStart((e.line-c+1).toString(),d)+" | "+a.str+"\n"+o}a=getLine(e.buffer,i[t],f[t],e.position,p);o+=s.repeat(" ",n.indent)+padStart((e.line+1).toString(),d)+" | "+a.str+"\n";o+=s.repeat("-",n.indent+d+3+a.pos)+"^"+"\n";for(c=1;c<=n.linesAfter;c++){if(t+c>=f.length)break;a=getLine(e.buffer,i[t+c],f[t+c],e.position-(i[t]-i[t+c]),p);o+=s.repeat(" ",n.indent)+padStart((e.line+c+1).toString(),d)+" | "+a.str+"\n"}return o.replace(/\n$/,"")}e.exports=makeSnippet},7060:(e,n,r)=>{"use strict";var s=r(6141);var i=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"];var f=["scalar","sequence","mapping"];function compileStyleAliases(e){var n={};if(e!==null){Object.keys(e).forEach(function(r){e[r].forEach(function(e){n[String(e)]=r})})}return n}function Type(e,n){n=n||{};Object.keys(n).forEach(function(n){if(i.indexOf(n)===-1){throw new s('Unknown option "'+n+'" is met in definition of "'+e+'" YAML type.')}});this.options=n;this.tag=e;this.kind=n["kind"]||null;this.resolve=n["resolve"]||function(){return true};this.construct=n["construct"]||function(e){return e};this.instanceOf=n["instanceOf"]||null;this.predicate=n["predicate"]||null;this.represent=n["represent"]||null;this.representName=n["representName"]||null;this.defaultStyle=n["defaultStyle"]||null;this.multi=n["multi"]||false;this.styleAliases=compileStyleAliases(n["styleAliases"]||null);if(f.indexOf(this.kind)===-1){throw new s('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}}e.exports=Type},2410:(e,n,r)=>{"use strict";var s=r(7060);var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r";function resolveYamlBinary(e){if(e===null)return false;var n,r,s=0,f=e.length,l=i;for(r=0;r<f;r++){n=l.indexOf(e.charAt(r));if(n>64)continue;if(n<0)return false;s+=6}return s%8===0}function constructYamlBinary(e){var n,r,s=e.replace(/[\r\n=]/g,""),f=s.length,l=i,t=0,o=[];for(n=0;n<f;n++){if(n%4===0&&n){o.push(t>>16&255);o.push(t>>8&255);o.push(t&255)}t=t<<6|l.indexOf(s.charAt(n))}r=f%4*6;if(r===0){o.push(t>>16&255);o.push(t>>8&255);o.push(t&255)}else if(r===18){o.push(t>>10&255);o.push(t>>2&255)}else if(r===12){o.push(t>>4&255)}return new Uint8Array(o)}function representYamlBinary(e){var n="",r=0,s,f,l=e.length,t=i;for(s=0;s<l;s++){if(s%3===0&&s){n+=t[r>>18&63];n+=t[r>>12&63];n+=t[r>>6&63];n+=t[r&63]}r=(r<<8)+e[s]}f=l%3;if(f===0){n+=t[r>>18&63];n+=t[r>>12&63];n+=t[r>>6&63];n+=t[r&63]}else if(f===2){n+=t[r>>10&63];n+=t[r>>4&63];n+=t[r<<2&63];n+=t[64]}else if(f===1){n+=t[r>>2&63];n+=t[r<<4&63];n+=t[64];n+=t[64]}return n}function isBinary(e){return Object.prototype.toString.call(e)==="[object Uint8Array]"}e.exports=new s("tag:yaml.org,2002:binary",{kind:"scalar",resolve:resolveYamlBinary,construct:constructYamlBinary,predicate:isBinary,represent:representYamlBinary})},4719:(e,n,r)=>{"use strict";var s=r(7060);function resolveYamlBoolean(e){if(e===null)return false;var n=e.length;return n===4&&(e==="true"||e==="True"||e==="TRUE")||n===5&&(e==="false"||e==="False"||e==="FALSE")}function constructYamlBoolean(e){return e==="true"||e==="True"||e==="TRUE"}function isBoolean(e){return Object.prototype.toString.call(e)==="[object Boolean]"}e.exports=new s("tag:yaml.org,2002:bool",{kind:"scalar",resolve:resolveYamlBoolean,construct:constructYamlBoolean,predicate:isBoolean,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"})},3760:(e,n,r)=>{"use strict";var s=r(130);var i=r(7060);var f=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?"+"|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?"+"|[-+]?\\.(?:inf|Inf|INF)"+"|\\.(?:nan|NaN|NAN))$");function resolveYamlFloat(e){if(e===null)return false;if(!f.test(e)||e[e.length-1]==="_"){return false}return true}function constructYamlFloat(e){var n,r;n=e.replace(/_/g,"").toLowerCase();r=n[0]==="-"?-1:1;if("+-".indexOf(n[0])>=0){n=n.slice(1)}if(n===".inf"){return r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY}else if(n===".nan"){return NaN}return r*parseFloat(n,10)}var l=/^[-+]?[0-9]+e/;function representYamlFloat(e,n){var r;if(isNaN(e)){switch(n){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}}else if(Number.POSITIVE_INFINITY===e){switch(n){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}}else if(Number.NEGATIVE_INFINITY===e){switch(n){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}}else if(s.isNegativeZero(e)){return"-0.0"}r=e.toString(10);return l.test(r)?r.replace("e",".e"):r}function isFloat(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||s.isNegativeZero(e))}e.exports=new i("tag:yaml.org,2002:float",{kind:"scalar",resolve:resolveYamlFloat,construct:constructYamlFloat,predicate:isFloat,represent:representYamlFloat,defaultStyle:"lowercase"})},436:(e,n,r)=>{"use strict";var s=r(130);var i=r(7060);function isHexCode(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function isOctCode(e){return 48<=e&&e<=55}function isDecCode(e){return 48<=e&&e<=57}function resolveYamlInteger(e){if(e===null)return false;var n=e.length,r=0,s=false,i;if(!n)return false;i=e[r];if(i==="-"||i==="+"){i=e[++r]}if(i==="0"){if(r+1===n)return true;i=e[++r];if(i==="b"){r++;for(;r<n;r++){i=e[r];if(i==="_")continue;if(i!=="0"&&i!=="1")return false;s=true}return s&&i!=="_"}if(i==="x"){r++;for(;r<n;r++){i=e[r];if(i==="_")continue;if(!isHexCode(e.charCodeAt(r)))return false;s=true}return s&&i!=="_"}if(i==="o"){r++;for(;r<n;r++){i=e[r];if(i==="_")continue;if(!isOctCode(e.charCodeAt(r)))return false;s=true}return s&&i!=="_"}}if(i==="_")return false;for(;r<n;r++){i=e[r];if(i==="_")continue;if(!isDecCode(e.charCodeAt(r))){return false}s=true}if(!s||i==="_")return false;return true}function constructYamlInteger(e){var n=e,r=1,s;if(n.indexOf("_")!==-1){n=n.replace(/_/g,"")}s=n[0];if(s==="-"||s==="+"){if(s==="-")r=-1;n=n.slice(1);s=n[0]}if(n==="0")return 0;if(s==="0"){if(n[1]==="b")return r*parseInt(n.slice(2),2);if(n[1]==="x")return r*parseInt(n.slice(2),16);if(n[1]==="o")return r*parseInt(n.slice(2),8)}return r*parseInt(n,10)}function isInteger(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1===0&&!s.isNegativeZero(e))}e.exports=new i("tag:yaml.org,2002:int",{kind:"scalar",resolve:resolveYamlInteger,construct:constructYamlInteger,predicate:isInteger,represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})},5113:(e,n,r)=>{"use strict";var s=r(7060);e.exports=new s("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}})},4789:(e,n,r)=>{"use strict";var s=r(7060);function resolveYamlMerge(e){return e==="<<"||e===null}e.exports=new s("tag:yaml.org,2002:merge",{kind:"scalar",resolve:resolveYamlMerge})},5711:(e,n,r)=>{"use strict";var s=r(7060);function resolveYamlNull(e){if(e===null)return true;var n=e.length;return n===1&&e==="~"||n===4&&(e==="null"||e==="Null"||e==="NULL")}function constructYamlNull(){return null}function isNull(e){return e===null}e.exports=new s("tag:yaml.org,2002:null",{kind:"scalar",resolve:resolveYamlNull,construct:constructYamlNull,predicate:isNull,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"})},4189:(e,n,r)=>{"use strict";var s=r(7060);var i=Object.prototype.hasOwnProperty;var f=Object.prototype.toString;function resolveYamlOmap(e){if(e===null)return true;var n=[],r,s,l,t,o,c=e;for(r=0,s=c.length;r<s;r+=1){l=c[r];o=false;if(f.call(l)!=="[object Object]")return false;for(t in l){if(i.call(l,t)){if(!o)o=true;else return false}}if(!o)return false;if(n.indexOf(t)===-1)n.push(t);else return false}return true}function constructYamlOmap(e){return e!==null?e:[]}e.exports=new s("tag:yaml.org,2002:omap",{kind:"sequence",resolve:resolveYamlOmap,construct:constructYamlOmap})},8851:(e,n,r)=>{"use strict";var s=r(7060);var i=Object.prototype.toString;function resolveYamlPairs(e){if(e===null)return true;var n,r,s,f,l,t=e;l=new Array(t.length);for(n=0,r=t.length;n<r;n+=1){s=t[n];if(i.call(s)!=="[object Object]")return false;f=Object.keys(s);if(f.length!==1)return false;l[n]=[f[0],s[f[0]]]}return true}function constructYamlPairs(e){if(e===null)return[];var n,r,s,i,f,l=e;f=new Array(l.length);for(n=0,r=l.length;n<r;n+=1){s=l[n];i=Object.keys(s);f[n]=[i[0],s[i[0]]]}return f}e.exports=new s("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:resolveYamlPairs,construct:constructYamlPairs})},7331:(e,n,r)=>{"use strict";var s=r(7060);e.exports=new s("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}})},7282:(e,n,r)=>{"use strict";var s=r(7060);var i=Object.prototype.hasOwnProperty;function resolveYamlSet(e){if(e===null)return true;var n,r=e;for(n in r){if(i.call(r,n)){if(r[n]!==null)return false}}return true}function constructYamlSet(e){return e!==null?e:{}}e.exports=new s("tag:yaml.org,2002:set",{kind:"mapping",resolve:resolveYamlSet,construct:constructYamlSet})},1299:(e,n,r)=>{"use strict";var s=r(7060);e.exports=new s("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}})},3637:(e,n,r)=>{"use strict";var s=r(7060);var i=new RegExp("^([0-9][0-9][0-9][0-9])"+"-([0-9][0-9])"+"-([0-9][0-9])$");var f=new RegExp("^([0-9][0-9][0-9][0-9])"+"-([0-9][0-9]?)"+"-([0-9][0-9]?)"+"(?:[Tt]|[ \\t]+)"+"([0-9][0-9]?)"+":([0-9][0-9])"+":([0-9][0-9])"+"(?:\\.([0-9]*))?"+"(?:[ \\t]*(Z|([-+])([0-9][0-9]?)"+"(?::([0-9][0-9]))?))?$");function resolveYamlTimestamp(e){if(e===null)return false;if(i.exec(e)!==null)return true;if(f.exec(e)!==null)return true;return false}function constructYamlTimestamp(e){var n,r,s,l,t,o,c,a=0,d=null,p,u,h;n=i.exec(e);if(n===null)n=f.exec(e);if(n===null)throw new Error("Date resolve error");r=+n[1];s=+n[2]-1;l=+n[3];if(!n[4]){return new Date(Date.UTC(r,s,l))}t=+n[4];o=+n[5];c=+n[6];if(n[7]){a=n[7].slice(0,3);while(a.length<3){a+="0"}a=+a}if(n[9]){p=+n[10];u=+(n[11]||0);d=(p*60+u)*6e4;if(n[9]==="-")d=-d}h=new Date(Date.UTC(r,s,l,t,o,c,a));if(d)h.setTime(h.getTime()-d);return h}function representYamlTimestamp(e){return e.toISOString()}e.exports=new s("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:resolveYamlTimestamp,construct:constructYamlTimestamp,instanceOf:Date,represent:representYamlTimestamp})},7438:e=>{"use strict";var n=e.exports=function(e,n,r){if(typeof n=="function"){r=n;n={}}r=n.cb||r;var s=typeof r=="function"?r:r.pre||function(){};var i=r.post||function(){};_traverse(n,s,i,e,"",e)};n.keywords={additionalItems:true,items:true,contains:true,additionalProperties:true,propertyNames:true,not:true};n.arrayKeywords={items:true,allOf:true,anyOf:true,oneOf:true};n.propsKeywords={definitions:true,properties:true,patternProperties:true,dependencies:true};n.skipKeywords={default:true,enum:true,const:true,required:true,maximum:true,minimum:true,exclusiveMaximum:true,exclusiveMinimum:true,multipleOf:true,maxLength:true,minLength:true,pattern:true,format:true,maxItems:true,minItems:true,uniqueItems:true,maxProperties:true,minProperties:true};function _traverse(e,r,s,i,f,l,t,o,c,a){if(i&&typeof i=="object"&&!Array.isArray(i)){r(i,f,l,t,o,c,a);for(var d in i){var p=i[d];if(Array.isArray(p)){if(d in n.arrayKeywords){for(var u=0;u<p.length;u++)_traverse(e,r,s,p[u],f+"/"+d+"/"+u,l,f,d,i,u)}}else if(d in n.propsKeywords){if(p&&typeof p=="object"){for(var h in p)_traverse(e,r,s,p[h],f+"/"+d+"/"+escapeJsonPtr(h),l,f,d,i,h)}}else if(d in n.keywords||e.allKeys&&!(d in n.skipKeywords)){_traverse(e,r,s,p,f+"/"+d,l,f,d,i)}}s(i,f,l,t,o,c,a)}}function escapeJsonPtr(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}},9297:(e,n)=>{n=e.exports=stringify;n.getSerialize=serializer;function stringify(e,n,r,s){return JSON.stringify(e,serializer(n,s),r)}function serializer(e,n){var r=[],s=[];if(n==null)n=function(e,n){if(r[0]===n)return"[Circular ~]";return"[Circular ~."+s.slice(0,r.indexOf(n)).join(".")+"]"};return function(i,f){if(r.length>0){var l=r.indexOf(this);~l?r.splice(l+1):r.push(this);~l?s.splice(l,Infinity,i):s.push(i);if(~r.indexOf(f))f=n.call(this,i,f)}else r.push(f);return e==null?f:e.call(this,i,f)}}},5221:(e,n,r)=>{let s;try{s=r(4742)}catch(e){s=r(5747)}const i=r(8522);const{stringify:f,stripBom:l}=r(1266);async function _readFile(e,n={}){if(typeof n==="string"){n={encoding:n}}const r=n.fs||s;const f="throws"in n?n.throws:true;let t=await i.fromCallback(r.readFile)(e,n);t=l(t);let o;try{o=JSON.parse(t,n?n.reviver:null)}catch(n){if(f){n.message=`${e}: ${n.message}`;throw n}else{return null}}return o}const t=i.fromPromise(_readFile);function readFileSync(e,n={}){if(typeof n==="string"){n={encoding:n}}const r=n.fs||s;const i="throws"in n?n.throws:true;try{let s=r.readFileSync(e,n);s=l(s);return JSON.parse(s,n.reviver)}catch(n){if(i){n.message=`${e}: ${n.message}`;throw n}else{return null}}}async function _writeFile(e,n,r={}){const l=r.fs||s;const t=f(n,r);await i.fromCallback(l.writeFile)(e,t,r)}const o=i.fromPromise(_writeFile);function writeFileSync(e,n,r={}){const i=r.fs||s;const l=f(n,r);return i.writeFileSync(e,l,r)}const c={readFile:t,readFileSync:readFileSync,writeFile:o,writeFileSync:writeFileSync};e.exports=c},1266:e=>{function stringify(e,{EOL:n="\n",finalEOL:r=true,replacer:s=null,spaces:i}={}){const f=r?n:"";const l=JSON.stringify(e,s,i);return l.replace(/\n/g,n)+f}function stripBom(e){if(Buffer.isBuffer(e))e=e.toString("utf8");return e.replace(/^\uFEFF/,"")}e.exports={stringify:stringify,stripBom:stripBom}},7140:(e,n,r)=>{"use strict";const s=r(7572);const i=Symbol("max");const f=Symbol("length");const l=Symbol("lengthCalculator");const t=Symbol("allowStale");const o=Symbol("maxAge");const c=Symbol("dispose");const a=Symbol("noDisposeOnSet");const d=Symbol("lruList");const p=Symbol("cache");const u=Symbol("updateAgeOnGet");const h=()=>1;class LRUCache{constructor(e){if(typeof e==="number")e={max:e};if(!e)e={};if(e.max&&(typeof e.max!=="number"||e.max<0))throw new TypeError("max must be a non-negative number");const n=this[i]=e.max||Infinity;const r=e.length||h;this[l]=typeof r!=="function"?h:r;this[t]=e.stale||false;if(e.maxAge&&typeof e.maxAge!=="number")throw new TypeError("maxAge must be a number");this[o]=e.maxAge||0;this[c]=e.dispose;this[a]=e.noDisposeOnSet||false;this[u]=e.updateAgeOnGet||false;this.reset()}set max(e){if(typeof e!=="number"||e<0)throw new TypeError("max must be a non-negative number");this[i]=e||Infinity;b(this)}get max(){return this[i]}set allowStale(e){this[t]=!!e}get allowStale(){return this[t]}set maxAge(e){if(typeof e!=="number")throw new TypeError("maxAge must be a non-negative number");this[o]=e;b(this)}get maxAge(){return this[o]}set lengthCalculator(e){if(typeof e!=="function")e=h;if(e!==this[l]){this[l]=e;this[f]=0;this[d].forEach(e=>{e.length=this[l](e.value,e.key);this[f]+=e.length})}b(this)}get lengthCalculator(){return this[l]}get length(){return this[f]}get itemCount(){return this[d].length}rforEach(e,n){n=n||this;for(let r=this[d].tail;r!==null;){const s=r.prev;y(this,e,r,n);r=s}}forEach(e,n){n=n||this;for(let r=this[d].head;r!==null;){const s=r.next;y(this,e,r,n);r=s}}keys(){return this[d].toArray().map(e=>e.key)}values(){return this[d].toArray().map(e=>e.value)}reset(){if(this[c]&&this[d]&&this[d].length){this[d].forEach(e=>this[c](e.key,e.value))}this[p]=new Map;this[d]=new s;this[f]=0}dump(){return this[d].map(e=>g(this,e)?false:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[d]}set(e,n,r){r=r||this[o];if(r&&typeof r!=="number")throw new TypeError("maxAge must be a number");const s=r?Date.now():0;const t=this[l](n,e);if(this[p].has(e)){if(t>this[i]){w(this,this[p].get(e));return false}const l=this[p].get(e);const o=l.value;if(this[c]){if(!this[a])this[c](e,o.value)}o.now=s;o.maxAge=r;o.value=n;this[f]+=t-o.length;o.length=t;this.get(e);b(this);return true}const u=new Entry(e,n,t,s,r);if(u.length>this[i]){if(this[c])this[c](e,n);return false}this[f]+=u.length;this[d].unshift(u);this[p].set(e,this[d].head);b(this);return true}has(e){if(!this[p].has(e))return false;const n=this[p].get(e).value;return!g(this,n)}get(e){return v(this,e,true)}peek(e){return v(this,e,false)}pop(){const e=this[d].tail;if(!e)return null;w(this,e);return e.value}del(e){w(this,this[p].get(e))}load(e){this.reset();const n=Date.now();for(let r=e.length-1;r>=0;r--){const s=e[r];const i=s.e||0;if(i===0)this.set(s.k,s.v);else{const e=i-n;if(e>0){this.set(s.k,s.v,e)}}}}prune(){this[p].forEach((e,n)=>v(this,n,false))}}const v=(e,n,r)=>{const s=e[p].get(n);if(s){const n=s.value;if(g(e,n)){w(e,s);if(!e[t])return undefined}else{if(r){if(e[u])s.value.now=Date.now();e[d].unshiftNode(s)}}return n.value}};const g=(e,n)=>{if(!n||!n.maxAge&&!e[o])return false;const r=Date.now()-n.now;return n.maxAge?r>n.maxAge:e[o]&&r>e[o]};const b=e=>{if(e[f]>e[i]){for(let n=e[d].tail;e[f]>e[i]&&n!==null;){const r=n.prev;w(e,n);n=r}}};const w=(e,n)=>{if(n){const r=n.value;if(e[c])e[c](r.key,r.value);e[f]-=r.length;e[p].delete(r.key);e[d].removeNode(n)}};class Entry{constructor(e,n,r,s,i){this.key=e;this.value=n;this.length=r;this.now=s;this.maxAge=i||0}}const y=(e,n,r,s)=>{let i=r.value;if(g(e,i)){w(e,r);if(!e[t])i=undefined}if(i)n.call(s,i.value,i.key,e)};e.exports=LRUCache},892:e=>{var n=1e3;var r=n*60;var s=r*60;var i=s*24;var f=i*7;var l=i*365.25;e.exports=function(e,n){n=n||{};var r=typeof e;if(r==="string"&&e.length>0){return parse(e)}else if(r==="number"&&isFinite(e)){return n.long?fmtLong(e):fmtShort(e)}throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function parse(e){e=String(e);if(e.length>100){return}var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t){return}var o=parseFloat(t[1]);var c=(t[2]||"ms").toLowerCase();switch(c){case"years":case"year":case"yrs":case"yr":case"y":return o*l;case"weeks":case"week":case"w":return o*f;case"days":case"day":case"d":return o*i;case"hours":case"hour":case"hrs":case"hr":case"h":return o*s;case"minutes":case"minute":case"mins":case"min":case"m":return o*r;case"seconds":case"second":case"secs":case"sec":case"s":return o*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return o;default:return undefined}}function fmtShort(e){var f=Math.abs(e);if(f>=i){return Math.round(e/i)+"d"}if(f>=s){return Math.round(e/s)+"h"}if(f>=r){return Math.round(e/r)+"m"}if(f>=n){return Math.round(e/n)+"s"}return e+"ms"}function fmtLong(e){var f=Math.abs(e);if(f>=i){return plural(e,f,i,"day")}if(f>=s){return plural(e,f,s,"hour")}if(f>=r){return plural(e,f,r,"minute")}if(f>=n){return plural(e,f,n,"second")}return e+" ms"}function plural(e,n,r,s){var i=n>=r*1.5;return Math.round(e/r)+" "+s+(i?"s":"")}},9474:e=>{var n=1e3;var r=n*60;var s=r*60;var i=s*24;var f=i*7;var l=i*365.25;e.exports=function(e,n){n=n||{};var r=typeof e;if(r==="string"&&e.length>0){return parse(e)}else if(r==="number"&&isFinite(e)){return n.long?fmtLong(e):fmtShort(e)}throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function parse(e){e=String(e);if(e.length>100){return}var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t){return}var o=parseFloat(t[1]);var c=(t[2]||"ms").toLowerCase();switch(c){case"years":case"year":case"yrs":case"yr":case"y":return o*l;case"weeks":case"week":case"w":return o*f;case"days":case"day":case"d":return o*i;case"hours":case"hour":case"hrs":case"hr":case"h":return o*s;case"minutes":case"minute":case"mins":case"min":case"m":return o*r;case"seconds":case"second":case"secs":case"sec":case"s":return o*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return o;default:return undefined}}function fmtShort(e){var f=Math.abs(e);if(f>=i){return Math.round(e/i)+"d"}if(f>=s){return Math.round(e/s)+"h"}if(f>=r){return Math.round(e/r)+"m"}if(f>=n){return Math.round(e/n)+"s"}return e+"ms"}function fmtLong(e){var f=Math.abs(e);if(f>=i){return plural(e,f,i,"day")}if(f>=s){return plural(e,f,s,"hour")}if(f>=r){return plural(e,f,r,"minute")}if(f>=n){return plural(e,f,n,"second")}return e+" ms"}function plural(e,n,r,s){var i=n>=r*1.5;return Math.round(e/r)+" "+s+(i?"s":"")}},3290:(e,n,r)=>{const s=r(5585);const i=r(5844);const{EOL:f}=r(2087);const l=r(9297);e.exports.stringify=(e=>s.obj(e,(e,n,r)=>{r(null,l(e)+f)}));e.exports.parse=(e=>{e=e||{};e.strict=e.strict!==false;function parseRow(n){try{if(n)return JSON.parse(n)}catch(r){if(e.strict){this.emit("error",new Error("Could not parse row "+n.slice(0,50)+"..."))}}}return i(parseRow,e)})},7795:e=>{"use strict";e.exports=function(e){if(typeof e!=="string"){throw new Error("expected a string")}return e.split("\n").map(user).filter(Boolean)};function user(e,n){if(!e||!e.length||e.charAt(0)==="#"){return null}var r=e.split(":");return{username:r[0],password:r[1],uid:r[2],gid:r[3],gecos:r[4],homedir:r[5],shell:r[6]}}},5484:e=>{"use strict";const n={};function createErrorType(e,r,s){if(!s){s=Error}function getMessage(e,n,s){if(typeof r==="string"){return r}else{return r(e,n,s)}}class NodeError extends s{constructor(e,n,r){super(getMessage(e,n,r))}}NodeError.prototype.name=s.name;NodeError.prototype.code=e;n[e]=NodeError}function oneOf(e,n){if(Array.isArray(e)){const r=e.length;e=e.map(e=>String(e));if(r>2){return`one of ${n} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]}else if(r===2){return`one of ${n} ${e[0]} or ${e[1]}`}else{return`of ${n} ${e[0]}`}}else{return`of ${n} ${String(e)}`}}function startsWith(e,n,r){return e.substr(!r||r<0?0:+r,n.length)===n}function endsWith(e,n,r){if(r===undefined||r>e.length){r=e.length}return e.substring(r-n.length,r)===n}function includes(e,n,r){if(typeof r!=="number"){r=0}if(r+n.length>e.length){return false}else{return e.indexOf(n,r)!==-1}}createErrorType("ERR_INVALID_OPT_VALUE",function(e,n){return'The value "'+n+'" is invalid for option "'+e+'"'},TypeError);createErrorType("ERR_INVALID_ARG_TYPE",function(e,n,r){let s;if(typeof n==="string"&&startsWith(n,"not ")){s="must not be";n=n.replace(/^not /,"")}else{s="must be"}let i;if(endsWith(e," argument")){i=`The ${e} ${s} ${oneOf(n,"type")}`}else{const r=includes(e,".")?"property":"argument";i=`The "${e}" ${r} ${s} ${oneOf(n,"type")}`}i+=`. Received type ${typeof r}`;return i},TypeError);createErrorType("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");createErrorType("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"});createErrorType("ERR_STREAM_PREMATURE_CLOSE","Premature close");createErrorType("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"});createErrorType("ERR_MULTIPLE_CALLBACK","Callback called multiple times");createErrorType("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end");createErrorType("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);createErrorType("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError);createErrorType("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");e.exports.q=n},6238:(e,n,r)=>{"use strict";var s=Object.keys||function(e){var n=[];for(var r in e){n.push(r)}return n};e.exports=Duplex;var i=r(7790);var f=r(8376);r(3655)(Duplex,i);{var l=s(f.prototype);for(var t=0;t<l.length;t++){var o=l[t];if(!Duplex.prototype[o])Duplex.prototype[o]=f.prototype[o]}}function Duplex(e){if(!(this instanceof Duplex))return new Duplex(e);i.call(this,e);f.call(this,e);this.allowHalfOpen=true;if(e){if(e.readable===false)this.readable=false;if(e.writable===false)this.writable=false;if(e.allowHalfOpen===false){this.allowHalfOpen=false;this.once("end",onend)}}}Object.defineProperty(Duplex.prototype,"writableHighWaterMark",{enumerable:false,get:function get(){return this._writableState.highWaterMark}});Object.defineProperty(Duplex.prototype,"writableBuffer",{enumerable:false,get:function get(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(Duplex.prototype,"writableLength",{enumerable:false,get:function get(){return this._writableState.length}});function onend(){if(this._writableState.ended)return;process.nextTick(onEndNT,this)}function onEndNT(e){e.end()}Object.defineProperty(Duplex.prototype,"destroyed",{enumerable:false,get:function get(){if(this._readableState===undefined||this._writableState===undefined){return false}return this._readableState.destroyed&&this._writableState.destroyed},set:function set(e){if(this._readableState===undefined||this._writableState===undefined){return}this._readableState.destroyed=e;this._writableState.destroyed=e}})},1650:(e,n,r)=>{"use strict";e.exports=PassThrough;var s=r(1784);r(3655)(PassThrough,s);function PassThrough(e){if(!(this instanceof PassThrough))return new PassThrough(e);s.call(this,e)}PassThrough.prototype._transform=function(e,n,r){r(null,e)}},7790:(e,n,r)=>{"use strict";e.exports=Readable;var s;Readable.ReadableState=ReadableState;var i=r(8614).EventEmitter;var f=function EElistenerCount(e,n){return e.listeners(n).length};var l=r(4194);var t=r(4293).Buffer;var o=global.Uint8Array||function(){};function _uint8ArrayToBuffer(e){return t.from(e)}function _isUint8Array(e){return t.isBuffer(e)||e instanceof o}var c=r(1669);var a;if(c&&c.debuglog){a=c.debuglog("stream")}else{a=function debug(){}}var d=r(8994);var p=r(8608);var u=r(9971),h=u.getHighWaterMark;var v=r(5484).q,g=v.ERR_INVALID_ARG_TYPE,b=v.ERR_STREAM_PUSH_AFTER_EOF,w=v.ERR_METHOD_NOT_IMPLEMENTED,y=v.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;var m;var E;var S;r(3655)(Readable,l);var C=p.errorOrDestroy;var O=["error","close","destroy","pause","resume"];function prependListener(e,n,r){if(typeof e.prependListener==="function")return e.prependListener(n,r);if(!e._events||!e._events[n])e.on(n,r);else if(Array.isArray(e._events[n]))e._events[n].unshift(r);else e._events[n]=[r,e._events[n]]}function ReadableState(e,n,i){s=s||r(6238);e=e||{};if(typeof i!=="boolean")i=n instanceof s;this.objectMode=!!e.objectMode;if(i)this.objectMode=this.objectMode||!!e.readableObjectMode;this.highWaterMark=h(this,e,"readableHighWaterMark",i);this.buffer=new d;this.length=0;this.pipes=null;this.pipesCount=0;this.flowing=null;this.ended=false;this.endEmitted=false;this.reading=false;this.sync=true;this.needReadable=false;this.emittedReadable=false;this.readableListening=false;this.resumeScheduled=false;this.paused=true;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.destroyed=false;this.defaultEncoding=e.defaultEncoding||"utf8";this.awaitDrain=0;this.readingMore=false;this.decoder=null;this.encoding=null;if(e.encoding){if(!m)m=r(6745).s;this.decoder=new m(e.encoding);this.encoding=e.encoding}}function Readable(e){s=s||r(6238);if(!(this instanceof Readable))return new Readable(e);var n=this instanceof s;this._readableState=new ReadableState(e,this,n);this.readable=true;if(e){if(typeof e.read==="function")this._read=e.read;if(typeof e.destroy==="function")this._destroy=e.destroy}l.call(this)}Object.defineProperty(Readable.prototype,"destroyed",{enumerable:false,get:function get(){if(this._readableState===undefined){return false}return this._readableState.destroyed},set:function set(e){if(!this._readableState){return}this._readableState.destroyed=e}});Readable.prototype.destroy=p.destroy;Readable.prototype._undestroy=p.undestroy;Readable.prototype._destroy=function(e,n){n(e)};Readable.prototype.push=function(e,n){var r=this._readableState;var s;if(!r.objectMode){if(typeof e==="string"){n=n||r.defaultEncoding;if(n!==r.encoding){e=t.from(e,n);n=""}s=true}}else{s=true}return readableAddChunk(this,e,n,false,s)};Readable.prototype.unshift=function(e){return readableAddChunk(this,e,null,true,false)};function readableAddChunk(e,n,r,s,i){a("readableAddChunk",n);var f=e._readableState;if(n===null){f.reading=false;onEofChunk(e,f)}else{var l;if(!i)l=chunkInvalid(f,n);if(l){C(e,l)}else if(f.objectMode||n&&n.length>0){if(typeof n!=="string"&&!f.objectMode&&Object.getPrototypeOf(n)!==t.prototype){n=_uint8ArrayToBuffer(n)}if(s){if(f.endEmitted)C(e,new y);else addChunk(e,f,n,true)}else if(f.ended){C(e,new b)}else if(f.destroyed){return false}else{f.reading=false;if(f.decoder&&!r){n=f.decoder.write(n);if(f.objectMode||n.length!==0)addChunk(e,f,n,false);else maybeReadMore(e,f)}else{addChunk(e,f,n,false)}}}else if(!s){f.reading=false;maybeReadMore(e,f)}}return!f.ended&&(f.length<f.highWaterMark||f.length===0)}function addChunk(e,n,r,s){if(n.flowing&&n.length===0&&!n.sync){n.awaitDrain=0;e.emit("data",r)}else{n.length+=n.objectMode?1:r.length;if(s)n.buffer.unshift(r);else n.buffer.push(r);if(n.needReadable)emitReadable(e)}maybeReadMore(e,n)}function chunkInvalid(e,n){var r;if(!_isUint8Array(n)&&typeof n!=="string"&&n!==undefined&&!e.objectMode){r=new g("chunk",["string","Buffer","Uint8Array"],n)}return r}Readable.prototype.isPaused=function(){return this._readableState.flowing===false};Readable.prototype.setEncoding=function(e){if(!m)m=r(6745).s;var n=new m(e);this._readableState.decoder=n;this._readableState.encoding=this._readableState.decoder.encoding;var s=this._readableState.buffer.head;var i="";while(s!==null){i+=n.write(s.data);s=s.next}this._readableState.buffer.clear();if(i!=="")this._readableState.buffer.push(i);this._readableState.length=i.length;return this};var A=1073741824;function computeNewHighWaterMark(e){if(e>=A){e=A}else{e--;e|=e>>>1;e|=e>>>2;e|=e>>>4;e|=e>>>8;e|=e>>>16;e++}return e}function howMuchToRead(e,n){if(e<=0||n.length===0&&n.ended)return 0;if(n.objectMode)return 1;if(e!==e){if(n.flowing&&n.length)return n.buffer.head.data.length;else return n.length}if(e>n.highWaterMark)n.highWaterMark=computeNewHighWaterMark(e);if(e<=n.length)return e;if(!n.ended){n.needReadable=true;return 0}return n.length}Readable.prototype.read=function(e){a("read",e);e=parseInt(e,10);var n=this._readableState;var r=e;if(e!==0)n.emittedReadable=false;if(e===0&&n.needReadable&&((n.highWaterMark!==0?n.length>=n.highWaterMark:n.length>0)||n.ended)){a("read: emitReadable",n.length,n.ended);if(n.length===0&&n.ended)endReadable(this);else emitReadable(this);return null}e=howMuchToRead(e,n);if(e===0&&n.ended){if(n.length===0)endReadable(this);return null}var s=n.needReadable;a("need readable",s);if(n.length===0||n.length-e<n.highWaterMark){s=true;a("length less than watermark",s)}if(n.ended||n.reading){s=false;a("reading or ended",s)}else if(s){a("do read");n.reading=true;n.sync=true;if(n.length===0)n.needReadable=true;this._read(n.highWaterMark);n.sync=false;if(!n.reading)e=howMuchToRead(r,n)}var i;if(e>0)i=fromList(e,n);else i=null;if(i===null){n.needReadable=n.length<=n.highWaterMark;e=0}else{n.length-=e;n.awaitDrain=0}if(n.length===0){if(!n.ended)n.needReadable=true;if(r!==e&&n.ended)endReadable(this)}if(i!==null)this.emit("data",i);return i};function onEofChunk(e,n){a("onEofChunk");if(n.ended)return;if(n.decoder){var r=n.decoder.end();if(r&&r.length){n.buffer.push(r);n.length+=n.objectMode?1:r.length}}n.ended=true;if(n.sync){emitReadable(e)}else{n.needReadable=false;if(!n.emittedReadable){n.emittedReadable=true;emitReadable_(e)}}}function emitReadable(e){var n=e._readableState;a("emitReadable",n.needReadable,n.emittedReadable);n.needReadable=false;if(!n.emittedReadable){a("emitReadable",n.flowing);n.emittedReadable=true;process.nextTick(emitReadable_,e)}}function emitReadable_(e){var n=e._readableState;a("emitReadable_",n.destroyed,n.length,n.ended);if(!n.destroyed&&(n.length||n.ended)){e.emit("readable");n.emittedReadable=false}n.needReadable=!n.flowing&&!n.ended&&n.length<=n.highWaterMark;flow(e)}function maybeReadMore(e,n){if(!n.readingMore){n.readingMore=true;process.nextTick(maybeReadMore_,e,n)}}function maybeReadMore_(e,n){while(!n.reading&&!n.ended&&(n.length<n.highWaterMark||n.flowing&&n.length===0)){var r=n.length;a("maybeReadMore read 0");e.read(0);if(r===n.length)break}n.readingMore=false}Readable.prototype._read=function(e){C(this,new w("_read()"))};Readable.prototype.pipe=function(e,n){var r=this;var s=this._readableState;switch(s.pipesCount){case 0:s.pipes=e;break;case 1:s.pipes=[s.pipes,e];break;default:s.pipes.push(e);break}s.pipesCount+=1;a("pipe count=%d opts=%j",s.pipesCount,n);var i=(!n||n.end!==false)&&e!==process.stdout&&e!==process.stderr;var l=i?onend:unpipe;if(s.endEmitted)process.nextTick(l);else r.once("end",l);e.on("unpipe",onunpipe);function onunpipe(e,n){a("onunpipe");if(e===r){if(n&&n.hasUnpiped===false){n.hasUnpiped=true;cleanup()}}}function onend(){a("onend");e.end()}var t=pipeOnDrain(r);e.on("drain",t);var o=false;function cleanup(){a("cleanup");e.removeListener("close",onclose);e.removeListener("finish",onfinish);e.removeListener("drain",t);e.removeListener("error",onerror);e.removeListener("unpipe",onunpipe);r.removeListener("end",onend);r.removeListener("end",unpipe);r.removeListener("data",ondata);o=true;if(s.awaitDrain&&(!e._writableState||e._writableState.needDrain))t()}r.on("data",ondata);function ondata(n){a("ondata");var i=e.write(n);a("dest.write",i);if(i===false){if((s.pipesCount===1&&s.pipes===e||s.pipesCount>1&&indexOf(s.pipes,e)!==-1)&&!o){a("false write response, pause",s.awaitDrain);s.awaitDrain++}r.pause()}}function onerror(n){a("onerror",n);unpipe();e.removeListener("error",onerror);if(f(e,"error")===0)C(e,n)}prependListener(e,"error",onerror);function onclose(){e.removeListener("finish",onfinish);unpipe()}e.once("close",onclose);function onfinish(){a("onfinish");e.removeListener("close",onclose);unpipe()}e.once("finish",onfinish);function unpipe(){a("unpipe");r.unpipe(e)}e.emit("pipe",r);if(!s.flowing){a("pipe resume");r.resume()}return e};function pipeOnDrain(e){return function pipeOnDrainFunctionResult(){var n=e._readableState;a("pipeOnDrain",n.awaitDrain);if(n.awaitDrain)n.awaitDrain--;if(n.awaitDrain===0&&f(e,"data")){n.flowing=true;flow(e)}}}Readable.prototype.unpipe=function(e){var n=this._readableState;var r={hasUnpiped:false};if(n.pipesCount===0)return this;if(n.pipesCount===1){if(e&&e!==n.pipes)return this;if(!e)e=n.pipes;n.pipes=null;n.pipesCount=0;n.flowing=false;if(e)e.emit("unpipe",this,r);return this}if(!e){var s=n.pipes;var i=n.pipesCount;n.pipes=null;n.pipesCount=0;n.flowing=false;for(var f=0;f<i;f++){s[f].emit("unpipe",this,{hasUnpiped:false})}return this}var l=indexOf(n.pipes,e);if(l===-1)return this;n.pipes.splice(l,1);n.pipesCount-=1;if(n.pipesCount===1)n.pipes=n.pipes[0];e.emit("unpipe",this,r);return this};Readable.prototype.on=function(e,n){var r=l.prototype.on.call(this,e,n);var s=this._readableState;if(e==="data"){s.readableListening=this.listenerCount("readable")>0;if(s.flowing!==false)this.resume()}else if(e==="readable"){if(!s.endEmitted&&!s.readableListening){s.readableListening=s.needReadable=true;s.flowing=false;s.emittedReadable=false;a("on readable",s.length,s.reading);if(s.length){emitReadable(this)}else if(!s.reading){process.nextTick(nReadingNextTick,this)}}}return r};Readable.prototype.addListener=Readable.prototype.on;Readable.prototype.removeListener=function(e,n){var r=l.prototype.removeListener.call(this,e,n);if(e==="readable"){process.nextTick(updateReadableListening,this)}return r};Readable.prototype.removeAllListeners=function(e){var n=l.prototype.removeAllListeners.apply(this,arguments);if(e==="readable"||e===undefined){process.nextTick(updateReadableListening,this)}return n};function updateReadableListening(e){var n=e._readableState;n.readableListening=e.listenerCount("readable")>0;if(n.resumeScheduled&&!n.paused){n.flowing=true}else if(e.listenerCount("data")>0){e.resume()}}function nReadingNextTick(e){a("readable nexttick read 0");e.read(0)}Readable.prototype.resume=function(){var e=this._readableState;if(!e.flowing){a("resume");e.flowing=!e.readableListening;resume(this,e)}e.paused=false;return this};function resume(e,n){if(!n.resumeScheduled){n.resumeScheduled=true;process.nextTick(resume_,e,n)}}function resume_(e,n){a("resume",n.reading);if(!n.reading){e.read(0)}n.resumeScheduled=false;e.emit("resume");flow(e);if(n.flowing&&!n.reading)e.read(0)}Readable.prototype.pause=function(){a("call pause flowing=%j",this._readableState.flowing);if(this._readableState.flowing!==false){a("pause");this._readableState.flowing=false;this.emit("pause")}this._readableState.paused=true;return this};function flow(e){var n=e._readableState;a("flow",n.flowing);while(n.flowing&&e.read()!==null){}}Readable.prototype.wrap=function(e){var n=this;var r=this._readableState;var s=false;e.on("end",function(){a("wrapped end");if(r.decoder&&!r.ended){var e=r.decoder.end();if(e&&e.length)n.push(e)}n.push(null)});e.on("data",function(i){a("wrapped data");if(r.decoder)i=r.decoder.write(i);if(r.objectMode&&(i===null||i===undefined))return;else if(!r.objectMode&&(!i||!i.length))return;var f=n.push(i);if(!f){s=true;e.pause()}});for(var i in e){if(this[i]===undefined&&typeof e[i]==="function"){this[i]=function methodWrap(n){return function methodWrapReturnFunction(){return e[n].apply(e,arguments)}}(i)}}for(var f=0;f<O.length;f++){e.on(O[f],this.emit.bind(this,O[f]))}this._read=function(n){a("wrapped _read",n);if(s){s=false;e.resume()}};return this};if(typeof Symbol==="function"){Readable.prototype[Symbol.asyncIterator]=function(){if(E===undefined){E=r(4790)}return E(this)}}Object.defineProperty(Readable.prototype,"readableHighWaterMark",{enumerable:false,get:function get(){return this._readableState.highWaterMark}});Object.defineProperty(Readable.prototype,"readableBuffer",{enumerable:false,get:function get(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(Readable.prototype,"readableFlowing",{enumerable:false,get:function get(){return this._readableState.flowing},set:function set(e){if(this._readableState){this._readableState.flowing=e}}});Readable._fromList=fromList;Object.defineProperty(Readable.prototype,"readableLength",{enumerable:false,get:function get(){return this._readableState.length}});function fromList(e,n){if(n.length===0)return null;var r;if(n.objectMode)r=n.buffer.shift();else if(!e||e>=n.length){if(n.decoder)r=n.buffer.join("");else if(n.buffer.length===1)r=n.buffer.first();else r=n.buffer.concat(n.length);n.buffer.clear()}else{r=n.buffer.consume(e,n.decoder)}return r}function endReadable(e){var n=e._readableState;a("endReadable",n.endEmitted);if(!n.endEmitted){n.ended=true;process.nextTick(endReadableNT,n,e)}}function endReadableNT(e,n){a("endReadableNT",e.endEmitted,e.length);if(!e.endEmitted&&e.length===0){e.endEmitted=true;n.readable=false;n.emit("end");if(e.autoDestroy){var r=n._writableState;if(!r||r.autoDestroy&&r.finished){n.destroy()}}}}if(typeof Symbol==="function"){Readable.from=function(e,n){if(S===undefined){S=r(8831)}return S(Readable,e,n)}}function indexOf(e,n){for(var r=0,s=e.length;r<s;r++){if(e[r]===n)return r}return-1}},1784:(e,n,r)=>{"use strict";e.exports=Transform;var s=r(5484).q,i=s.ERR_METHOD_NOT_IMPLEMENTED,f=s.ERR_MULTIPLE_CALLBACK,l=s.ERR_TRANSFORM_ALREADY_TRANSFORMING,t=s.ERR_TRANSFORM_WITH_LENGTH_0;var o=r(6238);r(3655)(Transform,o);function afterTransform(e,n){var r=this._transformState;r.transforming=false;var s=r.writecb;if(s===null){return this.emit("error",new f)}r.writechunk=null;r.writecb=null;if(n!=null)this.push(n);s(e);var i=this._readableState;i.reading=false;if(i.needReadable||i.length<i.highWaterMark){this._read(i.highWaterMark)}}function Transform(e){if(!(this instanceof Transform))return new Transform(e);o.call(this,e);this._transformState={afterTransform:afterTransform.bind(this),needTransform:false,transforming:false,writecb:null,writechunk:null,writeencoding:null};this._readableState.needReadable=true;this._readableState.sync=false;if(e){if(typeof e.transform==="function")this._transform=e.transform;if(typeof e.flush==="function")this._flush=e.flush}this.on("prefinish",prefinish)}function prefinish(){var e=this;if(typeof this._flush==="function"&&!this._readableState.destroyed){this._flush(function(n,r){done(e,n,r)})}else{done(this,null,null)}}Transform.prototype.push=function(e,n){this._transformState.needTransform=false;return o.prototype.push.call(this,e,n)};Transform.prototype._transform=function(e,n,r){r(new i("_transform()"))};Transform.prototype._write=function(e,n,r){var s=this._transformState;s.writecb=r;s.writechunk=e;s.writeencoding=n;if(!s.transforming){var i=this._readableState;if(s.needTransform||i.needReadable||i.length<i.highWaterMark)this._read(i.highWaterMark)}};Transform.prototype._read=function(e){var n=this._transformState;if(n.writechunk!==null&&!n.transforming){n.transforming=true;this._transform(n.writechunk,n.writeencoding,n.afterTransform)}else{n.needTransform=true}};Transform.prototype._destroy=function(e,n){o.prototype._destroy.call(this,e,function(e){n(e)})};function done(e,n,r){if(n)return e.emit("error",n);if(r!=null)e.push(r);if(e._writableState.length)throw new t;if(e._transformState.transforming)throw new l;return e.push(null)}},8376:(e,n,r)=>{"use strict";e.exports=Writable;function WriteReq(e,n,r){this.chunk=e;this.encoding=n;this.callback=r;this.next=null}function CorkedRequest(e){var n=this;this.next=null;this.entry=null;this.finish=function(){onCorkedFinish(n,e)}}var s;Writable.WritableState=WritableState;var i={deprecate:r(1202)};var f=r(4194);var l=r(4293).Buffer;var t=global.Uint8Array||function(){};function _uint8ArrayToBuffer(e){return l.from(e)}function _isUint8Array(e){return l.isBuffer(e)||e instanceof t}var o=r(8608);var c=r(9971),a=c.getHighWaterMark;var d=r(5484).q,p=d.ERR_INVALID_ARG_TYPE,u=d.ERR_METHOD_NOT_IMPLEMENTED,h=d.ERR_MULTIPLE_CALLBACK,v=d.ERR_STREAM_CANNOT_PIPE,g=d.ERR_STREAM_DESTROYED,b=d.ERR_STREAM_NULL_VALUES,w=d.ERR_STREAM_WRITE_AFTER_END,y=d.ERR_UNKNOWN_ENCODING;var m=o.errorOrDestroy;r(3655)(Writable,f);function nop(){}function WritableState(e,n,i){s=s||r(6238);e=e||{};if(typeof i!=="boolean")i=n instanceof s;this.objectMode=!!e.objectMode;if(i)this.objectMode=this.objectMode||!!e.writableObjectMode;this.highWaterMark=a(this,e,"writableHighWaterMark",i);this.finalCalled=false;this.needDrain=false;this.ending=false;this.ended=false;this.finished=false;this.destroyed=false;var f=e.decodeStrings===false;this.decodeStrings=!f;this.defaultEncoding=e.defaultEncoding||"utf8";this.length=0;this.writing=false;this.corked=0;this.sync=true;this.bufferProcessing=false;this.onwrite=function(e){onwrite(n,e)};this.writecb=null;this.writelen=0;this.bufferedRequest=null;this.lastBufferedRequest=null;this.pendingcb=0;this.prefinished=false;this.errorEmitted=false;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.bufferedRequestCount=0;this.corkedRequestsFree=new CorkedRequest(this)}WritableState.prototype.getBuffer=function getBuffer(){var e=this.bufferedRequest;var n=[];while(e){n.push(e);e=e.next}return n};(function(){try{Object.defineProperty(WritableState.prototype,"buffer",{get:i.deprecate(function writableStateBufferGetter(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer "+"instead.","DEP0003")})}catch(e){}})();var E;if(typeof Symbol==="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]==="function"){E=Function.prototype[Symbol.hasInstance];Object.defineProperty(Writable,Symbol.hasInstance,{value:function value(e){if(E.call(this,e))return true;if(this!==Writable)return false;return e&&e._writableState instanceof WritableState}})}else{E=function realHasInstance(e){return e instanceof this}}function Writable(e){s=s||r(6238);var n=this instanceof s;if(!n&&!E.call(Writable,this))return new Writable(e);this._writableState=new WritableState(e,this,n);this.writable=true;if(e){if(typeof e.write==="function")this._write=e.write;if(typeof e.writev==="function")this._writev=e.writev;if(typeof e.destroy==="function")this._destroy=e.destroy;if(typeof e.final==="function")this._final=e.final}f.call(this)}Writable.prototype.pipe=function(){m(this,new v)};function writeAfterEnd(e,n){var r=new w;m(e,r);process.nextTick(n,r)}function validChunk(e,n,r,s){var i;if(r===null){i=new b}else if(typeof r!=="string"&&!n.objectMode){i=new p("chunk",["string","Buffer"],r)}if(i){m(e,i);process.nextTick(s,i);return false}return true}Writable.prototype.write=function(e,n,r){var s=this._writableState;var i=false;var f=!s.objectMode&&_isUint8Array(e);if(f&&!l.isBuffer(e)){e=_uint8ArrayToBuffer(e)}if(typeof n==="function"){r=n;n=null}if(f)n="buffer";else if(!n)n=s.defaultEncoding;if(typeof r!=="function")r=nop;if(s.ending)writeAfterEnd(this,r);else if(f||validChunk(this,s,e,r)){s.pendingcb++;i=writeOrBuffer(this,s,f,e,n,r)}return i};Writable.prototype.cork=function(){this._writableState.corked++};Writable.prototype.uncork=function(){var e=this._writableState;if(e.corked){e.corked--;if(!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest)clearBuffer(this,e)}};Writable.prototype.setDefaultEncoding=function setDefaultEncoding(e){if(typeof e==="string")e=e.toLowerCase();if(!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new y(e);this._writableState.defaultEncoding=e;return this};Object.defineProperty(Writable.prototype,"writableBuffer",{enumerable:false,get:function get(){return this._writableState&&this._writableState.getBuffer()}});function decodeChunk(e,n,r){if(!e.objectMode&&e.decodeStrings!==false&&typeof n==="string"){n=l.from(n,r)}return n}Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:false,get:function get(){return this._writableState.highWaterMark}});function writeOrBuffer(e,n,r,s,i,f){if(!r){var l=decodeChunk(n,s,i);if(s!==l){r=true;i="buffer";s=l}}var t=n.objectMode?1:s.length;n.length+=t;var o=n.length<n.highWaterMark;if(!o)n.needDrain=true;if(n.writing||n.corked){var c=n.lastBufferedRequest;n.lastBufferedRequest={chunk:s,encoding:i,isBuf:r,callback:f,next:null};if(c){c.next=n.lastBufferedRequest}else{n.bufferedRequest=n.lastBufferedRequest}n.bufferedRequestCount+=1}else{doWrite(e,n,false,t,s,i,f)}return o}function doWrite(e,n,r,s,i,f,l){n.writelen=s;n.writecb=l;n.writing=true;n.sync=true;if(n.destroyed)n.onwrite(new g("write"));else if(r)e._writev(i,n.onwrite);else e._write(i,f,n.onwrite);n.sync=false}function onwriteError(e,n,r,s,i){--n.pendingcb;if(r){process.nextTick(i,s);process.nextTick(finishMaybe,e,n);e._writableState.errorEmitted=true;m(e,s)}else{i(s);e._writableState.errorEmitted=true;m(e,s);finishMaybe(e,n)}}function onwriteStateUpdate(e){e.writing=false;e.writecb=null;e.length-=e.writelen;e.writelen=0}function onwrite(e,n){var r=e._writableState;var s=r.sync;var i=r.writecb;if(typeof i!=="function")throw new h;onwriteStateUpdate(r);if(n)onwriteError(e,r,s,n,i);else{var f=needFinish(r)||e.destroyed;if(!f&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest){clearBuffer(e,r)}if(s){process.nextTick(afterWrite,e,r,f,i)}else{afterWrite(e,r,f,i)}}}function afterWrite(e,n,r,s){if(!r)onwriteDrain(e,n);n.pendingcb--;s();finishMaybe(e,n)}function onwriteDrain(e,n){if(n.length===0&&n.needDrain){n.needDrain=false;e.emit("drain")}}function clearBuffer(e,n){n.bufferProcessing=true;var r=n.bufferedRequest;if(e._writev&&r&&r.next){var s=n.bufferedRequestCount;var i=new Array(s);var f=n.corkedRequestsFree;f.entry=r;var l=0;var t=true;while(r){i[l]=r;if(!r.isBuf)t=false;r=r.next;l+=1}i.allBuffers=t;doWrite(e,n,true,n.length,i,"",f.finish);n.pendingcb++;n.lastBufferedRequest=null;if(f.next){n.corkedRequestsFree=f.next;f.next=null}else{n.corkedRequestsFree=new CorkedRequest(n)}n.bufferedRequestCount=0}else{while(r){var o=r.chunk;var c=r.encoding;var a=r.callback;var d=n.objectMode?1:o.length;doWrite(e,n,false,d,o,c,a);r=r.next;n.bufferedRequestCount--;if(n.writing){break}}if(r===null)n.lastBufferedRequest=null}n.bufferedRequest=r;n.bufferProcessing=false}Writable.prototype._write=function(e,n,r){r(new u("_write()"))};Writable.prototype._writev=null;Writable.prototype.end=function(e,n,r){var s=this._writableState;if(typeof e==="function"){r=e;e=null;n=null}else if(typeof n==="function"){r=n;n=null}if(e!==null&&e!==undefined)this.write(e,n);if(s.corked){s.corked=1;this.uncork()}if(!s.ending)endWritable(this,s,r);return this};Object.defineProperty(Writable.prototype,"writableLength",{enumerable:false,get:function get(){return this._writableState.length}});function needFinish(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function callFinal(e,n){e._final(function(r){n.pendingcb--;if(r){m(e,r)}n.prefinished=true;e.emit("prefinish");finishMaybe(e,n)})}function prefinish(e,n){if(!n.prefinished&&!n.finalCalled){if(typeof e._final==="function"&&!n.destroyed){n.pendingcb++;n.finalCalled=true;process.nextTick(callFinal,e,n)}else{n.prefinished=true;e.emit("prefinish")}}}function finishMaybe(e,n){var r=needFinish(n);if(r){prefinish(e,n);if(n.pendingcb===0){n.finished=true;e.emit("finish");if(n.autoDestroy){var s=e._readableState;if(!s||s.autoDestroy&&s.endEmitted){e.destroy()}}}}return r}function endWritable(e,n,r){n.ending=true;finishMaybe(e,n);if(r){if(n.finished)process.nextTick(r);else e.once("finish",r)}n.ended=true;e.writable=false}function onCorkedFinish(e,n,r){var s=e.entry;e.entry=null;while(s){var i=s.callback;n.pendingcb--;i(r);s=s.next}n.corkedRequestsFree.next=e}Object.defineProperty(Writable.prototype,"destroyed",{enumerable:false,get:function get(){if(this._writableState===undefined){return false}return this._writableState.destroyed},set:function set(e){if(!this._writableState){return}this._writableState.destroyed=e}});Writable.prototype.destroy=o.destroy;Writable.prototype._undestroy=o.undestroy;Writable.prototype._destroy=function(e,n){n(e)}},4790:(e,n,r)=>{"use strict";var s;function _defineProperty(e,n,r){if(n in e){Object.defineProperty(e,n,{value:r,enumerable:true,configurable:true,writable:true})}else{e[n]=r}return e}var i=r(6659);var f=Symbol("lastResolve");var l=Symbol("lastReject");var t=Symbol("error");var o=Symbol("ended");var c=Symbol("lastPromise");var a=Symbol("handlePromise");var d=Symbol("stream");function createIterResult(e,n){return{value:e,done:n}}function readAndResolve(e){var n=e[f];if(n!==null){var r=e[d].read();if(r!==null){e[c]=null;e[f]=null;e[l]=null;n(createIterResult(r,false))}}}function onReadable(e){process.nextTick(readAndResolve,e)}function wrapForNext(e,n){return function(r,s){e.then(function(){if(n[o]){r(createIterResult(undefined,true));return}n[a](r,s)},s)}}var p=Object.getPrototypeOf(function(){});var u=Object.setPrototypeOf((s={get stream(){return this[d]},next:function next(){var e=this;var n=this[t];if(n!==null){return Promise.reject(n)}if(this[o]){return Promise.resolve(createIterResult(undefined,true))}if(this[d].destroyed){return new Promise(function(n,r){process.nextTick(function(){if(e[t]){r(e[t])}else{n(createIterResult(undefined,true))}})})}var r=this[c];var s;if(r){s=new Promise(wrapForNext(r,this))}else{var i=this[d].read();if(i!==null){return Promise.resolve(createIterResult(i,false))}s=new Promise(this[a])}this[c]=s;return s}},_defineProperty(s,Symbol.asyncIterator,function(){return this}),_defineProperty(s,"return",function _return(){var e=this;return new Promise(function(n,r){e[d].destroy(null,function(e){if(e){r(e);return}n(createIterResult(undefined,true))})})}),s),p);var h=function createReadableStreamAsyncIterator(e){var n;var r=Object.create(u,(n={},_defineProperty(n,d,{value:e,writable:true}),_defineProperty(n,f,{value:null,writable:true}),_defineProperty(n,l,{value:null,writable:true}),_defineProperty(n,t,{value:null,writable:true}),_defineProperty(n,o,{value:e._readableState.endEmitted,writable:true}),_defineProperty(n,a,{value:function value(e,n){var s=r[d].read();if(s){r[c]=null;r[f]=null;r[l]=null;e(createIterResult(s,false))}else{r[f]=e;r[l]=n}},writable:true}),n));r[c]=null;i(e,function(e){if(e&&e.code!=="ERR_STREAM_PREMATURE_CLOSE"){var n=r[l];if(n!==null){r[c]=null;r[f]=null;r[l]=null;n(e)}r[t]=e;return}var s=r[f];if(s!==null){r[c]=null;r[f]=null;r[l]=null;s(createIterResult(undefined,true))}r[o]=true});e.on("readable",onReadable.bind(null,r));return r};e.exports=h},8994:(e,n,r)=>{"use strict";function ownKeys(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(n)s=s.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable});r.push.apply(r,s)}return r}function _objectSpread(e){for(var n=1;n<arguments.length;n++){var r=arguments[n]!=null?arguments[n]:{};if(n%2){ownKeys(Object(r),true).forEach(function(n){_defineProperty(e,n,r[n])})}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(e,Object.getOwnPropertyDescriptors(r))}else{ownKeys(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}}return e}function _defineProperty(e,n,r){if(n in e){Object.defineProperty(e,n,{value:r,enumerable:true,configurable:true,writable:true})}else{e[n]=r}return e}function _classCallCheck(e,n){if(!(e instanceof n)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(e,n){for(var r=0;r<n.length;r++){var s=n[r];s.enumerable=s.enumerable||false;s.configurable=true;if("value"in s)s.writable=true;Object.defineProperty(e,s.key,s)}}function _createClass(e,n,r){if(n)_defineProperties(e.prototype,n);if(r)_defineProperties(e,r);return e}var s=r(4293),i=s.Buffer;var f=r(1669),l=f.inspect;var t=l&&l.custom||"inspect";function copyBuffer(e,n,r){i.prototype.copy.call(e,n,r)}e.exports=function(){function BufferList(){_classCallCheck(this,BufferList);this.head=null;this.tail=null;this.length=0}_createClass(BufferList,[{key:"push",value:function push(e){var n={data:e,next:null};if(this.length>0)this.tail.next=n;else this.head=n;this.tail=n;++this.length}},{key:"unshift",value:function unshift(e){var n={data:e,next:this.head};if(this.length===0)this.tail=n;this.head=n;++this.length}},{key:"shift",value:function shift(){if(this.length===0)return;var e=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;--this.length;return e}},{key:"clear",value:function clear(){this.head=this.tail=null;this.length=0}},{key:"join",value:function join(e){if(this.length===0)return"";var n=this.head;var r=""+n.data;while(n=n.next){r+=e+n.data}return r}},{key:"concat",value:function concat(e){if(this.length===0)return i.alloc(0);var n=i.allocUnsafe(e>>>0);var r=this.head;var s=0;while(r){copyBuffer(r.data,n,s);s+=r.data.length;r=r.next}return n}},{key:"consume",value:function consume(e,n){var r;if(e<this.head.data.length){r=this.head.data.slice(0,e);this.head.data=this.head.data.slice(e)}else if(e===this.head.data.length){r=this.shift()}else{r=n?this._getString(e):this._getBuffer(e)}return r}},{key:"first",value:function first(){return this.head.data}},{key:"_getString",value:function _getString(e){var n=this.head;var r=1;var s=n.data;e-=s.length;while(n=n.next){var i=n.data;var f=e>i.length?i.length:e;if(f===i.length)s+=i;else s+=i.slice(0,e);e-=f;if(e===0){if(f===i.length){++r;if(n.next)this.head=n.next;else this.head=this.tail=null}else{this.head=n;n.data=i.slice(f)}break}++r}this.length-=r;return s}},{key:"_getBuffer",value:function _getBuffer(e){var n=i.allocUnsafe(e);var r=this.head;var s=1;r.data.copy(n);e-=r.data.length;while(r=r.next){var f=r.data;var l=e>f.length?f.length:e;f.copy(n,n.length-e,0,l);e-=l;if(e===0){if(l===f.length){++s;if(r.next)this.head=r.next;else this.head=this.tail=null}else{this.head=r;r.data=f.slice(l)}break}++s}this.length-=s;return n}},{key:t,value:function value(e,n){return l(this,_objectSpread({},n,{depth:0,customInspect:false}))}}]);return BufferList}()},8608:e=>{"use strict";function destroy(e,n){var r=this;var s=this._readableState&&this._readableState.destroyed;var i=this._writableState&&this._writableState.destroyed;if(s||i){if(n){n(e)}else if(e){if(!this._writableState){process.nextTick(emitErrorNT,this,e)}else if(!this._writableState.errorEmitted){this._writableState.errorEmitted=true;process.nextTick(emitErrorNT,this,e)}}return this}if(this._readableState){this._readableState.destroyed=true}if(this._writableState){this._writableState.destroyed=true}this._destroy(e||null,function(e){if(!n&&e){if(!r._writableState){process.nextTick(emitErrorAndCloseNT,r,e)}else if(!r._writableState.errorEmitted){r._writableState.errorEmitted=true;process.nextTick(emitErrorAndCloseNT,r,e)}else{process.nextTick(emitCloseNT,r)}}else if(n){process.nextTick(emitCloseNT,r);n(e)}else{process.nextTick(emitCloseNT,r)}});return this}function emitErrorAndCloseNT(e,n){emitErrorNT(e,n);emitCloseNT(e)}function emitCloseNT(e){if(e._writableState&&!e._writableState.emitClose)return;if(e._readableState&&!e._readableState.emitClose)return;e.emit("close")}function undestroy(){if(this._readableState){this._readableState.destroyed=false;this._readableState.reading=false;this._readableState.ended=false;this._readableState.endEmitted=false}if(this._writableState){this._writableState.destroyed=false;this._writableState.ended=false;this._writableState.ending=false;this._writableState.finalCalled=false;this._writableState.prefinished=false;this._writableState.finished=false;this._writableState.errorEmitted=false}}function emitErrorNT(e,n){e.emit("error",n)}function errorOrDestroy(e,n){var r=e._readableState;var s=e._writableState;if(r&&r.autoDestroy||s&&s.autoDestroy)e.destroy(n);else e.emit("error",n)}e.exports={destroy:destroy,undestroy:undestroy,errorOrDestroy:errorOrDestroy}},6659:(e,n,r)=>{"use strict";var s=r(5484).q.ERR_STREAM_PREMATURE_CLOSE;function once(e){var n=false;return function(){if(n)return;n=true;for(var r=arguments.length,s=new Array(r),i=0;i<r;i++){s[i]=arguments[i]}e.apply(this,s)}}function noop(){}function isRequest(e){return e.setHeader&&typeof e.abort==="function"}function eos(e,n,r){if(typeof n==="function")return eos(e,null,n);if(!n)n={};r=once(r||noop);var i=n.readable||n.readable!==false&&e.readable;var f=n.writable||n.writable!==false&&e.writable;var l=function onlegacyfinish(){if(!e.writable)o()};var t=e._writableState&&e._writableState.finished;var o=function onfinish(){f=false;t=true;if(!i)r.call(e)};var c=e._readableState&&e._readableState.endEmitted;var a=function onend(){i=false;c=true;if(!f)r.call(e)};var d=function onerror(n){r.call(e,n)};var p=function onclose(){var n;if(i&&!c){if(!e._readableState||!e._readableState.ended)n=new s;return r.call(e,n)}if(f&&!t){if(!e._writableState||!e._writableState.ended)n=new s;return r.call(e,n)}};var u=function onrequest(){e.req.on("finish",o)};if(isRequest(e)){e.on("complete",o);e.on("abort",p);if(e.req)u();else e.on("request",u)}else if(f&&!e._writableState){e.on("end",l);e.on("close",l)}e.on("end",a);e.on("finish",o);if(n.error!==false)e.on("error",d);e.on("close",p);return function(){e.removeListener("complete",o);e.removeListener("abort",p);e.removeListener("request",u);if(e.req)e.req.removeListener("finish",o);e.removeListener("end",l);e.removeListener("close",l);e.removeListener("finish",o);e.removeListener("end",a);e.removeListener("error",d);e.removeListener("close",p)}}e.exports=eos},8831:(e,n,r)=>{"use strict";function asyncGeneratorStep(e,n,r,s,i,f,l){try{var t=e[f](l);var o=t.value}catch(e){r(e);return}if(t.done){n(o)}else{Promise.resolve(o).then(s,i)}}function _asyncToGenerator(e){return function(){var n=this,r=arguments;return new Promise(function(s,i){var f=e.apply(n,r);function _next(e){asyncGeneratorStep(f,s,i,_next,_throw,"next",e)}function _throw(e){asyncGeneratorStep(f,s,i,_next,_throw,"throw",e)}_next(undefined)})}}function ownKeys(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);if(n)s=s.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable});r.push.apply(r,s)}return r}function _objectSpread(e){for(var n=1;n<arguments.length;n++){var r=arguments[n]!=null?arguments[n]:{};if(n%2){ownKeys(Object(r),true).forEach(function(n){_defineProperty(e,n,r[n])})}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(e,Object.getOwnPropertyDescriptors(r))}else{ownKeys(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}}return e}function _defineProperty(e,n,r){if(n in e){Object.defineProperty(e,n,{value:r,enumerable:true,configurable:true,writable:true})}else{e[n]=r}return e}var s=r(5484).q.ERR_INVALID_ARG_TYPE;function from(e,n,r){var i;if(n&&typeof n.next==="function"){i=n}else if(n&&n[Symbol.asyncIterator])i=n[Symbol.asyncIterator]();else if(n&&n[Symbol.iterator])i=n[Symbol.iterator]();else throw new s("iterable",["Iterable"],n);var f=new e(_objectSpread({objectMode:true},r));var l=false;f._read=function(){if(!l){l=true;next()}};function next(){return _next2.apply(this,arguments)}function _next2(){_next2=_asyncToGenerator(function*(){try{var e=yield i.next(),n=e.value,r=e.done;if(r){f.push(null)}else if(f.push(yield n)){next()}else{l=false}}catch(e){f.destroy(e)}});return _next2.apply(this,arguments)}return f}e.exports=from},7751:(e,n,r)=>{"use strict";var s;function once(e){var n=false;return function(){if(n)return;n=true;e.apply(void 0,arguments)}}var i=r(5484).q,f=i.ERR_MISSING_ARGS,l=i.ERR_STREAM_DESTROYED;function noop(e){if(e)throw e}function isRequest(e){return e.setHeader&&typeof e.abort==="function"}function destroyer(e,n,i,f){f=once(f);var t=false;e.on("close",function(){t=true});if(s===undefined)s=r(6659);s(e,{readable:n,writable:i},function(e){if(e)return f(e);t=true;f()});var o=false;return function(n){if(t)return;if(o)return;o=true;if(isRequest(e))return e.abort();if(typeof e.destroy==="function")return e.destroy();f(n||new l("pipe"))}}function call(e){e()}function pipe(e,n){return e.pipe(n)}function popCallback(e){if(!e.length)return noop;if(typeof e[e.length-1]!=="function")return noop;return e.pop()}function pipeline(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++){n[r]=arguments[r]}var s=popCallback(n);if(Array.isArray(n[0]))n=n[0];if(n.length<2){throw new f("streams")}var i;var l=n.map(function(e,r){var f=r<n.length-1;var t=r>0;return destroyer(e,f,t,function(e){if(!i)i=e;if(e)l.forEach(call);if(f)return;l.forEach(call);s(i)})});return n.reduce(pipe)}e.exports=pipeline},9971:(e,n,r)=>{"use strict";var s=r(5484).q.ERR_INVALID_OPT_VALUE;function highWaterMarkFrom(e,n,r){return e.highWaterMark!=null?e.highWaterMark:n?e[r]:null}function getHighWaterMark(e,n,r,i){var f=highWaterMarkFrom(n,i,r);if(f!=null){if(!(isFinite(f)&&Math.floor(f)===f)||f<0){var l=i?r:"highWaterMark";throw new s(l,f)}return Math.floor(f)}return e.objectMode?16:16*1024}e.exports={getHighWaterMark:getHighWaterMark}},4194:(e,n,r)=>{e.exports=r(2413)},3739:(e,n,r)=>{var s=r(2413);if(process.env.READABLE_STREAM==="disable"&&s){e.exports=s.Readable;Object.assign(e.exports,s);e.exports.Stream=s}else{n=e.exports=r(7790);n.Stream=s||n;n.Readable=n;n.Writable=r(8376);n.Duplex=r(6238);n.Transform=r(1784);n.PassThrough=r(1650);n.finished=r(6659);n.pipeline=r(7751)}},8414:(e,n,r)=>{var s=r(4293);var i=s.Buffer;function copyProps(e,n){for(var r in e){n[r]=e[r]}}if(i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow){e.exports=s}else{copyProps(s,n);n.Buffer=SafeBuffer}function SafeBuffer(e,n,r){return i(e,n,r)}SafeBuffer.prototype=Object.create(i.prototype);copyProps(i,SafeBuffer);SafeBuffer.from=function(e,n,r){if(typeof e==="number"){throw new TypeError("Argument must not be a number")}return i(e,n,r)};SafeBuffer.alloc=function(e,n,r){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}var s=i(e);if(n!==undefined){if(typeof r==="string"){s.fill(n,r)}else{s.fill(n)}}else{s.fill(0)}return s};SafeBuffer.allocUnsafe=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return i(e)};SafeBuffer.allocUnsafeSlow=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return s.SlowBuffer(e)}},2313:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});const s=r(7008);const i=4096;const f="utf8";class SmartBuffer{constructor(e){this.length=0;this._encoding=f;this._writeOffset=0;this._readOffset=0;if(SmartBuffer.isSmartBufferOptions(e)){if(e.encoding){s.checkEncoding(e.encoding);this._encoding=e.encoding}if(e.size){if(s.isFiniteInteger(e.size)&&e.size>0){this._buff=Buffer.allocUnsafe(e.size)}else{throw new Error(s.ERRORS.INVALID_SMARTBUFFER_SIZE)}}else if(e.buff){if(Buffer.isBuffer(e.buff)){this._buff=e.buff;this.length=e.buff.length}else{throw new Error(s.ERRORS.INVALID_SMARTBUFFER_BUFFER)}}else{this._buff=Buffer.allocUnsafe(i)}}else{if(typeof e!=="undefined"){throw new Error(s.ERRORS.INVALID_SMARTBUFFER_OBJECT)}this._buff=Buffer.allocUnsafe(i)}}static fromSize(e,n){return new this({size:e,encoding:n})}static fromBuffer(e,n){return new this({buff:e,encoding:n})}static fromOptions(e){return new this(e)}static isSmartBufferOptions(e){const n=e;return n&&(n.encoding!==undefined||n.size!==undefined||n.buff!==undefined)}readInt8(e){return this._readNumberValue(Buffer.prototype.readInt8,1,e)}readInt16BE(e){return this._readNumberValue(Buffer.prototype.readInt16BE,2,e)}readInt16LE(e){return this._readNumberValue(Buffer.prototype.readInt16LE,2,e)}readInt32BE(e){return this._readNumberValue(Buffer.prototype.readInt32BE,4,e)}readInt32LE(e){return this._readNumberValue(Buffer.prototype.readInt32LE,4,e)}readBigInt64BE(e){s.bigIntAndBufferInt64Check("readBigInt64BE");return this._readNumberValue(Buffer.prototype.readBigInt64BE,8,e)}readBigInt64LE(e){s.bigIntAndBufferInt64Check("readBigInt64LE");return this._readNumberValue(Buffer.prototype.readBigInt64LE,8,e)}writeInt8(e,n){this._writeNumberValue(Buffer.prototype.writeInt8,1,e,n);return this}insertInt8(e,n){return this._insertNumberValue(Buffer.prototype.writeInt8,1,e,n)}writeInt16BE(e,n){return this._writeNumberValue(Buffer.prototype.writeInt16BE,2,e,n)}insertInt16BE(e,n){return this._insertNumberValue(Buffer.prototype.writeInt16BE,2,e,n)}writeInt16LE(e,n){return this._writeNumberValue(Buffer.prototype.writeInt16LE,2,e,n)}insertInt16LE(e,n){return this._insertNumberValue(Buffer.prototype.writeInt16LE,2,e,n)}writeInt32BE(e,n){return this._writeNumberValue(Buffer.prototype.writeInt32BE,4,e,n)}insertInt32BE(e,n){return this._insertNumberValue(Buffer.prototype.writeInt32BE,4,e,n)}writeInt32LE(e,n){return this._writeNumberValue(Buffer.prototype.writeInt32LE,4,e,n)}insertInt32LE(e,n){return this._insertNumberValue(Buffer.prototype.writeInt32LE,4,e,n)}writeBigInt64BE(e,n){s.bigIntAndBufferInt64Check("writeBigInt64BE");return this._writeNumberValue(Buffer.prototype.writeBigInt64BE,8,e,n)}insertBigInt64BE(e,n){s.bigIntAndBufferInt64Check("writeBigInt64BE");return this._insertNumberValue(Buffer.prototype.writeBigInt64BE,8,e,n)}writeBigInt64LE(e,n){s.bigIntAndBufferInt64Check("writeBigInt64LE");return this._writeNumberValue(Buffer.prototype.writeBigInt64LE,8,e,n)}insertBigInt64LE(e,n){s.bigIntAndBufferInt64Check("writeBigInt64LE");return this._insertNumberValue(Buffer.prototype.writeBigInt64LE,8,e,n)}readUInt8(e){return this._readNumberValue(Buffer.prototype.readUInt8,1,e)}readUInt16BE(e){return this._readNumberValue(Buffer.prototype.readUInt16BE,2,e)}readUInt16LE(e){return this._readNumberValue(Buffer.prototype.readUInt16LE,2,e)}readUInt32BE(e){return this._readNumberValue(Buffer.prototype.readUInt32BE,4,e)}readUInt32LE(e){return this._readNumberValue(Buffer.prototype.readUInt32LE,4,e)}readBigUInt64BE(e){s.bigIntAndBufferInt64Check("readBigUInt64BE");return this._readNumberValue(Buffer.prototype.readBigUInt64BE,8,e)}readBigUInt64LE(e){s.bigIntAndBufferInt64Check("readBigUInt64LE");return this._readNumberValue(Buffer.prototype.readBigUInt64LE,8,e)}writeUInt8(e,n){return this._writeNumberValue(Buffer.prototype.writeUInt8,1,e,n)}insertUInt8(e,n){return this._insertNumberValue(Buffer.prototype.writeUInt8,1,e,n)}writeUInt16BE(e,n){return this._writeNumberValue(Buffer.prototype.writeUInt16BE,2,e,n)}insertUInt16BE(e,n){return this._insertNumberValue(Buffer.prototype.writeUInt16BE,2,e,n)}writeUInt16LE(e,n){return this._writeNumberValue(Buffer.prototype.writeUInt16LE,2,e,n)}insertUInt16LE(e,n){return this._insertNumberValue(Buffer.prototype.writeUInt16LE,2,e,n)}writeUInt32BE(e,n){return this._writeNumberValue(Buffer.prototype.writeUInt32BE,4,e,n)}insertUInt32BE(e,n){return this._insertNumberValue(Buffer.prototype.writeUInt32BE,4,e,n)}writeUInt32LE(e,n){return this._writeNumberValue(Buffer.prototype.writeUInt32LE,4,e,n)}insertUInt32LE(e,n){return this._insertNumberValue(Buffer.prototype.writeUInt32LE,4,e,n)}writeBigUInt64BE(e,n){s.bigIntAndBufferInt64Check("writeBigUInt64BE");return this._writeNumberValue(Buffer.prototype.writeBigUInt64BE,8,e,n)}insertBigUInt64BE(e,n){s.bigIntAndBufferInt64Check("writeBigUInt64BE");return this._insertNumberValue(Buffer.prototype.writeBigUInt64BE,8,e,n)}writeBigUInt64LE(e,n){s.bigIntAndBufferInt64Check("writeBigUInt64LE");return this._writeNumberValue(Buffer.prototype.writeBigUInt64LE,8,e,n)}insertBigUInt64LE(e,n){s.bigIntAndBufferInt64Check("writeBigUInt64LE");return this._insertNumberValue(Buffer.prototype.writeBigUInt64LE,8,e,n)}readFloatBE(e){return this._readNumberValue(Buffer.prototype.readFloatBE,4,e)}readFloatLE(e){return this._readNumberValue(Buffer.prototype.readFloatLE,4,e)}writeFloatBE(e,n){return this._writeNumberValue(Buffer.prototype.writeFloatBE,4,e,n)}insertFloatBE(e,n){return this._insertNumberValue(Buffer.prototype.writeFloatBE,4,e,n)}writeFloatLE(e,n){return this._writeNumberValue(Buffer.prototype.writeFloatLE,4,e,n)}insertFloatLE(e,n){return this._insertNumberValue(Buffer.prototype.writeFloatLE,4,e,n)}readDoubleBE(e){return this._readNumberValue(Buffer.prototype.readDoubleBE,8,e)}readDoubleLE(e){return this._readNumberValue(Buffer.prototype.readDoubleLE,8,e)}writeDoubleBE(e,n){return this._writeNumberValue(Buffer.prototype.writeDoubleBE,8,e,n)}insertDoubleBE(e,n){return this._insertNumberValue(Buffer.prototype.writeDoubleBE,8,e,n)}writeDoubleLE(e,n){return this._writeNumberValue(Buffer.prototype.writeDoubleLE,8,e,n)}insertDoubleLE(e,n){return this._insertNumberValue(Buffer.prototype.writeDoubleLE,8,e,n)}readString(e,n){let r;if(typeof e==="number"){s.checkLengthValue(e);r=Math.min(e,this.length-this._readOffset)}else{n=e;r=this.length-this._readOffset}if(typeof n!=="undefined"){s.checkEncoding(n)}const i=this._buff.slice(this._readOffset,this._readOffset+r).toString(n||this._encoding);this._readOffset+=r;return i}insertString(e,n,r){s.checkOffsetValue(n);return this._handleString(e,true,n,r)}writeString(e,n,r){return this._handleString(e,false,n,r)}readStringNT(e){if(typeof e!=="undefined"){s.checkEncoding(e)}let n=this.length;for(let e=this._readOffset;e<this.length;e++){if(this._buff[e]===0){n=e;break}}const r=this._buff.slice(this._readOffset,n);this._readOffset=n+1;return r.toString(e||this._encoding)}insertStringNT(e,n,r){s.checkOffsetValue(n);this.insertString(e,n,r);this.insertUInt8(0,n+e.length);return this}writeStringNT(e,n,r){this.writeString(e,n,r);this.writeUInt8(0,typeof n==="number"?n+e.length:this.writeOffset);return this}readBuffer(e){if(typeof e!=="undefined"){s.checkLengthValue(e)}const n=typeof e==="number"?e:this.length;const r=Math.min(this.length,this._readOffset+n);const i=this._buff.slice(this._readOffset,r);this._readOffset=r;return i}insertBuffer(e,n){s.checkOffsetValue(n);return this._handleBuffer(e,true,n)}writeBuffer(e,n){return this._handleBuffer(e,false,n)}readBufferNT(){let e=this.length;for(let n=this._readOffset;n<this.length;n++){if(this._buff[n]===0){e=n;break}}const n=this._buff.slice(this._readOffset,e);this._readOffset=e+1;return n}insertBufferNT(e,n){s.checkOffsetValue(n);this.insertBuffer(e,n);this.insertUInt8(0,n+e.length);return this}writeBufferNT(e,n){if(typeof n!=="undefined"){s.checkOffsetValue(n)}this.writeBuffer(e,n);this.writeUInt8(0,typeof n==="number"?n+e.length:this._writeOffset);return this}clear(){this._writeOffset=0;this._readOffset=0;this.length=0;return this}remaining(){return this.length-this._readOffset}get readOffset(){return this._readOffset}set readOffset(e){s.checkOffsetValue(e);s.checkTargetOffset(e,this);this._readOffset=e}get writeOffset(){return this._writeOffset}set writeOffset(e){s.checkOffsetValue(e);s.checkTargetOffset(e,this);this._writeOffset=e}get encoding(){return this._encoding}set encoding(e){s.checkEncoding(e);this._encoding=e}get internalBuffer(){return this._buff}toBuffer(){return this._buff.slice(0,this.length)}toString(e){const n=typeof e==="string"?e:this._encoding;s.checkEncoding(n);return this._buff.toString(n,0,this.length)}destroy(){this.clear();return this}_handleString(e,n,r,i){let f=this._writeOffset;let l=this._encoding;if(typeof r==="number"){f=r}else if(typeof r==="string"){s.checkEncoding(r);l=r}if(typeof i==="string"){s.checkEncoding(i);l=i}const t=Buffer.byteLength(e,l);if(n){this.ensureInsertable(t,f)}else{this._ensureWriteable(t,f)}this._buff.write(e,f,t,l);if(n){this._writeOffset+=t}else{if(typeof r==="number"){this._writeOffset=Math.max(this._writeOffset,f+t)}else{this._writeOffset+=t}}return this}_handleBuffer(e,n,r){const s=typeof r==="number"?r:this._writeOffset;if(n){this.ensureInsertable(e.length,s)}else{this._ensureWriteable(e.length,s)}e.copy(this._buff,s);if(n){this._writeOffset+=e.length}else{if(typeof r==="number"){this._writeOffset=Math.max(this._writeOffset,s+e.length)}else{this._writeOffset+=e.length}}return this}ensureReadable(e,n){let r=this._readOffset;if(typeof n!=="undefined"){s.checkOffsetValue(n);r=n}if(r<0||r+e>this.length){throw new Error(s.ERRORS.INVALID_READ_BEYOND_BOUNDS)}}ensureInsertable(e,n){s.checkOffsetValue(n);this._ensureCapacity(this.length+e);if(n<this.length){this._buff.copy(this._buff,n+e,n,this._buff.length)}if(n+e>this.length){this.length=n+e}else{this.length+=e}}_ensureWriteable(e,n){const r=typeof n==="number"?n:this._writeOffset;this._ensureCapacity(r+e);if(r+e>this.length){this.length=r+e}}_ensureCapacity(e){const n=this._buff.length;if(e>n){let r=this._buff;let s=n*3/2+1;if(s<e){s=e}this._buff=Buffer.allocUnsafe(s);r.copy(this._buff,0,0,n)}}_readNumberValue(e,n,r){this.ensureReadable(n,r);const s=e.call(this._buff,typeof r==="number"?r:this._readOffset);if(typeof r==="undefined"){this._readOffset+=n}return s}_insertNumberValue(e,n,r,i){s.checkOffsetValue(i);this.ensureInsertable(n,i);e.call(this._buff,r,i);this._writeOffset+=n;return this}_writeNumberValue(e,n,r,i){if(typeof i==="number"){if(i<0){throw new Error(s.ERRORS.INVALID_WRITE_BEYOND_BOUNDS)}s.checkOffsetValue(i)}const f=typeof i==="number"?i:this._writeOffset;this._ensureWriteable(n,f);e.call(this._buff,r,f);if(typeof i==="number"){this._writeOffset=Math.max(this._writeOffset,f+n)}else{this._writeOffset+=n}return this}}n.SmartBuffer=SmartBuffer},7008:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});const s=r(4293);const i={INVALID_ENCODING:"Invalid encoding provided. Please specify a valid encoding the internal Node.js Buffer supports.",INVALID_SMARTBUFFER_SIZE:"Invalid size provided. Size must be a valid integer greater than zero.",INVALID_SMARTBUFFER_BUFFER:"Invalid Buffer provided in SmartBufferOptions.",INVALID_SMARTBUFFER_OBJECT:"Invalid SmartBufferOptions object supplied to SmartBuffer constructor or factory methods.",INVALID_OFFSET:"An invalid offset value was provided.",INVALID_OFFSET_NON_NUMBER:"An invalid offset value was provided. A numeric value is required.",INVALID_LENGTH:"An invalid length value was provided.",INVALID_LENGTH_NON_NUMBER:"An invalid length value was provived. A numeric value is required.",INVALID_TARGET_OFFSET:"Target offset is beyond the bounds of the internal SmartBuffer data.",INVALID_TARGET_LENGTH:"Specified length value moves cursor beyong the bounds of the internal SmartBuffer data.",INVALID_READ_BEYOND_BOUNDS:"Attempted to read beyond the bounds of the managed data.",INVALID_WRITE_BEYOND_BOUNDS:"Attempted to write beyond the bounds of the managed data."};n.ERRORS=i;function checkEncoding(e){if(!s.Buffer.isEncoding(e)){throw new Error(i.INVALID_ENCODING)}}n.checkEncoding=checkEncoding;function isFiniteInteger(e){return typeof e==="number"&&isFinite(e)&&isInteger(e)}n.isFiniteInteger=isFiniteInteger;function checkOffsetOrLengthValue(e,n){if(typeof e==="number"){if(!isFiniteInteger(e)||e<0){throw new Error(n?i.INVALID_OFFSET:i.INVALID_LENGTH)}}else{throw new Error(n?i.INVALID_OFFSET_NON_NUMBER:i.INVALID_LENGTH_NON_NUMBER)}}function checkLengthValue(e){checkOffsetOrLengthValue(e,false)}n.checkLengthValue=checkLengthValue;function checkOffsetValue(e){checkOffsetOrLengthValue(e,true)}n.checkOffsetValue=checkOffsetValue;function checkTargetOffset(e,n){if(e<0||e>n.length){throw new Error(i.INVALID_TARGET_OFFSET)}}n.checkTargetOffset=checkTargetOffset;function isInteger(e){return typeof e==="number"&&isFinite(e)&&Math.floor(e)===e}function bigIntAndBufferInt64Check(e){if(typeof BigInt==="undefined"){throw new Error("Platform does not support JS BigInt type.")}if(typeof s.Buffer.prototype[e]==="undefined"){throw new Error(`Platform does not support Buffer.prototype.${e}.`)}}n.bigIntAndBufferInt64Check=bigIntAndBufferInt64Check},2019:function(e,n,r){"use strict";var s=this&&this.__awaiter||function(e,n,r,s){function adopt(e){return e instanceof r?e:new r(function(n){n(e)})}return new(r||(r=Promise))(function(r,i){function fulfilled(e){try{step(s.next(e))}catch(e){i(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,n||[])).next())})};var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:true});const f=i(r(881));const l=i(r(4016));const t=i(r(8835));const o=i(r(6782));const c=r(44);const a=r(8128);const d=o.default("socks-proxy-agent");function dnsLookup(e){return new Promise((n,r)=>{f.default.lookup(e,(e,s)=>{if(e){r(e)}else{n(s)}})})}function parseSocksProxy(e){let n=0;let r=false;let s=5;const i=e.hostname||e.host;if(!i){throw new TypeError('No "host"')}if(typeof e.port==="number"){n=e.port}else if(typeof e.port==="string"){n=parseInt(e.port,10)}if(!n){n=1080}if(e.protocol){switch(e.protocol.replace(":","")){case"socks4":r=true;case"socks4a":s=4;break;case"socks5":r=true;case"socks":case"socks5h":s=5;break;default:throw new TypeError(`A "socks" protocol must be specified! Got: ${e.protocol}`)}}if(typeof e.type!=="undefined"){if(e.type===4||e.type===5){s=e.type}else{throw new TypeError(`"type" must be 4 or 5, got: ${e.type}`)}}const f={host:i,port:n,type:s};let l=e.userId||e.username;let t=e.password;if(e.auth){const n=e.auth.split(":");l=n[0];t=n[1]}if(l){Object.defineProperty(f,"userId",{value:l,enumerable:false})}if(t){Object.defineProperty(f,"password",{value:t,enumerable:false})}return{lookup:r,proxy:f}}class SocksProxyAgent extends c.Agent{constructor(e){let n;if(typeof e==="string"){n=t.default.parse(e)}else{n=e}if(!n){throw new TypeError("a SOCKS proxy server `host` and `port` must be specified!")}super(n);const r=parseSocksProxy(n);this.lookup=r.lookup;this.proxy=r.proxy;this.tlsConnectionOptions=n.tls||{}}callback(e,n){return s(this,void 0,void 0,function*(){const{lookup:e,proxy:r}=this;let{host:s,port:i,timeout:f}=n;if(!s){throw new Error("No `host` defined!")}if(e){s=yield dnsLookup(s)}const t={proxy:r,destination:{host:s,port:i},command:"connect",timeout:f};d("Creating socks proxy connection: %o",t);const{socket:o}=yield a.SocksClient.createConnection(t);d("Successfully created socks proxy connection");if(n.secureEndpoint){d("Upgrading socket connection to TLS");const e=n.servername||n.host;return l.default.connect(Object.assign(Object.assign(Object.assign({},omit(n,"host","hostname","path","port")),{socket:o,servername:e}),this.tlsConnectionOptions))}return o})}}n.default=SocksProxyAgent;function omit(e,...n){const r={};let s;for(s in e){if(!n.includes(s)){r[s]=e[s]}}return r}},7039:function(e,n,r){"use strict";var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};const i=s(r(2019));function createSocksProxyAgent(e){return new i.default(e)}(function(e){e.SocksProxyAgent=i.default;e.prototype=i.default.prototype})(createSocksProxyAgent||(createSocksProxyAgent={}));e.exports=createSocksProxyAgent},8821:function(e,n,r){"use strict";var s=this&&this.__awaiter||function(e,n,r,s){function adopt(e){return e instanceof r?e:new r(function(n){n(e)})}return new(r||(r=Promise))(function(r,i){function fulfilled(e){try{step(s.next(e))}catch(e){i(e)}}function rejected(e){try{step(s["throw"](e))}catch(e){i(e)}}function step(e){e.done?r(e.value):adopt(e.value).then(fulfilled,rejected)}step((s=s.apply(e,n||[])).next())})};Object.defineProperty(n,"__esModule",{value:true});n.SocksClientError=n.SocksClient=void 0;const i=r(8614);const f=r(1631);const l=r(5316);const t=r(2313);const o=r(8105);const c=r(6113);const a=r(8888);const d=r(2864);Object.defineProperty(n,"SocksClientError",{enumerable:true,get:function(){return d.SocksClientError}});class SocksClient extends i.EventEmitter{constructor(e){super();this.options=Object.assign({},e);(0,c.validateSocksClientOptions)(e);this.setState(o.SocksClientState.Created)}static createConnection(e,n){return new Promise((r,s)=>{try{(0,c.validateSocksClientOptions)(e,["connect"])}catch(e){if(typeof n==="function"){n(e);return r(e)}else{return s(e)}}const i=new SocksClient(e);i.connect(e.existing_socket);i.once("established",e=>{i.removeAllListeners();if(typeof n==="function"){n(null,e);r(e)}else{r(e)}});i.once("error",e=>{i.removeAllListeners();if(typeof n==="function"){n(e);r(e)}else{s(e)}})})}static createConnectionChain(e,n){return new Promise((r,i)=>s(this,void 0,void 0,function*(){try{(0,c.validateSocksClientChainOptions)(e)}catch(e){if(typeof n==="function"){n(e);return r(e)}else{return i(e)}}let s;if(e.randomizeChain){(0,d.shuffleArray)(e.proxies)}try{for(let n=0;n<e.proxies.length;n++){const r=e.proxies[n];const i=n===e.proxies.length-1?e.destination:{host:e.proxies[n+1].host||e.proxies[n+1].ipaddress,port:e.proxies[n+1].port};const f=yield SocksClient.createConnection({command:"connect",proxy:r,destination:i});if(!s){s=f.socket}}if(typeof n==="function"){n(null,{socket:s});r({socket:s})}else{r({socket:s})}}catch(e){if(typeof n==="function"){n(e);r(e)}else{i(e)}}}))}static createUDPFrame(e){const n=new t.SmartBuffer;n.writeUInt16BE(0);n.writeUInt8(e.frameNumber||0);if(f.isIPv4(e.remoteHost.host)){n.writeUInt8(o.Socks5HostType.IPv4);n.writeUInt32BE(l.toLong(e.remoteHost.host))}else if(f.isIPv6(e.remoteHost.host)){n.writeUInt8(o.Socks5HostType.IPv6);n.writeBuffer(l.toBuffer(e.remoteHost.host))}else{n.writeUInt8(o.Socks5HostType.Hostname);n.writeUInt8(Buffer.byteLength(e.remoteHost.host));n.writeString(e.remoteHost.host)}n.writeUInt16BE(e.remoteHost.port);n.writeBuffer(e.data);return n.toBuffer()}static parseUDPFrame(e){const n=t.SmartBuffer.fromBuffer(e);n.readOffset=2;const r=n.readUInt8();const s=n.readUInt8();let i;if(s===o.Socks5HostType.IPv4){i=l.fromLong(n.readUInt32BE())}else if(s===o.Socks5HostType.IPv6){i=l.toString(n.readBuffer(16))}else{i=n.readString(n.readUInt8())}const f=n.readUInt16BE();return{frameNumber:r,remoteHost:{host:i,port:f},data:n.readBuffer()}}setState(e){if(this.state!==o.SocksClientState.Error){this.state=e}}connect(e){this.onDataReceived=(e=>this.onDataReceivedHandler(e));this.onClose=(()=>this.onCloseHandler());this.onError=(e=>this.onErrorHandler(e));this.onConnect=(()=>this.onConnectHandler());const n=setTimeout(()=>this.onEstablishedTimeout(),this.options.timeout||o.DEFAULT_TIMEOUT);if(n.unref&&typeof n.unref==="function"){n.unref()}if(e){this.socket=e}else{this.socket=new f.Socket}this.socket.once("close",this.onClose);this.socket.once("error",this.onError);this.socket.once("connect",this.onConnect);this.socket.on("data",this.onDataReceived);this.setState(o.SocksClientState.Connecting);this.receiveBuffer=new a.ReceiveBuffer;if(e){this.socket.emit("connect")}else{this.socket.connect(this.getSocketOptions());if(this.options.set_tcp_nodelay!==undefined&&this.options.set_tcp_nodelay!==null){this.socket.setNoDelay(!!this.options.set_tcp_nodelay)}}this.prependOnceListener("established",e=>{setImmediate(()=>{if(this.receiveBuffer.length>0){const n=this.receiveBuffer.get(this.receiveBuffer.length);e.socket.emit("data",n)}e.socket.resume()})})}getSocketOptions(){return Object.assign(Object.assign({},this.options.socket_options),{host:this.options.proxy.host||this.options.proxy.ipaddress,port:this.options.proxy.port})}onEstablishedTimeout(){if(this.state!==o.SocksClientState.Established&&this.state!==o.SocksClientState.BoundWaitingForConnection){this.closeSocket(o.ERRORS.ProxyConnectionTimedOut)}}onConnectHandler(){this.setState(o.SocksClientState.Connected);if(this.options.proxy.type===4){this.sendSocks4InitialHandshake()}else{this.sendSocks5InitialHandshake()}this.setState(o.SocksClientState.SentInitialHandshake)}onDataReceivedHandler(e){this.receiveBuffer.append(e);this.processData()}processData(){while(this.state!==o.SocksClientState.Established&&this.state!==o.SocksClientState.Error&&this.receiveBuffer.length>=this.nextRequiredPacketBufferSize){if(this.state===o.SocksClientState.SentInitialHandshake){if(this.options.proxy.type===4){this.handleSocks4FinalHandshakeResponse()}else{this.handleInitialSocks5HandshakeResponse()}}else if(this.state===o.SocksClientState.SentAuthentication){this.handleInitialSocks5AuthenticationHandshakeResponse()}else if(this.state===o.SocksClientState.SentFinalHandshake){this.handleSocks5FinalHandshakeResponse()}else if(this.state===o.SocksClientState.BoundWaitingForConnection){if(this.options.proxy.type===4){this.handleSocks4IncomingConnectionResponse()}else{this.handleSocks5IncomingConnectionResponse()}}else{this.closeSocket(o.ERRORS.InternalError);break}}}onCloseHandler(){this.closeSocket(o.ERRORS.SocketClosed)}onErrorHandler(e){this.closeSocket(e.message)}removeInternalSocketHandlers(){this.socket.pause();this.socket.removeListener("data",this.onDataReceived);this.socket.removeListener("close",this.onClose);this.socket.removeListener("error",this.onError);this.socket.removeListener("connect",this.onConnect)}closeSocket(e){if(this.state!==o.SocksClientState.Error){this.setState(o.SocksClientState.Error);this.socket.destroy();this.removeInternalSocketHandlers();this.emit("error",new d.SocksClientError(e,this.options))}}sendSocks4InitialHandshake(){const e=this.options.proxy.userId||"";const n=new t.SmartBuffer;n.writeUInt8(4);n.writeUInt8(o.SocksCommand[this.options.command]);n.writeUInt16BE(this.options.destination.port);if(f.isIPv4(this.options.destination.host)){n.writeBuffer(l.toBuffer(this.options.destination.host));n.writeStringNT(e)}else{n.writeUInt8(0);n.writeUInt8(0);n.writeUInt8(0);n.writeUInt8(1);n.writeStringNT(e);n.writeStringNT(this.options.destination.host)}this.nextRequiredPacketBufferSize=o.SOCKS_INCOMING_PACKET_SIZES.Socks4Response;this.socket.write(n.toBuffer())}handleSocks4FinalHandshakeResponse(){const e=this.receiveBuffer.get(8);if(e[1]!==o.Socks4Response.Granted){this.closeSocket(`${o.ERRORS.Socks4ProxyRejectedConnection} - (${o.Socks4Response[e[1]]})`)}else{if(o.SocksCommand[this.options.command]===o.SocksCommand.bind){const n=t.SmartBuffer.fromBuffer(e);n.readOffset=2;const r={port:n.readUInt16BE(),host:l.fromLong(n.readUInt32BE())};if(r.host==="0.0.0.0"){r.host=this.options.proxy.ipaddress}this.setState(o.SocksClientState.BoundWaitingForConnection);this.emit("bound",{remoteHost:r,socket:this.socket})}else{this.setState(o.SocksClientState.Established);this.removeInternalSocketHandlers();this.emit("established",{socket:this.socket})}}}handleSocks4IncomingConnectionResponse(){const e=this.receiveBuffer.get(8);if(e[1]!==o.Socks4Response.Granted){this.closeSocket(`${o.ERRORS.Socks4ProxyRejectedIncomingBoundConnection} - (${o.Socks4Response[e[1]]})`)}else{const n=t.SmartBuffer.fromBuffer(e);n.readOffset=2;const r={port:n.readUInt16BE(),host:l.fromLong(n.readUInt32BE())};this.setState(o.SocksClientState.Established);this.removeInternalSocketHandlers();this.emit("established",{remoteHost:r,socket:this.socket})}}sendSocks5InitialHandshake(){const e=new t.SmartBuffer;const n=[o.Socks5Auth.NoAuth];if(this.options.proxy.userId||this.options.proxy.password){n.push(o.Socks5Auth.UserPass)}if(this.options.proxy.custom_auth_method!==undefined){n.push(this.options.proxy.custom_auth_method)}e.writeUInt8(5);e.writeUInt8(n.length);for(const r of n){e.writeUInt8(r)}this.nextRequiredPacketBufferSize=o.SOCKS_INCOMING_PACKET_SIZES.Socks5InitialHandshakeResponse;this.socket.write(e.toBuffer());this.setState(o.SocksClientState.SentInitialHandshake)}handleInitialSocks5HandshakeResponse(){const e=this.receiveBuffer.get(2);if(e[0]!==5){this.closeSocket(o.ERRORS.InvalidSocks5IntiailHandshakeSocksVersion)}else if(e[1]===o.SOCKS5_NO_ACCEPTABLE_AUTH){this.closeSocket(o.ERRORS.InvalidSocks5InitialHandshakeNoAcceptedAuthType)}else{if(e[1]===o.Socks5Auth.NoAuth){this.socks5ChosenAuthType=o.Socks5Auth.NoAuth;this.sendSocks5CommandRequest()}else if(e[1]===o.Socks5Auth.UserPass){this.socks5ChosenAuthType=o.Socks5Auth.UserPass;this.sendSocks5UserPassAuthentication()}else if(e[1]===this.options.proxy.custom_auth_method){this.socks5ChosenAuthType=this.options.proxy.custom_auth_method;this.sendSocks5CustomAuthentication()}else{this.closeSocket(o.ERRORS.InvalidSocks5InitialHandshakeUnknownAuthType)}}}sendSocks5UserPassAuthentication(){const e=this.options.proxy.userId||"";const n=this.options.proxy.password||"";const r=new t.SmartBuffer;r.writeUInt8(1);r.writeUInt8(Buffer.byteLength(e));r.writeString(e);r.writeUInt8(Buffer.byteLength(n));r.writeString(n);this.nextRequiredPacketBufferSize=o.SOCKS_INCOMING_PACKET_SIZES.Socks5UserPassAuthenticationResponse;this.socket.write(r.toBuffer());this.setState(o.SocksClientState.SentAuthentication)}sendSocks5CustomAuthentication(){return s(this,void 0,void 0,function*(){this.nextRequiredPacketBufferSize=this.options.proxy.custom_auth_response_size;this.socket.write(yield this.options.proxy.custom_auth_request_handler());this.setState(o.SocksClientState.SentAuthentication)})}handleSocks5CustomAuthHandshakeResponse(e){return s(this,void 0,void 0,function*(){return yield this.options.proxy.custom_auth_response_handler(e)})}handleSocks5AuthenticationNoAuthHandshakeResponse(e){return s(this,void 0,void 0,function*(){return e[1]===0})}handleSocks5AuthenticationUserPassHandshakeResponse(e){return s(this,void 0,void 0,function*(){return e[1]===0})}handleInitialSocks5AuthenticationHandshakeResponse(){return s(this,void 0,void 0,function*(){this.setState(o.SocksClientState.ReceivedAuthenticationResponse);let e=false;if(this.socks5ChosenAuthType===o.Socks5Auth.NoAuth){e=yield this.handleSocks5AuthenticationNoAuthHandshakeResponse(this.receiveBuffer.get(2))}else if(this.socks5ChosenAuthType===o.Socks5Auth.UserPass){e=yield this.handleSocks5AuthenticationUserPassHandshakeResponse(this.receiveBuffer.get(2))}else if(this.socks5ChosenAuthType===this.options.proxy.custom_auth_method){e=yield this.handleSocks5CustomAuthHandshakeResponse(this.receiveBuffer.get(this.options.proxy.custom_auth_response_size))}if(!e){this.closeSocket(o.ERRORS.Socks5AuthenticationFailed)}else{this.sendSocks5CommandRequest()}})}sendSocks5CommandRequest(){const e=new t.SmartBuffer;e.writeUInt8(5);e.writeUInt8(o.SocksCommand[this.options.command]);e.writeUInt8(0);if(f.isIPv4(this.options.destination.host)){e.writeUInt8(o.Socks5HostType.IPv4);e.writeBuffer(l.toBuffer(this.options.destination.host))}else if(f.isIPv6(this.options.destination.host)){e.writeUInt8(o.Socks5HostType.IPv6);e.writeBuffer(l.toBuffer(this.options.destination.host))}else{e.writeUInt8(o.Socks5HostType.Hostname);e.writeUInt8(this.options.destination.host.length);e.writeString(this.options.destination.host)}e.writeUInt16BE(this.options.destination.port);this.nextRequiredPacketBufferSize=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseHeader;this.socket.write(e.toBuffer());this.setState(o.SocksClientState.SentFinalHandshake)}handleSocks5FinalHandshakeResponse(){const e=this.receiveBuffer.peek(5);if(e[0]!==5||e[1]!==o.Socks5Response.Granted){this.closeSocket(`${o.ERRORS.InvalidSocks5FinalHandshakeRejected} - ${o.Socks5Response[e[1]]}`)}else{const n=e[3];let r;let s;if(n===o.Socks5HostType.IPv4){const e=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseIPv4;if(this.receiveBuffer.length<e){this.nextRequiredPacketBufferSize=e;return}s=t.SmartBuffer.fromBuffer(this.receiveBuffer.get(e).slice(4));r={host:l.fromLong(s.readUInt32BE()),port:s.readUInt16BE()};if(r.host==="0.0.0.0"){r.host=this.options.proxy.ipaddress}}else if(n===o.Socks5HostType.Hostname){const n=e[4];const i=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseHostname(n);if(this.receiveBuffer.length<i){this.nextRequiredPacketBufferSize=i;return}s=t.SmartBuffer.fromBuffer(this.receiveBuffer.get(i).slice(5));r={host:s.readString(n),port:s.readUInt16BE()}}else if(n===o.Socks5HostType.IPv6){const e=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseIPv6;if(this.receiveBuffer.length<e){this.nextRequiredPacketBufferSize=e;return}s=t.SmartBuffer.fromBuffer(this.receiveBuffer.get(e).slice(4));r={host:l.toString(s.readBuffer(16)),port:s.readUInt16BE()}}this.setState(o.SocksClientState.ReceivedFinalResponse);if(o.SocksCommand[this.options.command]===o.SocksCommand.connect){this.setState(o.SocksClientState.Established);this.removeInternalSocketHandlers();this.emit("established",{remoteHost:r,socket:this.socket})}else if(o.SocksCommand[this.options.command]===o.SocksCommand.bind){this.setState(o.SocksClientState.BoundWaitingForConnection);this.nextRequiredPacketBufferSize=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseHeader;this.emit("bound",{remoteHost:r,socket:this.socket})}else if(o.SocksCommand[this.options.command]===o.SocksCommand.associate){this.setState(o.SocksClientState.Established);this.removeInternalSocketHandlers();this.emit("established",{remoteHost:r,socket:this.socket})}}}handleSocks5IncomingConnectionResponse(){const e=this.receiveBuffer.peek(5);if(e[0]!==5||e[1]!==o.Socks5Response.Granted){this.closeSocket(`${o.ERRORS.Socks5ProxyRejectedIncomingBoundConnection} - ${o.Socks5Response[e[1]]}`)}else{const n=e[3];let r;let s;if(n===o.Socks5HostType.IPv4){const e=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseIPv4;if(this.receiveBuffer.length<e){this.nextRequiredPacketBufferSize=e;return}s=t.SmartBuffer.fromBuffer(this.receiveBuffer.get(e).slice(4));r={host:l.fromLong(s.readUInt32BE()),port:s.readUInt16BE()};if(r.host==="0.0.0.0"){r.host=this.options.proxy.ipaddress}}else if(n===o.Socks5HostType.Hostname){const n=e[4];const i=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseHostname(n);if(this.receiveBuffer.length<i){this.nextRequiredPacketBufferSize=i;return}s=t.SmartBuffer.fromBuffer(this.receiveBuffer.get(i).slice(5));r={host:s.readString(n),port:s.readUInt16BE()}}else if(n===o.Socks5HostType.IPv6){const e=o.SOCKS_INCOMING_PACKET_SIZES.Socks5ResponseIPv6;if(this.receiveBuffer.length<e){this.nextRequiredPacketBufferSize=e;return}s=t.SmartBuffer.fromBuffer(this.receiveBuffer.get(e).slice(4));r={host:l.toString(s.readBuffer(16)),port:s.readUInt16BE()}}this.setState(o.SocksClientState.Established);this.removeInternalSocketHandlers();this.emit("established",{remoteHost:r,socket:this.socket})}}get socksClientOptions(){return Object.assign({},this.options)}}n.SocksClient=SocksClient},8105:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.SOCKS5_NO_ACCEPTABLE_AUTH=n.SOCKS5_CUSTOM_AUTH_END=n.SOCKS5_CUSTOM_AUTH_START=n.SOCKS_INCOMING_PACKET_SIZES=n.SocksClientState=n.Socks5Response=n.Socks5HostType=n.Socks5Auth=n.Socks4Response=n.SocksCommand=n.ERRORS=n.DEFAULT_TIMEOUT=void 0;const r=3e4;n.DEFAULT_TIMEOUT=r;const s={InvalidSocksCommand:"An invalid SOCKS command was provided. Valid options are connect, bind, and associate.",InvalidSocksCommandForOperation:"An invalid SOCKS command was provided. Only a subset of commands are supported for this operation.",InvalidSocksCommandChain:"An invalid SOCKS command was provided. Chaining currently only supports the connect command.",InvalidSocksClientOptionsDestination:"An invalid destination host was provided.",InvalidSocksClientOptionsExistingSocket:"An invalid existing socket was provided. This should be an instance of stream.Duplex.",InvalidSocksClientOptionsProxy:"Invalid SOCKS proxy details were provided.",InvalidSocksClientOptionsTimeout:"An invalid timeout value was provided. Please enter a value above 0 (in ms).",InvalidSocksClientOptionsProxiesLength:"At least two socks proxies must be provided for chaining.",InvalidSocksClientOptionsCustomAuthRange:"Custom auth must be a value between 0x80 and 0xFE.",InvalidSocksClientOptionsCustomAuthOptions:"When a custom_auth_method is provided, custom_auth_request_handler, custom_auth_response_size, and custom_auth_response_handler must also be provided and valid.",NegotiationError:"Negotiation error",SocketClosed:"Socket closed",ProxyConnectionTimedOut:"Proxy connection timed out",InternalError:"SocksClient internal error (this should not happen)",InvalidSocks4HandshakeResponse:"Received invalid Socks4 handshake response",Socks4ProxyRejectedConnection:"Socks4 Proxy rejected connection",InvalidSocks4IncomingConnectionResponse:"Socks4 invalid incoming connection response",Socks4ProxyRejectedIncomingBoundConnection:"Socks4 Proxy rejected incoming bound connection",InvalidSocks5InitialHandshakeResponse:"Received invalid Socks5 initial handshake response",InvalidSocks5IntiailHandshakeSocksVersion:"Received invalid Socks5 initial handshake (invalid socks version)",InvalidSocks5InitialHandshakeNoAcceptedAuthType:"Received invalid Socks5 initial handshake (no accepted authentication type)",InvalidSocks5InitialHandshakeUnknownAuthType:"Received invalid Socks5 initial handshake (unknown authentication type)",Socks5AuthenticationFailed:"Socks5 Authentication failed",InvalidSocks5FinalHandshake:"Received invalid Socks5 final handshake response",InvalidSocks5FinalHandshakeRejected:"Socks5 proxy rejected connection",InvalidSocks5IncomingConnectionResponse:"Received invalid Socks5 incoming connection response",Socks5ProxyRejectedIncomingBoundConnection:"Socks5 Proxy rejected incoming bound connection"};n.ERRORS=s;const i={Socks5InitialHandshakeResponse:2,Socks5UserPassAuthenticationResponse:2,Socks5ResponseHeader:5,Socks5ResponseIPv4:10,Socks5ResponseIPv6:22,Socks5ResponseHostname:e=>e+7,Socks4Response:8};n.SOCKS_INCOMING_PACKET_SIZES=i;var f;(function(e){e[e["connect"]=1]="connect";e[e["bind"]=2]="bind";e[e["associate"]=3]="associate"})(f||(f={}));n.SocksCommand=f;var l;(function(e){e[e["Granted"]=90]="Granted";e[e["Failed"]=91]="Failed";e[e["Rejected"]=92]="Rejected";e[e["RejectedIdent"]=93]="RejectedIdent"})(l||(l={}));n.Socks4Response=l;var t;(function(e){e[e["NoAuth"]=0]="NoAuth";e[e["GSSApi"]=1]="GSSApi";e[e["UserPass"]=2]="UserPass"})(t||(t={}));n.Socks5Auth=t;const o=128;n.SOCKS5_CUSTOM_AUTH_START=o;const c=254;n.SOCKS5_CUSTOM_AUTH_END=c;const a=255;n.SOCKS5_NO_ACCEPTABLE_AUTH=a;var d;(function(e){e[e["Granted"]=0]="Granted";e[e["Failure"]=1]="Failure";e[e["NotAllowed"]=2]="NotAllowed";e[e["NetworkUnreachable"]=3]="NetworkUnreachable";e[e["HostUnreachable"]=4]="HostUnreachable";e[e["ConnectionRefused"]=5]="ConnectionRefused";e[e["TTLExpired"]=6]="TTLExpired";e[e["CommandNotSupported"]=7]="CommandNotSupported";e[e["AddressNotSupported"]=8]="AddressNotSupported"})(d||(d={}));n.Socks5Response=d;var p;(function(e){e[e["IPv4"]=1]="IPv4";e[e["Hostname"]=3]="Hostname";e[e["IPv6"]=4]="IPv6"})(p||(p={}));n.Socks5HostType=p;var u;(function(e){e[e["Created"]=0]="Created";e[e["Connecting"]=1]="Connecting";e[e["Connected"]=2]="Connected";e[e["SentInitialHandshake"]=3]="SentInitialHandshake";e[e["ReceivedInitialHandshakeResponse"]=4]="ReceivedInitialHandshakeResponse";e[e["SentAuthentication"]=5]="SentAuthentication";e[e["ReceivedAuthenticationResponse"]=6]="ReceivedAuthenticationResponse";e[e["SentFinalHandshake"]=7]="SentFinalHandshake";e[e["ReceivedFinalResponse"]=8]="ReceivedFinalResponse";e[e["BoundWaitingForConnection"]=9]="BoundWaitingForConnection";e[e["Established"]=10]="Established";e[e["Disconnected"]=11]="Disconnected";e[e["Error"]=99]="Error"})(u||(u={}));n.SocksClientState=u},6113:(e,n,r)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.validateSocksClientChainOptions=n.validateSocksClientOptions=void 0;const s=r(2864);const i=r(8105);const f=r(2413);function validateSocksClientOptions(e,n=["connect","bind","associate"]){if(!i.SocksCommand[e.command]){throw new s.SocksClientError(i.ERRORS.InvalidSocksCommand,e)}if(n.indexOf(e.command)===-1){throw new s.SocksClientError(i.ERRORS.InvalidSocksCommandForOperation,e)}if(!isValidSocksRemoteHost(e.destination)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsDestination,e)}if(!isValidSocksProxy(e.proxy)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsProxy,e)}validateCustomProxyAuth(e.proxy,e);if(e.timeout&&!isValidTimeoutValue(e.timeout)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsTimeout,e)}if(e.existing_socket&&!(e.existing_socket instanceof f.Duplex)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsExistingSocket,e)}}n.validateSocksClientOptions=validateSocksClientOptions;function validateSocksClientChainOptions(e){if(e.command!=="connect"){throw new s.SocksClientError(i.ERRORS.InvalidSocksCommandChain,e)}if(!isValidSocksRemoteHost(e.destination)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsDestination,e)}if(!(e.proxies&&Array.isArray(e.proxies)&&e.proxies.length>=2)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsProxiesLength,e)}e.proxies.forEach(n=>{if(!isValidSocksProxy(n)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsProxy,e)}validateCustomProxyAuth(n,e)});if(e.timeout&&!isValidTimeoutValue(e.timeout)){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsTimeout,e)}}n.validateSocksClientChainOptions=validateSocksClientChainOptions;function validateCustomProxyAuth(e,n){if(e.custom_auth_method!==undefined){if(e.custom_auth_method<i.SOCKS5_CUSTOM_AUTH_START||e.custom_auth_method>i.SOCKS5_CUSTOM_AUTH_END){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsCustomAuthRange,n)}if(e.custom_auth_request_handler===undefined||typeof e.custom_auth_request_handler!=="function"){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsCustomAuthOptions,n)}if(e.custom_auth_response_size===undefined){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsCustomAuthOptions,n)}if(e.custom_auth_response_handler===undefined||typeof e.custom_auth_response_handler!=="function"){throw new s.SocksClientError(i.ERRORS.InvalidSocksClientOptionsCustomAuthOptions,n)}}}function isValidSocksRemoteHost(e){return e&&typeof e.host==="string"&&typeof e.port==="number"&&e.port>=0&&e.port<=65535}function isValidSocksProxy(e){return e&&(typeof e.host==="string"||typeof e.ipaddress==="string")&&typeof e.port==="number"&&e.port>=0&&e.port<=65535&&(e.type===4||e.type===5)}function isValidTimeoutValue(e){return typeof e==="number"&&e>0}},8888:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.ReceiveBuffer=void 0;class ReceiveBuffer{constructor(e=4096){this.buffer=Buffer.allocUnsafe(e);this.offset=0;this.originalSize=e}get length(){return this.offset}append(e){if(!Buffer.isBuffer(e)){throw new Error("Attempted to append a non-buffer instance to ReceiveBuffer.")}if(this.offset+e.length>=this.buffer.length){const n=this.buffer;this.buffer=Buffer.allocUnsafe(Math.max(this.buffer.length+this.originalSize,this.buffer.length+e.length));n.copy(this.buffer)}e.copy(this.buffer,this.offset);return this.offset+=e.length}peek(e){if(e>this.offset){throw new Error("Attempted to read beyond the bounds of the managed internal data.")}return this.buffer.slice(0,e)}get(e){if(e>this.offset){throw new Error("Attempted to read beyond the bounds of the managed internal data.")}const n=Buffer.allocUnsafe(e);this.buffer.slice(0,e).copy(n);this.buffer.copyWithin(0,e,e+this.offset-e);this.offset-=e;return n}}n.ReceiveBuffer=ReceiveBuffer},2864:(e,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:true});n.shuffleArray=n.SocksClientError=void 0;class SocksClientError extends Error{constructor(e,n){super(e);this.options=n}}n.SocksClientError=SocksClientError;function shuffleArray(e){for(let n=e.length-1;n>0;n--){const r=Math.floor(Math.random()*(n+1));[e[n],e[r]]=[e[r],e[n]]}}n.shuffleArray=shuffleArray},8128:function(e,n,r){"use strict";var s=this&&this.__createBinding||(Object.create?function(e,n,r,s){if(s===undefined)s=r;Object.defineProperty(e,s,{enumerable:true,get:function(){return n[r]}})}:function(e,n,r,s){if(s===undefined)s=r;e[s]=n[r]});var i=this&&this.__exportStar||function(e,n){for(var r in e)if(r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r))s(n,e,r)};Object.defineProperty(n,"__esModule",{value:true});i(r(8821),n)},5844:(e,n,r)=>{"use strict";const{Transform:s}=r(3739);const{StringDecoder:i}=r(4304);const f=Symbol("last");const l=Symbol("decoder");function transform(e,n,r){var s;if(this.overflow){var i=this[l].write(e);s=i.split(this.matcher);if(s.length===1)return r();s.shift();this.overflow=false}else{this[f]+=this[l].write(e);s=this[f].split(this.matcher)}this[f]=s.pop();for(var t=0;t<s.length;t++){try{push(this,this.mapper(s[t]))}catch(e){return r(e)}}this.overflow=this[f].length>this.maxLength;if(this.overflow&&!this.skipOverflow)return r(new Error("maximum buffer reached"));r()}function flush(e){this[f]+=this[l].end();if(this[f]){try{push(this,this.mapper(this[f]))}catch(n){return e(n)}}e()}function push(e,n){if(n!==undefined){e.push(n)}}function noop(e){return e}function split(e,n,r){e=e||/\r?\n/;n=n||noop;r=r||{};switch(arguments.length){case 1:if(typeof e==="function"){n=e;e=/\r?\n/}else if(typeof e==="object"&&!(e instanceof RegExp)){r=e;e=/\r?\n/}break;case 2:if(typeof e==="function"){r=n;n=e;e=/\r?\n/}else if(typeof n==="object"){r=n;n=noop}}r=Object.assign({},r);r.transform=transform;r.flush=flush;r.readableObjectMode=true;const t=new s(r);t[f]="";t[l]=new i("utf8");t.matcher=e;t.mapper=n;t.maxLength=r.maxLength;t.skipOverflow=r.skipOverflow;t.overflow=false;return t}e.exports=split},6745:(e,n,r)=>{"use strict";var s=r(8414).Buffer;var i=s.isEncoding||function(e){e=""+e;switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return true;default:return false}};function _normalizeEncoding(e){if(!e)return"utf8";var n;while(true){switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(n)return;e=(""+e).toLowerCase();n=true}}}function normalizeEncoding(e){var n=_normalizeEncoding(e);if(typeof n!=="string"&&(s.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return n||e}n.s=StringDecoder;function StringDecoder(e){this.encoding=normalizeEncoding(e);var n;switch(this.encoding){case"utf16le":this.text=utf16Text;this.end=utf16End;n=4;break;case"utf8":this.fillLast=utf8FillLast;n=4;break;case"base64":this.text=base64Text;this.end=base64End;n=3;break;default:this.write=simpleWrite;this.end=simpleEnd;return}this.lastNeed=0;this.lastTotal=0;this.lastChar=s.allocUnsafe(n)}StringDecoder.prototype.write=function(e){if(e.length===0)return"";var n;var r;if(this.lastNeed){n=this.fillLast(e);if(n===undefined)return"";r=this.lastNeed;this.lastNeed=0}else{r=0}if(r<e.length)return n?n+this.text(e,r):this.text(e,r);return n||""};StringDecoder.prototype.end=utf8End;StringDecoder.prototype.text=utf8Text;StringDecoder.prototype.fillLast=function(e){if(this.lastNeed<=e.length){e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length);this.lastNeed-=e.length};function utf8CheckByte(e){if(e<=127)return 0;else if(e>>5===6)return 2;else if(e>>4===14)return 3;else if(e>>3===30)return 4;return e>>6===2?-1:-2}function utf8CheckIncomplete(e,n,r){var s=n.length-1;if(s<r)return 0;var i=utf8CheckByte(n[s]);if(i>=0){if(i>0)e.lastNeed=i-1;return i}if(--s<r||i===-2)return 0;i=utf8CheckByte(n[s]);if(i>=0){if(i>0)e.lastNeed=i-2;return i}if(--s<r||i===-2)return 0;i=utf8CheckByte(n[s]);if(i>=0){if(i>0){if(i===2)i=0;else e.lastNeed=i-3}return i}return 0}function utf8CheckExtraBytes(e,n,r){if((n[0]&192)!==128){e.lastNeed=0;return"<22>"}if(e.lastNeed>1&&n.length>1){if((n[1]&192)!==128){e.lastNeed=1;return"<22>"}if(e.lastNeed>2&&n.length>2){if((n[2]&192)!==128){e.lastNeed=2;return"<22>"}}}}function utf8FillLast(e){var n=this.lastTotal-this.lastNeed;var r=utf8CheckExtraBytes(this,e,n);if(r!==undefined)return r;if(this.lastNeed<=e.length){e.copy(this.lastChar,n,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,n,0,e.length);this.lastNeed-=e.length}function utf8Text(e,n){var r=utf8CheckIncomplete(this,e,n);if(!this.lastNeed)return e.toString("utf8",n);this.lastTotal=r;var s=e.length-(r-this.lastNeed);e.copy(this.lastChar,0,s);return e.toString("utf8",n,s)}function utf8End(e){var n=e&&e.length?this.write(e):"";if(this.lastNeed)return n+"<22>";return n}function utf16Text(e,n){if((e.length-n)%2===0){var r=e.toString("utf16le",n);if(r){var s=r.charCodeAt(r.length-1);if(s>=55296&&s<=56319){this.lastNeed=2;this.lastTotal=4;this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1];return r.slice(0,-1)}}return r}this.lastNeed=1;this.lastTotal=2;this.lastChar[0]=e[e.length-1];return e.toString("utf16le",n,e.length-1)}function utf16End(e){var n=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return n+this.lastChar.toString("utf16le",0,r)}return n}function base64Text(e,n){var r=(e.length-n)%3;if(r===0)return e.toString("base64",n);this.lastNeed=3-r;this.lastTotal=3;if(r===1){this.lastChar[0]=e[e.length-1]}else{this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1]}return e.toString("base64",n,e.length-r)}function base64End(e){var n=e&&e.length?this.write(e):"";if(this.lastNeed)return n+this.lastChar.toString("base64",0,3-this.lastNeed);return n}function simpleWrite(e){return e.toString(this.encoding)}function simpleEnd(e){return e&&e.length?this.write(e):""}},5585:(e,n,r)=>{const{Transform:s}=r(3739);function inherits(e,n){e.super_=n;e.prototype=Object.create(n.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}})}function through2(e){return(n,r,s)=>{if(typeof n==="function"){s=r;r=n;n={}}if(typeof r!=="function"){r=((e,n,r)=>r(null,e))}if(typeof s!=="function"){s=null}return e(n,r,s)}}const i=through2((e,n,r)=>{const i=new s(e);i._transform=n;if(r){i._flush=r}return i});const f=through2((e,n,r)=>{function Through2(i){if(!(this instanceof Through2)){return new Through2(i)}this.options=Object.assign({},e,i);s.call(this,this.options);this._transform=n;if(r){this._flush=r}}inherits(Through2,s);return Through2});const l=through2(function(e,n,r){const i=new s(Object.assign({objectMode:true,highWaterMark:16},e));i._transform=n;if(r){i._flush=r}return i});e.exports=i;e.exports.ctor=f;e.exports.obj=l},3695:(e,n,r)=>{e.exports=r(2584)},2584:(e,n,r)=>{"use strict";var s=r(1631);var i=r(4016);var f=r(8605);var l=r(7211);var t=r(8614);var o=r(2357);var c=r(1669);n.httpOverHttp=httpOverHttp;n.httpsOverHttp=httpsOverHttp;n.httpOverHttps=httpOverHttps;n.httpsOverHttps=httpsOverHttps;function httpOverHttp(e){var n=new TunnelingAgent(e);n.request=f.request;return n}function httpsOverHttp(e){var n=new TunnelingAgent(e);n.request=f.request;n.createSocket=createSecureSocket;n.defaultPort=443;return n}function httpOverHttps(e){var n=new TunnelingAgent(e);n.request=l.request;return n}function httpsOverHttps(e){var n=new TunnelingAgent(e);n.request=l.request;n.createSocket=createSecureSocket;n.defaultPort=443;return n}function TunnelingAgent(e){var n=this;n.options=e||{};n.proxyOptions=n.options.proxy||{};n.maxSockets=n.options.maxSockets||f.Agent.defaultMaxSockets;n.requests=[];n.sockets=[];n.on("free",function onFree(e,r,s,i){var f=toOptions(r,s,i);for(var l=0,t=n.requests.length;l<t;++l){var o=n.requests[l];if(o.host===f.host&&o.port===f.port){n.requests.splice(l,1);o.request.onSocket(e);return}}e.destroy();n.removeSocket(e)})}c.inherits(TunnelingAgent,t.EventEmitter);TunnelingAgent.prototype.addRequest=function addRequest(e,n,r,s){var i=this;var f=mergeOptions({request:e},i.options,toOptions(n,r,s));if(i.sockets.length>=this.maxSockets){i.requests.push(f);return}i.createSocket(f,function(n){n.on("free",onFree);n.on("close",onCloseOrRemove);n.on("agentRemove",onCloseOrRemove);e.onSocket(n);function onFree(){i.emit("free",n,f)}function onCloseOrRemove(e){i.removeSocket(n);n.removeListener("free",onFree);n.removeListener("close",onCloseOrRemove);n.removeListener("agentRemove",onCloseOrRemove)}})};TunnelingAgent.prototype.createSocket=function createSocket(e,n){var r=this;var s={};r.sockets.push(s);var i=mergeOptions({},r.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:false,headers:{host:e.host+":"+e.port}});if(e.localAddress){i.localAddress=e.localAddress}if(i.proxyAuth){i.headers=i.headers||{};i.headers["Proxy-Authorization"]="Basic "+new Buffer(i.proxyAuth).toString("base64")}a("making CONNECT request");var f=r.request(i);f.useChunkedEncodingByDefault=false;f.once("response",onResponse);f.once("upgrade",onUpgrade);f.once("connect",onConnect);f.once("error",onError);f.end();function onResponse(e){e.upgrade=true}function onUpgrade(e,n,r){process.nextTick(function(){onConnect(e,n,r)})}function onConnect(i,l,t){f.removeAllListeners();l.removeAllListeners();if(i.statusCode!==200){a("tunneling socket could not be established, statusCode=%d",i.statusCode);l.destroy();var o=new Error("tunneling socket could not be established, "+"statusCode="+i.statusCode);o.code="ECONNRESET";e.request.emit("error",o);r.removeSocket(s);return}if(t.length>0){a("got illegal response body from proxy");l.destroy();var o=new Error("got illegal response body from proxy");o.code="ECONNRESET";e.request.emit("error",o);r.removeSocket(s);return}a("tunneling connection has established");r.sockets[r.sockets.indexOf(s)]=l;return n(l)}function onError(n){f.removeAllListeners();a("tunneling socket could not be established, cause=%s\n",n.message,n.stack);var i=new Error("tunneling socket could not be established, "+"cause="+n.message);i.code="ECONNRESET";e.request.emit("error",i);r.removeSocket(s)}};TunnelingAgent.prototype.removeSocket=function removeSocket(e){var n=this.sockets.indexOf(e);if(n===-1){return}this.sockets.splice(n,1);var r=this.requests.shift();if(r){this.createSocket(r,function(e){r.request.onSocket(e)})}};function createSecureSocket(e,n){var r=this;TunnelingAgent.prototype.createSocket.call(r,e,function(s){var f=e.request.getHeader("host");var l=mergeOptions({},r.options,{socket:s,servername:f?f.replace(/:.*$/,""):e.host});var t=i.connect(0,l);r.sockets[r.sockets.indexOf(s)]=t;n(t)})}function toOptions(e,n,r){if(typeof e==="string"){return{host:e,port:n,localAddress:r}}return e}function mergeOptions(e){for(var n=1,r=arguments.length;n<r;++n){var s=arguments[n];if(typeof s==="object"){var i=Object.keys(s);for(var f=0,l=i.length;f<l;++f){var t=i[f];if(s[t]!==undefined){e[t]=s[t]}}}}return e}var a;if(process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)){a=function(){var e=Array.prototype.slice.call(arguments);if(typeof e[0]==="string"){e[0]="TUNNEL: "+e[0]}else{e.unshift("TUNNEL:")}console.error.apply(console,e)}}else{a=function(){}}n.debug=a},8522:(e,n)=>{"use strict";n.fromCallback=function(e){return Object.defineProperty(function(...n){if(typeof n[n.length-1]==="function")e.apply(this,n);else{return new Promise((r,s)=>{e.call(this,...n,(e,n)=>e!=null?s(e):r(n))})}},"name",{value:e.name})};n.fromPromise=function(e){return Object.defineProperty(function(...n){const r=n[n.length-1];if(typeof r!=="function")return e.apply(this,n);else e.apply(this,n.slice(0,-1)).then(e=>r(null,e),r)},"name",{value:e.name})}},3786:function(e,n){(function(e,r){true?r(n):0})(this,function(e){"use strict";function merge(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++){n[r]=arguments[r]}if(n.length>1){n[0]=n[0].slice(0,-1);var s=n.length-1;for(var i=1;i<s;++i){n[i]=n[i].slice(1,-1)}n[s]=n[s].slice(1);return n.join("")}else{return n[0]}}function subexp(e){return"(?:"+e+")"}function typeOf(e){return e===undefined?"undefined":e===null?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function toUpperCase(e){return e.toUpperCase()}function toArray(e){return e!==undefined&&e!==null?e instanceof Array?e:typeof e.length!=="number"||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}function assign(e,n){var r=e;if(n){for(var s in n){r[s]=n[s]}}return r}function buildExps(e){var n="[A-Za-z]",r="[\\x0D]",s="[0-9]",i="[\\x22]",f=merge(s,"[A-Fa-f]"),l="[\\x0A]",t="[\\x20]",o=subexp(subexp("%[EFef]"+f+"%"+f+f+"%"+f+f)+"|"+subexp("%[89A-Fa-f]"+f+"%"+f+f)+"|"+subexp("%"+f+f)),c="[\\:\\/\\?\\#\\[\\]\\@]",a="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",d=merge(c,a),p=e?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",u=e?"[\\uE000-\\uF8FF]":"[]",h=merge(n,s,"[\\-\\.\\_\\~]",p),v=subexp(n+merge(n,s,"[\\+\\-\\.]")+"*"),g=subexp(subexp(o+"|"+merge(h,a,"[\\:]"))+"*"),b=subexp(subexp("25[0-5]")+"|"+subexp("2[0-4]"+s)+"|"+subexp("1"+s+s)+"|"+subexp("[1-9]"+s)+"|"+s),w=subexp(subexp("25[0-5]")+"|"+subexp("2[0-4]"+s)+"|"+subexp("1"+s+s)+"|"+subexp("0?[1-9]"+s)+"|0?0?"+s),y=subexp(w+"\\."+w+"\\."+w+"\\."+w),m=subexp(f+"{1,4}"),E=subexp(subexp(m+"\\:"+m)+"|"+y),S=subexp(subexp(m+"\\:")+"{6}"+E),C=subexp("\\:\\:"+subexp(m+"\\:")+"{5}"+E),O=subexp(subexp(m)+"?\\:\\:"+subexp(m+"\\:")+"{4}"+E),A=subexp(subexp(subexp(m+"\\:")+"{0,1}"+m)+"?\\:\\:"+subexp(m+"\\:")+"{3}"+E),R=subexp(subexp(subexp(m+"\\:")+"{0,2}"+m)+"?\\:\\:"+subexp(m+"\\:")+"{2}"+E),k=subexp(subexp(subexp(m+"\\:")+"{0,3}"+m)+"?\\:\\:"+m+"\\:"+E),I=subexp(subexp(subexp(m+"\\:")+"{0,4}"+m)+"?\\:\\:"+E),T=subexp(subexp(subexp(m+"\\:")+"{0,5}"+m)+"?\\:\\:"+m),x=subexp(subexp(subexp(m+"\\:")+"{0,6}"+m)+"?\\:\\:"),F=subexp([S,C,O,A,R,k,I,T,x].join("|")),j=subexp(subexp(h+"|"+o)+"+"),B=subexp(F+"\\%25"+j),L=subexp(F+subexp("\\%25|\\%(?!"+f+"{2})")+j),M=subexp("[vV]"+f+"+\\."+merge(h,a,"[\\:]")+"+"),U=subexp("\\["+subexp(L+"|"+F+"|"+M)+"\\]"),D=subexp(subexp(o+"|"+merge(h,a))+"*"),N=subexp(U+"|"+y+"(?!"+D+")"+"|"+D),q=subexp(s+"*"),z=subexp(subexp(g+"@")+"?"+N+subexp("\\:"+q)+"?"),H=subexp(o+"|"+merge(h,a,"[\\:\\@]")),W=subexp(H+"*"),Y=subexp(H+"+"),G=subexp(subexp(o+"|"+merge(h,a,"[\\@]"))+"+"),Q=subexp(subexp("\\/"+W)+"*"),J=subexp("\\/"+subexp(Y+Q)+"?"),X=subexp(G+Q),Z=subexp(Y+Q),V="(?!"+H+")",K=subexp(Q+"|"+J+"|"+X+"|"+Z+"|"+V),P=subexp(subexp(H+"|"+merge("[\\/\\?]",u))+"*"),_=subexp(subexp(H+"|[\\/\\?]")+"*"),$=subexp(subexp("\\/\\/"+z+Q)+"|"+J+"|"+Z+"|"+V),ee=subexp(v+"\\:"+$+subexp("\\?"+P)+"?"+subexp("\\#"+_)+"?"),ne=subexp(subexp("\\/\\/"+z+Q)+"|"+J+"|"+X+"|"+V),re=subexp(ne+subexp("\\?"+P)+"?"+subexp("\\#"+_)+"?"),se=subexp(ee+"|"+re),ie=subexp(v+"\\:"+$+subexp("\\?"+P)+"?"),fe="^("+v+")\\:"+subexp(subexp("\\/\\/("+subexp("("+g+")@")+"?("+N+")"+subexp("\\:("+q+")")+"?)")+"?("+Q+"|"+J+"|"+Z+"|"+V+")")+subexp("\\?("+P+")")+"?"+subexp("\\#("+_+")")+"?$",le="^(){0}"+subexp(subexp("\\/\\/("+subexp("("+g+")@")+"?("+N+")"+subexp("\\:("+q+")")+"?)")+"?("+Q+"|"+J+"|"+X+"|"+V+")")+subexp("\\?("+P+")")+"?"+subexp("\\#("+_+")")+"?$",te="^("+v+")\\:"+subexp(subexp("\\/\\/("+subexp("("+g+")@")+"?("+N+")"+subexp("\\:("+q+")")+"?)")+"?("+Q+"|"+J+"|"+Z+"|"+V+")")+subexp("\\?("+P+")")+"?$",oe="^"+subexp("\\#("+_+")")+"?$",ce="^"+subexp("("+g+")@")+"?("+N+")"+subexp("\\:("+q+")")+"?$";return{NOT_SCHEME:new RegExp(merge("[^]",n,s,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(merge("[^\\%\\:]",h,a),"g"),NOT_HOST:new RegExp(merge("[^\\%\\[\\]\\:]",h,a),"g"),NOT_PATH:new RegExp(merge("[^\\%\\/\\:\\@]",h,a),"g"),NOT_PATH_NOSCHEME:new RegExp(merge("[^\\%\\/\\@]",h,a),"g"),NOT_QUERY:new RegExp(merge("[^\\%]",h,a,"[\\:\\@\\/\\?]",u),"g"),NOT_FRAGMENT:new RegExp(merge("[^\\%]",h,a,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(merge("[^]",h,a),"g"),UNRESERVED:new RegExp(h,"g"),OTHER_CHARS:new RegExp(merge("[^\\%]",h,d),"g"),PCT_ENCODED:new RegExp(o,"g"),IPV4ADDRESS:new RegExp("^("+y+")$"),IPV6ADDRESS:new RegExp("^\\[?("+F+")"+subexp(subexp("\\%25|\\%(?!"+f+"{2})")+"("+j+")")+"?\\]?$")}}var n=buildExps(false);var r=buildExps(true);var s=function(){function sliceIterator(e,n){var r=[];var s=true;var i=false;var f=undefined;try{for(var l=e[Symbol.iterator](),t;!(s=(t=l.next()).done);s=true){r.push(t.value);if(n&&r.length===n)break}}catch(e){i=true;f=e}finally{try{if(!s&&l["return"])l["return"]()}finally{if(i)throw f}}return r}return function(e,n){if(Array.isArray(e)){return e}else if(Symbol.iterator in Object(e)){return sliceIterator(e,n)}else{throw new TypeError("Invalid attempt to destructure non-iterable instance")}}}();var i=function(e){if(Array.isArray(e)){for(var n=0,r=Array(e.length);n<e.length;n++)r[n]=e[n];return r}else{return Array.from(e)}};var f=2147483647;var l=36;var t=1;var o=26;var c=38;var a=700;var d=72;var p=128;var u="-";var h=/^xn--/;var v=/[^\0-\x7E]/;var g=/[\x2E\u3002\uFF0E\uFF61]/g;var b={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"};var w=l-t;var y=Math.floor;var m=String.fromCharCode;function error$1(e){throw new RangeError(b[e])}function map(e,n){var r=[];var s=e.length;while(s--){r[s]=n(e[s])}return r}function mapDomain(e,n){var r=e.split("@");var s="";if(r.length>1){s=r[0]+"@";e=r[1]}e=e.replace(g,".");var i=e.split(".");var f=map(i,n).join(".");return s+f}function ucs2decode(e){var n=[];var r=0;var s=e.length;while(r<s){var i=e.charCodeAt(r++);if(i>=55296&&i<=56319&&r<s){var f=e.charCodeAt(r++);if((f&64512)==56320){n.push(((i&1023)<<10)+(f&1023)+65536)}else{n.push(i);r--}}else{n.push(i)}}return n}var E=function ucs2encode(e){return String.fromCodePoint.apply(String,i(e))};var S=function basicToDigit(e){if(e-48<10){return e-22}if(e-65<26){return e-65}if(e-97<26){return e-97}return l};var C=function digitToBasic(e,n){return e+22+75*(e<26)-((n!=0)<<5)};var O=function adapt(e,n,r){var s=0;e=r?y(e/a):e>>1;e+=y(e/n);for(;e>w*o>>1;s+=l){e=y(e/w)}return y(s+(w+1)*e/(e+c))};var A=function decode(e){var n=[];var r=e.length;var s=0;var i=p;var c=d;var a=e.lastIndexOf(u);if(a<0){a=0}for(var h=0;h<a;++h){if(e.charCodeAt(h)>=128){error$1("not-basic")}n.push(e.charCodeAt(h))}for(var v=a>0?a+1:0;v<r;){var g=s;for(var b=1,w=l;;w+=l){if(v>=r){error$1("invalid-input")}var m=S(e.charCodeAt(v++));if(m>=l||m>y((f-s)/b)){error$1("overflow")}s+=m*b;var E=w<=c?t:w>=c+o?o:w-c;if(m<E){break}var C=l-E;if(b>y(f/C)){error$1("overflow")}b*=C}var A=n.length+1;c=O(s-g,A,g==0);if(y(s/A)>f-i){error$1("overflow")}i+=y(s/A);s%=A;n.splice(s++,0,i)}return String.fromCodePoint.apply(String,n)};var R=function encode(e){var n=[];e=ucs2decode(e);var r=e.length;var s=p;var i=0;var c=d;var a=true;var h=false;var v=undefined;try{for(var g=e[Symbol.iterator](),b;!(a=(b=g.next()).done);a=true){var w=b.value;if(w<128){n.push(m(w))}}}catch(e){h=true;v=e}finally{try{if(!a&&g.return){g.return()}}finally{if(h){throw v}}}var E=n.length;var S=E;if(E){n.push(u)}while(S<r){var A=f;var R=true;var k=false;var I=undefined;try{for(var T=e[Symbol.iterator](),x;!(R=(x=T.next()).done);R=true){var F=x.value;if(F>=s&&F<A){A=F}}}catch(e){k=true;I=e}finally{try{if(!R&&T.return){T.return()}}finally{if(k){throw I}}}var j=S+1;if(A-s>y((f-i)/j)){error$1("overflow")}i+=(A-s)*j;s=A;var B=true;var L=false;var M=undefined;try{for(var U=e[Symbol.iterator](),D;!(B=(D=U.next()).done);B=true){var N=D.value;if(N<s&&++i>f){error$1("overflow")}if(N==s){var q=i;for(var z=l;;z+=l){var H=z<=c?t:z>=c+o?o:z-c;if(q<H){break}var W=q-H;var Y=l-H;n.push(m(C(H+W%Y,0)));q=y(W/Y)}n.push(m(C(q,0)));c=O(i,j,S==E);i=0;++S}}}catch(e){L=true;M=e}finally{try{if(!B&&U.return){U.return()}}finally{if(L){throw M}}}++i;++s}return n.join("")};var k=function toUnicode(e){return mapDomain(e,function(e){return h.test(e)?A(e.slice(4).toLowerCase()):e})};var I=function toASCII(e){return mapDomain(e,function(e){return v.test(e)?"xn--"+R(e):e})};var T={version:"2.1.0",ucs2:{decode:ucs2decode,encode:E},decode:A,encode:R,toASCII:I,toUnicode:k};var x={};function pctEncChar(e){var n=e.charCodeAt(0);var r=void 0;if(n<16)r="%0"+n.toString(16).toUpperCase();else if(n<128)r="%"+n.toString(16).toUpperCase();else if(n<2048)r="%"+(n>>6|192).toString(16).toUpperCase()+"%"+(n&63|128).toString(16).toUpperCase();else r="%"+(n>>12|224).toString(16).toUpperCase()+"%"+(n>>6&63|128).toString(16).toUpperCase()+"%"+(n&63|128).toString(16).toUpperCase();return r}function pctDecChars(e){var n="";var r=0;var s=e.length;while(r<s){var i=parseInt(e.substr(r+1,2),16);if(i<128){n+=String.fromCharCode(i);r+=3}else if(i>=194&&i<224){if(s-r>=6){var f=parseInt(e.substr(r+4,2),16);n+=String.fromCharCode((i&31)<<6|f&63)}else{n+=e.substr(r,6)}r+=6}else if(i>=224){if(s-r>=9){var l=parseInt(e.substr(r+4,2),16);var t=parseInt(e.substr(r+7,2),16);n+=String.fromCharCode((i&15)<<12|(l&63)<<6|t&63)}else{n+=e.substr(r,9)}r+=9}else{n+=e.substr(r,3);r+=3}}return n}function _normalizeComponentEncoding(e,n){function decodeUnreserved(e){var r=pctDecChars(e);return!r.match(n.UNRESERVED)?e:r}if(e.scheme)e.scheme=String(e.scheme).replace(n.PCT_ENCODED,decodeUnreserved).toLowerCase().replace(n.NOT_SCHEME,"");if(e.userinfo!==undefined)e.userinfo=String(e.userinfo).replace(n.PCT_ENCODED,decodeUnreserved).replace(n.NOT_USERINFO,pctEncChar).replace(n.PCT_ENCODED,toUpperCase);if(e.host!==undefined)e.host=String(e.host).replace(n.PCT_ENCODED,decodeUnreserved).toLowerCase().replace(n.NOT_HOST,pctEncChar).replace(n.PCT_ENCODED,toUpperCase);if(e.path!==undefined)e.path=String(e.path).replace(n.PCT_ENCODED,decodeUnreserved).replace(e.scheme?n.NOT_PATH:n.NOT_PATH_NOSCHEME,pctEncChar).replace(n.PCT_ENCODED,toUpperCase);if(e.query!==undefined)e.query=String(e.query).replace(n.PCT_ENCODED,decodeUnreserved).replace(n.NOT_QUERY,pctEncChar).replace(n.PCT_ENCODED,toUpperCase);if(e.fragment!==undefined)e.fragment=String(e.fragment).replace(n.PCT_ENCODED,decodeUnreserved).replace(n.NOT_FRAGMENT,pctEncChar).replace(n.PCT_ENCODED,toUpperCase);return e}function _stripLeadingZeros(e){return e.replace(/^0*(.*)/,"$1")||"0"}function _normalizeIPv4(e,n){var r=e.match(n.IPV4ADDRESS)||[];var i=s(r,2),f=i[1];if(f){return f.split(".").map(_stripLeadingZeros).join(".")}else{return e}}function _normalizeIPv6(e,n){var r=e.match(n.IPV6ADDRESS)||[];var i=s(r,3),f=i[1],l=i[2];if(f){var t=f.toLowerCase().split("::").reverse(),o=s(t,2),c=o[0],a=o[1];var d=a?a.split(":").map(_stripLeadingZeros):[];var p=c.split(":").map(_stripLeadingZeros);var u=n.IPV4ADDRESS.test(p[p.length-1]);var h=u?7:8;var v=p.length-h;var g=Array(h);for(var b=0;b<h;++b){g[b]=d[b]||p[v+b]||""}if(u){g[h-1]=_normalizeIPv4(g[h-1],n)}var w=g.reduce(function(e,n,r){if(!n||n==="0"){var s=e[e.length-1];if(s&&s.index+s.length===r){s.length++}else{e.push({index:r,length:1})}}return e},[]);var y=w.sort(function(e,n){return n.length-e.length})[0];var m=void 0;if(y&&y.length>1){var E=g.slice(0,y.index);var S=g.slice(y.index+y.length);m=E.join(":")+"::"+S.join(":")}else{m=g.join(":")}if(l){m+="%"+l}return m}else{return e}}var F=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i;var j="".match(/(){0}/)[1]===undefined;function parse(e){var s=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};var i={};var f=s.iri!==false?r:n;if(s.reference==="suffix")e=(s.scheme?s.scheme+":":"")+"//"+e;var l=e.match(F);if(l){if(j){i.scheme=l[1];i.userinfo=l[3];i.host=l[4];i.port=parseInt(l[5],10);i.path=l[6]||"";i.query=l[7];i.fragment=l[8];if(isNaN(i.port)){i.port=l[5]}}else{i.scheme=l[1]||undefined;i.userinfo=e.indexOf("@")!==-1?l[3]:undefined;i.host=e.indexOf("//")!==-1?l[4]:undefined;i.port=parseInt(l[5],10);i.path=l[6]||"";i.query=e.indexOf("?")!==-1?l[7]:undefined;i.fragment=e.indexOf("#")!==-1?l[8]:undefined;if(isNaN(i.port)){i.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?l[4]:undefined}}if(i.host){i.host=_normalizeIPv6(_normalizeIPv4(i.host,f),f)}if(i.scheme===undefined&&i.userinfo===undefined&&i.host===undefined&&i.port===undefined&&!i.path&&i.query===undefined){i.reference="same-document"}else if(i.scheme===undefined){i.reference="relative"}else if(i.fragment===undefined){i.reference="absolute"}else{i.reference="uri"}if(s.reference&&s.reference!=="suffix"&&s.reference!==i.reference){i.error=i.error||"URI is not a "+s.reference+" reference."}var t=x[(s.scheme||i.scheme||"").toLowerCase()];if(!s.unicodeSupport&&(!t||!t.unicodeSupport)){if(i.host&&(s.domainHost||t&&t.domainHost)){try{i.host=T.toASCII(i.host.replace(f.PCT_ENCODED,pctDecChars).toLowerCase())}catch(e){i.error=i.error||"Host's domain name can not be converted to ASCII via punycode: "+e}}_normalizeComponentEncoding(i,n)}else{_normalizeComponentEncoding(i,f)}if(t&&t.parse){t.parse(i,s)}}else{i.error=i.error||"URI can not be parsed."}return i}function _recomposeAuthority(e,s){var i=s.iri!==false?r:n;var f=[];if(e.userinfo!==undefined){f.push(e.userinfo);f.push("@")}if(e.host!==undefined){f.push(_normalizeIPv6(_normalizeIPv4(String(e.host),i),i).replace(i.IPV6ADDRESS,function(e,n,r){return"["+n+(r?"%25"+r:"")+"]"}))}if(typeof e.port==="number"||typeof e.port==="string"){f.push(":");f.push(String(e.port))}return f.length?f.join(""):undefined}var B=/^\.\.?\//;var L=/^\/\.(\/|$)/;var M=/^\/\.\.(\/|$)/;var U=/^\/?(?:.|\n)*?(?=\/|$)/;function removeDotSegments(e){var n=[];while(e.length){if(e.match(B)){e=e.replace(B,"")}else if(e.match(L)){e=e.replace(L,"/")}else if(e.match(M)){e=e.replace(M,"/");n.pop()}else if(e==="."||e===".."){e=""}else{var r=e.match(U);if(r){var s=r[0];e=e.slice(s.length);n.push(s)}else{throw new Error("Unexpected dot segment condition")}}}return n.join("")}function serialize(e){var s=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};var i=s.iri?r:n;var f=[];var l=x[(s.scheme||e.scheme||"").toLowerCase()];if(l&&l.serialize)l.serialize(e,s);if(e.host){if(i.IPV6ADDRESS.test(e.host)){}else if(s.domainHost||l&&l.domainHost){try{e.host=!s.iri?T.toASCII(e.host.replace(i.PCT_ENCODED,pctDecChars).toLowerCase()):T.toUnicode(e.host)}catch(n){e.error=e.error||"Host's domain name can not be converted to "+(!s.iri?"ASCII":"Unicode")+" via punycode: "+n}}}_normalizeComponentEncoding(e,i);if(s.reference!=="suffix"&&e.scheme){f.push(e.scheme);f.push(":")}var t=_recomposeAuthority(e,s);if(t!==undefined){if(s.reference!=="suffix"){f.push("//")}f.push(t);if(e.path&&e.path.charAt(0)!=="/"){f.push("/")}}if(e.path!==undefined){var o=e.path;if(!s.absolutePath&&(!l||!l.absolutePath)){o=removeDotSegments(o)}if(t===undefined){o=o.replace(/^\/\//,"/%2F")}f.push(o)}if(e.query!==undefined){f.push("?");f.push(e.query)}if(e.fragment!==undefined){f.push("#");f.push(e.fragment)}return f.join("")}function resolveComponents(e,n){var r=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};var s=arguments[3];var i={};if(!s){e=parse(serialize(e,r),r);n=parse(serialize(n,r),r)}r=r||{};if(!r.tolerant&&n.scheme){i.scheme=n.scheme;i.userinfo=n.userinfo;i.host=n.host;i.port=n.port;i.path=removeDotSegments(n.path||"");i.query=n.query}else{if(n.userinfo!==undefined||n.host!==undefined||n.port!==undefined){i.userinfo=n.userinfo;i.host=n.host;i.port=n.port;i.path=removeDotSegments(n.path||"");i.query=n.query}else{if(!n.path){i.path=e.path;if(n.query!==undefined){i.query=n.query}else{i.query=e.query}}else{if(n.path.charAt(0)==="/"){i.path=removeDotSegments(n.path)}else{if((e.userinfo!==undefined||e.host!==undefined||e.port!==undefined)&&!e.path){i.path="/"+n.path}else if(!e.path){i.path=n.path}else{i.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+n.path}i.path=removeDotSegments(i.path)}i.query=n.query}i.userinfo=e.userinfo;i.host=e.host;i.port=e.port}i.scheme=e.scheme}i.fragment=n.fragment;return i}function resolve(e,n,r){var s=assign({scheme:"null"},r);return serialize(resolveComponents(parse(e,s),parse(n,s),s,true),s)}function normalize(e,n){if(typeof e==="string"){e=serialize(parse(e,n),n)}else if(typeOf(e)==="object"){e=parse(serialize(e,n),n)}return e}function equal(e,n,r){if(typeof e==="string"){e=serialize(parse(e,r),r)}else if(typeOf(e)==="object"){e=serialize(e,r)}if(typeof n==="string"){n=serialize(parse(n,r),r)}else if(typeOf(n)==="object"){n=serialize(n,r)}return e===n}function escapeComponent(e,s){return e&&e.toString().replace(!s||!s.iri?n.ESCAPE:r.ESCAPE,pctEncChar)}function unescapeComponent(e,s){return e&&e.toString().replace(!s||!s.iri?n.PCT_ENCODED:r.PCT_ENCODED,pctDecChars)}var D={scheme:"http",domainHost:true,parse:function parse(e,n){if(!e.host){e.error=e.error||"HTTP URIs must have a host."}return e},serialize:function serialize(e,n){var r=String(e.scheme).toLowerCase()==="https";if(e.port===(r?443:80)||e.port===""){e.port=undefined}if(!e.path){e.path="/"}return e}};var N={scheme:"https",domainHost:D.domainHost,parse:D.parse,serialize:D.serialize};function isSecure(e){return typeof e.secure==="boolean"?e.secure:String(e.scheme).toLowerCase()==="wss"}var q={scheme:"ws",domainHost:true,parse:function parse(e,n){var r=e;r.secure=isSecure(r);r.resourceName=(r.path||"/")+(r.query?"?"+r.query:"");r.path=undefined;r.query=undefined;return r},serialize:function serialize(e,n){if(e.port===(isSecure(e)?443:80)||e.port===""){e.port=undefined}if(typeof e.secure==="boolean"){e.scheme=e.secure?"wss":"ws";e.secure=undefined}if(e.resourceName){var r=e.resourceName.split("?"),i=s(r,2),f=i[0],l=i[1];e.path=f&&f!=="/"?f:undefined;e.query=l;e.resourceName=undefined}e.fragment=undefined;return e}};var z={scheme:"wss",domainHost:q.domainHost,parse:q.parse,serialize:q.serialize};var H={};var W=true;var Y="[A-Za-z0-9\\-\\.\\_\\~"+(W?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]";var G="[0-9A-Fa-f]";var Q=subexp(subexp("%[EFef]"+G+"%"+G+G+"%"+G+G)+"|"+subexp("%[89A-Fa-f]"+G+"%"+G+G)+"|"+subexp("%"+G+G));var J="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]";var X="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]";var Z=merge(X,'[\\"\\\\]');var V="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]";var K=new RegExp(Y,"g");var P=new RegExp(Q,"g");var _=new RegExp(merge("[^]",J,"[\\.]",'[\\"]',Z),"g");var $=new RegExp(merge("[^]",Y,V),"g");var ee=$;function decodeUnreserved(e){var n=pctDecChars(e);return!n.match(K)?e:n}var ne={scheme:"mailto",parse:function parse$$1(e,n){var r=e;var s=r.to=r.path?r.path.split(","):[];r.path=undefined;if(r.query){var i=false;var f={};var l=r.query.split("&");for(var t=0,o=l.length;t<o;++t){var c=l[t].split("=");switch(c[0]){case"to":var a=c[1].split(",");for(var d=0,p=a.length;d<p;++d){s.push(a[d])}break;case"subject":r.subject=unescapeComponent(c[1],n);break;case"body":r.body=unescapeComponent(c[1],n);break;default:i=true;f[unescapeComponent(c[0],n)]=unescapeComponent(c[1],n);break}}if(i)r.headers=f}r.query=undefined;for(var u=0,h=s.length;u<h;++u){var v=s[u].split("@");v[0]=unescapeComponent(v[0]);if(!n.unicodeSupport){try{v[1]=T.toASCII(unescapeComponent(v[1],n).toLowerCase())}catch(e){r.error=r.error||"Email address's domain name can not be converted to ASCII via punycode: "+e}}else{v[1]=unescapeComponent(v[1],n).toLowerCase()}s[u]=v.join("@")}return r},serialize:function serialize$$1(e,n){var r=e;var s=toArray(e.to);if(s){for(var i=0,f=s.length;i<f;++i){var l=String(s[i]);var t=l.lastIndexOf("@");var o=l.slice(0,t).replace(P,decodeUnreserved).replace(P,toUpperCase).replace(_,pctEncChar);var c=l.slice(t+1);try{c=!n.iri?T.toASCII(unescapeComponent(c,n).toLowerCase()):T.toUnicode(c)}catch(e){r.error=r.error||"Email address's domain name can not be converted to "+(!n.iri?"ASCII":"Unicode")+" via punycode: "+e}s[i]=o+"@"+c}r.path=s.join(",")}var a=e.headers=e.headers||{};if(e.subject)a["subject"]=e.subject;if(e.body)a["body"]=e.body;var d=[];for(var p in a){if(a[p]!==H[p]){d.push(p.replace(P,decodeUnreserved).replace(P,toUpperCase).replace($,pctEncChar)+"="+a[p].replace(P,decodeUnreserved).replace(P,toUpperCase).replace(ee,pctEncChar))}}if(d.length){r.query=d.join("&")}return r}};var re=/^([^\:]+)\:(.*)/;var se={scheme:"urn",parse:function parse$$1(e,n){var r=e.path&&e.path.match(re);var s=e;if(r){var i=n.scheme||s.scheme||"urn";var f=r[1].toLowerCase();var l=r[2];var t=i+":"+(n.nid||f);var o=x[t];s.nid=f;s.nss=l;s.path=undefined;if(o){s=o.parse(s,n)}}else{s.error=s.error||"URN can not be parsed."}return s},serialize:function serialize$$1(e,n){var r=n.scheme||e.scheme||"urn";var s=e.nid;var i=r+":"+(n.nid||s);var f=x[i];if(f){e=f.serialize(e,n)}var l=e;var t=e.nss;l.path=(s||n.nid)+":"+t;return l}};var ie=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;var fe={scheme:"urn:uuid",parse:function parse(e,n){var r=e;r.uuid=r.nss;r.nss=undefined;if(!n.tolerant&&(!r.uuid||!r.uuid.match(ie))){r.error=r.error||"UUID is not valid."}return r},serialize:function serialize(e,n){var r=e;r.nss=(e.uuid||"").toLowerCase();return r}};x[D.scheme]=D;x[N.scheme]=N;x[q.scheme]=q;x[z.scheme]=z;x[ne.scheme]=ne;x[se.scheme]=se;x[fe.scheme]=fe;e.SCHEMES=x;e.pctEncChar=pctEncChar;e.pctDecChars=pctDecChars;e.parse=parse;e.removeDotSegments=removeDotSegments;e.serialize=serialize;e.resolveComponents=resolveComponents;e.resolve=resolve;e.normalize=normalize;e.equal=equal;e.escapeComponent=escapeComponent;e.unescapeComponent=unescapeComponent;Object.defineProperty(e,"__esModule",{value:true})})},1202:(e,n,r)=>{e.exports=r(1669).deprecate},7007:e=>{"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next){yield e.value}}}},7572:(e,n,r)=>{"use strict";e.exports=Yallist;Yallist.Node=Node;Yallist.create=Yallist;function Yallist(e){var n=this;if(!(n instanceof Yallist)){n=new Yallist}n.tail=null;n.head=null;n.length=0;if(e&&typeof e.forEach==="function"){e.forEach(function(e){n.push(e)})}else if(arguments.length>0){for(var r=0,s=arguments.length;r<s;r++){n.push(arguments[r])}}return n}Yallist.prototype.removeNode=function(e){if(e.list!==this){throw new Error("removing node which does not belong to this list")}var n=e.next;var r=e.prev;if(n){n.prev=r}if(r){r.next=n}if(e===this.head){this.head=n}if(e===this.tail){this.tail=r}e.list.length--;e.next=null;e.prev=null;e.list=null;return n};Yallist.prototype.unshiftNode=function(e){if(e===this.head){return}if(e.list){e.list.removeNode(e)}var n=this.head;e.list=this;e.next=n;if(n){n.prev=e}this.head=e;if(!this.tail){this.tail=e}this.length++};Yallist.prototype.pushNode=function(e){if(e===this.tail){return}if(e.list){e.list.removeNode(e)}var n=this.tail;e.list=this;e.prev=n;if(n){n.next=e}this.tail=e;if(!this.head){this.head=e}this.length++};Yallist.prototype.push=function(){for(var e=0,n=arguments.length;e<n;e++){push(this,arguments[e])}return this.length};Yallist.prototype.unshift=function(){for(var e=0,n=arguments.length;e<n;e++){unshift(this,arguments[e])}return this.length};Yallist.prototype.pop=function(){if(!this.tail){return undefined}var e=this.tail.value;this.tail=this.tail.prev;if(this.tail){this.tail.next=null}else{this.head=null}this.length--;return e};Yallist.prototype.shift=function(){if(!this.head){return undefined}var e=this.head.value;this.head=this.head.next;if(this.head){this.head.prev=null}else{this.tail=null}this.length--;return e};Yallist.prototype.forEach=function(e,n){n=n||this;for(var r=this.head,s=0;r!==null;s++){e.call(n,r.value,s,this);r=r.next}};Yallist.prototype.forEachReverse=function(e,n){n=n||this;for(var r=this.tail,s=this.length-1;r!==null;s--){e.call(n,r.value,s,this);r=r.prev}};Yallist.prototype.get=function(e){for(var n=0,r=this.head;r!==null&&n<e;n++){r=r.next}if(n===e&&r!==null){return r.value}};Yallist.prototype.getReverse=function(e){for(var n=0,r=this.tail;r!==null&&n<e;n++){r=r.prev}if(n===e&&r!==null){return r.value}};Yallist.prototype.map=function(e,n){n=n||this;var r=new Yallist;for(var s=this.head;s!==null;){r.push(e.call(n,s.value,this));s=s.next}return r};Yallist.prototype.mapReverse=function(e,n){n=n||this;var r=new Yallist;for(var s=this.tail;s!==null;){r.push(e.call(n,s.value,this));s=s.prev}return r};Yallist.prototype.reduce=function(e,n){var r;var s=this.head;if(arguments.length>1){r=n}else if(this.head){s=this.head.next;r=this.head.value}else{throw new TypeError("Reduce of empty list with no initial value")}for(var i=0;s!==null;i++){r=e(r,s.value,i);s=s.next}return r};Yallist.prototype.reduceReverse=function(e,n){var r;var s=this.tail;if(arguments.length>1){r=n}else if(this.tail){s=this.tail.prev;r=this.tail.value}else{throw new TypeError("Reduce of empty list with no initial value")}for(var i=this.length-1;s!==null;i--){r=e(r,s.value,i);s=s.prev}return r};Yallist.prototype.toArray=function(){var e=new Array(this.length);for(var n=0,r=this.head;r!==null;n++){e[n]=r.value;r=r.next}return e};Yallist.prototype.toArrayReverse=function(){var e=new Array(this.length);for(var n=0,r=this.tail;r!==null;n++){e[n]=r.value;r=r.prev}return e};Yallist.prototype.slice=function(e,n){n=n||this.length;if(n<0){n+=this.length}e=e||0;if(e<0){e+=this.length}var r=new Yallist;if(n<e||n<0){return r}if(e<0){e=0}if(n>this.length){n=this.length}for(var s=0,i=this.head;i!==null&&s<e;s++){i=i.next}for(;i!==null&&s<n;s++,i=i.next){r.push(i.value)}return r};Yallist.prototype.sliceReverse=function(e,n){n=n||this.length;if(n<0){n+=this.length}e=e||0;if(e<0){e+=this.length}var r=new Yallist;if(n<e||n<0){return r}if(e<0){e=0}if(n>this.length){n=this.length}for(var s=this.length,i=this.tail;i!==null&&s>n;s--){i=i.prev}for(;i!==null&&s>e;s--,i=i.prev){r.push(i.value)}return r};Yallist.prototype.splice=function(e,n,...r){if(e>this.length){e=this.length-1}if(e<0){e=this.length+e}for(var s=0,i=this.head;i!==null&&s<e;s++){i=i.next}var f=[];for(var s=0;i&&s<n;s++){f.push(i.value);i=this.removeNode(i)}if(i===null){i=this.tail}if(i!==this.head&&i!==this.tail){i=i.prev}for(var s=0;s<r.length;s++){i=insert(this,i,r[s])}return f};Yallist.prototype.reverse=function(){var e=this.head;var n=this.tail;for(var r=e;r!==null;r=r.prev){var s=r.prev;r.prev=r.next;r.next=s}this.head=n;this.tail=e;return this};function insert(e,n,r){var s=n===e.head?new Node(r,null,n,e):new Node(r,n,n.next,e);if(s.next===null){e.tail=s}if(s.prev===null){e.head=s}e.length++;return s}function push(e,n){e.tail=new Node(n,e.tail,null,e);if(!e.head){e.head=e.tail}e.length++}function unshift(e,n){e.head=new Node(n,null,e.head,e);if(!e.tail){e.tail=e.head}e.length++}function Node(e,n,r,s){if(!(this instanceof Node)){return new Node(e,n,r,s)}this.list=s;this.value=e;if(n){n.next=this;this.prev=n}else{this.prev=null}if(r){r.prev=this;this.next=r}else{this.next=null}}try{r(7007)(Yallist)}catch(e){}},1415:module=>{module.exports=eval("require")("supports-color")},5999:(e,n,r)=>{"use strict";n=e.exports=fetch;const s=r(8605);const i=r(7211);const f=r(8761);const l=r(2413);const t=r(6551);const o=r(1669);const c=r(5835);const a=r(6417);const d=r(8835);class FetchBaseError extends Error{constructor(e,n){super(e);Error.captureStackTrace(this,this.constructor);this.type=n}get name(){return this.constructor.name}get[Symbol.toStringTag](){return this.constructor.name}}class FetchError extends FetchBaseError{constructor(e,n,r){super(e,n);if(r){this.code=this.errno=r.code;this.erroredSysCall=r.syscall}}}const p=Symbol.toStringTag;const u=e=>{return typeof e==="object"&&typeof e.append==="function"&&typeof e.delete==="function"&&typeof e.get==="function"&&typeof e.getAll==="function"&&typeof e.has==="function"&&typeof e.set==="function"&&typeof e.sort==="function"&&e[p]==="URLSearchParams"};const h=e=>{return typeof e==="object"&&typeof e.arrayBuffer==="function"&&typeof e.type==="string"&&typeof e.stream==="function"&&typeof e.constructor==="function"&&/^(Blob|File)$/.test(e[p])};function isFormData(e){return typeof e==="object"&&typeof e.append==="function"&&typeof e.set==="function"&&typeof e.get==="function"&&typeof e.getAll==="function"&&typeof e.delete==="function"&&typeof e.keys==="function"&&typeof e.values==="function"&&typeof e.entries==="function"&&typeof e.constructor==="function"&&e[p]==="FormData"}const v=e=>{return typeof e==="object"&&e[p]==="AbortSignal"};const g="\r\n";const b="-".repeat(2);const w=Buffer.byteLength(g);const y=e=>`${b}${e}${b}${g.repeat(2)}`;function getHeader(e,n,r){let s="";s+=`${b}${e}${g}`;s+=`Content-Disposition: form-data; name="${n}"`;if(h(r)){s+=`; filename="${r.name}"${g}`;s+=`Content-Type: ${r.type||"application/octet-stream"}`}return`${s}${g.repeat(2)}`}const m=()=>a.randomBytes(8).toString("hex");async function*formDataIterator(e,n){for(const[r,s]of e){yield getHeader(n,r,s);if(h(s)){yield*s.stream()}else{yield s}yield g}yield y(n)}function getFormDataLength(e,n){let r=0;for(const[s,i]of e){r+=Buffer.byteLength(getHeader(n,s,i));if(h(i)){r+=i.size}else{r+=Buffer.byteLength(String(i))}r+=w}r+=Buffer.byteLength(y(n));return r}const E=Symbol("Body internals");class Body{constructor(e,{size:n=0}={}){let r=null;if(e===null){e=null}else if(u(e)){e=Buffer.from(e.toString())}else if(h(e)) ;else if(Buffer.isBuffer(e)) ;else if(o.types.isAnyArrayBuffer(e)){e=Buffer.from(e)}else if(ArrayBuffer.isView(e)){e=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}else if(e instanceof l) ;else if(isFormData(e)){r=`NodeFetchFormDataBoundary${m()}`;e=l.Readable.from(formDataIterator(e,r))}else{e=Buffer.from(String(e))}this[E]={body:e,boundary:r,disturbed:false,error:null};this.size=n;if(e instanceof l){e.on("error",e=>{const n=e instanceof FetchBaseError?e:new FetchError(`Invalid response body while trying to fetch ${this.url}: ${e.message}`,"system",e);this[E].error=n})}}get body(){return this[E].body}get bodyUsed(){return this[E].disturbed}async arrayBuffer(){const{buffer:e,byteOffset:n,byteLength:r}=await consumeBody(this);return e.slice(n,n+r)}async blob(){const e=this.headers&&this.headers.get("content-type")||this[E].body&&this[E].body.type||"";const n=await this.buffer();return new c([n],{type:e})}async json(){const e=await consumeBody(this);return JSON.parse(e.toString())}async text(){const e=await consumeBody(this);return e.toString()}buffer(){return consumeBody(this)}}Object.defineProperties(Body.prototype,{body:{enumerable:true},bodyUsed:{enumerable:true},arrayBuffer:{enumerable:true},blob:{enumerable:true},json:{enumerable:true},text:{enumerable:true}});async function consumeBody(e){if(e[E].disturbed){throw new TypeError(`body used already for: ${e.url}`)}e[E].disturbed=true;if(e[E].error){throw e[E].error}let{body:n}=e;if(n===null){return Buffer.alloc(0)}if(h(n)){n=n.stream()}if(Buffer.isBuffer(n)){return n}if(!(n instanceof l)){return Buffer.alloc(0)}const r=[];let s=0;try{for await(const i of n){if(e.size>0&&s+i.length>e.size){const r=new FetchError(`content size at ${e.url} over limit: ${e.size}`,"max-size");n.destroy(r);throw r}s+=i.length;r.push(i)}}catch(n){if(n instanceof FetchBaseError){throw n}else{throw new FetchError(`Invalid response body while trying to fetch ${e.url}: ${n.message}`,"system",n)}}if(n.readableEnded===true||n._readableState.ended===true){try{if(r.every(e=>typeof e==="string")){return Buffer.from(r.join(""))}return Buffer.concat(r,s)}catch(n){throw new FetchError(`Could not create Buffer from response body for ${e.url}: ${n.message}`,"system",n)}}else{throw new FetchError(`Premature close of server response while trying to fetch ${e.url}`)}}const S=(e,n)=>{let r;let s;let{body:i}=e;if(e.bodyUsed){throw new Error("cannot clone body after it is used")}if(i instanceof l&&typeof i.getBoundary!=="function"){r=new l.PassThrough({highWaterMark:n});s=new l.PassThrough({highWaterMark:n});i.pipe(r);i.pipe(s);e[E].body=r;i=s}return i};const C=(e,n)=>{if(e===null){return null}if(typeof e==="string"){return"text/plain;charset=UTF-8"}if(u(e)){return"application/x-www-form-urlencoded;charset=UTF-8"}if(h(e)){return e.type||null}if(Buffer.isBuffer(e)||o.types.isAnyArrayBuffer(e)||ArrayBuffer.isView(e)){return null}if(e&&typeof e.getBoundary==="function"){return`multipart/form-data;boundary=${e.getBoundary()}`}if(isFormData(e)){return`multipart/form-data; boundary=${n[E].boundary}`}if(e instanceof l){return null}return"text/plain;charset=UTF-8"};const O=e=>{const{body:n}=e;if(n===null){return 0}if(h(n)){return n.size}if(Buffer.isBuffer(n)){return n.length}if(n&&typeof n.getLengthSync==="function"){return n.hasKnownLength&&n.hasKnownLength()?n.getLengthSync():null}if(isFormData(n)){return getFormDataLength(e[E].boundary)}return null};const A=(e,{body:n})=>{if(n===null){e.end()}else if(h(n)){n.stream().pipe(e)}else if(Buffer.isBuffer(n)){e.write(n);e.end()}else{n.pipe(e)}};const R=typeof s.validateHeaderName==="function"?s.validateHeaderName:e=>{if(!/^[\^`\-\w!#$%&'*+.|~]+$/.test(e)){const n=new TypeError(`Header name must be a valid HTTP token [${e}]`);Object.defineProperty(n,"code",{value:"ERR_INVALID_HTTP_TOKEN"});throw n}};const k=typeof s.validateHeaderValue==="function"?s.validateHeaderValue:(e,n)=>{if(/[^\t\u0020-\u007E\u0080-\u00FF]/.test(n)){const n=new TypeError(`Invalid character in header content ["${e}"]`);Object.defineProperty(n,"code",{value:"ERR_INVALID_CHAR"});throw n}};class Headers extends URLSearchParams{constructor(e){let n=[];if(e instanceof Headers){const r=e.raw();for(const[e,s]of Object.entries(r)){n.push(...s.map(n=>[e,n]))}}else if(e==null) ;else if(typeof e==="object"&&!o.types.isBoxedPrimitive(e)){const r=e[Symbol.iterator];if(r==null){n.push(...Object.entries(e))}else{if(typeof r!=="function"){throw new TypeError("Header pairs must be iterable")}n=[...e].map(e=>{if(typeof e!=="object"||o.types.isBoxedPrimitive(e)){throw new TypeError("Each header pair must be an iterable object")}return[...e]}).map(e=>{if(e.length!==2){throw new TypeError("Each header pair must be a name/value tuple")}return[...e]})}}else{throw new TypeError("Failed to construct 'Headers': The provided value is not of type '(sequence<sequence<ByteString>> or record<ByteString, ByteString>)")}n=n.length>0?n.map(([e,n])=>{R(e);k(e,String(n));return[String(e).toLowerCase(),String(n)]}):undefined;super(n);return new Proxy(this,{get(e,n,r){switch(n){case"append":case"set":return(e,s)=>{R(e);k(e,String(s));return URLSearchParams.prototype[n].call(r,String(e).toLowerCase(),String(s))};case"delete":case"has":case"getAll":return e=>{R(e);return URLSearchParams.prototype[n].call(r,String(e).toLowerCase())};case"keys":return()=>{e.sort();return new Set(URLSearchParams.prototype.keys.call(e)).keys()};default:return Reflect.get(e,n,r)}}})}get[Symbol.toStringTag](){return this.constructor.name}toString(){return Object.prototype.toString.call(this)}get(e){const n=this.getAll(e);if(n.length===0){return null}let r=n.join(", ");if(/^content-encoding$/i.test(e)){r=r.toLowerCase()}return r}forEach(e){for(const n of this.keys()){e(this.get(n),n)}}*values(){for(const e of this.keys()){yield this.get(e)}}*entries(){for(const e of this.keys()){yield[e,this.get(e)]}}[Symbol.iterator](){return this.entries()}raw(){return[...this.keys()].reduce((e,n)=>{e[n]=this.getAll(n);return e},{})}[Symbol.for("nodejs.util.inspect.custom")](){return[...this.keys()].reduce((e,n)=>{const r=this.getAll(n);if(n==="host"){e[n]=r[0]}else{e[n]=r.length>1?r:r[0]}return e},{})}}Object.defineProperties(Headers.prototype,["get","entries","forEach","values"].reduce((e,n)=>{e[n]={enumerable:true};return e},{}));function fromRawHeaders(e=[]){return new Headers(e.reduce((e,n,r,s)=>{if(r%2===0){e.push(s.slice(r,r+2))}return e},[]).filter(([e,n])=>{try{R(e);k(e,String(n));return true}catch{return false}}))}const I=new Set([301,302,303,307,308]);const T=e=>{return I.has(e)};const x=Symbol("Response internals");class Response extends Body{constructor(e=null,n={}){super(e,n);const r=n.status||200;const s=new Headers(n.headers);if(e!==null&&!s.has("Content-Type")){const n=C(e);if(n){s.append("Content-Type",n)}}this[x]={url:n.url,status:r,statusText:n.statusText||"",headers:s,counter:n.counter,highWaterMark:n.highWaterMark}}get url(){return this[x].url||""}get status(){return this[x].status}get ok(){return this[x].status>=200&&this[x].status<300}get redirected(){return this[x].counter>0}get statusText(){return this[x].statusText}get headers(){return this[x].headers}get highWaterMark(){return this[x].highWaterMark}clone(){return new Response(S(this,this.highWaterMark),{url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected,size:this.size})}static redirect(e,n=302){if(!T(n)){throw new RangeError('Failed to execute "redirect" on "response": Invalid status code')}return new Response(null,{headers:{location:new URL(e).toString()},status:n})}get[Symbol.toStringTag](){return"Response"}}Object.defineProperties(Response.prototype,{url:{enumerable:true},status:{enumerable:true},ok:{enumerable:true},redirected:{enumerable:true},statusText:{enumerable:true},headers:{enumerable:true},clone:{enumerable:true}});const F=e=>{if(e.search){return e.search}const n=e.href.length-1;const r=e.hash||(e.href[n]==="#"?"#":"");return e.href[n-r.length]==="?"?"?":""};const j=Symbol("Request internals");const B=e=>{return typeof e==="object"&&typeof e[j]==="object"};class Request extends Body{constructor(e,n={}){let r;if(B(e)){r=new URL(e.url)}else{r=new URL(e);e={}}let s=n.method||e.method||"GET";s=s.toUpperCase();if((n.body!=null||B(e))&&e.body!==null&&(s==="GET"||s==="HEAD")){throw new TypeError("Request with GET/HEAD method cannot have body")}const i=n.body?n.body:B(e)&&e.body!==null?S(e):null;super(i,{size:n.size||e.size||0});const f=new Headers(n.headers||e.headers||{});if(i!==null&&!f.has("Content-Type")){const e=C(i,this);if(e){f.append("Content-Type",e)}}let l=B(e)?e.signal:null;if("signal"in n){l=n.signal}if(l!==null&&!v(l)){throw new TypeError("Expected signal to be an instanceof AbortSignal")}this[j]={method:s,redirect:n.redirect||e.redirect||"follow",headers:f,parsedURL:r,signal:l};this.follow=n.follow===undefined?e.follow===undefined?20:e.follow:n.follow;this.compress=n.compress===undefined?e.compress===undefined?true:e.compress:n.compress;this.counter=n.counter||e.counter||0;this.agent=n.agent||e.agent;this.highWaterMark=n.highWaterMark||e.highWaterMark||16384;this.insecureHTTPParser=n.insecureHTTPParser||e.insecureHTTPParser||false}get method(){return this[j].method}get url(){return d.format(this[j].parsedURL)}get headers(){return this[j].headers}get redirect(){return this[j].redirect}get signal(){return this[j].signal}clone(){return new Request(this)}get[Symbol.toStringTag](){return"Request"}}Object.defineProperties(Request.prototype,{method:{enumerable:true},url:{enumerable:true},headers:{enumerable:true},redirect:{enumerable:true},clone:{enumerable:true},signal:{enumerable:true}});const L=e=>{const{parsedURL:n}=e[j];const r=new Headers(e[j].headers);if(!r.has("Accept")){r.set("Accept","*/*")}let s=null;if(e.body===null&&/^(post|put)$/i.test(e.method)){s="0"}if(e.body!==null){const n=O(e);if(typeof n==="number"&&!Number.isNaN(n)){s=String(n)}}if(s){r.set("Content-Length",s)}if(!r.has("User-Agent")){r.set("User-Agent","node-fetch")}if(e.compress&&!r.has("Accept-Encoding")){r.set("Accept-Encoding","gzip,deflate,br")}let{agent:i}=e;if(typeof i==="function"){i=i(n)}if(!r.has("Connection")&&!i){r.set("Connection","close")}const f=F(n);const l={path:n.pathname+f,pathname:n.pathname,hostname:n.hostname,protocol:n.protocol,port:n.port,hash:n.hash,search:n.search,query:n.query,href:n.href,method:e.method,headers:r[Symbol.for("nodejs.util.inspect.custom")](),insecureHTTPParser:e.insecureHTTPParser,agent:i};return l};class AbortError extends FetchBaseError{constructor(e,n="aborted"){super(e,n)}}const M=new Set(["data:","http:","https:"]);async function fetch(e,n){return new Promise((r,o)=>{const c=new Request(e,n);const a=L(c);if(!M.has(a.protocol)){throw new TypeError(`node-fetch cannot load ${e}. URL scheme "${a.protocol.replace(/:$/,"")}" is not supported.`)}if(a.protocol==="data:"){const e=t(c.url);const n=new Response(e,{headers:{"Content-Type":e.typeFull}});r(n);return}const d=(a.protocol==="https:"?i:s).request;const{signal:p}=c;let u=null;const h=()=>{const e=new AbortError("The operation was aborted.");o(e);if(c.body&&c.body instanceof l.Readable){c.body.destroy(e)}if(!u||!u.body){return}u.body.emit("error",e)};if(p&&p.aborted){h();return}const v=()=>{h();b()};const g=d(a);if(p){p.addEventListener("abort",v)}const b=()=>{g.abort();if(p){p.removeEventListener("abort",v)}};g.on("error",e=>{o(new FetchError(`request to ${c.url} failed, reason: ${e.message}`,"system",e));b()});g.on("response",e=>{g.setTimeout(0);const s=fromRawHeaders(e.rawHeaders);if(T(e.statusCode)){const i=s.get("Location");const f=i===null?null:new URL(i,c.url);switch(c.redirect){case"error":o(new FetchError(`uri requested responds with a redirect, redirect mode is set to error: ${c.url}`,"no-redirect"));b();return;case"manual":if(f!==null){try{s.set("Location",f)}catch(e){o(e)}}break;case"follow":{if(f===null){break}if(c.counter>=c.follow){o(new FetchError(`maximum redirect reached at: ${c.url}`,"max-redirect"));b();return}const s={headers:new Headers(c.headers),follow:c.follow,counter:c.counter+1,agent:c.agent,compress:c.compress,method:c.method,body:c.body,signal:c.signal,size:c.size};if(e.statusCode!==303&&c.body&&n.body instanceof l.Readable){o(new FetchError("Cannot follow redirect with body being a readable stream","unsupported-redirect"));b();return}if(e.statusCode===303||(e.statusCode===301||e.statusCode===302)&&c.method==="POST"){s.method="GET";s.body=undefined;s.headers.delete("content-length")}r(fetch(new Request(f,s)));b();return}}}e.once("end",()=>{if(p){p.removeEventListener("abort",v)}});let i=l.pipeline(e,new l.PassThrough,e=>{o(e)});if(process.version<"v12.10"){e.on("aborted",v)}const t={url:c.url,status:e.statusCode,statusText:e.statusMessage,headers:s,size:c.size,counter:c.counter,highWaterMark:c.highWaterMark};const a=s.get("Content-Encoding");if(!c.compress||c.method==="HEAD"||a===null||e.statusCode===204||e.statusCode===304){u=new Response(i,t);r(u);return}const d={flush:f.Z_SYNC_FLUSH,finishFlush:f.Z_SYNC_FLUSH};if(a==="gzip"||a==="x-gzip"){i=l.pipeline(i,f.createGunzip(d),e=>{o(e)});u=new Response(i,t);r(u);return}if(a==="deflate"||a==="x-deflate"){const n=l.pipeline(e,new l.PassThrough,e=>{o(e)});n.once("data",e=>{if((e[0]&15)===8){i=l.pipeline(i,f.createInflate(),e=>{o(e)})}else{i=l.pipeline(i,f.createInflateRaw(),e=>{o(e)})}u=new Response(i,t);r(u)});return}if(a==="br"){i=l.pipeline(i,f.createBrotliDecompress(),e=>{o(e)});u=new Response(i,t);r(u);return}u=new Response(i,t);r(u)});A(g,c)})}n.AbortError=AbortError;n.FetchError=FetchError;n.Headers=Headers;n.Request=Request;n.Response=Response;n.default=fetch;n.isRedirect=T},2706:e=>{"use strict";e.exports=JSON.parse('{"$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":false}')},1742:e=>{"use strict";e.exports=JSON.parse('{"$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":true,"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":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"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":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"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":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"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":true}')},2357:e=>{"use strict";e.exports=require("assert")},4293:e=>{"use strict";e.exports=require("buffer")},3129:e=>{"use strict";e.exports=require("child_process")},7619:e=>{"use strict";e.exports=require("constants")},6417:e=>{"use strict";e.exports=require("crypto")},881:e=>{"use strict";e.exports=require("dns")},8614:e=>{"use strict";e.exports=require("events")},5747:e=>{"use strict";e.exports=require("fs")},8605:e=>{"use strict";e.exports=require("http")},7211:e=>{"use strict";e.exports=require("https")},1631:e=>{"use strict";e.exports=require("net")},2087:e=>{"use strict";e.exports=require("os")},5622:e=>{"use strict";e.exports=require("path")},1765:e=>{"use strict";e.exports=require("process")},2413:e=>{"use strict";e.exports=require("stream")},4304:e=>{"use strict";e.exports=require("string_decoder")},4016:e=>{"use strict";e.exports=require("tls")},3867:e=>{"use strict";e.exports=require("tty")},8835:e=>{"use strict";e.exports=require("url")},1669:e=>{"use strict";e.exports=require("util")},8761:e=>{"use strict";e.exports=require("zlib")}};var __webpack_module_cache__={};function __nccwpck_require__(e){if(__webpack_module_cache__[e]){return __webpack_module_cache__[e].exports}var n=__webpack_module_cache__[e]={exports:{}};var r=true;try{__webpack_modules__[e].call(n.exports,n,n.exports,__nccwpck_require__);r=false}finally{if(r)delete __webpack_module_cache__[e]}return n.exports}__nccwpck_require__.ab=__dirname+"/";return __nccwpck_require__(6152)})(); |