mirror of
https://github.com/docker/setup-qemu-action.git
synced 2026-10-03 02:26:11 +03:00
chore: update generated content
This commit is contained in:
1 parent
c3e57563e9
commit
a42c0c12dd
2 files changed
+81
-81
No files matched your search
+77
-77
@@ -1,83 +1,83 @@
|
||||
var B5=Object.create;var UC=Object.defineProperty;var Q5=Object.getOwnPropertyDescriptor;var x5=Object.getOwnPropertyNames;var w5=Object.getPrototypeOf,b5=Object.prototype.hasOwnProperty;var h=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),N5=(t,e)=>{for(var r in e)UC(t,r,{get:e[r],enumerable:!0})},S5=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of x5(e))!b5.call(t,s)&&s!==r&&UC(t,s,{get:()=>e[s],enumerable:!(n=Q5(e,s))||n.enumerable});return t};var B=(t,e,r)=>(r=t!=null?B5(w5(t)):{},S5(e||!t||!t.__esModule?UC(r,"default",{value:t,enumerable:!0}):r,t));var YD=h(sc=>{"use strict";var I0e=require("net"),D5=require("tls"),HC=require("http"),HD=require("https"),k5=require("events"),B0e=require("assert"),T5=require("util");sc.httpOverHttp=M5;sc.httpsOverHttp=L5;sc.httpOverHttps=_5;sc.httpsOverHttps=F5;function M5(t){var e=new ti(t);return e.request=HC.request,e}function L5(t){var e=new ti(t);return e.request=HC.request,e.createSocket=zD,e.defaultPort=443,e}function _5(t){var e=new ti(t);return e.request=HD.request,e}function F5(t){var e=new ti(t);return e.request=HD.request,e.createSocket=zD,e.defaultPort=443,e}function ti(t){var e=this;e.options=t||{},e.proxyOptions=e.options.proxy||{},e.maxSockets=e.options.maxSockets||HC.Agent.defaultMaxSockets,e.requests=[],e.sockets=[],e.on("free",function(n,s,i,o){for(var a=GD(s,i,o),c=0,l=e.requests.length;c<l;++c){var A=e.requests[c];if(A.host===a.host&&A.port===a.port){e.requests.splice(c,1),A.request.onSocket(n);return}}n.destroy(),e.removeSocket(n)})}T5.inherits(ti,k5.EventEmitter);ti.prototype.addRequest=function(e,r,n,s){var i=this,o=zC({request:e},i.options,GD(r,n,s));if(i.sockets.length>=this.maxSockets){i.requests.push(o);return}i.createSocket(o,function(a){a.on("free",c),a.on("close",l),a.on("agentRemove",l),e.onSocket(a);function c(){i.emit("free",a,o)}function l(A){i.removeSocket(a),a.removeListener("free",c),a.removeListener("close",l),a.removeListener("agentRemove",l)}})};ti.prototype.createSocket=function(e,r){var n=this,s={};n.sockets.push(s);var i=zC({},n.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(i.localAddress=e.localAddress),i.proxyAuth&&(i.headers=i.headers||{},i.headers["Proxy-Authorization"]="Basic "+new Buffer(i.proxyAuth).toString("base64")),Oi("making CONNECT request");var o=n.request(i);o.useChunkedEncodingByDefault=!1,o.once("response",a),o.once("upgrade",c),o.once("connect",l),o.once("error",A),o.end();function a(u){u.upgrade=!0}function c(u,d,m){process.nextTick(function(){l(u,d,m)})}function l(u,d,m){if(o.removeAllListeners(),d.removeAllListeners(),u.statusCode!==200){Oi("tunneling socket could not be established, statusCode=%d",u.statusCode),d.destroy();var p=new Error("tunneling socket could not be established, statusCode="+u.statusCode);p.code="ECONNRESET",e.request.emit("error",p),n.removeSocket(s);return}if(m.length>0){Oi("got illegal response body from proxy"),d.destroy();var p=new Error("got illegal response body from proxy");p.code="ECONNRESET",e.request.emit("error",p),n.removeSocket(s);return}return Oi("tunneling connection has established"),n.sockets[n.sockets.indexOf(s)]=d,r(d)}function A(u){o.removeAllListeners(),Oi(`tunneling socket could not be established, cause=%s
|
||||
`,u.message,u.stack);var d=new Error("tunneling socket could not be established, cause="+u.message);d.code="ECONNRESET",e.request.emit("error",d),n.removeSocket(s)}};ti.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var n=this.requests.shift();n&&this.createSocket(n,function(s){n.request.onSocket(s)})}};function zD(t,e){var r=this;ti.prototype.createSocket.call(r,t,function(n){var s=t.request.getHeader("host"),i=zC({},r.options,{socket:n,servername:s?s.replace(/:.*$/,""):t.host}),o=D5.connect(0,i);r.sockets[r.sockets.indexOf(n)]=o,e(o)})}function GD(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function zC(t){for(var e=1,r=arguments.length;e<r;++e){var n=arguments[e];if(typeof n=="object")for(var s=Object.keys(n),i=0,o=s.length;i<o;++i){var a=s[i];n[a]!==void 0&&(t[a]=n[a])}}return t}var Oi;process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?Oi=function(){var t=Array.prototype.slice.call(arguments);typeof t[0]=="string"?t[0]="TUNNEL: "+t[0]:t.unshift("TUNNEL:"),console.error.apply(console,t)}:Oi=function(){};sc.debug=Oi});var QA=h((x0e,VD)=>{VD.exports=YD()});var Le=h((w0e,JD)=>{JD.exports={kClose:Symbol("close"),kDestroy:Symbol("destroy"),kDispatch:Symbol("dispatch"),kUrl:Symbol("url"),kWriting:Symbol("writing"),kResuming:Symbol("resuming"),kQueue:Symbol("queue"),kConnect:Symbol("connect"),kConnecting:Symbol("connecting"),kKeepAliveDefaultTimeout:Symbol("default keep alive timeout"),kKeepAliveMaxTimeout:Symbol("max keep alive timeout"),kKeepAliveTimeoutThreshold:Symbol("keep alive timeout threshold"),kKeepAliveTimeoutValue:Symbol("keep alive timeout"),kKeepAlive:Symbol("keep alive"),kHeadersTimeout:Symbol("headers timeout"),kBodyTimeout:Symbol("body timeout"),kServerName:Symbol("server name"),kLocalAddress:Symbol("local address"),kHost:Symbol("host"),kNoRef:Symbol("no ref"),kBodyUsed:Symbol("used"),kBody:Symbol("abstracted request body"),kRunning:Symbol("running"),kBlocking:Symbol("blocking"),kPending:Symbol("pending"),kSize:Symbol("size"),kBusy:Symbol("busy"),kQueued:Symbol("queued"),kFree:Symbol("free"),kConnected:Symbol("connected"),kClosed:Symbol("closed"),kNeedDrain:Symbol("need drain"),kReset:Symbol("reset"),kDestroyed:Symbol.for("nodejs.stream.destroyed"),kResume:Symbol("resume"),kOnError:Symbol("on error"),kMaxHeadersSize:Symbol("max headers size"),kRunningIdx:Symbol("running index"),kPendingIdx:Symbol("pending index"),kError:Symbol("error"),kClients:Symbol("clients"),kClient:Symbol("client"),kParser:Symbol("parser"),kOnDestroyed:Symbol("destroy callbacks"),kPipelining:Symbol("pipelining"),kSocket:Symbol("socket"),kHostHeader:Symbol("host header"),kConnector:Symbol("connector"),kStrictContentLength:Symbol("strict content length"),kMaxRedirections:Symbol("maxRedirections"),kMaxRequests:Symbol("maxRequestsPerClient"),kProxy:Symbol("proxy agent options"),kCounter:Symbol("socket request counter"),kInterceptors:Symbol("dispatch interceptors"),kMaxResponseSize:Symbol("max response size"),kHTTP2Session:Symbol("http2Session"),kHTTP2SessionState:Symbol("http2Session state"),kRetryHandlerDefaultRetry:Symbol("retry agent default retry"),kConstruct:Symbol("constructable"),kListeners:Symbol("listeners"),kHTTPContext:Symbol("http context"),kMaxConcurrentStreams:Symbol("max concurrent streams"),kNoProxyAgent:Symbol("no proxy agent"),kHttpProxyAgent:Symbol("http proxy agent"),kHttpsProxyAgent:Symbol("https proxy agent")}});var ye=h((b0e,yk)=>{"use strict";var WD=Symbol.for("undici.error.UND_ERR"),_e=class extends Error{constructor(e){super(e),this.name="UndiciError",this.code="UND_ERR"}static[Symbol.hasInstance](e){return e&&e[WD]===!0}[WD]=!0},$D=Symbol.for("undici.error.UND_ERR_CONNECT_TIMEOUT"),GC=class extends _e{constructor(e){super(e),this.name="ConnectTimeoutError",this.message=e||"Connect Timeout Error",this.code="UND_ERR_CONNECT_TIMEOUT"}static[Symbol.hasInstance](e){return e&&e[$D]===!0}[$D]=!0},jD=Symbol.for("undici.error.UND_ERR_HEADERS_TIMEOUT"),YC=class extends _e{constructor(e){super(e),this.name="HeadersTimeoutError",this.message=e||"Headers Timeout Error",this.code="UND_ERR_HEADERS_TIMEOUT"}static[Symbol.hasInstance](e){return e&&e[jD]===!0}[jD]=!0},KD=Symbol.for("undici.error.UND_ERR_HEADERS_OVERFLOW"),VC=class extends _e{constructor(e){super(e),this.name="HeadersOverflowError",this.message=e||"Headers Overflow Error",this.code="UND_ERR_HEADERS_OVERFLOW"}static[Symbol.hasInstance](e){return e&&e[KD]===!0}[KD]=!0},XD=Symbol.for("undici.error.UND_ERR_BODY_TIMEOUT"),JC=class extends _e{constructor(e){super(e),this.name="BodyTimeoutError",this.message=e||"Body Timeout Error",this.code="UND_ERR_BODY_TIMEOUT"}static[Symbol.hasInstance](e){return e&&e[XD]===!0}[XD]=!0},ZD=Symbol.for("undici.error.UND_ERR_RESPONSE_STATUS_CODE"),WC=class extends _e{constructor(e,r,n,s){super(e),this.name="ResponseStatusCodeError",this.message=e||"Response Status Code Error",this.code="UND_ERR_RESPONSE_STATUS_CODE",this.body=s,this.sta
Line truncated
|
||||
`)||t.includes("\r")||t.includes("\0"))===!1}function ej(t,e){let{headersList:r}=e,n=(r.get("referrer-policy",!0)??"").split(","),s="";if(n.length>0)for(let i=n.length;i!==0;i--){let o=n[i-1].trim();if(F6.has(o)){s=o;break}}s!==""&&(t.referrerPolicy=s)}function tj(){return"allowed"}function rj(){return"success"}function nj(){return"success"}function sj(t){let e=null;e=t.mode,t.headersList.set("sec-fetch-mode",e,!0)}function ij(t){let e=t.origin;if(!(e==="client"||e===void 0)){if(t.responseTainting==="cors"||t.mode==="websocket")t.headersList.append("origin",e,!0);else if(t.method!=="GET"&&t.method!=="HEAD"){switch(t.referrerPolicy){case"no-referrer":e=null;break;case"no-referrer-when-downgrade":case"strict-origin":case"strict-origin-when-cross-origin":t.origin&&UI(t.origin)&&!UI(DA(t))&&(e=null);break;case"same-origin":lp(t,DA(t))||(e=null);break;default:}t.headersList.append("origin",e,!0)}}}function pc(t,e){return t}function oj(t,e,r){return!t?.startTime||t.startTime<e?{domainLookupStartTime:e,domainLookupEndTime:e,connectionStartTime:e,connectionEndTime:e,secureConnectionStartTime:e,ALPNNegotiatedProtocol:t?.ALPNNegotiatedProtocol}:{domainLookupStartTime:pc(t.domainLookupStartTime,r),domainLookupEndTime:pc(t.domainLookupEndTime,r),connectionStartTime:pc(t.connectionStartTime,r),connectionEndTime:pc(t.connectionEndTime,r),secureConnectionStartTime:pc(t.secureConnectionStartTime,r),ALPNNegotiatedProtocol:t.ALPNNegotiatedProtocol}}function aj(t){return pc(z6.now(),t)}function cj(t){return{startTime:t.startTime??0,redirectStartTime:0,redirectEndTime:0,postRedirectStartTime:t.startTime??0,finalServiceWorkerStartTime:0,finalNetworkResponseStartTime:0,finalNetworkRequestStartTime:0,endTime:0,encodedBodySize:0,decodedBodySize:0,finalConnectionTimingInfo:null}}function kT(){return{referrerPolicy:"strict-origin-when-cross-origin"}}function lj(t){return{referrerPolicy:t.referrerPolicy}}function Aj(t){let e=t.referrerPolicy;qo(e);let r=null;if(t.referrer==="client"){let a=NT();if(!a||a.origin==="null")return"no-referrer";r=new URL(a)}else t.referrer instanceof URL&&(r=t.referrer);let n=FI(r),s=FI(r,!0);n.toString().length>4096&&(n=s);let i=lp(t,n),o=vA(n)&&!vA(t.url);switch(e){case"origin":return s??FI(r,!0);case"unsafe-url":return n;case"same-origin":return i?s:"no-referrer";case"origin-when-cross-origin":return i?n:s;case"strict-origin-when-cross-origin":{let a=DA(t);return lp(n,a)?n:vA(n)&&!vA(a)?"no-referrer":s}default:return o?"no-referrer":s}}function FI(t,e){return qo(t instanceof URL),t=new URL(t),t.protocol==="file:"||t.protocol==="about:"||t.protocol==="blank:"?"no-referrer":(t.username="",t.password="",t.hash="",e&&(t.pathname="",t.search=""),t)}function vA(t){if(!(t instanceof URL))return!1;if(t.href==="about:blank"||t.href==="about:srcdoc"||t.protocol==="data:"||t.protocol==="file:")return!0;return e(t.origin);function e(r){if(r==null||r==="null")return!1;let n=new URL(r);return!!(n.protocol==="https:"||n.protocol==="wss:"||/^127(?:\.[0-9]+){0,2}\.[0-9]+$|^\[(?:0*:)*?:?0*1\]$/.test(n.hostname)||n.hostname==="localhost"||n.hostname.includes("localhost.")||n.hostname.endsWith(".localhost"))}}function uj(t,e){if(cp===void 0)return!0;let r=TT(e);if(r==="no metadata"||r.length===0)return!0;let n=mj(r),s=pj(r,n);for(let i of s){let o=i.algo,a=i.hash,c=cp.createHash(o).update(t).digest("base64");if(c[c.length-1]==="="&&(c[c.length-2]==="="?c=c.slice(0,-2):c=c.slice(0,-1)),hj(c,a))return!0}return!1}var dj=/(?<algo>sha256|sha384|sha512)-((?<hash>[A-Za-z0-9+/]+|[A-Za-z0-9_-]+)={0,2}(?:\s|$)( +[!-~]*)?)?/i;function TT(t){let e=[],r=!0;for(let n of t.split(" ")){r=!1;let s=dj.exec(n);if(s===null||s.groups===void 0||s.groups.algo===void 0)continue;let i=s.groups.algo.toLowerCase();RT.includes(i)&&e.push(s.groups)}return r===!0?"no metadata":e}function mj(t){let e=t[0].algo;if(e[3]==="5")return e;for(let r=1;r<t.length;++r){let n=t[r];if(n.algo[3]==="5"){e="sha512";break}else{if(e[3]==="3")continue;n.algo[3]==="3"&&(e="sha384")}}return e}function pj(t,e){if(t.length===1)return t;let r=0;for(let n=0;n<t.length;++n)t[n].algo===e&&(t[r++]=t[n]);return t.length=r,t}function hj(t,e){if(t.length!==e.length)return!1;for(let r=0;r<t.length;++r)if(t[r]!==e[r]){if(t[r]==="+"&&e[r]==="-"||t[r]==="/"&&e[r]==="_")continue;return!1}return!0}function fj(t){}function lp(t,e){return t.origin===e.origin&&t.origin==="null"||t.protocol===e.protocol&&t.hostname===e.hostname&&t.port===e.port}function gj(){let t,e;return{promise:new Promise((n,s)=>{t=n,e=s}),resolve:t,reject:e}}function yj(t){return t.controller.state==="aborted"}function Ej(t){return t.controller.state==="aborted"||t.controller.state==="terminated"}function Cj(t){return V6[t.toLowerCase()]??t}function Ij(t){let e=JSON.stringify(t);if(e===void 0)throw new TypeError("Value is not JSON serializable");return qo(typeof e=="string"),e}var Bj=Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]()));function MT(t,e,r=0,n=1){class s{#e;#t;#r;constructor(o,a){this.#e=o,
Line truncated
|
||||
`);function Xj(t){for(let e=0;e<t.length;++e)if((t.charCodeAt(e)&-128)!==0)return!1;return!0}function Zj(t){let e=t.length;if(e<27||e>70)return!1;for(let r=0;r<e;++r){let n=t.charCodeAt(r);if(!(n>=48&&n<=57||n>=65&&n<=90||n>=97&&n<=122||n===39||n===45||n===95))return!1}return!0}function eK(t,e){up(e!=="failure"&&e.essence==="multipart/form-data");let r=e.parameters.get("boundary");if(r===void 0)return"failure";let n=Buffer.from(`--${r}`,"utf8"),s=[],i={position:0};for(;t[i.position]===13&&t[i.position+1]===10;)i.position+=2;let o=t.length;for(;t[o-1]===10&&t[o-2]===13;)o-=2;for(o!==t.length&&(t=t.subarray(0,o));;){if(t.subarray(i.position,i.position+n.length).equals(n))i.position+=n.length;else return"failure";if(i.position===t.length-2&&dp(t,jj,i)||i.position===t.length-4&&dp(t,Kj,i))return s;if(t[i.position]!==13||t[i.position+1]!==10)return"failure";i.position+=2;let a=tK(t,i);if(a==="failure")return"failure";let{name:c,filename:l,contentType:A,encoding:u}=a;i.position+=2;let d;{let p=t.indexOf(n.subarray(2),i.position);if(p===-1)return"failure";d=t.subarray(i.position,p-4),i.position+=d.length,u==="base64"&&(d=Buffer.from(d.toString(),"base64"))}if(t[i.position]!==13||t[i.position+1]!==10)return"failure";i.position+=2;let m;l!==null?(A??="text/plain",Xj(A)||(A=""),m=new Wj([d],l,{type:A})):m=zj(Buffer.from(d)),up(JT(c)),up(typeof m=="string"&&JT(m)||Yj(m)),s.push(Vj(c,m,l))}}function tK(t,e){let r=null,n=null,s=null,i=null;for(;;){if(t[e.position]===13&&t[e.position+1]===10)return r===null?"failure":{name:r,filename:n,contentType:s,encoding:i};let o=fc(a=>a!==10&&a!==13&&a!==58,t,e);if(o=VI(o,!0,!0,a=>a===9||a===32),!Gj.test(o.toString())||t[e.position]!==58)return"failure";switch(e.position++,fc(a=>a===32||a===9,t,e),Hj(o)){case"content-disposition":{if(r=n=null,!dp(t,$j,e)||(e.position+=17,r=jT(t,e),r===null))return"failure";if(dp(t,$T,e)){let a=e.position+$T.length;if(t[a]===42&&(e.position+=1,a+=1),t[a]!==61||t[a+1]!==34||(e.position+=12,n=jT(t,e),n===null))return"failure"}break}case"content-type":{let a=fc(c=>c!==10&&c!==13,t,e);a=VI(a,!1,!0,c=>c===9||c===32),s=WT(a);break}case"content-transfer-encoding":{let a=fc(c=>c!==10&&c!==13,t,e);a=VI(a,!1,!0,c=>c===9||c===32),i=WT(a);break}default:fc(a=>a!==10&&a!==13,t,e)}if(t[e.position]!==13&&t[e.position+1]!==10)return"failure";e.position+=2}}function jT(t,e){up(t[e.position-1]===34);let r=fc(n=>n!==10&&n!==13&&n!==34,t,e);return t[e.position]!==34?null:(e.position++,r=new TextDecoder().decode(r).replace(/%0A/ig,`
|
||||
`).replace(/%0D/ig,"\r").replace(/%22/g,'"'),r)}function fc(t,e,r){let n=r.position;for(;n<e.length&&t(e[n]);)++n;return e.subarray(r.position,r.position=n)}function VI(t,e,r,n){let s=0,i=t.length-1;if(e)for(;s<t.length&&n(t[s]);)s++;if(r)for(;i>0&&n(t[i]);)i--;return s===0&&i===t.length-1?t:t.subarray(s,i+1)}function dp(t,e,r){if(t.length<e.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[r.position+n])return!1;return!0}KT.exports={multipartFormDataParser:eK,validateBoundary:Zj}});var Ec=h((K0e,cM)=>{"use strict";var MA=ce(),{ReadableStreamFrom:rK,isBlobLike:ZT,isReadableStreamLike:nK,readableStreamClose:sK,createDeferredPromise:iK,fullyReadBody:oK,extractMimeType:aK,utf8DecodeBytes:rM}=br(),{FormData:eM}=TA(),{kState:yc}=qi(),{webidl:cK}=vt(),{Blob:lK}=require("node:buffer"),JI=require("node:assert"),{isErrored:nM,isDisturbed:AK}=require("node:stream"),{isArrayBuffer:uK}=require("node:util/types"),{serializeAMimeType:dK}=ir(),{multipartFormDataParser:mK}=XT(),WI;try{let t=require("node:crypto");WI=e=>t.randomInt(0,e)}catch{WI=t=>Math.floor(Math.random(t))}var mp=new TextEncoder;function pK(){}var sM=globalThis.FinalizationRegistry&&process.version.indexOf("v18")!==0,iM;sM&&(iM=new FinalizationRegistry(t=>{let e=t.deref();e&&!e.locked&&!AK(e)&&!nM(e)&&e.cancel("Response object has been garbage collected").catch(pK)}));function oM(t,e=!1){let r=null;t instanceof ReadableStream?r=t:ZT(t)?r=t.stream():r=new ReadableStream({async pull(c){let l=typeof s=="string"?mp.encode(s):s;l.byteLength&&c.enqueue(l),queueMicrotask(()=>sK(c))},start(){},type:"bytes"}),JI(nK(r));let n=null,s=null,i=null,o=null;if(typeof t=="string")s=t,o="text/plain;charset=UTF-8";else if(t instanceof URLSearchParams)s=t.toString(),o="application/x-www-form-urlencoded;charset=UTF-8";else if(uK(t))s=new Uint8Array(t.slice());else if(ArrayBuffer.isView(t))s=new Uint8Array(t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength));else if(MA.isFormDataLike(t)){let c=`----formdata-undici-0${`${WI(1e11)}`.padStart(11,"0")}`,l=`--${c}\r
|
||||
var r5=Object.create;var bC=Object.defineProperty;var n5=Object.getOwnPropertyDescriptor;var s5=Object.getOwnPropertyNames;var i5=Object.getPrototypeOf,o5=Object.prototype.hasOwnProperty;var h=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),a5=(t,e)=>{for(var r in e)bC(t,r,{get:e[r],enumerable:!0})},c5=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of s5(e))!o5.call(t,s)&&s!==r&&bC(t,s,{get:()=>e[s],enumerable:!(n=n5(e,s))||n.enumerable});return t};var B=(t,e,r)=>(r=t!=null?r5(i5(t)):{},c5(e||!t||!t.__esModule?bC(r,"default",{value:t,enumerable:!0}):r,t));var vD=h(Za=>{"use strict";var Vwe=require("net"),d5=require("tls"),vC=require("http"),SD=require("https"),m5=require("events"),Jwe=require("assert"),p5=require("util");Za.httpOverHttp=h5;Za.httpsOverHttp=f5;Za.httpOverHttps=g5;Za.httpsOverHttps=y5;function h5(t){var e=new ti(t);return e.request=vC.request,e}function f5(t){var e=new ti(t);return e.request=vC.request,e.createSocket=RD,e.defaultPort=443,e}function g5(t){var e=new ti(t);return e.request=SD.request,e}function y5(t){var e=new ti(t);return e.request=SD.request,e.createSocket=RD,e.defaultPort=443,e}function ti(t){var e=this;e.options=t||{},e.proxyOptions=e.options.proxy||{},e.maxSockets=e.options.maxSockets||vC.Agent.defaultMaxSockets,e.requests=[],e.sockets=[],e.on("free",function(n,s,i,o){for(var a=PD(s,i,o),c=0,l=e.requests.length;c<l;++c){var A=e.requests[c];if(A.host===a.host&&A.port===a.port){e.requests.splice(c,1),A.request.onSocket(n);return}}n.destroy(),e.removeSocket(n)})}p5.inherits(ti,m5.EventEmitter);ti.prototype.addRequest=function(e,r,n,s){var i=this,o=DC({request:e},i.options,PD(r,n,s));if(i.sockets.length>=this.maxSockets){i.requests.push(o);return}i.createSocket(o,function(a){a.on("free",c),a.on("close",l),a.on("agentRemove",l),e.onSocket(a);function c(){i.emit("free",a,o)}function l(A){i.removeSocket(a),a.removeListener("free",c),a.removeListener("close",l),a.removeListener("agentRemove",l)}})};ti.prototype.createSocket=function(e,r){var n=this,s={};n.sockets.push(s);var i=DC({},n.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(i.localAddress=e.localAddress),i.proxyAuth&&(i.headers=i.headers||{},i.headers["Proxy-Authorization"]="Basic "+new Buffer(i.proxyAuth).toString("base64")),Oi("making CONNECT request");var o=n.request(i);o.useChunkedEncodingByDefault=!1,o.once("response",a),o.once("upgrade",c),o.once("connect",l),o.once("error",A),o.end();function a(u){u.upgrade=!0}function c(u,d,m){process.nextTick(function(){l(u,d,m)})}function l(u,d,m){if(o.removeAllListeners(),d.removeAllListeners(),u.statusCode!==200){Oi("tunneling socket could not be established, statusCode=%d",u.statusCode),d.destroy();var p=new Error("tunneling socket could not be established, statusCode="+u.statusCode);p.code="ECONNRESET",e.request.emit("error",p),n.removeSocket(s);return}if(m.length>0){Oi("got illegal response body from proxy"),d.destroy();var p=new Error("got illegal response body from proxy");p.code="ECONNRESET",e.request.emit("error",p),n.removeSocket(s);return}return Oi("tunneling connection has established"),n.sockets[n.sockets.indexOf(s)]=d,r(d)}function A(u){o.removeAllListeners(),Oi(`tunneling socket could not be established, cause=%s
|
||||
`,u.message,u.stack);var d=new Error("tunneling socket could not be established, cause="+u.message);d.code="ECONNRESET",e.request.emit("error",d),n.removeSocket(s)}};ti.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var n=this.requests.shift();n&&this.createSocket(n,function(s){n.request.onSocket(s)})}};function RD(t,e){var r=this;ti.prototype.createSocket.call(r,t,function(n){var s=t.request.getHeader("host"),i=DC({},r.options,{socket:n,servername:s?s.replace(/:.*$/,""):t.host}),o=d5.connect(0,i);r.sockets[r.sockets.indexOf(n)]=o,e(o)})}function PD(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function DC(t){for(var e=1,r=arguments.length;e<r;++e){var n=arguments[e];if(typeof n=="object")for(var s=Object.keys(n),i=0,o=s.length;i<o;++i){var a=s[i];n[a]!==void 0&&(t[a]=n[a])}}return t}var Oi;process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?Oi=function(){var t=Array.prototype.slice.call(arguments);typeof t[0]=="string"?t[0]="TUNNEL: "+t[0]:t.unshift("TUNNEL:"),console.error.apply(console,t)}:Oi=function(){};Za.debug=Oi});var kC=h(($we,DD)=>{DD.exports=vD()});var Le=h((jwe,kD)=>{kD.exports={kClose:Symbol("close"),kDestroy:Symbol("destroy"),kDispatch:Symbol("dispatch"),kUrl:Symbol("url"),kWriting:Symbol("writing"),kResuming:Symbol("resuming"),kQueue:Symbol("queue"),kConnect:Symbol("connect"),kConnecting:Symbol("connecting"),kKeepAliveDefaultTimeout:Symbol("default keep alive timeout"),kKeepAliveMaxTimeout:Symbol("max keep alive timeout"),kKeepAliveTimeoutThreshold:Symbol("keep alive timeout threshold"),kKeepAliveTimeoutValue:Symbol("keep alive timeout"),kKeepAlive:Symbol("keep alive"),kHeadersTimeout:Symbol("headers timeout"),kBodyTimeout:Symbol("body timeout"),kServerName:Symbol("server name"),kLocalAddress:Symbol("local address"),kHost:Symbol("host"),kNoRef:Symbol("no ref"),kBodyUsed:Symbol("used"),kBody:Symbol("abstracted request body"),kRunning:Symbol("running"),kBlocking:Symbol("blocking"),kPending:Symbol("pending"),kSize:Symbol("size"),kBusy:Symbol("busy"),kQueued:Symbol("queued"),kFree:Symbol("free"),kConnected:Symbol("connected"),kClosed:Symbol("closed"),kNeedDrain:Symbol("need drain"),kReset:Symbol("reset"),kDestroyed:Symbol.for("nodejs.stream.destroyed"),kResume:Symbol("resume"),kOnError:Symbol("on error"),kMaxHeadersSize:Symbol("max headers size"),kRunningIdx:Symbol("running index"),kPendingIdx:Symbol("pending index"),kError:Symbol("error"),kClients:Symbol("clients"),kClient:Symbol("client"),kParser:Symbol("parser"),kOnDestroyed:Symbol("destroy callbacks"),kPipelining:Symbol("pipelining"),kSocket:Symbol("socket"),kHostHeader:Symbol("host header"),kConnector:Symbol("connector"),kStrictContentLength:Symbol("strict content length"),kMaxRedirections:Symbol("maxRedirections"),kMaxRequests:Symbol("maxRequestsPerClient"),kProxy:Symbol("proxy agent options"),kCounter:Symbol("socket request counter"),kInterceptors:Symbol("dispatch interceptors"),kMaxResponseSize:Symbol("max response size"),kHTTP2Session:Symbol("http2Session"),kHTTP2SessionState:Symbol("http2Session state"),kRetryHandlerDefaultRetry:Symbol("retry agent default retry"),kConstruct:Symbol("constructable"),kListeners:Symbol("listeners"),kHTTPContext:Symbol("http context"),kMaxConcurrentStreams:Symbol("max concurrent streams"),kNoProxyAgent:Symbol("no proxy agent"),kHttpProxyAgent:Symbol("http proxy agent"),kHttpsProxyAgent:Symbol("https proxy agent")}});var Ee=h((Kwe,sk)=>{"use strict";var TD=Symbol.for("undici.error.UND_ERR"),Fe=class extends Error{constructor(e){super(e),this.name="UndiciError",this.code="UND_ERR"}static[Symbol.hasInstance](e){return e&&e[TD]===!0}[TD]=!0},MD=Symbol.for("undici.error.UND_ERR_CONNECT_TIMEOUT"),TC=class extends Fe{constructor(e){super(e),this.name="ConnectTimeoutError",this.message=e||"Connect Timeout Error",this.code="UND_ERR_CONNECT_TIMEOUT"}static[Symbol.hasInstance](e){return e&&e[MD]===!0}[MD]=!0},LD=Symbol.for("undici.error.UND_ERR_HEADERS_TIMEOUT"),MC=class extends Fe{constructor(e){super(e),this.name="HeadersTimeoutError",this.message=e||"Headers Timeout Error",this.code="UND_ERR_HEADERS_TIMEOUT"}static[Symbol.hasInstance](e){return e&&e[LD]===!0}[LD]=!0},FD=Symbol.for("undici.error.UND_ERR_HEADERS_OVERFLOW"),LC=class extends Fe{constructor(e){super(e),this.name="HeadersOverflowError",this.message=e||"Headers Overflow Error",this.code="UND_ERR_HEADERS_OVERFLOW"}static[Symbol.hasInstance](e){return e&&e[FD]===!0}[FD]=!0},_D=Symbol.for("undici.error.UND_ERR_BODY_TIMEOUT"),FC=class extends Fe{constructor(e){super(e),this.name="BodyTimeoutError",this.message=e||"Body Timeout Error",this.code="UND_ERR_BODY_TIMEOUT"}static[Symbol.hasInstance](e){return e&&e[_D]===!0}[_D]=!0},UD=Symbol.for("undici.error.UND_ERR_RESPONSE_STATUS_CODE"),_C=class extends Fe{constructor(e,r,n,s){super(e),this.name="ResponseStatusCodeError",this.message=e||"Response Status Code Error",this.code="UND_ERR_RESPONSE_STATUS_CODE",this.body=s,this.sta
Line truncated
|
||||
`)||t.includes("\r")||t.includes("\0"))===!1}function T6(t,e){let{headersList:r}=e,n=(r.get("referrer-policy",!0)??"").split(","),s="";if(n.length>0)for(let i=n.length;i!==0;i--){let o=n[i-1].trim();if(y6.has(o)){s=o;break}}s!==""&&(t.referrerPolicy=s)}function M6(){return"allowed"}function L6(){return"success"}function F6(){return"success"}function _6(t){let e=null;e=t.mode,t.headersList.set("sec-fetch-mode",e,!0)}function U6(t){let e=t.origin;if(!(e==="client"||e===void 0)){if(t.responseTainting==="cors"||t.mode==="websocket")t.headersList.append("origin",e,!0);else if(t.method!=="GET"&&t.method!=="HEAD"){switch(t.referrerPolicy){case"no-referrer":e=null;break;case"no-referrer-when-downgrade":case"strict-origin":case"strict-origin-when-cross-origin":t.origin&&RI(t.origin)&&!RI(NA(t))&&(e=null);break;case"same-origin":ep(t,NA(t))||(e=null);break;default:}t.headersList.append("origin",e,!0)}}}function lc(t,e){return t}function O6(t,e,r){return!t?.startTime||t.startTime<e?{domainLookupStartTime:e,domainLookupEndTime:e,connectionStartTime:e,connectionEndTime:e,secureConnectionStartTime:e,ALPNNegotiatedProtocol:t?.ALPNNegotiatedProtocol}:{domainLookupStartTime:lc(t.domainLookupStartTime,r),domainLookupEndTime:lc(t.domainLookupEndTime,r),connectionStartTime:lc(t.connectionStartTime,r),connectionEndTime:lc(t.connectionEndTime,r),secureConnectionStartTime:lc(t.secureConnectionStartTime,r),ALPNNegotiatedProtocol:t.ALPNNegotiatedProtocol}}function q6(t){return lc(Q6.now(),t)}function H6(t){return{startTime:t.startTime??0,redirectStartTime:0,redirectEndTime:0,postRedirectStartTime:t.startTime??0,finalServiceWorkerStartTime:0,finalNetworkResponseStartTime:0,finalNetworkRequestStartTime:0,endTime:0,encodedBodySize:0,decodedBodySize:0,finalConnectionTimingInfo:null}}function ET(){return{referrerPolicy:"strict-origin-when-cross-origin"}}function z6(t){return{referrerPolicy:t.referrerPolicy}}function G6(t){let e=t.referrerPolicy;_o(e);let r=null;if(t.referrer==="client"){let a=mT();if(!a||a.origin==="null")return"no-referrer";r=new URL(a)}else t.referrer instanceof URL&&(r=t.referrer);let n=SI(r),s=SI(r,!0);n.toString().length>4096&&(n=s);let i=ep(t,n),o=wA(n)&&!wA(t.url);switch(e){case"origin":return s??SI(r,!0);case"unsafe-url":return n;case"same-origin":return i?s:"no-referrer";case"origin-when-cross-origin":return i?n:s;case"strict-origin-when-cross-origin":{let a=NA(t);return ep(n,a)?n:wA(n)&&!wA(a)?"no-referrer":s}default:return o?"no-referrer":s}}function SI(t,e){return _o(t instanceof URL),t=new URL(t),t.protocol==="file:"||t.protocol==="about:"||t.protocol==="blank:"?"no-referrer":(t.username="",t.password="",t.hash="",e&&(t.pathname="",t.search=""),t)}function wA(t){if(!(t instanceof URL))return!1;if(t.href==="about:blank"||t.href==="about:srcdoc"||t.protocol==="data:"||t.protocol==="file:")return!0;return e(t.origin);function e(r){if(r==null||r==="null")return!1;let n=new URL(r);return!!(n.protocol==="https:"||n.protocol==="wss:"||/^127(?:\.[0-9]+){0,2}\.[0-9]+$|^\[(?:0*:)*?:?0*1\]$/.test(n.hostname)||n.hostname==="localhost"||n.hostname.includes("localhost.")||n.hostname.endsWith(".localhost"))}}function Y6(t,e){if(Zm===void 0)return!0;let r=CT(e);if(r==="no metadata"||r.length===0)return!0;let n=J6(r),s=W6(r,n);for(let i of s){let o=i.algo,a=i.hash,c=Zm.createHash(o).update(t).digest("base64");if(c[c.length-1]==="="&&(c[c.length-2]==="="?c=c.slice(0,-2):c=c.slice(0,-1)),$6(c,a))return!0}return!1}var V6=/(?<algo>sha256|sha384|sha512)-((?<hash>[A-Za-z0-9+/]+|[A-Za-z0-9_-]+)={0,2}(?:\s|$)( +[!-~]*)?)?/i;function CT(t){let e=[],r=!0;for(let n of t.split(" ")){r=!1;let s=V6.exec(n);if(s===null||s.groups===void 0||s.groups.algo===void 0)continue;let i=s.groups.algo.toLowerCase();hT.includes(i)&&e.push(s.groups)}return r===!0?"no metadata":e}function J6(t){let e=t[0].algo;if(e[3]==="5")return e;for(let r=1;r<t.length;++r){let n=t[r];if(n.algo[3]==="5"){e="sha512";break}else{if(e[3]==="3")continue;n.algo[3]==="3"&&(e="sha384")}}return e}function W6(t,e){if(t.length===1)return t;let r=0;for(let n=0;n<t.length;++n)t[n].algo===e&&(t[r++]=t[n]);return t.length=r,t}function $6(t,e){if(t.length!==e.length)return!1;for(let r=0;r<t.length;++r)if(t[r]!==e[r]){if(t[r]==="+"&&e[r]==="-"||t[r]==="/"&&e[r]==="_")continue;return!1}return!0}function j6(t){}function ep(t,e){return t.origin===e.origin&&t.origin==="null"||t.protocol===e.protocol&&t.hostname===e.hostname&&t.port===e.port}function K6(){let t,e;return{promise:new Promise((n,s)=>{t=n,e=s}),resolve:t,reject:e}}function X6(t){return t.controller.state==="aborted"}function Z6(t){return t.controller.state==="aborted"||t.controller.state==="terminated"}function ej(t){return w6[t.toLowerCase()]??t}function tj(t){let e=JSON.stringify(t);if(e===void 0)throw new TypeError("Value is not JSON serializable");return _o(typeof e=="string"),e}var rj=Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]()));function IT(t,e,r=0,n=1){class s{#e;#t;#r;constructor(o,a){this.#e=o,
Line truncated
|
||||
`);function Dj(t){for(let e=0;e<t.length;++e)if((t.charCodeAt(e)&-128)!==0)return!1;return!0}function kj(t){let e=t.length;if(e<27||e>70)return!1;for(let r=0;r<e;++r){let n=t.charCodeAt(r);if(!(n>=48&&n<=57||n>=65&&n<=90||n>=97&&n<=122||n===39||n===45||n===95))return!1}return!0}function Tj(t,e){rp(e!=="failure"&&e.essence==="multipart/form-data");let r=e.parameters.get("boundary");if(r===void 0)return"failure";let n=Buffer.from(`--${r}`,"utf8"),s=[],i={position:0};for(;t[i.position]===13&&t[i.position+1]===10;)i.position+=2;let o=t.length;for(;t[o-1]===10&&t[o-2]===13;)o-=2;for(o!==t.length&&(t=t.subarray(0,o));;){if(t.subarray(i.position,i.position+n.length).equals(n))i.position+=n.length;else return"failure";if(i.position===t.length-2&&np(t,Pj,i)||i.position===t.length-4&&np(t,vj,i))return s;if(t[i.position]!==13||t[i.position+1]!==10)return"failure";i.position+=2;let a=Mj(t,i);if(a==="failure")return"failure";let{name:c,filename:l,contentType:A,encoding:u}=a;i.position+=2;let d;{let p=t.indexOf(n.subarray(2),i.position);if(p===-1)return"failure";d=t.subarray(i.position,p-4),i.position+=d.length,u==="base64"&&(d=Buffer.from(d.toString(),"base64"))}if(t[i.position]!==13||t[i.position+1]!==10)return"failure";i.position+=2;let m;l!==null?(A??="text/plain",Dj(A)||(A=""),m=new Sj([d],l,{type:A})):m=Qj(Buffer.from(d)),rp(kT(c)),rp(typeof m=="string"&&kT(m)||bj(m)),s.push(wj(c,m,l))}}function Mj(t,e){let r=null,n=null,s=null,i=null;for(;;){if(t[e.position]===13&&t[e.position+1]===10)return r===null?"failure":{name:r,filename:n,contentType:s,encoding:i};let o=uc(a=>a!==10&&a!==13&&a!==58,t,e);if(o=LI(o,!0,!0,a=>a===9||a===32),!xj.test(o.toString())||t[e.position]!==58)return"failure";switch(e.position++,uc(a=>a===32||a===9,t,e),Bj(o)){case"content-disposition":{if(r=n=null,!np(t,Rj,e)||(e.position+=17,r=LT(t,e),r===null))return"failure";if(np(t,MT,e)){let a=e.position+MT.length;if(t[a]===42&&(e.position+=1,a+=1),t[a]!==61||t[a+1]!==34||(e.position+=12,n=LT(t,e),n===null))return"failure"}break}case"content-type":{let a=uc(c=>c!==10&&c!==13,t,e);a=LI(a,!1,!0,c=>c===9||c===32),s=TT(a);break}case"content-transfer-encoding":{let a=uc(c=>c!==10&&c!==13,t,e);a=LI(a,!1,!0,c=>c===9||c===32),i=TT(a);break}default:uc(a=>a!==10&&a!==13,t,e)}if(t[e.position]!==13&&t[e.position+1]!==10)return"failure";e.position+=2}}function LT(t,e){rp(t[e.position-1]===34);let r=uc(n=>n!==10&&n!==13&&n!==34,t,e);return t[e.position]!==34?null:(e.position++,r=new TextDecoder().decode(r).replace(/%0A/ig,`
|
||||
`).replace(/%0D/ig,"\r").replace(/%22/g,'"'),r)}function uc(t,e,r){let n=r.position;for(;n<e.length&&t(e[n]);)++n;return e.subarray(r.position,r.position=n)}function LI(t,e,r,n){let s=0,i=t.length-1;if(e)for(;s<t.length&&n(t[s]);)s++;if(r)for(;i>0&&n(t[i]);)i--;return s===0&&i===t.length-1?t:t.subarray(s,i+1)}function np(t,e,r){if(t.length<e.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[r.position+n])return!1;return!0}FT.exports={multipartFormDataParser:Tj,validateBoundary:kj}});var pc=h((BNe,WT)=>{"use strict";var PA=ce(),{ReadableStreamFrom:Lj,isBlobLike:UT,isReadableStreamLike:Fj,readableStreamClose:_j,createDeferredPromise:Uj,fullyReadBody:Oj,extractMimeType:qj,utf8DecodeBytes:HT}=Sr(),{FormData:OT}=RA(),{kState:mc}=qi(),{webidl:Hj}=vt(),{Blob:zj}=require("node:buffer"),FI=require("node:assert"),{isErrored:zT,isDisturbed:Gj}=require("node:stream"),{isArrayBuffer:Yj}=require("node:util/types"),{serializeAMimeType:Vj}=or(),{multipartFormDataParser:Jj}=_T(),_I;try{let t=require("node:crypto");_I=e=>t.randomInt(0,e)}catch{_I=t=>Math.floor(Math.random(t))}var sp=new TextEncoder;function Wj(){}var GT=globalThis.FinalizationRegistry&&process.version.indexOf("v18")!==0,YT;GT&&(YT=new FinalizationRegistry(t=>{let e=t.deref();e&&!e.locked&&!Gj(e)&&!zT(e)&&e.cancel("Response object has been garbage collected").catch(Wj)}));function VT(t,e=!1){let r=null;t instanceof ReadableStream?r=t:UT(t)?r=t.stream():r=new ReadableStream({async pull(c){let l=typeof s=="string"?sp.encode(s):s;l.byteLength&&c.enqueue(l),queueMicrotask(()=>_j(c))},start(){},type:"bytes"}),FI(Fj(r));let n=null,s=null,i=null,o=null;if(typeof t=="string")s=t,o="text/plain;charset=UTF-8";else if(t instanceof URLSearchParams)s=t.toString(),o="application/x-www-form-urlencoded;charset=UTF-8";else if(Yj(t))s=new Uint8Array(t.slice());else if(ArrayBuffer.isView(t))s=new Uint8Array(t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength));else if(PA.isFormDataLike(t)){let c=`----formdata-undici-0${`${_I(1e11)}`.padStart(11,"0")}`,l=`--${c}\r
|
||||
Content-Disposition: form-data`;let A=E=>E.replace(/\n/g,"%0A").replace(/\r/g,"%0D").replace(/"/g,"%22"),u=E=>E.replace(/\r?\n|\r/g,`\r
|
||||
`),d=[],m=new Uint8Array([13,10]);i=0;let p=!1;for(let[E,g]of t)if(typeof g=="string"){let y=mp.encode(l+`; name="${A(u(E))}"\r
|
||||
`),d=[],m=new Uint8Array([13,10]);i=0;let p=!1;for(let[E,g]of t)if(typeof g=="string"){let y=sp.encode(l+`; name="${A(u(E))}"\r
|
||||
\r
|
||||
${u(g)}\r
|
||||
`);d.push(y),i+=y.byteLength}else{let y=mp.encode(`${l}; name="${A(u(E))}"`+(g.name?`; filename="${A(g.name)}"`:"")+`\r
|
||||
`);d.push(y),i+=y.byteLength}else{let y=sp.encode(`${l}; name="${A(u(E))}"`+(g.name?`; filename="${A(g.name)}"`:"")+`\r
|
||||
Content-Type: ${g.type||"application/octet-stream"}\r
|
||||
\r
|
||||
`);d.push(y,g,m),typeof g.size=="number"?i+=y.byteLength+g.size+m.byteLength:p=!0}let f=mp.encode(`--${c}--\r
|
||||
`);d.push(f),i+=f.byteLength,p&&(i=null),s=t,n=async function*(){for(let E of d)E.stream?yield*E.stream():yield E},o=`multipart/form-data; boundary=${c}`}else if(ZT(t))s=t,i=t.size,t.type&&(o=t.type);else if(typeof t[Symbol.asyncIterator]=="function"){if(e)throw new TypeError("keepalive");if(MA.isDisturbed(t)||t.locked)throw new TypeError("Response body object should not be disturbed or locked");r=t instanceof ReadableStream?t:rK(t)}if((typeof s=="string"||MA.isBuffer(s))&&(i=Buffer.byteLength(s)),n!=null){let c;r=new ReadableStream({async start(){c=n(t)[Symbol.asyncIterator]()},async pull(l){let{value:A,done:u}=await c.next();if(u)queueMicrotask(()=>{l.close(),l.byobRequest?.respond(0)});else if(!nM(r)){let d=new Uint8Array(A);d.byteLength&&l.enqueue(d)}return l.desiredSize>0},async cancel(l){await c.return()},type:"bytes"})}return[{stream:r,source:s,length:i},o]}function hK(t,e=!1){return t instanceof ReadableStream&&(JI(!MA.isDisturbed(t),"The body has already been consumed."),JI(!t.locked,"The stream is locked.")),oM(t,e)}function fK(t,e){let[r,n]=e.stream.tee();return e.stream=r,{stream:n,length:e.length,source:e.source}}function gK(t){if(t.aborted)throw new DOMException("The operation was aborted.","AbortError")}function yK(t){return{blob(){return gc(this,r=>{let n=tM(this);return n===null?n="":n&&(n=dK(n)),new lK([r],{type:n})},t)},arrayBuffer(){return gc(this,r=>new Uint8Array(r).buffer,t)},text(){return gc(this,rM,t)},json(){return gc(this,CK,t)},formData(){return gc(this,r=>{let n=tM(this);if(n!==null)switch(n.essence){case"multipart/form-data":{let s=mK(r,n);if(s==="failure")throw new TypeError("Failed to parse body as FormData.");let i=new eM;return i[yc]=s,i}case"application/x-www-form-urlencoded":{let s=new URLSearchParams(r.toString()),i=new eM;for(let[o,a]of s)i.append(o,a);return i}}throw new TypeError('Content-Type was not one of "multipart/form-data" or "application/x-www-form-urlencoded".')},t)},bytes(){return gc(this,r=>new Uint8Array(r),t)}}}function EK(t){Object.assign(t.prototype,yK(t))}async function gc(t,e,r){if(cK.brandCheck(t,r),aM(t))throw new TypeError("Body is unusable: Body has already been read");gK(t[yc]);let n=iK(),s=o=>n.reject(o),i=o=>{try{n.resolve(e(o))}catch(a){s(a)}};return t[yc].body==null?(i(Buffer.allocUnsafe(0)),n.promise):(await oK(t[yc].body,i,s),n.promise)}function aM(t){let e=t[yc].body;return e!=null&&(e.stream.locked||MA.isDisturbed(e.stream))}function CK(t){return JSON.parse(rM(t))}function tM(t){let e=t[yc].headersList,r=aK(e);return r==="failure"?null:r}cM.exports={extractBody:oM,safelyExtractBody:hK,cloneBody:fK,mixinBody:EK,streamRegistry:iM,hasFinalizationRegistry:sM,bodyUnusable:aM}});var BM=h((X0e,IM)=>{"use strict";var V=require("node:assert"),Z=ce(),{channels:lM}=oc(),$I=PI(),{RequestContentLengthMismatchError:Ho,ResponseContentLengthMismatchError:AM,RequestAbortedError:yM,HeadersTimeoutError:IK,HeadersOverflowError:BK,SocketError:Cp,InformationalError:Cc,BodyTimeoutError:QK,HTTPParserError:xK,ResponseExceededMaxSizeError:wK}=ye(),{kUrl:EM,kReset:or,kClient:gp,kParser:Ye,kBlocking:FA,kRunning:Mt,kPending:bK,kSize:uM,kWriting:zi,kQueue:Sn,kNoRef:LA,kKeepAliveDefaultTimeout:NK,kHostHeader:SK,kPendingIdx:RK,kRunningIdx:tn,kError:Vt,kPipelining:yp,kSocket:Ic,kKeepAliveTimeoutValue:Ip,kMaxHeadersSize:jI,kKeepAliveMaxTimeout:PK,kKeepAliveTimeoutThreshold:vK,kHeadersTimeout:DK,kBodyTimeout:kK,kStrictContentLength:ZI,kMaxRequests:dM,kCounter:TK,kMaxResponseSize:MK,kOnError:mM,kResume:Hi,kHTTPContext:CM}=Le(),Nr=iT(),pM=Buffer.alloc(0),pp=Buffer[Symbol.species],hp=Z.addListener,LK=Z.removeAllListeners,KI;async function _K(){let t=process.env.JEST_WORKER_ID?kI():void 0,e;try{e=await WebAssembly.compile(cT())}catch{e=await WebAssembly.compile(t||kI())}return await WebAssembly.instantiate(e,{env:{wasm_on_url:(r,n,s)=>0,wasm_on_status:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onStatus(new pp(ns.buffer,i,s))||0},wasm_on_message_begin:r=>(V(Ge.ptr===r),Ge.onMessageBegin()||0),wasm_on_header_field:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onHeaderField(new pp(ns.buffer,i,s))||0},wasm_on_header_value:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onHeaderValue(new pp(ns.buffer,i,s))||0},wasm_on_headers_complete:(r,n,s,i)=>(V(Ge.ptr===r),Ge.onHeadersComplete(n,!!s,!!i)||0),wasm_on_body:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onBody(new pp(ns.buffer,i,s))||0},wasm_on_message_complete:r=>(V(Ge.ptr===r),Ge.onMessageComplete()||0)}})}var XI=null,eB=_K();eB.catch();var Ge=null,ns=null,fp=0,ss=null,FK=0,_A=1,Bc=2|_A,Ep=4|_A,tB=8|FK,rB=class{constructor(e,r,{exports:n}){V(Number.isFinite(e[jI])&&e[jI]>0),this.llhttp=n,this.ptr=this.llhttp.llhttp_alloc(Nr.TYPE.RESPONSE),this.client=e,this.socket=r,this.timeout=null,this.timeoutValue=null,this.timeoutType=null,this.statusCode=null,this.statusText="",this.upgrade=!1,this.headers=[],this.headersSize=0,this.headersMaxSize=e[jI],this.shouldKeepAlive=!1,this.pause
Line truncated
|
||||
`);d.push(y,g,m),typeof g.size=="number"?i+=y.byteLength+g.size+m.byteLength:p=!0}let f=sp.encode(`--${c}--\r
|
||||
`);d.push(f),i+=f.byteLength,p&&(i=null),s=t,n=async function*(){for(let E of d)E.stream?yield*E.stream():yield E},o=`multipart/form-data; boundary=${c}`}else if(UT(t))s=t,i=t.size,t.type&&(o=t.type);else if(typeof t[Symbol.asyncIterator]=="function"){if(e)throw new TypeError("keepalive");if(PA.isDisturbed(t)||t.locked)throw new TypeError("Response body object should not be disturbed or locked");r=t instanceof ReadableStream?t:Lj(t)}if((typeof s=="string"||PA.isBuffer(s))&&(i=Buffer.byteLength(s)),n!=null){let c;r=new ReadableStream({async start(){c=n(t)[Symbol.asyncIterator]()},async pull(l){let{value:A,done:u}=await c.next();if(u)queueMicrotask(()=>{l.close(),l.byobRequest?.respond(0)});else if(!zT(r)){let d=new Uint8Array(A);d.byteLength&&l.enqueue(d)}return l.desiredSize>0},async cancel(l){await c.return()},type:"bytes"})}return[{stream:r,source:s,length:i},o]}function $j(t,e=!1){return t instanceof ReadableStream&&(FI(!PA.isDisturbed(t),"The body has already been consumed."),FI(!t.locked,"The stream is locked.")),VT(t,e)}function jj(t,e){let[r,n]=e.stream.tee();return e.stream=r,{stream:n,length:e.length,source:e.source}}function Kj(t){if(t.aborted)throw new DOMException("The operation was aborted.","AbortError")}function Xj(t){return{blob(){return dc(this,r=>{let n=qT(this);return n===null?n="":n&&(n=Vj(n)),new zj([r],{type:n})},t)},arrayBuffer(){return dc(this,r=>new Uint8Array(r).buffer,t)},text(){return dc(this,HT,t)},json(){return dc(this,eK,t)},formData(){return dc(this,r=>{let n=qT(this);if(n!==null)switch(n.essence){case"multipart/form-data":{let s=Jj(r,n);if(s==="failure")throw new TypeError("Failed to parse body as FormData.");let i=new OT;return i[mc]=s,i}case"application/x-www-form-urlencoded":{let s=new URLSearchParams(r.toString()),i=new OT;for(let[o,a]of s)i.append(o,a);return i}}throw new TypeError('Content-Type was not one of "multipart/form-data" or "application/x-www-form-urlencoded".')},t)},bytes(){return dc(this,r=>new Uint8Array(r),t)}}}function Zj(t){Object.assign(t.prototype,Xj(t))}async function dc(t,e,r){if(Hj.brandCheck(t,r),JT(t))throw new TypeError("Body is unusable: Body has already been read");Kj(t[mc]);let n=Uj(),s=o=>n.reject(o),i=o=>{try{n.resolve(e(o))}catch(a){s(a)}};return t[mc].body==null?(i(Buffer.allocUnsafe(0)),n.promise):(await Oj(t[mc].body,i,s),n.promise)}function JT(t){let e=t[mc].body;return e!=null&&(e.stream.locked||PA.isDisturbed(e.stream))}function eK(t){return JSON.parse(HT(t))}function qT(t){let e=t[mc].headersList,r=qj(e);return r==="failure"?null:r}WT.exports={extractBody:VT,safelyExtractBody:$j,cloneBody:jj,mixinBody:Zj,streamRegistry:YT,hasFinalizationRegistry:GT,bodyUnusable:JT}});var cM=h((QNe,aM)=>{"use strict";var V=require("node:assert"),Z=ce(),{channels:$T}=tc(),UI=CI(),{RequestContentLengthMismatchError:Uo,ResponseContentLengthMismatchError:jT,RequestAbortedError:sM,HeadersTimeoutError:tK,HeadersOverflowError:rK,SocketError:up,InformationalError:hc,BodyTimeoutError:nK,HTTPParserError:sK,ResponseExceededMaxSizeError:iK}=Ee(),{kUrl:iM,kReset:ar,kClient:cp,kParser:Ye,kBlocking:kA,kRunning:Mt,kPending:oK,kSize:KT,kWriting:zi,kQueue:Rn,kNoRef:vA,kKeepAliveDefaultTimeout:aK,kHostHeader:cK,kPendingIdx:lK,kRunningIdx:rn,kError:Vt,kPipelining:lp,kSocket:fc,kKeepAliveTimeoutValue:dp,kMaxHeadersSize:OI,kKeepAliveMaxTimeout:AK,kKeepAliveTimeoutThreshold:uK,kHeadersTimeout:dK,kBodyTimeout:mK,kStrictContentLength:zI,kMaxRequests:XT,kCounter:pK,kMaxResponseSize:hK,kOnError:ZT,kResume:Hi,kHTTPContext:oM}=Le(),Rr=Yk(),eM=Buffer.alloc(0),ip=Buffer[Symbol.species],op=Z.addListener,fK=Z.removeAllListeners,qI;async function gK(){let t=process.env.JEST_WORKER_ID?QI():void 0,e;try{e=await WebAssembly.compile(Wk())}catch{e=await WebAssembly.compile(t||QI())}return await WebAssembly.instantiate(e,{env:{wasm_on_url:(r,n,s)=>0,wasm_on_status:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onStatus(new ip(ns.buffer,i,s))||0},wasm_on_message_begin:r=>(V(Ge.ptr===r),Ge.onMessageBegin()||0),wasm_on_header_field:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onHeaderField(new ip(ns.buffer,i,s))||0},wasm_on_header_value:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onHeaderValue(new ip(ns.buffer,i,s))||0},wasm_on_headers_complete:(r,n,s,i)=>(V(Ge.ptr===r),Ge.onHeadersComplete(n,!!s,!!i)||0),wasm_on_body:(r,n,s)=>{V(Ge.ptr===r);let i=n-ss+ns.byteOffset;return Ge.onBody(new ip(ns.buffer,i,s))||0},wasm_on_message_complete:r=>(V(Ge.ptr===r),Ge.onMessageComplete()||0)}})}var HI=null,GI=gK();GI.catch();var Ge=null,ns=null,ap=0,ss=null,yK=0,DA=1,gc=2|DA,Ap=4|DA,YI=8|yK,VI=class{constructor(e,r,{exports:n}){V(Number.isFinite(e[OI])&&e[OI]>0),this.llhttp=n,this.ptr=this.llhttp.llhttp_alloc(Rr.TYPE.RESPONSE),this.client=e,this.socket=r,this.timeout=null,this.timeoutValue=null,this.timeoutType=null,this.statusCode=null,this.statusText="",this.upgrade=!1,this.headers=[],this.headersSize=0,this.headersMaxSize=e[OI],this.shouldKeepAlive=!1,this.pause
Line truncated
|
||||
`;if(typeof s=="string"?f+=`host: ${s}\r
|
||||
`:f+=t[SK],i?f+=`connection: upgrade\r
|
||||
`:f+=t[cK],i?f+=`connection: upgrade\r
|
||||
upgrade: ${i}\r
|
||||
`:t[yp]&&!m[or]?f+=`connection: keep-alive\r
|
||||
`:t[lp]&&!m[ar]?f+=`connection: keep-alive\r
|
||||
`:f+=`connection: close\r
|
||||
`,Array.isArray(l))for(let E=0;E<l.length;E+=2){let g=l[E+0],y=l[E+1];if(Array.isArray(y))for(let C=0;C<y.length;C++)f+=`${g}: ${y[C]}\r
|
||||
`;else f+=`${g}: ${y}\r
|
||||
`}return lM.sendHeaders.hasSubscribers&&lM.sendHeaders.publish({request:e,headers:f,socket:m}),!c||d===0?fM(p,null,t,e,m,A,f,u):Z.isBuffer(c)?fM(p,c,t,e,m,A,f,u):Z.isBlobLike(c)?typeof c.stream=="function"?gM(p,c.stream(),t,e,m,A,f,u):GK(p,c,t,e,m,A,f,u):Z.isStream(c)?zK(p,c,t,e,m,A,f,u):Z.isIterable(c)?gM(p,c,t,e,m,A,f,u):V(!1),!0}function zK(t,e,r,n,s,i,o,a){V(i!==0||r[Mt]===0,"stream body cannot be pipelined");let c=!1,l=new Bp({abort:t,socket:s,request:n,contentLength:i,client:r,expectsPayload:a,header:o}),A=function(p){if(!c)try{!l.write(p)&&this.pause&&this.pause()}catch(f){Z.destroy(this,f)}},u=function(){c||e.resume&&e.resume()},d=function(){if(queueMicrotask(()=>{e.removeListener("error",m)}),!c){let p=new yM;queueMicrotask(()=>m(p))}},m=function(p){if(!c){if(c=!0,V(s.destroyed||s[zi]&&r[Mt]<=1),s.off("drain",u).off("error",m),e.removeListener("data",A).removeListener("end",m).removeListener("close",d),!p)try{l.end()}catch(f){p=f}l.destroy(p),p&&(p.code!=="UND_ERR_INFO"||p.message!=="reset")?Z.destroy(e,p):Z.destroy(e)}};e.on("data",A).on("end",m).on("error",m).on("close",d),e.resume&&e.resume(),s.on("drain",u).on("error",m),e.errorEmitted??e.errored?setImmediate(()=>m(e.errored)):(e.endEmitted??e.readableEnded)&&setImmediate(()=>m(null)),(e.closeEmitted??e.closed)&&setImmediate(d)}function fM(t,e,r,n,s,i,o,a){try{e?Z.isBuffer(e)&&(V(i===e.byteLength,"buffer body must have content length"),s.cork(),s.write(`${o}content-length: ${i}\r
|
||||
`}return $T.sendHeaders.hasSubscribers&&$T.sendHeaders.publish({request:e,headers:f,socket:m}),!c||d===0?rM(p,null,t,e,m,A,f,u):Z.isBuffer(c)?rM(p,c,t,e,m,A,f,u):Z.isBlobLike(c)?typeof c.stream=="function"?nM(p,c.stream(),t,e,m,A,f,u):xK(p,c,t,e,m,A,f,u):Z.isStream(c)?QK(p,c,t,e,m,A,f,u):Z.isIterable(c)?nM(p,c,t,e,m,A,f,u):V(!1),!0}function QK(t,e,r,n,s,i,o,a){V(i!==0||r[Mt]===0,"stream body cannot be pipelined");let c=!1,l=new mp({abort:t,socket:s,request:n,contentLength:i,client:r,expectsPayload:a,header:o}),A=function(p){if(!c)try{!l.write(p)&&this.pause&&this.pause()}catch(f){Z.destroy(this,f)}},u=function(){c||e.resume&&e.resume()},d=function(){if(queueMicrotask(()=>{e.removeListener("error",m)}),!c){let p=new sM;queueMicrotask(()=>m(p))}},m=function(p){if(!c){if(c=!0,V(s.destroyed||s[zi]&&r[Mt]<=1),s.off("drain",u).off("error",m),e.removeListener("data",A).removeListener("end",m).removeListener("close",d),!p)try{l.end()}catch(f){p=f}l.destroy(p),p&&(p.code!=="UND_ERR_INFO"||p.message!=="reset")?Z.destroy(e,p):Z.destroy(e)}};e.on("data",A).on("end",m).on("error",m).on("close",d),e.resume&&e.resume(),s.on("drain",u).on("error",m),e.errorEmitted??e.errored?setImmediate(()=>m(e.errored)):(e.endEmitted??e.readableEnded)&&setImmediate(()=>m(null)),(e.closeEmitted??e.closed)&&setImmediate(d)}function rM(t,e,r,n,s,i,o,a){try{e?Z.isBuffer(e)&&(V(i===e.byteLength,"buffer body must have content length"),s.cork(),s.write(`${o}content-length: ${i}\r
|
||||
\r
|
||||
`,"latin1"),s.write(e),s.uncork(),n.onBodySent(e),!a&&n.reset!==!1&&(s[or]=!0)):i===0?s.write(`${o}content-length: 0\r
|
||||
`,"latin1"),s.write(e),s.uncork(),n.onBodySent(e),!a&&n.reset!==!1&&(s[ar]=!0)):i===0?s.write(`${o}content-length: 0\r
|
||||
\r
|
||||
`,"latin1"):(V(i===null,"no body must not have content length"),s.write(`${o}\r
|
||||
`,"latin1")),n.onRequestSent(),r[Hi]()}catch(c){t(c)}}async function GK(t,e,r,n,s,i,o,a){V(i===e.size,"blob body must have content length");try{if(i!=null&&i!==e.size)throw new Ho;let c=Buffer.from(await e.arrayBuffer());s.cork(),s.write(`${o}content-length: ${i}\r
|
||||
`,"latin1")),n.onRequestSent(),r[Hi]()}catch(c){t(c)}}async function xK(t,e,r,n,s,i,o,a){V(i===e.size,"blob body must have content length");try{if(i!=null&&i!==e.size)throw new Uo;let c=Buffer.from(await e.arrayBuffer());s.cork(),s.write(`${o}content-length: ${i}\r
|
||||
\r
|
||||
`,"latin1"),s.write(c),s.uncork(),n.onBodySent(c),n.onRequestSent(),!a&&n.reset!==!1&&(s[or]=!0),r[Hi]()}catch(c){t(c)}}async function gM(t,e,r,n,s,i,o,a){V(i!==0||r[Mt]===0,"iterator body cannot be pipelined");let c=null;function l(){if(c){let d=c;c=null,d()}}let A=()=>new Promise((d,m)=>{V(c===null),s[Vt]?m(s[Vt]):c=d});s.on("close",l).on("drain",l);let u=new Bp({abort:t,socket:s,request:n,contentLength:i,client:r,expectsPayload:a,header:o});try{for await(let d of e){if(s[Vt])throw s[Vt];u.write(d)||await A()}u.end()}catch(d){u.destroy(d)}finally{s.off("close",l).off("drain",l)}}var Bp=class{constructor({abort:e,socket:r,request:n,contentLength:s,client:i,expectsPayload:o,header:a}){this.socket=r,this.request=n,this.contentLength=s,this.client=i,this.bytesWritten=0,this.expectsPayload=o,this.header=a,this.abort=e,r[zi]=!0}write(e){let{socket:r,request:n,contentLength:s,client:i,bytesWritten:o,expectsPayload:a,header:c}=this;if(r[Vt])throw r[Vt];if(r.destroyed)return!1;let l=Buffer.byteLength(e);if(!l)return!0;if(s!==null&&o+l>s){if(i[ZI])throw new Ho;process.emitWarning(new Ho)}r.cork(),o===0&&(!a&&n.reset!==!1&&(r[or]=!0),s===null?r.write(`${c}transfer-encoding: chunked\r
|
||||
`,"latin1"),s.write(c),s.uncork(),n.onBodySent(c),n.onRequestSent(),!a&&n.reset!==!1&&(s[ar]=!0),r[Hi]()}catch(c){t(c)}}async function nM(t,e,r,n,s,i,o,a){V(i!==0||r[Mt]===0,"iterator body cannot be pipelined");let c=null;function l(){if(c){let d=c;c=null,d()}}let A=()=>new Promise((d,m)=>{V(c===null),s[Vt]?m(s[Vt]):c=d});s.on("close",l).on("drain",l);let u=new mp({abort:t,socket:s,request:n,contentLength:i,client:r,expectsPayload:a,header:o});try{for await(let d of e){if(s[Vt])throw s[Vt];u.write(d)||await A()}u.end()}catch(d){u.destroy(d)}finally{s.off("close",l).off("drain",l)}}var mp=class{constructor({abort:e,socket:r,request:n,contentLength:s,client:i,expectsPayload:o,header:a}){this.socket=r,this.request=n,this.contentLength=s,this.client=i,this.bytesWritten=0,this.expectsPayload=o,this.header=a,this.abort=e,r[zi]=!0}write(e){let{socket:r,request:n,contentLength:s,client:i,bytesWritten:o,expectsPayload:a,header:c}=this;if(r[Vt])throw r[Vt];if(r.destroyed)return!1;let l=Buffer.byteLength(e);if(!l)return!0;if(s!==null&&o+l>s){if(i[zI])throw new Uo;process.emitWarning(new Uo)}r.cork(),o===0&&(!a&&n.reset!==!1&&(r[ar]=!0),s===null?r.write(`${c}transfer-encoding: chunked\r
|
||||
`,"latin1"):r.write(`${c}content-length: ${s}\r
|
||||
\r
|
||||
`,"latin1")),s===null&&r.write(`\r
|
||||
${l.toString(16)}\r
|
||||
`,"latin1"),this.bytesWritten+=l;let A=r.write(e);return r.uncork(),n.onBodySent(e),A||r[Ye].timeout&&r[Ye].timeoutType===Bc&&r[Ye].timeout.refresh&&r[Ye].timeout.refresh(),A}end(){let{socket:e,contentLength:r,client:n,bytesWritten:s,expectsPayload:i,header:o,request:a}=this;if(a.onRequestSent(),e[zi]=!1,e[Vt])throw e[Vt];if(!e.destroyed){if(s===0?i?e.write(`${o}content-length: 0\r
|
||||
`,"latin1"),this.bytesWritten+=l;let A=r.write(e);return r.uncork(),n.onBodySent(e),A||r[Ye].timeout&&r[Ye].timeoutType===gc&&r[Ye].timeout.refresh&&r[Ye].timeout.refresh(),A}end(){let{socket:e,contentLength:r,client:n,bytesWritten:s,expectsPayload:i,header:o,request:a}=this;if(a.onRequestSent(),e[zi]=!1,e[Vt])throw e[Vt];if(!e.destroyed){if(s===0?i?e.write(`${o}content-length: 0\r
|
||||
\r
|
||||
`,"latin1"):e.write(`${o}\r
|
||||
`,"latin1"):r===null&&e.write(`\r
|
||||
0\r
|
||||
\r
|
||||
`,"latin1"),r!==null&&s!==r){if(n[ZI])throw new Ho;process.emitWarning(new Ho)}e[Ye].timeout&&e[Ye].timeoutType===Bc&&e[Ye].timeout.refresh&&e[Ye].timeout.refresh(),n[Hi]()}}destroy(e){let{socket:r,client:n,abort:s}=this;r[zi]=!1,e&&(V(n[Mt]<=1,"pipeline should only contain this request"),s(e))}};IM.exports=UK});var PM=h((Z0e,RM)=>{"use strict";var rn=require("node:assert"),{pipeline:YK}=require("node:stream"),Ae=ce(),{RequestContentLengthMismatchError:nB,RequestAbortedError:QM,SocketError:UA,InformationalError:sB}=ye(),{kUrl:Qp,kReset:wp,kClient:Qc,kRunning:bp,kPending:VK,kQueue:Gi,kPendingIdx:iB,kRunningIdx:Rn,kError:vn,kSocket:xt,kStrictContentLength:JK,kOnError:oB,kMaxConcurrentStreams:SM,kHTTP2Session:Pn,kResume:Yi,kSize:WK,kHTTPContext:$K}=Le(),ai=Symbol("open streams"),xM,wM=!1,xp;try{xp=require("node:http2")}catch{xp={constants:{}}}var{constants:{HTTP2_HEADER_AUTHORITY:jK,HTTP2_HEADER_METHOD:KK,HTTP2_HEADER_PATH:XK,HTTP2_HEADER_SCHEME:ZK,HTTP2_HEADER_CONTENT_LENGTH:eX,HTTP2_HEADER_EXPECT:tX,HTTP2_HEADER_STATUS:rX}}=xp;function nX(t){let e=[];for(let[r,n]of Object.entries(t))if(Array.isArray(n))for(let s of n)e.push(Buffer.from(r),Buffer.from(s));else e.push(Buffer.from(r),Buffer.from(n));return e}async function sX(t,e){t[xt]=e,wM||(wM=!0,process.emitWarning("H2 support is experimental, expect them to change at any time.",{code:"UNDICI-H2"}));let r=xp.connect(t[Qp],{createConnection:()=>e,peerMaxConcurrentStreams:t[SM]});r[ai]=0,r[Qc]=t,r[xt]=e,Ae.addListener(r,"error",oX),Ae.addListener(r,"frameError",aX),Ae.addListener(r,"end",cX),Ae.addListener(r,"goaway",lX),Ae.addListener(r,"close",function(){let{[Qc]:s}=this,{[xt]:i}=s,o=this[xt][vn]||this[vn]||new UA("closed",Ae.getSocketInfo(i));if(s[Pn]=null,s.destroyed){rn(s[VK]===0);let a=s[Gi].splice(s[Rn]);for(let c=0;c<a.length;c++){let l=a[c];Ae.errorRequest(s,l,o)}}}),r.unref(),t[Pn]=r,e[Pn]=r,Ae.addListener(e,"error",function(s){rn(s.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[vn]=s,this[Qc][oB](s)}),Ae.addListener(e,"end",function(){Ae.destroy(this,new UA("other side closed",Ae.getSocketInfo(this)))}),Ae.addListener(e,"close",function(){let s=this[vn]||new UA("closed",Ae.getSocketInfo(this));t[xt]=null,this[Pn]!=null&&this[Pn].destroy(s),t[iB]=t[Rn],rn(t[bp]===0),t.emit("disconnect",t[Qp],[t],s),t[Yi]()});let n=!1;return e.on("close",()=>{n=!0}),{version:"h2",defaultPipelining:1/0,write(...s){return uX(t,...s)},resume(){iX(t)},destroy(s,i){n?queueMicrotask(i):e.destroy(s).on("close",i)},get destroyed(){return e.destroyed},busy(){return!1}}}function iX(t){let e=t[xt];e?.destroyed===!1&&(t[WK]===0&&t[SM]===0?(e.unref(),t[Pn].unref()):(e.ref(),t[Pn].ref()))}function oX(t){rn(t.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[xt][vn]=t,this[Qc][oB](t)}function aX(t,e,r){if(r===0){let n=new sB(`HTTP/2: "frameError" received - type ${t}, code ${e}`);this[xt][vn]=n,this[Qc][oB](n)}}function cX(){let t=new UA("other side closed",Ae.getSocketInfo(this[xt]));this.destroy(t),Ae.destroy(this[xt],t)}function lX(t){let e=this[vn]||new UA(`HTTP/2: "GOAWAY" frame received with code ${t}`,Ae.getSocketInfo(this)),r=this[Qc];if(r[xt]=null,r[$K]=null,this[Pn]!=null&&(this[Pn].destroy(e),this[Pn]=null),Ae.destroy(this[xt],e),r[Rn]<r[Gi].length){let n=r[Gi][r[Rn]];r[Gi][r[Rn]++]=null,Ae.errorRequest(r,n,e),r[iB]=r[Rn]}rn(r[bp]===0),r.emit("disconnect",r[Qp],[r],e),r[Yi]()}function AX(t){return t!=="GET"&&t!=="HEAD"&&t!=="OPTIONS"&&t!=="TRACE"&&t!=="CONNECT"}function uX(t,e){let r=t[Pn],{method:n,path:s,host:i,upgrade:o,expectContinue:a,signal:c,headers:l}=e,{body:A}=e;if(o)return Ae.errorRequest(t,e,new Error("Upgrade not supported for H2")),!1;let u={};for(let I=0;I<l.length;I+=2){let w=l[I+0],D=l[I+1];if(Array.isArray(D))for(let _=0;_<D.length;_++)u[w]?u[w]+=`,${D[_]}`:u[w]=D[_];else u[w]=D}let d,{hostname:m,port:p}=t[Qp];u[jK]=i||`${m}${p?`:${p}`:""}`,u[KK]=n;let f=I=>{e.aborted||e.completed||(I=I||new QM,Ae.errorRequest(t,e,I),d!=null&&Ae.destroy(d,I),Ae.destroy(A,I),t[Gi][t[Rn]++]=null,t[Yi]())};try{e.onConnect(f)}catch(I){Ae.errorRequest(t,e,I)}if(e.aborted)return!1;if(n==="CONNECT")return r.ref(),d=r.request(u,{endStream:!1,signal:c}),d.id&&!d.pending?(e.onUpgrade(null,null,d),++r[ai],t[Gi][t[Rn]++]=null):d.once("ready",()=>{e.onUpgrade(null,null,d),++r[ai],t[Gi][t[Rn]++]=null}),d.once("close",()=>{r[ai]-=1,r[ai]===0&&r.unref()}),!0;u[XK]=s,u[ZK]="https";let E=n==="PUT"||n==="POST"||n==="PATCH";A&&typeof A.read=="function"&&A.read(0);let g=Ae.bodyLength(A);if(Ae.isFormDataLike(A)){xM??=Ec().extractBody;let[I,w]=xM(A);u["content-type"]=w,A=I.stream,g=I.length}if(g==null&&(g=e.contentLength),(g===0||!E)&&(g=null),AX(n)&&g>0&&e.contentLength!=null&&e.contentLength!==g){if(t[JK])return Ae.errorRequest(t,e,new nB),!1;process.emitWarning(new nB)}g!=null&&(rn(A,"no body must not have content length"),u[eX]=`${g}`),r.ref();let y=n==="GET"||n==="HEAD"||A===null;return a?(u[tX]="100-continue",d=r.request(u,{endStream:y,signal:c}),d.once("continue",C)):(d=r.request(u,{endStream:
Line truncated
|
||||
`,this[_X]=c??3e5,this[LX]=s??3e5,this[FX]=y??!0,this[UX]=I,this[AB]=D,this[Ji]=null,this[GX]=ae>-1?ae:-1,this[VX]=H??100,this[nt]=null,this[Dn]=[],this[li]=0,this[kn]=0,this[zA]=de=>dB(this,de),this[YX]=de=>HM(this,de)}get pipelining(){return this[Pp]}set pipelining(e){this[Pp]=e,this[zA](!0)}get[VA](){return this[Dn].length-this[kn]}get[YA](){return this[kn]-this[li]}get[GA](){return this[Dn].length-this[li]}get[RX](){return!!this[nt]&&!this[wc]&&!this[nt].destroyed}get[lB](){return!!(this[nt]?.busy(null)||this[GA]>=(qM(this)||1)||this[VA]>0)}[SX](e){zM(this),this.once("connect",e)}[zX](e,r){let n=e.origin||this[os].origin,s=new BX(n,e,r);return this[Dn].push(s),this[Go]||(zo.bodyLength(s.body)==null&&zo.isIterable(s.body)?(this[Go]=1,queueMicrotask(()=>dB(this))):this[zA](!0)),this[Go]&&this[Wi]!==2&&this[lB]&&(this[Wi]=2),this[Wi]<2}async[qX](){return new Promise(e=>{this[GA]?this[Ji]=e:e(null)})}async[HX](e){return new Promise(r=>{let n=this[Dn].splice(this[kn]);for(let i=0;i<n.length;i++){let o=n[i];zo.errorRequest(this,o,e)}let s=()=>{this[Ji]&&(this[Ji](),this[Ji]=null),r(null)};this[nt]?(this[nt].destroy(e,s),this[nt]=null):queueMicrotask(s),this[zA]()})}},$X=Rp();function HM(t,e){if(t[YA]===0&&e.code!=="UND_ERR_INFO"&&e.code!=="UND_ERR_SOCKET"){ci(t[kn]===t[li]);let r=t[Dn].splice(t[li]);for(let n=0;n<r.length;n++){let s=r[n];zo.errorRequest(t,s,e)}ci(t[GA]===0)}}async function zM(t){ci(!t[wc]),ci(!t[nt]);let{host:e,hostname:r,protocol:n,port:s}=t[os];if(r[0]==="["){let i=r.indexOf("]");ci(i!==-1);let o=r.substring(1,i);ci(OM.isIP(o)),r=o}t[wc]=!0,xc.beforeConnect.hasSubscribers&&xc.beforeConnect.publish({connectParams:{host:e,hostname:r,protocol:n,port:s,version:t[nt]?.version,servername:t[Vi],localAddress:t[HA]},connector:t[qA]});try{let i=await new Promise((o,a)=>{t[qA]({host:e,hostname:r,protocol:n,port:s,servername:t[Vi],localAddress:t[HA]},(c,l)=>{c?a(c):o(l)})});if(t.destroyed){zo.destroy(i.on("error",FM),new wX);return}ci(i);try{t[nt]=i.alpnProtocol==="h2"?await WX(t,i):await JX(t,i)}catch(o){throw i.destroy().on("error",FM),o}t[wc]=!1,i[OX]=0,i[AB]=t[AB],i[NX]=t,i[vX]=null,xc.connected.hasSubscribers&&xc.connected.publish({connectParams:{host:e,hostname:r,protocol:n,port:s,version:t[nt]?.version,servername:t[Vi],localAddress:t[HA]},connector:t[qA],socket:i}),t.emit("connect",t[os],[t])}catch(i){if(t.destroyed)return;if(t[wc]=!1,xc.connectError.hasSubscribers&&xc.connectError.publish({connectParams:{host:e,hostname:r,protocol:n,port:s,version:t[nt]?.version,servername:t[Vi],localAddress:t[HA]},connector:t[qA],error:i}),i.code==="ERR_TLS_CERT_ALTNAME_INVALID")for(ci(t[YA]===0);t[VA]>0&&t[Dn][t[kn]].servername===t[Vi];){let o=t[Dn][t[kn]++];zo.errorRequest(t,o,i)}else HM(t,i);t.emit("connectionError",t[os],[t],i)}t[zA]()}function UM(t){t[Wi]=0,t.emit("drain",t[os],[t])}function dB(t,e){t[Go]!==2&&(t[Go]=2,jX(t,e),t[Go]=0,t[li]>256&&(t[Dn].splice(0,t[li]),t[kn]-=t[li],t[li]=0))}function jX(t,e){for(;;){if(t.destroyed){ci(t[VA]===0);return}if(t[Ji]&&!t[GA]){t[Ji](),t[Ji]=null;return}if(t[nt]&&t[nt].resume(),t[lB])t[Wi]=2;else if(t[Wi]===2){e?(t[Wi]=1,queueMicrotask(()=>UM(t))):UM(t);continue}if(t[VA]===0||t[YA]>=(qM(t)||1))return;let r=t[Dn][t[kn]];if(t[os].protocol==="https:"&&t[Vi]!==r.servername){if(t[YA]>0)return;t[Vi]=r.servername,t[nt]?.destroy(new xX("servername changed"),()=>{t[nt]=null,dB(t)})}if(t[wc])return;if(!t[nt]){zM(t);return}if(t[nt].destroyed||t[nt].busy(r))return;!r.aborted&&t[nt].write(r)?t[kn]++:t[Dn].splice(t[kn],1)}}GM.exports=uB});var mB=h((sNe,YM)=>{"use strict";var vp=class{constructor(){this.bottom=0,this.top=0,this.list=new Array(2048),this.next=null}isEmpty(){return this.top===this.bottom}isFull(){return(this.top+1&2047)===this.bottom}push(e){this.list[this.top]=e,this.top=this.top+1&2047}shift(){let e=this.list[this.bottom];return e===void 0?null:(this.list[this.bottom]=void 0,this.bottom=this.bottom+1&2047,e)}};YM.exports=class{constructor(){this.head=this.tail=new vp}isEmpty(){return this.head.isEmpty()}push(e){this.head.isFull()&&(this.head=this.head.next=new vp),this.head.push(e)}shift(){let e=this.tail,r=e.shift();return e.isEmpty()&&e.next!==null&&(this.tail=e.next),r}}});var JM=h((iNe,VM)=>{var{kFree:KX,kConnected:XX,kPending:ZX,kQueued:eZ,kRunning:tZ,kSize:rZ}=Le(),Yo=Symbol("pool"),pB=class{constructor(e){this[Yo]=e}get connected(){return this[Yo][XX]}get free(){return this[Yo][KX]}get pending(){return this[Yo][ZX]}get queued(){return this[Yo][eZ]}get running(){return this[Yo][tZ]}get size(){return this[Yo][rZ]}};VM.exports=pB});var CB=h((oNe,nL)=>{"use strict";var nZ=Ac(),sZ=mB(),{kConnected:hB,kSize:WM,kRunning:$M,kPending:jM,kQueued:JA,kBusy:iZ,kFree:oZ,kUrl:aZ,kClose:cZ,kDestroy:lZ,kDispatch:AZ}=Le(),uZ=JM(),ar=Symbol("clients"),Jt=Symbol("needDrain"),WA=Symbol("queue"),fB=Symbol("closed resolve"),gB=Symbol("onDrain"),KM=Symbol("onConnect"),XM=Symbol("onDisconnect"),ZM=Symbol("onConnectionError"),yB=Symbol("get dispatcher"),tL=Symbol("add client"),rL
Line truncated
|
||||
`,"latin1"),r!==null&&s!==r){if(n[zI])throw new Uo;process.emitWarning(new Uo)}e[Ye].timeout&&e[Ye].timeoutType===gc&&e[Ye].timeout.refresh&&e[Ye].timeout.refresh(),n[Hi]()}}destroy(e){let{socket:r,client:n,abort:s}=this;r[zi]=!1,e&&(V(n[Mt]<=1,"pipeline should only contain this request"),s(e))}};aM.exports=EK});var fM=h((xNe,hM)=>{"use strict";var nn=require("node:assert"),{pipeline:bK}=require("node:stream"),Ae=ce(),{RequestContentLengthMismatchError:JI,RequestAbortedError:lM,SocketError:TA,InformationalError:WI}=Ee(),{kUrl:pp,kReset:fp,kClient:yc,kRunning:gp,kPending:wK,kQueue:Gi,kPendingIdx:$I,kRunningIdx:Pn,kError:Dn,kSocket:xt,kStrictContentLength:NK,kOnError:jI,kMaxConcurrentStreams:pM,kHTTP2Session:vn,kResume:Yi,kSize:SK,kHTTPContext:RK}=Le(),ai=Symbol("open streams"),AM,uM=!1,hp;try{hp=require("node:http2")}catch{hp={constants:{}}}var{constants:{HTTP2_HEADER_AUTHORITY:PK,HTTP2_HEADER_METHOD:vK,HTTP2_HEADER_PATH:DK,HTTP2_HEADER_SCHEME:kK,HTTP2_HEADER_CONTENT_LENGTH:TK,HTTP2_HEADER_EXPECT:MK,HTTP2_HEADER_STATUS:LK}}=hp;function FK(t){let e=[];for(let[r,n]of Object.entries(t))if(Array.isArray(n))for(let s of n)e.push(Buffer.from(r),Buffer.from(s));else e.push(Buffer.from(r),Buffer.from(n));return e}async function _K(t,e){t[xt]=e,uM||(uM=!0,process.emitWarning("H2 support is experimental, expect them to change at any time.",{code:"UNDICI-H2"}));let r=hp.connect(t[pp],{createConnection:()=>e,peerMaxConcurrentStreams:t[pM]});r[ai]=0,r[yc]=t,r[xt]=e,Ae.addListener(r,"error",OK),Ae.addListener(r,"frameError",qK),Ae.addListener(r,"end",HK),Ae.addListener(r,"goaway",zK),Ae.addListener(r,"close",function(){let{[yc]:s}=this,{[xt]:i}=s,o=this[xt][Dn]||this[Dn]||new TA("closed",Ae.getSocketInfo(i));if(s[vn]=null,s.destroyed){nn(s[wK]===0);let a=s[Gi].splice(s[Pn]);for(let c=0;c<a.length;c++){let l=a[c];Ae.errorRequest(s,l,o)}}}),r.unref(),t[vn]=r,e[vn]=r,Ae.addListener(e,"error",function(s){nn(s.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[Dn]=s,this[yc][jI](s)}),Ae.addListener(e,"end",function(){Ae.destroy(this,new TA("other side closed",Ae.getSocketInfo(this)))}),Ae.addListener(e,"close",function(){let s=this[Dn]||new TA("closed",Ae.getSocketInfo(this));t[xt]=null,this[vn]!=null&&this[vn].destroy(s),t[$I]=t[Pn],nn(t[gp]===0),t.emit("disconnect",t[pp],[t],s),t[Yi]()});let n=!1;return e.on("close",()=>{n=!0}),{version:"h2",defaultPipelining:1/0,write(...s){return YK(t,...s)},resume(){UK(t)},destroy(s,i){n?queueMicrotask(i):e.destroy(s).on("close",i)},get destroyed(){return e.destroyed},busy(){return!1}}}function UK(t){let e=t[xt];e?.destroyed===!1&&(t[SK]===0&&t[pM]===0?(e.unref(),t[vn].unref()):(e.ref(),t[vn].ref()))}function OK(t){nn(t.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[xt][Dn]=t,this[yc][jI](t)}function qK(t,e,r){if(r===0){let n=new WI(`HTTP/2: "frameError" received - type ${t}, code ${e}`);this[xt][Dn]=n,this[yc][jI](n)}}function HK(){let t=new TA("other side closed",Ae.getSocketInfo(this[xt]));this.destroy(t),Ae.destroy(this[xt],t)}function zK(t){let e=this[Dn]||new TA(`HTTP/2: "GOAWAY" frame received with code ${t}`,Ae.getSocketInfo(this)),r=this[yc];if(r[xt]=null,r[RK]=null,this[vn]!=null&&(this[vn].destroy(e),this[vn]=null),Ae.destroy(this[xt],e),r[Pn]<r[Gi].length){let n=r[Gi][r[Pn]];r[Gi][r[Pn]++]=null,Ae.errorRequest(r,n,e),r[$I]=r[Pn]}nn(r[gp]===0),r.emit("disconnect",r[pp],[r],e),r[Yi]()}function GK(t){return t!=="GET"&&t!=="HEAD"&&t!=="OPTIONS"&&t!=="TRACE"&&t!=="CONNECT"}function YK(t,e){let r=t[vn],{method:n,path:s,host:i,upgrade:o,expectContinue:a,signal:c,headers:l}=e,{body:A}=e;if(o)return Ae.errorRequest(t,e,new Error("Upgrade not supported for H2")),!1;let u={};for(let I=0;I<l.length;I+=2){let w=l[I+0],D=l[I+1];if(Array.isArray(D))for(let F=0;F<D.length;F++)u[w]?u[w]+=`,${D[F]}`:u[w]=D[F];else u[w]=D}let d,{hostname:m,port:p}=t[pp];u[PK]=i||`${m}${p?`:${p}`:""}`,u[vK]=n;let f=I=>{e.aborted||e.completed||(I=I||new lM,Ae.errorRequest(t,e,I),d!=null&&Ae.destroy(d,I),Ae.destroy(A,I),t[Gi][t[Pn]++]=null,t[Yi]())};try{e.onConnect(f)}catch(I){Ae.errorRequest(t,e,I)}if(e.aborted)return!1;if(n==="CONNECT")return r.ref(),d=r.request(u,{endStream:!1,signal:c}),d.id&&!d.pending?(e.onUpgrade(null,null,d),++r[ai],t[Gi][t[Pn]++]=null):d.once("ready",()=>{e.onUpgrade(null,null,d),++r[ai],t[Gi][t[Pn]++]=null}),d.once("close",()=>{r[ai]-=1,r[ai]===0&&r.unref()}),!0;u[DK]=s,u[kK]="https";let E=n==="PUT"||n==="POST"||n==="PATCH";A&&typeof A.read=="function"&&A.read(0);let g=Ae.bodyLength(A);if(Ae.isFormDataLike(A)){AM??=pc().extractBody;let[I,w]=AM(A);u["content-type"]=w,A=I.stream,g=I.length}if(g==null&&(g=e.contentLength),(g===0||!E)&&(g=null),GK(n)&&g>0&&e.contentLength!=null&&e.contentLength!==g){if(t[NK])return Ae.errorRequest(t,e,new JI),!1;process.emitWarning(new JI)}g!=null&&(nn(A,"no body must not have content length"),u[TK]=`${g}`),r.ref();let y=n==="GET"||n==="HEAD"||A===null;return a?(u[MK]="100-continue",d=r.request(u,{endStream:y,signal:c}),d.once("continue",C)):(d=r.request(u,{endStream:
Line truncated
|
||||
`,this[gX]=c??3e5,this[fX]=s??3e5,this[yX]=y??!0,this[EX]=I,this[eB]=D,this[Ji]=null,this[xX]=ae>-1?ae:-1,this[wX]=H??100,this[nt]=null,this[kn]=[],this[li]=0,this[Tn]=0,this[_A]=de=>rB(this,de),this[bX]=de=>SM(this,de)}get pipelining(){return this[Ip]}set pipelining(e){this[Ip]=e,this[_A](!0)}get[qA](){return this[kn].length-this[Tn]}get[OA](){return this[Tn]-this[li]}get[UA](){return this[kn].length-this[li]}get[lX](){return!!this[nt]&&!this[Cc]&&!this[nt].destroyed}get[ZI](){return!!(this[nt]?.busy(null)||this[UA]>=(NM(this)||1)||this[qA]>0)}[cX](e){RM(this),this.once("connect",e)}[QX](e,r){let n=e.origin||this[os].origin,s=new rX(n,e,r);return this[kn].push(s),this[qo]||(Oo.bodyLength(s.body)==null&&Oo.isIterable(s.body)?(this[qo]=1,queueMicrotask(()=>rB(this))):this[_A](!0)),this[qo]&&this[Wi]!==2&&this[ZI]&&(this[Wi]=2),this[Wi]<2}async[IX](){return new Promise(e=>{this[UA]?this[Ji]=e:e(null)})}async[BX](e){return new Promise(r=>{let n=this[kn].splice(this[Tn]);for(let i=0;i<n.length;i++){let o=n[i];Oo.errorRequest(this,o,e)}let s=()=>{this[Ji]&&(this[Ji](),this[Ji]=null),r(null)};this[nt]?(this[nt].destroy(e,s),this[nt]=null):queueMicrotask(s),this[_A]()})}},RX=Cp();function SM(t,e){if(t[OA]===0&&e.code!=="UND_ERR_INFO"&&e.code!=="UND_ERR_SOCKET"){ci(t[Tn]===t[li]);let r=t[kn].splice(t[li]);for(let n=0;n<r.length;n++){let s=r[n];Oo.errorRequest(t,s,e)}ci(t[UA]===0)}}async function RM(t){ci(!t[Cc]),ci(!t[nt]);let{host:e,hostname:r,protocol:n,port:s}=t[os];if(r[0]==="["){let i=r.indexOf("]");ci(i!==-1);let o=r.substring(1,i);ci(wM.isIP(o)),r=o}t[Cc]=!0,Ec.beforeConnect.hasSubscribers&&Ec.beforeConnect.publish({connectParams:{host:e,hostname:r,protocol:n,port:s,version:t[nt]?.version,servername:t[Vi],localAddress:t[FA]},connector:t[LA]});try{let i=await new Promise((o,a)=>{t[LA]({host:e,hostname:r,protocol:n,port:s,servername:t[Vi],localAddress:t[FA]},(c,l)=>{c?a(c):o(l)})});if(t.destroyed){Oo.destroy(i.on("error",xM),new iX);return}ci(i);try{t[nt]=i.alpnProtocol==="h2"?await SX(t,i):await NX(t,i)}catch(o){throw i.destroy().on("error",xM),o}t[Cc]=!1,i[CX]=0,i[eB]=t[eB],i[aX]=t,i[uX]=null,Ec.connected.hasSubscribers&&Ec.connected.publish({connectParams:{host:e,hostname:r,protocol:n,port:s,version:t[nt]?.version,servername:t[Vi],localAddress:t[FA]},connector:t[LA],socket:i}),t.emit("connect",t[os],[t])}catch(i){if(t.destroyed)return;if(t[Cc]=!1,Ec.connectError.hasSubscribers&&Ec.connectError.publish({connectParams:{host:e,hostname:r,protocol:n,port:s,version:t[nt]?.version,servername:t[Vi],localAddress:t[FA]},connector:t[LA],error:i}),i.code==="ERR_TLS_CERT_ALTNAME_INVALID")for(ci(t[OA]===0);t[qA]>0&&t[kn][t[Tn]].servername===t[Vi];){let o=t[kn][t[Tn]++];Oo.errorRequest(t,o,i)}else SM(t,i);t.emit("connectionError",t[os],[t],i)}t[_A]()}function bM(t){t[Wi]=0,t.emit("drain",t[os],[t])}function rB(t,e){t[qo]!==2&&(t[qo]=2,PX(t,e),t[qo]=0,t[li]>256&&(t[kn].splice(0,t[li]),t[Tn]-=t[li],t[li]=0))}function PX(t,e){for(;;){if(t.destroyed){ci(t[qA]===0);return}if(t[Ji]&&!t[UA]){t[Ji](),t[Ji]=null;return}if(t[nt]&&t[nt].resume(),t[ZI])t[Wi]=2;else if(t[Wi]===2){e?(t[Wi]=1,queueMicrotask(()=>bM(t))):bM(t);continue}if(t[qA]===0||t[OA]>=(NM(t)||1))return;let r=t[kn][t[Tn]];if(t[os].protocol==="https:"&&t[Vi]!==r.servername){if(t[OA]>0)return;t[Vi]=r.servername,t[nt]?.destroy(new sX("servername changed"),()=>{t[nt]=null,rB(t)})}if(t[Cc])return;if(!t[nt]){RM(t);return}if(t[nt].destroyed||t[nt].busy(r))return;!r.aborted&&t[nt].write(r)?t[Tn]++:t[kn].splice(t[Tn],1)}}PM.exports=tB});var nB=h((RNe,vM)=>{"use strict";var Bp=class{constructor(){this.bottom=0,this.top=0,this.list=new Array(2048),this.next=null}isEmpty(){return this.top===this.bottom}isFull(){return(this.top+1&2047)===this.bottom}push(e){this.list[this.top]=e,this.top=this.top+1&2047}shift(){let e=this.list[this.bottom];return e===void 0?null:(this.list[this.bottom]=void 0,this.bottom=this.bottom+1&2047,e)}};vM.exports=class{constructor(){this.head=this.tail=new Bp}isEmpty(){return this.head.isEmpty()}push(e){this.head.isFull()&&(this.head=this.head.next=new Bp),this.head.push(e)}shift(){let e=this.tail,r=e.shift();return e.isEmpty()&&e.next!==null&&(this.tail=e.next),r}}});var kM=h((PNe,DM)=>{var{kFree:vX,kConnected:DX,kPending:kX,kQueued:TX,kRunning:MX,kSize:LX}=Le(),Ho=Symbol("pool"),sB=class{constructor(e){this[Ho]=e}get connected(){return this[Ho][DX]}get free(){return this[Ho][vX]}get pending(){return this[Ho][kX]}get queued(){return this[Ho][TX]}get running(){return this[Ho][MX]}get size(){return this[Ho][LX]}};DM.exports=sB});var AB=h((vNe,zM)=>{"use strict";var FX=ic(),_X=nB(),{kConnected:iB,kSize:TM,kRunning:MM,kPending:LM,kQueued:HA,kBusy:UX,kFree:OX,kUrl:qX,kClose:HX,kDestroy:zX,kDispatch:GX}=Le(),YX=kM(),cr=Symbol("clients"),Jt=Symbol("needDrain"),zA=Symbol("queue"),oB=Symbol("closed resolve"),aB=Symbol("onDrain"),FM=Symbol("onConnect"),_M=Symbol("onDisconnect"),UM=Symbol("onConnectionError"),cB=Symbol("get dispatcher"),qM=Symbol("add client"),HM
Line truncated
|
||||
${n.count} ${n.noun} ${n.is} pending:
|
||||
|
||||
${e.format(r)}
|
||||
`.trim())}};lF.exports=CQ});var $p=h((TNe,pF)=>{"use strict";var uF=Symbol.for("undici.globalDispatcher.1"),{InvalidArgumentError:_ee}=ye(),Fee=Sc();mF()===void 0&&dF(new Fee);function dF(t){if(!t||typeof t.dispatch!="function")throw new _ee("Argument agent must implement Agent");Object.defineProperty(globalThis,uF,{value:t,writable:!0,enumerable:!1,configurable:!1})}function mF(){return globalThis[uF]}pF.exports={setGlobalDispatcher:dF,getGlobalDispatcher:mF}});var jp=h((LNe,hF)=>{"use strict";hF.exports=class{#e;constructor(e){if(typeof e!="object"||e===null)throw new TypeError("handler must be an object");this.#e=e}onConnect(...e){return this.#e.onConnect?.(...e)}onError(...e){return this.#e.onError?.(...e)}onUpgrade(...e){return this.#e.onUpgrade?.(...e)}onResponseStarted(...e){return this.#e.onResponseStarted?.(...e)}onHeaders(...e){return this.#e.onHeaders?.(...e)}onData(...e){return this.#e.onData?.(...e)}onComplete(...e){return this.#e.onComplete?.(...e)}onBodySent(...e){return this.#e.onBodySent?.(...e)}}});var gF=h((_Ne,fF)=>{"use strict";var Uee=Sp();fF.exports=t=>{let e=t?.maxRedirections;return r=>function(s,i){let{maxRedirections:o=e,...a}=s;if(!o)return r(s,i);let c=new Uee(r,o,s,i);return r(a,c)}}});var EF=h((FNe,yF)=>{"use strict";var Oee=Up();yF.exports=t=>e=>function(n,s){return e(n,new Oee({...n,retryOptions:{...t,...n.retryOptions}},{handler:s,dispatch:e}))}});var IF=h((UNe,CF)=>{"use strict";var qee=ce(),{InvalidArgumentError:Hee,RequestAbortedError:zee}=ye(),Gee=jp(),IQ=class extends Gee{#e=1024*1024;#t=null;#r=!1;#i=!1;#s=0;#n=null;#o=null;constructor({maxSize:e},r){if(super(r),e!=null&&(!Number.isFinite(e)||e<1))throw new Hee("maxSize must be a number greater than 0");this.#e=e??this.#e,this.#o=r}onConnect(e){this.#t=e,this.#o.onConnect(this.#a.bind(this))}#a(e){this.#i=!0,this.#n=e}onHeaders(e,r,n,s){let o=qee.parseHeaders(r)["content-length"];if(o!=null&&o>this.#e)throw new zee(`Response size (${o}) larger than maxSize (${this.#e})`);return this.#i?!0:this.#o.onHeaders(e,r,n,s)}onError(e){this.#r||(e=this.#n??e,this.#o.onError(e))}onData(e){return this.#s=this.#s+e.length,this.#s>=this.#e&&(this.#r=!0,this.#i?this.#o.onError(this.#n):this.#o.onComplete([])),!0}onComplete(e){if(!this.#r){if(this.#i){this.#o.onError(this.reason);return}this.#o.onComplete(e)}}};function Yee({maxSize:t}={maxSize:1024*1024}){return e=>function(n,s){let{dumpMaxSize:i=t}=n,o=new IQ({maxSize:i},s);return e(n,o)}}CF.exports=Yee});var xF=h((ONe,QF)=>{"use strict";var{isIP:Vee}=require("node:net"),{lookup:Jee}=require("node:dns"),Wee=jp(),{InvalidArgumentError:Fc,InformationalError:$ee}=ye(),BF=Math.pow(2,31)-1,BQ=class{#e=0;#t=0;#r=new Map;dualStack=!0;affinity=null;lookup=null;pick=null;constructor(e){this.#e=e.maxTTL,this.#t=e.maxItems,this.dualStack=e.dualStack,this.affinity=e.affinity,this.lookup=e.lookup??this.#i,this.pick=e.pick??this.#s}get full(){return this.#r.size===this.#t}runLookup(e,r,n){let s=this.#r.get(e.hostname);if(s==null&&this.full){n(null,e.origin);return}let i={affinity:this.affinity,dualStack:this.dualStack,lookup:this.lookup,pick:this.pick,...r.dns,maxTTL:this.#e,maxItems:this.#t};if(s==null)this.lookup(e,i,(o,a)=>{if(o||a==null||a.length===0){n(o??new $ee("No DNS entries found"));return}this.setRecords(e,a);let c=this.#r.get(e.hostname),l=this.pick(e,c,i.affinity),A;typeof l.port=="number"?A=`:${l.port}`:e.port!==""?A=`:${e.port}`:A="",n(null,`${e.protocol}//${l.family===6?`[${l.address}]`:l.address}${A}`)});else{let o=this.pick(e,s,i.affinity);if(o==null){this.#r.delete(e.hostname),this.runLookup(e,r,n);return}let a;typeof o.port=="number"?a=`:${o.port}`:e.port!==""?a=`:${e.port}`:a="",n(null,`${e.protocol}//${o.family===6?`[${o.address}]`:o.address}${a}`)}}#i(e,r,n){Jee(e.hostname,{all:!0,family:this.dualStack===!1?this.affinity:0,order:"ipv4first"},(s,i)=>{if(s)return n(s);let o=new Map;for(let a of i)o.set(`${a.address}:${a.family}`,a);n(null,o.values())})}#s(e,r,n){let s=null,{records:i,offset:o}=r,a;if(this.dualStack?(n==null&&(o==null||o===BF?(r.offset=0,n=4):(r.offset++,n=(r.offset&1)===1?6:4)),i[n]!=null&&i[n].ips.length>0?a=i[n]:a=i[n===4?6:4]):a=i[n],a==null||a.ips.length===0)return s;a.offset==null||a.offset===BF?a.offset=0:a.offset++;let c=a.offset%a.ips.length;return s=a.ips[c]??null,s==null?s:Date.now()-s.timestamp>s.ttl?(a.ips.splice(c,1),this.pick(e,r,n)):s}setRecords(e,r){let n=Date.now(),s={records:{4:null,6:null}};for(let i of r){i.timestamp=n,typeof i.ttl=="number"?i.ttl=Math.min(i.ttl,this.#e):i.ttl=this.#e;let o=s.records[i.family]??{ips:[]};o.ips.push(i),s.records[i.family]=o}this.#r.set(e.hostname,s)}getHandler(e,r){return new QQ(this,e,r)}},QQ=class extends Wee{#e=null;#t=null;#r=null;#i=null;#s=null;constructor(e,{origin:r,handler:n,dispatch:s},i){super(n),this.#s=r,this.#i=n,this.#t={...i},this.#e=e,this.#r=s}onError(e){switch(e.code){case"ETIMEDOUT":case"ECONNREFUSED":{if(this.#e.dualStack){this.#e.runLookup(this.#s,this.#t,(r,n)=>{if(r)return this.#i.o
Line truncated
|
||||
${i}`;break;case"retry":n1(i)&&(r[s]=i);break;case"id":s1(i)&&(r[s]=i);break;case"event":i.length>0&&(r[s]=i);break}}processEvent(e){e.retry&&n1(e.retry)&&(this.state.reconnectionTime=parseInt(e.retry,10)),e.id&&s1(e.id)&&(this.state.lastEventId=e.id),e.data!==void 0&&this.push({type:e.event||"message",options:{data:e.data,lastEventId:this.state.lastEventId,origin:this.state.origin}})}clearEvent(){this.event={data:void 0,event:void 0,id:void 0,retry:void 0}}};i1.exports={EventSourceStream:lx}});var p1=h((gSe,m1)=>{"use strict";var{pipeline:sie}=require("node:stream"),{fetching:iie}=au(),{makeRequest:oie}=qc(),{webidl:pi}=vt(),{EventSourceStream:aie}=o1(),{parseMIMEType:cie}=ir(),{createFastMessageEvent:lie}=Jc(),{isNetworkError:a1}=iu(),{delay:Aie}=ax(),{kEnumerableProperty:oa}=ce(),{environmentSettingsObject:c1}=br(),l1=!1,A1=3e3,Cu=0,u1=1,Iu=2,uie="anonymous",die="use-credentials",Xc=class t extends EventTarget{#e={open:null,error:null,message:null};#t=null;#r=!1;#i=Cu;#s=null;#n=null;#o;#a;constructor(e,r={}){super(),pi.util.markAsUncloneable(this);let n="EventSource constructor";pi.argumentLengthCheck(arguments,1,n),l1||(l1=!0,process.emitWarning("EventSource is experimental, expect them to change at any time.",{code:"UNDICI-ES"})),e=pi.converters.USVString(e,n,"url"),r=pi.converters.EventSourceInitDict(r,n,"eventSourceInitDict"),this.#o=r.dispatcher,this.#a={lastEventId:"",reconnectionTime:A1};let s=c1,i;try{i=new URL(e,s.settingsObject.baseUrl),this.#a.origin=i.origin}catch(c){throw new DOMException(c,"SyntaxError")}this.#t=i.href;let o=uie;r.withCredentials&&(o=die,this.#r=!0);let a={redirect:"follow",keepalive:!0,mode:"cors",credentials:o==="anonymous"?"same-origin":"omit",referrer:"no-referrer"};a.client=c1.settingsObject,a.headersList=[["accept",{name:"accept",value:"text/event-stream"}]],a.cache="no-store",a.initiator="other",a.urlList=[new URL(this.#t)],this.#s=oie(a),this.#c()}get readyState(){return this.#i}get url(){return this.#t}get withCredentials(){return this.#r}#c(){if(this.#i===Iu)return;this.#i=Cu;let e={request:this.#s,dispatcher:this.#o},r=n=>{a1(n)&&(this.dispatchEvent(new Event("error")),this.close()),this.#l()};e.processResponseEndOfBody=r,e.processResponse=n=>{if(a1(n))if(n.aborted){this.close(),this.dispatchEvent(new Event("error"));return}else{this.#l();return}let s=n.headersList.get("content-type",!0),i=s!==null?cie(s):"failure",o=i!=="failure"&&i.essence==="text/event-stream";if(n.status!==200||o===!1){this.close(),this.dispatchEvent(new Event("error"));return}this.#i=u1,this.dispatchEvent(new Event("open")),this.#a.origin=n.urlList[n.urlList.length-1].origin;let a=new aie({eventSourceSettings:this.#a,push:c=>{this.dispatchEvent(lie(c.type,c.options))}});sie(n.body.stream,a,c=>{c?.aborted===!1&&(this.close(),this.dispatchEvent(new Event("error")))})},this.#n=iie(e)}async#l(){this.#i!==Iu&&(this.#i=Cu,this.dispatchEvent(new Event("error")),await Aie(this.#a.reconnectionTime),this.#i===Cu&&(this.#a.lastEventId.length&&this.#s.headersList.set("last-event-id",this.#a.lastEventId,!0),this.#c()))}close(){pi.brandCheck(this,t),this.#i!==Iu&&(this.#i=Iu,this.#n.abort(),this.#s=null)}get onopen(){return this.#e.open}set onopen(e){this.#e.open&&this.removeEventListener("open",this.#e.open),typeof e=="function"?(this.#e.open=e,this.addEventListener("open",e)):this.#e.open=null}get onmessage(){return this.#e.message}set onmessage(e){this.#e.message&&this.removeEventListener("message",this.#e.message),typeof e=="function"?(this.#e.message=e,this.addEventListener("message",e)):this.#e.message=null}get onerror(){return this.#e.error}set onerror(e){this.#e.error&&this.removeEventListener("error",this.#e.error),typeof e=="function"?(this.#e.error=e,this.addEventListener("error",e)):this.#e.error=null}},d1={CONNECTING:{__proto__:null,configurable:!1,enumerable:!0,value:Cu,writable:!1},OPEN:{__proto__:null,configurable:!1,enumerable:!0,value:u1,writable:!1},CLOSED:{__proto__:null,configurable:!1,enumerable:!0,value:Iu,writable:!1}};Object.defineProperties(Xc,d1);Object.defineProperties(Xc.prototype,d1);Object.defineProperties(Xc.prototype,{close:oa,onerror:oa,onmessage:oa,onopen:oa,readyState:oa,url:oa,withCredentials:oa});pi.converters.EventSourceInitDict=pi.dictionaryConverter([{key:"withCredentials",converter:pi.converters.boolean,defaultValue:()=>!1},{key:"dispatcher",converter:pi.converters.any}]);m1.exports={EventSource:Xc,defaultReconnectionTime:A1}});var Qu=h((ySe,j)=>{"use strict";var mie=bc(),h1=wA(),pie=Nc(),hie=dL(),fie=Sc(),gie=kB(),yie=LL(),Eie=HL(),f1=ye(),_h=ce(),{InvalidArgumentError:Lh}=f1,Zc=S_(),Cie=NA(),Iie=pQ(),Bie=AF(),Qie=gQ(),xie=tQ(),wie=Up(),{getGlobalDispatcher:g1,setGlobalDispatcher:bie}=$p(),Nie=jp(),Sie=Sp(),Rie=Rp();Object.assign(h1.prototype,Zc);j.exports.Dispatcher=h1;j.exports.Client=mie;j.exports.Pool=pie;j.exports.BalancedPool=hie;j.exports.Agent=fie;j.exports.ProxyAgent=gie;j.exports.EnvHttpProxyAgent=yie;j.exports.RetryAgent=Eie;j.exports.RetryHandler=wi
Line truncated
|
||||
%s`,w,w,y,n);var D=y.type==="*"?uw:y.type==="?"?Aw:"\\"+y.type;s=!0,n=n.slice(0,y.reStart)+D+"\\("+w}p(),i&&(n+="\\\\");var _=!1;switch(n.charAt(0)){case"[":case".":case"(":_=!0}for(var ae=a.length-1;ae>-1;ae--){var ge=a[ae],Be=n.slice(0,ge.reStart),H=n.slice(ge.reStart,ge.reEnd-8),ee=n.slice(ge.reEnd-8,ge.reEnd),F=n.slice(ge.reEnd);ee+=F;var de=Be.split("(").length-1,At=F;for(f=0;f<de;f++)At=At.replace(/\)[+*?]?/,"");F=At;var He="";F===""&&e!==uf&&(He="$");var tt=Be+H+F+He+ee;n=tt}if(n!==""&&s&&(n="(?=.)"+n),_&&(n=d+n),e===uf)return[n,s];if(!s)return $le(t);var ei=r.nocase?"i":"";try{var wr=new RegExp("^"+n+"$",ei)}catch{return new RegExp("$.")}return wr._glob=t,wr._src=n,wr}_r.makeRe=function(t,e){return new Dt(t,e||{}).makeRe()};Dt.prototype.makeRe=Wle;function Wle(){if(this.regexp||this.regexp===!1)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var e=this.options,r=e.noglobstar?uw:e.dot?Ole:qle,n=e.nocase?"i":"",s=t.map(function(i){return i.map(function(o){return o===dw?r:typeof o=="string"?jle(o):o._src}).join("\\/")}).join("|");s="^(?:"+s+")$",this.negate&&(s="^(?!"+s+").*$");try{this.regexp=new RegExp(s,n)}catch{this.regexp=!1}return this.regexp}_r.match=function(t,e,r){r=r||{};var n=new Dt(e,r);return t=t.filter(function(s){return n.match(s)}),n.options.nonull&&!t.length&&t.push(e),t};Dt.prototype.match=function(e,r){if(typeof r>"u"&&(r=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&r)return!0;var n=this.options;Gu.sep!=="/"&&(e=e.split(Gu.sep).join("/")),e=e.split(CH),this.debug(this.pattern,"split",e);var s=this.set;this.debug(this.pattern,"set",s);var i,o;for(o=e.length-1;o>=0&&(i=e[o],!i);o--);for(o=0;o<s.length;o++){var a=s[o],c=e;n.matchBase&&a.length===1&&(c=[i]);var l=this.matchOne(c,a,r);if(l)return n.flipNegate?!0:!this.negate}return n.flipNegate?!1:this.negate};Dt.prototype.matchOne=function(t,e,r){var n=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var s=0,i=0,o=t.length,a=e.length;s<o&&i<a;s++,i++){this.debug("matchOne loop");var c=e[i],l=t[s];if(this.debug(e,c,l),c===!1)return!1;if(c===dw){this.debug("GLOBSTAR",[e,c,l]);var A=s,u=i+1;if(u===a){for(this.debug("** at the end");s<o;s++)if(t[s]==="."||t[s]===".."||!n.dot&&t[s].charAt(0)===".")return!1;return!0}for(;A<o;){var d=t[A];if(this.debug(`
|
||||
`.trim())}};$F.exports=AQ});var Op=h((i0e,e2)=>{"use strict";var KF=Symbol.for("undici.globalDispatcher.1"),{InvalidArgumentError:gee}=Ee(),yee=Qc();ZF()===void 0&&XF(new yee);function XF(t){if(!t||typeof t.dispatch!="function")throw new gee("Argument agent must implement Agent");Object.defineProperty(globalThis,KF,{value:t,writable:!0,enumerable:!1,configurable:!1})}function ZF(){return globalThis[KF]}e2.exports={setGlobalDispatcher:XF,getGlobalDispatcher:ZF}});var qp=h((a0e,t2)=>{"use strict";t2.exports=class{#e;constructor(e){if(typeof e!="object"||e===null)throw new TypeError("handler must be an object");this.#e=e}onConnect(...e){return this.#e.onConnect?.(...e)}onError(...e){return this.#e.onError?.(...e)}onUpgrade(...e){return this.#e.onUpgrade?.(...e)}onResponseStarted(...e){return this.#e.onResponseStarted?.(...e)}onHeaders(...e){return this.#e.onHeaders?.(...e)}onData(...e){return this.#e.onData?.(...e)}onComplete(...e){return this.#e.onComplete?.(...e)}onBodySent(...e){return this.#e.onBodySent?.(...e)}}});var n2=h((c0e,r2)=>{"use strict";var Eee=Ep();r2.exports=t=>{let e=t?.maxRedirections;return r=>function(s,i){let{maxRedirections:o=e,...a}=s;if(!o)return r(s,i);let c=new Eee(r,o,s,i);return r(a,c)}}});var i2=h((l0e,s2)=>{"use strict";var Cee=Pp();s2.exports=t=>e=>function(n,s){return e(n,new Cee({...n,retryOptions:{...t,...n.retryOptions}},{handler:s,dispatch:e}))}});var a2=h((A0e,o2)=>{"use strict";var Iee=ce(),{InvalidArgumentError:Bee,RequestAbortedError:Qee}=Ee(),xee=qp(),uQ=class extends xee{#e=1024*1024;#t=null;#r=!1;#i=!1;#s=0;#n=null;#o=null;constructor({maxSize:e},r){if(super(r),e!=null&&(!Number.isFinite(e)||e<1))throw new Bee("maxSize must be a number greater than 0");this.#e=e??this.#e,this.#o=r}onConnect(e){this.#t=e,this.#o.onConnect(this.#a.bind(this))}#a(e){this.#i=!0,this.#n=e}onHeaders(e,r,n,s){let o=Iee.parseHeaders(r)["content-length"];if(o!=null&&o>this.#e)throw new Qee(`Response size (${o}) larger than maxSize (${this.#e})`);return this.#i?!0:this.#o.onHeaders(e,r,n,s)}onError(e){this.#r||(e=this.#n??e,this.#o.onError(e))}onData(e){return this.#s=this.#s+e.length,this.#s>=this.#e&&(this.#r=!0,this.#i?this.#o.onError(this.#n):this.#o.onComplete([])),!0}onComplete(e){if(!this.#r){if(this.#i){this.#o.onError(this.reason);return}this.#o.onComplete(e)}}};function bee({maxSize:t}={maxSize:1024*1024}){return e=>function(n,s){let{dumpMaxSize:i=t}=n,o=new uQ({maxSize:i},s);return e(n,o)}}o2.exports=bee});var A2=h((u0e,l2)=>{"use strict";var{isIP:wee}=require("node:net"),{lookup:Nee}=require("node:dns"),See=qp(),{InvalidArgumentError:kc,InformationalError:Ree}=Ee(),c2=Math.pow(2,31)-1,dQ=class{#e=0;#t=0;#r=new Map;dualStack=!0;affinity=null;lookup=null;pick=null;constructor(e){this.#e=e.maxTTL,this.#t=e.maxItems,this.dualStack=e.dualStack,this.affinity=e.affinity,this.lookup=e.lookup??this.#i,this.pick=e.pick??this.#s}get full(){return this.#r.size===this.#t}runLookup(e,r,n){let s=this.#r.get(e.hostname);if(s==null&&this.full){n(null,e.origin);return}let i={affinity:this.affinity,dualStack:this.dualStack,lookup:this.lookup,pick:this.pick,...r.dns,maxTTL:this.#e,maxItems:this.#t};if(s==null)this.lookup(e,i,(o,a)=>{if(o||a==null||a.length===0){n(o??new Ree("No DNS entries found"));return}this.setRecords(e,a);let c=this.#r.get(e.hostname),l=this.pick(e,c,i.affinity),A;typeof l.port=="number"?A=`:${l.port}`:e.port!==""?A=`:${e.port}`:A="",n(null,`${e.protocol}//${l.family===6?`[${l.address}]`:l.address}${A}`)});else{let o=this.pick(e,s,i.affinity);if(o==null){this.#r.delete(e.hostname),this.runLookup(e,r,n);return}let a;typeof o.port=="number"?a=`:${o.port}`:e.port!==""?a=`:${e.port}`:a="",n(null,`${e.protocol}//${o.family===6?`[${o.address}]`:o.address}${a}`)}}#i(e,r,n){Nee(e.hostname,{all:!0,family:this.dualStack===!1?this.affinity:0,order:"ipv4first"},(s,i)=>{if(s)return n(s);let o=new Map;for(let a of i)o.set(`${a.address}:${a.family}`,a);n(null,o.values())})}#s(e,r,n){let s=null,{records:i,offset:o}=r,a;if(this.dualStack?(n==null&&(o==null||o===c2?(r.offset=0,n=4):(r.offset++,n=(r.offset&1)===1?6:4)),i[n]!=null&&i[n].ips.length>0?a=i[n]:a=i[n===4?6:4]):a=i[n],a==null||a.ips.length===0)return s;a.offset==null||a.offset===c2?a.offset=0:a.offset++;let c=a.offset%a.ips.length;return s=a.ips[c]??null,s==null?s:Date.now()-s.timestamp>s.ttl?(a.ips.splice(c,1),this.pick(e,r,n)):s}setRecords(e,r){let n=Date.now(),s={records:{4:null,6:null}};for(let i of r){i.timestamp=n,typeof i.ttl=="number"?i.ttl=Math.min(i.ttl,this.#e):i.ttl=this.#e;let o=s.records[i.family]??{ips:[]};o.ips.push(i),s.records[i.family]=o}this.#r.set(e.hostname,s)}getHandler(e,r){return new mQ(this,e,r)}},mQ=class extends See{#e=null;#t=null;#r=null;#i=null;#s=null;constructor(e,{origin:r,handler:n,dispatch:s},i){super(n),this.#s=r,this.#i=n,this.#t={...i},this.#e=e,this.#r=s}onError(e){switch(e.code){case"ETIMEDOUT":case"ECONNREFUSED":{if(this.#e.dualStack){this.#e.runLookup(this.#s,this.#t,(r,n)=>{if(r)return this.#i.o
Line truncated
|
||||
${i}`;break;case"retry":zU(i)&&(r[s]=i);break;case"id":GU(i)&&(r[s]=i);break;case"event":i.length>0&&(r[s]=i);break}}processEvent(e){e.retry&&zU(e.retry)&&(this.state.reconnectionTime=parseInt(e.retry,10)),e.id&&GU(e.id)&&(this.state.lastEventId=e.id),e.data!==void 0&&this.push({type:e.event||"message",options:{data:e.data,lastEventId:this.state.lastEventId,origin:this.state.origin}})}clearEvent(){this.event={data:void 0,event:void 0,id:void 0,retry:void 0}}};YU.exports={EventSourceStream:ZQ}});var e1=h((H0e,ZU)=>{"use strict";var{pipeline:_se}=require("node:stream"),{fetching:Use}=ru(),{makeRequest:Ose}=Lc(),{webidl:pi}=vt(),{EventSourceStream:qse}=VU(),{parseMIMEType:Hse}=or(),{createFastMessageEvent:zse}=Hc(),{isNetworkError:JU}=eu(),{delay:Gse}=KQ(),{kEnumerableProperty:na}=ce(),{environmentSettingsObject:WU}=Sr(),$U=!1,jU=3e3,hu=0,KU=1,fu=2,Yse="anonymous",Vse="use-credentials",Jc=class t extends EventTarget{#e={open:null,error:null,message:null};#t=null;#r=!1;#i=hu;#s=null;#n=null;#o;#a;constructor(e,r={}){super(),pi.util.markAsUncloneable(this);let n="EventSource constructor";pi.argumentLengthCheck(arguments,1,n),$U||($U=!0,process.emitWarning("EventSource is experimental, expect them to change at any time.",{code:"UNDICI-ES"})),e=pi.converters.USVString(e,n,"url"),r=pi.converters.EventSourceInitDict(r,n,"eventSourceInitDict"),this.#o=r.dispatcher,this.#a={lastEventId:"",reconnectionTime:jU};let s=WU,i;try{i=new URL(e,s.settingsObject.baseUrl),this.#a.origin=i.origin}catch(c){throw new DOMException(c,"SyntaxError")}this.#t=i.href;let o=Yse;r.withCredentials&&(o=Vse,this.#r=!0);let a={redirect:"follow",keepalive:!0,mode:"cors",credentials:o==="anonymous"?"same-origin":"omit",referrer:"no-referrer"};a.client=WU.settingsObject,a.headersList=[["accept",{name:"accept",value:"text/event-stream"}]],a.cache="no-store",a.initiator="other",a.urlList=[new URL(this.#t)],this.#s=Ose(a),this.#c()}get readyState(){return this.#i}get url(){return this.#t}get withCredentials(){return this.#r}#c(){if(this.#i===fu)return;this.#i=hu;let e={request:this.#s,dispatcher:this.#o},r=n=>{JU(n)&&(this.dispatchEvent(new Event("error")),this.close()),this.#l()};e.processResponseEndOfBody=r,e.processResponse=n=>{if(JU(n))if(n.aborted){this.close(),this.dispatchEvent(new Event("error"));return}else{this.#l();return}let s=n.headersList.get("content-type",!0),i=s!==null?Hse(s):"failure",o=i!=="failure"&&i.essence==="text/event-stream";if(n.status!==200||o===!1){this.close(),this.dispatchEvent(new Event("error"));return}this.#i=KU,this.dispatchEvent(new Event("open")),this.#a.origin=n.urlList[n.urlList.length-1].origin;let a=new qse({eventSourceSettings:this.#a,push:c=>{this.dispatchEvent(zse(c.type,c.options))}});_se(n.body.stream,a,c=>{c?.aborted===!1&&(this.close(),this.dispatchEvent(new Event("error")))})},this.#n=Use(e)}async#l(){this.#i!==fu&&(this.#i=hu,this.dispatchEvent(new Event("error")),await Gse(this.#a.reconnectionTime),this.#i===hu&&(this.#a.lastEventId.length&&this.#s.headersList.set("last-event-id",this.#a.lastEventId,!0),this.#c()))}close(){pi.brandCheck(this,t),this.#i!==fu&&(this.#i=fu,this.#n.abort(),this.#s=null)}get onopen(){return this.#e.open}set onopen(e){this.#e.open&&this.removeEventListener("open",this.#e.open),typeof e=="function"?(this.#e.open=e,this.addEventListener("open",e)):this.#e.open=null}get onmessage(){return this.#e.message}set onmessage(e){this.#e.message&&this.removeEventListener("message",this.#e.message),typeof e=="function"?(this.#e.message=e,this.addEventListener("message",e)):this.#e.message=null}get onerror(){return this.#e.error}set onerror(e){this.#e.error&&this.removeEventListener("error",this.#e.error),typeof e=="function"?(this.#e.error=e,this.addEventListener("error",e)):this.#e.error=null}},XU={CONNECTING:{__proto__:null,configurable:!1,enumerable:!0,value:hu,writable:!1},OPEN:{__proto__:null,configurable:!1,enumerable:!0,value:KU,writable:!1},CLOSED:{__proto__:null,configurable:!1,enumerable:!0,value:fu,writable:!1}};Object.defineProperties(Jc,XU);Object.defineProperties(Jc.prototype,XU);Object.defineProperties(Jc.prototype,{close:na,onerror:na,onmessage:na,onopen:na,readyState:na,url:na,withCredentials:na});pi.converters.EventSourceInitDict=pi.dictionaryConverter([{key:"withCredentials",converter:pi.converters.boolean,defaultValue:()=>!1},{key:"dispatcher",converter:pi.converters.any}]);ZU.exports={EventSource:Jc,defaultReconnectionTime:jU}});var ex=h((z0e,j)=>{"use strict";var Jse=Ic(),t1=CA(),Wse=Bc(),$se=XM(),jse=Qc(),Kse=QB(),Xse=BL(),Zse=SL(),r1=Ee(),Sh=ce(),{InvalidArgumentError:Nh}=r1,Wc=pF(),eie=BA(),tie=sQ(),rie=jF(),nie=aQ(),sie=YB(),iie=Pp(),{getGlobalDispatcher:n1,setGlobalDispatcher:oie}=Op(),aie=qp(),cie=Ep(),lie=Cp();Object.assign(t1.prototype,Wc);j.exports.Dispatcher=t1;j.exports.Client=Jse;j.exports.Pool=Wse;j.exports.BalancedPool=$se;j.exports.Agent=jse;j.exports.ProxyAgent=Kse;j.exports.EnvHttpProxyAgent=Xse;j.exports.RetryAgent=Zse;j.exports.RetryHandler=ii
Line truncated
|
||||
%s`,w,w,y,n);var D=y.type==="*"?Zx:y.type==="?"?Xx:"\\"+y.type;s=!0,n=n.slice(0,y.reStart)+D+"\\("+w}p(),i&&(n+="\\\\");var F=!1;switch(n.charAt(0)){case"[":case".":case"(":F=!0}for(var ae=a.length-1;ae>-1;ae--){var ye=a[ae],Qe=n.slice(0,ye.reStart),H=n.slice(ye.reStart,ye.reEnd-8),ee=n.slice(ye.reEnd-8,ye.reEnd),_=n.slice(ye.reEnd);ee+=_;var de=Qe.split("(").length-1,At=_;for(f=0;f<de;f++)At=At.replace(/\)[+*?]?/,"");_=At;var He="";_===""&&e!==jh&&(He="$");var tt=Qe+H+_+He+ee;n=tt}if(n!==""&&s&&(n="(?=.)"+n),F&&(n=d+n),e===jh)return[n,s];if(!s)return Cle(t);var Zs=r.nocase?"i":"";try{var Nr=new RegExp("^"+n+"$",Zs)}catch{return new RegExp("$.")}return Nr._glob=t,Nr._src=n,Nr}_r.makeRe=function(t,e){return new Dt(t,e||{}).makeRe()};Dt.prototype.makeRe=Ele;function Ele(){if(this.regexp||this.regexp===!1)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var e=this.options,r=e.noglobstar?Zx:e.dot?ule:dle,n=e.nocase?"i":"",s=t.map(function(i){return i.map(function(o){return o===eb?r:typeof o=="string"?Ile(o):o._src}).join("\\/")}).join("|");s="^(?:"+s+")$",this.negate&&(s="^(?!"+s+").*$");try{this.regexp=new RegExp(s,n)}catch{this.regexp=!1}return this.regexp}_r.match=function(t,e,r){r=r||{};var n=new Dt(e,r);return t=t.filter(function(s){return n.match(s)}),n.options.nonull&&!t.length&&t.push(e),t};Dt.prototype.match=function(e,r){if(typeof r>"u"&&(r=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&r)return!0;var n=this.options;Lu.sep!=="/"&&(e=e.split(Lu.sep).join("/")),e=e.split(eH),this.debug(this.pattern,"split",e);var s=this.set;this.debug(this.pattern,"set",s);var i,o;for(o=e.length-1;o>=0&&(i=e[o],!i);o--);for(o=0;o<s.length;o++){var a=s[o],c=e;n.matchBase&&a.length===1&&(c=[i]);var l=this.matchOne(c,a,r);if(l)return n.flipNegate?!0:!this.negate}return n.flipNegate?!1:this.negate};Dt.prototype.matchOne=function(t,e,r){var n=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var s=0,i=0,o=t.length,a=e.length;s<o&&i<a;s++,i++){this.debug("matchOne loop");var c=e[i],l=t[s];if(this.debug(e,c,l),c===!1)return!1;if(c===eb){this.debug("GLOBSTAR",[e,c,l]);var A=s,u=i+1;if(u===a){for(this.debug("** at the end");s<o;s++)if(t[s]==="."||t[s]===".."||!n.dot&&t[s].charAt(0)===".")return!1;return!0}for(;A<o;){var d=t[A];if(this.debug(`
|
||||
globstar while`,t,A,e,u,d),this.matchOne(t.slice(A),e.slice(u),r))return this.debug("globstar found match!",A,o,d),!0;if(d==="."||d===".."||!n.dot&&d.charAt(0)==="."){this.debug("dot detected!",t,A,e,u);break}this.debug("globstar swallow a segment, and continue"),A++}return!!(r&&(this.debug(`
|
||||
>>> no match, partial?`,t,A,e,u),A===o))}var m;if(typeof c=="string"?(m=l===c,this.debug("string match",c,l,m)):(m=l.match(c),this.debug("pattern match",c,l,m)),!m)return!1}if(s===o&&i===a)return!0;if(s===o)return r;if(i===a)return s===o-1&&t[s]==="";throw new Error("wtf?")};function $le(t){return t.replace(/\\(.)/g,"$1")}function jle(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}});var Ju=h((Tve,NH)=>{"use strict";var sAe="2.0.0",iAe=Number.MAX_SAFE_INTEGER||9007199254740991,oAe=16,aAe=250,cAe=["major","premajor","minor","preminor","patch","prepatch","prerelease"];NH.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:oAe,MAX_SAFE_BUILD_LENGTH:aAe,MAX_SAFE_INTEGER:iAe,RELEASE_TYPES:cAe,SEMVER_SPEC_VERSION:sAe,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var Wu=h((Mve,SH)=>{"use strict";var lAe=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};SH.exports=lAe});var Al=h((hs,RH)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:pw,MAX_SAFE_BUILD_LENGTH:AAe,MAX_LENGTH:uAe}=Ju(),dAe=Wu();hs=RH.exports={};var mAe=hs.re=[],pAe=hs.safeRe=[],M=hs.src=[],hAe=hs.safeSrc=[],L=hs.t={},fAe=0,hw="[a-zA-Z0-9-]",gAe=[["\\s",1],["\\d",uAe],[hw,AAe]],yAe=t=>{for(let[e,r]of gAe)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);return t},re=(t,e,r)=>{let n=yAe(e),s=fAe++;dAe(t,s,e),L[t]=s,M[s]=e,hAe[s]=n,mAe[s]=new RegExp(e,r?"g":void 0),pAe[s]=new RegExp(n,r?"g":void 0)};re("NUMERICIDENTIFIER","0|[1-9]\\d*");re("NUMERICIDENTIFIERLOOSE","\\d+");re("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${hw}*`);re("MAINVERSION",`(${M[L.NUMERICIDENTIFIER]})\\.(${M[L.NUMERICIDENTIFIER]})\\.(${M[L.NUMERICIDENTIFIER]})`);re("MAINVERSIONLOOSE",`(${M[L.NUMERICIDENTIFIERLOOSE]})\\.(${M[L.NUMERICIDENTIFIERLOOSE]})\\.(${M[L.NUMERICIDENTIFIERLOOSE]})`);re("PRERELEASEIDENTIFIER",`(?:${M[L.NONNUMERICIDENTIFIER]}|${M[L.NUMERICIDENTIFIER]})`);re("PRERELEASEIDENTIFIERLOOSE",`(?:${M[L.NONNUMERICIDENTIFIER]}|${M[L.NUMERICIDENTIFIERLOOSE]})`);re("PRERELEASE",`(?:-(${M[L.PRERELEASEIDENTIFIER]}(?:\\.${M[L.PRERELEASEIDENTIFIER]})*))`);re("PRERELEASELOOSE",`(?:-?(${M[L.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${M[L.PRERELEASEIDENTIFIERLOOSE]})*))`);re("BUILDIDENTIFIER",`${hw}+`);re("BUILD",`(?:\\+(${M[L.BUILDIDENTIFIER]}(?:\\.${M[L.BUILDIDENTIFIER]})*))`);re("FULLPLAIN",`v?${M[L.MAINVERSION]}${M[L.PRERELEASE]}?${M[L.BUILD]}?`);re("FULL",`^${M[L.FULLPLAIN]}$`);re("LOOSEPLAIN",`[v=\\s]*${M[L.MAINVERSIONLOOSE]}${M[L.PRERELEASELOOSE]}?${M[L.BUILD]}?`);re("LOOSE",`^${M[L.LOOSEPLAIN]}$`);re("GTLT","((?:<|>)?=?)");re("XRANGEIDENTIFIERLOOSE",`${M[L.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);re("XRANGEIDENTIFIER",`${M[L.NUMERICIDENTIFIER]}|x|X|\\*`);re("XRANGEPLAIN",`[v=\\s]*(${M[L.XRANGEIDENTIFIER]})(?:\\.(${M[L.XRANGEIDENTIFIER]})(?:\\.(${M[L.XRANGEIDENTIFIER]})(?:${M[L.PRERELEASE]})?${M[L.BUILD]}?)?)?`);re("XRANGEPLAINLOOSE",`[v=\\s]*(${M[L.XRANGEIDENTIFIERLOOSE]})(?:\\.(${M[L.XRANGEIDENTIFIERLOOSE]})(?:\\.(${M[L.XRANGEIDENTIFIERLOOSE]})(?:${M[L.PRERELEASELOOSE]})?${M[L.BUILD]}?)?)?`);re("XRANGE",`^${M[L.GTLT]}\\s*${M[L.XRANGEPLAIN]}$`);re("XRANGELOOSE",`^${M[L.GTLT]}\\s*${M[L.XRANGEPLAINLOOSE]}$`);re("COERCEPLAIN",`(^|[^\\d])(\\d{1,${pw}})(?:\\.(\\d{1,${pw}}))?(?:\\.(\\d{1,${pw}}))?`);re("COERCE",`${M[L.COERCEPLAIN]}(?:$|[^\\d])`);re("COERCEFULL",M[L.COERCEPLAIN]+`(?:${M[L.PRERELEASE]})?(?:${M[L.BUILD]})?(?:$|[^\\d])`);re("COERCERTL",M[L.COERCE],!0);re("COERCERTLFULL",M[L.COERCEFULL],!0);re("LONETILDE","(?:~>?)");re("TILDETRIM",`(\\s*)${M[L.LONETILDE]}\\s+`,!0);hs.tildeTrimReplace="$1~";re("TILDE",`^${M[L.LONETILDE]}${M[L.XRANGEPLAIN]}$`);re("TILDELOOSE",`^${M[L.LONETILDE]}${M[L.XRANGEPLAINLOOSE]}$`);re("LONECARET","(?:\\^)");re("CARETTRIM",`(\\s*)${M[L.LONECARET]}\\s+`,!0);hs.caretTrimReplace="$1^";re("CARET",`^${M[L.LONECARET]}${M[L.XRANGEPLAIN]}$`);re("CARETLOOSE",`^${M[L.LONECARET]}${M[L.XRANGEPLAINLOOSE]}$`);re("COMPARATORLOOSE",`^${M[L.GTLT]}\\s*(${M[L.LOOSEPLAIN]})$|^$`);re("COMPARATOR",`^${M[L.GTLT]}\\s*(${M[L.FULLPLAIN]})$|^$`);re("COMPARATORTRIM",`(\\s*)${M[L.GTLT]}\\s*(${M[L.LOOSEPLAIN]}|${M[L.XRANGEPLAIN]})`,!0);hs.comparatorTrimReplace="$1$2$3";re("HYPHENRANGE",`^\\s*(${M[L.XRANGEPLAIN]})\\s+-\\s+(${M[L.XRANGEPLAIN]})\\s*$`);re("HYPHENRANGELOOSE",`^\\s*(${M[L.XRANGEPLAINLOOSE]})\\s+-\\s+(${M[L.XRANGEPLAINLOOSE]})\\s*$`);re("STAR","(<|>)?=?\\s*\\*");re("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");re("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var hf=h((Lve,PH)=>{"use strict";var EAe=Object.freeze({loose:!0}),CAe=Object.freeze({}),IAe=t=>t?typeof t!="object"?EAe:t:CAe;PH.exports=IAe});var fw=h((_ve,kH)=>{"use strict";var vH=/^[0-9]+$/,DH=(t,e)=>{if(typeof t=="number"&&typeof e=="number")return t===e?0:t<e?-1:1;let r=vH.test(t),n=vH.test(e);return r&&n&&(t=+t,e=+e),t===e?0:r&&!n?-1:n&&!r?1:t<e?-1:1},BAe=(t,e)=>DH(e,t);kH.exports={compareIdentifiers:DH,rcompareIdentifiers:BAe}});var qt=h((Fve,MH)=>{"use strict";var ff=Wu(),{MAX_LENGTH:TH,MAX_SAFE_INTEGER:gf}=Ju(),{
Line truncated
|
||||
>>> no match, partial?`,t,A,e,u),A===o))}var m;if(typeof c=="string"?(m=l===c,this.debug("string match",c,l,m)):(m=l.match(c),this.debug("pattern match",c,l,m)),!m)return!1}if(s===o&&i===a)return!0;if(s===o)return r;if(i===a)return s===o-1&&t[s]==="";throw new Error("wtf?")};function Cle(t){return t.replace(/\\(.)/g,"$1")}function Ile(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}});var Uu=h((jPe,aH)=>{"use strict";var Rle="2.0.0",Ple=Number.MAX_SAFE_INTEGER||9007199254740991,vle=16,Dle=250,kle=["major","premajor","minor","preminor","patch","prepatch","prerelease"];aH.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:vle,MAX_SAFE_BUILD_LENGTH:Dle,MAX_SAFE_INTEGER:Ple,RELEASE_TYPES:kle,SEMVER_SPEC_VERSION:Rle,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var Ou=h((KPe,cH)=>{"use strict";var Tle=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};cH.exports=Tle});var ol=h((ps,lH)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:rb,MAX_SAFE_BUILD_LENGTH:Mle,MAX_LENGTH:Lle}=Uu(),Fle=Ou();ps=lH.exports={};var _le=ps.re=[],Ule=ps.safeRe=[],M=ps.src=[],Ole=ps.safeSrc=[],L=ps.t={},qle=0,nb="[a-zA-Z0-9-]",Hle=[["\\s",1],["\\d",Lle],[nb,Mle]],zle=t=>{for(let[e,r]of Hle)t=t.split(`${e}*`).join(`${e}{0,${r}}`).split(`${e}+`).join(`${e}{1,${r}}`);return t},re=(t,e,r)=>{let n=zle(e),s=qle++;Fle(t,s,e),L[t]=s,M[s]=e,Ole[s]=n,_le[s]=new RegExp(e,r?"g":void 0),Ule[s]=new RegExp(n,r?"g":void 0)};re("NUMERICIDENTIFIER","0|[1-9]\\d*");re("NUMERICIDENTIFIERLOOSE","\\d+");re("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${nb}*`);re("MAINVERSION",`(${M[L.NUMERICIDENTIFIER]})\\.(${M[L.NUMERICIDENTIFIER]})\\.(${M[L.NUMERICIDENTIFIER]})`);re("MAINVERSIONLOOSE",`(${M[L.NUMERICIDENTIFIERLOOSE]})\\.(${M[L.NUMERICIDENTIFIERLOOSE]})\\.(${M[L.NUMERICIDENTIFIERLOOSE]})`);re("PRERELEASEIDENTIFIER",`(?:${M[L.NONNUMERICIDENTIFIER]}|${M[L.NUMERICIDENTIFIER]})`);re("PRERELEASEIDENTIFIERLOOSE",`(?:${M[L.NONNUMERICIDENTIFIER]}|${M[L.NUMERICIDENTIFIERLOOSE]})`);re("PRERELEASE",`(?:-(${M[L.PRERELEASEIDENTIFIER]}(?:\\.${M[L.PRERELEASEIDENTIFIER]})*))`);re("PRERELEASELOOSE",`(?:-?(${M[L.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${M[L.PRERELEASEIDENTIFIERLOOSE]})*))`);re("BUILDIDENTIFIER",`${nb}+`);re("BUILD",`(?:\\+(${M[L.BUILDIDENTIFIER]}(?:\\.${M[L.BUILDIDENTIFIER]})*))`);re("FULLPLAIN",`v?${M[L.MAINVERSION]}${M[L.PRERELEASE]}?${M[L.BUILD]}?`);re("FULL",`^${M[L.FULLPLAIN]}$`);re("LOOSEPLAIN",`[v=\\s]*${M[L.MAINVERSIONLOOSE]}${M[L.PRERELEASELOOSE]}?${M[L.BUILD]}?`);re("LOOSE",`^${M[L.LOOSEPLAIN]}$`);re("GTLT","((?:<|>)?=?)");re("XRANGEIDENTIFIERLOOSE",`${M[L.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);re("XRANGEIDENTIFIER",`${M[L.NUMERICIDENTIFIER]}|x|X|\\*`);re("XRANGEPLAIN",`[v=\\s]*(${M[L.XRANGEIDENTIFIER]})(?:\\.(${M[L.XRANGEIDENTIFIER]})(?:\\.(${M[L.XRANGEIDENTIFIER]})(?:${M[L.PRERELEASE]})?${M[L.BUILD]}?)?)?`);re("XRANGEPLAINLOOSE",`[v=\\s]*(${M[L.XRANGEIDENTIFIERLOOSE]})(?:\\.(${M[L.XRANGEIDENTIFIERLOOSE]})(?:\\.(${M[L.XRANGEIDENTIFIERLOOSE]})(?:${M[L.PRERELEASELOOSE]})?${M[L.BUILD]}?)?)?`);re("XRANGE",`^${M[L.GTLT]}\\s*${M[L.XRANGEPLAIN]}$`);re("XRANGELOOSE",`^${M[L.GTLT]}\\s*${M[L.XRANGEPLAINLOOSE]}$`);re("COERCEPLAIN",`(^|[^\\d])(\\d{1,${rb}})(?:\\.(\\d{1,${rb}}))?(?:\\.(\\d{1,${rb}}))?`);re("COERCE",`${M[L.COERCEPLAIN]}(?:$|[^\\d])`);re("COERCEFULL",M[L.COERCEPLAIN]+`(?:${M[L.PRERELEASE]})?(?:${M[L.BUILD]})?(?:$|[^\\d])`);re("COERCERTL",M[L.COERCE],!0);re("COERCERTLFULL",M[L.COERCEFULL],!0);re("LONETILDE","(?:~>?)");re("TILDETRIM",`(\\s*)${M[L.LONETILDE]}\\s+`,!0);ps.tildeTrimReplace="$1~";re("TILDE",`^${M[L.LONETILDE]}${M[L.XRANGEPLAIN]}$`);re("TILDELOOSE",`^${M[L.LONETILDE]}${M[L.XRANGEPLAINLOOSE]}$`);re("LONECARET","(?:\\^)");re("CARETTRIM",`(\\s*)${M[L.LONECARET]}\\s+`,!0);ps.caretTrimReplace="$1^";re("CARET",`^${M[L.LONECARET]}${M[L.XRANGEPLAIN]}$`);re("CARETLOOSE",`^${M[L.LONECARET]}${M[L.XRANGEPLAINLOOSE]}$`);re("COMPARATORLOOSE",`^${M[L.GTLT]}\\s*(${M[L.LOOSEPLAIN]})$|^$`);re("COMPARATOR",`^${M[L.GTLT]}\\s*(${M[L.FULLPLAIN]})$|^$`);re("COMPARATORTRIM",`(\\s*)${M[L.GTLT]}\\s*(${M[L.LOOSEPLAIN]}|${M[L.XRANGEPLAIN]})`,!0);ps.comparatorTrimReplace="$1$2$3";re("HYPHENRANGE",`^\\s*(${M[L.XRANGEPLAIN]})\\s+-\\s+(${M[L.XRANGEPLAIN]})\\s*$`);re("HYPHENRANGELOOSE",`^\\s*(${M[L.XRANGEPLAINLOOSE]})\\s+-\\s+(${M[L.XRANGEPLAINLOOSE]})\\s*$`);re("STAR","(<|>)?=?\\s*\\*");re("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$");re("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")});var ef=h((XPe,AH)=>{"use strict";var Gle=Object.freeze({loose:!0}),Yle=Object.freeze({}),Vle=t=>t?typeof t!="object"?Gle:t:Yle;AH.exports=Vle});var sb=h((ZPe,mH)=>{"use strict";var uH=/^[0-9]+$/,dH=(t,e)=>{if(typeof t=="number"&&typeof e=="number")return t===e?0:t<e?-1:1;let r=uH.test(t),n=uH.test(e);return r&&n&&(t=+t,e=+e),t===e?0:r&&!n?-1:n&&!r?1:t<e?-1:1},Jle=(t,e)=>dH(e,t);mH.exports={compareIdentifiers:dH,rcompareIdentifiers:Jle}});var qt=h((eve,hH)=>{"use strict";var tf=Ou(),{MAX_LENGTH:pH,MAX_SAFE_INTEGER:rf}=Uu(),{
Line truncated
|
||||
`).join(`
|
||||
`+i),t.push(s+"m+"+eg.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=Kme()+e+" "+t[0]}function Kme(){return kt.inspectOpts.hideDate?"":new Date().toISOString()+" "}function Xme(...t){return process.stderr.write(Zf.format(...t)+`
|
||||
`)}function Zme(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function epe(){return process.env.DEBUG}function tpe(t){t.inspectOpts={};let e=Object.keys(kt.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=kt.inspectOpts[e[r]]}eg.exports=nb()(kt);var{formatters:uY}=eg.exports;uY.o=function(t){return this.inspectOpts.colors=this.useColors,Zf.inspect(t,this.inspectOpts).split(`
|
||||
`).map(e=>e.trim()).join(" ")};uY.O=function(t){return this.inspectOpts.colors=this.useColors,Zf.inspect(t,this.inspectOpts)}});var tg=h((Zke,ob)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?ob.exports=iY():ob.exports=dY()});var hY=h(pr=>{"use strict";var rpe=pr&&pr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),npe=pr&&pr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),mY=pr&&pr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&rpe(e,t,r);return npe(e,t),e};Object.defineProperty(pr,"__esModule",{value:!0});pr.req=pr.json=pr.toBuffer=void 0;var spe=mY(require("http")),ipe=mY(require("https"));async function pY(t){let e=0,r=[];for await(let n of t)e+=n.length,r.push(n);return Buffer.concat(r,e)}pr.toBuffer=pY;async function ope(t){let r=(await pY(t)).toString("utf8");try{return JSON.parse(r)}catch(n){let s=n;throw s.message+=` (input: ${r})`,s}}pr.json=ope;function ape(t,e={}){let n=((typeof t=="string"?t:t.href).startsWith("https:")?ipe:spe).request(t,e),s=new Promise((i,o)=>{n.once("response",i).once("error",o).end()});return n.then=s.then.bind(s),n}pr.req=ape});var EY=h(qr=>{"use strict";var gY=qr&&qr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),cpe=qr&&qr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),yY=qr&&qr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&gY(e,t,r);return cpe(e,t),e},lpe=qr&&qr.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&gY(e,t,r)};Object.defineProperty(qr,"__esModule",{value:!0});qr.Agent=void 0;var Ape=yY(require("net")),fY=yY(require("http")),upe=require("https");lpe(hY(),qr);var Es=Symbol("AgentBaseInternalState"),ab=class extends fY.Agent{constructor(e){super(e),this[Es]={}}isSecureEndpoint(e){if(e){if(typeof e.secureEndpoint=="boolean")return e.secureEndpoint;if(typeof e.protocol=="string")return e.protocol==="https:"}let{stack:r}=new Error;return typeof r!="string"?!1:r.split(`
|
||||
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)return null;this.sockets[e]||(this.sockets[e]=[]);let r=new Ape.Socket({writable:!1});return this.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;let n=this.sockets[e],s=n.indexOf(r);s!==-1&&(n.splice(s,1),this.totalSocketCount--,n.length===0&&delete this.sockets[e])}getName(e){return this.isSecureEndpoint(e)?upe.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){let s={...r,secureEndpoint:this.isSecureEndpoint(r)},i=this.getName(s),o=this.incrementSockets(i);Promise.resolve().then(()=>this.connect(e,s)).then(a=>{if(this.decrementSockets(i,o),a instanceof fY.Agent)try{return a.addRequest(e,s)}catch(c){return n(c)}this[Es].currentSocket=a,super.createSocket(e,r,n)},a=>{this.decrementSockets(i,o),n(a)})}createConnection(){let e=this[Es].currentSocket;if(this[Es].currentSocket=void 0,!e)throw new Error("No socket was returned in the `connect()` function");return e}get defaultPort(){return this[Es].defaultPort??(this.protocol==="https:"?443:80)}set defaultPort(e){this[Es]&&(this[Es].defaultPort=e)}get protocol(){return this[Es].protocol??(this.isSecureEndpoint()?"https:":"http:")}set protocol(e){this[Es]&&(this[Es].protocol=e)}};qr.Agent=ab});var CY=h(Cl=>{"use strict";var dpe=Cl&&Cl.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Cl,"__esModule",{value:!0});Cl.parseProxyResponse=void 0;var mpe=dpe(tg()),rg=(0,mpe.default)("https-proxy-agent:parse-proxy-response");function ppe(t){return new Promise((e,r)=>{let n=0,s=[];function i(){let A=t.read();A?l(A):t.once("readable",i)}function o(){t.removeListener("end",a),t.removeListener("error",c),t.removeListener("readable",i)}function a(){o(),rg("onend"),r(new Error("Proxy connection ended before receiving CONNECT response"))}function c(A){o(),rg("onerror %o",A),r(A)}function l(A){s.push(A),n+=A.length;let u=Buffer.concat(s,n),d=u.indexOf(`\r
|
||||
`+i),t.push(s+"m+"+Of.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=Bme()+e+" "+t[0]}function Bme(){return kt.inspectOpts.hideDate?"":new Date().toISOString()+" "}function Qme(...t){return process.stderr.write(Uf.format(...t)+`
|
||||
`)}function xme(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function bme(){return process.env.DEBUG}function wme(t){t.inspectOpts={};let e=Object.keys(kt.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=kt.inspectOpts[e[r]]}Of.exports=Yb()(kt);var{formatters:YG}=Of.exports;YG.o=function(t){return this.inspectOpts.colors=this.useColors,Uf.inspect(t,this.inspectOpts).split(`
|
||||
`).map(e=>e.trim()).join(" ")};YG.O=function(t){return this.inspectOpts.colors=this.useColors,Uf.inspect(t,this.inspectOpts)}});var qf=h((hke,Wb)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?Wb.exports=UG():Wb.exports=VG()});var $G=h(fr=>{"use strict";var Nme=fr&&fr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Sme=fr&&fr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),JG=fr&&fr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Nme(e,t,r);return Sme(e,t),e};Object.defineProperty(fr,"__esModule",{value:!0});fr.req=fr.json=fr.toBuffer=void 0;var Rme=JG(require("http")),Pme=JG(require("https"));async function WG(t){let e=0,r=[];for await(let n of t)e+=n.length,r.push(n);return Buffer.concat(r,e)}fr.toBuffer=WG;async function vme(t){let r=(await WG(t)).toString("utf8");try{return JSON.parse(r)}catch(n){let s=n;throw s.message+=` (input: ${r})`,s}}fr.json=vme;function Dme(t,e={}){let n=((typeof t=="string"?t:t.href).startsWith("https:")?Pme:Rme).request(t,e),s=new Promise((i,o)=>{n.once("response",i).once("error",o).end()});return n.then=s.then.bind(s),n}fr.req=Dme});var ZG=h(Hr=>{"use strict";var KG=Hr&&Hr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),kme=Hr&&Hr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),XG=Hr&&Hr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&KG(e,t,r);return kme(e,t),e},Tme=Hr&&Hr.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&KG(e,t,r)};Object.defineProperty(Hr,"__esModule",{value:!0});Hr.Agent=void 0;var Mme=XG(require("net")),jG=XG(require("http")),Lme=require("https");Tme($G(),Hr);var ys=Symbol("AgentBaseInternalState"),$b=class extends jG.Agent{constructor(e){super(e),this[ys]={}}isSecureEndpoint(e){if(e){if(typeof e.secureEndpoint=="boolean")return e.secureEndpoint;if(typeof e.protocol=="string")return e.protocol==="https:"}let{stack:r}=new Error;return typeof r!="string"?!1:r.split(`
|
||||
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)return null;this.sockets[e]||(this.sockets[e]=[]);let r=new Mme.Socket({writable:!1});return this.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;let n=this.sockets[e],s=n.indexOf(r);s!==-1&&(n.splice(s,1),this.totalSocketCount--,n.length===0&&delete this.sockets[e])}getName(e){return this.isSecureEndpoint(e)?Lme.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){let s={...r,secureEndpoint:this.isSecureEndpoint(r)},i=this.getName(s),o=this.incrementSockets(i);Promise.resolve().then(()=>this.connect(e,s)).then(a=>{if(this.decrementSockets(i,o),a instanceof jG.Agent)try{return a.addRequest(e,s)}catch(c){return n(c)}this[ys].currentSocket=a,super.createSocket(e,r,n)},a=>{this.decrementSockets(i,o),n(a)})}createConnection(){let e=this[ys].currentSocket;if(this[ys].currentSocket=void 0,!e)throw new Error("No socket was returned in the `connect()` function");return e}get defaultPort(){return this[ys].defaultPort??(this.protocol==="https:"?443:80)}set defaultPort(e){this[ys]&&(this[ys].defaultPort=e)}get protocol(){return this[ys].protocol??(this.isSecureEndpoint()?"https:":"http:")}set protocol(e){this[ys]&&(this[ys].protocol=e)}};Hr.Agent=$b});var eY=h(fl=>{"use strict";var Fme=fl&&fl.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(fl,"__esModule",{value:!0});fl.parseProxyResponse=void 0;var _me=Fme(qf()),Hf=(0,_me.default)("https-proxy-agent:parse-proxy-response");function Ume(t){return new Promise((e,r)=>{let n=0,s=[];function i(){let A=t.read();A?l(A):t.once("readable",i)}function o(){t.removeListener("end",a),t.removeListener("error",c),t.removeListener("readable",i)}function a(){o(),Hf("onend"),r(new Error("Proxy connection ended before receiving CONNECT response"))}function c(A){o(),Hf("onerror %o",A),r(A)}function l(A){s.push(A),n+=A.length;let u=Buffer.concat(s,n),d=u.indexOf(`\r
|
||||
\r
|
||||
`);if(d===-1){rg("have not received end of HTTP headers yet..."),i();return}let m=u.slice(0,d).toString("ascii").split(`\r
|
||||
`),p=m.shift();if(!p)return t.destroy(),r(new Error("No header received from proxy CONNECT response"));let f=p.split(" "),E=+f[1],g=f.slice(2).join(" "),y={};for(let C of m){if(!C)continue;let I=C.indexOf(":");if(I===-1)return t.destroy(),r(new Error(`Invalid header from proxy CONNECT response: "${C}"`));let w=C.slice(0,I).toLowerCase(),D=C.slice(I+1).trimStart(),_=y[w];typeof _=="string"?y[w]=[_,D]:Array.isArray(_)?_.push(D):y[w]=D}rg("got proxy server response: %o %o",p,y),o(),e({connect:{statusCode:E,statusText:g,headers:y},buffered:u})}t.on("error",c),t.on("end",a),i()})}Cl.parseProxyResponse=ppe});var bY=h(hn=>{"use strict";var hpe=hn&&hn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),fpe=hn&&hn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),xY=hn&&hn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&hpe(e,t,r);return fpe(e,t),e},wY=hn&&hn.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(hn,"__esModule",{value:!0});hn.HttpsProxyAgent=void 0;var ng=xY(require("net")),IY=xY(require("tls")),gpe=wY(require("assert")),ype=wY(tg()),Epe=EY(),Cpe=require("url"),Ipe=CY(),Ad=(0,ype.default)("https-proxy-agent"),BY=t=>t.servername===void 0&&t.host&&!ng.isIP(t.host)?{...t,servername:t.host}:t,sg=class extends Epe.Agent{constructor(e,r){super(r),this.options={path:void 0},this.proxy=typeof e=="string"?new Cpe.URL(e):e,this.proxyHeaders=r?.headers??{},Ad("Creating new HttpsProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),s=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={ALPNProtocols:["http/1.1"],...r?QY(r,"headers"):null,host:n,port:s}}async connect(e,r){let{proxy:n}=this;if(!r.host)throw new TypeError('No "host" provided');let s;n.protocol==="https:"?(Ad("Creating `tls.Socket`: %o",this.connectOpts),s=IY.connect(BY(this.connectOpts))):(Ad("Creating `net.Socket`: %o",this.connectOpts),s=ng.connect(this.connectOpts));let i=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders},o=ng.isIPv6(r.host)?`[${r.host}]`:r.host,a=`CONNECT ${o}:${r.port} HTTP/1.1\r
|
||||
`);if(d===-1){Hf("have not received end of HTTP headers yet..."),i();return}let m=u.slice(0,d).toString("ascii").split(`\r
|
||||
`),p=m.shift();if(!p)return t.destroy(),r(new Error("No header received from proxy CONNECT response"));let f=p.split(" "),E=+f[1],g=f.slice(2).join(" "),y={};for(let C of m){if(!C)continue;let I=C.indexOf(":");if(I===-1)return t.destroy(),r(new Error(`Invalid header from proxy CONNECT response: "${C}"`));let w=C.slice(0,I).toLowerCase(),D=C.slice(I+1).trimStart(),F=y[w];typeof F=="string"?y[w]=[F,D]:Array.isArray(F)?F.push(D):y[w]=D}Hf("got proxy server response: %o %o",p,y),o(),e({connect:{statusCode:E,statusText:g,headers:y},buffered:u})}t.on("error",c),t.on("end",a),i()})}fl.parseProxyResponse=Ume});var oY=h(fn=>{"use strict";var Ome=fn&&fn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),qme=fn&&fn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),sY=fn&&fn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Ome(e,t,r);return qme(e,t),e},iY=fn&&fn.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(fn,"__esModule",{value:!0});fn.HttpsProxyAgent=void 0;var zf=sY(require("net")),tY=sY(require("tls")),Hme=iY(require("assert")),zme=iY(qf()),Gme=ZG(),Yme=require("url"),Vme=eY(),rd=(0,zme.default)("https-proxy-agent"),rY=t=>t.servername===void 0&&t.host&&!zf.isIP(t.host)?{...t,servername:t.host}:t,Gf=class extends Gme.Agent{constructor(e,r){super(r),this.options={path:void 0},this.proxy=typeof e=="string"?new Yme.URL(e):e,this.proxyHeaders=r?.headers??{},rd("Creating new HttpsProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),s=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={ALPNProtocols:["http/1.1"],...r?nY(r,"headers"):null,host:n,port:s}}async connect(e,r){let{proxy:n}=this;if(!r.host)throw new TypeError('No "host" provided');let s;n.protocol==="https:"?(rd("Creating `tls.Socket`: %o",this.connectOpts),s=tY.connect(rY(this.connectOpts))):(rd("Creating `net.Socket`: %o",this.connectOpts),s=zf.connect(this.connectOpts));let i=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders},o=zf.isIPv6(r.host)?`[${r.host}]`:r.host,a=`CONNECT ${o}:${r.port} HTTP/1.1\r
|
||||
`;if(n.username||n.password){let d=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;i["Proxy-Authorization"]=`Basic ${Buffer.from(d).toString("base64")}`}i.Host=`${o}:${r.port}`,i["Proxy-Connection"]||(i["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let d of Object.keys(i))a+=`${d}: ${i[d]}\r
|
||||
`;let c=(0,Ipe.parseProxyResponse)(s);s.write(`${a}\r
|
||||
`);let{connect:l,buffered:A}=await c;if(e.emit("proxyConnect",l),this.emit("proxyConnect",l,e),l.statusCode===200)return e.once("socket",Bpe),r.secureEndpoint?(Ad("Upgrading socket connection to TLS"),IY.connect({...QY(BY(r),"host","path","port"),socket:s})):s;s.destroy();let u=new ng.Socket({writable:!1});return u.readable=!0,e.once("socket",d=>{Ad("Replaying proxy buffer for failed request"),(0,gpe.default)(d.listenerCount("data")>0),d.push(A),d.push(null)}),u}};sg.protocols=["http","https"];hn.HttpsProxyAgent=sg;function Bpe(t){t.resume()}function QY(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var RY=h(hr=>{"use strict";var Qpe=hr&&hr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),xpe=hr&&hr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),NY=hr&&hr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Qpe(e,t,r);return xpe(e,t),e};Object.defineProperty(hr,"__esModule",{value:!0});hr.req=hr.json=hr.toBuffer=void 0;var wpe=NY(require("http")),bpe=NY(require("https"));async function SY(t){let e=0,r=[];for await(let n of t)e+=n.length,r.push(n);return Buffer.concat(r,e)}hr.toBuffer=SY;async function Npe(t){let r=(await SY(t)).toString("utf8");try{return JSON.parse(r)}catch(n){let s=n;throw s.message+=` (input: ${r})`,s}}hr.json=Npe;function Spe(t,e={}){let n=((typeof t=="string"?t:t.href).startsWith("https:")?bpe:wpe).request(t,e),s=new Promise((i,o)=>{n.once("response",i).once("error",o).end()});return n.then=s.then.bind(s),n}hr.req=Spe});var kY=h(Hr=>{"use strict";var vY=Hr&&Hr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Rpe=Hr&&Hr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),DY=Hr&&Hr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&vY(e,t,r);return Rpe(e,t),e},Ppe=Hr&&Hr.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&vY(e,t,r)};Object.defineProperty(Hr,"__esModule",{value:!0});Hr.Agent=void 0;var vpe=DY(require("net")),PY=DY(require("http")),Dpe=require("https");Ppe(RY(),Hr);var Cs=Symbol("AgentBaseInternalState"),cb=class extends PY.Agent{constructor(e){super(e),this[Cs]={}}isSecureEndpoint(e){if(e){if(typeof e.secureEndpoint=="boolean")return e.secureEndpoint;if(typeof e.protocol=="string")return e.protocol==="https:"}let{stack:r}=new Error;return typeof r!="string"?!1:r.split(`
|
||||
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)return null;this.sockets[e]||(this.sockets[e]=[]);let r=new vpe.Socket({writable:!1});return this.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;let n=this.sockets[e],s=n.indexOf(r);s!==-1&&(n.splice(s,1),this.totalSocketCount--,n.length===0&&delete this.sockets[e])}getName(e){return(typeof e.secureEndpoint=="boolean"?e.secureEndpoint:this.isSecureEndpoint(e))?Dpe.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){let s={...r,secureEndpoint:this.isSecureEndpoint(r)},i=this.getName(s),o=this.incrementSockets(i);Promise.resolve().then(()=>this.connect(e,s)).then(a=>{if(this.decrementSockets(i,o),a instanceof PY.Agent)return a.addRequest(e,s);this[Cs].currentSocket=a,super.createSocket(e,r,n)},a=>{this.decrementSockets(i,o),n(a)})}createConnection(){let e=this[Cs].currentSocket;if(this[Cs].currentSocket=void 0,!e)throw new Error("No socket was returned in the `connect()` function");return e}get defaultPort(){return this[Cs].defaultPort??(this.protocol==="https:"?443:80)}set defaultPort(e){this[Cs]&&(this[Cs].defaultPort=e)}get protocol(){return this[Cs].protocol??(this.isSecureEndpoint()?"https:":"http:")}set protocol(e){this[Cs]&&(this[Cs].protocol=e)}};Hr.Agent=cb});var LY=h(fn=>{"use strict";var kpe=fn&&fn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Tpe=fn&&fn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),MY=fn&&fn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&kpe(e,t,r);return Tpe(e,t),e},Mpe=fn&&fn.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(fn,"__esModule",{value:!0});fn.HttpProxyAgent=void 0;var Lpe=MY(require("net")),_pe=MY(require("tls")),Fpe=Mpe(tg()),Upe=require("events"),Ope=kY(),TY=require("url"),Il=(0,Fpe.default)("http-proxy-agent"),ig=class extends Ope.Agent{constructor(e,r){super(r),this.proxy=typeof e=="string"?new TY.URL(e):e,this.proxyHeaders=r?.headers??{},Il("Creating new HttpProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),s=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={...r?qpe(r,"headers"):null,host:n,port:s}}addRequest(e,r){e._header=null,this.setRequestProps(e,r),super.addRequest(e,r)}setRequestProps(e,r){let{proxy:n}=this,s=r.secureEndpoint?"https:":"http:",i=e.getHeader("host")||"localhost",o=`${s}//${i}`,a=new TY.URL(e.path,o);r.port!==80&&(a.port=String(r.port)),e.path=String(a);let c=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders};if(n.username||n.password){let l=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;c["Proxy-Authorization"]=`Basic ${Buffer.from(l).toString("base64")}`}c["Proxy-Connection"]||(c["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let l of Object.keys(c)){let A=c[l];A&&e.setHeader(l,A)}}async connect(e,r){e._header=null,e.path.includes("://")||this.setRequestProps(e,r);let n,s;Il("Regenerating stored HTTP header string for request"),e._implicitHeader(),e.outputData&&e.outputData.length>0&&(Il("Patching connection write() output buffer with updated header"),n=e.outputData[0].data,s=n.indexOf(`\r
|
||||
`;let c=(0,Vme.parseProxyResponse)(s);s.write(`${a}\r
|
||||
`);let{connect:l,buffered:A}=await c;if(e.emit("proxyConnect",l),this.emit("proxyConnect",l,e),l.statusCode===200)return e.once("socket",Jme),r.secureEndpoint?(rd("Upgrading socket connection to TLS"),tY.connect({...nY(rY(r),"host","path","port"),socket:s})):s;s.destroy();let u=new zf.Socket({writable:!1});return u.readable=!0,e.once("socket",d=>{rd("Replaying proxy buffer for failed request"),(0,Hme.default)(d.listenerCount("data")>0),d.push(A),d.push(null)}),u}};Gf.protocols=["http","https"];fn.HttpsProxyAgent=Gf;function Jme(t){t.resume()}function nY(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var lY=h(gr=>{"use strict";var Wme=gr&&gr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),$me=gr&&gr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),aY=gr&&gr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Wme(e,t,r);return $me(e,t),e};Object.defineProperty(gr,"__esModule",{value:!0});gr.req=gr.json=gr.toBuffer=void 0;var jme=aY(require("http")),Kme=aY(require("https"));async function cY(t){let e=0,r=[];for await(let n of t)e+=n.length,r.push(n);return Buffer.concat(r,e)}gr.toBuffer=cY;async function Xme(t){let r=(await cY(t)).toString("utf8");try{return JSON.parse(r)}catch(n){let s=n;throw s.message+=` (input: ${r})`,s}}gr.json=Xme;function Zme(t,e={}){let n=((typeof t=="string"?t:t.href).startsWith("https:")?Kme:jme).request(t,e),s=new Promise((i,o)=>{n.once("response",i).once("error",o).end()});return n.then=s.then.bind(s),n}gr.req=Zme});var mY=h(zr=>{"use strict";var uY=zr&&zr.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),epe=zr&&zr.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),dY=zr&&zr.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&uY(e,t,r);return epe(e,t),e},tpe=zr&&zr.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&uY(e,t,r)};Object.defineProperty(zr,"__esModule",{value:!0});zr.Agent=void 0;var rpe=dY(require("net")),AY=dY(require("http")),npe=require("https");tpe(lY(),zr);var Es=Symbol("AgentBaseInternalState"),jb=class extends AY.Agent{constructor(e){super(e),this[Es]={}}isSecureEndpoint(e){if(e){if(typeof e.secureEndpoint=="boolean")return e.secureEndpoint;if(typeof e.protocol=="string")return e.protocol==="https:"}let{stack:r}=new Error;return typeof r!="string"?!1:r.split(`
|
||||
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)return null;this.sockets[e]||(this.sockets[e]=[]);let r=new rpe.Socket({writable:!1});return this.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;let n=this.sockets[e],s=n.indexOf(r);s!==-1&&(n.splice(s,1),this.totalSocketCount--,n.length===0&&delete this.sockets[e])}getName(e){return(typeof e.secureEndpoint=="boolean"?e.secureEndpoint:this.isSecureEndpoint(e))?npe.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){let s={...r,secureEndpoint:this.isSecureEndpoint(r)},i=this.getName(s),o=this.incrementSockets(i);Promise.resolve().then(()=>this.connect(e,s)).then(a=>{if(this.decrementSockets(i,o),a instanceof AY.Agent)return a.addRequest(e,s);this[Es].currentSocket=a,super.createSocket(e,r,n)},a=>{this.decrementSockets(i,o),n(a)})}createConnection(){let e=this[Es].currentSocket;if(this[Es].currentSocket=void 0,!e)throw new Error("No socket was returned in the `connect()` function");return e}get defaultPort(){return this[Es].defaultPort??(this.protocol==="https:"?443:80)}set defaultPort(e){this[Es]&&(this[Es].defaultPort=e)}get protocol(){return this[Es].protocol??(this.isSecureEndpoint()?"https:":"http:")}set protocol(e){this[Es]&&(this[Es].protocol=e)}};zr.Agent=jb});var fY=h(gn=>{"use strict";var spe=gn&&gn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var s=Object.getOwnPropertyDescriptor(e,r);(!s||("get"in s?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),ipe=gn&&gn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),hY=gn&&gn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&spe(e,t,r);return ipe(e,t),e},ope=gn&&gn.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(gn,"__esModule",{value:!0});gn.HttpProxyAgent=void 0;var ape=hY(require("net")),cpe=hY(require("tls")),lpe=ope(qf()),Ape=require("events"),upe=mY(),pY=require("url"),gl=(0,lpe.default)("http-proxy-agent"),Yf=class extends upe.Agent{constructor(e,r){super(r),this.proxy=typeof e=="string"?new pY.URL(e):e,this.proxyHeaders=r?.headers??{},gl("Creating new HttpProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),s=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={...r?dpe(r,"headers"):null,host:n,port:s}}addRequest(e,r){e._header=null,this.setRequestProps(e,r),super.addRequest(e,r)}setRequestProps(e,r){let{proxy:n}=this,s=r.secureEndpoint?"https:":"http:",i=e.getHeader("host")||"localhost",o=`${s}//${i}`,a=new pY.URL(e.path,o);r.port!==80&&(a.port=String(r.port)),e.path=String(a);let c=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders};if(n.username||n.password){let l=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;c["Proxy-Authorization"]=`Basic ${Buffer.from(l).toString("base64")}`}c["Proxy-Connection"]||(c["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let l of Object.keys(c)){let A=c[l];A&&e.setHeader(l,A)}}async connect(e,r){e._header=null,e.path.includes("://")||this.setRequestProps(e,r);let n,s;gl("Regenerating stored HTTP header string for request"),e._implicitHeader(),e.outputData&&e.outputData.length>0&&(gl("Patching connection write() output buffer with updated header"),n=e.outputData[0].data,s=n.indexOf(`\r
|
||||
\r
|
||||
`)+4,e.outputData[0].data=e._header+n.substring(s),Il("Output buffer: %o",e.outputData[0].data));let i;return this.proxy.protocol==="https:"?(Il("Creating `tls.Socket`: %o",this.connectOpts),i=_pe.connect(this.connectOpts)):(Il("Creating `net.Socket`: %o",this.connectOpts),i=Lpe.connect(this.connectOpts)),await(0,Upe.once)(i,"connect"),i}};ig.protocols=["http","https"];fn.HttpProxyAgent=ig;function qpe(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var sV=h(Eg=>{"use strict";Object.defineProperty(Eg,"__esModule",{value:!0});Eg.state=void 0;Eg.state={instrumenterImplementation:void 0}});var IV=h(xg=>{"use strict";Object.defineProperty(xg,"__esModule",{value:!0});xg.state=void 0;xg.state={operationRequestMap:new WeakMap}});var Z3=h(Ul=>{"use strict";Object.defineProperty(Ul,"__esModule",{value:!0});var aCe=require("os"),cCe=require("util");function lCe(t){return t&&typeof t=="object"&&"default"in t?t:{default:t}}var ACe=lCe(cCe);function uCe(t,...e){process.stderr.write(`${ACe.default.format(t,...e)}${aCe.EOL}`)}var z3=typeof process<"u"&&process.env&&process.env.DEBUG||void 0,Y3,OR=[],qR=[],zy=[];z3&&HR(z3);var V3=Object.assign(t=>J3(t),{enable:HR,enabled:zR,disable:dCe,log:uCe});function HR(t){Y3=t,OR=[],qR=[];let e=/\*/g,r=t.split(",").map(n=>n.trim().replace(e,".*?"));for(let n of r)n.startsWith("-")?qR.push(new RegExp(`^${n.substr(1)}$`)):OR.push(new RegExp(`^${n}$`));for(let n of zy)n.enabled=zR(n.namespace)}function zR(t){if(t.endsWith("*"))return!0;for(let e of qR)if(e.test(t))return!1;for(let e of OR)if(e.test(t))return!0;return!1}function dCe(){let t=Y3||"";return HR(""),t}function J3(t){let e=Object.assign(r,{enabled:zR(t),destroy:mCe,log:V3.log,namespace:t,extend:pCe});function r(...n){e.enabled&&(n.length>0&&(n[0]=`${t} ${n[0]}`),e.log(...n))}return zy.push(e),e}function mCe(){let t=zy.indexOf(this);return t>=0?(zy.splice(t,1),!0):!1}function pCe(t){let e=J3(`${this.namespace}:${t}`);return e.log=this.log,e}var Kd=V3,W3=new Set,qy=typeof process<"u"&&process.env&&process.env.AZURE_LOG_LEVEL||void 0,Gy,Yy=Kd("azure");Yy.log=(...t)=>{Kd.log(...t)};var GR=["verbose","info","warning","error"];qy&&(X3(qy)?$3(qy):console.error(`AZURE_LOG_LEVEL set to unknown log level '${qy}'; logging is not enabled. Acceptable values: ${GR.join(", ")}.`));function $3(t){if(t&&!X3(t))throw new Error(`Unknown log level '${t}'. Acceptable values: ${GR.join(",")}`);Gy=t;let e=[];for(let r of W3)K3(r)&&e.push(r.namespace);Kd.enable(e.join(","))}function hCe(){return Gy}var G3={verbose:400,info:300,warning:200,error:100};function fCe(t){let e=Yy.extend(t);return j3(Yy,e),{error:Hy(e,"error"),warning:Hy(e,"warning"),info:Hy(e,"info"),verbose:Hy(e,"verbose")}}function j3(t,e){e.log=(...r)=>{t.log(...r)}}function Hy(t,e){let r=Object.assign(t.extend(e),{level:e});if(j3(t,r),K3(r)){let n=Kd.disable();Kd.enable(n+","+r.namespace)}return W3.add(r),r}function K3(t){return!!(Gy&&G3[t.level]<=G3[Gy])}function X3(t){return GR.includes(t)}Ul.AzureLogger=Yy;Ul.createClientLogger=fCe;Ul.getLogLevel=hCe;Ul.setLogLevel=$3});var JR=h(Zd=>{"use strict";Object.defineProperty(Zd,"__esModule",{value:!0});var Ol=new WeakMap,Vy=new WeakMap,Xd=class t{constructor(){this.onabort=null,Ol.set(this,[]),Vy.set(this,!1)}get aborted(){if(!Vy.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");return Vy.get(this)}static get none(){return new t}addEventListener(e,r){if(!Ol.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");Ol.get(this).push(r)}removeEventListener(e,r){if(!Ol.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");let n=Ol.get(this),s=n.indexOf(r);s>-1&&n.splice(s,1)}dispatchEvent(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")}};function e4(t){if(t.aborted)return;t.onabort&&t.onabort.call(t);let e=Ol.get(t);e&&e.slice().forEach(r=>{r.call(t,{type:"abort"})}),Vy.set(t,!0)}var YR=class extends Error{constructor(e){super(e),this.name="AbortError"}},VR=class{constructor(e){if(this._signal=new Xd,!!e){Array.isArray(e)||(e=arguments);for(let r of e)r.aborted?this.abort():r.addEventListener("abort",()=>{this.abort()})}}get signal(){return this._signal}abort(){e4(this._signal)}static timeout(e){let r=new Xd,n=setTimeout(e4,e,r);return typeof n.unref=="function"&&n.unref(),r}};Zd.AbortController=VR;Zd.AbortError=YR;Zd.AbortSignal=Xd});var i4=h(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});var gCe=JR(),eP=require("crypto");function t4(t,e){let{cleanupBeforeAbort:r,abortSignal:n,abortErrorMsg:s}=e??{};return new Promise((i,o)=>{function a(){o(new gCe.AbortError(s??"The operation was aborted."))}function c(){n?.removeEventListener("abort",l)}function l(){r?.(),c(),a()}if(n?.aborted)return a();try{t(A=>{c(),i(A)},A=>{c(),o(A)})}catch(A){o(A)}n?.addEventListener("abort",l)})}var yCe="The delay was aborted.";function ECe(t,e){let r,{ab
Line truncated
|
||||
`)+4,e.outputData[0].data=e._header+n.substring(s),gl("Output buffer: %o",e.outputData[0].data));let i;return this.proxy.protocol==="https:"?(gl("Creating `tls.Socket`: %o",this.connectOpts),i=cpe.connect(this.connectOpts)):(gl("Creating `net.Socket`: %o",this.connectOpts),i=ape.connect(this.connectOpts)),await(0,Ape.once)(i,"connect"),i}};Yf.protocols=["http","https"];gn.HttpProxyAgent=Yf;function dpe(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var _Y=h(ig=>{"use strict";Object.defineProperty(ig,"__esModule",{value:!0});ig.state=void 0;ig.state={instrumenterImplementation:void 0}});var tV=h(Ag=>{"use strict";Object.defineProperty(Ag,"__esModule",{value:!0});Ag.state=void 0;Ag.state={operationRequestMap:new WeakMap}});var k3=h(Ml=>{"use strict";Object.defineProperty(Ml,"__esModule",{value:!0});var DEe=require("os"),kEe=require("util");function TEe(t){return t&&typeof t=="object"&&"default"in t?t:{default:t}}var MEe=TEe(kEe);function LEe(t,...e){process.stderr.write(`${MEe.default.format(t,...e)}${DEe.EOL}`)}var Q3=typeof process<"u"&&process.env&&process.env.DEBUG||void 0,b3,SR=[],RR=[],Ry=[];Q3&&PR(Q3);var w3=Object.assign(t=>N3(t),{enable:PR,enabled:vR,disable:FEe,log:LEe});function PR(t){b3=t,SR=[],RR=[];let e=/\*/g,r=t.split(",").map(n=>n.trim().replace(e,".*?"));for(let n of r)n.startsWith("-")?RR.push(new RegExp(`^${n.substr(1)}$`)):SR.push(new RegExp(`^${n}$`));for(let n of Ry)n.enabled=vR(n.namespace)}function vR(t){if(t.endsWith("*"))return!0;for(let e of RR)if(e.test(t))return!1;for(let e of SR)if(e.test(t))return!0;return!1}function FEe(){let t=b3||"";return PR(""),t}function N3(t){let e=Object.assign(r,{enabled:vR(t),destroy:_Ee,log:w3.log,namespace:t,extend:UEe});function r(...n){e.enabled&&(n.length>0&&(n[0]=`${t} ${n[0]}`),e.log(...n))}return Ry.push(e),e}function _Ee(){let t=Ry.indexOf(this);return t>=0?(Ry.splice(t,1),!0):!1}function UEe(t){let e=N3(`${this.namespace}:${t}`);return e.log=this.log,e}var zd=w3,S3=new Set,Ny=typeof process<"u"&&process.env&&process.env.AZURE_LOG_LEVEL||void 0,Py,vy=zd("azure");vy.log=(...t)=>{zd.log(...t)};var DR=["verbose","info","warning","error"];Ny&&(D3(Ny)?R3(Ny):console.error(`AZURE_LOG_LEVEL set to unknown log level '${Ny}'; logging is not enabled. Acceptable values: ${DR.join(", ")}.`));function R3(t){if(t&&!D3(t))throw new Error(`Unknown log level '${t}'. Acceptable values: ${DR.join(",")}`);Py=t;let e=[];for(let r of S3)v3(r)&&e.push(r.namespace);zd.enable(e.join(","))}function OEe(){return Py}var x3={verbose:400,info:300,warning:200,error:100};function qEe(t){let e=vy.extend(t);return P3(vy,e),{error:Sy(e,"error"),warning:Sy(e,"warning"),info:Sy(e,"info"),verbose:Sy(e,"verbose")}}function P3(t,e){e.log=(...r)=>{t.log(...r)}}function Sy(t,e){let r=Object.assign(t.extend(e),{level:e});if(P3(t,r),v3(r)){let n=zd.disable();zd.enable(n+","+r.namespace)}return S3.add(r),r}function v3(t){return!!(Py&&x3[t.level]<=x3[Py])}function D3(t){return DR.includes(t)}Ml.AzureLogger=vy;Ml.createClientLogger=qEe;Ml.getLogLevel=OEe;Ml.setLogLevel=R3});var MR=h(Yd=>{"use strict";Object.defineProperty(Yd,"__esModule",{value:!0});var Ll=new WeakMap,Dy=new WeakMap,Gd=class t{constructor(){this.onabort=null,Ll.set(this,[]),Dy.set(this,!1)}get aborted(){if(!Dy.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");return Dy.get(this)}static get none(){return new t}addEventListener(e,r){if(!Ll.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");Ll.get(this).push(r)}removeEventListener(e,r){if(!Ll.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");let n=Ll.get(this),s=n.indexOf(r);s>-1&&n.splice(s,1)}dispatchEvent(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")}};function T3(t){if(t.aborted)return;t.onabort&&t.onabort.call(t);let e=Ll.get(t);e&&e.slice().forEach(r=>{r.call(t,{type:"abort"})}),Dy.set(t,!0)}var kR=class extends Error{constructor(e){super(e),this.name="AbortError"}},TR=class{constructor(e){if(this._signal=new Gd,!!e){Array.isArray(e)||(e=arguments);for(let r of e)r.aborted?this.abort():r.addEventListener("abort",()=>{this.abort()})}}get signal(){return this._signal}abort(){T3(this._signal)}static timeout(e){let r=new Gd,n=setTimeout(T3,e,r);return typeof n.unref=="function"&&n.unref(),r}};Yd.AbortController=TR;Yd.AbortError=kR;Yd.AbortSignal=Gd});var U3=h(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});var HEe=MR(),HR=require("crypto");function M3(t,e){let{cleanupBeforeAbort:r,abortSignal:n,abortErrorMsg:s}=e??{};return new Promise((i,o)=>{function a(){o(new HEe.AbortError(s??"The operation was aborted."))}function c(){n?.removeEventListener("abort",l)}function l(){r?.(),c(),a()}if(n?.aborted)return a();try{t(A=>{c(),i(A)},A=>{c(),o(A)})}catch(A){o(A)}n?.addEventListener("abort",l)})}var zEe="The delay was aborted.";function GEe(t,e){let r,{ab
Line truncated
|
||||
Polling from: ${r.config.operationLocation}
|
||||
Operation status: ${A}
|
||||
Polling status: ${l4.includes(A)?"Stopped":"Running"}`),A==="succeeded"){let u=o(l,r);if(u!==void 0)return{response:await e(u).catch(a4({state:r,stateProxy:n,isOperationError:a})),status:A}}return{response:l,status:A}}async function m4(t){let{poll:e,state:r,stateProxy:n,options:s,getOperationStatus:i,getResourceLocation:o,getOperationLocation:a,isOperationError:c,withOperationLocation:l,getPollingInterval:A,processResult:u,getError:d,updateState:m,setDelay:p,isDone:f,setErrorAsResult:E}=t,{operationLocation:g}=r.config;if(g!==void 0){let{response:y,status:C}=await VCe({poll:e,getOperationStatus:i,state:r,stateProxy:n,operationLocation:g,getResourceLocation:o,isOperationError:c,options:s});if(u4({status:C,response:y,state:r,stateProxy:n,isDone:f,processResult:u,getError:d,setErrorAsResult:E}),!l4.includes(C)){let I=A?.(y);I&&p(I);let w=a?.(y,r);if(w!==void 0){let D=g!==w;r.config.operationLocation=w,l?.(w,D)}else l?.(g,!1)}m?.(r,y)}}function p4(t){let{azureAsyncOperation:e,operationLocation:r}=t;return r??e}function h4(t){return t.headers.location}function f4(t){return t.headers["operation-location"]}function g4(t){return t.headers["azure-asyncoperation"]}function JCe(t){var e;let{location:r,requestMethod:n,requestPath:s,resourceLocationConfig:i}=t;switch(n){case"PUT":return s;case"DELETE":return;case"PATCH":return(e=o())!==null&&e!==void 0?e:s;default:return o()}function o(){switch(i){case"azure-async-operation":return;case"original-uri":return s;default:return r}}}function y4(t){let{rawResponse:e,requestMethod:r,requestPath:n,resourceLocationConfig:s}=t,i=f4(e),o=g4(e),a=p4({operationLocation:i,azureAsyncOperation:o}),c=h4(e),l=r?.toLocaleUpperCase();return a!==void 0?{mode:"OperationLocation",operationLocation:a,resourceLocation:JCe({requestMethod:l,location:c,requestPath:n,resourceLocationConfig:s})}:c!==void 0?{mode:"ResourceLocation",operationLocation:c}:l==="PUT"&&n?{mode:"Body",operationLocation:n}:void 0}function E4(t){let{status:e,statusCode:r}=t;if(typeof e!="string"&&e!==void 0)throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${e}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`);switch(e?.toLocaleLowerCase()){case void 0:return sP(r);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:return qa.verbose(`LRO: unrecognized operation status: ${e}`),e}}function WCe(t){var e;let{status:r}=(e=t.body)!==null&&e!==void 0?e:{};return E4({status:r,statusCode:t.statusCode})}function $Ce(t){var e,r;let{properties:n,provisioningState:s}=(e=t.body)!==null&&e!==void 0?e:{},i=(r=n?.provisioningState)!==null&&r!==void 0?r:s;return E4({status:i,statusCode:t.statusCode})}function sP(t){return t===202?"running":t<300?"succeeded":"failed"}function C4({rawResponse:t}){let e=t.headers["retry-after"];if(e!==void 0){let r=parseInt(e);return isNaN(r)?jCe(new Date(e)):r*1e3}}function I4(t){let e=t.flatResponse.error;if(!e){qa.warning("The long-running operation failed but there is no error property in the response's body");return}if(!e.code||!e.message){qa.warning("The long-running operation failed but the error property in the response's body doesn't contain code or message");return}return e}function jCe(t){let e=Math.floor(new Date().getTime()),r=t.getTime();if(e<r)return r-e}function B4(t){let{response:e,state:r,operationLocation:n}=t;function s(){var o;switch((o=r.config.metadata)===null||o===void 0?void 0:o.mode){case void 0:return sP(e.rawResponse.statusCode);case"Body":return iP(e,r);default:return"running"}}let i=s();return i==="running"&&n===void 0?"succeeded":i}async function KCe(t){let{stateProxy:e,resourceLocationConfig:r,processResult:n,lro:s,setErrorAsResult:i}=t;return d4({init:async()=>{let o=await s.sendInitialRequest(),a=y4({rawResponse:o.rawResponse,requestPath:s.requestPath,requestMethod:s.requestMethod,resourceLocationConfig:r});return Object.assign({response:o,operationLocation:a?.operationLocation,resourceLocation:a?.resourceLocation},a?.mode?{metadata:{mode:a.mode}}:{})},stateProxy:e,processResult:n?({flatResponse:o},a)=>n(o,a):({flatResponse:o})=>o,getOperationStatus:B4,setErrorAsResult:i})}function Q4({rawResponse:t},e){var r;switch((r=e.config.metadata)===null||r===void 0?void 0:r.mode){case"OperationLocation":return p4({operationLocation:f4(t),azureAsyncOperation:g4(t)});case"ResourceLocation":return h4(t);default:return}}function iP({rawResponse:t},e){var r;let n=(r=e.config.metadata)===null||r===void 0?void 0:r.mode;switch(n){case"OperationLocation":return WCe(t);case"ResourceLocation":return sP(t.statusCode);case"Body":return $Ce(t);default:throw new Error(`Internal error: Unexpected operation mode: ${n}`)}}function x4({flatResponse:t},e){if(typeof t=="object"){let r=t.resourceLocation;r!Line truncated
|
||||
`:case"\r":case" ":case" ":continue;default:throw Error("invalid base64 string.")}switch(s){case 0:o=i,s=1;break;case 1:r[n++]=o<<2|(i&48)>>4,o=i,s=2;break;case 2:r[n++]=(o&15)<<4|(i&60)>>2,o=i,s=3;break;case 3:r[n++]=(o&3)<<6|i,s=0;break}}if(s==1)throw Error("invalid base64 string.");return r.subarray(0,n)}Vl.base64decode=TIe;function MIe(t){let e="",r=0,n,s=0;for(let i=0;i<t.length;i++)switch(n=t[i],r){case 0:e+=ki[n>>2],s=(n&3)<<4,r=1;break;case 1:e+=ki[s|n>>4],s=(n&15)<<2,r=2;break;case 2:e+=ki[s|n>>6],e+=ki[n&63],r=0;break}return r&&(e+=ki[s],e+="=",r==1&&(e+="=")),e}Vl.base64encode=MIe});var Z4=h(uE=>{"use strict";Object.defineProperty(uE,"__esModule",{value:!0});uE.utf8read=void 0;var hP=t=>String.fromCharCode.apply(String,t);function LIe(t){if(t.length<1)return"";let e=0,r=[],n=[],s=0,i,o=t.length;for(;e<o;)i=t[e++],i<128?n[s++]=i:i>191&&i<224?n[s++]=(i&31)<<6|t[e++]&63:i>239&&i<365?(i=((i&7)<<18|(t[e++]&63)<<12|(t[e++]&63)<<6|t[e++]&63)-65536,n[s++]=55296+(i>>10),n[s++]=56320+(i&1023)):n[s++]=(i&15)<<12|(t[e++]&63)<<6|t[e++]&63,s>8191&&(r.push(hP(n)),s=0);return r.length?(s&&r.push(hP(n.slice(0,s))),r.join("")):hP(n.slice(0,s))}uE.utf8read=LIe});var am=h(Vs=>{"use strict";Object.defineProperty(Vs,"__esModule",{value:!0});Vs.WireType=Vs.mergeBinaryOptions=Vs.UnknownFieldHandler=void 0;var _Ie;(function(t){t.symbol=Symbol.for("protobuf-ts/unknown"),t.onRead=(r,n,s,i,o)=>{(e(n)?n[t.symbol]:n[t.symbol]=[]).push({no:s,wireType:i,data:o})},t.onWrite=(r,n,s)=>{for(let{no:i,wireType:o,data:a}of t.list(n))s.tag(i,o).raw(a)},t.list=(r,n)=>{if(e(r)){let s=r[t.symbol];return n?s.filter(i=>i.no==n):s}return[]},t.last=(r,n)=>t.list(r,n).slice(-1)[0];let e=r=>r&&Array.isArray(r[t.symbol])})(_Ie=Vs.UnknownFieldHandler||(Vs.UnknownFieldHandler={}));function FIe(t,e){return Object.assign(Object.assign({},t),e)}Vs.mergeBinaryOptions=FIe;var UIe;(function(t){t[t.Varint=0]="Varint",t[t.Bit64=1]="Bit64",t[t.LengthDelimited=2]="LengthDelimited",t[t.StartGroup=3]="StartGroup",t[t.EndGroup=4]="EndGroup",t[t.Bit32=5]="Bit32"})(UIe=Vs.WireType||(Vs.WireType={}))});var mE=h(Br=>{"use strict";Object.defineProperty(Br,"__esModule",{value:!0});Br.varint32read=Br.varint32write=Br.int64toString=Br.int64fromString=Br.varint64write=Br.varint64read=void 0;function OIe(){let t=0,e=0;for(let n=0;n<28;n+=7){let s=this.buf[this.pos++];if(t|=(s&127)<<n,(s&128)==0)return this.assertBounds(),[t,e]}let r=this.buf[this.pos++];if(t|=(r&15)<<28,e=(r&112)>>4,(r&128)==0)return this.assertBounds(),[t,e];for(let n=3;n<=31;n+=7){let s=this.buf[this.pos++];if(e|=(s&127)<<n,(s&128)==0)return this.assertBounds(),[t,e]}throw new Error("invalid varint")}Br.varint64read=OIe;function qIe(t,e,r){for(let i=0;i<28;i=i+7){let o=t>>>i,a=!(!(o>>>7)&&e==0),c=(a?o|128:o)&255;if(r.push(c),!a)return}let n=t>>>28&15|(e&7)<<4,s=e>>3!=0;if(r.push((s?n|128:n)&255),!!s){for(let i=3;i<31;i=i+7){let o=e>>>i,a=!!(o>>>7),c=(a?o|128:o)&255;if(r.push(c),!a)return}r.push(e>>>31&1)}}Br.varint64write=qIe;var dE=65536*65536;function HIe(t){let e=t[0]=="-";e&&(t=t.slice(1));let r=1e6,n=0,s=0;function i(o,a){let c=Number(t.slice(o,a));s*=r,n=n*r+c,n>=dE&&(s=s+(n/dE|0),n=n%dE)}return i(-24,-18),i(-18,-12),i(-12,-6),i(-6),[e,n,s]}Br.int64fromString=HIe;function zIe(t,e){if(e>>>0<=2097151)return""+(dE*e+(t>>>0));let r=t&16777215,n=(t>>>24|e<<8)>>>0&16777215,s=e>>16&65535,i=r+n*6777216+s*6710656,o=n+s*8147497,a=s*2,c=1e7;i>=c&&(o+=Math.floor(i/c),i%=c),o>=c&&(a+=Math.floor(o/c),o%=c);function l(A,u){let d=A?String(A):"";return u?"0000000".slice(d.length)+d:d}return l(a,0)+l(o,a)+l(i,1)}Br.int64toString=zIe;function GIe(t,e){if(t>=0){for(;t>127;)e.push(t&127|128),t=t>>>7;e.push(t)}else{for(let r=0;r<9;r++)e.push(t&127|128),t=t>>7;e.push(1)}}Br.varint32write=GIe;function YIe(){let t=this.buf[this.pos++],e=t&127;if((t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<7,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<14,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<21,(t&128)==0)return this.assertBounds(),e;t=this.buf[this.pos++],e|=(t&15)<<28;for(let r=5;(t&128)!==0&&r<10;r++)t=this.buf[this.pos++];if((t&128)!=0)throw new Error("invalid varint");return this.assertBounds(),e>>>0}Br.varint32read=YIe});var Do=h(vo=>{"use strict";Object.defineProperty(vo,"__esModule",{value:!0});vo.PbLong=vo.PbULong=vo.detectBi=void 0;var cm=mE(),Ne;function eW(){let t=new DataView(new ArrayBuffer(8));Ne=globalThis.BigInt!==void 0&&typeof t.getBigInt64=="function"&&typeof t.getBigUint64=="function"&&typeof t.setBigInt64=="function"&&typeof t.setBigUint64=="function"?{MIN:BigInt("-9223372036854775808"),MAX:BigInt("9223372036854775807"),UMIN:BigInt("0"),UMAX:BigInt("18446744073709551615"),C:BigInt,V:t}:void 0}vo.detectBi=eW;eW();function tW(t){if(!t)throw new Error("BigInt unavailable, see https://github.com/timostamm/protobuf-ts/blob/v1.0.8/MANUAL.md#bigint-support")}var rW=/^-?[0-9]+$/,hE=4294967296,pE=2147483648,fE=class{c
Line truncated
|
||||
`)}};OE.RpcError=HP});var GP=h(HE=>{"use strict";Object.defineProperty(HE,"__esModule",{value:!0});HE.mergeRpcOptions=void 0;var DW=ct();function mQe(t,e){if(!e)return t;let r={};qE(t,r),qE(e,r);for(let n of Object.keys(e)){let s=e[n];switch(n){case"jsonOptions":r.jsonOptions=DW.mergeJsonOptions(t.jsonOptions,r.jsonOptions);break;case"binaryOptions":r.binaryOptions=DW.mergeBinaryOptions(t.binaryOptions,r.binaryOptions);break;case"meta":r.meta={},qE(t.meta,r.meta),qE(e.meta,r.meta);break;case"interceptors":r.interceptors=t.interceptors?t.interceptors.concat(s):s.concat();break}}return r}HE.mergeRpcOptions=mQe;function qE(t,e){if(!t)return;let r=e;for(let[n,s]of Object.entries(t))s instanceof Date?r[n]=new Date(s.getTime()):Array.isArray(s)?r[n]=s.concat():r[n]=s}});var VP=h(Va=>{"use strict";Object.defineProperty(Va,"__esModule",{value:!0});Va.Deferred=Va.DeferredState=void 0;var $s;(function(t){t[t.PENDING=0]="PENDING",t[t.REJECTED=1]="REJECTED",t[t.RESOLVED=2]="RESOLVED"})($s=Va.DeferredState||(Va.DeferredState={}));var YP=class{constructor(e=!0){this._state=$s.PENDING,this._promise=new Promise((r,n)=>{this._resolve=r,this._reject=n}),e&&this._promise.catch(r=>{})}get state(){return this._state}get promise(){return this._promise}resolve(e){if(this.state!==$s.PENDING)throw new Error(`cannot resolve ${$s[this.state].toLowerCase()}`);this._resolve(e),this._state=$s.RESOLVED}reject(e){if(this.state!==$s.PENDING)throw new Error(`cannot reject ${$s[this.state].toLowerCase()}`);this._reject(e),this._state=$s.REJECTED}resolvePending(e){this._state===$s.PENDING&&this.resolve(e)}rejectPending(e){this._state===$s.PENDING&&this.reject(e)}};Va.Deferred=YP});var WP=h(zE=>{"use strict";Object.defineProperty(zE,"__esModule",{value:!0});zE.RpcOutputStreamController=void 0;var kW=VP(),Ja=ct(),JP=class{constructor(){this._lis={nxt:[],msg:[],err:[],cmp:[]},this._closed=!1,this._itState={q:[]}}onNext(e){return this.addLis(e,this._lis.nxt)}onMessage(e){return this.addLis(e,this._lis.msg)}onError(e){return this.addLis(e,this._lis.err)}onComplete(e){return this.addLis(e,this._lis.cmp)}addLis(e,r){return r.push(e),()=>{let n=r.indexOf(e);n>=0&&r.splice(n,1)}}clearLis(){for(let e of Object.values(this._lis))e.splice(0,e.length)}get closed(){return this._closed!==!1}notifyNext(e,r,n){Ja.assert((e?1:0)+(r?1:0)+(n?1:0)<=1,"only one emission at a time"),e&&this.notifyMessage(e),r&&this.notifyError(r),n&&this.notifyComplete()}notifyMessage(e){Ja.assert(!this.closed,"stream is closed"),this.pushIt({value:e,done:!1}),this._lis.msg.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(e,void 0,!1))}notifyError(e){Ja.assert(!this.closed,"stream is closed"),this._closed=e,this.pushIt(e),this._lis.err.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(void 0,e,!1)),this.clearLis()}notifyComplete(){Ja.assert(!this.closed,"stream is closed"),this._closed=!0,this.pushIt({value:null,done:!0}),this._lis.cmp.forEach(e=>e()),this._lis.nxt.forEach(e=>e(void 0,void 0,!0)),this.clearLis()}[Symbol.asyncIterator](){return this._closed===!0?this.pushIt({value:null,done:!0}):this._closed!==!1&&this.pushIt(this._closed),{next:()=>{let e=this._itState;Ja.assert(e,"bad state"),Ja.assert(!e.p,"iterator contract broken");let r=e.q.shift();return r?"value"in r?Promise.resolve(r):Promise.reject(r):(e.p=new kW.Deferred,e.p.promise)}}}pushIt(e){let r=this._itState;if(r.p){let n=r.p;Ja.assert(n.state==kW.DeferredState.PENDING,"iterator contract broken"),"value"in e?n.resolve(e):n.reject(e),delete r.p}else r.q.push(e)}};zE.RpcOutputStreamController=JP});var jP=h(Zl=>{"use strict";var pQe=Zl&&Zl.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};Object.defineProperty(Zl,"__esModule",{value:!0});Zl.UnaryCall=void 0;var $P=class{constructor(e,r,n,s,i,o,a){this.method=e,this.requestHeaders=r,this.request=n,this.headers=s,this.response=i,this.status=o,this.trailers=a}then(e,r){return this.promiseFinished().then(n=>e?Promise.resolve(e(n)):n,n=>r?Promise.resolve(r(n)):Promise.reject(n))}promiseFinished(){return pQe(this,void 0,void 0,function*(){let[e,r,n,s]=yield Promise.all([this.headers,this.response,this.status,this.trailers]);return{method:this.method,requestHeaders:this.requestHeaders,request:this.request,headers:e,response:r,status:n,trailers:s}})}};Zl.UnaryCall=$P});var XP=h(eA=>{"use strict";var hQe=eA&&eA.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};Object.defineProperty(eA,"__esModule",{value:!0});eA.ServerStreamingCall=void 0;var KP=class{constructor(e,r,n,s
Line truncated
|
||||
Polling status: ${z3.includes(A)?"Stopped":"Running"}`),A==="succeeded"){let u=o(l,r);if(u!==void 0)return{response:await e(u).catch(q3({state:r,stateProxy:n,isOperationError:a})),status:A}}return{response:l,status:A}}async function J3(t){let{poll:e,state:r,stateProxy:n,options:s,getOperationStatus:i,getResourceLocation:o,getOperationLocation:a,isOperationError:c,withOperationLocation:l,getPollingInterval:A,processResult:u,getError:d,updateState:m,setDelay:p,isDone:f,setErrorAsResult:E}=t,{operationLocation:g}=r.config;if(g!==void 0){let{response:y,status:C}=await gCe({poll:e,getOperationStatus:i,state:r,stateProxy:n,operationLocation:g,getResourceLocation:o,isOperationError:c,options:s});if(Y3({status:C,response:y,state:r,stateProxy:n,isDone:f,processResult:u,getError:d,setErrorAsResult:E}),!z3.includes(C)){let I=A?.(y);I&&p(I);let w=a?.(y,r);if(w!==void 0){let D=g!==w;r.config.operationLocation=w,l?.(w,D)}else l?.(g,!1)}m?.(r,y)}}function W3(t){let{azureAsyncOperation:e,operationLocation:r}=t;return r??e}function $3(t){return t.headers.location}function j3(t){return t.headers["operation-location"]}function K3(t){return t.headers["azure-asyncoperation"]}function yCe(t){var e;let{location:r,requestMethod:n,requestPath:s,resourceLocationConfig:i}=t;switch(n){case"PUT":return s;case"DELETE":return;case"PATCH":return(e=o())!==null&&e!==void 0?e:s;default:return o()}function o(){switch(i){case"azure-async-operation":return;case"original-uri":return s;default:return r}}}function X3(t){let{rawResponse:e,requestMethod:r,requestPath:n,resourceLocationConfig:s}=t,i=j3(e),o=K3(e),a=W3({operationLocation:i,azureAsyncOperation:o}),c=$3(e),l=r?.toLocaleUpperCase();return a!==void 0?{mode:"OperationLocation",operationLocation:a,resourceLocation:yCe({requestMethod:l,location:c,requestPath:n,resourceLocationConfig:s})}:c!==void 0?{mode:"ResourceLocation",operationLocation:c}:l==="PUT"&&n?{mode:"Body",operationLocation:n}:void 0}function Z3(t){let{status:e,statusCode:r}=t;if(typeof e!="string"&&e!==void 0)throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${e}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`);switch(e?.toLocaleLowerCase()){case void 0:return VR(r);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:return La.verbose(`LRO: unrecognized operation status: ${e}`),e}}function ECe(t){var e;let{status:r}=(e=t.body)!==null&&e!==void 0?e:{};return Z3({status:r,statusCode:t.statusCode})}function CCe(t){var e,r;let{properties:n,provisioningState:s}=(e=t.body)!==null&&e!==void 0?e:{},i=(r=n?.provisioningState)!==null&&r!==void 0?r:s;return Z3({status:i,statusCode:t.statusCode})}function VR(t){return t===202?"running":t<300?"succeeded":"failed"}function e4({rawResponse:t}){let e=t.headers["retry-after"];if(e!==void 0){let r=parseInt(e);return isNaN(r)?ICe(new Date(e)):r*1e3}}function t4(t){let e=t.flatResponse.error;if(!e){La.warning("The long-running operation failed but there is no error property in the response's body");return}if(!e.code||!e.message){La.warning("The long-running operation failed but the error property in the response's body doesn't contain code or message");return}return e}function ICe(t){let e=Math.floor(new Date().getTime()),r=t.getTime();if(e<r)return r-e}function r4(t){let{response:e,state:r,operationLocation:n}=t;function s(){var o;switch((o=r.config.metadata)===null||o===void 0?void 0:o.mode){case void 0:return VR(e.rawResponse.statusCode);case"Body":return JR(e,r);default:return"running"}}let i=s();return i==="running"&&n===void 0?"succeeded":i}async function BCe(t){let{stateProxy:e,resourceLocationConfig:r,processResult:n,lro:s,setErrorAsResult:i}=t;return V3({init:async()=>{let o=await s.sendInitialRequest(),a=X3({rawResponse:o.rawResponse,requestPath:s.requestPath,requestMethod:s.requestMethod,resourceLocationConfig:r});return Object.assign({response:o,operationLocation:a?.operationLocation,resourceLocation:a?.resourceLocation},a?.mode?{metadata:{mode:a.mode}}:{})},stateProxy:e,processResult:n?({flatResponse:o},a)=>n(o,a):({flatResponse:o})=>o,getOperationStatus:r4,setErrorAsResult:i})}function n4({rawResponse:t},e){var r;switch((r=e.config.metadata)===null||r===void 0?void 0:r.mode){case"OperationLocation":return W3({operationLocation:j3(t),azureAsyncOperation:K3(t)});case"ResourceLocation":return $3(t);default:return}}function JR({rawResponse:t},e){var r;let n=(r=e.config.metadata)===null||r===void 0?void 0:r.mode;switch(n){case"OperationLocation":return ECe(t);case"ResourceLocation":return VR(t.statusCode);case"Body":return CCe(t);default:throw new Error(`Internal error: Unexpected operation mode: ${n}`)}}function s4({flatResponse:t},e){if(typeof t=="object"){let r=t.resourceLocation;r!Line truncated
|
||||
`:case"\r":case" ":case" ":continue;default:throw Error("invalid base64 string.")}switch(s){case 0:o=i,s=1;break;case 1:r[n++]=o<<2|(i&48)>>4,o=i,s=2;break;case 2:r[n++]=(o&15)<<4|(i&60)>>2,o=i,s=3;break;case 3:r[n++]=(o&3)<<6|i,s=0;break}}if(s==1)throw Error("invalid base64 string.");return r.subarray(0,n)}Hl.base64decode=iIe;function oIe(t){let e="",r=0,n,s=0;for(let i=0;i<t.length;i++)switch(n=t[i],r){case 0:e+=ki[n>>2],s=(n&3)<<4,r=1;break;case 1:e+=ki[s|n>>4],s=(n&15)<<2,r=2;break;case 2:e+=ki[s|n>>6],e+=ki[n&63],r=0;break}return r&&(e+=ki[s],e+="=",r==1&&(e+="=")),e}Hl.base64encode=oIe});var k4=h(Ky=>{"use strict";Object.defineProperty(Ky,"__esModule",{value:!0});Ky.utf8read=void 0;var nP=t=>String.fromCharCode.apply(String,t);function aIe(t){if(t.length<1)return"";let e=0,r=[],n=[],s=0,i,o=t.length;for(;e<o;)i=t[e++],i<128?n[s++]=i:i>191&&i<224?n[s++]=(i&31)<<6|t[e++]&63:i>239&&i<365?(i=((i&7)<<18|(t[e++]&63)<<12|(t[e++]&63)<<6|t[e++]&63)-65536,n[s++]=55296+(i>>10),n[s++]=56320+(i&1023)):n[s++]=(i&15)<<12|(t[e++]&63)<<6|t[e++]&63,s>8191&&(r.push(nP(n)),s=0);return r.length?(s&&r.push(nP(n.slice(0,s))),r.join("")):nP(n.slice(0,s))}Ky.utf8read=aIe});var Zd=h(Ys=>{"use strict";Object.defineProperty(Ys,"__esModule",{value:!0});Ys.WireType=Ys.mergeBinaryOptions=Ys.UnknownFieldHandler=void 0;var cIe;(function(t){t.symbol=Symbol.for("protobuf-ts/unknown"),t.onRead=(r,n,s,i,o)=>{(e(n)?n[t.symbol]:n[t.symbol]=[]).push({no:s,wireType:i,data:o})},t.onWrite=(r,n,s)=>{for(let{no:i,wireType:o,data:a}of t.list(n))s.tag(i,o).raw(a)},t.list=(r,n)=>{if(e(r)){let s=r[t.symbol];return n?s.filter(i=>i.no==n):s}return[]},t.last=(r,n)=>t.list(r,n).slice(-1)[0];let e=r=>r&&Array.isArray(r[t.symbol])})(cIe=Ys.UnknownFieldHandler||(Ys.UnknownFieldHandler={}));function lIe(t,e){return Object.assign(Object.assign({},t),e)}Ys.mergeBinaryOptions=lIe;var AIe;(function(t){t[t.Varint=0]="Varint",t[t.Bit64=1]="Bit64",t[t.LengthDelimited=2]="LengthDelimited",t[t.StartGroup=3]="StartGroup",t[t.EndGroup=4]="EndGroup",t[t.Bit32=5]="Bit32"})(AIe=Ys.WireType||(Ys.WireType={}))});var Zy=h(xr=>{"use strict";Object.defineProperty(xr,"__esModule",{value:!0});xr.varint32read=xr.varint32write=xr.int64toString=xr.int64fromString=xr.varint64write=xr.varint64read=void 0;function uIe(){let t=0,e=0;for(let n=0;n<28;n+=7){let s=this.buf[this.pos++];if(t|=(s&127)<<n,(s&128)==0)return this.assertBounds(),[t,e]}let r=this.buf[this.pos++];if(t|=(r&15)<<28,e=(r&112)>>4,(r&128)==0)return this.assertBounds(),[t,e];for(let n=3;n<=31;n+=7){let s=this.buf[this.pos++];if(e|=(s&127)<<n,(s&128)==0)return this.assertBounds(),[t,e]}throw new Error("invalid varint")}xr.varint64read=uIe;function dIe(t,e,r){for(let i=0;i<28;i=i+7){let o=t>>>i,a=!(!(o>>>7)&&e==0),c=(a?o|128:o)&255;if(r.push(c),!a)return}let n=t>>>28&15|(e&7)<<4,s=e>>3!=0;if(r.push((s?n|128:n)&255),!!s){for(let i=3;i<31;i=i+7){let o=e>>>i,a=!!(o>>>7),c=(a?o|128:o)&255;if(r.push(c),!a)return}r.push(e>>>31&1)}}xr.varint64write=dIe;var Xy=65536*65536;function mIe(t){let e=t[0]=="-";e&&(t=t.slice(1));let r=1e6,n=0,s=0;function i(o,a){let c=Number(t.slice(o,a));s*=r,n=n*r+c,n>=Xy&&(s=s+(n/Xy|0),n=n%Xy)}return i(-24,-18),i(-18,-12),i(-12,-6),i(-6),[e,n,s]}xr.int64fromString=mIe;function pIe(t,e){if(e>>>0<=2097151)return""+(Xy*e+(t>>>0));let r=t&16777215,n=(t>>>24|e<<8)>>>0&16777215,s=e>>16&65535,i=r+n*6777216+s*6710656,o=n+s*8147497,a=s*2,c=1e7;i>=c&&(o+=Math.floor(i/c),i%=c),o>=c&&(a+=Math.floor(o/c),o%=c);function l(A,u){let d=A?String(A):"";return u?"0000000".slice(d.length)+d:d}return l(a,0)+l(o,a)+l(i,1)}xr.int64toString=pIe;function hIe(t,e){if(t>=0){for(;t>127;)e.push(t&127|128),t=t>>>7;e.push(t)}else{for(let r=0;r<9;r++)e.push(t&127|128),t=t>>7;e.push(1)}}xr.varint32write=hIe;function fIe(){let t=this.buf[this.pos++],e=t&127;if((t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<7,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<14,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<21,(t&128)==0)return this.assertBounds(),e;t=this.buf[this.pos++],e|=(t&15)<<28;for(let r=5;(t&128)!==0&&r<10;r++)t=this.buf[this.pos++];if((t&128)!=0)throw new Error("invalid varint");return this.assertBounds(),e>>>0}xr.varint32read=fIe});var Ro=h(So=>{"use strict";Object.defineProperty(So,"__esModule",{value:!0});So.PbLong=So.PbULong=So.detectBi=void 0;var em=Zy(),Se;function T4(){let t=new DataView(new ArrayBuffer(8));Se=globalThis.BigInt!==void 0&&typeof t.getBigInt64=="function"&&typeof t.getBigUint64=="function"&&typeof t.setBigInt64=="function"&&typeof t.setBigUint64=="function"?{MIN:BigInt("-9223372036854775808"),MAX:BigInt("9223372036854775807"),UMIN:BigInt("0"),UMAX:BigInt("18446744073709551615"),C:BigInt,V:t}:void 0}So.detectBi=T4;T4();function M4(t){if(!t)throw new Error("BigInt unavailable, see https://github.com/timostamm/protobuf-ts/blob/v1.0.8/MANUAL.md#bigint-support")}var L4=/^-?[0-9]+$/,tE=4294967296,eE=2147483648,rE=class{c
Line truncated
|
||||
`)}};wE.RpcError=PP});var DP=h(SE=>{"use strict";Object.defineProperty(SE,"__esModule",{value:!0});SE.mergeRpcOptions=void 0;var d8=ct();function _Be(t,e){if(!e)return t;let r={};NE(t,r),NE(e,r);for(let n of Object.keys(e)){let s=e[n];switch(n){case"jsonOptions":r.jsonOptions=d8.mergeJsonOptions(t.jsonOptions,r.jsonOptions);break;case"binaryOptions":r.binaryOptions=d8.mergeBinaryOptions(t.binaryOptions,r.binaryOptions);break;case"meta":r.meta={},NE(t.meta,r.meta),NE(e.meta,r.meta);break;case"interceptors":r.interceptors=t.interceptors?t.interceptors.concat(s):s.concat();break}}return r}SE.mergeRpcOptions=_Be;function NE(t,e){if(!t)return;let r=e;for(let[n,s]of Object.entries(t))s instanceof Date?r[n]=new Date(s.getTime()):Array.isArray(s)?r[n]=s.concat():r[n]=s}});var TP=h(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});qa.Deferred=qa.DeferredState=void 0;var Ws;(function(t){t[t.PENDING=0]="PENDING",t[t.REJECTED=1]="REJECTED",t[t.RESOLVED=2]="RESOLVED"})(Ws=qa.DeferredState||(qa.DeferredState={}));var kP=class{constructor(e=!0){this._state=Ws.PENDING,this._promise=new Promise((r,n)=>{this._resolve=r,this._reject=n}),e&&this._promise.catch(r=>{})}get state(){return this._state}get promise(){return this._promise}resolve(e){if(this.state!==Ws.PENDING)throw new Error(`cannot resolve ${Ws[this.state].toLowerCase()}`);this._resolve(e),this._state=Ws.RESOLVED}reject(e){if(this.state!==Ws.PENDING)throw new Error(`cannot reject ${Ws[this.state].toLowerCase()}`);this._reject(e),this._state=Ws.REJECTED}resolvePending(e){this._state===Ws.PENDING&&this.resolve(e)}rejectPending(e){this._state===Ws.PENDING&&this.reject(e)}};qa.Deferred=kP});var LP=h(RE=>{"use strict";Object.defineProperty(RE,"__esModule",{value:!0});RE.RpcOutputStreamController=void 0;var m8=TP(),Ha=ct(),MP=class{constructor(){this._lis={nxt:[],msg:[],err:[],cmp:[]},this._closed=!1,this._itState={q:[]}}onNext(e){return this.addLis(e,this._lis.nxt)}onMessage(e){return this.addLis(e,this._lis.msg)}onError(e){return this.addLis(e,this._lis.err)}onComplete(e){return this.addLis(e,this._lis.cmp)}addLis(e,r){return r.push(e),()=>{let n=r.indexOf(e);n>=0&&r.splice(n,1)}}clearLis(){for(let e of Object.values(this._lis))e.splice(0,e.length)}get closed(){return this._closed!==!1}notifyNext(e,r,n){Ha.assert((e?1:0)+(r?1:0)+(n?1:0)<=1,"only one emission at a time"),e&&this.notifyMessage(e),r&&this.notifyError(r),n&&this.notifyComplete()}notifyMessage(e){Ha.assert(!this.closed,"stream is closed"),this.pushIt({value:e,done:!1}),this._lis.msg.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(e,void 0,!1))}notifyError(e){Ha.assert(!this.closed,"stream is closed"),this._closed=e,this.pushIt(e),this._lis.err.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(void 0,e,!1)),this.clearLis()}notifyComplete(){Ha.assert(!this.closed,"stream is closed"),this._closed=!0,this.pushIt({value:null,done:!0}),this._lis.cmp.forEach(e=>e()),this._lis.nxt.forEach(e=>e(void 0,void 0,!0)),this.clearLis()}[Symbol.asyncIterator](){return this._closed===!0?this.pushIt({value:null,done:!0}):this._closed!==!1&&this.pushIt(this._closed),{next:()=>{let e=this._itState;Ha.assert(e,"bad state"),Ha.assert(!e.p,"iterator contract broken");let r=e.q.shift();return r?"value"in r?Promise.resolve(r):Promise.reject(r):(e.p=new m8.Deferred,e.p.promise)}}}pushIt(e){let r=this._itState;if(r.p){let n=r.p;Ha.assert(n.state==m8.DeferredState.PENDING,"iterator contract broken"),"value"in e?n.resolve(e):n.reject(e),delete r.p}else r.q.push(e)}};RE.RpcOutputStreamController=MP});var _P=h($l=>{"use strict";var UBe=$l&&$l.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};Object.defineProperty($l,"__esModule",{value:!0});$l.UnaryCall=void 0;var FP=class{constructor(e,r,n,s,i,o,a){this.method=e,this.requestHeaders=r,this.request=n,this.headers=s,this.response=i,this.status=o,this.trailers=a}then(e,r){return this.promiseFinished().then(n=>e?Promise.resolve(e(n)):n,n=>r?Promise.resolve(r(n)):Promise.reject(n))}promiseFinished(){return UBe(this,void 0,void 0,function*(){let[e,r,n,s]=yield Promise.all([this.headers,this.response,this.status,this.trailers]);return{method:this.method,requestHeaders:this.requestHeaders,request:this.request,headers:e,response:r,status:n,trailers:s}})}};$l.UnaryCall=FP});var OP=h(jl=>{"use strict";var OBe=jl&&jl.__awaiter||function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};Object.defineProperty(jl,"__esModule",{value:!0});jl.ServerStreamingCall=void 0;var UP=class{constructor(e,r,n,s
Line truncated
|
||||
You can add a runtime option to disable the check or this warning:
|
||||
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}function uwe(){Object.keys(dC).forEach(function(t){delete dC[t]})}});var pC=h(Xs=>{"use strict";Xs.__esModule=!0;Xs.HandlebarsEnvironment=Kv;function J8(t){return t&&t.__esModule?t:{default:t}}var Xa=sr(),dwe=Xr(),$v=J8(dwe),mwe=Yv(),pwe=z8(),hwe=Jv(),mC=J8(hwe),fwe=Wv(),gwe="4.7.9";Xs.VERSION=gwe;var ywe=8;Xs.COMPILER_REVISION=ywe;var Ewe=7;Xs.LAST_COMPATIBLE_COMPILER_REVISION=Ewe;var Cwe={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1",7:">= 4.0.0 <4.3.0",8:">= 4.3.0"};Xs.REVISION_CHANGES=Cwe;var jv="[object Object]";function Kv(t,e,r){this.helpers=t||{},this.partials=e||{},this.decorators=r||{},mwe.registerDefaultHelpers(this),pwe.registerDefaultDecorators(this)}Kv.prototype={constructor:Kv,logger:mC.default,log:mC.default.log,registerHelper:function(e,r){if(Xa.toString.call(e)===jv){if(r)throw new $v.default("Arg not supported with multiple helpers");Xa.extend(this.helpers,e)}else this.helpers[e]=r},unregisterHelper:function(e){delete this.helpers[e]},registerPartial:function(e,r){if(Xa.toString.call(e)===jv)Xa.extend(this.partials,e);else{if(typeof r>"u")throw new $v.default('Attempting to register a partial called "'+e+'" as undefined');this.partials[e]=r}},unregisterPartial:function(e){delete this.partials[e]},registerDecorator:function(e,r){if(Xa.toString.call(e)===jv){if(r)throw new $v.default("Arg not supported with multiple decorators");Xa.extend(this.decorators,e)}else this.decorators[e]=r},unregisterDecorator:function(e){delete this.decorators[e]},resetLoggedPropertyAccesses:function(){fwe.resetLoggedProperties()}};var Iwe=mC.default.log;Xs.log=Iwe;Xs.createFrame=Xa.createFrame;Xs.logger=mC.default});var $8=h((hC,W8)=>{"use strict";hC.__esModule=!0;function Xv(t){this.string=t}Xv.prototype.toString=Xv.prototype.toHTML=function(){return""+this.string};hC.default=Xv;W8.exports=hC.default});var j8=h(Zv=>{"use strict";Zv.__esModule=!0;Zv.wrapHelper=Bwe;function Bwe(t,e){if(typeof t!="function")return t;var r=function(){var s=arguments[arguments.length-1];return arguments[arguments.length-1]=e(s),t.apply(this,arguments)};return r}});var r$=h(Mo=>{"use strict";Mo.__esModule=!0;Mo.checkRevision=Swe;Mo.template=Rwe;Mo.wrapProgram=fC;Mo.resolvePartial=Pwe;Mo.invokePartial=vwe;Mo.noop=e$;function Qwe(t){return t&&t.__esModule?t:{default:t}}function xwe(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var wwe=sr(),dA=xwe(wwe),bwe=Xr(),Li=Qwe(bwe),_i=pC(),K8=Yv(),Nwe=j8(),X8=Wv();function Swe(t){var e=t&&t[0]||1,r=_i.COMPILER_REVISION;if(!(e>=_i.LAST_COMPATIBLE_COMPILER_REVISION&&e<=_i.COMPILER_REVISION))if(e<_i.LAST_COMPATIBLE_COMPILER_REVISION){var n=_i.REVISION_CHANGES[r],s=_i.REVISION_CHANGES[e];throw new Li.default("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+n+") or downgrade your runtime to an older version ("+s+").")}else throw new Li.default("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+t[1]+").")}function Rwe(t,e){if(!e)throw new Li.default("No environment passed to template");if(!t||!t.main)throw new Li.default("Unknown template object: "+typeof t);t.main.decorator=t.main_d,e.VM.checkRevision(t.compiler);var r=t.compiler&&t.compiler[0]===7;function n(o,a,c){c.hash&&(a=dA.extend({},a,c.hash),c.ids&&(c.ids[0]=!0)),o=e.VM.resolvePartial.call(this,o,a,c),c.hooks=this.hooks,c.protoAccessControl=this.protoAccessControl;var l=e.VM.invokePartial.call(this,o,a,c);if(l==null&&e.compile&&(c.partials[c.name]=e.compile(o,t.compilerOptions,e),l=c.partials[c.name](a,c)),l!=null){if(c.indent){for(var A=l.split(`
|
||||
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}function Lxe(){Object.keys(XE).forEach(function(t){delete XE[t]})}});var eC=h(Ks=>{"use strict";Ks.__esModule=!0;Ks.HandlebarsEnvironment=Uv;function NW(t){return t&&t.__esModule?t:{default:t}}var Ja=ir(),Fxe=Zr(),Fv=NW(Fxe),_xe=kv(),Uxe=QW(),Oxe=Mv(),ZE=NW(Oxe),qxe=Lv(),Hxe="4.7.9";Ks.VERSION=Hxe;var zxe=8;Ks.COMPILER_REVISION=zxe;var Gxe=7;Ks.LAST_COMPATIBLE_COMPILER_REVISION=Gxe;var Yxe={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1",7:">= 4.0.0 <4.3.0",8:">= 4.3.0"};Ks.REVISION_CHANGES=Yxe;var _v="[object Object]";function Uv(t,e,r){this.helpers=t||{},this.partials=e||{},this.decorators=r||{},_xe.registerDefaultHelpers(this),Uxe.registerDefaultDecorators(this)}Uv.prototype={constructor:Uv,logger:ZE.default,log:ZE.default.log,registerHelper:function(e,r){if(Ja.toString.call(e)===_v){if(r)throw new Fv.default("Arg not supported with multiple helpers");Ja.extend(this.helpers,e)}else this.helpers[e]=r},unregisterHelper:function(e){delete this.helpers[e]},registerPartial:function(e,r){if(Ja.toString.call(e)===_v)Ja.extend(this.partials,e);else{if(typeof r>"u")throw new Fv.default('Attempting to register a partial called "'+e+'" as undefined');this.partials[e]=r}},unregisterPartial:function(e){delete this.partials[e]},registerDecorator:function(e,r){if(Ja.toString.call(e)===_v){if(r)throw new Fv.default("Arg not supported with multiple decorators");Ja.extend(this.decorators,e)}else this.decorators[e]=r},unregisterDecorator:function(e){delete this.decorators[e]},resetLoggedPropertyAccesses:function(){qxe.resetLoggedProperties()}};var Vxe=ZE.default.log;Ks.log=Vxe;Ks.createFrame=Ja.createFrame;Ks.logger=ZE.default});var RW=h((tC,SW)=>{"use strict";tC.__esModule=!0;function Ov(t){this.string=t}Ov.prototype.toString=Ov.prototype.toHTML=function(){return""+this.string};tC.default=Ov;SW.exports=tC.default});var PW=h(qv=>{"use strict";qv.__esModule=!0;qv.wrapHelper=Jxe;function Jxe(t,e){if(typeof t!="function")return t;var r=function(){var s=arguments[arguments.length-1];return arguments[arguments.length-1]=e(s),t.apply(this,arguments)};return r}});var LW=h(Do=>{"use strict";Do.__esModule=!0;Do.checkRevision=Zxe;Do.template=ebe;Do.wrapProgram=rC;Do.resolvePartial=tbe;Do.invokePartial=rbe;Do.noop=TW;function Wxe(t){return t&&t.__esModule?t:{default:t}}function $xe(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var jxe=ir(),cA=$xe(jxe),Kxe=Zr(),Li=Wxe(Kxe),Fi=eC(),vW=kv(),Xxe=PW(),DW=Lv();function Zxe(t){var e=t&&t[0]||1,r=Fi.COMPILER_REVISION;if(!(e>=Fi.LAST_COMPATIBLE_COMPILER_REVISION&&e<=Fi.COMPILER_REVISION))if(e<Fi.LAST_COMPATIBLE_COMPILER_REVISION){var n=Fi.REVISION_CHANGES[r],s=Fi.REVISION_CHANGES[e];throw new Li.default("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+n+") or downgrade your runtime to an older version ("+s+").")}else throw new Li.default("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+t[1]+").")}function ebe(t,e){if(!e)throw new Li.default("No environment passed to template");if(!t||!t.main)throw new Li.default("Unknown template object: "+typeof t);t.main.decorator=t.main_d,e.VM.checkRevision(t.compiler);var r=t.compiler&&t.compiler[0]===7;function n(o,a,c){c.hash&&(a=cA.extend({},a,c.hash),c.ids&&(c.ids[0]=!0)),o=e.VM.resolvePartial.call(this,o,a,c),c.hooks=this.hooks,c.protoAccessControl=this.protoAccessControl;var l=e.VM.invokePartial.call(this,o,a,c);if(l==null&&e.compile&&(c.partials[c.name]=e.compile(o,t.compilerOptions,e),l=c.partials[c.name](a,c)),l!=null){if(c.indent){for(var A=l.split(`
|
||||
`),u=0,d=A.length;u<d&&!(!A[u]&&u+1===d);u++)A[u]=c.indent+A[u];l=A.join(`
|
||||
`)}return l}else throw new Li.default("The partial "+c.name+" could not be compiled when running in runtime-only mode")}var s={strict:function(a,c,l){if(!a||!(c in a))throw new Li.default('"'+c+'" not defined in '+a,{loc:l});return s.lookupProperty(a,c)},lookupProperty:function(a,c){var l=a[c];if(l==null||Object.prototype.hasOwnProperty.call(a,c)||X8.resultIsAllowed(l,s.protoAccessControl,c))return l},lookup:function(a,c){for(var l=a.length,A=0;A<l;A++){var u=a[A]&&s.lookupProperty(a[A],c);if(u!=null)return u}},lambda:function(a,c){return typeof a=="function"?a.call(c):a},escapeExpression:dA.escapeExpression,invokePartial:n,fn:function(a){var c=t[a];return c.decorator=t[a+"_d"],c},programs:[],program:function(a,c,l,A,u){var d=this.programs[a],m=this.fn(a);return c||u||A||l?d=fC(this,a,m,c,l,A,u):d||(d=this.programs[a]=fC(this,a,m)),d},data:function(a,c){for(;a&&c--;)a=a._parent;return a},mergeIfNeeded:function(a,c){var l=a||c;return a&&c&&a!==c&&(l=dA.extend({},c,a)),l},nullContext:Object.seal({}),noop:e.VM.noop,compilerInfo:t.compiler};function i(o){var a=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],c=a.data;i._setup(a),!a.partial&&t.useData&&(c=Dwe(o,c));var l=void 0,A=t.useBlockParams?[]:void 0;t.useDepths&&(a.depths?l=o!=a.depths[0]?[o].concat(a.depths):a.depths:l=[o]);function u(d){return""+t.main(s,d,s.helpers,s.partials,c,A,l)}return u=t$(t.main,u,s,a.depths||[],c,A),u(o,a)}return i.isTop=!0,i._setup=function(o){if(o.partial)s.protoAccessControl=o.protoAccessControl,s.helpers=o.helpers,s.partials=o.partials,s.decorators=o.decorators,s.hooks=o.hooks;else{var a={};Z8(a,e.helpers,s),Z8(a,o.helpers,s),s.helpers=a,t.usePartial&&(s.partials=s.mergeIfNeeded(o.partials,e.partials)),(t.usePartial||t.useDecorators)&&(s.decorators=dA.extend({},e.decorators,o.decorators)),s.hooks={},s.protoAccessControl=X8.createProtoAccessControl(o);var c=o.allowCallsToHelperMissing||r;K8.moveHelperToHooks(s,"helperMissing",c),K8.moveHelperToHooks(s,"blockHelperMissing",c)}},i._child=function(o,a,c,l){if(t.useBlockParams&&!c)throw new Li.default("must pass block params");if(t.useDepths&&!l)throw new Li.default("must pass parent depths");return fC(s,o,t[o],a,0,c,l)},i}function fC(t,e,r,n,s,i,o){function a(c){var l=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],A=o;return o&&c!=o[0]&&!(c===t.nullContext&&o[0]===null)&&(A=[c].concat(o)),r(t,c,t.helpers,t.partials,l.data||n,i&&[l.blockParams].concat(i),A)}return a=t$(r,a,t,o,n,i),a.program=e,a.depth=o?o.length:0,a.blockParams=s||0,a}function Pwe(t,e,r){return t?!t.call&&!r.name&&(r.name=t,t=gC(r.partials,t)):r.name==="@partial-block"?t=gC(r.data,"partial-block"):t=gC(r.partials,r.name),t}function vwe(t,e,r){var n=gC(r.data,"partial-block");r.partial=!0,r.ids&&(r.data.contextPath=r.ids[0]||r.data.contextPath);var s=void 0;if(r.fn&&r.fn!==e$&&(function(){r.data=_i.createFrame(r.data);var i=r.fn;s=r.data["partial-block"]=function(a){var c=arguments.length<=1||arguments[1]===void 0?{}:arguments[1];return c.data=_i.createFrame(c.data),c.data["partial-block"]=n,i(a,c)},i.partials&&(r.partials=dA.extend({},r.partials,i.partials))})(),t===void 0&&s&&(t=s),t===void 0)throw new Li.default("The partial "+r.name+" could not be found");if(t instanceof Function)return t(e,r)}function e$(){return""}function gC(t,e){if(t&&Object.prototype.hasOwnProperty.call(t,e))return t[e]}function Dwe(t,e){return(!e||!("root"in e))&&(e=e?_i.createFrame(e):{},e.root=t),e}function t$(t,e,r,n,s,i){if(t.decorator){var o={};e=t.decorator(e,o,r,n&&n[0],s,i,n),dA.extend(e,o)}return e}function Z8(t,e,r){e&&Object.keys(e).forEach(function(n){var s=e[n];t[n]=kwe(s,r)})}function kwe(t,e){var r=e.lookupProperty;return Nwe.wrapHelper(t,function(n){return n.lookupProperty=r,n})}});var eD=h((yC,n$)=>{"use strict";yC.__esModule=!0;yC.default=function(t){(function(){typeof globalThis!="object"&&(Object.prototype.__defineGetter__("__magic__",function(){return this}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__)})();var e=globalThis.Handlebars;t.noConflict=function(){return globalThis.Handlebars===t&&(globalThis.Handlebars=e),t}};n$.exports=yC.default});var c$=h((EC,a$)=>{"use strict";EC.__esModule=!0;function rD(t){return t&&t.__esModule?t:{default:t}}function nD(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var Twe=pC(),s$=nD(Twe),Mwe=$8(),Lwe=rD(Mwe),_we=Xr(),Fwe=rD(_we),Uwe=sr(),tD=nD(Uwe),Owe=r$(),i$=nD(Owe),qwe=eD(),Hwe=rD(qwe);function o$(){var t=new s$.HandlebarsEnvironment;return tD.extend(t,s$),t.SafeString=Lwe.default,t.Exception=Fwe.default,t.Utils=tD,t.escapeExpression=tD.escapeExpression,t.VM=i$,t.template=function(e){return i$.template(e,t)},t}var Nm=o$();Nm.create=o$;Hwe.default(Nm);Nm.default=Nm;EC.default=Nm;a$.exports=EC.default});var sD=h((CC,A$)=>{"use strict";CC.__esModule=!0;var l$={helpers:{helperExpression:function(e){return e.type==="SubExpression"||(e.type==="Mus
Line truncated
|
||||
`)}return l}else throw new Li.default("The partial "+c.name+" could not be compiled when running in runtime-only mode")}var s={strict:function(a,c,l){if(!a||!(c in a))throw new Li.default('"'+c+'" not defined in '+a,{loc:l});return s.lookupProperty(a,c)},lookupProperty:function(a,c){var l=a[c];if(l==null||Object.prototype.hasOwnProperty.call(a,c)||DW.resultIsAllowed(l,s.protoAccessControl,c))return l},lookup:function(a,c){for(var l=a.length,A=0;A<l;A++){var u=a[A]&&s.lookupProperty(a[A],c);if(u!=null)return u}},lambda:function(a,c){return typeof a=="function"?a.call(c):a},escapeExpression:cA.escapeExpression,invokePartial:n,fn:function(a){var c=t[a];return c.decorator=t[a+"_d"],c},programs:[],program:function(a,c,l,A,u){var d=this.programs[a],m=this.fn(a);return c||u||A||l?d=rC(this,a,m,c,l,A,u):d||(d=this.programs[a]=rC(this,a,m)),d},data:function(a,c){for(;a&&c--;)a=a._parent;return a},mergeIfNeeded:function(a,c){var l=a||c;return a&&c&&a!==c&&(l=cA.extend({},c,a)),l},nullContext:Object.seal({}),noop:e.VM.noop,compilerInfo:t.compiler};function i(o){var a=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],c=a.data;i._setup(a),!a.partial&&t.useData&&(c=nbe(o,c));var l=void 0,A=t.useBlockParams?[]:void 0;t.useDepths&&(a.depths?l=o!=a.depths[0]?[o].concat(a.depths):a.depths:l=[o]);function u(d){return""+t.main(s,d,s.helpers,s.partials,c,A,l)}return u=MW(t.main,u,s,a.depths||[],c,A),u(o,a)}return i.isTop=!0,i._setup=function(o){if(o.partial)s.protoAccessControl=o.protoAccessControl,s.helpers=o.helpers,s.partials=o.partials,s.decorators=o.decorators,s.hooks=o.hooks;else{var a={};kW(a,e.helpers,s),kW(a,o.helpers,s),s.helpers=a,t.usePartial&&(s.partials=s.mergeIfNeeded(o.partials,e.partials)),(t.usePartial||t.useDecorators)&&(s.decorators=cA.extend({},e.decorators,o.decorators)),s.hooks={},s.protoAccessControl=DW.createProtoAccessControl(o);var c=o.allowCallsToHelperMissing||r;vW.moveHelperToHooks(s,"helperMissing",c),vW.moveHelperToHooks(s,"blockHelperMissing",c)}},i._child=function(o,a,c,l){if(t.useBlockParams&&!c)throw new Li.default("must pass block params");if(t.useDepths&&!l)throw new Li.default("must pass parent depths");return rC(s,o,t[o],a,0,c,l)},i}function rC(t,e,r,n,s,i,o){function a(c){var l=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],A=o;return o&&c!=o[0]&&!(c===t.nullContext&&o[0]===null)&&(A=[c].concat(o)),r(t,c,t.helpers,t.partials,l.data||n,i&&[l.blockParams].concat(i),A)}return a=MW(r,a,t,o,n,i),a.program=e,a.depth=o?o.length:0,a.blockParams=s||0,a}function tbe(t,e,r){return t?!t.call&&!r.name&&(r.name=t,t=nC(r.partials,t)):r.name==="@partial-block"?t=nC(r.data,"partial-block"):t=nC(r.partials,r.name),t}function rbe(t,e,r){var n=nC(r.data,"partial-block");r.partial=!0,r.ids&&(r.data.contextPath=r.ids[0]||r.data.contextPath);var s=void 0;if(r.fn&&r.fn!==TW&&(function(){r.data=Fi.createFrame(r.data);var i=r.fn;s=r.data["partial-block"]=function(a){var c=arguments.length<=1||arguments[1]===void 0?{}:arguments[1];return c.data=Fi.createFrame(c.data),c.data["partial-block"]=n,i(a,c)},i.partials&&(r.partials=cA.extend({},r.partials,i.partials))})(),t===void 0&&s&&(t=s),t===void 0)throw new Li.default("The partial "+r.name+" could not be found");if(t instanceof Function)return t(e,r)}function TW(){return""}function nC(t,e){if(t&&Object.prototype.hasOwnProperty.call(t,e))return t[e]}function nbe(t,e){return(!e||!("root"in e))&&(e=e?Fi.createFrame(e):{},e.root=t),e}function MW(t,e,r,n,s,i){if(t.decorator){var o={};e=t.decorator(e,o,r,n&&n[0],s,i,n),cA.extend(e,o)}return e}function kW(t,e,r){e&&Object.keys(e).forEach(function(n){var s=e[n];t[n]=sbe(s,r)})}function sbe(t,e){var r=e.lookupProperty;return Xxe.wrapHelper(t,function(n){return n.lookupProperty=r,n})}});var Hv=h((sC,FW)=>{"use strict";sC.__esModule=!0;sC.default=function(t){(function(){typeof globalThis!="object"&&(Object.prototype.__defineGetter__("__magic__",function(){return this}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__)})();var e=globalThis.Handlebars;t.noConflict=function(){return globalThis.Handlebars===t&&(globalThis.Handlebars=e),t}};FW.exports=sC.default});var HW=h((iC,qW)=>{"use strict";iC.__esModule=!0;function Gv(t){return t&&t.__esModule?t:{default:t}}function Yv(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var ibe=eC(),_W=Yv(ibe),obe=RW(),abe=Gv(obe),cbe=Zr(),lbe=Gv(cbe),Abe=ir(),zv=Yv(Abe),ube=LW(),UW=Yv(ube),dbe=Hv(),mbe=Gv(dbe);function OW(){var t=new _W.HandlebarsEnvironment;return zv.extend(t,_W),t.SafeString=abe.default,t.Exception=lbe.default,t.Utils=zv,t.escapeExpression=zv.escapeExpression,t.VM=UW,t.template=function(e){return UW.template(e,t)},t}var Em=OW();Em.create=OW;mbe.default(Em);Em.default=Em;iC.default=Em;qW.exports=iC.default});var Vv=h((oC,GW)=>{"use strict";oC.__esModule=!0;var zW={helpers:{helperExpression:function(e){return e.type==="SubExpression"||(e.type==="Mus
Line truncated
|
||||
`+this.lexer.showPosition()+`
|
||||
Expecting `+de.join(", ")+", got '"+(this.terminals_[I]||I)+"'":At="Parse error on line "+(u+1)+": Unexpected "+(I==1?"end of input":"'"+(this.terminals_[I]||I)+"'"),this.parseError(At,{text:this.lexer.match,token:this.terminals_[I]||I,line:this.lexer.yylineno,loc:E,expected:de})}}if(_[0]instanceof Array&&_.length>1)throw new Error("Parse Error: multiple actions possible at state: "+D+", token: "+I);switch(_[0]){case 1:o.push(I),a.push(this.lexer.yytext),c.push(this.lexer.yylloc),o.push(_[1]),I=null,w?(I=w,w=null):(d=this.lexer.yyleng,A=this.lexer.yytext,u=this.lexer.yylineno,E=this.lexer.yylloc,m>0&&m--);break;case 2:if(ee=this.productions_[_[1]][1],Be.$=a[a.length-ee],Be._$={first_line:c[c.length-(ee||1)].first_line,last_line:c[c.length-1].last_line,first_column:c[c.length-(ee||1)].first_column,last_column:c[c.length-1].last_column},g&&(Be._$.range=[c[c.length-(ee||1)].range[0],c[c.length-1].range[1]]),ge=this.performAction.call(Be,A,d,u,this.yy,_[1],a,c),typeof ge<"u")return ge;ee&&(o=o.slice(0,-1*ee*2),a=a.slice(0,-1*ee),c=c.slice(0,-1*ee)),o.push(this.productions_[_[1]][0]),a.push(Be.$),c.push(Be._$),F=l[o[o.length-2]][o[o.length-1]],o.push(F);break;case 3:return!0}}return!0}},e=(function(){var n={EOF:1,parseError:function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw new Error(i)},setInput:function(i){return this._input=i,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var i=this._input[0];this.yytext+=i,this.yyleng++,this.offset++,this.match+=i,this.matched+=i;var o=i.match(/(?:\r\n?|\n).*/g);return o?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),i},unput:function(i){var o=i.length,a=i.split(/(?:\r\n?|\n)/g);this._input=i+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-o-1),this.offset-=o;var c=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),a.length-1&&(this.yylineno-=a.length-1);var l=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:a?(a.length===c.length?this.yylloc.first_column:0)+c[c.length-a.length].length-a[0].length:this.yylloc.first_column-o},this.options.ranges&&(this.yylloc.range=[l[0],l[0]+this.yyleng-o]),this},more:function(){return this._more=!0,this},less:function(i){this.unput(this.match.slice(i))},pastInput:function(){var i=this.matched.substr(0,this.matched.length-this.match.length);return(i.length>20?"...":"")+i.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var i=this.match;return i.length<20&&(i+=this._input.substr(0,20-i.length)),(i.substr(0,20)+(i.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var i=this.pastInput(),o=new Array(i.length+1).join("-");return i+this.upcomingInput()+`
|
||||
Expecting `+de.join(", ")+", got '"+(this.terminals_[I]||I)+"'":At="Parse error on line "+(u+1)+": Unexpected "+(I==1?"end of input":"'"+(this.terminals_[I]||I)+"'"),this.parseError(At,{text:this.lexer.match,token:this.terminals_[I]||I,line:this.lexer.yylineno,loc:E,expected:de})}}if(F[0]instanceof Array&&F.length>1)throw new Error("Parse Error: multiple actions possible at state: "+D+", token: "+I);switch(F[0]){case 1:o.push(I),a.push(this.lexer.yytext),c.push(this.lexer.yylloc),o.push(F[1]),I=null,w?(I=w,w=null):(d=this.lexer.yyleng,A=this.lexer.yytext,u=this.lexer.yylineno,E=this.lexer.yylloc,m>0&&m--);break;case 2:if(ee=this.productions_[F[1]][1],Qe.$=a[a.length-ee],Qe._$={first_line:c[c.length-(ee||1)].first_line,last_line:c[c.length-1].last_line,first_column:c[c.length-(ee||1)].first_column,last_column:c[c.length-1].last_column},g&&(Qe._$.range=[c[c.length-(ee||1)].range[0],c[c.length-1].range[1]]),ye=this.performAction.call(Qe,A,d,u,this.yy,F[1],a,c),typeof ye<"u")return ye;ee&&(o=o.slice(0,-1*ee*2),a=a.slice(0,-1*ee),c=c.slice(0,-1*ee)),o.push(this.productions_[F[1]][0]),a.push(Qe.$),c.push(Qe._$),_=l[o[o.length-2]][o[o.length-1]],o.push(_);break;case 3:return!0}}return!0}},e=(function(){var n={EOF:1,parseError:function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw new Error(i)},setInput:function(i){return this._input=i,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var i=this._input[0];this.yytext+=i,this.yyleng++,this.offset++,this.match+=i,this.matched+=i;var o=i.match(/(?:\r\n?|\n).*/g);return o?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),i},unput:function(i){var o=i.length,a=i.split(/(?:\r\n?|\n)/g);this._input=i+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-o-1),this.offset-=o;var c=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),a.length-1&&(this.yylineno-=a.length-1);var l=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:a?(a.length===c.length?this.yylloc.first_column:0)+c[c.length-a.length].length-a[0].length:this.yylloc.first_column-o},this.options.ranges&&(this.yylloc.range=[l[0],l[0]+this.yyleng-o]),this},more:function(){return this._more=!0,this},less:function(i){this.unput(this.match.slice(i))},pastInput:function(){var i=this.matched.substr(0,this.matched.length-this.match.length);return(i.length>20?"...":"")+i.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var i=this.match;return i.length<20&&(i+=this._input.substr(0,20-i.length)),(i.substr(0,20)+(i.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var i=this.pastInput(),o=new Array(i.length+1).join("-");return i+this.upcomingInput()+`
|
||||
`+o+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var i,o,a,c,l,A;this._more||(this.yytext="",this.match="");for(var u=this._currentRules(),d=0;d<u.length&&(a=this._input.match(this.rules[u[d]]),!(a&&(!o||a[0].length>o[0].length)&&(o=a,c=d,!this.options.flex)));d++);return o?(A=o[0].match(/(?:\r\n?|\n).*/g),A&&(this.yylineno+=A.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:A?A[A.length-1].length-A[A.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+o[0].length},this.yytext+=o[0],this.match+=o[0],this.matches=o,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._input=this._input.slice(o[0].length),this.matched+=o[0],i=this.performAction.call(this,this.yy,this,u[c],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i||void 0):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
||||
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var i=this.next();return typeof i<"u"?i:this.lex()},begin:function(i){this.conditionStack.push(i)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(i){this.begin(i)}};return n.options={},n.performAction=function(i,o,a,c){function l(u,d){return o.yytext=o.yytext.substring(u,o.yyleng-d+u)}var A=c;switch(a){case 0:if(o.yytext.slice(-2)==="\\\\"?(l(0,1),this.begin("mu")):o.yytext.slice(-1)==="\\"?(l(0,1),this.begin("emu")):this.begin("mu"),o.yytext)return 15;break;case 1:return 15;case 2:return this.popState(),15;break;case 3:return this.begin("raw"),15;break;case 4:return this.popState(),this.conditionStack[this.conditionStack.length-1]==="raw"?15:(l(5,9),"END_RAW_BLOCK");case 5:return 15;case 6:return this.popState(),14;break;case 7:return 65;case 8:return 68;case 9:return 19;case 10:return this.popState(),this.begin("raw"),23;break;case 11:return 55;case 12:return 60;case 13:return 29;case 14:return 47;case 15:return this.popState(),44;break;case 16:return this.popState(),44;break;case 17:return 34;case 18:return 39;case 19:return 51;case 20:return 48;case 21:this.unput(o.yytext),this.popState(),this.begin("com");break;case 22:return this.popState(),14;break;case 23:return 48;case 24:return 73;case 25:return 72;case 26:return 72;case 27:return 87;case 28:break;case 29:return this.popState(),54;break;case 30:return this.popState(),33;break;case 31:return o.yytext=l(1,2).replace(/\\"/g,'"'),80;break;case 32:return o.yytext=l(1,2).replace(/\\'/g,"'"),80;break;case 33:return 85;case 34:return 82;case 35:return 82;case 36:return 83;case 37:return 84;case 38:return 81;case 39:return 75;case 40:return 77;case 41:return 72;case 42:return o.yytext=o.yytext.replace(/\\([\\\]])/g,"$1"),72;break;case 43:return"INVALID";case 44:return 5}},n.rules=[/^(?:[^\x00]*?(?=(\{\{)))/,/^(?:[^\x00]+)/,/^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/,/^(?:\{\{\{\{(?=[^\/]))/,/^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/,/^(?:[^\x00]+?(?=(\{\{\{\{)))/,/^(?:[\s\S]*?--(~)?\}\})/,/^(?:\()/,/^(?:\))/,/^(?:\{\{\{\{)/,/^(?:\}\}\}\})/,/^(?:\{\{(~)?>)/,/^(?:\{\{(~)?#>)/,/^(?:\{\{(~)?#\*?)/,/^(?:\{\{(~)?\/)/,/^(?:\{\{(~)?\^\s*(~)?\}\})/,/^(?:\{\{(~)?\s*else\s*(~)?\}\})/,/^(?:\{\{(~)?\^)/,/^(?:\{\{(~)?\s*else\b)/,/^(?:\{\{(~)?\{)/,/^(?:\{\{(~)?&)/,/^(?:\{\{(~)?!--)/,/^(?:\{\{(~)?![\s\S]*?\}\})/,/^(?:\{\{(~)?\*?)/,/^(?:=)/,/^(?:\.\.)/,/^(?:\.(?=([=~}\s\/.)|])))/,/^(?:[\/.])/,/^(?:\s+)/,/^(?:\}(~)?\}\})/,/^(?:(~)?\}\})/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:@)/,/^(?:true(?=([~}\s)])))/,/^(?:false(?=([~}\s)])))/,/^(?:undefined(?=([~}\s)])))/,/^(?:null(?=([~}\s)])))/,/^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/,/^(?:as\s+\|)/,/^(?:\|)/,/^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/,/^(?:\[(\\\]|[^\]])*\])/,/^(?:.)/,/^(?:$)/],n.conditions={mu:{rules:[7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44],inclusive:!1},emu:{rules:[2],inclusive:!1},com:{rules:[6],inclusive:!1},raw:{rules:[3,4,5],inclusive:!1},INITIAL:{rules:[0,1,44],inclusive:!0}},n})();t.lexer=e;function r(){this.yy={}}return r.prototype=t,t.Parser=r,new r})();IC.default=zwe;u$.exports=IC.default});var wC=h((xC,h$)=>{"use strict";xC.__esModule=!0;function Gwe(t){return t&&t.__esModule?t:{default:t}}var Ywe=Xr(),iD=Gwe(Ywe);function BC(){this.parents=[]}BC.prototype={constructor:BC,mutating:!1,acceptKey:function(e,r){var n=this.accept(e[r]);if(this.mutating){if(n&&!BC.prototype[n.type])throw new iD.default('Unexpected node type "'+n.type+'" found when accepting '+r+" on "+e.type);e[r]=n}},acceptRequired:function(e,r){if(this.acceptKey(e,r),!e[r])throw new iD.default(e.type+" requires "+r)},acceptArray:function(e){for(var r=0,n=e.length;r<n;r++)this.acceptKey(e,r),e[r]||(e.splice(r,1),r--,n--)},accept:function(e){if(e){if(!this[e.type])throw new iD.default("Unknown type: "+e.type,e);this.current&&this.parents.unshift(this.current),this.current=e;var r=this[e.type](e);if(this.current=this.parents.shift(),!this.mutating||r)return r;if(r!==!1)return e}},Program:function(e){this.acceptArray(e.body)},MustacheStatement:QC,Decorator:QC,BlockStatement:m$,DecoratorBlock:m$,PartialStatement:p$,PartialBlockStatement:function(e){p$.call(this,e),this.acceptKey(e,"program")},ContentStatement:function(){},CommentStatement:function(){},SubExpression:QC,PathExpression:function(){},StringLiteral:function(){},NumberLiteral:function(){},BooleanLiteral:function(){},UndefinedLiteral:function(){},NullLiteral:function(){},Hash:function(e){this.acceptArray(e.pairs)},HashPair:function(e){this.acceptRequired(e,"value")}};function QC(t){this.acceptRequired(t,"path"),this.acceptArray(t.params),this.acceptKey(t,"hash")}function m$(t){Line truncated
|
||||
`])}),e},each:function(e){for(var r=0,n=this.source.length;r<n;r++)e(this.source[r])},empty:function(){var e=this.currentLocation||{start:{}};return new rc(e.start.line,e.start.column,this.srcFile)},wrap:function(e){var r=arguments.length<=1||arguments[1]===void 0?this.currentLocation||{start:{}}:arguments[1];return e instanceof rc?e:(e=ND(e,this,r),new rc(r.start.line,r.start.column,this.srcFile,e))},functionCall:function(e,r,n){return n=this.generateList(n),this.wrap([e,r?"."+r+"(":"(",n,")"])},quotedString:function(e){return'"'+(e+"").replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")+'"'},objectLiteral:function(e){var r=this,n=[];Object.keys(e).forEach(function(i){var o=ND(e[i],r);o!=="undefined"&&n.push([r.quotedString(i),":",o])});var s=this.generateList(n);return s.prepend("{"),s.add("}"),s},generateList:function(e){for(var r=this.empty(),n=0,s=e.length;n<s;n++)n&&r.add(","),r.add(ND(e[n],this));return r},generateArray:function(e){var r=this.generateList(e);return r.prepend("["),r.add("]"),r}};kC.default=j$;K$.exports=kC.default});var n5=h((TC,r5)=>{"use strict";TC.__esModule=!0;function t5(t){return t&&t.__esModule?t:{default:t}}var Z$=pC(),Hbe=Xr(),RD=t5(Hbe),zbe=sr(),Gbe=X$(),e5=t5(Gbe);function yA(t){this.value=t}function EA(){}EA.prototype={nameLookup:function(e,r){return this.internalNameLookup(e,r)},depthedLookup:function(e){return[this.aliasable("container.lookup"),"(depths, ",JSON.stringify(e),")"]},compilerInfo:function(){var e=Z$.COMPILER_REVISION,r=Z$.REVISION_CHANGES[e];return[e,r]},appendToBuffer:function(e,r,n){return zbe.isArray(e)||(e=[e]),e=this.source.wrap(e,r),this.environment.isSimple?["return ",e,";"]:n?["buffer += ",e,";"]:(e.appendToBuffer=!0,e)},initializeBuffer:function(){return this.quotedString("")},internalNameLookup:function(e,r){return this.lookupPropertyFunctionIsUsed=!0,["lookupProperty(",e,",",JSON.stringify(r),")"]},lookupPropertyFunctionIsUsed:!1,compile:function(e,r,n,s){this.environment=e,this.options=r,this.stringParams=this.options.stringParams,this.trackIds=this.options.trackIds,this.precompile=!s,this.name=this.environment.name,this.isChild=!!n,this.context=n||{decorators:[],programs:[],environments:[]},this.preamble(),this.stackSlot=0,this.stackVars=[],this.aliases={},this.registers={list:[]},this.hashes=[],this.compileStack=[],this.inlineStack=[],this.blockParams=[],this.compileChildren(e,r),this.useDepths=this.useDepths||e.useDepths||e.useDecorators||this.options.compat,this.useBlockParams=this.useBlockParams||e.useBlockParams;var i=e.opcodes,o=void 0,a=void 0,c=void 0,l=void 0;for(c=0,l=i.length;c<l;c++)o=i[c],this.source.currentLocation=o.loc,a=a||o.loc,this[o.opcode].apply(this,o.args);if(this.source.currentLocation=a,this.pushSource(""),this.stackSlot||this.inlineStack.length||this.compileStack.length)throw new RD.default("Compile completed with content left on stack");this.decorators.isEmpty()?this.decorators=void 0:(this.useDecorators=!0,this.decorators.prepend(["var decorators = container.decorators, ",this.lookupPropertyFunctionVarDeclaration(),`;
|
||||
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var i=this.next();return typeof i<"u"?i:this.lex()},begin:function(i){this.conditionStack.push(i)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(i){this.begin(i)}};return n.options={},n.performAction=function(i,o,a,c){function l(u,d){return o.yytext=o.yytext.substring(u,o.yyleng-d+u)}var A=c;switch(a){case 0:if(o.yytext.slice(-2)==="\\\\"?(l(0,1),this.begin("mu")):o.yytext.slice(-1)==="\\"?(l(0,1),this.begin("emu")):this.begin("mu"),o.yytext)return 15;break;case 1:return 15;case 2:return this.popState(),15;break;case 3:return this.begin("raw"),15;break;case 4:return this.popState(),this.conditionStack[this.conditionStack.length-1]==="raw"?15:(l(5,9),"END_RAW_BLOCK");case 5:return 15;case 6:return this.popState(),14;break;case 7:return 65;case 8:return 68;case 9:return 19;case 10:return this.popState(),this.begin("raw"),23;break;case 11:return 55;case 12:return 60;case 13:return 29;case 14:return 47;case 15:return this.popState(),44;break;case 16:return this.popState(),44;break;case 17:return 34;case 18:return 39;case 19:return 51;case 20:return 48;case 21:this.unput(o.yytext),this.popState(),this.begin("com");break;case 22:return this.popState(),14;break;case 23:return 48;case 24:return 73;case 25:return 72;case 26:return 72;case 27:return 87;case 28:break;case 29:return this.popState(),54;break;case 30:return this.popState(),33;break;case 31:return o.yytext=l(1,2).replace(/\\"/g,'"'),80;break;case 32:return o.yytext=l(1,2).replace(/\\'/g,"'"),80;break;case 33:return 85;case 34:return 82;case 35:return 82;case 36:return 83;case 37:return 84;case 38:return 81;case 39:return 75;case 40:return 77;case 41:return 72;case 42:return o.yytext=o.yytext.replace(/\\([\\\]])/g,"$1"),72;break;case 43:return"INVALID";case 44:return 5}},n.rules=[/^(?:[^\x00]*?(?=(\{\{)))/,/^(?:[^\x00]+)/,/^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/,/^(?:\{\{\{\{(?=[^\/]))/,/^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/,/^(?:[^\x00]+?(?=(\{\{\{\{)))/,/^(?:[\s\S]*?--(~)?\}\})/,/^(?:\()/,/^(?:\))/,/^(?:\{\{\{\{)/,/^(?:\}\}\}\})/,/^(?:\{\{(~)?>)/,/^(?:\{\{(~)?#>)/,/^(?:\{\{(~)?#\*?)/,/^(?:\{\{(~)?\/)/,/^(?:\{\{(~)?\^\s*(~)?\}\})/,/^(?:\{\{(~)?\s*else\s*(~)?\}\})/,/^(?:\{\{(~)?\^)/,/^(?:\{\{(~)?\s*else\b)/,/^(?:\{\{(~)?\{)/,/^(?:\{\{(~)?&)/,/^(?:\{\{(~)?!--)/,/^(?:\{\{(~)?![\s\S]*?\}\})/,/^(?:\{\{(~)?\*?)/,/^(?:=)/,/^(?:\.\.)/,/^(?:\.(?=([=~}\s\/.)|])))/,/^(?:[\/.])/,/^(?:\s+)/,/^(?:\}(~)?\}\})/,/^(?:(~)?\}\})/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:@)/,/^(?:true(?=([~}\s)])))/,/^(?:false(?=([~}\s)])))/,/^(?:undefined(?=([~}\s)])))/,/^(?:null(?=([~}\s)])))/,/^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/,/^(?:as\s+\|)/,/^(?:\|)/,/^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/,/^(?:\[(\\\]|[^\]])*\])/,/^(?:.)/,/^(?:$)/],n.conditions={mu:{rules:[7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44],inclusive:!1},emu:{rules:[2],inclusive:!1},com:{rules:[6],inclusive:!1},raw:{rules:[3,4,5],inclusive:!1},INITIAL:{rules:[0,1,44],inclusive:!0}},n})();t.lexer=e;function r(){this.yy={}}return r.prototype=t,t.Parser=r,new r})();aC.default=pbe;YW.exports=aC.default});var uC=h((AC,$W)=>{"use strict";AC.__esModule=!0;function hbe(t){return t&&t.__esModule?t:{default:t}}var fbe=Zr(),Jv=hbe(fbe);function cC(){this.parents=[]}cC.prototype={constructor:cC,mutating:!1,acceptKey:function(e,r){var n=this.accept(e[r]);if(this.mutating){if(n&&!cC.prototype[n.type])throw new Jv.default('Unexpected node type "'+n.type+'" found when accepting '+r+" on "+e.type);e[r]=n}},acceptRequired:function(e,r){if(this.acceptKey(e,r),!e[r])throw new Jv.default(e.type+" requires "+r)},acceptArray:function(e){for(var r=0,n=e.length;r<n;r++)this.acceptKey(e,r),e[r]||(e.splice(r,1),r--,n--)},accept:function(e){if(e){if(!this[e.type])throw new Jv.default("Unknown type: "+e.type,e);this.current&&this.parents.unshift(this.current),this.current=e;var r=this[e.type](e);if(this.current=this.parents.shift(),!this.mutating||r)return r;if(r!==!1)return e}},Program:function(e){this.acceptArray(e.body)},MustacheStatement:lC,Decorator:lC,BlockStatement:JW,DecoratorBlock:JW,PartialStatement:WW,PartialBlockStatement:function(e){WW.call(this,e),this.acceptKey(e,"program")},ContentStatement:function(){},CommentStatement:function(){},SubExpression:lC,PathExpression:function(){},StringLiteral:function(){},NumberLiteral:function(){},BooleanLiteral:function(){},UndefinedLiteral:function(){},NullLiteral:function(){},Hash:function(e){this.acceptArray(e.pairs)},HashPair:function(e){this.acceptRequired(e,"value")}};function lC(t){this.acceptRequired(t,"path"),this.acceptArray(t.params),this.acceptKey(t,"hash")}function JW(t){Line truncated
|
||||
`])}),e},each:function(e){for(var r=0,n=this.source.length;r<n;r++)e(this.source[r])},empty:function(){var e=this.currentLocation||{start:{}};return new Ka(e.start.line,e.start.column,this.srcFile)},wrap:function(e){var r=arguments.length<=1||arguments[1]===void 0?this.currentLocation||{start:{}}:arguments[1];return e instanceof Ka?e:(e=hD(e,this,r),new Ka(r.start.line,r.start.column,this.srcFile,e))},functionCall:function(e,r,n){return n=this.generateList(n),this.wrap([e,r?"."+r+"(":"(",n,")"])},quotedString:function(e){return'"'+(e+"").replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")+'"'},objectLiteral:function(e){var r=this,n=[];Object.keys(e).forEach(function(i){var o=hD(e[i],r);o!=="undefined"&&n.push([r.quotedString(i),":",o])});var s=this.generateList(n);return s.prepend("{"),s.add("}"),s},generateList:function(e){for(var r=this.empty(),n=0,s=e.length;n<s;n++)n&&r.add(","),r.add(hD(e[n],this));return r},generateArray:function(e){var r=this.generateList(e);return r.prepend("["),r.add("]"),r}};EC.default=P$;v$.exports=EC.default});var F$=h((CC,L$)=>{"use strict";CC.__esModule=!0;function M$(t){return t&&t.__esModule?t:{default:t}}var k$=eC(),mwe=Zr(),gD=M$(mwe),pwe=ir(),hwe=D$(),T$=M$(hwe);function pA(t){this.value=t}function hA(){}hA.prototype={nameLookup:function(e,r){return this.internalNameLookup(e,r)},depthedLookup:function(e){return[this.aliasable("container.lookup"),"(depths, ",JSON.stringify(e),")"]},compilerInfo:function(){var e=k$.COMPILER_REVISION,r=k$.REVISION_CHANGES[e];return[e,r]},appendToBuffer:function(e,r,n){return pwe.isArray(e)||(e=[e]),e=this.source.wrap(e,r),this.environment.isSimple?["return ",e,";"]:n?["buffer += ",e,";"]:(e.appendToBuffer=!0,e)},initializeBuffer:function(){return this.quotedString("")},internalNameLookup:function(e,r){return this.lookupPropertyFunctionIsUsed=!0,["lookupProperty(",e,",",JSON.stringify(r),")"]},lookupPropertyFunctionIsUsed:!1,compile:function(e,r,n,s){this.environment=e,this.options=r,this.stringParams=this.options.stringParams,this.trackIds=this.options.trackIds,this.precompile=!s,this.name=this.environment.name,this.isChild=!!n,this.context=n||{decorators:[],programs:[],environments:[]},this.preamble(),this.stackSlot=0,this.stackVars=[],this.aliases={},this.registers={list:[]},this.hashes=[],this.compileStack=[],this.inlineStack=[],this.blockParams=[],this.compileChildren(e,r),this.useDepths=this.useDepths||e.useDepths||e.useDecorators||this.options.compat,this.useBlockParams=this.useBlockParams||e.useBlockParams;var i=e.opcodes,o=void 0,a=void 0,c=void 0,l=void 0;for(c=0,l=i.length;c<l;c++)o=i[c],this.source.currentLocation=o.loc,a=a||o.loc,this[o.opcode].apply(this,o.args);if(this.source.currentLocation=a,this.pushSource(""),this.stackSlot||this.inlineStack.length||this.compileStack.length)throw new gD.default("Compile completed with content left on stack");this.decorators.isEmpty()?this.decorators=void 0:(this.useDecorators=!0,this.decorators.prepend(["var decorators = container.decorators, ",this.lookupPropertyFunctionVarDeclaration(),`;
|
||||
`]),this.decorators.push("return fn;"),s?this.decorators=Function.apply(this,["fn","props","container","depth0","data","blockParams","depths",this.decorators.merge()]):(this.decorators.prepend(`function(fn, props, container, depth0, data, blockParams, depths) {
|
||||
`),this.decorators.push(`}
|
||||
`),this.decorators=this.decorators.merge()));var A=this.createFunctionContext(s);if(this.isChild)return A;var u={compiler:this.compilerInfo(),main:A};this.decorators&&(u.main_d=this.decorators,u.useDecorators=!0);var d=this.context,m=d.programs,p=d.decorators;for(c=0,l=m.length;c<l;c++)u[c]=m[c],p[c]&&(u[c+"_d"]=p[c],u.useDecorators=!0);return this.environment.usePartial&&(u.usePartial=!0),this.options.data&&(u.useData=!0),this.useDepths&&(u.useDepths=!0),this.useBlockParams&&(u.useBlockParams=!0),this.options.compat&&(u.compat=!0),s?u.compilerOptions=this.options:(u.compiler=JSON.stringify(u.compiler),this.source.currentLocation={start:{line:1,column:0}},u=this.objectLiteral(u),r.srcName?(u=u.toStringWithSourceMap({file:r.destName}),u.map=u.map&&u.map.toString()):u=u.toString()),u},preamble:function(){this.lastContext=0,this.source=new e5.default(this.options.srcName),this.decorators=new e5.default(this.options.srcName)},createFunctionContext:function(e){var r=this,n="",s=this.stackVars.concat(this.registers.list);s.length>0&&(n+=", "+s.join(", "));var i=0;Object.keys(this.aliases).forEach(function(c){var l=r.aliases[c];l.children&&l.referenceCount>1&&(n+=", alias"+ ++i+"="+c,l.children[0]="alias"+i)}),this.lookupPropertyFunctionIsUsed&&(n+=", "+this.lookupPropertyFunctionVarDeclaration());var o=["container","depth0","helpers","partials","data"];(this.useBlockParams||this.useDepths)&&o.push("blockParams"),this.useDepths&&o.push("depths");var a=this.mergeSource(n);return e?(o.push(a),Function.apply(this,o)):this.source.wrap(["function(",o.join(","),`) {
|
||||
`),this.decorators=this.decorators.merge()));var A=this.createFunctionContext(s);if(this.isChild)return A;var u={compiler:this.compilerInfo(),main:A};this.decorators&&(u.main_d=this.decorators,u.useDecorators=!0);var d=this.context,m=d.programs,p=d.decorators;for(c=0,l=m.length;c<l;c++)u[c]=m[c],p[c]&&(u[c+"_d"]=p[c],u.useDecorators=!0);return this.environment.usePartial&&(u.usePartial=!0),this.options.data&&(u.useData=!0),this.useDepths&&(u.useDepths=!0),this.useBlockParams&&(u.useBlockParams=!0),this.options.compat&&(u.compat=!0),s?u.compilerOptions=this.options:(u.compiler=JSON.stringify(u.compiler),this.source.currentLocation={start:{line:1,column:0}},u=this.objectLiteral(u),r.srcName?(u=u.toStringWithSourceMap({file:r.destName}),u.map=u.map&&u.map.toString()):u=u.toString()),u},preamble:function(){this.lastContext=0,this.source=new T$.default(this.options.srcName),this.decorators=new T$.default(this.options.srcName)},createFunctionContext:function(e){var r=this,n="",s=this.stackVars.concat(this.registers.list);s.length>0&&(n+=", "+s.join(", "));var i=0;Object.keys(this.aliases).forEach(function(c){var l=r.aliases[c];l.children&&l.referenceCount>1&&(n+=", alias"+ ++i+"="+c,l.children[0]="alias"+i)}),this.lookupPropertyFunctionIsUsed&&(n+=", "+this.lookupPropertyFunctionVarDeclaration());var o=["container","depth0","helpers","partials","data"];(this.useBlockParams||this.useDepths)&&o.push("blockParams"),this.useDepths&&o.push("depths");var a=this.mergeSource(n);return e?(o.push(a),Function.apply(this,o)):this.source.wrap(["function(",o.join(","),`) {
|
||||
`,a,"}"])},mergeSource:function(e){var r=this.environment.isSimple,n=!this.forceBuffer,s=void 0,i=void 0,o=void 0,a=void 0;return this.source.each(function(c){c.appendToBuffer?(o?c.prepend(" + "):o=c,a=c):(o&&(i?o.prepend("buffer += "):s=!0,a.add(";"),o=a=void 0),i=!0,r||(n=!1))}),n?o?(o.prepend("return "),a.add(";")):i||this.source.push('return "";'):(e+=", buffer = "+(s?"":this.initializeBuffer()),o?(o.prepend("return buffer + "),a.add(";")):this.source.push("return buffer;")),e&&this.source.prepend("var "+e.substring(2)+(s?"":`;
|
||||
`)),this.source.merge()},lookupPropertyFunctionVarDeclaration:function(){return`
|
||||
lookupProperty = container.lookupProperty || function(parent, propertyName) {
|
||||
@@ -86,49 +86,49 @@ Expecting `+de.join(", ")+", got '"+(this.terminals_[I]||I)+"'":At="Parse error
|
||||
}
|
||||
return undefined
|
||||
}
|
||||
`.trim()},blockValue:function(e){var r=this.aliasable("container.hooks.blockHelperMissing"),n=[this.contextName(0)];this.setupHelperArgs(e,0,n);var s=this.popStack();n.splice(1,0,s),this.push(this.source.functionCall(r,"call",n))},ambiguousBlockValue:function(){var e=this.aliasable("container.hooks.blockHelperMissing"),r=[this.contextName(0)];this.setupHelperArgs("",0,r,!0),this.flushInline();var n=this.topStack();r.splice(1,0,n),this.pushSource(["if (!",this.lastHelper,") { ",n," = ",this.source.functionCall(e,"call",r),"}"])},appendContent:function(e){this.pendingContent?e=this.pendingContent+e:this.pendingLocation=this.source.currentLocation,this.pendingContent=e},append:function(){if(this.isInline())this.replaceStack(function(r){return[" != null ? ",r,' : ""']}),this.pushSource(this.appendToBuffer(this.popStack()));else{var e=this.popStack();this.pushSource(["if (",e," != null) { ",this.appendToBuffer(e,void 0,!0)," }"]),this.environment.isSimple&&this.pushSource(["else { ",this.appendToBuffer("''",void 0,!0)," }"])}},appendEscaped:function(){this.pushSource(this.appendToBuffer([this.aliasable("container.escapeExpression"),"(",this.popStack(),")"]))},getContext:function(e){this.lastContext=e},pushContext:function(){this.pushStackLiteral(this.contextName(this.lastContext))},lookupOnContext:function(e,r,n,s){var i=0;!s&&this.options.compat&&!this.lastContext?this.push(this.depthedLookup(e[i++])):this.pushContext(),this.resolvePath("context",e,i,r,n)},lookupBlockParam:function(e,r){this.useBlockParams=!0,this.push(["blockParams[",e[0],"][",e[1],"]"]),this.resolvePath("context",r,1)},lookupData:function(e,r,n){e?this.pushStackLiteral("container.data(data, "+e+")"):this.pushStackLiteral("data"),this.resolvePath("data",r,0,!0,n)},resolvePath:function(e,r,n,s,i){var o=this;if(this.options.strict||this.options.assumeObjects){this.push(Ybe(this.options.strict&&i,this,r,n,e));return}for(var a=r.length,c=function(A){o.replaceStack(function(u){var d=o.nameLookup(u,r[A],e);return s?[" && ",d]:[" != null ? ",d," : ",u]})},l=n;l<a;l++)c(l)},resolvePossibleLambda:function(){this.push([this.aliasable("container.lambda"),"(",this.popStack(),", ",this.contextName(0),")"])},pushStringParam:function(e,r){this.pushContext(),this.pushString(r),r!=="SubExpression"&&(typeof e=="string"?this.pushString(e):this.pushStackLiteral(e))},emptyHash:function(e){this.trackIds&&this.push("{}"),this.stringParams&&(this.push("{}"),this.push("{}")),this.pushStackLiteral(e?"undefined":"{}")},pushHash:function(){this.hash&&this.hashes.push(this.hash),this.hash={values:{},types:[],contexts:[],ids:[]}},popHash:function(){var e=this.hash;this.hash=this.hashes.pop(),this.trackIds&&this.push(this.objectLiteral(e.ids)),this.stringParams&&(this.push(this.objectLiteral(e.contexts)),this.push(this.objectLiteral(e.types))),this.push(this.objectLiteral(e.values))},pushString:function(e){this.pushStackLiteral(this.quotedString(e))},pushLiteral:function(e){this.pushStackLiteral(e)},pushProgram:function(e){e!=null?this.pushStackLiteral(this.programExpression(e)):this.pushStackLiteral(null)},registerDecorator:function(e,r){var n=this.nameLookup("decorators",r,"decorator"),s=this.setupHelperArgs(r,e);this.decorators.push(["var decorator = ",n,";"]),this.decorators.push(['if (typeof decorator !== "function") { throw new Error(',this.quotedString('Missing decorator: "'+r+'"'),"); }"]),this.decorators.push(["fn = ",this.decorators.functionCall("decorator","",["fn","props","container",s])," || fn;"])},invokeHelper:function(e,r,n){var s=this.popStack(),i=this.setupHelper(e,r),o=[];n&&o.push(i.name),o.push(s),this.options.strict||o.push(this.aliasable("container.hooks.helperMissing"));var a=["(",this.itemsSeparatedBy(o,"||"),")"],c=this.source.functionCall(a,"call",i.callParams);this.push(c)},itemsSeparatedBy:function(e,r){var n=[];n.push(e[0]);for(var s=1;s<e.length;s++)n.push(r,e[s]);return n},invokeKnownHelper:function(e,r){var n=this.setupHelper(e,r);this.push(this.source.functionCall(n.name,"call",n.callParams))},invokeAmbiguous:function(e,r){this.useRegister("helper");var n=this.popStack();this.emptyHash();var s=this.setupHelper(0,e,r),i=this.lastHelper=this.nameLookup("helpers",e,"helper"),o=["(","(helper = ",i," || ",n,")"];this.options.strict||(o[0]="(helper = ",o.push(" != null ? helper : ",this.aliasable("container.hooks.helperMissing"))),this.push(["(",o,s.paramsInit?["),(",s.paramsInit]:[],"),","(typeof helper === ",this.aliasable('"function"')," ? ",this.source.functionCall("helper","call",s.callParams)," : helper))"])},invokePartial:function(e,r,n){var s=[],i=this.setupParams(r,1,s);e&&(r=this.popStack(),delete i.name),n&&(i.indent=JSON.stringify(n)),i.helpers="helpers",i.partials="partials",i.decorators="container.decorators",e?s.unshift(r):s.unshift(this.nameLookup("partials",r,"partial")),this.options.compat&&(i.depths="depths"),i=this.objectLiteral(i),s.push(i),this.push(this.source.functionCall("container.invokePartial","",s))},assignToHash
Line truncated
|
||||
`,e};et.prototype.Program=function(t){var e="",r=t.body,n=void 0,s=void 0;if(t.blockParams){var i="BLOCK PARAMS: [";for(n=0,s=t.blockParams.length;n<s;n++)i+=" "+t.blockParams[n];i+=" ]",e+=this.pad(i)}for(n=0,s=r.length;n<s;n++)e+=this.accept(r[n]);return this.padding--,e};et.prototype.MustacheStatement=function(t){return this.pad("{{ "+this.SubExpression(t)+" }}")};et.prototype.Decorator=function(t){return this.pad("{{ DIRECTIVE "+this.SubExpression(t)+" }}")};et.prototype.BlockStatement=et.prototype.DecoratorBlock=function(t){var e="";return e+=this.pad((t.type==="DecoratorBlock"?"DIRECTIVE ":"")+"BLOCK:"),this.padding++,e+=this.pad(this.SubExpression(t)),t.program&&(e+=this.pad("PROGRAM:"),this.padding++,e+=this.accept(t.program),this.padding--),t.inverse&&(t.program&&this.padding++,e+=this.pad("{{^}}"),this.padding++,e+=this.accept(t.inverse),this.padding--,t.program&&this.padding--),this.padding--,e};et.prototype.PartialStatement=function(t){var e="PARTIAL:"+t.name.original;return t.params[0]&&(e+=" "+this.accept(t.params[0])),t.hash&&(e+=" "+this.accept(t.hash)),this.pad("{{> "+e+" }}")};et.prototype.PartialBlockStatement=function(t){var e="PARTIAL BLOCK:"+t.name.original;return t.params[0]&&(e+=" "+this.accept(t.params[0])),t.hash&&(e+=" "+this.accept(t.hash)),e+=" "+this.pad("PROGRAM:"),this.padding++,e+=this.accept(t.program),this.padding--,this.pad("{{> "+e+" }}")};et.prototype.ContentStatement=function(t){return this.pad("CONTENT[ '"+t.value+"' ]")};et.prototype.CommentStatement=function(t){return this.pad("{{! '"+t.value+"' }}")};et.prototype.SubExpression=function(t){for(var e=t.params,r=[],n=void 0,s=0,i=e.length;s<i;s++)r.push(this.accept(e[s]));return e="["+r.join(", ")+"]",n=t.hash?" "+this.accept(t.hash):"",this.accept(t.path)+" "+e+n};et.prototype.PathExpression=function(t){var e=t.parts.join("/");return(t.data?"@":"")+"PATH:"+e};et.prototype.StringLiteral=function(t){return'"'+t.value+'"'};et.prototype.NumberLiteral=function(t){return"NUMBER{"+t.value+"}"};et.prototype.BooleanLiteral=function(t){return"BOOLEAN{"+t.value+"}"};et.prototype.UndefinedLiteral=function(){return"UNDEFINED"};et.prototype.NullLiteral=function(){return"NULL"};et.prototype.Hash=function(t){for(var e=t.pairs,r=[],n=0,s=e.length;n<s;n++)r.push(this.accept(e[n]));return"HASH{"+r.join(", ")+"}"};et.prototype.HashPair=function(t){return t.key+"="+this.accept(t.value)}});var u5=h((N4e,A5)=>{var _C=o5().default,l5=a5();_C.PrintVisitor=l5.PrintVisitor;_C.print=l5.print;A5.exports=_C;function c5(t,e){var r=require("fs"),n=r.readFileSync(e,"utf8");t.exports=_C.compile(n)}typeof require<"u"&&require.extensions&&(require.extensions[".handlebars"]=c5,require.extensions[".hbs"]=c5)});var FD=B(require("os"),1);function Ui(t){return t==null?"":typeof t=="string"||t instanceof String?t:JSON.stringify(t)}function Om(t,e,r){let n=new OC(t,e,r);process.stdout.write(n.toString()+FD.EOL)}function qC(t,e=""){Om(t,{},e)}var _D="::",OC=class{constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){let e=_D+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(let n in this.properties)if(this.properties.hasOwnProperty(n)){let s=this.properties[n];s&&(r?r=!1:e+=",",e+=`${n}=${P5(s)}`)}}return e+=`${_D}${R5(this.message)}`,e}};function R5(t){return Ui(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function P5(t){return Ui(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}var UD=B(require("crypto"),1),Hm=B(require("fs"),1),qm=B(require("os"),1);function OD(t,e){let r=process.env[`GITHUB_${t}`];if(!r)throw new Error(`Unable to find environment variable for file command ${t}`);if(!Hm.existsSync(r))throw new Error(`Missing file at path: ${r}`);Hm.appendFileSync(r,`${Ui(e)}${qm.EOL}`,{encoding:"utf8"})}function qD(t,e){let r=`ghadelimiter_${UD.randomUUID()}`,n=Ui(e);if(t.includes(r))throw new Error(`Unexpected input: name should not contain the delimiter "${r}"`);if(n.includes(r))throw new Error(`Unexpected input: value should not contain the delimiter "${r}"`);return`${t}<<${r}${qm.EOL}${n}${qm.EOL}${r}`}var Bx=B(require("os"),1);var Fh=B(QA(),1),Yie=B(Qu(),1);var As;(function(t){t[t.OK=200]="OK",t[t.MultipleChoices=300]="MultipleChoices",t[t.MovedPermanently=301]="MovedPermanently",t[t.ResourceMoved=302]="ResourceMoved",t[t.SeeOther=303]="SeeOther",t[t.NotModified=304]="NotModified",t[t.UseProxy=305]="UseProxy",t[t.SwitchProxy=306]="SwitchProxy",t[t.TemporaryRedirect=307]="TemporaryRedirect",t[t.PermanentRedirect=308]="PermanentRedirect",t[t.BadRequest=400]="BadRequest",t[t.Unauthorized=401]="Unauthorized",t[t.PaymentRequired=402]="PaymentRequired",t[t.Forbidden=403]="Forbidden",t[t.NotFound=404]="NotFound",t[t.MethodNotAllowed=405]="MethodNotAllowed",t[t.NotAcceptable=406]="NotAcceptable",t[t.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",t[t.RequestTimeout=408]="RequestTi
Line truncated
|
||||
Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}function O1(t,e){if(process.env.GITHUB_OUTPUT||"")return OD("OUTPUT",qD(t,e));process.stdout.write(Bx.EOL),Om("set-output",{name:t},Ui(e))}function Pe(t){Om("debug",{},t)}function zh(t){process.stdout.write(t+Bx.EOL)}function soe(t){qC("group",t)}function ioe(){qC("endgroup")}function ao(t,e){return noe(this,void 0,void 0,function*(){soe(t);let r;try{r=yield e()}finally{ioe()}return r})}var H1=B(require("os"),1);function co(t){return t==null?"":typeof t=="string"||t instanceof String?t:JSON.stringify(t)}function wx(t){return Object.keys(t).length?{title:t.title,file:t.file,line:t.startLine,endLine:t.endLine,col:t.startColumn,endColumn:t.endColumn}:{}}function rl(t,e,r){let n=new bx(t,e,r);process.stdout.write(n.toString()+H1.EOL)}function Nx(t,e=""){rl(t,{},e)}var q1="::",bx=class{constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){let e=q1+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(let n in this.properties)if(this.properties.hasOwnProperty(n)){let s=this.properties[n];s&&(r?r=!1:e+=",",e+=`${n}=${aoe(s)}`)}}return e+=`${q1}${ooe(this.message)}`,e}};function ooe(t){return co(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function aoe(t){return co(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}var z1=B(require("crypto"),1),Yh=B(require("fs"),1),Gh=B(require("os"),1);function G1(t,e){let r=process.env[`GITHUB_${t}`];if(!r)throw new Error(`Unable to find environment variable for file command ${t}`);if(!Yh.existsSync(r))throw new Error(`Missing file at path: ${r}`);Yh.appendFileSync(r,`${co(e)}${Gh.EOL}`,{encoding:"utf8"})}function Y1(t,e){let r=`ghadelimiter_${z1.randomUUID()}`,n=co(e);if(t.includes(r))throw new Error(`Unexpected input: name should not contain the delimiter "${r}"`);if(n.includes(r))throw new Error(`Unexpected input: value should not contain the delimiter "${r}"`);return`${t}<<${r}${Gh.EOL}${n}${Gh.EOL}${r}`}var j1=B(require("os"),1);var Vh=B(QA(),1),loe=B(Qu(),1);var ds;(function(t){t[t.OK=200]="OK",t[t.MultipleChoices=300]="MultipleChoices",t[t.MovedPermanently=301]="MovedPermanently",t[t.ResourceMoved=302]="ResourceMoved",t[t.SeeOther=303]="SeeOther",t[t.NotModified=304]="NotModified",t[t.UseProxy=305]="UseProxy",t[t.SwitchProxy=306]="SwitchProxy",t[t.TemporaryRedirect=307]="TemporaryRedirect",t[t.PermanentRedirect=308]="PermanentRedirect",t[t.BadRequest=400]="BadRequest",t[t.Unauthorized=401]="Unauthorized",t[t.PaymentRequired=402]="PaymentRequired",t[t.Forbidden=403]="Forbidden",t[t.NotFound=404]="NotFound",t[t.MethodNotAllowed=405]="MethodNotAllowed",t[t.NotAcceptable=406]="NotAcceptable",t[t.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",t[t.RequestTimeout=408]="RequestTimeout",t[t.Conflict=409]="Conflict",t[t.Gone=410]="Gone",t[t.TooManyRequests=429]="TooManyRequests",t[t.InternalServerError=500]="InternalServerError",t[t.NotImplemented=501]="NotImplemented",t[t.BadGateway=502]="BadGateway",t[t.ServiceUnavailable=503]="ServiceUnavailable",t[t.GatewayTimeout=504]="GatewayTimeout"})(ds||(ds={}));var V1;(function(t){t.Accept="accept",t.ContentType="content-type"})(V1||(V1={}));var J1;(function(t){t.ApplicationJson="application/json"})(J1||(J1={}));var sRe=[ds.MovedPermanently,ds.ResourceMoved,ds.SeeOther,ds.TemporaryRedirect,ds.PermanentRedirect],iRe=[ds.BadGateway,ds.ServiceUnavailable,ds.GatewayTimeout];var $1=require("os"),Ru=require("fs"),Sx=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},{access:Aoe,appendFile:uoe,writeFile:doe}=Ru.promises,W1="GITHUB_STEP_SUMMARY";var Rx=class{constructor(){this._buffer=""}filePath(){return Sx(this,void 0,void 0,function*(){if(this._filePath)return this._filePath;let e=process.env[W1];if(!e)throw new Error(`Unable to find environment variable for $${W1}. Check if your runtime environment supports job summaries.`);try{yield Aoe(e,Ru.constants.R_OK|Ru.constants.W_OK)}catch{throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}return this._filePath=e,this._filePath})}wrap(e,r,n={}){let s=Object.entries(n).map(([i,o])=>` ${i}="${o}"`).join("");return r?`<${e}${s}>${r}</${e}>`:`<${e}${s}>`}write(e){return Sx(this,void 0,void 0,function*(){let r=!!e?.overwrite,n=yield this.filePath();return yield(r?doe:uoe)(n,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){return Sx(this,void 0,void 0,function*(){return this.emptyBuffer().write({overwrite:!0})})}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){return this._buffer="",this}addRaw(Line truncated
|
||||
`.trim()},blockValue:function(e){var r=this.aliasable("container.hooks.blockHelperMissing"),n=[this.contextName(0)];this.setupHelperArgs(e,0,n);var s=this.popStack();n.splice(1,0,s),this.push(this.source.functionCall(r,"call",n))},ambiguousBlockValue:function(){var e=this.aliasable("container.hooks.blockHelperMissing"),r=[this.contextName(0)];this.setupHelperArgs("",0,r,!0),this.flushInline();var n=this.topStack();r.splice(1,0,n),this.pushSource(["if (!",this.lastHelper,") { ",n," = ",this.source.functionCall(e,"call",r),"}"])},appendContent:function(e){this.pendingContent?e=this.pendingContent+e:this.pendingLocation=this.source.currentLocation,this.pendingContent=e},append:function(){if(this.isInline())this.replaceStack(function(r){return[" != null ? ",r,' : ""']}),this.pushSource(this.appendToBuffer(this.popStack()));else{var e=this.popStack();this.pushSource(["if (",e," != null) { ",this.appendToBuffer(e,void 0,!0)," }"]),this.environment.isSimple&&this.pushSource(["else { ",this.appendToBuffer("''",void 0,!0)," }"])}},appendEscaped:function(){this.pushSource(this.appendToBuffer([this.aliasable("container.escapeExpression"),"(",this.popStack(),")"]))},getContext:function(e){this.lastContext=e},pushContext:function(){this.pushStackLiteral(this.contextName(this.lastContext))},lookupOnContext:function(e,r,n,s){var i=0;!s&&this.options.compat&&!this.lastContext?this.push(this.depthedLookup(e[i++])):this.pushContext(),this.resolvePath("context",e,i,r,n)},lookupBlockParam:function(e,r){this.useBlockParams=!0,this.push(["blockParams[",e[0],"][",e[1],"]"]),this.resolvePath("context",r,1)},lookupData:function(e,r,n){e?this.pushStackLiteral("container.data(data, "+e+")"):this.pushStackLiteral("data"),this.resolvePath("data",r,0,!0,n)},resolvePath:function(e,r,n,s,i){var o=this;if(this.options.strict||this.options.assumeObjects){this.push(fwe(this.options.strict&&i,this,r,n,e));return}for(var a=r.length,c=function(A){o.replaceStack(function(u){var d=o.nameLookup(u,r[A],e);return s?[" && ",d]:[" != null ? ",d," : ",u]})},l=n;l<a;l++)c(l)},resolvePossibleLambda:function(){this.push([this.aliasable("container.lambda"),"(",this.popStack(),", ",this.contextName(0),")"])},pushStringParam:function(e,r){this.pushContext(),this.pushString(r),r!=="SubExpression"&&(typeof e=="string"?this.pushString(e):this.pushStackLiteral(e))},emptyHash:function(e){this.trackIds&&this.push("{}"),this.stringParams&&(this.push("{}"),this.push("{}")),this.pushStackLiteral(e?"undefined":"{}")},pushHash:function(){this.hash&&this.hashes.push(this.hash),this.hash={values:{},types:[],contexts:[],ids:[]}},popHash:function(){var e=this.hash;this.hash=this.hashes.pop(),this.trackIds&&this.push(this.objectLiteral(e.ids)),this.stringParams&&(this.push(this.objectLiteral(e.contexts)),this.push(this.objectLiteral(e.types))),this.push(this.objectLiteral(e.values))},pushString:function(e){this.pushStackLiteral(this.quotedString(e))},pushLiteral:function(e){this.pushStackLiteral(e)},pushProgram:function(e){e!=null?this.pushStackLiteral(this.programExpression(e)):this.pushStackLiteral(null)},registerDecorator:function(e,r){var n=this.nameLookup("decorators",r,"decorator"),s=this.setupHelperArgs(r,e);this.decorators.push(["var decorator = ",n,";"]),this.decorators.push(['if (typeof decorator !== "function") { throw new Error(',this.quotedString('Missing decorator: "'+r+'"'),"); }"]),this.decorators.push(["fn = ",this.decorators.functionCall("decorator","",["fn","props","container",s])," || fn;"])},invokeHelper:function(e,r,n){var s=this.popStack(),i=this.setupHelper(e,r),o=[];n&&o.push(i.name),o.push(s),this.options.strict||o.push(this.aliasable("container.hooks.helperMissing"));var a=["(",this.itemsSeparatedBy(o,"||"),")"],c=this.source.functionCall(a,"call",i.callParams);this.push(c)},itemsSeparatedBy:function(e,r){var n=[];n.push(e[0]);for(var s=1;s<e.length;s++)n.push(r,e[s]);return n},invokeKnownHelper:function(e,r){var n=this.setupHelper(e,r);this.push(this.source.functionCall(n.name,"call",n.callParams))},invokeAmbiguous:function(e,r){this.useRegister("helper");var n=this.popStack();this.emptyHash();var s=this.setupHelper(0,e,r),i=this.lastHelper=this.nameLookup("helpers",e,"helper"),o=["(","(helper = ",i," || ",n,")"];this.options.strict||(o[0]="(helper = ",o.push(" != null ? helper : ",this.aliasable("container.hooks.helperMissing"))),this.push(["(",o,s.paramsInit?["),(",s.paramsInit]:[],"),","(typeof helper === ",this.aliasable('"function"')," ? ",this.source.functionCall("helper","call",s.callParams)," : helper))"])},invokePartial:function(e,r,n){var s=[],i=this.setupParams(r,1,s);e&&(r=this.popStack(),delete i.name),n&&(i.indent=JSON.stringify(n)),i.helpers="helpers",i.partials="partials",i.decorators="container.decorators",e?s.unshift(r):s.unshift(this.nameLookup("partials",r,"partial")),this.options.compat&&(i.depths="depths"),i=this.objectLiteral(i),s.push(i),this.push(this.source.functionCall("container.invokePartial","",s))},assignToHash
Line truncated
|
||||
`,e};et.prototype.Program=function(t){var e="",r=t.body,n=void 0,s=void 0;if(t.blockParams){var i="BLOCK PARAMS: [";for(n=0,s=t.blockParams.length;n<s;n++)i+=" "+t.blockParams[n];i+=" ]",e+=this.pad(i)}for(n=0,s=r.length;n<s;n++)e+=this.accept(r[n]);return this.padding--,e};et.prototype.MustacheStatement=function(t){return this.pad("{{ "+this.SubExpression(t)+" }}")};et.prototype.Decorator=function(t){return this.pad("{{ DIRECTIVE "+this.SubExpression(t)+" }}")};et.prototype.BlockStatement=et.prototype.DecoratorBlock=function(t){var e="";return e+=this.pad((t.type==="DecoratorBlock"?"DIRECTIVE ":"")+"BLOCK:"),this.padding++,e+=this.pad(this.SubExpression(t)),t.program&&(e+=this.pad("PROGRAM:"),this.padding++,e+=this.accept(t.program),this.padding--),t.inverse&&(t.program&&this.padding++,e+=this.pad("{{^}}"),this.padding++,e+=this.accept(t.inverse),this.padding--,t.program&&this.padding--),this.padding--,e};et.prototype.PartialStatement=function(t){var e="PARTIAL:"+t.name.original;return t.params[0]&&(e+=" "+this.accept(t.params[0])),t.hash&&(e+=" "+this.accept(t.hash)),this.pad("{{> "+e+" }}")};et.prototype.PartialBlockStatement=function(t){var e="PARTIAL BLOCK:"+t.name.original;return t.params[0]&&(e+=" "+this.accept(t.params[0])),t.hash&&(e+=" "+this.accept(t.hash)),e+=" "+this.pad("PROGRAM:"),this.padding++,e+=this.accept(t.program),this.padding--,this.pad("{{> "+e+" }}")};et.prototype.ContentStatement=function(t){return this.pad("CONTENT[ '"+t.value+"' ]")};et.prototype.CommentStatement=function(t){return this.pad("{{! '"+t.value+"' }}")};et.prototype.SubExpression=function(t){for(var e=t.params,r=[],n=void 0,s=0,i=e.length;s<i;s++)r.push(this.accept(e[s]));return e="["+r.join(", ")+"]",n=t.hash?" "+this.accept(t.hash):"",this.accept(t.path)+" "+e+n};et.prototype.PathExpression=function(t){var e=t.parts.join("/");return(t.data?"@":"")+"PATH:"+e};et.prototype.StringLiteral=function(t){return'"'+t.value+'"'};et.prototype.NumberLiteral=function(t){return"NUMBER{"+t.value+"}"};et.prototype.BooleanLiteral=function(t){return"BOOLEAN{"+t.value+"}"};et.prototype.UndefinedLiteral=function(){return"UNDEFINED"};et.prototype.NullLiteral=function(){return"NULL"};et.prototype.Hash=function(t){for(var e=t.pairs,r=[],n=0,s=e.length;n<s;n++)r.push(this.accept(e[n]));return"HASH{"+r.join(", ")+"}"};et.prototype.HashPair=function(t){return t.key+"="+this.accept(t.value)}});var Y$=h((z3e,G$)=>{var QC=O$().default,z$=q$();QC.PrintVisitor=z$.PrintVisitor;QC.print=z$.print;G$.exports=QC;function H$(t,e){var r=require("fs"),n=r.readFileSync(e,"utf8");t.exports=QC.compile(n)}typeof require<"u"&&require.extensions&&(require.extensions[".handlebars"]=H$,require.extensions[".hbs"]=H$)});var wD=B(require("os"),1);function ei(t){return t==null?"":typeof t=="string"||t instanceof String?t:JSON.stringify(t)}function wC(t){return Object.keys(t).length?{title:t.title,file:t.file,line:t.startLine,endLine:t.endLine,col:t.startColumn,endColumn:t.endColumn}:{}}function Ui(t,e,r){let n=new NC(t,e,r);process.stdout.write(n.toString()+wD.EOL)}function SC(t,e=""){Ui(t,{},e)}var bD="::",NC=class{constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){let e=bD+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(let n in this.properties)if(this.properties.hasOwnProperty(n)){let s=this.properties[n];s&&(r?r=!1:e+=",",e+=`${n}=${A5(s)}`)}}return e+=`${bD}${l5(this.message)}`,e}};function l5(t){return ei(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function A5(t){return ei(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}var ND=B(require("crypto"),1),km=B(require("fs"),1),Dm=B(require("os"),1);function RC(t,e){let r=process.env[`GITHUB_${t}`];if(!r)throw new Error(`Unable to find environment variable for file command ${t}`);if(!km.existsSync(r))throw new Error(`Missing file at path: ${r}`);km.appendFileSync(r,`${ei(e)}${Dm.EOL}`,{encoding:"utf8"})}function PC(t,e){let r=`ghadelimiter_${ND.randomUUID()}`,n=ei(e);if(t.includes(r))throw new Error(`Unexpected input: name should not contain the delimiter "${r}"`);if(n.includes(r))throw new Error(`Unexpected input: value should not contain the delimiter "${r}"`);return`${t}<<${r}${Dm.EOL}${n}${Dm.EOL}${r}`}var hx=B(require("os"),1);var Rh=B(kC(),1),bie=B(ex(),1);var As;(function(t){t[t.OK=200]="OK",t[t.MultipleChoices=300]="MultipleChoices",t[t.MovedPermanently=301]="MovedPermanently",t[t.ResourceMoved=302]="ResourceMoved",t[t.SeeOther=303]="SeeOther",t[t.NotModified=304]="NotModified",t[t.UseProxy=305]="UseProxy",t[t.SwitchProxy=306]="SwitchProxy",t[t.TemporaryRedirect=307]="TemporaryRedirect",t[t.PermanentRedirect=308]="PermanentRedirect",t[t.BadRequest=400]="BadRequest",t[t.Unauthorized=401]="Unauthorized",t[t.PaymentRequired=402]="PaymentRequired",t[t.Forbidden=403]="Forbidden",t[t.NotFound=404]="NotFound",t[t.MethodNotAllowed=405]="MethodNo
Line truncated
|
||||
Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}function w1(t,e){if(process.env.GITHUB_OUTPUT||"")return RC("OUTPUT",PC(t,e));process.stdout.write(hx.EOL),Ui("set-output",{name:t},ei(e))}function N1(t){process.exitCode=px.Failure,Zc(t)}function aa(){return process.env.RUNNER_DEBUG==="1"}function x(t){Ui("debug",{},t)}function Zc(t,e={}){Ui("error",wC(e),t instanceof Error?t.toString():t)}function ht(t,e={}){Ui("warning",wC(e),t instanceof Error?t.toString():t)}function pe(t){process.stdout.write(t+hx.EOL)}function Fie(t){SC("group",t)}function _ie(){SC("endgroup")}function ds(t,e){return Lie(this,void 0,void 0,function*(){Fie(t);let r;try{r=yield e()}finally{_ie()}return r})}function Th(t,e){if(process.env.GITHUB_STATE||"")return RC("STATE",PC(t,e));Ui("save-state",{name:t},ei(e))}function S1(t){return process.env[`STATE_${t}`]||""}var FE=B(require("fs"),1),Cv=B(require("os"),1),Iv=B(require("path"),1);var P1=B(require("os"),1);function Qu(t){return t==null?"":typeof t=="string"||t instanceof String?t:JSON.stringify(t)}function v1(t,e,r){let n=new gx(t,e,r);process.stdout.write(n.toString()+P1.EOL)}var R1="::",gx=class{constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){let e=R1+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(let n in this.properties)if(this.properties.hasOwnProperty(n)){let s=this.properties[n];s&&(r?r=!1:e+=",",e+=`${n}=${Oie(s)}`)}}return e+=`${R1}${Uie(this.message)}`,e}};function Uie(t){return Qu(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function Oie(t){return Qu(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}var k1=require("os"),xu=require("fs"),yx=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},{access:qie,appendFile:Hie,writeFile:zie}=xu.promises,D1="GITHUB_STEP_SUMMARY";var Ex=class{constructor(){this._buffer=""}filePath(){return yx(this,void 0,void 0,function*(){if(this._filePath)return this._filePath;let e=process.env[D1];if(!e)throw new Error(`Unable to find environment variable for $${D1}. Check if your runtime environment supports job summaries.`);try{yield qie(e,xu.constants.R_OK|xu.constants.W_OK)}catch{throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}return this._filePath=e,this._filePath})}wrap(e,r,n={}){let s=Object.entries(n).map(([i,o])=>` ${i}="${o}"`).join("");return r?`<${e}${s}>${r}</${e}>`:`<${e}${s}>`}write(e){return yx(this,void 0,void 0,function*(){let r=!!e?.overwrite,n=yield this.filePath();return yield(r?zie:Hie)(n,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){return yx(this,void 0,void 0,function*(){return this.emptyBuffer().write({overwrite:!0})})}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){return this._buffer="",this}addRaw(e,r=!1){return this._buffer+=e,r?this.addEOL():this}addEOL(){return this.addRaw(k1.EOL)}addCodeBlock(e,r){let n=Object.assign({},r&&{lang:r}),s=this.wrap("pre",this.wrap("code",e),n);return this.addRaw(s).addEOL()}addList(e,r=!1){let n=r?"ol":"ul",s=e.map(o=>this.wrap("li",o)).join(""),i=this.wrap(n,s);return this.addRaw(i).addEOL()}addTable(e){let r=e.map(s=>{let i=s.map(o=>{if(typeof o=="string")return this.wrap("td",o);let{header:a,data:c,colspan:l,rowspan:A}=o,u=a?"th":"td",d=Object.assign(Object.assign({},l&&{colspan:l}),A&&{rowspan:A});return this.wrap(u,c,d)}).join("");return this.wrap("tr",i)}).join(""),n=this.wrap("table",r);return this.addRaw(n).addEOL()}addDetails(e,r){let n=this.wrap("details",this.wrap("summary",e)+r);return this.addRaw(n).addEOL()}addImage(e,r,n){let{width:s,height:i}=n||{},o=Object.assign(Object.assign({},s&&{width:s}),i&&{height:i}),a=this.wrap("img",null,Object.assign({src:e,alt:r},o));return this.addRaw(a).addEOL()}addHeading(e,r){let n=`h${r}`,s=["h1","h2","h3","h4","h5","h6"].includes(n)?n:"h1",i=this.wrap(s,e);return this.addRaw(i).addEOL()}addSeparator(){let e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){let e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,r){let n=Object.assign({},r&&{cite:r}),s=this.wrap("blockquote",e,n);return this.addRaw(s).addEOL()}addLink(e,r){let n=this.wrap("a",e,{href:r});return this.addRaw(n).addEOL()}},PSe=new Ex;var Cx=B(require("os"),1);var kSe=Cx.default.platform(),TSe=Cx.default.arch();var T1;(function(t){t[t.Success=0]="Success",t[t.Failure=1]="Failure"})(T1||(T1={}));function Wt(t){v1("debug",{},t)}var pr=B(require("fs"),1);var Oce=B(Ox(),1);var Jh=B(require("os"),1),ao=B(require("path"),1);var An=B(Ox(),1);var bq=require("assert");var xq=function(t,e,r,nLine truncated
|
||||
`),e=e.replace(/\r/g,`
|
||||
`));let s=e.split(`
|
||||
`).map(i=>i.trim());for(let i of s)!i||i.startsWith("#")||n.patterns.push(new Yu(i));return n.searchPaths.push(...aw(n.patterns)),n})}static stat(e,r,n){return mw(this,void 0,void 0,function*(){let s;if(r.followSymbolicLinks)try{s=yield ll.promises.stat(e.path)}catch(i){if(i.code==="ENOENT"){if(r.omitBrokenSymbolicLinks){Pe(`Broken symlink '${e.path}'`);return}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw i}else s=yield ll.promises.lstat(e.path);if(s.isDirectory()&&r.followSymbolicLinks){let i=yield ll.promises.realpath(e.path);for(;n.length>=e.level;)n.pop();if(n.some(o=>o===i)){Pe(`Symlink cycle detected for path '${e.path}' and realpath '${i}'`);return}n.push(i)}return s})}};var rAe=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};function bH(t,e){return rAe(this,void 0,void 0,function*(){return yield mf.create(t,e)})}var Rf=B(require("crypto"),1),dl=B(require("fs"),1),ga=B(require("path"),1),gG=B(hG(),1),yG=B(require("util"),1);var ed;(function(t){t.Gzip="cache.tgz",t.Zstd="cache.tzst"})(ed||(ed={}));var Xt;(function(t){t.Gzip="gzip",t.ZstdWithoutLong="zstd-without-long",t.Zstd="zstd"})(Xt||(Xt={}));var Fr;(function(t){t.GNU="gnu",t.BSD="bsd"})(Fr||(Fr={}));var Nf=2,Sf=5e3,kw=5e3,Tw=`${process.env.PROGRAMFILES}\\Git\\usr\\bin\\tar.exe`,fG=`${process.env.SYSTEMDRIVE}\\Windows\\System32\\tar.exe`,td="cache.tar",Mw="manifest.txt",xDe=10*Math.pow(1024,3);var ul=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},Zde=function(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],r;return e?e.call(t):(t=typeof __values=="function"?__values(t):t[Symbol.iterator](),r={},n("next"),n("throw"),n("return"),r[Symbol.asyncIterator]=function(){return this},r);function n(i){r[i]=t[i]&&function(o){return new Promise(function(a,c){o=t[i](o),s(a,c,o.done,o.value)})}}function s(i,o,a,c){Promise.resolve(c).then(function(l){i({value:l,done:a})},o)}},eme="1.0";function rd(){return ul(this,void 0,void 0,function*(){let t=process.platform==="win32",e=process.env.RUNNER_TEMP||"";if(!e){let n;t?n=process.env.USERPROFILE||"C:\\":process.platform==="darwin"?n="/Users":n="/home",e=ga.join(n,"actions","temp")}let r=ga.join(e,Rf.randomUUID());return yield la(r),r})}function fs(t){return dl.statSync(t).size}function Lw(t){return ul(this,void 0,void 0,function*(){var e,r,n,s,i;let o=[],a=(i=process.env.GITHUB_WORKSPACE)!==null&&i!==void 0?i:process.cwd(),c=yield bH(t.join(`
|
||||
`),{implicitDescendants:!1});try{for(var l=!0,A=Zde(c.globGenerator()),u;u=yield A.next(),e=u.done,!e;l=!0){s=u.value,l=!1;let m=ga.relative(a,s).replace(new RegExp(`\\${ga.sep}`,"g"),"/");N(`Matched: ${m}`),m===""?o.push("."):o.push(`${m}`)}}catch(d){r={error:d}}finally{try{!l&&!e&&(n=A.return)&&(yield n.call(A))}finally{if(r)throw r.error}}return o})}function nd(t){return ul(this,void 0,void 0,function*(){return yG.promisify(dl.unlink)(t)})}function EG(t){return ul(this,arguments,void 0,function*(e,r=[]){let n="";r.push("--version"),N(`Checking ${e} ${r.join(" ")}`);try{yield oo(`${e}`,r,{ignoreReturnCode:!0,silent:!0,listeners:{stdout:s=>n+=s.toString(),stderr:s=>n+=s.toString()}})}catch(s){N(s.message)}return n=n.trim(),N(n),n})}function sd(){return ul(this,void 0,void 0,function*(){let t=yield EG("zstd",["--quiet"]),e=gG.clean(t);return N(`zstd version: ${e}`),t===""?Xt.Gzip:Xt.ZstdWithoutLong})}function go(t){return t===Xt.Gzip?ed.Gzip:ed.Zstd}function CG(){return ul(this,void 0,void 0,function*(){return dl.existsSync(Tw)?Tw:(yield EG("tar")).toLowerCase().includes("gnu tar")?ur("tar"):""})}function _w(t,e){if(e===void 0)throw Error(`Expected ${t} but value was undefiend`);return e}function ml(t,e,r=!1){let n=t.slice();return e&&n.push(e),process.platform==="win32"&&!r&&n.push("windows-only"),n.push(eme),Rf.createHash("sha256").update(n.join("|")).digest("hex")}function IG(){let t=process.env.ACTIONS_RUNTIME_TOKEN;if(!t)throw new Error("Unable to get the ACTIONS_RUNTIME_TOKEN env variable");return t}var od=B(require("http"),1),Ow=B(require("https"),1);function Fw(t){let e=t.protocol==="https:";if(tme(t))return;let r=e?process.env.https_proxy||process.env.HTTPS_PROXY:process.env.http_proxy||process.env.HTTP_PROXY;if(r)try{return new vf(r)}catch{if(!r.startsWith("http://")&&!r.startsWith("https://"))return new vf(`http://${r}`)}else return}function tme(t){if(!t.hostname)return!1;let e=t.hostname;if(rme(e))return!0;let r=process.env.no_proxy||process.env.NO_PROXY||"";if(!r)return!1;let n;t.port?n=Number(t.port):t.protocol==="http:"?n=80:t.protocol==="https:"&&(n=443);let s=[t.hostname.toUpperCase()];typeof n=="number"&&s.push(`${s[0]}:${n}`);for(let i of r.split(",").map(o=>o.trim().toUpperCase()).filter(o=>o))if(i==="*"||s.some(o=>o===i||o.endsWith(`.${i}`)||i.startsWith(".")&&o.endsWith(`${i}`)))return!0;return!1}function rme(t){let e=t.toLowerCase();return e==="localhost"||e.startsWith("127.")||e.startsWith("[::1]")||e.startsWith("[0:0:0:0:0:0:0:1]")}var vf=class extends URL{constructor(e,r){super(e,r),this._decodedUsername=decodeURIComponent(super.username),this._decodedPassword=decodeURIComponent(super.password)}get username(){return this._decodedUsername}get password(){return this._decodedPassword}};var yo=B(QA(),1),BG=B(Qu(),1),st=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},Ve;(function(t){t[t.OK=200]="OK",t[t.MultipleChoices=300]="MultipleChoices",t[t.MovedPermanently=301]="MovedPermanently",t[t.ResourceMoved=302]="ResourceMoved",t[t.SeeOther=303]="SeeOther",t[t.NotModified=304]="NotModified",t[t.UseProxy=305]="UseProxy",t[t.SwitchProxy=306]="SwitchProxy",t[t.TemporaryRedirect=307]="TemporaryRedirect",t[t.PermanentRedirect=308]="PermanentRedirect",t[t.BadRequest=400]="BadRequest",t[t.Unauthorized=401]="Unauthorized",t[t.PaymentRequired=402]="PaymentRequired",t[t.Forbidden=403]="Forbidden",t[t.NotFound=404]="NotFound",t[t.MethodNotAllowed=405]="MethodNotAllowed",t[t.NotAcceptable=406]="NotAcceptable",t[t.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",t[t.RequestTimeout=408]="RequestTimeout",t[t.Conflict=409]="Conflict",t[t.Gone=410]="Gone",t[t.TooManyRequests=429]="TooManyRequests",t[t.InternalServerError=500]="InternalServerError",t[t.NotImplemented=501]="NotImplemented",t[t.BadGateway=502]="BadGateway",t[t.ServiceUnavailable=503]="ServiceUnavailable",t[t.GatewayTimeout=504]="GatewayTimeout"})(Ve||(Ve={}));var Zt;(function(t){t.Accept="accept",t.ContentType="content-type"})(Zt||(Zt={}));var yi;(function(t){t.ApplicationJson="application/json"})(yi||(yi={}));var sme=[Ve.MovedPermanently,Ve.ResourceMoved,Ve.SeeOther,Ve.TemporaryRedirect,Ve.PermanentRedirect],ime=[Ve.BadGateway,Ve.ServiceUnavailable,Ve.GatewayTimeout],ome=["OPTIONS","GET","DELETE","HEAD"],ame=10,cme=5,gs=class t extends Error{constructor(e,r){super(e),this.name="HttpClientError",this.statusCode=r,Object.setPrototypeOf(this,t.prototype)}},Uw=class{constructor(e){this.message=e}readBody(){return st(this,void 0,void 0,function*(){return new Promise(e=>st(this,void 0,void 0,function*(){let r=Buffer.alloc(0);this.message.on("data",n=>{r=Buffer.concat([r,n])}),this.message.on("end",()=>{e(r.toString())})}))})}readBodyBuffer(){return st(this,void 0,void 0,function*(){re
Line truncated
|
||||
${gme.sanitize({...this,request:{...this.request,agent:n},response:this.response})}`,enumerable:!1}),Object.setPrototypeOf(this,t.prototype)}};function _f(t){return t instanceof er?!0:Ea(t)&&t.name==="RestError"}function mr(t,e){return Buffer.from(t,e)}var Ff=B(require("node:http"),1),Uf=B(require("node:https"),1),jw=B(require("node:zlib"),1),OG=require("node:stream");var mn=ad("ts-http-runtime");var yme={};function cd(t){return t&&typeof t.pipe=="function"}function UG(t){return t.readable===!1?Promise.resolve():new Promise(e=>{let r=()=>{e(),t.removeListener("close",r),t.removeListener("end",r),t.removeListener("error",r)};t.on("close",r),t.on("end",r),t.on("error",r)})}function qG(t){return t&&typeof t.byteLength=="number"}var Of=class extends OG.Transform{loadedBytes=0;progressCallback;_transform(e,r,n){this.push(e),this.loadedBytes+=e.length;try{this.progressCallback({loadedBytes:this.loadedBytes}),n()}catch(s){n(s)}}constructor(e){super(),this.progressCallback=e}},Kw=class{cachedHttpAgent;cachedHttpsAgents=new WeakMap;async sendRequest(e){let r=new AbortController,n;if(e.abortSignal){if(e.abortSignal.aborted)throw new ys("The operation was aborted. Request has already been canceled.");n=l=>{l.type==="abort"&&r.abort()},e.abortSignal.addEventListener("abort",n)}let s;e.timeout>0&&(s=setTimeout(()=>{let l=new qn;mn.info(`request to '${l.sanitizeUrl(e.url)}' timed out. canceling...`),r.abort()},e.timeout));let i=e.headers.get("Accept-Encoding"),o=i?.includes("gzip")||i?.includes("deflate"),a=typeof e.body=="function"?e.body():e.body;if(a&&!e.headers.has("Content-Length")){let l=Bme(a);l!==null&&e.headers.set("Content-Length",l)}let c;try{if(a&&e.onUploadProgress){let p=e.onUploadProgress,f=new Of(p);f.on("error",E=>{mn.error("Error in upload progress",E)}),cd(a)?a.pipe(f):f.end(a),a=f}let l=await this.makeRequest(e,r,a);s!==void 0&&clearTimeout(s);let A=Eme(l),d={status:l.statusCode??0,headers:A,request:e};if(e.method==="HEAD")return l.resume(),d;c=o?Cme(l,A):l;let m=e.onDownloadProgress;if(m){let p=new Of(m);p.on("error",f=>{mn.error("Error in download progress",f)}),c.pipe(p),c=p}return e.streamResponseStatusCodes?.has(Number.POSITIVE_INFINITY)||e.streamResponseStatusCodes?.has(d.status)?d.readableStreamBody=c:d.bodyAsText=await Ime(c),d}finally{if(e.abortSignal&&n){let l=Promise.resolve();cd(a)&&(l=UG(a));let A=Promise.resolve();cd(c)&&(A=UG(c)),Promise.all([l,A]).then(()=>{n&&e.abortSignal?.removeEventListener("abort",n)}).catch(u=>{mn.warning("Error when cleaning up abortListener on httpRequest",u)})}}}makeRequest(e,r,n){let s=new URL(e.url),i=s.protocol!=="https:";if(i&&!e.allowInsecureConnection)throw new Error(`Cannot connect to ${e.url} while allowInsecureConnection is false.`);let a={agent:e.agent??this.getOrCreateAgent(e,i),hostname:s.hostname,path:`${s.pathname}${s.search}`,port:s.port,method:e.method,headers:e.headers.toJSON({preserveCase:!0}),...e.requestOverrides};return new Promise((c,l)=>{let A=i?Ff.default.request(a,c):Uf.default.request(a,c);A.once("error",u=>{l(new er(u.message,{code:u.code??er.REQUEST_SEND_ERROR,request:e}))}),r.signal.addEventListener("abort",()=>{let u=new ys("The operation was aborted. Rejecting from abort signal callback while making request.");A.destroy(u),l(u)}),n&&cd(n)?n.pipe(A):n?typeof n=="string"||Buffer.isBuffer(n)?A.end(n):qG(n)?A.end(ArrayBuffer.isView(n)?Buffer.from(n.buffer):Buffer.from(n)):(mn.error("Unrecognized body type",n),l(new er("Unrecognized body type"))):A.end()})}getOrCreateAgent(e,r){let n=e.disableKeepAlive;if(r)return n?Ff.default.globalAgent:(this.cachedHttpAgent||(this.cachedHttpAgent=new Ff.default.Agent({keepAlive:!0})),this.cachedHttpAgent);{if(n&&!e.tlsSettings)return Uf.default.globalAgent;let s=e.tlsSettings??yme,i=this.cachedHttpsAgents.get(s);return i&&i.options.keepAlive===!n||(mn.info("No cached TLS Agent exist, creating a new Agent"),i=new Uf.default.Agent({keepAlive:!n,...s}),this.cachedHttpsAgents.set(s,i)),i}}};function Eme(t){let e=Ur();for(let r of Object.keys(t.headers)){let n=t.headers[r];Array.isArray(n)?n.length>0&&e.set(r,n[0]):n&&e.set(r,n)}return e}function Cme(t,e){let r=e.get("Content-Encoding");if(r==="gzip"){let n=jw.default.createGunzip();return t.pipe(n),n}else if(r==="deflate"){let n=jw.default.createInflate();return t.pipe(n),n}return t}function Ime(t){return new Promise((e,r)=>{let n=[];t.on("data",s=>{Buffer.isBuffer(s)?n.push(s):n.push(Buffer.from(s))}),t.on("end",()=>{e(Buffer.concat(n).toString("utf8"))}),t.on("error",s=>{s&&s?.name==="AbortError"?r(s):r(new er(`Error reading response as text: ${s.message}`,{code:er.PARSE_ERROR}))})})}function Bme(t){return t?Buffer.isBuffer(t)?t.length:cd(t)?null:qG(t)?t.byteLength:typeof t=="string"?Buffer.from(t).length:null:0}function HG(){return new Kw}function qf(){return HG()}var Xw="logPolicy";function Hf(t={}){let e=t.logger??mn.info,r=new qn({additionalAllowedHeaderNames:t.additionalAllowedHeaderNames,additionalAllowedQueryParameters:t.additionalAllowedQue
Line truncated
|
||||
`;return e}function ehe(t){return t instanceof Uint8Array?t.byteLength:Ag(t)?t.size===-1?void 0:t.size:void 0}function the(t){let e=0;for(let r of t){let n=ehe(r);if(n===void 0)return;e+=n}return e}async function rhe(t,e,r){let n=[mr(`--${r}`,"utf-8"),...e.flatMap(i=>[mr(`\r
|
||||
`,"utf-8"),mr(Zpe(i.headers),"utf-8"),mr(`\r
|
||||
`,"utf-8"),i.body,mr(`\r
|
||||
--${r}`,"utf-8")]),mr(`--\r
|
||||
`).map(i=>i.trim());for(let i of s)!i||i.startsWith("#")||n.patterns.push(new Fu(i));return n.searchPaths.push(...$x(n.patterns)),n})}static stat(e,r,n){return tb(this,void 0,void 0,function*(){let s;if(r.followSymbolicLinks)try{s=yield il.promises.stat(e.path)}catch(i){if(i.code==="ENOENT"){if(r.omitBrokenSymbolicLinks){un(`Broken symlink '${e.path}'`);return}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw i}else s=yield il.promises.lstat(e.path);if(s.isDirectory()&&r.followSymbolicLinks){let i=yield il.promises.realpath(e.path);for(;n.length>=e.level;)n.pop();if(n.some(o=>o===i)){un(`Symlink cycle detected for path '${e.path}' and realpath '${i}'`);return}n.push(i)}return s})}};var Nle=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};function oH(t,e){return Nle(this,void 0,void 0,function*(){return yield Xh.create(t,e)})}var hf=B(require("crypto"),1),cl=B(require("fs"),1),da=B(require("path"),1),Kz=B($z(),1),Xz=B(require("util"),1);var Vu;(function(t){t.Gzip="cache.tgz",t.Zstd="cache.tzst"})(Vu||(Vu={}));var Zt;(function(t){t.Gzip="gzip",t.ZstdWithoutLong="zstd-without-long",t.Zstd="zstd"})(Zt||(Zt={}));var Ur;(function(t){t.GNU="gnu",t.BSD="bsd"})(Ur||(Ur={}));var mf=2,pf=5e3,Ib=5e3,Bb=`${process.env.PROGRAMFILES}\\Git\\usr\\bin\\tar.exe`,jz=`${process.env.SYSTEMDRIVE}\\Windows\\System32\\tar.exe`,Ju="cache.tar",Qb="manifest.txt",Ove=10*Math.pow(1024,3);var al=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},xde=function(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],r;return e?e.call(t):(t=typeof __values=="function"?__values(t):t[Symbol.iterator](),r={},n("next"),n("throw"),n("return"),r[Symbol.asyncIterator]=function(){return this},r);function n(i){r[i]=t[i]&&function(o){return new Promise(function(a,c){o=t[i](o),s(a,c,o.done,o.value)})}}function s(i,o,a,c){Promise.resolve(c).then(function(l){i({value:l,done:a})},o)}},bde="1.0";function Wu(){return al(this,void 0,void 0,function*(){let t=process.platform==="win32",e=process.env.RUNNER_TEMP||"";if(!e){let n;t?n=process.env.USERPROFILE||"C:\\":process.platform==="darwin"?n="/Users":n="/home",e=da.join(n,"actions","temp")}let r=da.join(e,hf.randomUUID());return yield oa(r),r})}function hs(t){return cl.statSync(t).size}function xb(t){return al(this,void 0,void 0,function*(){var e,r,n,s,i;let o=[],a=(i=process.env.GITHUB_WORKSPACE)!==null&&i!==void 0?i:process.cwd(),c=yield oH(t.join(`
|
||||
`),{implicitDescendants:!1});try{for(var l=!0,A=xde(c.globGenerator()),u;u=yield A.next(),e=u.done,!e;l=!0){s=u.value,l=!1;let m=da.relative(a,s).replace(new RegExp(`\\${da.sep}`,"g"),"/");x(`Matched: ${m}`),m===""?o.push("."):o.push(`${m}`)}}catch(d){r={error:d}}finally{try{!l&&!e&&(n=A.return)&&(yield n.call(A))}finally{if(r)throw r.error}}return o})}function $u(t){return al(this,void 0,void 0,function*(){return Xz.promisify(cl.unlink)(t)})}function Zz(t){return al(this,arguments,void 0,function*(e,r=[]){let n="";r.push("--version"),x(`Checking ${e} ${r.join(" ")}`);try{yield oo(`${e}`,r,{ignoreReturnCode:!0,silent:!0,listeners:{stdout:s=>n+=s.toString(),stderr:s=>n+=s.toString()}})}catch(s){x(s.message)}return n=n.trim(),x(n),n})}function ju(){return al(this,void 0,void 0,function*(){let t=yield Zz("zstd",["--quiet"]),e=Kz.clean(t);return x(`zstd version: ${e}`),t===""?Zt.Gzip:Zt.ZstdWithoutLong})}function po(t){return t===Zt.Gzip?Vu.Gzip:Vu.Zstd}function eG(){return al(this,void 0,void 0,function*(){return cl.existsSync(Bb)?Bb:(yield Zz("tar")).toLowerCase().includes("gnu tar")?dr("tar"):""})}function bb(t,e){if(e===void 0)throw Error(`Expected ${t} but value was undefiend`);return e}function ll(t,e,r=!1){let n=t.slice();return e&&n.push(e),process.platform==="win32"&&!r&&n.push("windows-only"),n.push(bde),hf.createHash("sha256").update(n.join("|")).digest("hex")}function tG(){let t=process.env.ACTIONS_RUNTIME_TOKEN;if(!t)throw new Error("Unable to get the ACTIONS_RUNTIME_TOKEN env variable");return t}var Xu=B(require("http"),1),Sb=B(require("https"),1);function wb(t){let e=t.protocol==="https:";if(wde(t))return;let r=e?process.env.https_proxy||process.env.HTTPS_PROXY:process.env.http_proxy||process.env.HTTP_PROXY;if(r)try{return new gf(r)}catch{if(!r.startsWith("http://")&&!r.startsWith("https://"))return new gf(`http://${r}`)}else return}function wde(t){if(!t.hostname)return!1;let e=t.hostname;if(Nde(e))return!0;let r=process.env.no_proxy||process.env.NO_PROXY||"";if(!r)return!1;let n;t.port?n=Number(t.port):t.protocol==="http:"?n=80:t.protocol==="https:"&&(n=443);let s=[t.hostname.toUpperCase()];typeof n=="number"&&s.push(`${s[0]}:${n}`);for(let i of r.split(",").map(o=>o.trim().toUpperCase()).filter(o=>o))if(i==="*"||s.some(o=>o===i||o.endsWith(`.${i}`)||i.startsWith(".")&&o.endsWith(`${i}`)))return!0;return!1}function Nde(t){let e=t.toLowerCase();return e==="localhost"||e.startsWith("127.")||e.startsWith("[::1]")||e.startsWith("[0:0:0:0:0:0:0:1]")}var gf=class extends URL{constructor(e,r){super(e,r),this._decodedUsername=decodeURIComponent(super.username),this._decodedPassword=decodeURIComponent(super.password)}get username(){return this._decodedUsername}get password(){return this._decodedPassword}};var ho=B(kC(),1),rG=B(ex(),1),st=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},Ve;(function(t){t[t.OK=200]="OK",t[t.MultipleChoices=300]="MultipleChoices",t[t.MovedPermanently=301]="MovedPermanently",t[t.ResourceMoved=302]="ResourceMoved",t[t.SeeOther=303]="SeeOther",t[t.NotModified=304]="NotModified",t[t.UseProxy=305]="UseProxy",t[t.SwitchProxy=306]="SwitchProxy",t[t.TemporaryRedirect=307]="TemporaryRedirect",t[t.PermanentRedirect=308]="PermanentRedirect",t[t.BadRequest=400]="BadRequest",t[t.Unauthorized=401]="Unauthorized",t[t.PaymentRequired=402]="PaymentRequired",t[t.Forbidden=403]="Forbidden",t[t.NotFound=404]="NotFound",t[t.MethodNotAllowed=405]="MethodNotAllowed",t[t.NotAcceptable=406]="NotAcceptable",t[t.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",t[t.RequestTimeout=408]="RequestTimeout",t[t.Conflict=409]="Conflict",t[t.Gone=410]="Gone",t[t.TooManyRequests=429]="TooManyRequests",t[t.InternalServerError=500]="InternalServerError",t[t.NotImplemented=501]="NotImplemented",t[t.BadGateway=502]="BadGateway",t[t.ServiceUnavailable=503]="ServiceUnavailable",t[t.GatewayTimeout=504]="GatewayTimeout"})(Ve||(Ve={}));var er;(function(t){t.Accept="accept",t.ContentType="content-type"})(er||(er={}));var yi;(function(t){t.ApplicationJson="application/json"})(yi||(yi={}));var Rde=[Ve.MovedPermanently,Ve.ResourceMoved,Ve.SeeOther,Ve.TemporaryRedirect,Ve.PermanentRedirect],Pde=[Ve.BadGateway,Ve.ServiceUnavailable,Ve.GatewayTimeout],vde=["OPTIONS","GET","DELETE","HEAD"],Dde=10,kde=5,fs=class t extends Error{constructor(e,r){super(e),this.name="HttpClientError",this.statusCode=r,Object.setPrototypeOf(this,t.prototype)}},Nb=class{constructor(e){this.message=e}readBody(){return st(this,void 0,void 0,function*(){return new Promise(e=>st(this,void 0,void 0,function*(){let r=Buffer.alloc(0);this.message.on("data",n=>{r=Buffer.concat([r,n])}),this.message.on("end",()=>{e(r.toString())})}))})}readBodyBuffer(){return st(this,void 0,void 0,function*(){re
Line truncated
|
||||
${Hde.sanitize({...this,request:{...this.request,agent:n},response:this.response})}`,enumerable:!1}),Object.setPrototypeOf(this,t.prototype)}};function Qf(t){return t instanceof tr?!0:pa(t)&&t.name==="RestError"}function hr(t,e){return Buffer.from(t,e)}var xf=B(require("node:http"),1),bf=B(require("node:https"),1),_b=B(require("node:zlib"),1),CG=require("node:stream");var pn=Zu("ts-http-runtime");var zde={};function ed(t){return t&&typeof t.pipe=="function"}function EG(t){return t.readable===!1?Promise.resolve():new Promise(e=>{let r=()=>{e(),t.removeListener("close",r),t.removeListener("end",r),t.removeListener("error",r)};t.on("close",r),t.on("end",r),t.on("error",r)})}function IG(t){return t&&typeof t.byteLength=="number"}var wf=class extends CG.Transform{loadedBytes=0;progressCallback;_transform(e,r,n){this.push(e),this.loadedBytes+=e.length;try{this.progressCallback({loadedBytes:this.loadedBytes}),n()}catch(s){n(s)}}constructor(e){super(),this.progressCallback=e}},Ub=class{cachedHttpAgent;cachedHttpsAgents=new WeakMap;async sendRequest(e){let r=new AbortController,n;if(e.abortSignal){if(e.abortSignal.aborted)throw new gs("The operation was aborted. Request has already been canceled.");n=l=>{l.type==="abort"&&r.abort()},e.abortSignal.addEventListener("abort",n)}let s;e.timeout>0&&(s=setTimeout(()=>{let l=new qn;pn.info(`request to '${l.sanitizeUrl(e.url)}' timed out. canceling...`),r.abort()},e.timeout));let i=e.headers.get("Accept-Encoding"),o=i?.includes("gzip")||i?.includes("deflate"),a=typeof e.body=="function"?e.body():e.body;if(a&&!e.headers.has("Content-Length")){let l=Jde(a);l!==null&&e.headers.set("Content-Length",l)}let c;try{if(a&&e.onUploadProgress){let p=e.onUploadProgress,f=new wf(p);f.on("error",E=>{pn.error("Error in upload progress",E)}),ed(a)?a.pipe(f):f.end(a),a=f}let l=await this.makeRequest(e,r,a);s!==void 0&&clearTimeout(s);let A=Gde(l),d={status:l.statusCode??0,headers:A,request:e};if(e.method==="HEAD")return l.resume(),d;c=o?Yde(l,A):l;let m=e.onDownloadProgress;if(m){let p=new wf(m);p.on("error",f=>{pn.error("Error in download progress",f)}),c.pipe(p),c=p}return e.streamResponseStatusCodes?.has(Number.POSITIVE_INFINITY)||e.streamResponseStatusCodes?.has(d.status)?d.readableStreamBody=c:d.bodyAsText=await Vde(c),d}finally{if(e.abortSignal&&n){let l=Promise.resolve();ed(a)&&(l=EG(a));let A=Promise.resolve();ed(c)&&(A=EG(c)),Promise.all([l,A]).then(()=>{n&&e.abortSignal?.removeEventListener("abort",n)}).catch(u=>{pn.warning("Error when cleaning up abortListener on httpRequest",u)})}}}makeRequest(e,r,n){let s=new URL(e.url),i=s.protocol!=="https:";if(i&&!e.allowInsecureConnection)throw new Error(`Cannot connect to ${e.url} while allowInsecureConnection is false.`);let a={agent:e.agent??this.getOrCreateAgent(e,i),hostname:s.hostname,path:`${s.pathname}${s.search}`,port:s.port,method:e.method,headers:e.headers.toJSON({preserveCase:!0}),...e.requestOverrides};return new Promise((c,l)=>{let A=i?xf.default.request(a,c):bf.default.request(a,c);A.once("error",u=>{l(new tr(u.message,{code:u.code??tr.REQUEST_SEND_ERROR,request:e}))}),r.signal.addEventListener("abort",()=>{let u=new gs("The operation was aborted. Rejecting from abort signal callback while making request.");A.destroy(u),l(u)}),n&&ed(n)?n.pipe(A):n?typeof n=="string"||Buffer.isBuffer(n)?A.end(n):IG(n)?A.end(ArrayBuffer.isView(n)?Buffer.from(n.buffer):Buffer.from(n)):(pn.error("Unrecognized body type",n),l(new tr("Unrecognized body type"))):A.end()})}getOrCreateAgent(e,r){let n=e.disableKeepAlive;if(r)return n?xf.default.globalAgent:(this.cachedHttpAgent||(this.cachedHttpAgent=new xf.default.Agent({keepAlive:!0})),this.cachedHttpAgent);{if(n&&!e.tlsSettings)return bf.default.globalAgent;let s=e.tlsSettings??zde,i=this.cachedHttpsAgents.get(s);return i&&i.options.keepAlive===!n||(pn.info("No cached TLS Agent exist, creating a new Agent"),i=new bf.default.Agent({keepAlive:!n,...s}),this.cachedHttpsAgents.set(s,i)),i}}};function Gde(t){let e=Or();for(let r of Object.keys(t.headers)){let n=t.headers[r];Array.isArray(n)?n.length>0&&e.set(r,n[0]):n&&e.set(r,n)}return e}function Yde(t,e){let r=e.get("Content-Encoding");if(r==="gzip"){let n=_b.default.createGunzip();return t.pipe(n),n}else if(r==="deflate"){let n=_b.default.createInflate();return t.pipe(n),n}return t}function Vde(t){return new Promise((e,r)=>{let n=[];t.on("data",s=>{Buffer.isBuffer(s)?n.push(s):n.push(Buffer.from(s))}),t.on("end",()=>{e(Buffer.concat(n).toString("utf8"))}),t.on("error",s=>{s&&s?.name==="AbortError"?r(s):r(new tr(`Error reading response as text: ${s.message}`,{code:tr.PARSE_ERROR}))})})}function Jde(t){return t?Buffer.isBuffer(t)?t.length:ed(t)?null:IG(t)?t.byteLength:typeof t=="string"?Buffer.from(t).length:null:0}function BG(){return new Ub}function Nf(){return BG()}var Ob="logPolicy";function Sf(t={}){let e=t.logger??pn.info,r=new qn({additionalAllowedHeaderNames:t.additionalAllowedHeaderNames,additionalAllowedQueryParameters:t.additionalAllowedQue
Line truncated
|
||||
`;return e}function bpe(t){return t instanceof Uint8Array?t.byteLength:jf(t)?t.size===-1?void 0:t.size:void 0}function wpe(t){let e=0;for(let r of t){let n=bpe(r);if(n===void 0)return;e+=n}return e}async function Npe(t,e,r){let n=[hr(`--${r}`,"utf-8"),...e.flatMap(i=>[hr(`\r
|
||||
`,"utf-8"),hr(xpe(i.headers),"utf-8"),hr(`\r
|
||||
`,"utf-8"),i.body,hr(`\r
|
||||
--${r}`,"utf-8")]),hr(`--\r
|
||||
\r
|
||||
`,"utf-8")],s=the(n);s&&t.headers.set("Content-Length",s),t.body=await VY(n)}var ud="multipartPolicy",nhe=70,she=new Set("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");function ihe(t){if(t.length>nhe)throw new Error(`Multipart boundary "${t}" exceeds maximum length of 70 characters`);if(Array.from(t).some(e=>!she.has(e)))throw new Error(`Multipart boundary "${t}" contains invalid characters`)}function dg(){return{name:ud,async sendRequest(t,e){if(!t.multipartBody)return e(t);if(t.body)throw new Error("multipartBody and regular body cannot be set at the same time");let r=t.multipartBody.boundary,n=t.headers.get("Content-Type")??"multipart/mixed",s=n.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!s)throw new Error(`Got multipart request body, but content-type header was not multipart: ${n}`);let[,i,o]=s;if(o&&r&&o!==r)throw new Error(`Multipart boundary was specified as ${o} in the header, but got ${r} in the request body`);return r??=o,r?ihe(r):r=Xpe(),t.headers.set("Content-Type",`${i}; boundary=${r}`),await rhe(t,t.multipartBody.parts,r),t.multipartBody=void 0,e(t)}}}function mg(){return Lf()}var JY=kf({logLevelEnvVarName:"AZURE_LOG_LEVEL",namespace:"azure"}),lLe=JY.logger;function Is(t){return JY.createClientLogger(t)}var Bs=Is("core-rest-pipeline");function hb(t={}){return Hf({logger:Bs.info,...t})}var fb=zf;function gb(t={}){return Gf(t)}var pg=B(require("node:os"),1),hg=B(require("node:process"),1);function WY(){return"User-Agent"}async function $Y(t){if(hg.default&&hg.default.versions){let e=`${pg.default.type()} ${pg.default.release()}; ${pg.default.arch()}`,r=hg.default.versions;r.bun?t.set("Bun",`${r.bun} (${e})`):r.deno?t.set("Deno",`${r.deno} (${e})`):r.node&&t.set("Node",`${r.node} (${e})`)}}var fg="1.22.2";function mhe(t){let e=[];for(let[r,n]of t){let s=n?`${r}/${n}`:r;e.push(s)}return e.join(" ")}function jY(){return WY()}async function gg(t){let e=new Map;e.set("core-rest-pipeline",fg),await $Y(e);let r=mhe(e);return t?`${t} ${r}`:r}var KY=jY(),XY="userAgentPolicy";function yb(t={}){let e=gg(t.userAgentPrefix);return{name:XY,async sendRequest(r,n){return r.headers.has(KY)||r.headers.set(KY,await e),n(r)}}}var zr=class extends Error{constructor(e){super(e),this.name="AbortError"}};function Eb(t,e){let{cleanupBeforeAbort:r,abortSignal:n,abortErrorMsg:s}=e??{};return new Promise((i,o)=>{function a(){o(new zr(s??"The operation was aborted."))}function c(){n?.removeEventListener("abort",l)}function l(){r?.(),c(),a()}if(n?.aborted)return a();try{t(A=>{c(),i(A)},A=>{c(),o(A)})}catch(A){o(A)}n?.addEventListener("abort",l)})}var yhe="The delay was aborted.";function dd(t,e){let r,{abortSignal:n,abortErrorMsg:s}=e??{};return Eb(i=>{r=setTimeout(i,t)},{cleanupBeforeAbort:()=>clearTimeout(r),abortSignal:n,abortErrorMsg:s??yhe})}function Co(t){if(Ea(t))return t.message;{let e;try{typeof t=="object"&&t?e=JSON.stringify(t):e=String(t)}catch{e="[unable to stringify input]"}return`Unknown error ${e}`}}function ZY(t){return Ea(t)}function Bl(){return ya()}var Ce=Ba;var eV=Symbol("rawContent");function Ib(t){return typeof t[eV]=="function"}function tV(t){return Ib(t)?t[eV]():t}var yg=ud;function Bb(){let t=dg();return{name:yg,sendRequest:async(e,r)=>{if(e.multipartBody)for(let n of e.multipartBody.parts)Ib(n.body)&&(n.body=tV(n.body));return t.sendRequest(e,r)}}}var Qb=Yf;function xb(){return Vf()}function wb(t={}){return $f(t)}function bb(){return jf()}function Io(t){return Ab(t)}function Nb(t,e){return ag(t,e)}var rV="setClientRequestIdPolicy";function Sb(t="x-ms-client-request-id"){return{name:rV,async sendRequest(e,r){return e.headers.has(t)||e.headers.set(t,e.requestId),r(e)}}}function Rb(t){return cg(t)}function Pb(t){return lg(t)}var Ql={span:Symbol.for("@azure/core-tracing span"),namespace:Symbol.for("@azure/core-tracing namespace")};function nV(t={}){let e=new vb(t.parentContext);return t.span&&(e=e.setValue(Ql.span,t.span)),t.namespace&&(e=e.setValue(Ql.namespace,t.namespace)),e}var vb=class t{_contextMap;constructor(e){this._contextMap=e instanceof t?new Map(e._contextMap):new Map}setValue(e,r){let n=new t(this);return n._contextMap.set(e,r),n}getValue(e){return this._contextMap.get(e)}deleteValue(e){let r=new t(this);return r._contextMap.delete(e),r}};var iV=B(sV(),1),Cg=iV.state;function Ehe(){return{end:()=>{},isRecording:()=>!1,recordException:()=>{},setAttribute:()=>{},setStatus:()=>{},addEvent:()=>{}}}function Che(){return{createRequestHeaders:()=>({}),parseTraceparentHeader:()=>{},startSpan:(t,e)=>({span:Ehe(),tracingContext:nV({parentContext:e.tracingContext})}),withContext(t,e,...r){return e(...r)}}}function md(){return Cg.instrumenterImplementation||(Cg.instrumenterImplementation=Che()),Cg.instrumenterImplementation}function pd(t){let{namespace:e,packageName:r,packageVersion:n}=t;function s(l,A,u){let d=md().startSpan(l,{...u,packageName:r,packageVersion:n,tracingContext:A?.tracingOptions?.tracingContext}),m=d.tracingContext,p=d.span;m.getValue(Ql.na
Line truncated
|
||||
`&&t[i]!=="\r";i++)c+=t[i];if(c=c.trim(),c[c.length-1]==="/"&&(c=c.substring(0,c.length-1),i--),!Hfe(c)){let u;return c.trim().length===0?u="Invalid space after '<'.":u="Tag '"+c+"' is an invalid name.",it("InvalidTag",u,tr(t,i))}let l=_fe(t,i);if(l===!1)return it("InvalidAttr","Attributes for '"+c+"' have open quote.",tr(t,i));let A=l.value;if(i=l.index,A[A.length-1]==="/"){let u=i-A.length;A=A.substring(0,A.length-1);let d=OV(A,e);if(d===!0)n=!0;else return it(d.err.code,d.err.msg,tr(t,u+d.err.line))}else if(a)if(l.tagClosed){if(A.trim().length>0)return it("InvalidTag","Closing tag '"+c+"' can't have attributes or invalid starting.",tr(t,o));if(r.length===0)return it("InvalidTag","Closing tag '"+c+"' has not been opened.",tr(t,o));{let u=r.pop();if(c!==u.tagName){let d=tr(t,u.tagStartPos);return it("InvalidTag","Expected closing tag '"+u.tagName+"' (opened in line "+d.line+", col "+d.col+") instead of closing tag '"+c+"'.",tr(t,o))}r.length==0&&(s=!0)}}else return it("InvalidTag","Closing tag '"+c+"' doesn't have proper closing.",tr(t,i));else{let u=OV(A,e);if(u!==!0)return it(u.err.code,u.err.msg,tr(t,i-A.length+u.err.line));if(s===!0)return it("InvalidXml","Multiple possible root nodes found.",tr(t,i));e.unpairedTags.indexOf(c)!==-1||r.push({tagName:c,tagStartPos:o}),n=!0}for(i++;i<t.length;i++)if(t[i]==="<")if(t[i+1]==="!"){i++,i=UV(t,i);continue}else if(t[i+1]==="?"){if(i=FV(t,++i),i.err)return i}else break;else if(t[i]==="&"){let u=Ofe(t,i);if(u==-1)return it("InvalidChar","char '&' is not expected.",tr(t,i));i=u}else if(s===!0&&!_V(t[i]))return it("InvalidXml","Extra text at the end",tr(t,i));t[i]==="<"&&i--}}else{if(_V(t[i]))continue;return it("InvalidChar","char '"+t[i]+"' is not expected.",tr(t,i))}if(n){if(r.length==1)return it("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",tr(t,r[0].tagStartPos));if(r.length>0)return it("InvalidXml","Invalid '"+JSON.stringify(r.map(i=>i.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return it("InvalidXml","Start tag expected.",1);return!0}function _V(t){return t===" "||t===" "||t===`
|
||||
`||t==="\r"}function FV(t,e){let r=e;for(;e<t.length;e++)if(t[e]=="?"||t[e]==" "){let n=t.substr(r,e-r);if(e>5&&n==="xml")return it("InvalidXml","XML declaration allowed only at the start of the document.",tr(t,e));if(t[e]=="?"&&t[e+1]==">"){e++;break}else continue}return e}function UV(t,e){if(t.length>e+5&&t[e+1]==="-"&&t[e+2]==="-"){for(e+=3;e<t.length;e++)if(t[e]==="-"&&t[e+1]==="-"&&t[e+2]===">"){e+=2;break}}else if(t.length>e+8&&t[e+1]==="D"&&t[e+2]==="O"&&t[e+3]==="C"&&t[e+4]==="T"&&t[e+5]==="Y"&&t[e+6]==="P"&&t[e+7]==="E"){let r=1;for(e+=8;e<t.length;e++)if(t[e]==="<")r++;else if(t[e]===">"&&(r--,r===0))break}else if(t.length>e+9&&t[e+1]==="["&&t[e+2]==="C"&&t[e+3]==="D"&&t[e+4]==="A"&&t[e+5]==="T"&&t[e+6]==="A"&&t[e+7]==="["){for(e+=8;e<t.length;e++)if(t[e]==="]"&&t[e+1]==="]"&&t[e+2]===">"){e+=2;break}}return e}var Mfe='"',Lfe="'";function _fe(t,e){let r="",n="",s=!1;for(;e<t.length;e++){if(t[e]===Mfe||t[e]===Lfe)n===""?n=t[e]:n!==t[e]||(n="");else if(t[e]===">"&&n===""){s=!0;break}r+=t[e]}return n!==""?!1:{value:r,index:e,tagClosed:s}}var Ffe=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function OV(t,e){let r=Rg(t,Ffe),n={};for(let s=0;s<r.length;s++){if(r[s][1].length===0)return it("InvalidAttr","Attribute '"+r[s][2]+"' has no space in starting.",xd(r[s]));if(r[s][3]!==void 0&&r[s][4]===void 0)return it("InvalidAttr","Attribute '"+r[s][2]+"' is without value.",xd(r[s]));if(r[s][3]===void 0&&!e.allowBooleanAttributes)return it("InvalidAttr","boolean attribute '"+r[s][2]+"' is not allowed.",xd(r[s]));let i=r[s][2];if(!qfe(i))return it("InvalidAttr","Attribute '"+i+"' is an invalid name.",xd(r[s]));if(!Object.prototype.hasOwnProperty.call(n,i))n[i]=1;else return it("InvalidAttr","Attribute '"+i+"' is repeated.",xd(r[s]))}return!0}function Ufe(t,e){let r=/\d/;for(t[e]==="x"&&(e++,r=/[\da-fA-F]/);e<t.length;e++){if(t[e]===";")return e;if(!t[e].match(r))break}return-1}function Ofe(t,e){if(e++,t[e]===";")return-1;if(t[e]==="#")return e++,Ufe(t,e);let r=0;for(;e<t.length;e++,r++)if(!(t[e].match(/\w/)&&r<20)){if(t[e]===";")break;return-1}return e}function it(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}function qfe(t){return $b(t)}function Hfe(t){return $b(t)}function tr(t,e){let r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function xd(t){return t.startIndex+t[1].length}var qV={amp:"&",AMP:"&",lt:"<",LT:"<",gt:">",GT:">",quot:'"',QUOT:'"',apos:"'",lsquo:"\u2018",rsquo:"\u2019",ldquo:"\u201C",rdquo:"\u201D",lsquor:"\u201A",rsquor:"\u2019",ldquor:"\u201E",bdquo:"\u201E",comma:",",period:".",colon:":",semi:";",excl:"!",quest:"?",num:"#",dollar:"$",percent:"%",amp:"&",ast:"*",commat:"@",lowbar:"_",verbar:"|",vert:"|",sol:"/",bsol:"\\",lbrace:"{",rbrace:"}",lbrack:"[",rbrack:"]",lpar:"(",rpar:")",nbsp:"\xA0",iexcl:"\xA1",cent:"\xA2",pound:"\xA3",curren:"\xA4",yen:"\xA5",brvbar:"\xA6",sect:"\xA7",uml:"\xA8",copy:"\xA9",COPY:"\xA9",ordf:"\xAA",laquo:"\xAB",not:"\xAC",shy:"\xAD",reg:"\xAE",REG:"\xAE",macr:"\xAF",deg:"\xB0",plusmn:"\xB1",sup2:"\xB2",sup3:"\xB3",acute:"\xB4",micro:"\xB5",para:"\xB6",middot:"\xB7",cedil:"\xB8",sup1:"\xB9",ordm:"\xBA",raquo:"\xBB",frac14:"\xBC",frac12:"\xBD",half:"\xBD",frac34:"\xBE",iquest:"\xBF",times:"\xD7",div:"\xF7",divide:"\xF7"},HV={Agrave:"\xC0",agrave:"\xE0",Aacute:"\xC1",aacute:"\xE1",Acirc:"\xC2",acirc:"\xE2",Atilde:"\xC3",atilde:"\xE3",Auml:"\xC4",auml:"\xE4",Aring:"\xC5",aring:"\xE5",AElig:"\xC6",aelig:"\xE6",Ccedil:"\xC7",ccedil:"\xE7",Egrave:"\xC8",egrave:"\xE8",Eacute:"\xC9",eacute:"\xE9",Ecirc:"\xCA",ecirc:"\xEA",Euml:"\xCB",euml:"\xEB",Igrave:"\xCC",igrave:"\xEC",Iacute:"\xCD",iacute:"\xED",Icirc:"\xCE",icirc:"\xEE",Iuml:"\xCF",iuml:"\xEF",ETH:"\xD0",eth:"\xF0",Ntilde:"\xD1",ntilde:"\xF1",Ograve:"\xD2",ograve:"\xF2",Oacute:"\xD3",oacute:"\xF3",Ocirc:"\xD4",ocirc:"\xF4",Otilde:"\xD5",otilde:"\xF5",Ouml:"\xD6",ouml:"\xF6",Oslash:"\xD8",oslash:"\xF8",Ugrave:"\xD9",ugrave:"\xF9",Uacute:"\xDA",uacute:"\xFA",Ucirc:"\xDB",ucirc:"\xFB",Uuml:"\xDC",uuml:"\xFC",Yacute:"\xDD",yacute:"\xFD",THORN:"\xDE",thorn:"\xFE",szlig:"\xDF",yuml:"\xFF",Yuml:"\u0178"},zV={Amacr:"\u0100",amacr:"\u0101",Abreve:"\u0102",abreve:"\u0103",Aogon:"\u0104",aogon:"\u0105",Cacute:"\u0106",cacute:"\u0107",Ccirc:"\u0108",ccirc:"\u0109",Cdot:"\u010A",cdot:"\u010B",Ccaron:"\u010C",ccaron:"\u010D",Dcaron:"\u010E",dcaron:"\u010F",Dstrok:"\u0110",dstrok:"\u0111",Emacr:"\u0112",emacr:"\u0113",Ecaron:"\u011A",ecaron:"\u011B",Edot:"\u0116",edot:"\u0117",Eogon:"\u0118",eogon:"\u0119",Gcirc:"\u011C",gcirc:"\u011D",Gbreve:"\u011E",gbreve:"\u011F",Gdot:"\u0120",gdot:"\u0121",Gcedil:"\u0122",Hcirc:"\u0124",hcirc:"\u0125",Hstrok:"\u0126",hstrok:"\u0127",Itilde:"\u0128",itilde:"\u0129",Imacr:"\u012A",imacr:"\u012B",Iogon:"\u012E",iogon:"\u012F",Idot:"\u0130",IJlig:"\u0132",ijlig:"\u0133",Jcirc:"\u0134",jcirc:"\u0135",Kcedil:"\u0136",kcedil:"\u0137",kgreen:"\u0138",Lacute:"\u0139",lacute:"\u013A",Lcedil:"\u013B",lcedil:"\u013C",Lcaron:"\u0Line truncated
|
||||
`);let e=new gr("!xml"),r=e,n="";this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let s=this.options,i=new Nd(s.processEntities),o=t.length;for(let a=0;a<o;a++)if(t[a]==="<"){let l=t.charCodeAt(a+1);if(l===47){let A=Sl(t,">",a,"Closing Tag is not closed."),u=t.substring(a+2,A).trim();if(s.removeNSPrefix){let m=u.indexOf(":");m!==-1&&(u=u.substr(m+1))}u=n0(s.transformTagName,u,"",s).tagName,r&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher));let d=this.matcher.getCurrentTag();if(u&&s.unpairedTagsSet.has(u))throw new Error(`Unpaired tag can not be used as closing tag: </${u}>`);d&&s.unpairedTagsSet.has(d)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,r=this.tagsNodeStack.pop(),n="",a=A}else if(l===63){let A=s0(t,a,!1,"?>");if(!A)throw new Error("Pi Tag is not closed.");n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let u=this.buildAttributesMap(A.tagExp,this.matcher,A.tagName,!0);if(u){let d=u[this.options.attributeNamePrefix+"version"];this.entityDecoder.setXmlVersion(Number(d)||1),i.setXmlVersion(Number(d)||1)}if(!(s.ignoreDeclaration&&A.tagName==="?xml"||s.ignorePiTags)){let d=new gr(A.tagName);d.add(s.textNodeName,""),A.tagName!==A.tagExp&&A.attrExpPresent&&s.ignoreAttributes!==!0&&(d[":@"]=u),this.addChild(r,d,this.readonlyMatcher,a)}a=A.closeIndex+1}else if(l===33&&t.charCodeAt(a+2)===45&&t.charCodeAt(a+3)===45){let A=Sl(t,"-->",a+4,"Comment is not closed.");if(s.commentPropName){let u=t.substring(a+4,A-2);n=this.saveTextToParentTag(n,r,this.readonlyMatcher),r.add(s.commentPropName,[{[s.textNodeName]:u}])}a=A}else if(l===33&&t.charCodeAt(a+2)===68){let A=i.readDocType(t,a);this.entityDecoder.addInputEntities(A.entities),a=A.i}else if(l===33&&t.charCodeAt(a+2)===91){let A=Sl(t,"]]>",a,"CDATA is not closed.")-2,u=t.substring(a+9,A);n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let d=this.parseTextData(u,r.tagname,this.readonlyMatcher,!0,!1,!0,!0);d==null&&(d=""),s.cdataPropName?r.add(s.cdataPropName,[{[s.textNodeName]:u}]):r.add(s.textNodeName,d),a=A+2}else{let A=s0(t,a,s.removeNSPrefix);if(!A){let D=t.substring(Math.max(0,a-50),Math.min(o,a+50));throw new Error(`readTagExp returned undefined at position ${a}. Context: "${D}"`)}let u=A.tagName,d=A.rawTagName,m=A.tagExp,p=A.attrExpPresent,f=A.closeIndex;if({tagName:u,tagExp:m}=n0(s.transformTagName,u,m,s),s.strictReservedNames&&(u===s.commentPropName||u===s.cdataPropName||u===s.textNodeName||u===s.attributesGroupName))throw new Error(`Invalid tag name: ${u}`);r&&n&&r.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher,!1));let E=r;E&&s.unpairedTagsSet.has(E.tagname)&&(r=this.tagsNodeStack.pop(),this.matcher.pop());let g=!1;m.length>0&&m.lastIndexOf("/")===m.length-1&&(g=!0,u[u.length-1]==="/"?(u=u.substr(0,u.length-1),m=u):m=m.substr(0,m.length-1),p=u!==m);let y=null,C={},I;I=uge(d),u!==e.tagname&&this.matcher.push(u,{},I),u!==m&&p&&(y=this.buildAttributesMap(m,this.matcher,u),y&&(C=Age(y,s))),u!==e.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let w=a;if(this.isCurrentNodeStopNode){let D="";if(g)a=A.closeIndex;else if(s.unpairedTagsSet.has(u))a=A.closeIndex;else{let ae=this.readStopNodeData(t,d,f+1);if(!ae)throw new Error(`Unexpected end of ${d}`);a=ae.i,D=ae.tagContent}let _=new gr(u);y&&(_[":@"]=y),_.add(s.textNodeName,D),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(r,_,this.readonlyMatcher,w)}else{if(g){({tagName:u,tagExp:m}=n0(s.transformTagName,u,m,s));let D=new gr(u);y&&(D[":@"]=y),this.addChild(r,D,this.readonlyMatcher,w),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else if(s.unpairedTagsSet.has(u)){let D=new gr(u);y&&(D[":@"]=y),this.addChild(r,D,this.readonlyMatcher,w),this.matcher.pop(),this.isCurrentNodeStopNode=!1,a=A.closeIndex;continue}else{let D=new gr(u);if(this.tagsNodeStack.length>s.maxNestedTags)throw new Error("Maximum nested tags exceeded");this.tagsNodeStack.push(r),y&&(D[":@"]=y),this.addChild(r,D,this.readonlyMatcher,w),r=D}n="",a=f}}}else n+=t[a];return e.child};function gge(t,e,r,n){this.options.captureMetaData||(n=void 0);let s=this.options.jPath?r.toString():r,i=this.options.updateTag(e.tagname,s,e[":@"]);i===!1||(typeof i=="string"&&(e.tagname=i),t.addChild(e,n))}function yge(t,e,r){let n=this.options.processEntities;if(!n||!n.enabled)return t;if(n.allowedTags){let s=this.options.jPath?r.toString():r;if(!(Array.isArray(n.allowedTags)?n.allowedTags.includes(e):n.allowedTags(e,s)))return t}if(n.tagFilter){let s=this.options.jPath?r.toString():r;if(!n.tagFilter(e,s))return t}return this.entityDecoder.decode(t)}function Ege(t,e,r,n){return t&&(n===void 0&&(n=e.child.length===0),t=this.parseTextData(t,e.tagname,r,!1,e[":@"]?Object.keys(e[":@"]).length!==0:!1,n),t!==void 0&&t!==""&&e.add(this.options.textNodeName,t),t=""),t}function Cge(){return this.stopNodeExpressionsSet.size===0?!1:this.matcher.matchesAny(this.stopNodeExpressionsSet)}function Ige(t,e,r="Line truncated
|
||||
`;function Rge(t,e){if(!Array.isArray(t)||t.length===0)return"1.0";let r=t[0];if(A0(r)==="?xml"){let s=r[":@"];if(s){let i=e.attributeNamePrefix+"version";if(s[i])return s[i]}}return"1.0"}function lJ(t,e,r,n,s){return!r.sanitizeName||Na(t,{xmlVersion:s})?t:r.sanitizeName(t,{isAttribute:e,matcher:n.readOnly()})}function l0(t,e){let r="";e.format&&(r=Sge);let n=[];if(e.stopNodes&&Array.isArray(e.stopNodes))for(let o=0;o<e.stopNodes.length;o++){let a=e.stopNodes[o];typeof a=="string"?n.push(new Vr(a)):a instanceof Vr&&n.push(a)}let s=Rge(t,e),i=new ws;return AJ(t,e,r,i,n,s)}function AJ(t,e,r,n,s,i){let o="",a=!1;if(e.maxNestedTags&&n.getDepth()>e.maxNestedTags)throw new Error("Maximum nested tags exceeded");if(!Array.isArray(t)){if(t!=null){let c=t.toString();return c=c0(c,e),c}return""}for(let c=0;c<t.length;c++){let l=t[c],A=A0(l);if(A===void 0)continue;let d=A===e.textNodeName||A===e.cdataPropName||A===e.commentPropName||A[0]==="?"?A:lJ(A,!1,e,n,i),m=Pge(l[":@"],e);n.push(d,m);let p=Dge(n,s);if(d===e.textNodeName){let C=l[A];p||(C=e.tagValueProcessor(d,C),C=c0(C,e)),a&&(o+=r),o+=C,a=!1,n.pop();continue}else if(d===e.cdataPropName){a&&(o+=r);let C=l[A][0][e.textNodeName],I=Lg(C);o+=`<![CDATA[${I}]]>`,a=!1,n.pop();continue}else if(d===e.commentPropName){let C=l[A][0][e.textNodeName],I=Mg(C);o+=r+`<!--${I}-->`,a=!0,n.pop();continue}else if(d[0]==="?"){let C=cJ(l[":@"],e,p,n,i);o+=(d==="?xml"?"":r)+`<${d}${C}?>`,a=!0,n.pop();continue}let f=r;f!==""&&(f+=e.indentBy);let E=cJ(l[":@"],e,p,n,i),g=r+`<${d}${E}`,y;p?y=uJ(l[A],e):y=AJ(l[A],e,f,n,s,i),e.unpairedTags.indexOf(d)!==-1?e.suppressUnpairedNode?o+=g+">":o+=g+"/>":(!y||y.length===0)&&e.suppressEmptyNode?o+=g+"/>":y&&y.endsWith(">")?o+=g+`>${y}${r}</${d}>`:(o+=g+">",y&&r!==""&&(y.includes("/>")||y.includes("</"))?o+=r+e.indentBy+y+r:o+=y,o+=`</${d}>`),a=!0,n.pop()}return o}function Pge(t,e){if(!t||e.ignoreAttributes)return null;let r={},n=!1;for(let s in t){if(!Object.prototype.hasOwnProperty.call(t,s))continue;let i=s.startsWith(e.attributeNamePrefix)?s.substr(e.attributeNamePrefix.length):s;r[i]=xo(t[s]),n=!0}return n?r:null}function uJ(t,e){if(!Array.isArray(t))return t!=null?t.toString():"";let r="";for(let n=0;n<t.length;n++){let s=t[n],i=A0(s);if(i===e.textNodeName)r+=s[i];else if(i===e.cdataPropName)r+=s[i][0][e.textNodeName];else if(i===e.commentPropName)r+=s[i][0][e.textNodeName];else{if(i&&i[0]==="?")continue;if(i){let o=vge(s[":@"],e),a=uJ(s[i],e);!a||a.length===0?r+=`<${i}${o}/>`:r+=`<${i}${o}>${a}</${i}>`}}}return r}function vge(t,e){let r="";if(t&&!e.ignoreAttributes)for(let n in t){if(!Object.prototype.hasOwnProperty.call(t,n))continue;let s=t[n];s===!0&&e.suppressBooleanAttributes?r+=` ${n.substr(e.attributeNamePrefix.length)}`:r+=` ${n.substr(e.attributeNamePrefix.length)}="${xo(s)}"`}return r}function A0(t){let e=Object.keys(t);for(let r=0;r<e.length;r++){let n=e[r];if(Object.prototype.hasOwnProperty.call(t,n)&&n!==":@")return n}}function cJ(t,e,r,n,s){let i="";if(t&&!e.ignoreAttributes)for(let o in t){if(!Object.prototype.hasOwnProperty.call(t,o))continue;let a=o.substr(e.attributeNamePrefix.length),c=r?a:lJ(a,!0,e,n,s),l;r?l=t[o]:(l=e.attributeValueProcessor(o,t[o]),l=c0(l,e)),l===!0&&e.suppressBooleanAttributes?i+=` ${c}`:i+=` ${c}="${xo(l)}"`}return i}function Dge(t,e){if(!e||e.length===0)return!1;for(let r=0;r<e.length;r++)if(t.matches(e[r]))return!0;return!1}function c0(t,e){if(t&&t.length>0&&e.processEntities)for(let r=0;r<e.entities.length;r++){let n=e.entities[r];t=t.replace(n.regex,n.val)}return t}function u0(t){return typeof t=="function"?t:Array.isArray(t)?e=>{for(let r of t)if(typeof r=="string"&&e===r||r instanceof RegExp&&r.test(e))return!0}:()=>!1}var kge={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1,maxNestedTags:100,jPath:!0,sanitizeName:!1};function Er(t){if(this.options=Object.assign({},kge,t),this.options.stopNodes&&Array.isArray(this.options.stopNodes)&&(this.options.stopNodes=this.options.stopNodes.map(e=>typeof e=="string"&&e.startsWith("*.")?".."+e.substring(2):e)),this.stopNodeExpressions=[],this.options.stopNodes&&Array.isArray(this.options.stopNodes))for(let e=0;e<this.options.stopNodes.length;e++){let r=this.options.stopNodes[e];typeof r=="string"?this.stopNodeExpressions.push(new Vr(r)):r instanceof Vr&&this.stopNodeExpressions.push(r)}this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFLine truncated
|
||||
`,"utf-8")],s=wpe(n);s&&t.headers.set("Content-Length",s),t.body=await wY(n)}var nd="multipartPolicy",Spe=70,Rpe=new Set("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");function Ppe(t){if(t.length>Spe)throw new Error(`Multipart boundary "${t}" exceeds maximum length of 70 characters`);if(Array.from(t).some(e=>!Rpe.has(e)))throw new Error(`Multipart boundary "${t}" contains invalid characters`)}function Xf(){return{name:nd,async sendRequest(t,e){if(!t.multipartBody)return e(t);if(t.body)throw new Error("multipartBody and regular body cannot be set at the same time");let r=t.multipartBody.boundary,n=t.headers.get("Content-Type")??"multipart/mixed",s=n.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!s)throw new Error(`Got multipart request body, but content-type header was not multipart: ${n}`);let[,i,o]=s;if(o&&r&&o!==r)throw new Error(`Multipart boundary was specified as ${o} in the header, but got ${r} in the request body`);return r??=o,r?Ppe(r):r=Qpe(),t.headers.set("Content-Type",`${i}; boundary=${r}`),await Npe(t,t.multipartBody.parts,r),t.multipartBody=void 0,e(t)}}}function Zf(){return Bf()}var NY=Ef({logLevelEnvVarName:"AZURE_LOG_LEVEL",namespace:"azure"}),bMe=NY.logger;function Cs(t){return NY.createClientLogger(t)}var Is=Cs("core-rest-pipeline");function nw(t={}){return Sf({logger:Is.info,...t})}var sw=Rf;function iw(t={}){return Pf(t)}var eg=B(require("node:os"),1),tg=B(require("node:process"),1);function SY(){return"User-Agent"}async function RY(t){if(tg.default&&tg.default.versions){let e=`${eg.default.type()} ${eg.default.release()}; ${eg.default.arch()}`,r=tg.default.versions;r.bun?t.set("Bun",`${r.bun} (${e})`):r.deno?t.set("Deno",`${r.deno} (${e})`):r.node&&t.set("Node",`${r.node} (${e})`)}}var rg="1.22.2";function _pe(t){let e=[];for(let[r,n]of t){let s=n?`${r}/${n}`:r;e.push(s)}return e.join(" ")}function PY(){return SY()}async function ng(t){let e=new Map;e.set("core-rest-pipeline",rg),await RY(e);let r=_pe(e);return t?`${t} ${r}`:r}var vY=PY(),DY="userAgentPolicy";function ow(t={}){let e=ng(t.userAgentPrefix);return{name:DY,async sendRequest(r,n){return r.headers.has(vY)||r.headers.set(vY,await e),n(r)}}}var Gr=class extends Error{constructor(e){super(e),this.name="AbortError"}};function aw(t,e){let{cleanupBeforeAbort:r,abortSignal:n,abortErrorMsg:s}=e??{};return new Promise((i,o)=>{function a(){o(new Gr(s??"The operation was aborted."))}function c(){n?.removeEventListener("abort",l)}function l(){r?.(),c(),a()}if(n?.aborted)return a();try{t(A=>{c(),i(A)},A=>{c(),o(A)})}catch(A){o(A)}n?.addEventListener("abort",l)})}var zpe="The delay was aborted.";function sd(t,e){let r,{abortSignal:n,abortErrorMsg:s}=e??{};return aw(i=>{r=setTimeout(i,t)},{cleanupBeforeAbort:()=>clearTimeout(r),abortSignal:n,abortErrorMsg:s??zpe})}function go(t){if(pa(t))return t.message;{let e;try{typeof t=="object"&&t?e=JSON.stringify(t):e=String(t)}catch{e="[unable to stringify input]"}return`Unknown error ${e}`}}function kY(t){return pa(t)}function yl(){return ma()}var Ie=ga;var TY=Symbol("rawContent");function lw(t){return typeof t[TY]=="function"}function MY(t){return lw(t)?t[TY]():t}var sg=nd;function Aw(){let t=Xf();return{name:sg,sendRequest:async(e,r)=>{if(e.multipartBody)for(let n of e.multipartBody.parts)lw(n.body)&&(n.body=MY(n.body));return t.sendRequest(e,r)}}}var uw=vf;function dw(){return Df()}function mw(t={}){return Mf(t)}function pw(){return Lf()}function yo(t){return Xb(t)}function hw(t,e){return Jf(t,e)}var LY="setClientRequestIdPolicy";function fw(t="x-ms-client-request-id"){return{name:LY,async sendRequest(e,r){return e.headers.has(t)||e.headers.set(t,e.requestId),r(e)}}}function gw(t){return Wf(t)}function yw(t){return $f(t)}var El={span:Symbol.for("@azure/core-tracing span"),namespace:Symbol.for("@azure/core-tracing namespace")};function FY(t={}){let e=new Ew(t.parentContext);return t.span&&(e=e.setValue(El.span,t.span)),t.namespace&&(e=e.setValue(El.namespace,t.namespace)),e}var Ew=class t{_contextMap;constructor(e){this._contextMap=e instanceof t?new Map(e._contextMap):new Map}setValue(e,r){let n=new t(this);return n._contextMap.set(e,r),n}getValue(e){return this._contextMap.get(e)}deleteValue(e){let r=new t(this);return r._contextMap.delete(e),r}};var UY=B(_Y(),1),og=UY.state;function Gpe(){return{end:()=>{},isRecording:()=>!1,recordException:()=>{},setAttribute:()=>{},setStatus:()=>{},addEvent:()=>{}}}function Ype(){return{createRequestHeaders:()=>({}),parseTraceparentHeader:()=>{},startSpan:(t,e)=>({span:Gpe(),tracingContext:FY({parentContext:e.tracingContext})}),withContext(t,e,...r){return e(...r)}}}function id(){return og.instrumenterImplementation||(og.instrumenterImplementation=Ype()),og.instrumenterImplementation}function od(t){let{namespace:e,packageName:r,packageVersion:n}=t;function s(l,A,u){let d=id().startSpan(l,{...u,packageName:r,packageVersion:n,tracingContext:A?.tracingOptions?.tracingContext}),m=d.tracingContext,p=d.span;m.getValue(El.na
Line truncated
|
||||
`&&t[i]!=="\r";i++)c+=t[i];if(c=c.trim(),c[c.length-1]==="/"&&(c=c.substring(0,c.length-1),i--),!mfe(c)){let u;return c.trim().length===0?u="Invalid space after '<'.":u="Tag '"+c+"' is an invalid name.",it("InvalidTag",u,rr(t,i))}let l=cfe(t,i);if(l===!1)return it("InvalidAttr","Attributes for '"+c+"' have open quote.",rr(t,i));let A=l.value;if(i=l.index,A[A.length-1]==="/"){let u=i-A.length;A=A.substring(0,A.length-1);let d=CV(A,e);if(d===!0)n=!0;else return it(d.err.code,d.err.msg,rr(t,u+d.err.line))}else if(a)if(l.tagClosed){if(A.trim().length>0)return it("InvalidTag","Closing tag '"+c+"' can't have attributes or invalid starting.",rr(t,o));if(r.length===0)return it("InvalidTag","Closing tag '"+c+"' has not been opened.",rr(t,o));{let u=r.pop();if(c!==u.tagName){let d=rr(t,u.tagStartPos);return it("InvalidTag","Expected closing tag '"+u.tagName+"' (opened in line "+d.line+", col "+d.col+") instead of closing tag '"+c+"'.",rr(t,o))}r.length==0&&(s=!0)}}else return it("InvalidTag","Closing tag '"+c+"' doesn't have proper closing.",rr(t,i));else{let u=CV(A,e);if(u!==!0)return it(u.err.code,u.err.msg,rr(t,i-A.length+u.err.line));if(s===!0)return it("InvalidXml","Multiple possible root nodes found.",rr(t,i));e.unpairedTags.indexOf(c)!==-1||r.push({tagName:c,tagStartPos:o}),n=!0}for(i++;i<t.length;i++)if(t[i]==="<")if(t[i+1]==="!"){i++,i=EV(t,i);continue}else if(t[i+1]==="?"){if(i=yV(t,++i),i.err)return i}else break;else if(t[i]==="&"){let u=ufe(t,i);if(u==-1)return it("InvalidChar","char '&' is not expected.",rr(t,i));i=u}else if(s===!0&&!gV(t[i]))return it("InvalidXml","Extra text at the end",rr(t,i));t[i]==="<"&&i--}}else{if(gV(t[i]))continue;return it("InvalidChar","char '"+t[i]+"' is not expected.",rr(t,i))}if(n){if(r.length==1)return it("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",rr(t,r[0].tagStartPos));if(r.length>0)return it("InvalidXml","Invalid '"+JSON.stringify(r.map(i=>i.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return it("InvalidXml","Start tag expected.",1);return!0}function gV(t){return t===" "||t===" "||t===`
|
||||
`||t==="\r"}function yV(t,e){let r=e;for(;e<t.length;e++)if(t[e]=="?"||t[e]==" "){let n=t.substr(r,e-r);if(e>5&&n==="xml")return it("InvalidXml","XML declaration allowed only at the start of the document.",rr(t,e));if(t[e]=="?"&&t[e+1]==">"){e++;break}else continue}return e}function EV(t,e){if(t.length>e+5&&t[e+1]==="-"&&t[e+2]==="-"){for(e+=3;e<t.length;e++)if(t[e]==="-"&&t[e+1]==="-"&&t[e+2]===">"){e+=2;break}}else if(t.length>e+8&&t[e+1]==="D"&&t[e+2]==="O"&&t[e+3]==="C"&&t[e+4]==="T"&&t[e+5]==="Y"&&t[e+6]==="P"&&t[e+7]==="E"){let r=1;for(e+=8;e<t.length;e++)if(t[e]==="<")r++;else if(t[e]===">"&&(r--,r===0))break}else if(t.length>e+9&&t[e+1]==="["&&t[e+2]==="C"&&t[e+3]==="D"&&t[e+4]==="A"&&t[e+5]==="T"&&t[e+6]==="A"&&t[e+7]==="["){for(e+=8;e<t.length;e++)if(t[e]==="]"&&t[e+1]==="]"&&t[e+2]===">"){e+=2;break}}return e}var ofe='"',afe="'";function cfe(t,e){let r="",n="",s=!1;for(;e<t.length;e++){if(t[e]===ofe||t[e]===afe)n===""?n=t[e]:n!==t[e]||(n="");else if(t[e]===">"&&n===""){s=!0;break}r+=t[e]}return n!==""?!1:{value:r,index:e,tagClosed:s}}var lfe=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function CV(t,e){let r=hg(t,lfe),n={};for(let s=0;s<r.length;s++){if(r[s][1].length===0)return it("InvalidAttr","Attribute '"+r[s][2]+"' has no space in starting.",fd(r[s]));if(r[s][3]!==void 0&&r[s][4]===void 0)return it("InvalidAttr","Attribute '"+r[s][2]+"' is without value.",fd(r[s]));if(r[s][3]===void 0&&!e.allowBooleanAttributes)return it("InvalidAttr","boolean attribute '"+r[s][2]+"' is not allowed.",fd(r[s]));let i=r[s][2];if(!dfe(i))return it("InvalidAttr","Attribute '"+i+"' is an invalid name.",fd(r[s]));if(!Object.prototype.hasOwnProperty.call(n,i))n[i]=1;else return it("InvalidAttr","Attribute '"+i+"' is repeated.",fd(r[s]))}return!0}function Afe(t,e){let r=/\d/;for(t[e]==="x"&&(e++,r=/[\da-fA-F]/);e<t.length;e++){if(t[e]===";")return e;if(!t[e].match(r))break}return-1}function ufe(t,e){if(e++,t[e]===";")return-1;if(t[e]==="#")return e++,Afe(t,e);let r=0;for(;e<t.length;e++,r++)if(!(t[e].match(/\w/)&&r<20)){if(t[e]===";")break;return-1}return e}function it(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}function dfe(t){return Fw(t)}function mfe(t){return Fw(t)}function rr(t,e){let r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function fd(t){return t.startIndex+t[1].length}var IV={amp:"&",AMP:"&",lt:"<",LT:"<",gt:">",GT:">",quot:'"',QUOT:'"',apos:"'",lsquo:"\u2018",rsquo:"\u2019",ldquo:"\u201C",rdquo:"\u201D",lsquor:"\u201A",rsquor:"\u2019",ldquor:"\u201E",bdquo:"\u201E",comma:",",period:".",colon:":",semi:";",excl:"!",quest:"?",num:"#",dollar:"$",percent:"%",amp:"&",ast:"*",commat:"@",lowbar:"_",verbar:"|",vert:"|",sol:"/",bsol:"\\",lbrace:"{",rbrace:"}",lbrack:"[",rbrack:"]",lpar:"(",rpar:")",nbsp:"\xA0",iexcl:"\xA1",cent:"\xA2",pound:"\xA3",curren:"\xA4",yen:"\xA5",brvbar:"\xA6",sect:"\xA7",uml:"\xA8",copy:"\xA9",COPY:"\xA9",ordf:"\xAA",laquo:"\xAB",not:"\xAC",shy:"\xAD",reg:"\xAE",REG:"\xAE",macr:"\xAF",deg:"\xB0",plusmn:"\xB1",sup2:"\xB2",sup3:"\xB3",acute:"\xB4",micro:"\xB5",para:"\xB6",middot:"\xB7",cedil:"\xB8",sup1:"\xB9",ordm:"\xBA",raquo:"\xBB",frac14:"\xBC",frac12:"\xBD",half:"\xBD",frac34:"\xBE",iquest:"\xBF",times:"\xD7",div:"\xF7",divide:"\xF7"},BV={Agrave:"\xC0",agrave:"\xE0",Aacute:"\xC1",aacute:"\xE1",Acirc:"\xC2",acirc:"\xE2",Atilde:"\xC3",atilde:"\xE3",Auml:"\xC4",auml:"\xE4",Aring:"\xC5",aring:"\xE5",AElig:"\xC6",aelig:"\xE6",Ccedil:"\xC7",ccedil:"\xE7",Egrave:"\xC8",egrave:"\xE8",Eacute:"\xC9",eacute:"\xE9",Ecirc:"\xCA",ecirc:"\xEA",Euml:"\xCB",euml:"\xEB",Igrave:"\xCC",igrave:"\xEC",Iacute:"\xCD",iacute:"\xED",Icirc:"\xCE",icirc:"\xEE",Iuml:"\xCF",iuml:"\xEF",ETH:"\xD0",eth:"\xF0",Ntilde:"\xD1",ntilde:"\xF1",Ograve:"\xD2",ograve:"\xF2",Oacute:"\xD3",oacute:"\xF3",Ocirc:"\xD4",ocirc:"\xF4",Otilde:"\xD5",otilde:"\xF5",Ouml:"\xD6",ouml:"\xF6",Oslash:"\xD8",oslash:"\xF8",Ugrave:"\xD9",ugrave:"\xF9",Uacute:"\xDA",uacute:"\xFA",Ucirc:"\xDB",ucirc:"\xFB",Uuml:"\xDC",uuml:"\xFC",Yacute:"\xDD",yacute:"\xFD",THORN:"\xDE",thorn:"\xFE",szlig:"\xDF",yuml:"\xFF",Yuml:"\u0178"},QV={Amacr:"\u0100",amacr:"\u0101",Abreve:"\u0102",abreve:"\u0103",Aogon:"\u0104",aogon:"\u0105",Cacute:"\u0106",cacute:"\u0107",Ccirc:"\u0108",ccirc:"\u0109",Cdot:"\u010A",cdot:"\u010B",Ccaron:"\u010C",ccaron:"\u010D",Dcaron:"\u010E",dcaron:"\u010F",Dstrok:"\u0110",dstrok:"\u0111",Emacr:"\u0112",emacr:"\u0113",Ecaron:"\u011A",ecaron:"\u011B",Edot:"\u0116",edot:"\u0117",Eogon:"\u0118",eogon:"\u0119",Gcirc:"\u011C",gcirc:"\u011D",Gbreve:"\u011E",gbreve:"\u011F",Gdot:"\u0120",gdot:"\u0121",Gcedil:"\u0122",Hcirc:"\u0124",hcirc:"\u0125",Hstrok:"\u0126",hstrok:"\u0127",Itilde:"\u0128",itilde:"\u0129",Imacr:"\u012A",imacr:"\u012B",Iogon:"\u012E",iogon:"\u012F",Idot:"\u0130",IJlig:"\u0132",ijlig:"\u0133",Jcirc:"\u0134",jcirc:"\u0135",Kcedil:"\u0136",kcedil:"\u0137",kgreen:"\u0138",Lacute:"\u0139",lacute:"\u013A",Lcedil:"\u013B",lcedil:"\u013C",Lcaron:"\u0Line truncated
|
||||
`);let e=new Er("!xml"),r=e,n="";this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let s=this.options,i=new Ed(s.processEntities),o=t.length;for(let a=0;a<o;a++)if(t[a]==="<"){let l=t.charCodeAt(a+1);if(l===47){let A=xl(t,">",a,"Closing Tag is not closed."),u=t.substring(a+2,A).trim();if(s.removeNSPrefix){let m=u.indexOf(":");m!==-1&&(u=u.substr(m+1))}u=Yw(s.transformTagName,u,"",s).tagName,r&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher));let d=this.matcher.getCurrentTag();if(u&&s.unpairedTagsSet.has(u))throw new Error(`Unpaired tag can not be used as closing tag: </${u}>`);d&&s.unpairedTagsSet.has(d)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,r=this.tagsNodeStack.pop(),n="",a=A}else if(l===63){let A=Vw(t,a,!1,"?>");if(!A)throw new Error("Pi Tag is not closed.");n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let u=this.buildAttributesMap(A.tagExp,this.matcher,A.tagName,!0);if(u){let d=u[this.options.attributeNamePrefix+"version"];this.entityDecoder.setXmlVersion(Number(d)||1),i.setXmlVersion(Number(d)||1)}if(!(s.ignoreDeclaration&&A.tagName==="?xml"||s.ignorePiTags)){let d=new Er(A.tagName);d.add(s.textNodeName,""),A.tagName!==A.tagExp&&A.attrExpPresent&&s.ignoreAttributes!==!0&&(d[":@"]=u),this.addChild(r,d,this.readonlyMatcher,a)}a=A.closeIndex+1}else if(l===33&&t.charCodeAt(a+2)===45&&t.charCodeAt(a+3)===45){let A=xl(t,"-->",a+4,"Comment is not closed.");if(s.commentPropName){let u=t.substring(a+4,A-2);n=this.saveTextToParentTag(n,r,this.readonlyMatcher),r.add(s.commentPropName,[{[s.textNodeName]:u}])}a=A}else if(l===33&&t.charCodeAt(a+2)===68){let A=i.readDocType(t,a);this.entityDecoder.addInputEntities(A.entities),a=A.i}else if(l===33&&t.charCodeAt(a+2)===91){let A=xl(t,"]]>",a,"CDATA is not closed.")-2,u=t.substring(a+9,A);n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let d=this.parseTextData(u,r.tagname,this.readonlyMatcher,!0,!1,!0,!0);d==null&&(d=""),s.cdataPropName?r.add(s.cdataPropName,[{[s.textNodeName]:u}]):r.add(s.textNodeName,d),a=A+2}else{let A=Vw(t,a,s.removeNSPrefix);if(!A){let D=t.substring(Math.max(0,a-50),Math.min(o,a+50));throw new Error(`readTagExp returned undefined at position ${a}. Context: "${D}"`)}let u=A.tagName,d=A.rawTagName,m=A.tagExp,p=A.attrExpPresent,f=A.closeIndex;if({tagName:u,tagExp:m}=Yw(s.transformTagName,u,m,s),s.strictReservedNames&&(u===s.commentPropName||u===s.cdataPropName||u===s.textNodeName||u===s.attributesGroupName))throw new Error(`Invalid tag name: ${u}`);r&&n&&r.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher,!1));let E=r;E&&s.unpairedTagsSet.has(E.tagname)&&(r=this.tagsNodeStack.pop(),this.matcher.pop());let g=!1;m.length>0&&m.lastIndexOf("/")===m.length-1&&(g=!0,u[u.length-1]==="/"?(u=u.substr(0,u.length-1),m=u):m=m.substr(0,m.length-1),p=u!==m);let y=null,C={},I;I=Lfe(d),u!==e.tagname&&this.matcher.push(u,{},I),u!==m&&p&&(y=this.buildAttributesMap(m,this.matcher,u),y&&(C=Mfe(y,s))),u!==e.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let w=a;if(this.isCurrentNodeStopNode){let D="";if(g)a=A.closeIndex;else if(s.unpairedTagsSet.has(u))a=A.closeIndex;else{let ae=this.readStopNodeData(t,d,f+1);if(!ae)throw new Error(`Unexpected end of ${d}`);a=ae.i,D=ae.tagContent}let F=new Er(u);y&&(F[":@"]=y),F.add(s.textNodeName,D),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(r,F,this.readonlyMatcher,w)}else{if(g){({tagName:u,tagExp:m}=Yw(s.transformTagName,u,m,s));let D=new Er(u);y&&(D[":@"]=y),this.addChild(r,D,this.readonlyMatcher,w),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else if(s.unpairedTagsSet.has(u)){let D=new Er(u);y&&(D[":@"]=y),this.addChild(r,D,this.readonlyMatcher,w),this.matcher.pop(),this.isCurrentNodeStopNode=!1,a=A.closeIndex;continue}else{let D=new Er(u);if(this.tagsNodeStack.length>s.maxNestedTags)throw new Error("Maximum nested tags exceeded");this.tagsNodeStack.push(r),y&&(D[":@"]=y),this.addChild(r,D,this.readonlyMatcher,w),r=D}n="",a=f}}}else n+=t[a];return e.child};function Hfe(t,e,r,n){this.options.captureMetaData||(n=void 0);let s=this.options.jPath?r.toString():r,i=this.options.updateTag(e.tagname,s,e[":@"]);i===!1||(typeof i=="string"&&(e.tagname=i),t.addChild(e,n))}function zfe(t,e,r){let n=this.options.processEntities;if(!n||!n.enabled)return t;if(n.allowedTags){let s=this.options.jPath?r.toString():r;if(!(Array.isArray(n.allowedTags)?n.allowedTags.includes(e):n.allowedTags(e,s)))return t}if(n.tagFilter){let s=this.options.jPath?r.toString():r;if(!n.tagFilter(e,s))return t}return this.entityDecoder.decode(t)}function Gfe(t,e,r,n){return t&&(n===void 0&&(n=e.child.length===0),t=this.parseTextData(t,e.tagname,r,!1,e[":@"]?Object.keys(e[":@"]).length!==0:!1,n),t!==void 0&&t!==""&&e.add(this.options.textNodeName,t),t=""),t}function Yfe(){return this.stopNodeExpressionsSet.size===0?!1:this.matcher.matchesAny(this.stopNodeExpressionsSet)}function Vfe(t,e,r="Line truncated
|
||||
`;function ege(t,e){if(!Array.isArray(t)||t.length===0)return"1.0";let r=t[0];if(Xw(r)==="?xml"){let s=r[":@"];if(s){let i=e.attributeNamePrefix+"version";if(s[i])return s[i]}}return"1.0"}function zV(t,e,r,n,s){return!r.sanitizeName||Ba(t,{xmlVersion:s})?t:r.sanitizeName(t,{isAttribute:e,matcher:n.readOnly()})}function Kw(t,e){let r="";e.format&&(r=Zfe);let n=[];if(e.stopNodes&&Array.isArray(e.stopNodes))for(let o=0;o<e.stopNodes.length;o++){let a=e.stopNodes[o];typeof a=="string"?n.push(new Jr(a)):a instanceof Jr&&n.push(a)}let s=ege(t,e),i=new xs;return GV(t,e,r,i,n,s)}function GV(t,e,r,n,s,i){let o="",a=!1;if(e.maxNestedTags&&n.getDepth()>e.maxNestedTags)throw new Error("Maximum nested tags exceeded");if(!Array.isArray(t)){if(t!=null){let c=t.toString();return c=jw(c,e),c}return""}for(let c=0;c<t.length;c++){let l=t[c],A=Xw(l);if(A===void 0)continue;let d=A===e.textNodeName||A===e.cdataPropName||A===e.commentPropName||A[0]==="?"?A:zV(A,!1,e,n,i),m=tge(l[":@"],e);n.push(d,m);let p=nge(n,s);if(d===e.textNodeName){let C=l[A];p||(C=e.tagValueProcessor(d,C),C=jw(C,e)),a&&(o+=r),o+=C,a=!1,n.pop();continue}else if(d===e.cdataPropName){a&&(o+=r);let C=l[A][0][e.textNodeName],I=Bg(C);o+=`<![CDATA[${I}]]>`,a=!1,n.pop();continue}else if(d===e.commentPropName){let C=l[A][0][e.textNodeName],I=Ig(C);o+=r+`<!--${I}-->`,a=!0,n.pop();continue}else if(d[0]==="?"){let C=HV(l[":@"],e,p,n,i);o+=(d==="?xml"?"":r)+`<${d}${C}?>`,a=!0,n.pop();continue}let f=r;f!==""&&(f+=e.indentBy);let E=HV(l[":@"],e,p,n,i),g=r+`<${d}${E}`,y;p?y=YV(l[A],e):y=GV(l[A],e,f,n,s,i),e.unpairedTags.indexOf(d)!==-1?e.suppressUnpairedNode?o+=g+">":o+=g+"/>":(!y||y.length===0)&&e.suppressEmptyNode?o+=g+"/>":y&&y.endsWith(">")?o+=g+`>${y}${r}</${d}>`:(o+=g+">",y&&r!==""&&(y.includes("/>")||y.includes("</"))?o+=r+e.indentBy+y+r:o+=y,o+=`</${d}>`),a=!0,n.pop()}return o}function tge(t,e){if(!t||e.ignoreAttributes)return null;let r={},n=!1;for(let s in t){if(!Object.prototype.hasOwnProperty.call(t,s))continue;let i=s.startsWith(e.attributeNamePrefix)?s.substr(e.attributeNamePrefix.length):s;r[i]=Io(t[s]),n=!0}return n?r:null}function YV(t,e){if(!Array.isArray(t))return t!=null?t.toString():"";let r="";for(let n=0;n<t.length;n++){let s=t[n],i=Xw(s);if(i===e.textNodeName)r+=s[i];else if(i===e.cdataPropName)r+=s[i][0][e.textNodeName];else if(i===e.commentPropName)r+=s[i][0][e.textNodeName];else{if(i&&i[0]==="?")continue;if(i){let o=rge(s[":@"],e),a=YV(s[i],e);!a||a.length===0?r+=`<${i}${o}/>`:r+=`<${i}${o}>${a}</${i}>`}}}return r}function rge(t,e){let r="";if(t&&!e.ignoreAttributes)for(let n in t){if(!Object.prototype.hasOwnProperty.call(t,n))continue;let s=t[n];s===!0&&e.suppressBooleanAttributes?r+=` ${n.substr(e.attributeNamePrefix.length)}`:r+=` ${n.substr(e.attributeNamePrefix.length)}="${Io(s)}"`}return r}function Xw(t){let e=Object.keys(t);for(let r=0;r<e.length;r++){let n=e[r];if(Object.prototype.hasOwnProperty.call(t,n)&&n!==":@")return n}}function HV(t,e,r,n,s){let i="";if(t&&!e.ignoreAttributes)for(let o in t){if(!Object.prototype.hasOwnProperty.call(t,o))continue;let a=o.substr(e.attributeNamePrefix.length),c=r?a:zV(a,!0,e,n,s),l;r?l=t[o]:(l=e.attributeValueProcessor(o,t[o]),l=jw(l,e)),l===!0&&e.suppressBooleanAttributes?i+=` ${c}`:i+=` ${c}="${Io(l)}"`}return i}function nge(t,e){if(!e||e.length===0)return!1;for(let r=0;r<e.length;r++)if(t.matches(e[r]))return!0;return!1}function jw(t,e){if(t&&t.length>0&&e.processEntities)for(let r=0;r<e.entities.length;r++){let n=e.entities[r];t=t.replace(n.regex,n.val)}return t}function Zw(t){return typeof t=="function"?t:Array.isArray(t)?e=>{for(let r of t)if(typeof r=="string"&&e===r||r instanceof RegExp&&r.test(e))return!0}:()=>!1}var sge={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1,maxNestedTags:100,jPath:!0,sanitizeName:!1};function Ir(t){if(this.options=Object.assign({},sge,t),this.options.stopNodes&&Array.isArray(this.options.stopNodes)&&(this.options.stopNodes=this.options.stopNodes.map(e=>typeof e=="string"&&e.startsWith("*.")?".."+e.substring(2):e)),this.stopNodeExpressions=[],this.options.stopNodes&&Array.isArray(this.options.stopNodes))for(let e=0;e<this.options.stopNodes.length;e++){let r=this.options.stopNodes[e];typeof r=="string"?this.stopNodeExpressions.push(new Jr(r)):r instanceof Jr&&this.stopNodeExpressions.push(r)}this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFLine truncated
|
||||
`,this.newLine=`
|
||||
`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function Tge(t,e){let r=t["?xml"];if(r&&typeof r=="object"){if(e.attributesGroupName&&r[e.attributesGroupName]){let s=r[e.attributesGroupName][e.attributeNamePrefix+"version"];if(s)return s}let n=r[e.attributeNamePrefix+"version"];if(n)return n}return"1.0"}function d0(t,e,r,n,s){return!r.sanitizeName||Na(t,{xmlVersion:s})?t:r.sanitizeName(t,{isAttribute:e,matcher:n.readOnly()})}Er.prototype.build=function(t){if(this.options.preserveOrder)return l0(t,this.options);{Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t});let e=new ws,r=Tge(t,this.options);return this.j2x(t,0,e,r).val}};Er.prototype.j2x=function(t,e,r,n){let s="",i="";if(this.options.maxNestedTags&&r.getDepth()>=this.options.maxNestedTags)throw new Error("Maximum nested tags exceeded");let o=this.options.jPath?r.toString():r,a=this.checkStopNode(r);for(let c in t){if(!Object.prototype.hasOwnProperty.call(t,c))continue;let A=c===this.options.textNodeName||c===this.options.cdataPropName||c===this.options.commentPropName||this.options.attributesGroupName&&c===this.options.attributesGroupName||this.isAttribute(c)||c[0]==="?"?c:d0(c,!1,this.options,r,n);if(typeof t[c]>"u")this.isAttribute(c)&&(i+="");else if(t[c]===null)this.isAttribute(c)||A===this.options.cdataPropName||A===this.options.commentPropName?i+="":A[0]==="?"?i+=this.indentate(e)+"<"+A+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+A+"/"+this.tagEndChar;else if(t[c]instanceof Date)i+=this.buildTextValNode(t[c],A,"",e,r);else if(typeof t[c]!="object"){let u=this.isAttribute(c);if(u&&!this.ignoreAttributesFn(u,o)){let d=d0(u,!0,this.options,r,n);s+=this.buildAttrPairStr(d,""+t[c],a)}else if(!u)if(c===this.options.textNodeName){let d=this.options.tagValueProcessor(c,""+t[c]);i+=this.replaceEntitiesValue(d)}else{r.push(A);let d=this.checkStopNode(r);if(r.pop(),d){let m=""+t[c];m===""?i+=this.indentate(e)+"<"+A+this.closeTag(A)+this.tagEndChar:i+=this.indentate(e)+"<"+A+">"+m+"</"+A+this.tagEndChar}else i+=this.buildTextValNode(t[c],A,"",e,r)}}else if(Array.isArray(t[c])){let u=t[c].length,d="",m="";for(let p=0;p<u;p++){let f=t[c][p];if(!(typeof f>"u"))if(f===null)A[0]==="?"?i+=this.indentate(e)+"<"+A+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+A+"/"+this.tagEndChar;else if(typeof f=="object")if(this.options.oneListGroup){r.push(A);let E=this.j2x(f,e+1,r,n);r.pop(),d+=E.val,this.options.attributesGroupName&&f.hasOwnProperty(this.options.attributesGroupName)&&(m+=E.attrStr)}else d+=this.processTextOrObjNode(f,A,e,r,n);else if(this.options.oneListGroup){let E=this.options.tagValueProcessor(A,f);E=this.replaceEntitiesValue(E),d+=E}else{r.push(A);let E=this.checkStopNode(r);if(r.pop(),E){let g=""+f;g===""?d+=this.indentate(e)+"<"+A+this.closeTag(A)+this.tagEndChar:d+=this.indentate(e)+"<"+A+">"+g+"</"+A+this.tagEndChar}else d+=this.buildTextValNode(f,A,"",e,r)}}this.options.oneListGroup&&(d=this.buildObjectNode(d,A,m,e)),i+=d}else if(this.options.attributesGroupName&&c===this.options.attributesGroupName){let u=Object.keys(t[c]),d=u.length;for(let m=0;m<d;m++){let p=d0(u[m],!0,this.options,r,n);s+=this.buildAttrPairStr(p,""+t[c][u[m]],a)}}else i+=this.processTextOrObjNode(t[c],A,e,r,n)}return{attrStr:s,val:i}};Er.prototype.buildAttrPairStr=function(t,e,r){return r||(e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e)),this.options.suppressBooleanAttributes&&e==="true"?" "+t:" "+t+'="'+xo(e)+'"'};function Mge(t,e,r,n,s){let i=this.extractAttributes(t);if(n.push(e,i),this.checkStopNode(n)){let c=this.buildRawContent(t),l=this.buildAttributesForStopNode(t);return n.pop(),this.buildObjectNode(c,e,l,r)}let a=this.j2x(t,r+1,n,s);return n.pop(),e[0]==="?"?this.buildTextValNode("",e,a.attrStr,r,n):t[this.options.textNodeName]!==void 0&&Object.keys(t).length===1?this.buildTextValNode(t[this.options.textNodeName],e,a.attrStr,r,n):this.buildObjectNode(a.val,e,a.attrStr,r)}Er.prototype.extractAttributes=function(t){if(!t||typeof t!="object")return null;let e={},r=!1;if(this.options.attributesGroupName&&t[this.options.attributesGroupName]){let n=t[this.options.attributesGroupName];for(let s in n){if(!Object.prototype.hasOwnProperty.call(n,s))continue;let i=s.startsWith(this.options.attributeNamePrefix)?s.substring(this.options.attributeNamePrefix.length):s;e[i]=xo(n[s]),r=!0}}else for(let n in t){if(!Object.prototype.hasOwnProperty.call(t,n))continue;let s=this.isAttribute(n);s&&(e[s]=xo(t[n]),r=!0)}return r?e:null};Er.prototype.buildRawContent=function(t){if(typeof t=="string")return t;if(typeof t!="object"||t===null)return String(t);if(t[this.options.textNodeName]!==void 0)return t[this.options.textNodeName];let e="";for(let r in t){if(!Object.prototype.hasOwnProperty.call(t,r)||this.isAttribute(r)||this.options.attributesGroupName&&r===this.options.attributesGroupName)continue;let n=t[r];if(r===this.options.textNodeName)e+=n;else if(Array.isA
Line truncated
|
||||
`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function ige(t,e){let r=t["?xml"];if(r&&typeof r=="object"){if(e.attributesGroupName&&r[e.attributesGroupName]){let s=r[e.attributesGroupName][e.attributeNamePrefix+"version"];if(s)return s}let n=r[e.attributeNamePrefix+"version"];if(n)return n}return"1.0"}function eN(t,e,r,n,s){return!r.sanitizeName||Ba(t,{xmlVersion:s})?t:r.sanitizeName(t,{isAttribute:e,matcher:n.readOnly()})}Ir.prototype.build=function(t){if(this.options.preserveOrder)return Kw(t,this.options);{Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t});let e=new xs,r=ige(t,this.options);return this.j2x(t,0,e,r).val}};Ir.prototype.j2x=function(t,e,r,n){let s="",i="";if(this.options.maxNestedTags&&r.getDepth()>=this.options.maxNestedTags)throw new Error("Maximum nested tags exceeded");let o=this.options.jPath?r.toString():r,a=this.checkStopNode(r);for(let c in t){if(!Object.prototype.hasOwnProperty.call(t,c))continue;let A=c===this.options.textNodeName||c===this.options.cdataPropName||c===this.options.commentPropName||this.options.attributesGroupName&&c===this.options.attributesGroupName||this.isAttribute(c)||c[0]==="?"?c:eN(c,!1,this.options,r,n);if(typeof t[c]>"u")this.isAttribute(c)&&(i+="");else if(t[c]===null)this.isAttribute(c)||A===this.options.cdataPropName||A===this.options.commentPropName?i+="":A[0]==="?"?i+=this.indentate(e)+"<"+A+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+A+"/"+this.tagEndChar;else if(t[c]instanceof Date)i+=this.buildTextValNode(t[c],A,"",e,r);else if(typeof t[c]!="object"){let u=this.isAttribute(c);if(u&&!this.ignoreAttributesFn(u,o)){let d=eN(u,!0,this.options,r,n);s+=this.buildAttrPairStr(d,""+t[c],a)}else if(!u)if(c===this.options.textNodeName){let d=this.options.tagValueProcessor(c,""+t[c]);i+=this.replaceEntitiesValue(d)}else{r.push(A);let d=this.checkStopNode(r);if(r.pop(),d){let m=""+t[c];m===""?i+=this.indentate(e)+"<"+A+this.closeTag(A)+this.tagEndChar:i+=this.indentate(e)+"<"+A+">"+m+"</"+A+this.tagEndChar}else i+=this.buildTextValNode(t[c],A,"",e,r)}}else if(Array.isArray(t[c])){let u=t[c].length,d="",m="";for(let p=0;p<u;p++){let f=t[c][p];if(!(typeof f>"u"))if(f===null)A[0]==="?"?i+=this.indentate(e)+"<"+A+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+A+"/"+this.tagEndChar;else if(typeof f=="object")if(this.options.oneListGroup){r.push(A);let E=this.j2x(f,e+1,r,n);r.pop(),d+=E.val,this.options.attributesGroupName&&f.hasOwnProperty(this.options.attributesGroupName)&&(m+=E.attrStr)}else d+=this.processTextOrObjNode(f,A,e,r,n);else if(this.options.oneListGroup){let E=this.options.tagValueProcessor(A,f);E=this.replaceEntitiesValue(E),d+=E}else{r.push(A);let E=this.checkStopNode(r);if(r.pop(),E){let g=""+f;g===""?d+=this.indentate(e)+"<"+A+this.closeTag(A)+this.tagEndChar:d+=this.indentate(e)+"<"+A+">"+g+"</"+A+this.tagEndChar}else d+=this.buildTextValNode(f,A,"",e,r)}}this.options.oneListGroup&&(d=this.buildObjectNode(d,A,m,e)),i+=d}else if(this.options.attributesGroupName&&c===this.options.attributesGroupName){let u=Object.keys(t[c]),d=u.length;for(let m=0;m<d;m++){let p=eN(u[m],!0,this.options,r,n);s+=this.buildAttrPairStr(p,""+t[c][u[m]],a)}}else i+=this.processTextOrObjNode(t[c],A,e,r,n)}return{attrStr:s,val:i}};Ir.prototype.buildAttrPairStr=function(t,e,r){return r||(e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e)),this.options.suppressBooleanAttributes&&e==="true"?" "+t:" "+t+'="'+Io(e)+'"'};function oge(t,e,r,n,s){let i=this.extractAttributes(t);if(n.push(e,i),this.checkStopNode(n)){let c=this.buildRawContent(t),l=this.buildAttributesForStopNode(t);return n.pop(),this.buildObjectNode(c,e,l,r)}let a=this.j2x(t,r+1,n,s);return n.pop(),e[0]==="?"?this.buildTextValNode("",e,a.attrStr,r,n):t[this.options.textNodeName]!==void 0&&Object.keys(t).length===1?this.buildTextValNode(t[this.options.textNodeName],e,a.attrStr,r,n):this.buildObjectNode(a.val,e,a.attrStr,r)}Ir.prototype.extractAttributes=function(t){if(!t||typeof t!="object")return null;let e={},r=!1;if(this.options.attributesGroupName&&t[this.options.attributesGroupName]){let n=t[this.options.attributesGroupName];for(let s in n){if(!Object.prototype.hasOwnProperty.call(n,s))continue;let i=s.startsWith(this.options.attributeNamePrefix)?s.substring(this.options.attributeNamePrefix.length):s;e[i]=Io(n[s]),r=!0}}else for(let n in t){if(!Object.prototype.hasOwnProperty.call(t,n))continue;let s=this.isAttribute(n);s&&(e[s]=Io(t[n]),r=!0)}return r?e:null};Ir.prototype.buildRawContent=function(t){if(typeof t=="string")return t;if(typeof t!="object"||t===null)return String(t);if(t[this.options.textNodeName]!==void 0)return t[this.options.textNodeName];let e="";for(let r in t){if(!Object.prototype.hasOwnProperty.call(t,r)||this.isAttribute(r)||this.options.attributesGroupName&&r===this.options.attributesGroupName)continue;let n=t[r];if(r===this.options.textNodeName)e+=n;else if(Array.isA
Line truncated
|
||||
`)+`
|
||||
`+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e),n=this.factory.computeHMACSHA256(r);return e.headers.set(X.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${n}`),e}getHeaderValueToSign(e,r){let n=e.headers.get(r);return!n||r===X.CONTENT_LENGTH&&n==="0"?"":n}getCanonicalizedHeadersString(e){let r=e.headers.headersArray().filter(s=>s.name.toLowerCase().startsWith(X.PREFIX_FOR_STORAGE));r.sort((s,i)=>Jg(s.name.toLowerCase(),i.name.toLowerCase())),r=r.filter((s,i,o)=>!(i>0&&s.name.toLowerCase()===o[i-1].name.toLowerCase()));let n="";return r.forEach(s=>{n+=`${s.name.toLowerCase().trimRight()}:${s.value.trimLeft()}
|
||||
`}),n}getCanonicalizedResourceString(e){let r=Gg(e.url)||"/",n="";n+=`/${this.factory.accountName}${r}`;let s=Yg(e.url),i={};if(s){let o=[];for(let a in s)if(Object.prototype.hasOwnProperty.call(s,a)){let c=a.toLowerCase();i[c]=s[a],o.push(c)}o.sort();for(let a of o)n+=`
|
||||
${a}:${decodeURIComponent(i[a])}`}return n}};var Je=class extends Pa{accountName;accountKey;constructor(e,r){super(),this.accountName=e,this.accountKey=Buffer.from(r,"base64")}create(e,r){return new Dd(e,r,this)}computeHMACSHA256(e){return(0,EJ.createHmac)("sha256",this.accountKey).update(e,"utf8").digest("base64")}};var gt=Is("storage-common");var gn;(function(t){t[t.EXPONENTIAL=0]="EXPONENTIAL",t[t.FIXED=1]="FIXED"})(gn||(gn={}));var bo={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:gn.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},Gge=new zr("The operation was aborted."),kd=class extends bs{retryOptions;constructor(e,r,n=bo){super(e,r),this.retryOptions={retryPolicyType:n.retryPolicyType?n.retryPolicyType:bo.retryPolicyType,maxTries:n.maxTries&&n.maxTries>=1?Math.floor(n.maxTries):bo.maxTries,tryTimeoutInMs:n.tryTimeoutInMs&&n.tryTimeoutInMs>=0?n.tryTimeoutInMs:bo.tryTimeoutInMs,retryDelayInMs:n.retryDelayInMs&&n.retryDelayInMs>=0?Math.min(n.retryDelayInMs,n.maxRetryDelayInMs?n.maxRetryDelayInMs:bo.maxRetryDelayInMs):bo.retryDelayInMs,maxRetryDelayInMs:n.maxRetryDelayInMs&&n.maxRetryDelayInMs>=0?n.maxRetryDelayInMs:bo.maxRetryDelayInMs,secondaryHost:n.secondaryHost?n.secondaryHost:bo.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,!1,1)}async attemptSendRequest(e,r,n){let s=e.clone(),i=r||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||n%2===1;i||(s.url=zg(s.url,this.retryOptions.secondaryHost)),this.retryOptions.tryTimeoutInMs&&(s.url=wo(s.url,Qi.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString()));let o;try{if(gt.info(`RetryPolicy: =====> Try=${n} ${i?"Primary":"Secondary"}`),o=await this._nextPolicy.sendRequest(s),!this.shouldRetry(i,n,o))return o;r=r||!i&&o.status===404}catch(a){if(gt.error(`RetryPolicy: Caught error, message: ${a.message}, code: ${a.code}`),!this.shouldRetry(i,n,o,a))throw a}return await this.delay(i,n,e.abortSignal),this.attemptSendRequest(e,r,++n)}shouldRetry(e,r,n,s){if(r>=this.retryOptions.maxTries)return gt.info(`RetryPolicy: Attempt(s) ${r} >= maxTries ${this.retryOptions.maxTries}, no further try.`),!1;let i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(s){for(let o of i)if(s.name.toUpperCase().includes(o)||s.message.toUpperCase().includes(o)||s.code&&s.code.toString().toUpperCase()===o)return gt.info(`RetryPolicy: Network error ${o} found, will retry.`),!0}if(n||s){let o=n?n.status:s?s.statusCode:0;if(!e&&o===404)return gt.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(o===503||o===500)return gt.info(`RetryPolicy: Will retry for status code ${o}.`),!0}if(n&&n?.status>=400){let o=n.headers.get(X.X_MS_CopySourceErrorCode);if(o!==void 0)switch(o){case"InternalError":case"OperationTimedOut":case"ServerBusy":return!0}}return s?.code==="PARSE_ERROR"&&s?.message.startsWith('Error "Error: Unclosed root tag')?(gt.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0):!1}async delay(e,r,n){let s=0;if(e)switch(this.retryOptions.retryPolicyType){case gn.EXPONENTIAL:s=Math.min((Math.pow(2,r-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case gn.FIXED:s=this.retryOptions.retryDelayInMs;break}else s=Math.random()*1e3;return gt.info(`RetryPolicy: Delay for ${s}ms`),Vg(s,n,Gge)}};var Td=class{retryOptions;constructor(e){this.retryOptions=e}create(e,r){return new kd(e,r,this.retryOptions)}};var Yge="storageBrowserPolicy";function CJ(){return{name:Yge,async sendRequest(t,e){return Ce||((t.method==="GET"||t.method==="HEAD")&&(t.url=wo(t.url,Qi.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),t.headers.delete(X.COOKIE),t.headers.delete(X.CONTENT_LENGTH)),e(t)}}}var Vge="StorageCorrectContentLengthPolicy";function IJ(){function t(e){e.body&&(typeof e.body=="string"||Buffer.isBuffer(e.body))&&e.body.length>0&&e.headers.set(X.CONTENT_LENGTH,Buffer.byteLength(e.body))}return{name:Vge,async sendRequest(e,r){return t(e),r(e)}}}var Jge="storageRetryPolicy",Pl={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:gn.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},Wge=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"],$ge=new zr("The operation was aborted.");function BJ(t={}){let e=t.retryPolicyType??Pl.retryPolicyType,r=t.maxTries??Pl.maxTries,n=t.retryDelayInMs??Pl.retryDelayInMs,s=t.maxRetryDelayInMs??Pl.maxRetryDelayInMs,i=t.secondaryHost??Pl.secondaryHost,o=t.tryTimeoutInMs??Pl.tryTimeoutInMs;function a({isPrimaryRetry:l,attempt:A,response:u,error:d}){if(A>=r)return gt.info(`RetryPolicy: Attempt(s) ${A} >= maxTries ${r}, no further try.`),!1;if(d){for(let m of Wge)if(d.name.toUpperCase().includes(m)||d.message.toUpperCase().includes(m)||d.code&&d.code.toString().toUpperCase()===m)return gt.info(
Line truncated
|
||||
`+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e),n=this.factory.computeHMACSHA256(r);return e.headers.set(X.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${n}`),e}getHeaderValueToSign(e,r){let n=e.headers.get(r);return!n||r===X.CONTENT_LENGTH&&n==="0"?"":n}getCanonicalizedHeadersString(e){let r=e.headers.headersArray().filter(s=>s.name.toLowerCase().startsWith(X.PREFIX_FOR_STORAGE));r.sort((s,i)=>kg(s.name.toLowerCase(),i.name.toLowerCase())),r=r.filter((s,i,o)=>!(i>0&&s.name.toLowerCase()===o[i-1].name.toLowerCase()));let n="";return r.forEach(s=>{n+=`${s.name.toLowerCase().trimRight()}:${s.value.trimLeft()}
|
||||
`}),n}getCanonicalizedResourceString(e){let r=Pg(e.url)||"/",n="";n+=`/${this.factory.accountName}${r}`;let s=vg(e.url),i={};if(s){let o=[];for(let a in s)if(Object.prototype.hasOwnProperty.call(s,a)){let c=a.toLowerCase();i[c]=s[a],o.push(c)}o.sort();for(let a of o)n+=`
|
||||
${a}:${decodeURIComponent(i[a])}`}return n}};var Je=class extends ba{accountName;accountKey;constructor(e,r){super(),this.accountName=e,this.accountKey=Buffer.from(r,"base64")}create(e,r){return new xd(e,r,this)}computeHMACSHA256(e){return(0,ZV.createHmac)("sha256",this.accountKey).update(e,"utf8").digest("base64")}};var gt=Cs("storage-common");var yn;(function(t){t[t.EXPONENTIAL=0]="EXPONENTIAL",t[t.FIXED=1]="FIXED"})(yn||(yn={}));var Qo={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:yn.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},hge=new Gr("The operation was aborted."),bd=class extends bs{retryOptions;constructor(e,r,n=Qo){super(e,r),this.retryOptions={retryPolicyType:n.retryPolicyType?n.retryPolicyType:Qo.retryPolicyType,maxTries:n.maxTries&&n.maxTries>=1?Math.floor(n.maxTries):Qo.maxTries,tryTimeoutInMs:n.tryTimeoutInMs&&n.tryTimeoutInMs>=0?n.tryTimeoutInMs:Qo.tryTimeoutInMs,retryDelayInMs:n.retryDelayInMs&&n.retryDelayInMs>=0?Math.min(n.retryDelayInMs,n.maxRetryDelayInMs?n.maxRetryDelayInMs:Qo.maxRetryDelayInMs):Qo.retryDelayInMs,maxRetryDelayInMs:n.maxRetryDelayInMs&&n.maxRetryDelayInMs>=0?n.maxRetryDelayInMs:Qo.maxRetryDelayInMs,secondaryHost:n.secondaryHost?n.secondaryHost:Qo.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,!1,1)}async attemptSendRequest(e,r,n){let s=e.clone(),i=r||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||n%2===1;i||(s.url=Rg(s.url,this.retryOptions.secondaryHost)),this.retryOptions.tryTimeoutInMs&&(s.url=Bo(s.url,Qi.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString()));let o;try{if(gt.info(`RetryPolicy: =====> Try=${n} ${i?"Primary":"Secondary"}`),o=await this._nextPolicy.sendRequest(s),!this.shouldRetry(i,n,o))return o;r=r||!i&&o.status===404}catch(a){if(gt.error(`RetryPolicy: Caught error, message: ${a.message}, code: ${a.code}`),!this.shouldRetry(i,n,o,a))throw a}return await this.delay(i,n,e.abortSignal),this.attemptSendRequest(e,r,++n)}shouldRetry(e,r,n,s){if(r>=this.retryOptions.maxTries)return gt.info(`RetryPolicy: Attempt(s) ${r} >= maxTries ${this.retryOptions.maxTries}, no further try.`),!1;let i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(s){for(let o of i)if(s.name.toUpperCase().includes(o)||s.message.toUpperCase().includes(o)||s.code&&s.code.toString().toUpperCase()===o)return gt.info(`RetryPolicy: Network error ${o} found, will retry.`),!0}if(n||s){let o=n?n.status:s?s.statusCode:0;if(!e&&o===404)return gt.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(o===503||o===500)return gt.info(`RetryPolicy: Will retry for status code ${o}.`),!0}if(n&&n?.status>=400){let o=n.headers.get(X.X_MS_CopySourceErrorCode);if(o!==void 0)switch(o){case"InternalError":case"OperationTimedOut":case"ServerBusy":return!0}}return s?.code==="PARSE_ERROR"&&s?.message.startsWith('Error "Error: Unclosed root tag')?(gt.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0):!1}async delay(e,r,n){let s=0;if(e)switch(this.retryOptions.retryPolicyType){case yn.EXPONENTIAL:s=Math.min((Math.pow(2,r-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case yn.FIXED:s=this.retryOptions.retryDelayInMs;break}else s=Math.random()*1e3;return gt.info(`RetryPolicy: Delay for ${s}ms`),Dg(s,n,hge)}};var wd=class{retryOptions;constructor(e){this.retryOptions=e}create(e,r){return new bd(e,r,this.retryOptions)}};var fge="storageBrowserPolicy";function eJ(){return{name:fge,async sendRequest(t,e){return Ie||((t.method==="GET"||t.method==="HEAD")&&(t.url=Bo(t.url,Qi.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),t.headers.delete(X.COOKIE),t.headers.delete(X.CONTENT_LENGTH)),e(t)}}}var gge="StorageCorrectContentLengthPolicy";function tJ(){function t(e){e.body&&(typeof e.body=="string"||Buffer.isBuffer(e.body))&&e.body.length>0&&e.headers.set(X.CONTENT_LENGTH,Buffer.byteLength(e.body))}return{name:gge,async sendRequest(e,r){return t(e),r(e)}}}var yge="storageRetryPolicy",wl={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:yn.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},Ege=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"],Cge=new Gr("The operation was aborted.");function rJ(t={}){let e=t.retryPolicyType??wl.retryPolicyType,r=t.maxTries??wl.maxTries,n=t.retryDelayInMs??wl.retryDelayInMs,s=t.maxRetryDelayInMs??wl.maxRetryDelayInMs,i=t.secondaryHost??wl.secondaryHost,o=t.tryTimeoutInMs??wl.tryTimeoutInMs;function a({isPrimaryRetry:l,attempt:A,response:u,error:d}){if(A>=r)return gt.info(`RetryPolicy: Attempt(s) ${A} >= maxTries ${r}, no further try.`),!1;if(d){for(let m of Ege)if(d.name.toUpperCase().includes(m)||d.message.toUpperCase().includes(m)||d.code&&d.code.toString().toUpperCase()===m)return gt.info(
Line truncated
|
||||
`)+`
|
||||
`+n(i)+s(i),a=(0,QJ.createHmac)("sha256",t.accountKey).update(o,"utf8").digest("base64");i.headers.set(X.AUTHORIZATION,`SharedKey ${t.accountName}:${a}`)}function r(i,o){let a=i.headers.get(o);return!a||o===X.CONTENT_LENGTH&&a==="0"?"":a}function n(i){let o=[];for(let[c,l]of i.headers)c.toLowerCase().startsWith(X.PREFIX_FOR_STORAGE)&&o.push({name:c,value:l});o.sort((c,l)=>Jg(c.name.toLowerCase(),l.name.toLowerCase())),o=o.filter((c,l,A)=>!(l>0&&c.name.toLowerCase()===A[l-1].name.toLowerCase()));let a="";return o.forEach(c=>{a+=`${c.name.toLowerCase().trimRight()}:${c.value.trimLeft()}
|
||||
`}),a}function s(i){let o=Gg(i.url)||"/",a="";a+=`/${t.accountName}${o}`;let c=Yg(i.url),l={};if(c){let A=[];for(let u in c)if(Object.prototype.hasOwnProperty.call(c,u)){let d=u.toLowerCase();l[d]=c[u],A.push(d)}A.sort();for(let u of A)a+=`
|
||||
${u}:${decodeURIComponent(l[u])}`}return a}return{name:jge,async sendRequest(i,o){return e(i),o(i)}}}var Kge="storageRequestFailureDetailsParserPolicy";function xJ(){return{name:Kge,async sendRequest(t,e){try{return await e(t)}catch(r){throw typeof r=="object"&&r!==null&&r.response&&r.response.parsedBody&&r.response.parsedBody.code==="InvalidHeaderValue"&&r.response.parsedBody.HeaderName==="x-ms-version"&&(r.message=`The provided service version is not enabled on this storage account. Please see https://learn.microsoft.com/rest/api/storageservices/versioning-for-the-azure-storage-services for additional information.
|
||||
`),r}}}}var wJ=require("node:crypto"),Wg=class{accountName;userDelegationKey;key;constructor(e,r){this.accountName=e,this.userDelegationKey=r,this.key=Buffer.from(r.value,"base64")}computeHMACSHA256(e){return(0,wJ.createHmac)("sha256",this.key).update(e,"utf8").digest("base64")}};var $g="12.31.0",jg="2026-02-06";var Kg="https://storage.azure.com/.default",xi={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}};var Hn="",y0="*",Xge=1*1024*1024;var Zge=4*Xge;var bJ="AES256",NJ="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;",SJ=["Access-Control-Allow-Origin","Cache-Control","Content-Length","Content-Type","Date","Request-Id","traceparent","Transfer-Encoding","User-Agent","x-ms-client-request-id","x-ms-date","x-ms-error-code","x-ms-request-id","x-ms-return-client-request-id","x-ms-version","Accept-Ranges","Content-Disposition","Content-Encoding","Content-Language","Content-MD5","Content-Range","ETag","Last-Modified","Server","Vary","x-ms-content-crc64","x-ms-copy-action","x-ms-copy-completion-time","x-ms-copy-id","x-ms-copy-progress","x-ms-copy-status","x-ms-has-immutability-policy","x-ms-has-legal-hold","x-ms-lease-state","x-ms-lease-status","x-ms-range","x-ms-request-server-encrypted","x-ms-server-encrypted","x-ms-snapshot","x-ms-source-range","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","x-ms-access-tier","x-ms-access-tier-change-time","x-ms-access-tier-inferred","x-ms-account-kind","x-ms-archive-status","x-ms-blob-append-offset","x-ms-blob-cache-control","x-ms-blob-committed-block-count","x-ms-blob-condition-appendpos","x-ms-blob-condition-maxsize","x-ms-blob-content-disposition","x-ms-blob-content-encoding","x-ms-blob-content-language","x-ms-blob-content-length","x-ms-blob-content-md5","x-ms-blob-content-type","x-ms-blob-public-access","x-ms-blob-sequence-number","x-ms-blob-type","x-ms-copy-destination-snapshot","x-ms-creation-time","x-ms-default-encryption-scope","x-ms-delete-snapshots","x-ms-delete-type-permanent","x-ms-deny-encryption-scope-override","x-ms-encryption-algorithm","x-ms-if-sequence-number-eq","x-ms-if-sequence-number-le","x-ms-if-sequence-number-lt","x-ms-incremental-copy","x-ms-lease-action","x-ms-lease-break-period","x-ms-lease-duration","x-ms-lease-id","x-ms-lease-time","x-ms-page-write","x-ms-proposed-lease-id","x-ms-range-get-content-md5","x-ms-rehydrate-priority","x-ms-sequence-number-action","x-ms-sku-name","x-ms-source-content-md5","x-ms-source-if-match","x-ms-source-if-modified-since","x-ms-source-if-none-match","x-ms-source-if-unmodified-since","x-ms-tag-count","x-ms-encryption-key-sha256","x-ms-copy-source-error-code","x-ms-copy-source-status-code","x-ms-if-tags","x-ms-source-if-tags"],RJ=["comp","maxresults","rscc","rscd","rsce","rscl","rsct","se","si","sip","sp","spr","sr","srt","ss","st","sv","include","marker","prefix","copyid","restype","blockid","blocklisttype","delimiter","prevsnapshot","ske","skoid","sks","skt","sktid","skv","snapshot"],PJ="BlobUsesCustomerSpecifiedEncryption",vJ="BlobDoesNotUseCustomerSpecifiedEncryption",DJ=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function wi(t){if(!t||typeof t!="object")return!1;let e=t;return Array.isArray(e.factories)&&typeof e.options=="object"&&typeof e.toServiceClientOptions=="function"}var Md=class{factories;options;constructor(e,r={}){this.factories=e,this.options=r}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}};function ot(t,e={}){t||(t=new Ue);let r=new Md([],e);return r._credential=t,r}function eye(t){let e=[tye,kJ,rye,nye,sye,iye,aye];if(t.factories.length){let r=t.factories.filter(n=>!e.some(s=>s(n)));if(r.length){let n=r.some(s=>oye(s));return{wrappedPolicies:Jb(r),afterRetry:n}}}}function E0(t){let{httpClient:e,...r}=t.options,n=t._coreHttpClient;n||(n=e?Wb(e):f0(),t._coreHttpClient=n);let s=t._corePipeline;if(!s){let i=`azsdk-js-azure-storage-blob/${$g}`,o=r.userAgentOptions&&r.userAgentOptions.userAgentPrefix?`${r.userAgentOptions.userAgentPrefix} ${i}`:`${i}`;s=gd({...r,loggingOptions:{additionalAllowedHeaderNames:SJ,additionalAllowedQueryParameters:RJ,logger:Fg.info},userAgentOptions:{userAgentPrefix:o},serializationOptions:{stringifyXML:_g,serializerOptions:{xml:{xmlCharKey:"#"}}},deserializationOptions:{parseXML:p0,serializerOptions:{xml:{xmlCharKey:"#"}}}}),s.removePolicy({phase:"Retry"}),s.removePolicy({name:Qb}),s.addPolicy(IJ()),s.addPolicy(BJ(r.retryOptions),{phase:"Retry"}),s.addPolicy(xJ()),s.addPolicy(CJ());let a=eye(t);a&&s.addPolicy(a.wrappedPolicies,a.afterRetry?{afterPhase:"Retry"}:void 0);let c=C0(t);Gr(c)?s.addPolicy(xl({credential:c,scopes:r.audience??Kg,challengeCallba
Line truncated
|
||||
`),i=e.computeHMACSHA256(s);return{sasQueryParameters:new Jn(t.version,i,n,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:s}}function tCe(t,e){if(t=Ua(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=zs.parse(t.permissions.toString()).toString():s=Gs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Ie(t.startsOn,!1):"",t.expiresOn?Ie(t.expiresOn,!1):"",Fa(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:i}}function rCe(t,e){if(t=Ua(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=zs.parse(t.permissions.toString()).toString():s=Gs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Ie(t.startsOn,!1):"",t.expiresOn?Ie(t.expiresOn,!1):"",Fa(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,void 0,void 0,void 0,t.encryptionScope),stringToSign:i}}function nCe(t,e){if(t=Ua(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=zs.parse(t.permissions.toString()).toString():s=Gs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Ie(t.startsOn,!1):"",t.expiresOn?Ie(t.expiresOn,!1):"",Fa(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ie(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ie(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey),stringToSign:i}}function sCe(t,e){if(t=Ua(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=zs.parse(t.permissions.toString()).toString():s=Gs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Ie(t.startsOn,!1):"",t.expiresOn?Ie(t.expiresOn,!1):"",Fa(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ie(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ie(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId),stringToSign:i}}function iCe(t,e){if(t=Ua(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=zs.parse(t.permissions.toString()).toString():s=Gs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Ie(t.startsOn,!1):"",t.expiresOn?Ie(t.expiresOn,!1):"",Fa(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ie(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ie(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope),stringToSign:i}}function oCe(t,e){if(t=Ua(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=zs.parse(t.permissions.toString()).toString():s=Gs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Ie(t.startsOn,!1):"",t.expiresOn?Ie(t.expiresOn,!1):"",Fa(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ie(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ie(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,void 0,t.delegatedUserObjectId,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope,t.delegatedUserObjectId),stringToSign:i}}function Fa(t,e,r){let n=[`/blob/${t}/${e}`];return r&&n.push(`/${r}`),n.join("")}function Ua(t){let e=t.version?t.version:jg;if(t.snapshotTime&&e<"2018-11-09")throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(t.blobName===void 0&&t.snapshotTime)throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(t.versionId&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(t.blobName===void 0&&t.versionId)throw RangeError("Must provide 'blobName' when providing 'versionId'.");if(t.permissions&&t.permissions.setImmutabilityPolicy&&e<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(t.permissions&&t.permissions.deleteVersion&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(t.permissions&&t.permissions.permanentDelete&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(t.permissions&&t.permissions.tag&&e<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&t.permissions&&(t.permissions.move||t.permissions.execute))throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2021-04-10"&&t.permissions&&t.permissions.filterByTags)throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(e<"2020-02-10"&&(t.preauthorizedAgentObjectId||t.correlationId))throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(t.encryptionScope&&e<"2020-12-06")throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");return t.version=e,t}var Jd=class{_leaseId;_url;_containerOrBlobOperation;_isContainer;get leaseId(){return this._leaseId}get url(){return this._url}constructor(e,r){let n=e.storageClientContext;this._url=e.url,e.name===void 0?(this._isContainer=!0,this._containerOrBlobOperation=n.container):(this._isContainer=!1,this._containerOrBlobOperation=n.blob),r||(r=Bl()),this._leaseId=r}async acquireLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Hn||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Hn||r.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-acquireLease",r,async n=>Y(await this._containerOrBlobOperation.acquireLease({abortSignal:r.abortSignal,duration:e,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},proposedLeaseId:this._leaseId,tracingOptions:n.tracingOptions})))}async changeLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Hn||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Hn||r.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-changeLease",r,async n=>{let s=Y(await this._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:r.abortSignal,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},tracingOptions:n.tracingOptions}));return this._leaseId=e,s})}async releaseLease(e={}){if(this._isContainer&&(e.conditions?.ifMatch&&e.conditions?.ifMatch!==Hn||e.conditions?.ifNoneMatch&&e.conditions?.ifNoneMatch!==Hn||e.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-releaseLease",e,async r=>Y(await this._containerOrBlobOperation.releaseLease(this._leaseId,{abortSignal:e.abortSignal,modifiedAccessConditions:{...e.conditions,ifTags:e.conditions?.tagConditions},tracingOptions:r.tracingOptions})))}async renewLease(e={}){if(this._isContainer&&(e.conditions?.ifMatch&&e.conditions?.ifMatch!==Hn||e.conditions?.ifNoneMatch&&e.conditions?.ifNoneMatch!==Hn||e.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-renewLease",e,async r=>this._containerOrBlobOperation.renewLease(this._leaseId,{abortSignal:e.abortSign
Line truncated
|
||||
If you are using self-hosted runners, please make sure your runner has access to all GitHub endpoints: https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/about-self-hosted-runners#communication-between-self-hosted-runners-and-github`;super(r),this.code=e,this.name="NetworkError"}};Hl.isNetworkErrorCode=t=>t?["ECONNRESET","ENOTFOUND","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH"].includes(t):!1;var za=class extends Error{constructor(){super(`Cache storage quota has been hit. Unable to upload any new cache entries.
|
||||
More info on storage limits: https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending`),this.name="UsageError"}};za.isUsageErrorMessage=t=>t?t.includes("insufficient usage"):!1;var nm=class extends Error{constructor(e){super(e),this.name="RateLimitError"}};var fIe=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},lP=class{constructor(e){this.contentLength=e,this.sentBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}setSentBytes(e){this.sentBytes=e}getTransferredBytes(){return this.sentBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.sentBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,s=(e/(1024*1024)/(n/1e3)).toFixed(1);mt(`Sent ${e} of ${this.contentLength} (${r}%), ${s} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setSentBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){let r=()=>{this.display(),this.isDone()||(this.timeoutHandle=setTimeout(r,e))};this.timeoutHandle=setTimeout(r,e)}stopDisplayTimer(){this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=void 0),this.display()}};function L4(t,e,r){return fIe(this,void 0,void 0,function*(){var n;let s=new Di(t),i=s.getBlockBlobClient(),o=new lP((n=r?.archiveSizeBytes)!==null&&n!==void 0?n:0),a={blockSize:r?.uploadChunkSize,concurrency:r?.uploadConcurrency,maxSingleShotSize:128*1024*1024,onProgress:o.onProgress()};try{o.startDisplayTimer(),N(`BlobClient: ${s.name}:${s.accountName}:${s.containerName}`);let c=yield i.uploadFile(e,a);if(c._response.status>=400)throw new tE(`uploadCacheArchiveSDK: upload failed with status code ${c._response.status}`);return c}catch(c){throw Fn(`uploadCacheArchiveSDK: internal error uploading cache archive: ${c.message}`),c}finally{o.stopDisplayTimer()}})}var F4=B(require("buffer"),1),Ys=B(require("fs"),1),U4=B(require("stream"),1),O4=B(require("util"),1);var rE=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};function nE(t){return t?t>=200&&t<300:!1}function gIe(t){return t?t>=500:!0}function yIe(t){return t?[Ve.BadGateway,Ve.ServiceUnavailable,Ve.GatewayTimeout].includes(t):!1}function EIe(t){return rE(this,void 0,void 0,function*(){return new Promise(e=>setTimeout(e,t))})}function _4(t,e,r){return rE(this,arguments,void 0,function*(n,s,i,o=Nf,a=Sf,c=void 0){let l="",A=1;for(;A<=o;){let u,d,m=!1;try{u=yield s()}catch(p){c&&(u=c(p)),m=!0,l=p.message}if(u&&(d=i(u),!gIe(d)))return u;if(d&&(m=yIe(d),l=`Cache service responded with ${d}`),N(`${n} - Attempt ${A} of ${o} failed with error: ${l}`),!m){N(`${n} - Error is not retryable`);break}yield EIe(a),A++}throw Error(`${n} failed: ${l}`)})}function sm(t,e){return rE(this,arguments,void 0,function*(r,n,s=Nf,i=Sf){return yield _4(r,n,o=>o.statusCode,s,i,o=>{if(o instanceof gs)return{statusCode:o.statusCode,result:null,headers:{},error:o}})})}function zl(t,e){return rE(this,arguments,void 0,function*(r,n,s=Nf,i=Sf){return yield _4(r,n,o=>o.message.statusCode,s,i)})}var Bn=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};function CIe(t,e){return Bn(this,void 0,void 0,function*(){yield O4.promisify(U4.pipeline)(t.message,e)})}var sE=class{constructor(e){this.contentLength=e,this.segmentIndex=0,this.segmentSize=0,this.segmentOffset=0,this.receivedBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}nextSegment(e){this.segmentOffset=this.segmentOffset+this.segmentSize,this.segmentIndex=this.segmentIndex+1,this.segmentSize=e,this.receivedBytes=0,N(`Downloading segment at offset ${this.segmentOffset} with length ${this.segmentSize}...`)}setReceivedBytes(e){this.receivedBytes=e}getTransferredBytes(){return this.segmentOffset+this.receivedBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.segmentOffset+this.receivedBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,s=(e/(1024*1024)/(n/1e3)).toFixed(1);mt(`Received ${e} of ${this.contentLength} (${r}%), ${s} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setReceivedBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){le
Line truncated
|
||||
Other caches with similar key:`);for(let a of i?.artifactCaches||[])N(`Cache Key: ${a?.cacheKey}, Cache Version: ${a?.cacheVersion}, Cache Scope: ${a?.scope}, Cache Created: ${a?.creationTime}`)}}})}function mP(t,e,r){return Ir(this,void 0,void 0,function*(){let n=new j4.URL(t),s=G4(r);n.hostname.endsWith(".blob.core.windows.net")?s.useAzureSdk?yield H4(t,e,s):s.concurrentBlobDownloads?yield q4(t,e,s):yield iE(t,e):yield iE(t,e)})}function X4(t,e,r){return Ir(this,void 0,void 0,function*(){let n=dP(),s=ml(e,r?.compressionMethod,r?.enableCrossOsArchive),i={key:t,version:s,cacheSize:r?.cacheSize};return yield sm("reserveCache",()=>Ir(this,void 0,void 0,function*(){return n.postJson(om("caches"),i)}))})}function $4(t,e){return`bytes ${t}-${e}/*`}function SIe(t,e,r,n,s){return Ir(this,void 0,void 0,function*(){N(`Uploading chunk of size ${s-n+1} bytes at offset ${n} with content range: ${$4(n,s)}`);let i={"Content-Type":"application/octet-stream","Content-Range":$4(n,s)},o=yield zl(`uploadChunk (start: ${n}, end: ${s})`,()=>Ir(this,void 0,void 0,function*(){return t.sendStream("PATCH",e,r(),i)}));if(!nE(o.message.statusCode))throw new Error(`Cache service responded with ${o.message.statusCode} during upload chunk.`)})}function RIe(t,e,r,n){return Ir(this,void 0,void 0,function*(){let s=fs(r),i=om(`caches/${e.toString()}`),o=Gl.openSync(r,"r"),a=AP(n),c=_w("uploadConcurrency",a.uploadConcurrency),l=_w("uploadChunkSize",a.uploadChunkSize),A=[...new Array(c).keys()];N("Awaiting all uploads");let u=0;try{yield Promise.all(A.map(()=>Ir(this,void 0,void 0,function*(){for(;u<s;){let d=Math.min(s-u,l),m=u,p=u+d-1;u+=l,yield SIe(t,i,()=>Gl.createReadStream(r,{fd:o,start:m,end:p,autoClose:!1}).on("error",f=>{throw new Error(`Cache upload failed because file read failed with ${f.message}`)}),m,p)}})))}finally{Gl.closeSync(o)}})}function PIe(t,e,r){return Ir(this,void 0,void 0,function*(){let n={size:r};return yield sm("commitCache",()=>Ir(this,void 0,void 0,function*(){return t.postJson(om(`caches/${e.toString()}`),n)}))})}function pP(t,e,r,n){return Ir(this,void 0,void 0,function*(){if(AP(n).useAzureSdk){if(!r)throw new Error("Azure Storage SDK can only be used when a signed URL is provided.");yield L4(r,e,n)}else{let i=dP();N("Upload cache"),yield RIe(i,t,e,n),N("Commiting cache");let o=fs(e);mt(`Cache Size: ~${Math.round(o/(1024*1024))} MB (${o} B)`);let a=yield PIe(i,t,o);if(!nE(a.statusCode))throw new Error(`Cache service responded with ${a.statusCode} during commit cache.`);mt("Cache saved successfully")}})}var VW=B(UW(),1),lt=B(ct(),1),$r=B(ct(),1),Wa=B(ct(),1),$a=B(ct(),1),ja=B(ct(),1);var cv=B(ct(),1),lv=B(ct(),1),zW=B(ct(),1),GW=B(ct(),1),YW=B(ct(),1);var iv=B(ct(),1),ov=B(ct(),1),OW=B(ct(),1),qW=B(ct(),1),HW=B(ct(),1),av=class extends HW.MessageType{constructor(){super("github.actions.results.entities.v1.CacheScope",[{no:1,name:"scope",kind:"scalar",T:9},{no:2,name:"permission",kind:"scalar",T:3}])}create(e){let r={scope:"",permission:"0"};return globalThis.Object.defineProperty(r,qW.MESSAGE_TYPE,{enumerable:!1,value:this}),e!==void 0&&(0,OW.reflectionMergePartial)(this,r,e),r}internalBinaryRead(e,r,n,s){let i=s??this.create(),o=e.pos+r;for(;e.pos<o;){let[a,c]=e.tag();switch(a){case 1:i.scope=e.string();break;case 2:i.permission=e.int64().toString();break;default:let l=n.readUnknownField;if(l==="throw")throw new globalThis.Error(`Unknown field ${a} (wire type ${c}) for ${this.typeName}`);let A=e.skip(c);l!==!1&&(l===!0?ov.UnknownFieldHandler.onRead:l)(this.typeName,i,a,c,A)}}return i}internalBinaryWrite(e,r,n){e.scope!==""&&r.tag(1,iv.WireType.LengthDelimited).string(e.scope),e.permission!=="0"&&r.tag(2,iv.WireType.Varint).int64(e.permission);let s=n.writeUnknownFields;return s!==!1&&(s==!0?ov.UnknownFieldHandler.onWrite:s)(this.typeName,e,r),r}},VE=new av;var Av=class extends YW.MessageType{constructor(){super("github.actions.results.entities.v1.CacheMetadata",[{no:1,name:"repository_id",kind:"scalar",T:3},{no:2,name:"scope",kind:"message",repeat:1,T:()=>VE}])}create(e){let r={repositoryId:"0",scope:[]};return globalThis.Object.defineProperty(r,GW.MESSAGE_TYPE,{enumerable:!1,value:this}),e!==void 0&&(0,zW.reflectionMergePartial)(this,r,e),r}internalBinaryRead(e,r,n,s){let i=s??this.create(),o=e.pos+r;for(;e.pos<o;){let[a,c]=e.tag();switch(a){case 1:i.repositoryId=e.int64().toString();break;case 2:i.scope.push(VE.internalBinaryRead(e,e.uint32(),n));break;default:let l=n.readUnknownField;if(l==="throw")throw new globalThis.Error(`Unknown field ${a} (wire type ${c}) for ${this.typeName}`);let A=e.skip(c);l!==!1&&(l===!0?lv.UnknownFieldHandler.onRead:l)(this.typeName,i,a,c,A)}}return i}internalBinaryWrite(e,r,n){e.repositoryId!=="0"&&r.tag(1,cv.WireType.Varint).int64(e.repositoryId);for(let i=0;i<e.scope.length;i++)VE.internalBinaryWrite(e.scope[i],r.tag(2,cv.WireType.LengthDelimited).fork(),n).join();let s=n.writeUnknownFields;return s!==!1&&(s==!0?lv.UnknownFieldHandler.onWrite:s)(this.typeName,e,r),r}},js=new
Line truncated
|
||||
`));let n=yield wv(r,"create");yield bv(n,t)})}var aA=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},jn=class t extends Error{constructor(e){super(e),this.name="ValidationError",Object.setPrototypeOf(this,t.prototype)}},oA=class t extends Error{constructor(e){super(e),this.name="ReserveCacheError",Object.setPrototypeOf(this,t.prototype)}},jE=class t extends Error{constructor(e){super(e),this.name="FinalizeCacheError",Object.setPrototypeOf(this,t.prototype)}};function jW(t){if(!t||t.length===0)throw new jn("Path Validation Error: At least one directory or file path is required")}function Rv(t){if(t.length>512)throw new jn(`Key Validation Error: ${t} cannot be larger than 512 characters.`);if(!/^[^,]*$/.test(t))throw new jn(`Key Validation Error: ${t} cannot contain commas.`)}function Pv(){return im()==="v2"?!!process.env.ACTIONS_RESULTS_URL:!!process.env.ACTIONS_CACHE_URL}function KW(t,e,r,n){return aA(this,arguments,void 0,function*(s,i,o,a,c=!1){let l=im();return N(`Cache service version: ${l}`),jW(s),l==="v2"?yield YQe(s,i,o,a,c):yield GQe(s,i,o,a,c)})}function GQe(t,e,r,n){return aA(this,arguments,void 0,function*(s,i,o,a,c=!1){o=o||[];let l=[i,...o];if(N("Resolved Keys:"),N(JSON.stringify(l)),l.length>10)throw new jn("Key Validation Error: Keys are limited to a maximum of 10.");for(let d of l)Rv(d);let A=yield sd(),u="";try{let d=yield K4(l,s,{compressionMethod:A,enableCrossOsArchive:c});if(!d?.archiveLocation)return;if(a?.lookupOnly)return mt("Lookup only - skipping download"),d.cacheKey;u=Bm.join(yield rd(),go(A)),N(`Archive Path: ${u}`),yield mP(d.archiveLocation,u,a),da()&&(yield Im(u,A));let m=fs(u);return mt(`Cache Size: ~${Math.round(m/(1024*1024))} MB (${m} B)`),yield Nv(u,A),mt("Cache restored successfully"),d.cacheKey}catch(d){let m=d;if(m.name===jn.name)throw d;m instanceof gs&&typeof m.statusCode=="number"&&m.statusCode>=500?qu(`Failed to restore: ${d.message}`):Fn(`Failed to restore: ${d.message}`)}finally{try{yield nd(u)}catch(d){N(`Failed to delete archive: ${d}`)}}})}function YQe(t,e,r,n){return aA(this,arguments,void 0,function*(s,i,o,a,c=!1){a=Object.assign(Object.assign({},a),{useAzureSdk:!0}),o=o||[];let l=[i,...o];if(N("Resolved Keys:"),N(JSON.stringify(l)),l.length>10)throw new jn("Key Validation Error: Keys are limited to a maximum of 10.");for(let u of l)Rv(u);let A="";try{let u=xv(),d=yield sd(),m={key:i,restoreKeys:o,version:ml(s,d,c)},p=yield u.GetCacheEntryDownloadURL(m);if(!p.ok){N(`Cache not found for version ${m.version} of keys: ${l.join(", ")}`);return}if(m.key!==p.matchedKey?mt(`Cache hit for restore-key: ${p.matchedKey}`):mt(`Cache hit for: ${p.matchedKey}`),a?.lookupOnly)return mt("Lookup only - skipping download"),p.matchedKey;A=Bm.join(yield rd(),go(d)),N(`Archive path: ${A}`),N(`Starting download of archive to: ${A}`),yield mP(p.signedDownloadUrl,A,a);let E=fs(A);return mt(`Cache Size: ~${Math.round(E/(1024*1024))} MB (${E} B)`),da()&&(yield Im(A,d)),yield Nv(A,d),mt("Cache restored successfully"),p.matchedKey}catch(u){let d=u;if(d.name===jn.name)throw u;d instanceof gs&&typeof d.statusCode=="number"&&d.statusCode>=500?qu(`Failed to restore: ${u.message}`):Fn(`Failed to restore: ${u.message}`)}finally{try{A&&(yield nd(A))}catch(u){N(`Failed to delete archive: ${u}`)}}})}function vv(t,e,r){return aA(this,arguments,void 0,function*(n,s,i,o=!1){let a=im();return N(`Cache service version: ${a}`),jW(n),Rv(s),a==="v2"?yield JQe(n,s,i,o):yield VQe(n,s,i,o)})}function VQe(t,e,r){return aA(this,arguments,void 0,function*(n,s,i,o=!1){var a,c,l,A,u;let d=yield sd(),m=-1,p=yield Lw(n);if(N("Cache Paths:"),N(`${JSON.stringify(p)}`),p.length===0)throw new Error("Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.");let f=yield rd(),E=Bm.join(f,go(d));N(`Archive Path: ${E}`);try{yield Sv(f,p,d),da()&&(yield Im(E,d));let g=10*1024*1024*1024,y=fs(E);if(N(`File Size: ${y}`),y>g&&!uP())throw new Error(`Cache size of ~${Math.round(y/(1024*1024))} MB (${y} B) is over the 10GB limit, not saving cache.`);N("Reserving Cache");let C=yield X4(s,n,{compressionMethod:d,enableCrossOsArchive:o,cacheSize:y});if(!((a=C?.result)===null||a===void 0)&&a.cacheId)m=(c=C?.result)===null||c===void 0?void 0:c.cacheId;else throw C?.statusCode===400?new Error((A=(l=C?.error)===null||l===void 0?void 0:l.message)!==null&&A!==void 0?A:`Cache size of ~${Math.round(y/(1024*1024))} MB (${y} B) is over the data cap limit, not saving cache.`):new oA(`Unable to reserve cache with key ${s}, another job may be creating this cache. More details: ${(u=C?.error)===null||u===void 0?void 0:u.message}`);N(`Saving Cache (ID: ${m})`),yield pP(m,E,"",i)}catch(g){let y=g;if(y.name===jn.name)throw g;y.name===oA.na
Line truncated
|
||||
`,o).length:u,l?(a===null?0:a.length)+c.length:0,l?c.length+u:0);return d<m},parse:function(n,s,i,o){let{bom:a,comment_no_infix:c,encoding:l,from_line:A,ltrim:u,max_record_size:d,raw:m,relax_quotes:p,rtrim:f,skip_empty_lines:E,to:g,to_line:y}=this.options,{comment:C,escape:I,quote:w,record_delimiter:D}=this.options,{bomSkipped:_,previousBuf:ae,rawBuffer:ge,escapeIsQuote:Be}=this.state,H;if(ae===void 0)if(n===void 0){o();return}else H=n;else ae!==void 0&&n===void 0?H=ae:H=Buffer.concat([ae,n]);if(_===!1)if(a===!1)this.state.bomSkipped=!0;else if(H.length<3){if(s===!1){this.state.previousBuf=H;return}}else{for(let de in IA)if(IA[de].compare(H,0,IA[de].length)===0){let At=IA[de].length;this.state.bufBytesStart+=At,H=H.slice(At);let He=TD({...this.original_options,encoding:de});for(let tt in He)this.options[tt]=He[tt];({comment:C,escape:I,quote:w}=this.options);break}this.state.bomSkipped=!0}let ee=H.length,F;for(F=0;F<ee&&!this.__needMoreData(F,ee,s);F++){if(this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1),y!==-1&&this.info.lines>y){this.state.stop=!0,o();return}this.state.quoting===!1&&D.length===0&&this.__autoDiscoverRecordDelimiter(H,F)&&(D=this.options.record_delimiter);let de=H[F];if(m===!0&&ge.append(de),(de===d0e||de===m0e)&&this.state.wasRowDelimiter===!1&&(this.state.wasRowDelimiter=!0),this.state.escaping===!0)this.state.escaping=!1;else{if(I!==null&&this.state.quoting===!0&&this.__isEscape(H,F,de)&&F+I.length<ee)if(Be){if(this.__isQuote(H,F+I.length)){this.state.escaping=!0,F+=I.length-1;continue}}else{this.state.escaping=!0,F+=I.length-1;continue}if(this.state.commenting===!1&&this.__isQuote(H,F))if(this.state.quoting===!0){let tt=H[F+w.length],ei=f&&this.__isCharTrimable(H,F+w.length),wr=C!==null&&this.__compareBytes(C,H,F+w.length,tt),Zn=this.__isDelimiter(H,F+w.length,tt),_o=D.length===0?this.__autoDiscoverRecordDelimiter(H,F+w.length):this.__isRecordDelimiter(tt,H,F+w.length);if(I!==null&&this.__isEscape(H,F,de)&&this.__isQuote(H,F+I.length))F+=I.length-1;else if(!tt||Zn||_o||wr||ei){this.state.quoting=!1,this.state.wasQuoting=!0,F+=w.length-1;continue}else if(p===!1){let nc=this.__error(new fe("CSV_INVALID_CLOSING_QUOTE",["Invalid Closing Quote:",`got "${String.fromCharCode(tt)}"`,`at line ${this.info.lines}`,"instead of delimiter, record delimiter, trimable character","(if activated) or comment"],this.options,this.__infoField()));if(nc!==void 0)return nc}else this.state.quoting=!1,this.state.wasQuoting=!0,this.state.field.prepend(w),F+=w.length-1}else if(this.state.field.length!==0){if(p===!1){let tt=this.__infoField(),ei=Object.keys(IA).map(Zn=>IA[Zn].equals(this.state.field.toString())?Zn:!1).filter(Boolean)[0],wr=this.__error(new fe("INVALID_OPENING_QUOTE",["Invalid Opening Quote:",`a quote is found on field ${JSON.stringify(tt.column)} at line ${tt.lines}, value is ${JSON.stringify(this.state.field.toString(l))}`,ei?`(${ei} bom)`:void 0],this.options,tt,{field:this.state.field}));if(wr!==void 0)return wr}}else{this.state.quoting=!0,F+=w.length-1;continue}if(this.state.quoting===!1){let tt=this.__isRecordDelimiter(de,H,F);if(tt!==0){if(this.state.commenting&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0)this.info.comment_lines++;else{if(this.state.enabled===!1&&this.info.lines+(this.state.wasRowDelimiter===!0?1:0)>=A){this.state.enabled=!0,this.__resetField(),this.__resetRecord(),F+=tt-1;continue}if(E===!0&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0){this.info.empty_lines++,F+=tt-1;continue}this.info.bytes=this.state.bufBytesStart+F;let Zn=this.__onField();if(Zn!==void 0)return Zn;this.info.bytes=this.state.bufBytesStart+F+tt;let _o=this.__onRecord(i);if(_o!==void 0)return _o;if(g!==-1&&this.info.records>=g){this.state.stop=!0,o();return}}this.state.commenting=!1,F+=tt-1;continue}if(this.state.commenting)continue;if(C!==null&&(c===!1||this.state.record.length===0&&this.state.field.length===0)&&this.__compareBytes(C,H,F,de)!==0){this.state.commenting=!0;continue}let ei=this.__isDelimiter(H,F,de);if(ei!==0){this.info.bytes=this.state.bufBytesStart+F;let wr=this.__onField();if(wr!==void 0)return wr;F+=ei-1;continue}}}if(this.state.commenting===!1&&d!==0&&this.state.record_length+this.state.field.length>d)return this.__error(new fe("CSV_MAX_RECORD_SIZE",["Max Record Size:","record exceed the maximum number of tolerated bytes",`of ${d}`,`at line ${this.info.lines}`],this.options,this.__infoField()));let At=u===!1||this.state.quoting===!0||this.state.field.length!==0||!this.__isCharTrimable(H,F),He=f===!1||this.state.wasQuoting===!1;if(At===!0&&He===!0)this.state.field.append(de);else{if(f===!0&&!this.__isCharTrimable(H,F))return this.__error(new fe("CSV_NON_TRIMABLE_CHAR_AFTER_CLOSING_QUOTE",["Invalid Closing Quote:","found non trimable byte after quote",`at line ${this.info.lines}`],this.options,this.__infoField()));At===!1&&(F+=this.__isCharTrimable(H,F)-1);continue}}if(s===!0
Line truncated
|
||||
`+n(i)+s(i),a=(0,nJ.createHmac)("sha256",t.accountKey).update(o,"utf8").digest("base64");i.headers.set(X.AUTHORIZATION,`SharedKey ${t.accountName}:${a}`)}function r(i,o){let a=i.headers.get(o);return!a||o===X.CONTENT_LENGTH&&a==="0"?"":a}function n(i){let o=[];for(let[c,l]of i.headers)c.toLowerCase().startsWith(X.PREFIX_FOR_STORAGE)&&o.push({name:c,value:l});o.sort((c,l)=>kg(c.name.toLowerCase(),l.name.toLowerCase())),o=o.filter((c,l,A)=>!(l>0&&c.name.toLowerCase()===A[l-1].name.toLowerCase()));let a="";return o.forEach(c=>{a+=`${c.name.toLowerCase().trimRight()}:${c.value.trimLeft()}
|
||||
`}),a}function s(i){let o=Pg(i.url)||"/",a="";a+=`/${t.accountName}${o}`;let c=vg(i.url),l={};if(c){let A=[];for(let u in c)if(Object.prototype.hasOwnProperty.call(c,u)){let d=u.toLowerCase();l[d]=c[u],A.push(d)}A.sort();for(let u of A)a+=`
|
||||
${u}:${decodeURIComponent(l[u])}`}return a}return{name:Ige,async sendRequest(i,o){return e(i),o(i)}}}var Bge="storageRequestFailureDetailsParserPolicy";function sJ(){return{name:Bge,async sendRequest(t,e){try{return await e(t)}catch(r){throw typeof r=="object"&&r!==null&&r.response&&r.response.parsedBody&&r.response.parsedBody.code==="InvalidHeaderValue"&&r.response.parsedBody.HeaderName==="x-ms-version"&&(r.message=`The provided service version is not enabled on this storage account. Please see https://learn.microsoft.com/rest/api/storageservices/versioning-for-the-azure-storage-services for additional information.
|
||||
`),r}}}}var iJ=require("node:crypto"),Tg=class{accountName;userDelegationKey;key;constructor(e,r){this.accountName=e,this.userDelegationKey=r,this.key=Buffer.from(r.value,"base64")}computeHMACSHA256(e){return(0,iJ.createHmac)("sha256",this.key).update(e,"utf8").digest("base64")}};var Mg="12.31.0",Lg="2026-02-06";var Fg="https://storage.azure.com/.default",xi={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}};var Hn="",oN="*",Qge=1*1024*1024;var xge=4*Qge;var oJ="AES256",aJ="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;",cJ=["Access-Control-Allow-Origin","Cache-Control","Content-Length","Content-Type","Date","Request-Id","traceparent","Transfer-Encoding","User-Agent","x-ms-client-request-id","x-ms-date","x-ms-error-code","x-ms-request-id","x-ms-return-client-request-id","x-ms-version","Accept-Ranges","Content-Disposition","Content-Encoding","Content-Language","Content-MD5","Content-Range","ETag","Last-Modified","Server","Vary","x-ms-content-crc64","x-ms-copy-action","x-ms-copy-completion-time","x-ms-copy-id","x-ms-copy-progress","x-ms-copy-status","x-ms-has-immutability-policy","x-ms-has-legal-hold","x-ms-lease-state","x-ms-lease-status","x-ms-range","x-ms-request-server-encrypted","x-ms-server-encrypted","x-ms-snapshot","x-ms-source-range","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","x-ms-access-tier","x-ms-access-tier-change-time","x-ms-access-tier-inferred","x-ms-account-kind","x-ms-archive-status","x-ms-blob-append-offset","x-ms-blob-cache-control","x-ms-blob-committed-block-count","x-ms-blob-condition-appendpos","x-ms-blob-condition-maxsize","x-ms-blob-content-disposition","x-ms-blob-content-encoding","x-ms-blob-content-language","x-ms-blob-content-length","x-ms-blob-content-md5","x-ms-blob-content-type","x-ms-blob-public-access","x-ms-blob-sequence-number","x-ms-blob-type","x-ms-copy-destination-snapshot","x-ms-creation-time","x-ms-default-encryption-scope","x-ms-delete-snapshots","x-ms-delete-type-permanent","x-ms-deny-encryption-scope-override","x-ms-encryption-algorithm","x-ms-if-sequence-number-eq","x-ms-if-sequence-number-le","x-ms-if-sequence-number-lt","x-ms-incremental-copy","x-ms-lease-action","x-ms-lease-break-period","x-ms-lease-duration","x-ms-lease-id","x-ms-lease-time","x-ms-page-write","x-ms-proposed-lease-id","x-ms-range-get-content-md5","x-ms-rehydrate-priority","x-ms-sequence-number-action","x-ms-sku-name","x-ms-source-content-md5","x-ms-source-if-match","x-ms-source-if-modified-since","x-ms-source-if-none-match","x-ms-source-if-unmodified-since","x-ms-tag-count","x-ms-encryption-key-sha256","x-ms-copy-source-error-code","x-ms-copy-source-status-code","x-ms-if-tags","x-ms-source-if-tags"],lJ=["comp","maxresults","rscc","rscd","rsce","rscl","rsct","se","si","sip","sp","spr","sr","srt","ss","st","sv","include","marker","prefix","copyid","restype","blockid","blocklisttype","delimiter","prevsnapshot","ske","skoid","sks","skt","sktid","skv","snapshot"],AJ="BlobUsesCustomerSpecifiedEncryption",uJ="BlobDoesNotUseCustomerSpecifiedEncryption",dJ=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function bi(t){if(!t||typeof t!="object")return!1;let e=t;return Array.isArray(e.factories)&&typeof e.options=="object"&&typeof e.toServiceClientOptions=="function"}var Nd=class{factories;options;constructor(e,r={}){this.factories=e,this.options=r}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}};function ot(t,e={}){t||(t=new Ue);let r=new Nd([],e);return r._credential=t,r}function bge(t){let e=[wge,mJ,Nge,Sge,Rge,Pge,Dge];if(t.factories.length){let r=t.factories.filter(n=>!e.some(s=>s(n)));if(r.length){let n=r.some(s=>vge(s));return{wrappedPolicies:Mw(r),afterRetry:n}}}}function aN(t){let{httpClient:e,...r}=t.options,n=t._coreHttpClient;n||(n=e?Lw(e):sN(),t._coreHttpClient=n);let s=t._corePipeline;if(!s){let i=`azsdk-js-azure-storage-blob/${Mg}`,o=r.userAgentOptions&&r.userAgentOptions.userAgentPrefix?`${r.userAgentOptions.userAgentPrefix} ${i}`:`${i}`;s=ld({...r,loggingOptions:{additionalAllowedHeaderNames:cJ,additionalAllowedQueryParameters:lJ,logger:xg.info},userAgentOptions:{userAgentPrefix:o},serializationOptions:{stringifyXML:Qg,serializerOptions:{xml:{xmlCharKey:"#"}}},deserializationOptions:{parseXML:rN,serializerOptions:{xml:{xmlCharKey:"#"}}}}),s.removePolicy({phase:"Retry"}),s.removePolicy({name:uw}),s.addPolicy(tJ()),s.addPolicy(rJ(r.retryOptions),{phase:"Retry"}),s.addPolicy(sJ()),s.addPolicy(eJ());let a=bge(t);a&&s.addPolicy(a.wrappedPolicies,a.afterRetry?{afterPhase:"Retry"}:void 0);let c=cN(t);Yr(c)?s.addPolicy(Cl({credential:c,scopes:r.audience??Fg,challengeCallba
Line truncated
|
||||
`),i=e.computeHMACSHA256(s);return{sasQueryParameters:new Jn(t.version,i,n,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:s}}function wEe(t,e){if(t=Ta(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=Hs.parse(t.permissions.toString()).toString():s=zs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Be(t.startsOn,!1):"",t.expiresOn?Be(t.expiresOn,!1):"",ka(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:i}}function NEe(t,e){if(t=Ta(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=Hs.parse(t.permissions.toString()).toString():s=zs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Be(t.startsOn,!1):"",t.expiresOn?Be(t.expiresOn,!1):"",ka(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,void 0,void 0,void 0,t.encryptionScope),stringToSign:i}}function SEe(t,e){if(t=Ta(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=Hs.parse(t.permissions.toString()).toString():s=zs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Be(t.startsOn,!1):"",t.expiresOn?Be(t.expiresOn,!1):"",ka(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Be(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Be(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey),stringToSign:i}}function REe(t,e){if(t=Ta(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=Hs.parse(t.permissions.toString()).toString():s=zs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Be(t.startsOn,!1):"",t.expiresOn?Be(t.expiresOn,!1):"",ka(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Be(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Be(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId),stringToSign:i}}function PEe(t,e){if(t=Ta(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=Hs.parse(t.permissions.toString()).toString():s=zs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Be(t.startsOn,!1):"",t.expiresOn?Be(t.expiresOn,!1):"",ka(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Be(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Be(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope),stringToSign:i}}function vEe(t,e){if(t=Ta(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let s;t.permissions&&(t.blobName?s=Hs.parse(t.permissions.toString()).toString():s=zs.parse(t.permissions.toString()).toString());let i=[s||"",t.startsOn?Be(t.startsOn,!1):"",t.expiresOn?Be(t.expiresOn,!1):"",ka(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Be(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Be(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,void 0,t.delegatedUserObjectId,t.ipRange?Vn(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
|
||||
`),o=e.computeHMACSHA256(i);return{sasQueryParameters:new Jn(t.version,o,s,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope,t.delegatedUserObjectId),stringToSign:i}}function ka(t,e,r){let n=[`/blob/${t}/${e}`];return r&&n.push(`/${r}`),n.join("")}function Ta(t){let e=t.version?t.version:Lg;if(t.snapshotTime&&e<"2018-11-09")throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(t.blobName===void 0&&t.snapshotTime)throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(t.versionId&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(t.blobName===void 0&&t.versionId)throw RangeError("Must provide 'blobName' when providing 'versionId'.");if(t.permissions&&t.permissions.setImmutabilityPolicy&&e<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(t.permissions&&t.permissions.deleteVersion&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(t.permissions&&t.permissions.permanentDelete&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(t.permissions&&t.permissions.tag&&e<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&t.permissions&&(t.permissions.move||t.permissions.execute))throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2021-04-10"&&t.permissions&&t.permissions.filterByTags)throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(e<"2020-02-10"&&(t.preauthorizedAgentObjectId||t.correlationId))throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(t.encryptionScope&&e<"2020-12-06")throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");return t.version=e,t}var Ud=class{_leaseId;_url;_containerOrBlobOperation;_isContainer;get leaseId(){return this._leaseId}get url(){return this._url}constructor(e,r){let n=e.storageClientContext;this._url=e.url,e.name===void 0?(this._isContainer=!0,this._containerOrBlobOperation=n.container):(this._isContainer=!1,this._containerOrBlobOperation=n.blob),r||(r=yl()),this._leaseId=r}async acquireLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Hn||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Hn||r.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-acquireLease",r,async n=>Y(await this._containerOrBlobOperation.acquireLease({abortSignal:r.abortSignal,duration:e,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},proposedLeaseId:this._leaseId,tracingOptions:n.tracingOptions})))}async changeLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Hn||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Hn||r.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-changeLease",r,async n=>{let s=Y(await this._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:r.abortSignal,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},tracingOptions:n.tracingOptions}));return this._leaseId=e,s})}async releaseLease(e={}){if(this._isContainer&&(e.conditions?.ifMatch&&e.conditions?.ifMatch!==Hn||e.conditions?.ifNoneMatch&&e.conditions?.ifNoneMatch!==Hn||e.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-releaseLease",e,async r=>Y(await this._containerOrBlobOperation.releaseLease(this._leaseId,{abortSignal:e.abortSignal,modifiedAccessConditions:{...e.conditions,ifTags:e.conditions?.tagConditions},tracingOptions:r.tracingOptions})))}async renewLease(e={}){if(this._isContainer&&(e.conditions?.ifMatch&&e.conditions?.ifMatch!==Hn||e.conditions?.ifNoneMatch&&e.conditions?.ifNoneMatch!==Hn||e.conditions?.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return q.withSpan("BlobLeaseClient-renewLease",e,async r=>this._containerOrBlobOperation.renewLease(this._leaseId,{abortSignal:e.abortSign
Line truncated
|
||||
If you are using self-hosted runners, please make sure your runner has access to all GitHub endpoints: https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/about-self-hosted-runners#communication-between-self-hosted-runners-and-github`;super(r),this.code=e,this.name="NetworkError"}};_l.isNetworkErrorCode=t=>t?["ECONNRESET","ENOTFOUND","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH"].includes(t):!1;var _a=class extends Error{constructor(){super(`Cache storage quota has been hit. Unable to upload any new cache entries.
|
||||
More info on storage limits: https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending`),this.name="UsageError"}};_a.isUsageErrorMessage=t=>t?t.includes("insufficient usage"):!1;var $d=class extends Error{constructor(e){super(e),this.name="RateLimitError"}};var qCe=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},KR=class{constructor(e){this.contentLength=e,this.sentBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}setSentBytes(e){this.sentBytes=e}getTransferredBytes(){return this.sentBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.sentBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,s=(e/(1024*1024)/(n/1e3)).toFixed(1);pe(`Sent ${e} of ${this.contentLength} (${r}%), ${s} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setSentBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){let r=()=>{this.display(),this.isDone()||(this.timeoutHandle=setTimeout(r,e))};this.timeoutHandle=setTimeout(r,e)}stopDisplayTimer(){this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=void 0),this.display()}};function f4(t,e,r){return qCe(this,void 0,void 0,function*(){var n;let s=new Di(t),i=s.getBlockBlobClient(),o=new KR((n=r?.archiveSizeBytes)!==null&&n!==void 0?n:0),a={blockSize:r?.uploadChunkSize,concurrency:r?.uploadConcurrency,maxSingleShotSize:128*1024*1024,onProgress:o.onProgress()};try{o.startDisplayTimer(),x(`BlobClient: ${s.name}:${s.accountName}:${s.containerName}`);let c=yield i.uploadFile(e,a);if(c._response.status>=400)throw new qy(`uploadCacheArchiveSDK: upload failed with status code ${c._response.status}`);return c}catch(c){throw ht(`uploadCacheArchiveSDK: internal error uploading cache archive: ${c.message}`),c}finally{o.stopDisplayTimer()}})}var y4=B(require("buffer"),1),Gs=B(require("fs"),1),E4=B(require("stream"),1),C4=B(require("util"),1);var Hy=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};function zy(t){return t?t>=200&&t<300:!1}function HCe(t){return t?t>=500:!0}function zCe(t){return t?[Ve.BadGateway,Ve.ServiceUnavailable,Ve.GatewayTimeout].includes(t):!1}function GCe(t){return Hy(this,void 0,void 0,function*(){return new Promise(e=>setTimeout(e,t))})}function g4(t,e,r){return Hy(this,arguments,void 0,function*(n,s,i,o=mf,a=pf,c=void 0){let l="",A=1;for(;A<=o;){let u,d,m=!1;try{u=yield s()}catch(p){c&&(u=c(p)),m=!0,l=p.message}if(u&&(d=i(u),!HCe(d)))return u;if(d&&(m=zCe(d),l=`Cache service responded with ${d}`),x(`${n} - Attempt ${A} of ${o} failed with error: ${l}`),!m){x(`${n} - Error is not retryable`);break}yield GCe(a),A++}throw Error(`${n} failed: ${l}`)})}function jd(t,e){return Hy(this,arguments,void 0,function*(r,n,s=mf,i=pf){return yield g4(r,n,o=>o.statusCode,s,i,o=>{if(o instanceof fs)return{statusCode:o.statusCode,result:null,headers:{},error:o}})})}function Ul(t,e){return Hy(this,arguments,void 0,function*(r,n,s=mf,i=pf){return yield g4(r,n,o=>o.message.statusCode,s,i)})}var Qn=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})};function YCe(t,e){return Qn(this,void 0,void 0,function*(){yield C4.promisify(E4.pipeline)(t.message,e)})}var Gy=class{constructor(e){this.contentLength=e,this.segmentIndex=0,this.segmentSize=0,this.segmentOffset=0,this.receivedBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}nextSegment(e){this.segmentOffset=this.segmentOffset+this.segmentSize,this.segmentIndex=this.segmentIndex+1,this.segmentSize=e,this.receivedBytes=0,x(`Downloading segment at offset ${this.segmentOffset} with length ${this.segmentSize}...`)}setReceivedBytes(e){this.receivedBytes=e}getTransferredBytes(){return this.segmentOffset+this.receivedBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.segmentOffset+this.receivedBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,s=(e/(1024*1024)/(n/1e3)).toFixed(1);pe(`Received ${e} of ${this.contentLength} (${r}%), ${s} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setReceivedBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){le
Line truncated
|
||||
Other caches with similar key:`);for(let a of i?.artifactCaches||[])x(`Cache Key: ${a?.cacheKey}, Cache Version: ${a?.cacheVersion}, Cache Scope: ${a?.scope}, Cache Created: ${a?.creationTime}`)}}})}function tP(t,e,r){return Qr(this,void 0,void 0,function*(){let n=new P4.URL(t),s=x4(r);n.hostname.endsWith(".blob.core.windows.net")?s.useAzureSdk?yield B4(t,e,s):s.concurrentBlobDownloads?yield I4(t,e,s):yield Yy(t,e):yield Yy(t,e)})}function D4(t,e,r){return Qr(this,void 0,void 0,function*(){let n=eP(),s=ll(e,r?.compressionMethod,r?.enableCrossOsArchive),i={key:t,version:s,cacheSize:r?.cacheSize};return yield jd("reserveCache",()=>Qr(this,void 0,void 0,function*(){return n.postJson(Xd("caches"),i)}))})}function R4(t,e){return`bytes ${t}-${e}/*`}function ZCe(t,e,r,n,s){return Qr(this,void 0,void 0,function*(){x(`Uploading chunk of size ${s-n+1} bytes at offset ${n} with content range: ${R4(n,s)}`);let i={"Content-Type":"application/octet-stream","Content-Range":R4(n,s)},o=yield Ul(`uploadChunk (start: ${n}, end: ${s})`,()=>Qr(this,void 0,void 0,function*(){return t.sendStream("PATCH",e,r(),i)}));if(!zy(o.message.statusCode))throw new Error(`Cache service responded with ${o.message.statusCode} during upload chunk.`)})}function eIe(t,e,r,n){return Qr(this,void 0,void 0,function*(){let s=hs(r),i=Xd(`caches/${e.toString()}`),o=Ol.openSync(r,"r"),a=XR(n),c=bb("uploadConcurrency",a.uploadConcurrency),l=bb("uploadChunkSize",a.uploadChunkSize),A=[...new Array(c).keys()];x("Awaiting all uploads");let u=0;try{yield Promise.all(A.map(()=>Qr(this,void 0,void 0,function*(){for(;u<s;){let d=Math.min(s-u,l),m=u,p=u+d-1;u+=l,yield ZCe(t,i,()=>Ol.createReadStream(r,{fd:o,start:m,end:p,autoClose:!1}).on("error",f=>{throw new Error(`Cache upload failed because file read failed with ${f.message}`)}),m,p)}})))}finally{Ol.closeSync(o)}})}function tIe(t,e,r){return Qr(this,void 0,void 0,function*(){let n={size:r};return yield jd("commitCache",()=>Qr(this,void 0,void 0,function*(){return t.postJson(Xd(`caches/${e.toString()}`),n)}))})}function rP(t,e,r,n){return Qr(this,void 0,void 0,function*(){if(XR(n).useAzureSdk){if(!r)throw new Error("Azure Storage SDK can only be used when a signed URL is provided.");yield f4(r,e,n)}else{let i=eP();x("Upload cache"),yield eIe(i,t,e,n),x("Commiting cache");let o=hs(e);pe(`Cache Size: ~${Math.round(o/(1024*1024))} MB (${o} B)`);let a=yield tIe(i,t,o);if(!zy(a.statusCode))throw new Error(`Cache service responded with ${a.statusCode} during commit cache.`);pe("Cache saved successfully")}})}var w8=B(E8(),1),lt=B(ct(),1),jr=B(ct(),1),za=B(ct(),1),Ga=B(ct(),1),Ya=B(ct(),1);var jP=B(ct(),1),KP=B(ct(),1),Q8=B(ct(),1),x8=B(ct(),1),b8=B(ct(),1);var JP=B(ct(),1),WP=B(ct(),1),C8=B(ct(),1),I8=B(ct(),1),B8=B(ct(),1),$P=class extends B8.MessageType{constructor(){super("github.actions.results.entities.v1.CacheScope",[{no:1,name:"scope",kind:"scalar",T:9},{no:2,name:"permission",kind:"scalar",T:3}])}create(e){let r={scope:"",permission:"0"};return globalThis.Object.defineProperty(r,I8.MESSAGE_TYPE,{enumerable:!1,value:this}),e!==void 0&&(0,C8.reflectionMergePartial)(this,r,e),r}internalBinaryRead(e,r,n,s){let i=s??this.create(),o=e.pos+r;for(;e.pos<o;){let[a,c]=e.tag();switch(a){case 1:i.scope=e.string();break;case 2:i.permission=e.int64().toString();break;default:let l=n.readUnknownField;if(l==="throw")throw new globalThis.Error(`Unknown field ${a} (wire type ${c}) for ${this.typeName}`);let A=e.skip(c);l!==!1&&(l===!0?WP.UnknownFieldHandler.onRead:l)(this.typeName,i,a,c,A)}}return i}internalBinaryWrite(e,r,n){e.scope!==""&&r.tag(1,JP.WireType.LengthDelimited).string(e.scope),e.permission!=="0"&&r.tag(2,JP.WireType.Varint).int64(e.permission);let s=n.writeUnknownFields;return s!==!1&&(s==!0?WP.UnknownFieldHandler.onWrite:s)(this.typeName,e,r),r}},DE=new $P;var XP=class extends b8.MessageType{constructor(){super("github.actions.results.entities.v1.CacheMetadata",[{no:1,name:"repository_id",kind:"scalar",T:3},{no:2,name:"scope",kind:"message",repeat:1,T:()=>DE}])}create(e){let r={repositoryId:"0",scope:[]};return globalThis.Object.defineProperty(r,x8.MESSAGE_TYPE,{enumerable:!1,value:this}),e!==void 0&&(0,Q8.reflectionMergePartial)(this,r,e),r}internalBinaryRead(e,r,n,s){let i=s??this.create(),o=e.pos+r;for(;e.pos<o;){let[a,c]=e.tag();switch(a){case 1:i.repositoryId=e.int64().toString();break;case 2:i.scope.push(DE.internalBinaryRead(e,e.uint32(),n));break;default:let l=n.readUnknownField;if(l==="throw")throw new globalThis.Error(`Unknown field ${a} (wire type ${c}) for ${this.typeName}`);let A=e.skip(c);l!==!1&&(l===!0?KP.UnknownFieldHandler.onRead:l)(this.typeName,i,a,c,A)}}return i}internalBinaryWrite(e,r,n){e.repositoryId!=="0"&&r.tag(1,jP.WireType.Varint).int64(e.repositoryId);for(let i=0;i<e.scope.length;i++)DE.internalBinaryWrite(e.scope[i],r.tag(2,jP.WireType.LengthDelimited).fork(),n).join();let s=n.writeUnknownFields;return s!==!1&&(s==!0?KP.UnknownFieldHandler.onWrite:s)(this.typeName,e,r),r}},$s=new
Line truncated
|
||||
`));let n=yield mv(r,"create");yield pv(n,t)})}var nA=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(o){o(i)})}return new(r||(r=Promise))(function(i,o){function a(A){try{l(n.next(A))}catch(u){o(u)}}function c(A){try{l(n.throw(A))}catch(u){o(u)}}function l(A){A.done?i(A.value):s(A.value).then(a,c)}l((n=n.apply(t,e||[])).next())})},jn=class t extends Error{constructor(e){super(e),this.name="ValidationError",Object.setPrototypeOf(this,t.prototype)}},rA=class t extends Error{constructor(e){super(e),this.name="ReserveCacheError",Object.setPrototypeOf(this,t.prototype)}},LE=class t extends Error{constructor(e){super(e),this.name="FinalizeCacheError",Object.setPrototypeOf(this,t.prototype)}};function P8(t){if(!t||t.length===0)throw new jn("Path Validation Error: At least one directory or file path is required")}function gv(t){if(t.length>512)throw new jn(`Key Validation Error: ${t} cannot be larger than 512 characters.`);if(!/^[^,]*$/.test(t))throw new jn(`Key Validation Error: ${t} cannot contain commas.`)}function yv(){return Kd()==="v2"?!!process.env.ACTIONS_RESULTS_URL:!!process.env.ACTIONS_CACHE_URL}function v8(t,e,r,n){return nA(this,arguments,void 0,function*(s,i,o,a,c=!1){let l=Kd();return x(`Cache service version: ${l}`),P8(s),l==="v2"?yield fQe(s,i,o,a,c):yield hQe(s,i,o,a,c)})}function hQe(t,e,r,n){return nA(this,arguments,void 0,function*(s,i,o,a,c=!1){o=o||[];let l=[i,...o];if(x("Resolved Keys:"),x(JSON.stringify(l)),l.length>10)throw new jn("Key Validation Error: Keys are limited to a maximum of 10.");for(let d of l)gv(d);let A=yield ju(),u="";try{let d=yield v4(l,s,{compressionMethod:A,enableCrossOsArchive:c});if(!d?.archiveLocation)return;if(a?.lookupOnly)return pe("Lookup only - skipping download"),d.cacheKey;u=pm.join(yield Wu(),po(A)),x(`Archive Path: ${u}`),yield tP(d.archiveLocation,u,a),aa()&&(yield mm(u,A));let m=hs(u);return pe(`Cache Size: ~${Math.round(m/(1024*1024))} MB (${m} B)`),yield hv(u,A),pe("Cache restored successfully"),d.cacheKey}catch(d){let m=d;if(m.name===jn.name)throw d;m instanceof fs&&typeof m.statusCode=="number"&&m.statusCode>=500?Zc(`Failed to restore: ${d.message}`):ht(`Failed to restore: ${d.message}`)}finally{try{yield $u(u)}catch(d){x(`Failed to delete archive: ${d}`)}}})}function fQe(t,e,r,n){return nA(this,arguments,void 0,function*(s,i,o,a,c=!1){a=Object.assign(Object.assign({},a),{useAzureSdk:!0}),o=o||[];let l=[i,...o];if(x("Resolved Keys:"),x(JSON.stringify(l)),l.length>10)throw new jn("Key Validation Error: Keys are limited to a maximum of 10.");for(let u of l)gv(u);let A="";try{let u=dv(),d=yield ju(),m={key:i,restoreKeys:o,version:ll(s,d,c)},p=yield u.GetCacheEntryDownloadURL(m);if(!p.ok){x(`Cache not found for version ${m.version} of keys: ${l.join(", ")}`);return}if(m.key!==p.matchedKey?pe(`Cache hit for restore-key: ${p.matchedKey}`):pe(`Cache hit for: ${p.matchedKey}`),a?.lookupOnly)return pe("Lookup only - skipping download"),p.matchedKey;A=pm.join(yield Wu(),po(d)),x(`Archive path: ${A}`),x(`Starting download of archive to: ${A}`),yield tP(p.signedDownloadUrl,A,a);let E=hs(A);return pe(`Cache Size: ~${Math.round(E/(1024*1024))} MB (${E} B)`),aa()&&(yield mm(A,d)),yield hv(A,d),pe("Cache restored successfully"),p.matchedKey}catch(u){let d=u;if(d.name===jn.name)throw u;d instanceof fs&&typeof d.statusCode=="number"&&d.statusCode>=500?Zc(`Failed to restore: ${u.message}`):ht(`Failed to restore: ${u.message}`)}finally{try{A&&(yield $u(A))}catch(u){x(`Failed to delete archive: ${u}`)}}})}function Ev(t,e,r){return nA(this,arguments,void 0,function*(n,s,i,o=!1){let a=Kd();return x(`Cache service version: ${a}`),P8(n),gv(s),a==="v2"?yield yQe(n,s,i,o):yield gQe(n,s,i,o)})}function gQe(t,e,r){return nA(this,arguments,void 0,function*(n,s,i,o=!1){var a,c,l,A,u;let d=yield ju(),m=-1,p=yield xb(n);if(x("Cache Paths:"),x(`${JSON.stringify(p)}`),p.length===0)throw new Error("Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.");let f=yield Wu(),E=pm.join(f,po(d));x(`Archive Path: ${E}`);try{yield fv(f,p,d),aa()&&(yield mm(E,d));let g=10*1024*1024*1024,y=hs(E);if(x(`File Size: ${y}`),y>g&&!ZR())throw new Error(`Cache size of ~${Math.round(y/(1024*1024))} MB (${y} B) is over the 10GB limit, not saving cache.`);x("Reserving Cache");let C=yield D4(s,n,{compressionMethod:d,enableCrossOsArchive:o,cacheSize:y});if(!((a=C?.result)===null||a===void 0)&&a.cacheId)m=(c=C?.result)===null||c===void 0?void 0:c.cacheId;else throw C?.statusCode===400?new Error((A=(l=C?.error)===null||l===void 0?void 0:l.message)!==null&&A!==void 0?A:`Cache size of ~${Math.round(y/(1024*1024))} MB (${y} B) is over the data cap limit, not saving cache.`):new rA(`Unable to reserve cache with key ${s}, another job may be creating this cache. More details: ${(u=C?.error)===null||u===void 0?void 0:u.message}`);x(`Saving Cache (ID: ${m})`),yield rP(m,E,"",i)}catch(g){let y=g;if(y.name===jn.name)throw g;y.name===rA.na
Line truncated
|
||||
`,o).length:u,l?(a===null?0:a.length)+c.length:0,l?c.length+u:0);return d<m},parse:function(n,s,i,o){let{bom:a,comment_no_infix:c,encoding:l,from_line:A,ltrim:u,max_record_size:d,raw:m,relax_quotes:p,rtrim:f,skip_empty_lines:E,to:g,to_line:y}=this.options,{comment:C,escape:I,quote:w,record_delimiter:D}=this.options,{bomSkipped:F,previousBuf:ae,rawBuffer:ye,escapeIsQuote:Qe}=this.state,H;if(ae===void 0)if(n===void 0){o();return}else H=n;else ae!==void 0&&n===void 0?H=ae:H=Buffer.concat([ae,n]);if(F===!1)if(a===!1)this.state.bomSkipped=!0;else if(H.length<3){if(s===!1){this.state.previousBuf=H;return}}else{for(let de in gA)if(gA[de].compare(H,0,gA[de].length)===0){let At=gA[de].length;this.state.bufBytesStart+=At,H=H.slice(At);let He=BD({...this.original_options,encoding:de});for(let tt in He)this.options[tt]=He[tt];({comment:C,escape:I,quote:w}=this.options);break}this.state.bomSkipped=!0}let ee=H.length,_;for(_=0;_<ee&&!this.__needMoreData(_,ee,s);_++){if(this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1),y!==-1&&this.info.lines>y){this.state.stop=!0,o();return}this.state.quoting===!1&&D.length===0&&this.__autoDiscoverRecordDelimiter(H,_)&&(D=this.options.record_delimiter);let de=H[_];if(m===!0&&ye.append(de),(de===Fwe||de===_we)&&this.state.wasRowDelimiter===!1&&(this.state.wasRowDelimiter=!0),this.state.escaping===!0)this.state.escaping=!1;else{if(I!==null&&this.state.quoting===!0&&this.__isEscape(H,_,de)&&_+I.length<ee)if(Qe){if(this.__isQuote(H,_+I.length)){this.state.escaping=!0,_+=I.length-1;continue}}else{this.state.escaping=!0,_+=I.length-1;continue}if(this.state.commenting===!1&&this.__isQuote(H,_))if(this.state.quoting===!0){let tt=H[_+w.length],Zs=f&&this.__isCharTrimable(H,_+w.length),Nr=C!==null&&this.__compareBytes(C,H,_+w.length,tt),Zn=this.__isDelimiter(H,_+w.length,tt),To=D.length===0?this.__autoDiscoverRecordDelimiter(H,_+w.length):this.__isRecordDelimiter(tt,H,_+w.length);if(I!==null&&this.__isEscape(H,_,de)&&this.__isQuote(H,_+I.length))_+=I.length-1;else if(!tt||Zn||To||Nr||Zs){this.state.quoting=!1,this.state.wasQuoting=!0,_+=w.length-1;continue}else if(p===!1){let Xa=this.__error(new ge("CSV_INVALID_CLOSING_QUOTE",["Invalid Closing Quote:",`got "${String.fromCharCode(tt)}"`,`at line ${this.info.lines}`,"instead of delimiter, record delimiter, trimable character","(if activated) or comment"],this.options,this.__infoField()));if(Xa!==void 0)return Xa}else this.state.quoting=!1,this.state.wasQuoting=!0,this.state.field.prepend(w),_+=w.length-1}else if(this.state.field.length!==0){if(p===!1){let tt=this.__infoField(),Zs=Object.keys(gA).map(Zn=>gA[Zn].equals(this.state.field.toString())?Zn:!1).filter(Boolean)[0],Nr=this.__error(new ge("INVALID_OPENING_QUOTE",["Invalid Opening Quote:",`a quote is found on field ${JSON.stringify(tt.column)} at line ${tt.lines}, value is ${JSON.stringify(this.state.field.toString(l))}`,Zs?`(${Zs} bom)`:void 0],this.options,tt,{field:this.state.field}));if(Nr!==void 0)return Nr}}else{this.state.quoting=!0,_+=w.length-1;continue}if(this.state.quoting===!1){let tt=this.__isRecordDelimiter(de,H,_);if(tt!==0){if(this.state.commenting&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0)this.info.comment_lines++;else{if(this.state.enabled===!1&&this.info.lines+(this.state.wasRowDelimiter===!0?1:0)>=A){this.state.enabled=!0,this.__resetField(),this.__resetRecord(),_+=tt-1;continue}if(E===!0&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0){this.info.empty_lines++,_+=tt-1;continue}this.info.bytes=this.state.bufBytesStart+_;let Zn=this.__onField();if(Zn!==void 0)return Zn;this.info.bytes=this.state.bufBytesStart+_+tt;let To=this.__onRecord(i);if(To!==void 0)return To;if(g!==-1&&this.info.records>=g){this.state.stop=!0,o();return}}this.state.commenting=!1,_+=tt-1;continue}if(this.state.commenting)continue;if(C!==null&&(c===!1||this.state.record.length===0&&this.state.field.length===0)&&this.__compareBytes(C,H,_,de)!==0){this.state.commenting=!0;continue}let Zs=this.__isDelimiter(H,_,de);if(Zs!==0){this.info.bytes=this.state.bufBytesStart+_;let Nr=this.__onField();if(Nr!==void 0)return Nr;_+=Zs-1;continue}}}if(this.state.commenting===!1&&d!==0&&this.state.record_length+this.state.field.length>d)return this.__error(new ge("CSV_MAX_RECORD_SIZE",["Max Record Size:","record exceed the maximum number of tolerated bytes",`of ${d}`,`at line ${this.info.lines}`],this.options,this.__infoField()));let At=u===!1||this.state.quoting===!0||this.state.field.length!==0||!this.__isCharTrimable(H,_),He=f===!1||this.state.wasQuoting===!1;if(At===!0&&He===!0)this.state.field.append(de);else{if(f===!0&&!this.__isCharTrimable(H,_))return this.__error(new ge("CSV_NON_TRIMABLE_CHAR_AFTER_CLOSING_QUOTE",["Invalid Closing Quote:","found non trimable byte after quote",`at line ${this.info.lines}`],this.options,this.__infoField()));At===!1&&(_+=this.__isCharTrimable(H,_)-1);continue}}if(s===!0
Line truncated
|
||||
`,i),Buffer.from(`
|
||||
`,i),Buffer.from("\r",i)];e:for(let a=0;a<o.length;a++){let c=o[a].length;for(let l=0;l<c;l++)if(o[a][l]!==n[s+l])continue e;return this.options.record_delimiter.push(o[a]),this.state.recordDelimiterMaxLength=o[a].length,o[a].length}return 0},__error:function(n){let{encoding:s,raw:i,skip_records_with_error:o}=this.options,a=typeof n=="string"?new Error(n):n;if(o){if(this.state.recordHasError=!0,this.options.on_skip!==void 0)try{this.options.on_skip(a,i?this.state.rawBuffer.toString(s):void 0)}catch(c){return c}return}else return a},__infoDataSet:function(){return{...this.info,columns:this.options.columns}},__infoRecord:function(){let{columns:n,raw:s,encoding:i}=this.options;return{...this.__infoDataSet(),bytes_records:this.info.bytes,error:this.state.error,header:n===!0,index:this.state.record.length,raw:s?this.state.rawBuffer.toString(i):void 0}},__infoField:function(){let{columns:n}=this.options,s=Array.isArray(n),i=this.info.bytes_records;return{...this.__infoRecord(),bytes_records:i,column:s===!0?n.length>this.state.record.length?n[this.state.record.length].name:null:this.state.record.length,quoting:this.state.wasQuoting}}}};var g5=function(t,e={}){typeof t=="string"&&(t=Buffer.from(t));let r=e&&e.objname?{}:[],n=f5(e),s=a=>{n.options.objname===void 0?r.push(a):r[a[0]]=a[1]},i=()=>{},o=n.parse(t,!0,s,i);if(o!==void 0)throw o;return r};var BA=class t{static getInputList(e,r){return this.getList(Dx(e,{trimWhitespace:r?.trimWhitespace!==!1}),r)}static getList(e,r){let n=[];if(e=="")return n;let s=g5(e,{columns:!1,relaxQuotes:!0,comment:r?.comment,comment_no_infix:r?.commentNoInfix,relaxColumnCount:!0,skipEmptyLines:!0,quote:r?.quote});for(let i of s)i.length==1?r?.ignoreComma?n.push(i[0]):n.push(...i[0].split(",")):r?.ignoreComma?n.push(i.join(",")):n.push(...i);return n.filter(i=>i).map(i=>r?.trimWhitespace===!1?i:i.trim())}static getInputNumber(e){let r=Dx(e);if(r)return parseInt(r)}static async asyncForEach(e,r){for(let n=0;n<e.length;n++)await r(e[n],n,e)}static isValidURL(e){let r;try{r=new URL(e)}catch{return!1}return r.protocol==="http:"||r.protocol==="https:"}static isValidRef(e){if(t.isValidURL(e))return!0;for(let r of["git://","github.com/","git@"])if(e.startsWith(r))return!0;return!1}static async powershellCommand(e,r){let n=await ur("powershell",!0),s=e.replace(/'/g,"''").replace(/"|\n|\r/g,""),i=[];if(r)for(let o in r)i.push(`-${o} '${r[o].replace(/'/g,"''").replace(/"|\n|\r/g,"")}'`);return{command:`"${n}"`,args:["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",`& '${s}' ${i.join(" ")}`]}}static isDirectory(e){try{return y5.default.lstatSync(e).isDirectory()}catch{}return!1}static trimPrefix(e,r){return!e||!r||e.indexOf(r)!==0?e:e.substring(r.length)}static trimSuffix(e,r){if(!e||!r)return e;let n=e.lastIndexOf(r);return n===-1||n+r.length!==e.length?e:e.substring(0,n)}static sleep(e){return new Promise(r=>setTimeout(r,e*1e3))}static hash(e){return MD.default.createHash("sha256").update(e).digest("hex")}static parseBool(e){if(e===void 0)return!1;switch(e){case"1":case"t":case"T":case"true":case"TRUE":case"True":return!0;case"0":case"f":case"F":case"false":case"FALSE":case"False":return!1;default:throw new Error(`parseBool syntax error: ${e}`)}}static parseBoolOrDefault(e,r=!1){try{return this.parseBool(e)}catch{return r}}static formatFileSize(e){if(e===0)return"0 Bytes";let r=1024,n=["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"],s=Math.floor(Math.log(e)/Math.log(r));return parseFloat((e/Math.pow(r,s)).toFixed(2))+" "+n[s]}static generateRandomString(e=10){return MD.default.randomBytes(Math.ceil(e/2)).toString("hex").slice(0,e)}static compileHandlebars(e,r,n){return E5.default.compile(e,r)(n)}static stringToUnicodeEntities(e){return Array.from(e).map(r=>`&#x${r.charCodeAt(0).toString(16)};`).join("")}static countLines(e){return e.split(/\r\n|\r|\n/).length}static isPathRelativeTo(e,r){let n=Fm.default.resolve(e);return Fm.default.resolve(r).startsWith(n.endsWith(Fm.default.sep)?n:`${n}${Fm.default.sep}`)}static formatDuration(e){if(e===0)return"0s";let r=Math.floor(e/1e9),n=Math.floor(r/3600),s=Math.floor(r%3600/60),i=r%60,o=[];return n&&o.push(`${n}h`),s&&o.push(`${s}m`),(i||o.length===0)&&o.push(`${i}s`),o.join("")}};var Xn=class t{static get configDir(){return process.env.DOCKER_CONFIG||Um.default.join(C5.default.homedir(),".docker")}static configFile(){let e=Um.default.join(t.configDir,"config.json");if(LD.default.existsSync(e))return JSON.parse(LD.default.readFileSync(e,{encoding:"utf-8"}))}static async isAvailable(){return await ur("docker",!0).then(e=>(Lr(`Docker.isAvailable ok: ${e}`),!0)).catch(e=>(Lr(`Docker.isAvailable error: ${e}`),!1))}static async isDaemonRunning(){try{return await t.getExecOutput(["version"],{silent:!0}),!0}catch{return!1}}static async exec(e,r){return Qm.exec("docker",e,t.execOptions(r))}static async getExecOutput(e,r){return Qm.getExecOutput("docker",e,t.execOptions(r))}static execOptions(e){return e||(e={}),e.en
Line truncated
|
||||
`,i),Buffer.from("\r",i)];e:for(let a=0;a<o.length;a++){let c=o[a].length;for(let l=0;l<c;l++)if(o[a][l]!==n[s+l])continue e;return this.options.record_delimiter.push(o[a]),this.state.recordDelimiterMaxLength=o[a].length,o[a].length}return 0},__error:function(n){let{encoding:s,raw:i,skip_records_with_error:o}=this.options,a=typeof n=="string"?new Error(n):n;if(o){if(this.state.recordHasError=!0,this.options.on_skip!==void 0)try{this.options.on_skip(a,i?this.state.rawBuffer.toString(s):void 0)}catch(c){return c}return}else return a},__infoDataSet:function(){return{...this.info,columns:this.options.columns}},__infoRecord:function(){let{columns:n,raw:s,encoding:i}=this.options;return{...this.__infoDataSet(),bytes_records:this.info.bytes,error:this.state.error,header:n===!0,index:this.state.record.length,raw:s?this.state.rawBuffer.toString(i):void 0}},__infoField:function(){let{columns:n}=this.options,s=Array.isArray(n),i=this.info.bytes_records;return{...this.__infoRecord(),bytes_records:i,column:s===!0?n.length>this.state.record.length?n[this.state.record.length].name:null:this.state.record.length,quoting:this.state.wasQuoting}}}};var K$=function(t,e={}){typeof t=="string"&&(t=Buffer.from(t));let r=e&&e.objname?{}:[],n=j$(e),s=a=>{n.options.objname===void 0?r.push(a):r[a[0]]=a[1]},i=()=>{},o=n.parse(t,!0,s,i);if(o!==void 0)throw o;return r};var yA=class t{static getInputList(e,r){return this.getList(Xc(e,{trimWhitespace:r?.trimWhitespace!==!1}),r)}static getList(e,r){let n=[];if(e=="")return n;let s=K$(e,{columns:!1,relaxQuotes:!0,comment:r?.comment,comment_no_infix:r?.commentNoInfix,relaxColumnCount:!0,skipEmptyLines:!0,quote:r?.quote});for(let i of s)i.length==1?r?.ignoreComma?n.push(i[0]):n.push(...i[0].split(",")):r?.ignoreComma?n.push(i.join(",")):n.push(...i);return n.filter(i=>i).map(i=>r?.trimWhitespace===!1?i:i.trim())}static getInputNumber(e){let r=Xc(e);if(r)return parseInt(r)}static async asyncForEach(e,r){for(let n=0;n<e.length;n++)await r(e[n],n,e)}static isValidURL(e){let r;try{r=new URL(e)}catch{return!1}return r.protocol==="http:"||r.protocol==="https:"}static isValidRef(e){if(t.isValidURL(e))return!0;for(let r of["git://","github.com/","git@"])if(e.startsWith(r))return!0;return!1}static async powershellCommand(e,r){let n=await dr("powershell",!0),s=e.replace(/'/g,"''").replace(/"|\n|\r/g,""),i=[];if(r)for(let o in r)i.push(`-${o} '${r[o].replace(/'/g,"''").replace(/"|\n|\r/g,"")}'`);return{command:`"${n}"`,args:["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",`& '${s}' ${i.join(" ")}`]}}static isDirectory(e){try{return X$.default.lstatSync(e).isDirectory()}catch{}return!1}static trimPrefix(e,r){return!e||!r||e.indexOf(r)!==0?e:e.substring(r.length)}static trimSuffix(e,r){if(!e||!r)return e;let n=e.lastIndexOf(r);return n===-1||n+r.length!==e.length?e:e.substring(0,n)}static sleep(e){return new Promise(r=>setTimeout(r,e*1e3))}static hash(e){return QD.default.createHash("sha256").update(e).digest("hex")}static parseBool(e){if(e===void 0)return!1;switch(e){case"1":case"t":case"T":case"true":case"TRUE":case"True":return!0;case"0":case"f":case"F":case"false":case"FALSE":case"False":return!1;default:throw new Error(`parseBool syntax error: ${e}`)}}static parseBoolOrDefault(e,r=!1){try{return this.parseBool(e)}catch{return r}}static formatFileSize(e){if(e===0)return"0 Bytes";let r=1024,n=["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"],s=Math.floor(Math.log(e)/Math.log(r));return parseFloat((e/Math.pow(r,s)).toFixed(2))+" "+n[s]}static generateRandomString(e=10){return QD.default.randomBytes(Math.ceil(e/2)).toString("hex").slice(0,e)}static compileHandlebars(e,r,n){return Z$.default.compile(e,r)(n)}static stringToUnicodeEntities(e){return Array.from(e).map(r=>`&#x${r.charCodeAt(0).toString(16)};`).join("")}static countLines(e){return e.split(/\r\n|\r|\n/).length}static isPathRelativeTo(e,r){let n=Pm.default.resolve(e);return Pm.default.resolve(r).startsWith(n.endsWith(Pm.default.sep)?n:`${n}${Pm.default.sep}`)}static formatDuration(e){if(e===0)return"0s";let r=Math.floor(e/1e9),n=Math.floor(r/3600),s=Math.floor(r%3600/60),i=r%60,o=[];return n&&o.push(`${n}h`),s&&o.push(`${s}m`),(i||o.length===0)&&o.push(`${i}s`),o.join("")}};var Xn=class t{static get configDir(){return process.env.DOCKER_CONFIG||vm.default.join(e5.default.homedir(),".docker")}static configFile(){let e=vm.default.join(t.configDir,"config.json");if(xD.default.existsSync(e))return JSON.parse(xD.default.readFileSync(e,{encoding:"utf-8"}))}static async isAvailable(){return await dr("docker",!0).then(e=>(x(`Docker.isAvailable ok: ${e}`),!0)).catch(e=>(x(`Docker.isAvailable error: ${e}`),!1))}static async isDaemonRunning(){try{return await t.getExecOutput(["version"],{silent:!0}),!0}catch{return!1}}static async exec(e,r){return hm.exec("docker",e,t.execOptions(r))}static async getExecOutput(e,r){return hm.getExecOutput("docker",e,t.execOptions(r))}static execOptions(e){return e||(e={}),e.env?
Line truncated
|
||||
/*! Bundled license information:
|
||||
|
||||
undici/lib/web/fetch/body.js:
|
||||
|
||||
+4
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"version": 3,
|
||||
"sources": ["../node_modules/tunnel/lib/tunnel.js", "../node_modules/tunnel/index.js", "../node_modules/undici/lib/core/symbols.js", "../node_modules/undici/lib/core/errors.js", "../node_modules/undici/lib/core/constants.js", "../node_modules/undici/lib/core/tree.js", "../node_modules/undici/lib/core/util.js", "../node_modules/undici/lib/core/diagnostics.js", "../node_modules/undici/lib/core/request.js", "../node_modules/undici/lib/dispatcher/dispatcher.js", "../node_modules/undici/lib/dispatcher/dispatcher-base.js", "../node_modules/undici/lib/util/timers.js", "../node_modules/undici/lib/core/connect.js", "../node_modules/undici/lib/llhttp/utils.js", "../node_modules/undici/lib/llhttp/constants.js", "../node_modules/undici/lib/llhttp/llhttp-wasm.js", "../node_modules/undici/lib/llhttp/llhttp_simd-wasm.js", "../node_modules/undici/lib/web/fetch/constants.js", "../node_modules/undici/lib/web/fetch/global.js", "../node_modules/undici/lib/web/fetch/data-url.js", "../node_modules/undici/lib/web/fetch/webidl.js", "../node_modules/undici/lib/web/fetch/util.js", "../node_modules/undici/lib/web/fetch/symbols.js", "../node_modules/undici/lib/web/fetch/file.js", "../node_modules/undici/lib/web/fetch/formdata.js", "../node_modules/undici/lib/web/fetch/formdata-parser.js", "../node_modules/undici/lib/web/fetch/body.js", "../node_modules/undici/lib/dispatcher/client-h1.js", "../node_modules/undici/lib/dispatcher/client-h2.js", "../node_modules/undici/lib/handler/redirect-handler.js", "../node_modules/undici/lib/interceptor/redirect-interceptor.js", "../node_modules/undici/lib/dispatcher/client.js", "../node_modules/undici/lib/dispatcher/fixed-queue.js", "../node_modules/undici/lib/dispatcher/pool-stats.js", "../node_modules/undici/lib/dispatcher/pool-base.js", "../node_modules/undici/lib/dispatcher/pool.js", "../node_modules/undici/lib/dispatcher/balanced-pool.js", "../node_modules/undici/lib/dispatcher/agent.js", "../node_modules/undici/lib/dispatcher/proxy-agent.js", "../node_modules/undici/lib/dispatcher/env-http-proxy-agent.js", "../node_modules/undici/lib/handler/retry-handler.js", "../node_modules/undici/lib/dispatcher/retry-agent.js", "../node_modules/undici/lib/api/readable.js", "../node_modules/undici/lib/api/util.js", "../node_modules/undici/lib/api/api-request.js", "../node_modules/undici/lib/api/abort-signal.js", "../node_modules/undici/lib/api/api-stream.js", "../node_modules/undici/lib/api/api-pipeline.js", "../node_modules/undici/lib/api/api-upgrade.js", "../node_modules/undici/lib/api/api-connect.js", "../node_modules/undici/lib/api/index.js", "../node_modules/undici/lib/mock/mock-errors.js", "../node_modules/undici/lib/mock/mock-symbols.js", "../node_modules/undici/lib/mock/mock-utils.js", "../node_modules/undici/lib/mock/mock-interceptor.js", "../node_modules/undici/lib/mock/mock-client.js", "../node_modules/undici/lib/mock/mock-pool.js", "../node_modules/undici/lib/mock/pluralizer.js", "../node_modules/undici/lib/mock/pending-interceptors-formatter.js", "../node_modules/undici/lib/mock/mock-agent.js", "../node_modules/undici/lib/global.js", "../node_modules/undici/lib/handler/decorator-handler.js", "../node_modules/undici/lib/interceptor/redirect.js", "../node_modules/undici/lib/interceptor/retry.js", "../node_modules/undici/lib/interceptor/dump.js", "../node_modules/undici/lib/interceptor/dns.js", "../node_modules/undici/lib/web/fetch/headers.js", "../node_modules/undici/lib/web/fetch/response.js", "../node_modules/undici/lib/web/fetch/dispatcher-weakref.js", "../node_modules/undici/lib/web/fetch/request.js", "../node_modules/undici/lib/web/fetch/index.js", "../node_modules/undici/lib/web/fileapi/symbols.js", "../node_modules/undici/lib/web/fileapi/progressevent.js", "../node_modules/undici/lib/web/fileapi/encoding.js", "../node_modules/undici/lib/web/fileapi/util.js", "../node_modules/undici/lib/web/fileapi/filereader.js", "../node_modules/undici/lib/web/cache/symbols.js", "../node_modules/undici/lib/web/cache/util.js", "../node_modules/undici/lib/web/cache/cache.js", "../node_modules/undici/lib/web/cache/cachestorage.js", "../node_modules/undici/lib/web/cookies/constants.js", "../node_modules/undici/lib/web/cookies/util.js", "../node_modules/undici/lib/web/cookies/parse.js", "../node_modules/undici/lib/web/cookies/index.js", "../node_modules/undici/lib/web/websocket/events.js", "../node_modules/undici/lib/web/websocket/constants.js", "../node_modules/undici/lib/web/websocket/symbols.js", "../node_modules/undici/lib/web/websocket/util.js", "../node_modules/undici/lib/web/websocket/frame.js", "../node_modules/undici/lib/web/websocket/connection.js", "../node_modules/undici/lib/web/websocket/permessage-deflate.js", "../node_modules/undici/lib/web/websocket/receiver.js", "../node_modules/undici/lib/web/websocket/sender.js", "../node_modules/undici/lib/web/websocket/websocket.js", "../node_modules/undici/lib/web/eventsource/util.js", "../node_modules/undici/lib/web/eventsource/eventsource-stream.js",Line truncated
|
||||
"sourcesContent": ["'use strict';\n\nvar net = require('net');\nvar tls = require('tls');\nvar http = require('http');\nvar https = require('https');\nvar events = require('events');\nvar assert = require('assert');\nvar util = require('util');\n\n\nexports.httpOverHttp = httpOverHttp;\nexports.httpsOverHttp = httpsOverHttp;\nexports.httpOverHttps = httpOverHttps;\nexports.httpsOverHttps = httpsOverHttps;\n\n\nfunction httpOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n return agent;\n}\n\nfunction httpsOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\nfunction httpOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n return agent;\n}\n\nfunction httpsOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\n\nfunction TunnelingAgent(options) {\n var self = this;\n self.options = options || {};\n self.proxyOptions = self.options.proxy || {};\n self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets;\n self.requests = [];\n self.sockets = [];\n\n self.on('free', function onFree(socket, host, port, localAddress) {\n var options = toOptions(host, port, localAddress);\n for (var i = 0, len = self.requests.length; i < len; ++i) {\n var pending = self.requests[i];\n if (pending.host === options.host && pending.port === options.port) {\n // Detect the request to connect same origin server,\n // reuse the connection.\n self.requests.splice(i, 1);\n pending.request.onSocket(socket);\n return;\n }\n }\n socket.destroy();\n self.removeSocket(socket);\n });\n}\nutil.inherits(TunnelingAgent, events.EventEmitter);\n\nTunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) {\n var self = this;\n var options = mergeOptions({request: req}, self.options, toOptions(host, port, localAddress));\n\n if (self.sockets.length >= this.maxSockets) {\n // We are over limit so we'll add it to the queue.\n self.requests.push(options);\n return;\n }\n\n // If we are under maxSockets create a new one.\n self.createSocket(options, function(socket) {\n socket.on('free', onFree);\n socket.on('close', onCloseOrRemove);\n socket.on('agentRemove', onCloseOrRemove);\n req.onSocket(socket);\n\n function onFree() {\n self.emit('free', socket, options);\n }\n\n function onCloseOrRemove(err) {\n self.removeSocket(socket);\n socket.removeListener('free', onFree);\n socket.removeListener('close', onCloseOrRemove);\n socket.removeListener('agentRemove', onCloseOrRemove);\n }\n });\n};\n\nTunnelingAgent.prototype.createSocket = function createSocket(options, cb) {\n var self = this;\n var placeholder = {};\n self.sockets.push(placeholder);\n\n var connectOptions = mergeOptions({}, self.proxyOptions, {\n method: 'CONNECT',\n path: options.host + ':' + options.port,\n agent: false,\n headers: {\n host: options.host + ':' + options.port\n }\n });\n if (options.localAddress) {\n connectOptions.localAddress = options.localAddress;\n }\n if (connectOptions.proxyAuth) {\n connectOptions.headers = connectOptions.headers || {};\n connectOptions.headers['Proxy-Authorization'] = 'Basic ' +\n new Buffer(connectOptions.proxyAuth).toString('base64');\n }\n\n debug('making CONNECT request');\n var connectReq = self.request(connectOptions);\n connectReq.useChunkedEncodingByDefault = false; // for v0.6\n connectReq.once('response', onResponse); // for v0.6\n connectReq.once('upgrade', onUpgrade); // for v0.6\n connectReq.once('connect', onConnect); // for v0.7 or later\n connectReq.once('error', onError);\n connectReq.end();\n\n function onResponse(res) {\n // Very hacky. This is necessary to avoid http-parser leaks.\n res.upgrade = true;\n }\n\n function onUpgrade(res, socket, head) {\n // Hacky.\n process.nextTick(function() {\n onConnect(res, socket, head);\n });\n }\n\n function onConnect(res, socket, head) {\n connectReq.removeAllListeners();\n socket.removeAllListeners();\n\n if (res.statusCode !== 200) {\n debug('tunneling socket could not be established, statusCode=%d',\n res.statusCode);\n socket.destroy();\n var error = new Error('tunneling socket could not be established, ' +\n 'statusCode=' + res.statusCode);\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n return;\n }\n if (head.length > 0) {\n debug('got illegal response body from proxy');\n socket.destroy();\n var error = new Error('Line truncated
|
||||
"mappings": "glBAAA,IAAAA,GAAAC,EAAAC,IAAA,cAEA,IAAIC,IAAM,QAAQ,KAAK,EACnBC,GAAM,QAAQ,KAAK,EACnBC,GAAO,QAAQ,MAAM,EACrBC,GAAQ,QAAQ,OAAO,EACvBC,GAAS,QAAQ,QAAQ,EACzBC,IAAS,QAAQ,QAAQ,EACzBC,GAAO,QAAQ,MAAM,EAGzBP,GAAQ,aAAeQ,GACvBR,GAAQ,cAAgBS,GACxBT,GAAQ,cAAgBU,GACxBV,GAAQ,eAAiBW,GAGzB,SAASH,GAAaI,EAAS,CAC7B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUV,GAAK,QACdU,CACT,CAEA,SAASJ,GAAcG,EAAS,CAC9B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUV,GAAK,QACrBU,EAAM,aAAeE,GACrBF,EAAM,YAAc,IACbA,CACT,CAEA,SAASH,GAAcE,EAAS,CAC9B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUT,GAAM,QACfS,CACT,CAEA,SAASF,GAAeC,EAAS,CAC/B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUT,GAAM,QACtBS,EAAM,aAAeE,GACrBF,EAAM,YAAc,IACbA,CACT,CAGA,SAASC,GAAeF,EAAS,CAC/B,IAAII,EAAO,KACXA,EAAK,QAAUJ,GAAW,CAAC,EAC3BI,EAAK,aAAeA,EAAK,QAAQ,OAAS,CAAC,EAC3CA,EAAK,WAAaA,EAAK,QAAQ,YAAcb,GAAK,MAAM,kBACxDa,EAAK,SAAW,CAAC,EACjBA,EAAK,QAAU,CAAC,EAEhBA,EAAK,GAAG,OAAQ,SAAgBC,EAAQC,EAAMC,EAAMC,EAAc,CAEhE,QADIR,EAAUS,GAAUH,EAAMC,EAAMC,CAAY,EACvCE,EAAI,EAAGC,EAAMP,EAAK,SAAS,OAAQM,EAAIC,EAAK,EAAED,EAAG,CACxD,IAAIE,EAAUR,EAAK,SAASM,CAAC,EAC7B,GAAIE,EAAQ,OAASZ,EAAQ,MAAQY,EAAQ,OAASZ,EAAQ,KAAM,CAGlEI,EAAK,SAAS,OAAOM,EAAG,CAAC,EACzBE,EAAQ,QAAQ,SAASP,CAAM,EAC/B,MACF,CACF,CACAA,EAAO,QAAQ,EACfD,EAAK,aAAaC,CAAM,CAC1B,CAAC,CACH,CACAV,GAAK,SAASO,GAAgBT,GAAO,YAAY,EAEjDS,GAAe,UAAU,WAAa,SAAoBW,EAAKP,EAAMC,EAAMC,EAAc,CACvF,IAAIJ,EAAO,KACPJ,EAAUc,GAAa,CAAC,QAASD,CAAG,EAAGT,EAAK,QAASK,GAAUH,EAAMC,EAAMC,CAAY,CAAC,EAE5F,GAAIJ,EAAK,QAAQ,QAAU,KAAK,WAAY,CAE1CA,EAAK,SAAS,KAAKJ,CAAO,EAC1B,MACF,CAGAI,EAAK,aAAaJ,EAAS,SAASK,EAAQ,CAC1CA,EAAO,GAAG,OAAQU,CAAM,EACxBV,EAAO,GAAG,QAASW,CAAe,EAClCX,EAAO,GAAG,cAAeW,CAAe,EACxCH,EAAI,SAASR,CAAM,EAEnB,SAASU,GAAS,CAChBX,EAAK,KAAK,OAAQC,EAAQL,CAAO,CACnC,CAEA,SAASgB,EAAgBC,EAAK,CAC5Bb,EAAK,aAAaC,CAAM,EACxBA,EAAO,eAAe,OAAQU,CAAM,EACpCV,EAAO,eAAe,QAASW,CAAe,EAC9CX,EAAO,eAAe,cAAeW,CAAe,CACtD,CACF,CAAC,CACH,EAEAd,GAAe,UAAU,aAAe,SAAsBF,EAASkB,EAAI,CACzE,IAAId,EAAO,KACPe,EAAc,CAAC,EACnBf,EAAK,QAAQ,KAAKe,CAAW,EAE7B,IAAIC,EAAiBN,GAAa,CAAC,EAAGV,EAAK,aAAc,CACvD,OAAQ,UACR,KAAMJ,EAAQ,KAAO,IAAMA,EAAQ,KACnC,MAAO,GACP,QAAS,CACP,KAAMA,EAAQ,KAAO,IAAMA,EAAQ,IACrC,CACF,CAAC,EACGA,EAAQ,eACVoB,EAAe,aAAepB,EAAQ,cAEpCoB,EAAe,YACjBA,EAAe,QAAUA,EAAe,SAAW,CAAC,EACpDA,EAAe,QAAQ,qBAAqB,EAAI,SAC5C,IAAI,OAAOA,EAAe,SAAS,EAAE,SAAS,QAAQ,GAG5DC,GAAM,wBAAwB,EAC9B,IAAIC,EAAalB,EAAK,QAAQgB,CAAc,EAC5CE,EAAW,4BAA8B,GACzCA,EAAW,KAAK,WAAYC,CAAU,EACtCD,EAAW,KAAK,UAAWE,CAAS,EACpCF,EAAW,KAAK,UAAWG,CAAS,EACpCH,EAAW,KAAK,QAASI,CAAO,EAChCJ,EAAW,IAAI,EAEf,SAASC,EAAWI,EAAK,CAEvBA,EAAI,QAAU,EAChB,CAEA,SAASH,EAAUG,EAAKtB,EAAQuB,EAAM,CAEpC,QAAQ,SAAS,UAAW,CAC1BH,EAAUE,EAAKtB,EAAQuB,CAAI,CAC7B,CAAC,CACH,CAEA,SAASH,EAAUE,EAAKtB,EAAQuB,EAAM,CAIpC,GAHAN,EAAW,mBAAmB,EAC9BjB,EAAO,mBAAmB,EAEtBsB,EAAI,aAAe,IAAK,CAC1BN,GAAM,2DACJM,EAAI,UAAU,EAChBtB,EAAO,QAAQ,EACf,IAAIwB,EAAQ,IAAI,MAAM,yDACJF,EAAI,UAAU,EAChCE,EAAM,KAAO,aACb7B,EAAQ,QAAQ,KAAK,QAAS6B,CAAK,EACnCzB,EAAK,aAAae,CAAW,EAC7B,MACF,CACA,GAAIS,EAAK,OAAS,EAAG,CACnBP,GAAM,sCAAsC,EAC5ChB,EAAO,QAAQ,EACf,IAAIwB,EAAQ,IAAI,MAAM,sCAAsC,EAC5DA,EAAM,KAAO,aACb7B,EAAQ,QAAQ,KAAK,QAAS6B,CAAK,EACnCzB,EAAK,aAAae,CAAW,EAC7B,MACF,CACA,OAAAE,GAAM,sCAAsC,EAC5CjB,EAAK,QAAQA,EAAK,QAAQ,QAAQe,CAAW,CAAC,EAAId,EAC3Ca,EAAGb,CAAM,CAClB,CAEA,SAASqB,EAAQI,EAAO,CACtBR,EAAW,mBAAmB,EAE9BD,GAAM;AAAA,EACAS,EAAM,QAASA,EAAM,KAAK,EAChC,IAAID,EAAQ,IAAI,MAAM,oDACWC,EAAM,OAAO,EAC9CD,EAAM,KAAO,aACb7B,EAAQ,QAAQ,KAAK,QAAS6B,CAAK,EACnCzB,EAAK,aAAae,CAAW,CAC/B,CACF,EAEAjB,GAAe,UAAU,aAAe,SAAsBG,EAAQ,CACpE,IAAI0B,EAAM,KAAK,QAAQ,QAAQ1B,CAAM,EACrC,GAAI0B,IAAQ,GAGZ,MAAK,QAAQ,OAAOA,EAAK,CAAC,EAE1B,IAAInB,EAAU,KAAK,SAAS,MAAM,EAC9BA,GAGF,KAAK,aAAaA,EAAS,SAASP,EAAQ,CAC1CO,EAAQ,QAAQ,SAASP,CAAM,CACjC,CAAC,EAEL,EAEA,SAASF,GAAmBH,EAASkB,EAAI,CACvC,IAAId,EAAO,KACXF,GAAe,UAAU,aAAa,KAAKE,EAAMJ,EAAS,SAASK,EAAQ,CACzE,IAAI2B,EAAahC,EAAQ,QAAQ,UAAU,MAAM,EAC7CiC,EAAanB,GAAa,CAAC,EAAGV,EAAK,QAAS,CAC9C,OAAQC,EACR,WAAY2B,EAAaA,EAAW,QAAQ,OAAQ,EAAE,EAAIhC,EAAQ,IACpE,CAAC,EAGGkC,EAAe5C,GAAI,QAAQ,EAAG2C,CAAU,EAC5C7B,EAAK,QAAQA,EAAK,QAAQ,QAAQC,CAAM,CAAC,EAAI6B,EAC7ChB,EAAGgB,CAAY,CACjB,CAAC,CACH,CAGA,SAASzB,GAAUH,EAAMC,EAAMC,EAAc,CAC3C,OAAI,OAAOF,GAAS,SACX,CACL,KAAMA,EACN,KAAMC,EACN,aAAcC,CAChB,EAEKF,CACT,CAEA,SAASQ,GAAaqB,EAAQ,CAC5B,QAASzB,EAAI,EAAGC,EAAM,UAAU,OAAQD,EAAIC,EAAK,EAAED,EAAG,CACpD,IAAI0B,EAAY,UAAU1B,CAAC,EAC3B,GAAI,OAAO0B,GAAc,SAEvB,QADIC,EAAO,OAAO,KAAKD,CAAS,EACvBE,EAAI,EAAGC,EAASF,EAAK,OAAQC,EAAIC,EAAQ,EAAED,EAAG,CACrD,IAAIE,EAAIH,EAAKC,CAAC,EACVF,EAAUI,CAAC,IAAM,SACnBL,EAAOK,CAAC,EAAIJ,EAAUI,CAAC,EAE3B,CAEJ,CACA,OAAOL,CACT,CAGA,IAAId,GACA,QAAQ,IAAI,YAAc,aAAa,KAAK,QAAQ,IAAI,UAAU,EACpEA,GAAQ,UAAW,CACjB,IAAIoB,EAAO,MAAM,UAAU,MAAM,KAAK,SAAS,EAC3C,OAAOA,EAAK,CAAC,GAAM,SACrBA,EAAK,CAAC,EAAI,WAAaA,EAAK,CAAC,EAE7BA,EAAK,QAAQ,SAAS,EAExB,QAAQ,MAAM,MAAM,QAASA,CAAI,CACnC,EAEApB,GAAQ,UAAW,CAAC,EAEtBjC,GAAQ,MAAQiC,KCvQhB,IAAAqB,GAAAC,EAAA,CAAAC,IAAAC,KAAA,CAAAA,GAAO,QAAU,OCAjB,IAAAC,GAAAC,EAAA,CAAAC,IAAAC,KAAA,CAAAA,GAAO,QAAU,CACf,OAAQ,OAAO,OAAO,EACtB,SAAU,OAAO,SAAS,EAC1B,UAAW,OAAO,UAAU,EAC5B,KAAM,OAAO,KAAK,EAClB,SAAULine truncated
|
||||
"names": ["require_tunnel", "__commonJSMin", "exports", "net", "tls", "http", "https", "events", "assert", "util", "httpOverHttp", "httpsOverHttp", "httpOverHttps", "httpsOverHttps", "options", "agent", "TunnelingAgent", "createSecureSocket", "self", "socket", "host", "port", "localAddress", "toOptions", "i", "len", "pending", "req", "mergeOptions", "onFree", "onCloseOrRemove", "err", "cb", "placeholder", "connectOptions", "debug", "connectReq", "onResponse", "onUpgrade", "onConnect", "onError", "res", "head", "error", "cause", "pos", "hostHeader", "tlsOptions", "secureSocket", "target", "overrides", "keys", "j", "keyLen", "k", "args", "require_tunnel", "__commonJSMin", "exports", "module", "require_symbols", "__commonJSMin", "exports", "module", "require_errors", "__commonJSMin", "exports", "module", "kUndiciError", "UndiciError", "message", "instance", "kConnectTimeoutError", "ConnectTimeoutError", "kHeadersTimeoutError", "HeadersTimeoutError", "kHeadersOverflowError", "HeadersOverflowError", "kBodyTimeoutError", "BodyTimeoutError", "kResponseStatusCodeError", "ResponseStatusCodeError", "statusCode", "headers", "body", "kInvalidArgumentError", "InvalidArgumentError", "kInvalidReturnValueError", "InvalidReturnValueError", "kAbortError", "AbortError", "kRequestAbortedError", "RequestAbortedError", "kInformationalError", "InformationalError", "kRequestContentLengthMismatchError", "RequestContentLengthMismatchError", "kResponseContentLengthMismatchError", "ResponseContentLengthMismatchError", "kClientDestroyedError", "ClientDestroyedError", "kClientClosedError", "ClientClosedError", "kSocketError", "SocketError", "socket", "kNotSupportedError", "NotSupportedError", "kBalancedPoolMissingUpstreamError", "BalancedPoolMissingUpstreamError", "kHTTPParserError", "HTTPParserError", "code", "data", "kResponseExceededMaxSizeError", "ResponseExceededMaxSizeError", "kRequestRetryError", "RequestRetryError", "kResponseError", "ResponseError", "kSecureProxyConnectionError", "SecureProxyConnectionError", "cause", "options", "kMessageSizeExceededError", "MessageSizeExceededError", "require_constants", "__commonJSMin", "exports", "module", "headerNameLowerCasedRecord", "wellknownHeaderNames", "i", "key", "lowerCasedKey", "require_tree", "__commonJSMin", "exports", "module", "wellknownHeaderNames", "headerNameLowerCasedRecord", "TstNode", "_TstNode", "key", "value", "index", "length", "node", "code", "keylength", "TernarySearchTree", "tree", "i", "require_util", "__commonJSMin", "exports", "module", "assert", "kDestroyed", "kBodyUsed", "kListeners", "kBody", "IncomingMessage", "stream", "net", "Blob", "nodeUtil", "stringify", "EE", "InvalidArgumentError", "headerNameLowerCasedRecord", "tree", "nodeMajor", "nodeMinor", "v", "BodyAsyncIterable", "body", "wrapRequestBody", "isStream", "bodyLength", "isIterable", "nop", "obj", "isBlobLike", "object", "sTag", "buildURL", "url", "queryParams", "stringified", "isValidPort", "port", "value", "isHttpOrHttpsPrefixed", "parseURL", "origin", "path", "parseOrigin", "getHostname", "host", "idx", "getServerName", "servername", "deepClone", "isAsyncIterable", "state", "isBuffer", "isDestroyed", "destroy", "err", "KEEPALIVE_TIMEOUT_EXPR", "parseKeepAliveTimeout", "val", "m", "headerNameToString", "bufferToLowerCasedHeaderName", "parseHeaders", "headers", "i", "key", "headersValue", "x", "parseRawHeaders", "len", "ret", "hasContentLength", "contentDispositionIdx", "kLen", "n", "buffer", "validateHandler", "handler", "method", "upgrade", "isDisturbed", "isErrored", "isReadable", "getSocketInfo", "socket", "ReadableStreamFrom", "iterable", "iterator", "controller", "done", "buf", "reason", "isFormDataLike", "addAbortListener", "signal", "listener", "hasToWellFormed", "hasIsWellFormed", "toUSVString", "isUSVString", "isTokenCharCode", "c", "isValidHTTPToken", "characters", "headerCharRegex", "isValidHeaderValue", "parseRangeHeader", "range", "addListener", "name", "removeAllListeners", "errorRequest", "client", "request", "kEnumerableProperty", "normalizedMethodRecordsBase", "normalizedMethodRecords", "require_diagnostics", "__commonJSMin", "exports", "module", "diagnosticsChannel", "util", "undiciDebugLog", "fetchDebuglog", "websocketDebuglog", "isClientSet", "channels", "debuglog", "evt", "version", "protocol", "port", "host", "error", "method", "path", "origin", "statusCode", "address", "websocket", "code", "reason", "err", "require_request", "__commonJSMin", "exports", "module", "InvalidArgumentError", "NotSupportedError", "assert", "isValidHTTPToken", "isValidHeaderValue", "isStream", "destroy", "isBuffer", "isFormDataLike", "isIterable", "isBlobLike", "buildURL", "validateHandler", "getServerName", "normalizedMethodRecords", "channels", "headerNameLowerCasedRecord", "invalidPathRegex", "kHandler", "Request", "origin", "path", "method", "body", "headers", "query", "idempotent", "blocking", "upgrade", "headersTimeout", "bodyTimeout", "reset", "throwOnError", "expectContinue", "servername",Line truncated
|
||||
"sources": ["../node_modules/tunnel/lib/tunnel.js", "../node_modules/tunnel/index.js", "../node_modules/undici/lib/core/symbols.js", "../node_modules/undici/lib/core/errors.js", "../node_modules/undici/lib/core/constants.js", "../node_modules/undici/lib/core/tree.js", "../node_modules/undici/lib/core/util.js", "../node_modules/undici/lib/core/diagnostics.js", "../node_modules/undici/lib/core/request.js", "../node_modules/undici/lib/dispatcher/dispatcher.js", "../node_modules/undici/lib/dispatcher/dispatcher-base.js", "../node_modules/undici/lib/util/timers.js", "../node_modules/undici/lib/core/connect.js", "../node_modules/undici/lib/llhttp/utils.js", "../node_modules/undici/lib/llhttp/constants.js", "../node_modules/undici/lib/llhttp/llhttp-wasm.js", "../node_modules/undici/lib/llhttp/llhttp_simd-wasm.js", "../node_modules/undici/lib/web/fetch/constants.js", "../node_modules/undici/lib/web/fetch/global.js", "../node_modules/undici/lib/web/fetch/data-url.js", "../node_modules/undici/lib/web/fetch/webidl.js", "../node_modules/undici/lib/web/fetch/util.js", "../node_modules/undici/lib/web/fetch/symbols.js", "../node_modules/undici/lib/web/fetch/file.js", "../node_modules/undici/lib/web/fetch/formdata.js", "../node_modules/undici/lib/web/fetch/formdata-parser.js", "../node_modules/undici/lib/web/fetch/body.js", "../node_modules/undici/lib/dispatcher/client-h1.js", "../node_modules/undici/lib/dispatcher/client-h2.js", "../node_modules/undici/lib/handler/redirect-handler.js", "../node_modules/undici/lib/interceptor/redirect-interceptor.js", "../node_modules/undici/lib/dispatcher/client.js", "../node_modules/undici/lib/dispatcher/fixed-queue.js", "../node_modules/undici/lib/dispatcher/pool-stats.js", "../node_modules/undici/lib/dispatcher/pool-base.js", "../node_modules/undici/lib/dispatcher/pool.js", "../node_modules/undici/lib/dispatcher/balanced-pool.js", "../node_modules/undici/lib/dispatcher/agent.js", "../node_modules/undici/lib/dispatcher/proxy-agent.js", "../node_modules/undici/lib/dispatcher/env-http-proxy-agent.js", "../node_modules/undici/lib/handler/retry-handler.js", "../node_modules/undici/lib/dispatcher/retry-agent.js", "../node_modules/undici/lib/api/readable.js", "../node_modules/undici/lib/api/util.js", "../node_modules/undici/lib/api/api-request.js", "../node_modules/undici/lib/api/abort-signal.js", "../node_modules/undici/lib/api/api-stream.js", "../node_modules/undici/lib/api/api-pipeline.js", "../node_modules/undici/lib/api/api-upgrade.js", "../node_modules/undici/lib/api/api-connect.js", "../node_modules/undici/lib/api/index.js", "../node_modules/undici/lib/mock/mock-errors.js", "../node_modules/undici/lib/mock/mock-symbols.js", "../node_modules/undici/lib/mock/mock-utils.js", "../node_modules/undici/lib/mock/mock-interceptor.js", "../node_modules/undici/lib/mock/mock-client.js", "../node_modules/undici/lib/mock/mock-pool.js", "../node_modules/undici/lib/mock/pluralizer.js", "../node_modules/undici/lib/mock/pending-interceptors-formatter.js", "../node_modules/undici/lib/mock/mock-agent.js", "../node_modules/undici/lib/global.js", "../node_modules/undici/lib/handler/decorator-handler.js", "../node_modules/undici/lib/interceptor/redirect.js", "../node_modules/undici/lib/interceptor/retry.js", "../node_modules/undici/lib/interceptor/dump.js", "../node_modules/undici/lib/interceptor/dns.js", "../node_modules/undici/lib/web/fetch/headers.js", "../node_modules/undici/lib/web/fetch/response.js", "../node_modules/undici/lib/web/fetch/dispatcher-weakref.js", "../node_modules/undici/lib/web/fetch/request.js", "../node_modules/undici/lib/web/fetch/index.js", "../node_modules/undici/lib/web/fileapi/symbols.js", "../node_modules/undici/lib/web/fileapi/progressevent.js", "../node_modules/undici/lib/web/fileapi/encoding.js", "../node_modules/undici/lib/web/fileapi/util.js", "../node_modules/undici/lib/web/fileapi/filereader.js", "../node_modules/undici/lib/web/cache/symbols.js", "../node_modules/undici/lib/web/cache/util.js", "../node_modules/undici/lib/web/cache/cache.js", "../node_modules/undici/lib/web/cache/cachestorage.js", "../node_modules/undici/lib/web/cookies/constants.js", "../node_modules/undici/lib/web/cookies/util.js", "../node_modules/undici/lib/web/cookies/parse.js", "../node_modules/undici/lib/web/cookies/index.js", "../node_modules/undici/lib/web/websocket/events.js", "../node_modules/undici/lib/web/websocket/constants.js", "../node_modules/undici/lib/web/websocket/symbols.js", "../node_modules/undici/lib/web/websocket/util.js", "../node_modules/undici/lib/web/websocket/frame.js", "../node_modules/undici/lib/web/websocket/connection.js", "../node_modules/undici/lib/web/websocket/permessage-deflate.js", "../node_modules/undici/lib/web/websocket/receiver.js", "../node_modules/undici/lib/web/websocket/sender.js", "../node_modules/undici/lib/web/websocket/websocket.js", "../node_modules/undici/lib/web/eventsource/util.js", "../node_modules/undici/lib/web/eventsource/eventsource-stream.js",Line truncated
|
||||
"sourcesContent": ["'use strict';\n\nvar net = require('net');\nvar tls = require('tls');\nvar http = require('http');\nvar https = require('https');\nvar events = require('events');\nvar assert = require('assert');\nvar util = require('util');\n\n\nexports.httpOverHttp = httpOverHttp;\nexports.httpsOverHttp = httpsOverHttp;\nexports.httpOverHttps = httpOverHttps;\nexports.httpsOverHttps = httpsOverHttps;\n\n\nfunction httpOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n return agent;\n}\n\nfunction httpsOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\nfunction httpOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n return agent;\n}\n\nfunction httpsOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\n\nfunction TunnelingAgent(options) {\n var self = this;\n self.options = options || {};\n self.proxyOptions = self.options.proxy || {};\n self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets;\n self.requests = [];\n self.sockets = [];\n\n self.on('free', function onFree(socket, host, port, localAddress) {\n var options = toOptions(host, port, localAddress);\n for (var i = 0, len = self.requests.length; i < len; ++i) {\n var pending = self.requests[i];\n if (pending.host === options.host && pending.port === options.port) {\n // Detect the request to connect same origin server,\n // reuse the connection.\n self.requests.splice(i, 1);\n pending.request.onSocket(socket);\n return;\n }\n }\n socket.destroy();\n self.removeSocket(socket);\n });\n}\nutil.inherits(TunnelingAgent, events.EventEmitter);\n\nTunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) {\n var self = this;\n var options = mergeOptions({request: req}, self.options, toOptions(host, port, localAddress));\n\n if (self.sockets.length >= this.maxSockets) {\n // We are over limit so we'll add it to the queue.\n self.requests.push(options);\n return;\n }\n\n // If we are under maxSockets create a new one.\n self.createSocket(options, function(socket) {\n socket.on('free', onFree);\n socket.on('close', onCloseOrRemove);\n socket.on('agentRemove', onCloseOrRemove);\n req.onSocket(socket);\n\n function onFree() {\n self.emit('free', socket, options);\n }\n\n function onCloseOrRemove(err) {\n self.removeSocket(socket);\n socket.removeListener('free', onFree);\n socket.removeListener('close', onCloseOrRemove);\n socket.removeListener('agentRemove', onCloseOrRemove);\n }\n });\n};\n\nTunnelingAgent.prototype.createSocket = function createSocket(options, cb) {\n var self = this;\n var placeholder = {};\n self.sockets.push(placeholder);\n\n var connectOptions = mergeOptions({}, self.proxyOptions, {\n method: 'CONNECT',\n path: options.host + ':' + options.port,\n agent: false,\n headers: {\n host: options.host + ':' + options.port\n }\n });\n if (options.localAddress) {\n connectOptions.localAddress = options.localAddress;\n }\n if (connectOptions.proxyAuth) {\n connectOptions.headers = connectOptions.headers || {};\n connectOptions.headers['Proxy-Authorization'] = 'Basic ' +\n new Buffer(connectOptions.proxyAuth).toString('base64');\n }\n\n debug('making CONNECT request');\n var connectReq = self.request(connectOptions);\n connectReq.useChunkedEncodingByDefault = false; // for v0.6\n connectReq.once('response', onResponse); // for v0.6\n connectReq.once('upgrade', onUpgrade); // for v0.6\n connectReq.once('connect', onConnect); // for v0.7 or later\n connectReq.once('error', onError);\n connectReq.end();\n\n function onResponse(res) {\n // Very hacky. This is necessary to avoid http-parser leaks.\n res.upgrade = true;\n }\n\n function onUpgrade(res, socket, head) {\n // Hacky.\n process.nextTick(function() {\n onConnect(res, socket, head);\n });\n }\n\n function onConnect(res, socket, head) {\n connectReq.removeAllListeners();\n socket.removeAllListeners();\n\n if (res.statusCode !== 200) {\n debug('tunneling socket could not be established, statusCode=%d',\n res.statusCode);\n socket.destroy();\n var error = new Error('tunneling socket could not be established, ' +\n 'statusCode=' + res.statusCode);\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n return;\n }\n if (head.length > 0) {\n debug('got illegal response body from proxy');\n socket.destroy();\n var error = new Error('Line truncated
|
||||
"mappings": "glBAAA,IAAAA,GAAAC,EAAAC,IAAA,cAEA,IAAIC,IAAM,QAAQ,KAAK,EACnBC,GAAM,QAAQ,KAAK,EACnBC,GAAO,QAAQ,MAAM,EACrBC,GAAQ,QAAQ,OAAO,EACvBC,GAAS,QAAQ,QAAQ,EACzBC,IAAS,QAAQ,QAAQ,EACzBC,GAAO,QAAQ,MAAM,EAGzBP,GAAQ,aAAeQ,GACvBR,GAAQ,cAAgBS,GACxBT,GAAQ,cAAgBU,GACxBV,GAAQ,eAAiBW,GAGzB,SAASH,GAAaI,EAAS,CAC7B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUV,GAAK,QACdU,CACT,CAEA,SAASJ,GAAcG,EAAS,CAC9B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUV,GAAK,QACrBU,EAAM,aAAeE,GACrBF,EAAM,YAAc,IACbA,CACT,CAEA,SAASH,GAAcE,EAAS,CAC9B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUT,GAAM,QACfS,CACT,CAEA,SAASF,GAAeC,EAAS,CAC/B,IAAIC,EAAQ,IAAIC,GAAeF,CAAO,EACtC,OAAAC,EAAM,QAAUT,GAAM,QACtBS,EAAM,aAAeE,GACrBF,EAAM,YAAc,IACbA,CACT,CAGA,SAASC,GAAeF,EAAS,CAC/B,IAAII,EAAO,KACXA,EAAK,QAAUJ,GAAW,CAAC,EAC3BI,EAAK,aAAeA,EAAK,QAAQ,OAAS,CAAC,EAC3CA,EAAK,WAAaA,EAAK,QAAQ,YAAcb,GAAK,MAAM,kBACxDa,EAAK,SAAW,CAAC,EACjBA,EAAK,QAAU,CAAC,EAEhBA,EAAK,GAAG,OAAQ,SAAgBC,EAAQC,EAAMC,EAAMC,EAAc,CAEhE,QADIR,EAAUS,GAAUH,EAAMC,EAAMC,CAAY,EACvCE,EAAI,EAAGC,EAAMP,EAAK,SAAS,OAAQM,EAAIC,EAAK,EAAED,EAAG,CACxD,IAAIE,EAAUR,EAAK,SAASM,CAAC,EAC7B,GAAIE,EAAQ,OAASZ,EAAQ,MAAQY,EAAQ,OAASZ,EAAQ,KAAM,CAGlEI,EAAK,SAAS,OAAOM,EAAG,CAAC,EACzBE,EAAQ,QAAQ,SAASP,CAAM,EAC/B,MACF,CACF,CACAA,EAAO,QAAQ,EACfD,EAAK,aAAaC,CAAM,CAC1B,CAAC,CACH,CACAV,GAAK,SAASO,GAAgBT,GAAO,YAAY,EAEjDS,GAAe,UAAU,WAAa,SAAoBW,EAAKP,EAAMC,EAAMC,EAAc,CACvF,IAAIJ,EAAO,KACPJ,EAAUc,GAAa,CAAC,QAASD,CAAG,EAAGT,EAAK,QAASK,GAAUH,EAAMC,EAAMC,CAAY,CAAC,EAE5F,GAAIJ,EAAK,QAAQ,QAAU,KAAK,WAAY,CAE1CA,EAAK,SAAS,KAAKJ,CAAO,EAC1B,MACF,CAGAI,EAAK,aAAaJ,EAAS,SAASK,EAAQ,CAC1CA,EAAO,GAAG,OAAQU,CAAM,EACxBV,EAAO,GAAG,QAASW,CAAe,EAClCX,EAAO,GAAG,cAAeW,CAAe,EACxCH,EAAI,SAASR,CAAM,EAEnB,SAASU,GAAS,CAChBX,EAAK,KAAK,OAAQC,EAAQL,CAAO,CACnC,CAEA,SAASgB,EAAgBC,EAAK,CAC5Bb,EAAK,aAAaC,CAAM,EACxBA,EAAO,eAAe,OAAQU,CAAM,EACpCV,EAAO,eAAe,QAASW,CAAe,EAC9CX,EAAO,eAAe,cAAeW,CAAe,CACtD,CACF,CAAC,CACH,EAEAd,GAAe,UAAU,aAAe,SAAsBF,EAASkB,EAAI,CACzE,IAAId,EAAO,KACPe,EAAc,CAAC,EACnBf,EAAK,QAAQ,KAAKe,CAAW,EAE7B,IAAIC,EAAiBN,GAAa,CAAC,EAAGV,EAAK,aAAc,CACvD,OAAQ,UACR,KAAMJ,EAAQ,KAAO,IAAMA,EAAQ,KACnC,MAAO,GACP,QAAS,CACP,KAAMA,EAAQ,KAAO,IAAMA,EAAQ,IACrC,CACF,CAAC,EACGA,EAAQ,eACVoB,EAAe,aAAepB,EAAQ,cAEpCoB,EAAe,YACjBA,EAAe,QAAUA,EAAe,SAAW,CAAC,EACpDA,EAAe,QAAQ,qBAAqB,EAAI,SAC5C,IAAI,OAAOA,EAAe,SAAS,EAAE,SAAS,QAAQ,GAG5DC,GAAM,wBAAwB,EAC9B,IAAIC,EAAalB,EAAK,QAAQgB,CAAc,EAC5CE,EAAW,4BAA8B,GACzCA,EAAW,KAAK,WAAYC,CAAU,EACtCD,EAAW,KAAK,UAAWE,CAAS,EACpCF,EAAW,KAAK,UAAWG,CAAS,EACpCH,EAAW,KAAK,QAASI,CAAO,EAChCJ,EAAW,IAAI,EAEf,SAASC,EAAWI,EAAK,CAEvBA,EAAI,QAAU,EAChB,CAEA,SAASH,EAAUG,EAAKtB,EAAQuB,EAAM,CAEpC,QAAQ,SAAS,UAAW,CAC1BH,EAAUE,EAAKtB,EAAQuB,CAAI,CAC7B,CAAC,CACH,CAEA,SAASH,EAAUE,EAAKtB,EAAQuB,EAAM,CAIpC,GAHAN,EAAW,mBAAmB,EAC9BjB,EAAO,mBAAmB,EAEtBsB,EAAI,aAAe,IAAK,CAC1BN,GAAM,2DACJM,EAAI,UAAU,EAChBtB,EAAO,QAAQ,EACf,IAAIwB,EAAQ,IAAI,MAAM,yDACJF,EAAI,UAAU,EAChCE,EAAM,KAAO,aACb7B,EAAQ,QAAQ,KAAK,QAAS6B,CAAK,EACnCzB,EAAK,aAAae,CAAW,EAC7B,MACF,CACA,GAAIS,EAAK,OAAS,EAAG,CACnBP,GAAM,sCAAsC,EAC5ChB,EAAO,QAAQ,EACf,IAAIwB,EAAQ,IAAI,MAAM,sCAAsC,EAC5DA,EAAM,KAAO,aACb7B,EAAQ,QAAQ,KAAK,QAAS6B,CAAK,EACnCzB,EAAK,aAAae,CAAW,EAC7B,MACF,CACA,OAAAE,GAAM,sCAAsC,EAC5CjB,EAAK,QAAQA,EAAK,QAAQ,QAAQe,CAAW,CAAC,EAAId,EAC3Ca,EAAGb,CAAM,CAClB,CAEA,SAASqB,EAAQI,EAAO,CACtBR,EAAW,mBAAmB,EAE9BD,GAAM;AAAA,EACAS,EAAM,QAASA,EAAM,KAAK,EAChC,IAAID,EAAQ,IAAI,MAAM,oDACWC,EAAM,OAAO,EAC9CD,EAAM,KAAO,aACb7B,EAAQ,QAAQ,KAAK,QAAS6B,CAAK,EACnCzB,EAAK,aAAae,CAAW,CAC/B,CACF,EAEAjB,GAAe,UAAU,aAAe,SAAsBG,EAAQ,CACpE,IAAI0B,EAAM,KAAK,QAAQ,QAAQ1B,CAAM,EACrC,GAAI0B,IAAQ,GAGZ,MAAK,QAAQ,OAAOA,EAAK,CAAC,EAE1B,IAAInB,EAAU,KAAK,SAAS,MAAM,EAC9BA,GAGF,KAAK,aAAaA,EAAS,SAASP,EAAQ,CAC1CO,EAAQ,QAAQ,SAASP,CAAM,CACjC,CAAC,EAEL,EAEA,SAASF,GAAmBH,EAASkB,EAAI,CACvC,IAAId,EAAO,KACXF,GAAe,UAAU,aAAa,KAAKE,EAAMJ,EAAS,SAASK,EAAQ,CACzE,IAAI2B,EAAahC,EAAQ,QAAQ,UAAU,MAAM,EAC7CiC,EAAanB,GAAa,CAAC,EAAGV,EAAK,QAAS,CAC9C,OAAQC,EACR,WAAY2B,EAAaA,EAAW,QAAQ,OAAQ,EAAE,EAAIhC,EAAQ,IACpE,CAAC,EAGGkC,EAAe5C,GAAI,QAAQ,EAAG2C,CAAU,EAC5C7B,EAAK,QAAQA,EAAK,QAAQ,QAAQC,CAAM,CAAC,EAAI6B,EAC7ChB,EAAGgB,CAAY,CACjB,CAAC,CACH,CAGA,SAASzB,GAAUH,EAAMC,EAAMC,EAAc,CAC3C,OAAI,OAAOF,GAAS,SACX,CACL,KAAMA,EACN,KAAMC,EACN,aAAcC,CAChB,EAEKF,CACT,CAEA,SAASQ,GAAaqB,EAAQ,CAC5B,QAASzB,EAAI,EAAGC,EAAM,UAAU,OAAQD,EAAIC,EAAK,EAAED,EAAG,CACpD,IAAI0B,EAAY,UAAU1B,CAAC,EAC3B,GAAI,OAAO0B,GAAc,SAEvB,QADIC,EAAO,OAAO,KAAKD,CAAS,EACvBE,EAAI,EAAGC,EAASF,EAAK,OAAQC,EAAIC,EAAQ,EAAED,EAAG,CACrD,IAAIE,EAAIH,EAAKC,CAAC,EACVF,EAAUI,CAAC,IAAM,SACnBL,EAAOK,CAAC,EAAIJ,EAAUI,CAAC,EAE3B,CAEJ,CACA,OAAOL,CACT,CAGA,IAAId,GACA,QAAQ,IAAI,YAAc,aAAa,KAAK,QAAQ,IAAI,UAAU,EACpEA,GAAQ,UAAW,CACjB,IAAIoB,EAAO,MAAM,UAAU,MAAM,KAAK,SAAS,EAC3C,OAAOA,EAAK,CAAC,GAAM,SACrBA,EAAK,CAAC,EAAI,WAAaA,EAAK,CAAC,EAE7BA,EAAK,QAAQ,SAAS,EAExB,QAAQ,MAAM,MAAM,QAASA,CAAI,CACnC,EAEApB,GAAQ,UAAW,CAAC,EAEtBjC,GAAQ,MAAQiC,KCvQhB,IAAAqB,GAAAC,EAAA,CAAAC,IAAAC,KAAA,CAAAA,GAAO,QAAU,OCAjB,IAAAC,GAAAC,EAAA,CAAAC,IAAAC,KAAA,CAAAA,GAAO,QAAU,CACf,OAAQ,OAAO,OAAO,EACtB,SAAU,OAAO,SAAS,EAC1B,UAAW,OAAO,UAAU,EAC5B,KAAM,OAAO,KAAK,EAClB,SAAULine truncated
|
||||
"names": ["require_tunnel", "__commonJSMin", "exports", "net", "tls", "http", "https", "events", "assert", "util", "httpOverHttp", "httpsOverHttp", "httpOverHttps", "httpsOverHttps", "options", "agent", "TunnelingAgent", "createSecureSocket", "self", "socket", "host", "port", "localAddress", "toOptions", "i", "len", "pending", "req", "mergeOptions", "onFree", "onCloseOrRemove", "err", "cb", "placeholder", "connectOptions", "debug", "connectReq", "onResponse", "onUpgrade", "onConnect", "onError", "res", "head", "error", "cause", "pos", "hostHeader", "tlsOptions", "secureSocket", "target", "overrides", "keys", "j", "keyLen", "k", "args", "require_tunnel", "__commonJSMin", "exports", "module", "require_symbols", "__commonJSMin", "exports", "module", "require_errors", "__commonJSMin", "exports", "module", "kUndiciError", "UndiciError", "message", "instance", "kConnectTimeoutError", "ConnectTimeoutError", "kHeadersTimeoutError", "HeadersTimeoutError", "kHeadersOverflowError", "HeadersOverflowError", "kBodyTimeoutError", "BodyTimeoutError", "kResponseStatusCodeError", "ResponseStatusCodeError", "statusCode", "headers", "body", "kInvalidArgumentError", "InvalidArgumentError", "kInvalidReturnValueError", "InvalidReturnValueError", "kAbortError", "AbortError", "kRequestAbortedError", "RequestAbortedError", "kInformationalError", "InformationalError", "kRequestContentLengthMismatchError", "RequestContentLengthMismatchError", "kResponseContentLengthMismatchError", "ResponseContentLengthMismatchError", "kClientDestroyedError", "ClientDestroyedError", "kClientClosedError", "ClientClosedError", "kSocketError", "SocketError", "socket", "kNotSupportedError", "NotSupportedError", "kBalancedPoolMissingUpstreamError", "BalancedPoolMissingUpstreamError", "kHTTPParserError", "HTTPParserError", "code", "data", "kResponseExceededMaxSizeError", "ResponseExceededMaxSizeError", "kRequestRetryError", "RequestRetryError", "kResponseError", "ResponseError", "kSecureProxyConnectionError", "SecureProxyConnectionError", "cause", "options", "kMessageSizeExceededError", "MessageSizeExceededError", "require_constants", "__commonJSMin", "exports", "module", "headerNameLowerCasedRecord", "wellknownHeaderNames", "i", "key", "lowerCasedKey", "require_tree", "__commonJSMin", "exports", "module", "wellknownHeaderNames", "headerNameLowerCasedRecord", "TstNode", "_TstNode", "key", "value", "index", "length", "node", "code", "keylength", "TernarySearchTree", "tree", "i", "require_util", "__commonJSMin", "exports", "module", "assert", "kDestroyed", "kBodyUsed", "kListeners", "kBody", "IncomingMessage", "stream", "net", "Blob", "nodeUtil", "stringify", "EE", "InvalidArgumentError", "headerNameLowerCasedRecord", "tree", "nodeMajor", "nodeMinor", "v", "BodyAsyncIterable", "body", "wrapRequestBody", "isStream", "bodyLength", "isIterable", "nop", "obj", "isBlobLike", "object", "sTag", "buildURL", "url", "queryParams", "stringified", "isValidPort", "port", "value", "isHttpOrHttpsPrefixed", "parseURL", "origin", "path", "parseOrigin", "getHostname", "host", "idx", "getServerName", "servername", "deepClone", "isAsyncIterable", "state", "isBuffer", "isDestroyed", "destroy", "err", "KEEPALIVE_TIMEOUT_EXPR", "parseKeepAliveTimeout", "val", "m", "headerNameToString", "bufferToLowerCasedHeaderName", "parseHeaders", "headers", "i", "key", "headersValue", "x", "parseRawHeaders", "len", "ret", "hasContentLength", "contentDispositionIdx", "kLen", "n", "buffer", "validateHandler", "handler", "method", "upgrade", "isDisturbed", "isErrored", "isReadable", "getSocketInfo", "socket", "ReadableStreamFrom", "iterable", "iterator", "controller", "done", "buf", "reason", "isFormDataLike", "addAbortListener", "signal", "listener", "hasToWellFormed", "hasIsWellFormed", "toUSVString", "isUSVString", "isTokenCharCode", "c", "isValidHTTPToken", "characters", "headerCharRegex", "isValidHeaderValue", "parseRangeHeader", "range", "addListener", "name", "removeAllListeners", "errorRequest", "client", "request", "kEnumerableProperty", "normalizedMethodRecordsBase", "normalizedMethodRecords", "require_diagnostics", "__commonJSMin", "exports", "module", "diagnosticsChannel", "util", "undiciDebugLog", "fetchDebuglog", "websocketDebuglog", "isClientSet", "channels", "debuglog", "evt", "version", "protocol", "port", "host", "error", "method", "path", "origin", "statusCode", "address", "websocket", "code", "reason", "err", "require_request", "__commonJSMin", "exports", "module", "InvalidArgumentError", "NotSupportedError", "assert", "isValidHTTPToken", "isValidHeaderValue", "isStream", "destroy", "isBuffer", "isFormDataLike", "isIterable", "isBlobLike", "buildURL", "validateHandler", "getServerName", "normalizedMethodRecords", "channels", "headerNameLowerCasedRecord", "invalidPathRegex", "kHandler", "Request", "origin", "path", "method", "body", "headers", "query", "idempotent", "blocking", "upgrade", "headersTimeout", "bodyTimeout", "reset", "throwOnError", "expectContinue", "servername",Line truncated
|
||||
}
|
||||
Reference in new issue
Block a user