var$ue=Object.create;varLE=Object.defineProperty;varYue=Object.getOwnPropertyDescriptor;varWue=Object.getOwnPropertyNames;varjue=Object.getPrototypeOf,Kue=Object.prototype.hasOwnProperty;varo=(t,e)=>LE(t,"name",{value:e,configurable:!0});varm=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Xue=(t,e)=>{for(varrine)LE(t,r,{get:e[r],enumerable:!0})},Zue=(t,e,r,n)=>{if(e&&typeofe=="object"||typeofe=="function")for(letsofWue(e))!Kue.call(t,s)&&s!==r&&LE(t,s,{get:()=>e[s],enumerable:!(n=Yue(e,s))||n.enumerable});returnt};varw=(t,e,r)=>(r=t!=null?$ue(jue(t)):{},Zue(e||!t||!t.__esModule?LE(r,"default",{value:t,enumerable:!0}):r,t));varLG=m(Cd=>{"use strict";varq6e=require("net"),tpe=require("tls"),Tx=require("http"),DG=require("https"),rpe=require("events"),G6e=require("assert"),npe=require("util");Cd.httpOverHttp=spe;Cd.httpsOverHttp=ipe;Cd.httpOverHttps=ope;Cd.httpsOverHttps=ape;functionspe(t){vare=newsa(t);returne.request=Tx.request,e}o(spe,"httpOverHttp");functionipe(t){vare=newsa(t);returne.request=Tx.request,e.createSocket=OG,e.defaultPort=443,e}o(ipe,"httpsOverHttp");functionope(t){vare=newsa(t);returne.request=DG.request,e}o(ope,"httpOverHttps");functionape(t){vare=newsa(t);returne.request=DG.request,e.createSocket=OG,e.defaultPort=443,e}o(ape,"httpsOverHttps");functionsa(t){vare=this;e.options=t||{},e.proxyOptions=e.options.proxy||{},e.maxSockets=e.options.maxSockets||Tx.Agent.defaultMaxSockets,e.requests=[],e.sockets=[],e.on("free",o(function(n,s,i,a){for(varc=MG(s,i,a),l=0,u=e.requests.length;l<u;++l){vard=e.requests[l];if(d.host===c.host&&d.port===c.port){e.requests.splice(l,1),d.request.onSocket(n);return}}n.destroy(),e.removeSocket(n)},"onFree"))}o(sa,"TunnelingAgent");npe.inherits(sa,rpe.EventEmitter);sa.prototype.addRequest=o(function(e,r,n,s){vari=this,a=vx({request:e},i.options,MG(r,n,s));if(i.sockets.length>=this.maxSockets){i.requests.push(a);return}i.createSocket(a,function(c){c.on("free",l),c.on("close",u),c.on("agentRemove",u),e.onSocket(c);functionl(){i.emit("free",c,a)}o(l,"onFree");functionu(d){i.removeSocket(c),c.removeListener("free",l),c.removeListener("close",u),c.removeListener("agentRemove",u)}o(u,"onCloseOrRemove")})},"addRequest");sa.prototype.createSocket=o(function(e,r){varn=this,s={};n.sockets.push(s);vari=vx({},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 "+newBuffer(i.proxyAuth).toString("base64")),ic("making CONNECT request");vara=n.request(i);a.useChunkedEncodingByDefault=!1,a.once("response",c),a.once("upgrade",l),a.once("connect",u),a.once("error",d),a.end();functionc(A){A.upgrade=!0}o(c,"onResponse");functionl(A,p,f){process.nextTick(function(){u(A,p,f)})}o(l,"onUpgrade");functionu(A,p,f){if(a.removeAllListeners(),p.removeAllListeners(),A.statusCode!==200){ic("tunneling socket could not be established, statusCode=%d",A.statusCode),p.destroy();varh=newError("tunneling socket could not be established, statusCode="+A.statusCode);h.code="ECONNRESET",e.request.emit("error",h),n.removeSocket(s);return}if(f.length>0){ic("got illegal response body from proxy"),p.destroy();varh=newError("got illegal response body from proxy");h.code="ECONNRESET",e.request.emit("error",h),n.removeSocket(s);return}returnic("tunneling connection has established"),n.sockets[n.sockets.indexOf(s)]=p,r(p)}o(u,"onConnect");functiond(A){a.removeAllListeners(),ic(`tunneling socket could not be established, cause=%s
`);p.push(g),i+=g.byteLength,h&&(i=null),s=t,n=o(async function*(){for(let y of p)y.stream?yield*y.stream():yield y},"action"),a=`multipart/form-data; boundary=${l}`}else if(zV(t))s=t,i=t.size,t.type&&(a=t.type);else if(typeof t[Symbol.asyncIterator]=="function"){if(e)throw new TypeError("keepalive");if(Jf.isDisturbed(t)||t.locked)throw new TypeError("Response body object should not be disturbed or locked");r=t instanceof ReadableStream?t:Sme(t)}if((typeof s=="string"||Jf.isBuffer(s))&&(i=Buffer.byteLength(s)),n!=null){let l;r=new ReadableStream({async start(){l=n(t)[Symbol.asyncIterator]()},async pull(u){let{value:d,done:A}=await l.next();if(A)queueMicrotask(()=>{u.close(),u.byobRequest?.respond(0)});else if(!WV(r)){let p=new Uint8Array(d);p.byteLength&&u.enqueue(p)}return u.desiredSize>0},async cancel(u){await l.return()},type:"bytes"})}return[{stream:r,source:s,length:i},a]}o(XV,"extractBody");function Lme(t,e=!1){return t instanceof ReadableStream&&(DQ(!Jf.isDisturbed(t),"The body has already been consumed."),DQ(!t.locked,"The stream is locked.")),XV(t,e)}o(Lme,"safelyExtractBody");function Fme(t,e){let[r,n]=e.stream.tee();return e.stream=r,{stream:n,length:e.length,source:e.source}}o(Fme,"cloneBody");function Ume(t){if(t.aborted)throw new DOMException("The operation was aborted.","AbortError")}o(Ume,"throwIfAborted");function qme(t){return{blob(){return _d(this,r=>{let n=$V(this);return n===null?n="":n&&(n=Dme(n)),new Pme([r],{type:n})},t)},arrayBuffer(){return _d(this,r=>new Uint8Array(r).buffer,t)},text(){return _d(this,YV,t)},json(){return _d(this,Hme,t)},formData(){return _d(this,r=>{let n=$V(this);if(n!==null)switch(n.essence){case"multipart/form-data":{let s=Ome(r,n);if(s==="failure")throw new TypeError("Failed to parse body as FormData.");let i=new JV;return i[kd]=s,i}case"application/x-www-form-urlencoded":{let s=new URLSearchParams(r.toString()),i=new JV;for(let[a,c]of s)i.append(a,c);return i}}throw new TypeError('Content-Typewasnotoneof"multipart/form-data"or"application/x-www-form-urlencoded".')},t)},bytes(){return _d(this,r=>new Uint8Array(r),t)}}}o(qme,"bodyMixinMethods");function Gme(t){Object.assign(t.prototype,qme(t))}o(Gme,"mixinBody");async function _d(t,e,r){if(vme.brandCheck(t,r),ZV(t))throw new TypeError("Body is unusable: Body has already been read");Ume(t[kd]);let n=Qme(),s=o(a=>n.reject(a),"errorSteps"),i=o(a=>{try{n.resolve(e(a))}catch(c){s(c)}},"successSteps");return t[kd].body==null?(i(Buffer.allocUnsafe(0)),n.promise):(await Rme(t[kd].body,i,s),n.promise)}o(_d,"consumeBody");function ZV(t){let e=t[kd].body;return e!=null&&(e.stream.locked||Jf.isDisturbed(e.stream))}o(ZV,"bodyUnusable");function Hme(t){return JSON.parse(YV(t))}o(Hme,"parseJSONFromBytes");function $V(t){let e=t[kd].headersList,r=Tme(e);return r==="failure"?null:r}o($V,"bodyMimeType");ez.exports={extractBody:XV,safelyExtractBody:Lme,cloneBody:Fme,mixinBody:Gme,streamRegistry:KV,hasFinalizationRegistry:jV,bodyUnusable:ZV}});var mz=m((DKe,hz)=>{"use strict";var X=require("node:assert"),te=Ie(),{channels:tz}=Bd(),MQ=EQ(),{RequestContentLengthMismatchError:Ql,ResponseContentLengthMismatchError:rz,RequestAbortedError:uz,InvalidArgumentError:Vme,HeadersTimeoutError:zme,HeadersOverflowError:Jme,SocketError:Od,InformationalError:Md,BodyTimeoutError:$me,HTTPParserError:Yme,ResponseExceededMaxSizeError:Wme}=ve(),{kUrl:dz,kReset:fn,kClient:by,kParser:nt,kBlocking:Wf,kRunning:zt,kPending:Az,kSize:nz,kWriting:ac,kQueue:oi,kNoRef:$f,kKeepAliveDefaultTimeout:jme,kHostHeader:Kme,kPendingIdx:Xme,kRunningIdx:ys,kError:Jr,kPipelining:wy,kSocket:Tl,kKeepAliveTimeoutValue:Ny,kMaxHeadersSize:LQ,kKeepAliveMaxTimeout:Zme,kKeepAliveTimeoutThreshold:ege,kHeadersTimeout:tge,kBodyTimeout:rge,kStrictContentLength:qQ,kMaxRequests:sz,kCounter:nge,kMaxResponseSize:sge,kOnError:iz,kResume:ua,kHTTPContext:pz}=dt(),Gn=KH(),oz=Buffer.alloc(0),Cy=Buffer[Symbol.species],Iy=te.addListener,ige=te.removeAllListeners,vl=Symbol("kIdleSocketValidation"),Rl=Symbol("kIdleSocketValidationTimeout"),zQ=Symbol("kSocketUsed"),FQ;async function oge(){let t=process.en
`}return tz.sendHeaders.hasSubscribers&&tz.sendHeaders.publish({request:e,headers:g,socket:f}),!l||p===0?cz(h,null,t,e,f,d,g,A):te.isBuffer(l)?cz(h,l,t,e,f,d,g,A):te.isBlobLike(l)?typeof l.stream=="function"?lz(h,l.stream(),t,e,f,d,g,A):fge(h,l,t,e,f,d,g,A):te.isStream(l)?pge(h,l,t,e,f,d,g,A):te.isIterable(l)?lz(h,l,t,e,f,d,g,A):X(!1),!0}o(Age,"writeH1");function pge(t,e,r,n,s,i,a,c){X(i!==0||r[zt]===0,"stream body cannot be pipelined");let l=!1,u=new xy({abort:t,socket:s,request:n,contentLength:i,client:r,expectsPayload:c,header:a}),d=o(function(h){if(!l)try{!u.write(h)&&this.pause&&this.pause()}catch(g){te.destroy(this,g)}},"onData"),A=o(function(){l||e.resume&&e.resume()},"onDrain"),p=o(function(){if(queueMicrotask(()=>{e.removeListener("error",f)}),!l){let h=new uz;queueMicrotask(()=>f(h))}},"onClose"),f=o(function(h){if(!l){if(l=!0,X(s.destroyed||s[ac]&&r[zt]<=1),s.off("drain",A).off("error",f),e.removeListener("data",d).removeListener("end",f).removeListener("close",p),!h)try{u.end()}catch(g){h=g}u.destroy(h),h&&(h.code!=="UND_ERR_INFO"||h.message!=="reset")?te.destroy(e,h):te.destroy(e)}},"onFinished");e.on("data",d).on("end",f).on("error",f).on("close",p),e.resume&&e.resume(),s.on("drain",A).on("error",f),e.errorEmitted??e.errored?setImmediate(()=>f(e.errored)):(e.endEmitted??e.readableEnded)&&setImmediate(()=>f(null)),(e.closeEmitted??e.closed)&&setImmediate(p)}o(pge,"writeStream");function cz(t,e,r,n,s,i,a,c){try{e?te.isBuffer(e)&&(X(i===e.byteLength,"buffer body must have content length"),s.cork(),s.write(`${a}content-length: ${i}\r
`,"latin1")),n.onRequestSent(),r[ua]()}catch(l){t(l)}}o(cz,"writeBuffer");async function fge(t,e,r,n,s,i,a,c){X(i===e.size,"blob body must have content length");try{if(i!=null&&i!==e.size)throw new Ql;let l=Buffer.from(await e.arrayBuffer());s.cork(),s.write(`${a}content-length: ${i}\r
`,"latin1"),s.write(l),s.uncork(),n.onBodySent(l),n.onRequestSent(),!c&&n.reset!==!1&&(s[fn]=!0),r[ua]()}catch(l){t(l)}}o(fge,"writeBlob");async function lz(t,e,r,n,s,i,a,c){X(i!==0||r[zt]===0,"iterator body cannot be pipelined");let l=null;function u(){if(l){let p=l;l=null,p()}}o(u,"onDrain");let d=o(()=>new Promise((p,f)=>{X(l===null),s[Jr]?f(s[Jr]):l=p}),"waitForDrain");s.on("close",u).on("drain",u);let A=new xy({abort:t,socket:s,request:n,contentLength:i,client:r,expectsPayload:c,header:a});try{for await(let p of e){if(s[Jr])throw s[Jr];A.write(p)||await d()}A.end()}catch(p){A.destroy(p)}finally{s.off("close",u).off("drain",u)}}o(lz,"writeIterable");var xy=class{static{o(this,"AsyncWriter")}constructor({abort:e,socket:r,request:n,contentLength:s,client:i,expectsPayload:a,header:c}){this.socket=r,this.request=n,this.contentLength=s,this.client=i,this.bytesWritten=0,this.expectsPayload=a,this.header=c,this.abort=e,r[ac]=!0}write(e){let{socket:r,request:n,contentLength:s,client:i,bytesWritten:a,expectsPayload:c,header:l}=this;if(r[Jr])throw r[Jr];if(r.destroyed)return!1;let u=Buffer.byteLength(e);if(!u)return!0;if(s!==null&&a+u>s){if(i[qQ])throw new Ql;process.emitWarning(new Ql)}r.cork(),a===0&&(!c&&n.reset!==!1&&(r[fn]=!0),s===null?r.write(`${l}transfer-encoding: chunked\r
`,"latin1"),r!==null&&s!==r){if(n[qQ])throw new Ql;process.emitWarning(new Ql)}e[nt].timeout&&e[nt].timeoutType===Ld&&e[nt].timeout.refresh&&e[nt].timeout.refresh(),n[ua]()}}destroy(e){let{socket:r,client:n,abort:s}=this;r[ac]=!1,e&&(X(n[zt]<=1,"pipeline should only contain this request"),s(e))}};hz.exports=cge});var wz=m((MKe,bz)=>{"use strict";var Cs=require("node:assert"),{pipeline:hge}=require("node:stream"),we=Ie(),{RequestContentLengthMismatchError:JQ,RequestAbortedError:gz,SocketError:jf,InformationalError:$Q}=ve(),{kUrl:Qy,kReset:Ty,kClient:Fd,kRunning:vy,kPending:mge,kQueue:cc,kPendingIdx:YQ,kRunningIdx:ai,kError:li,kSocket:ur,kStrictContentLength:gge,kOnError:WQ,kMaxConcurrentStreams:Bz,kHTTP2Session:ci,kResume:lc,kSize:Ege,kHTTPContext:yge}=dt(),da=Symbol("open streams"),Ez,yz=!1,Ry;try{Ry=require("node:http2")}catch{Ry={constants:{}}}var{constants:{HTTP2_HEADER_AUTHORITY:Cge,HTTP2_HEADER_METHOD:Ige,HTTP2_HEADER_PATH:Bge,HTTP2_HEADER_SCHEME:bge,HTTP2_HEADER_CONTENT_LENGTH:wge,HTTP2_HEADER_EXPECT:Sge,HTTP2_HEADER_STATUS:Nge}}=Ry;function xge(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}o(xge,"parseH2Headers");async function Qge(t,e){t[ur]=e,yz||(yz=!0,process.emitWarning("H2 support is experimental, expect them to change at any time.",{code:"UNDICI-H2"}));let r=Ry.connect(t[Qy],{createConnection:o(()=>e,"createConnection"),peerMaxConcurrentStreams:t[Bz]});r[da]=0,r[Fd]=t,r[ur]=e,we.addListener(r,"error",Tge),we.addListener(r,"frameError",vge),we.addListener(r,"end",Pge),we.addListener(r,"goaway",_ge),we.addListener(r,"close",function(){let{[Fd]:s}=this,{[ur]:i}=s,a=this[ur][li]||this[li]||new jf("closed",we.getSocketInfo(i));if(s[ci]=null,s.destroyed){Cs(s[mge]===0);let c=s[cc].splice(s[ai]);for(let l=0;l<c.length;l++){let u=c[l];we.errorRequest(s,u,a)}}}),r.unref(),t[ci]=r,e[ci]=r,we.addListener(e,"error",function(s){Cs(s.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[li]=s,this[Fd][WQ](s)}),we.addListener(e,"end",function(){we.destroy(this,new jf("other side closed",we.getSocketInfo(this)))}),we.addListener(e,"close",function(){let s=this[li]||new jf("closed",we.getSocketInfo(this));t[ur]=null,this[ci]!=null&&this[ci].destroy(s),t[YQ]=t[ai],Cs(t[vy]===0),t.emit("disconnect",t[Qy],[t],s),t[lc]()});let n=!1;return e.on("close",()=>{n=!0}),{version:"h2",defaultPipelining:1/0,write(...s){return Dge(t,...s)},resume(){Rge(t)},destroy(s,i){n?queueMicrotask(i):e.destroy(s).on("close",i)},get destroyed(){return e.destroyed},busy(){return!1}}}o(Qge,"connectH2");function Rge(t){let e=t[ur];e?.destroyed===!1&&(t[Ege]===0&&t[Bz]===0?(e.unref(),t[ci].unref()):(e.ref(),t[ci].ref()))}o(Rge,"resumeH2");function Tge(t){Cs(t.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[ur][li]=t,this[Fd][WQ](t)}o(Tge,"onHttp2SessionError");function vge(t,e,r){if(r===0){let n=new $Q(`HTTP/2: "frameError" received - type ${t}, code ${e}`);this[ur][li]=n,this[Fd][WQ](n)}}o(vge,"onHttp2FrameError");function Pge(){let t=new jf("other side closed",we.getSocketInfo(this[ur]));this.destroy(t),we.destroy(this[ur],t)}o(Pge,"onHttp2SessionEnd");function _ge(t){let e=this[li]||new jf(`HTTP/2: "GOAWAY" frame received with code ${t}`,we.getSocketInfo(this)),r=this[Fd];if(r[ur]=null,r[yge]=null,this[ci]!=null&&(this[ci].destroy(e),this[ci]=null),we.destroy(this[ur],e),r[ai]<r[cc].length){let n=r[cc][r[ai]];r[cc][r[ai]++]=null,we.errorRequest(r,n,e),r[YQ]=r[ai]}Cs(r[vy]===0),r.emit("disconnect",r[Qy],[r],e),r[lc]()}o(_ge,"onHTTP2GoAway");function kge(t){return t!=="GET"&&t!=="HEAD"&&t!=="OPTIONS"&&t!=="TRACE"&&t!=="CONNECT"}o(kge,"shouldSendContentLength");function Dge(t,e){let r=t[ci],{method:n,path:s,host:i,upgrade:a,expectContinue:c,signal:l,headers:u}=e,{body:d}=e;if(a)return we.errorRequest(t,e,new Error("Upgrade not supported for H2")),!1;let A={};for(let B=0;B<u.length;B+=2){let N=u[B+0],Q=u[B+1];if(Array.isArray(Q))for(let D=0;D<Q.length;D++)A[N]?A[N]+=`,${Q[D]}`:A[N]=Q[D];else A[N]=Q}let p,{hostname:f,port:h}=t[Qy];A[Cge]=i||`${f}$
`;if(n.username||n.password){let p=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;i["Proxy-Authorization"]=`Basic ${Buffer.from(p).toString("base64")}`}i.Host=`${a}:${r.port}`,i["Proxy-Connection"]||(i["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let p of Object.keys(i))c+=`${p}: ${i[p]}\r
`)+4,e.outputData[0].data=e._header+n.substring(s),UA("Output buffer: %o",e.outputData[0].data));let i;return this.proxy.protocol==="https:"?(UA("Creating `tls.Socket`: %o",this.connectOpts),i=fke.connect(this.connectOpts)):(UA("Creating `net.Socket`: %o",this.connectOpts),i=pke.connect(this.connectOpts)),await(0,mke.once)(i,"connect"),i}};iB.protocols=["http","https"];Ds.HttpProxyAgent=iB;function Eke(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}o(Eke,"omit")});var ZK=m(yB=>{"use strict";Object.defineProperty(yB,"__esModule",{value:!0});yB.state=void 0;yB.state={instrumenterImplementation:void 0}});var mX=m(wB=>{"use strict";Object.defineProperty(wB,"__esModule",{value:!0});wB.state=void 0;wB.state={operationRequestMap:new WeakMap}});var Y7=m(sp=>{"use strict";Object.defineProperty(sp,"__esModule",{value:!0});var L1e=require("os"),F1e=require("util");function U1e(t){return t&&typeof t=="object"&&"default"in t?t:{default:t}}o(U1e,"_interopDefaultLegacy");var q1e=U1e(F1e);function G1e(t,...e){process.stderr.write(`${q1e.default.format(t,...e)}${L1e.EOL}`)}o(G1e,"log");var L7=typeof process<"u"&&process.env&&process.env.DEBUG||void 0,U7,DM=[],OM=[],Hb=[];L7&&MM(L7);var q7=Object.assign(t=>G7(t),{enable:MM,enabled:LM,disable:H1e,log:G1e});function MM(t){U7=t,DM=[],OM=[];let e=/\*/g,r=t.split(",").map(n=>n.trim().replace(e,".*?"));for(let n of r)n.startsWith("-")?OM.push(new RegExp(`^${n.substr(1)}$`)):DM.push(new RegExp(`^${n}$`));for(let n of Hb)n.enabled=LM(n.namespace)}o(MM,"enable");function LM(t){if(t.endsWith("*"))return!0;for(let e of OM)if(e.test(t))return!1;for(let e of DM)if(e.test(t))return!0;return!1}o(LM,"enabled");function H1e(){let t=U7||"";return MM(""),t}o(H1e,"disable");function G7(t){let e=Object.assign(r,{enabled:LM(t),destroy:V1e,log:q7.log,namespace:t,extend:z1e});function r(...n){e.enabled&&(n.length>0&&(n[0]=`${t} ${n[0]}`),e.log(...n))}return o(r,"debug"),Hb.push(e),e}o(G7,"createDebugger");function V1e(){let t=Hb.indexOf(this);return t>=0?(Hb.splice(t,1),!0):!1}o(V1e,"destroy");function z1e(t){let e=G7(`${this.namespace}:${t}`);return e.log=this.log,e}o(z1e,"extend");var og=q7,H7=new Set,qb=typeof process<"u"&&process.env&&process.env.AZURE_LOG_LEVEL||void 0,Vb,zb=og("azure");zb.log=(...t)=>{og.log(...t)};var FM=["verbose","info","warning","error"];qb&&($7(qb)?V7(qb):console.error(`AZURE_LOG_LEVEL set to unknown log level '${qb}'; logging is not enabled. Acceptable values: ${FM.join(", ")}.`));function V7(t){if(t&&!$7(t))throw new Error(`Unknown log level '${t}'. Acceptable values: ${FM.join(",")}`);Vb=t;let e=[];for(let r of H7)J7(r)&&e.push(r.namespace);og.enable(e.join(","))}o(V7,"setLogLevel");function J1e(){return Vb}o(J1e,"getLogLevel");var F7={verbose:400,info:300,warning:200,error:100};function $1e(t){let e=zb.extend(t);return z7(zb,e),{error:Gb(e,"error"),warning:Gb(e,"warning"),info:Gb(e,"info"),verbose:Gb(e,"verbose")}}o($1e,"createClientLogger");function z7(t,e){e.log=(...r)=>{t.log(...r)}}o(z7,"patchLogMethod");function Gb(t,e){let r=Object.assign(t.extend(e),{level:e});if(z7(t,r),J7(r)){let n=og.disable();og.enable(n+","+r.namespace)}return H7.add(r),r}o(Gb,"createLogger");function J7(t){return!!(Vb&&F7[t.level]<=F7[Vb])}o(J7,"shouldEnable");function $7(t){return FM.includes(t)}o($7,"isAzureLogLevel");sp.AzureLogger=zb;sp.createClientLogger=$1e;sp.getLogLevel=J1e;sp.setLogLevel=V7});var GM=m(cg=>{"use strict";Object.defineProperty(cg,"__esModule",{value:!0});var ip=new WeakMap,Jb=new WeakMap,ag=class t{static{o(this,"AbortSignal")}constructor(){this.onabort=null,ip.set(this,[]),Jb.set(this,!1)}get aborted(){if(!Jb.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");return Jb.get(this)}static get none(){return new t}addEventListener(e,r){if(!ip.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");ip.get(this).push(r)}removeEventListener(e,r){if(!ip.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");let n=ip.get(this),s=n.indexOf(r);s>-1&&n.splice(s,1)}dispatchEvent(e){thro
Polling status: ${see.includes(d)?"Stopped":"Running"}`),d==="succeeded"){let A=a(u,r);if(A!==void 0)return{response:await e(A).catch(ree({state:r,stateProxy:n,isOperationError:c})),status:d}}return{response:u,status:d}}o(uFe,"pollOperationHelper");async function cee(t){let{poll:e,state:r,stateProxy:n,options:s,getOperationStatus:i,getResourceLocation:a,getOperationLocation:c,isOperationError:l,withOperationLocation:u,getPollingInterval:d,processResult:A,getError:p,updateState:f,setDelay:h,isDone:g,setErrorAsResult:y}=t,{operationLocation:E}=r.config;if(E!==void 0){let{response:C,status:I}=await uFe({poll:e,getOperationStatus:i,state:r,stateProxy:n,operationLocation:E,getResourceLocation:a,isOperationError:l,options:s});if(oee({status:I,response:C,state:r,stateProxy:n,isDone:g,processResult:A,getError:p,setErrorAsResult:y}),!see.includes(I)){let B=d?.(C);B&&h(B);let N=c?.(C,r);if(N!==void 0){let Q=E!==N;r.config.operationLocation=N,u?.(N,Q)}else u?.(E,!1)}f?.(r,C)}}o(cee,"pollOperation");function lee(t){let{azureAsyncOperation:e,operationLocation:r}=t;return r??e}o(lee,"getOperationLocationPollingUrl");function uee(t){return t.headers.location}o(uee,"getLocationHeader");function dee(t){return t.headers["operation-location"]}o(dee,"getOperationLocationHeader");function Aee(t){return t.headers["azure-asyncoperation"]}o(Aee,"getAzureAsyncOperationHeader");function dFe(t){let{location:e,requestMethod:r,requestPath:n,resourceLocationConfig:s}=t;switch(r){case"PUT":return n;case"DELETE":return;default:switch(s){case"azure-async-operation":return;case"original-uri":return n;default:return e}}}o(dFe,"findResourceLocation");function pee(t){let{rawResponse:e,requestMethod:r,requestPath:n,resourceLocationConfig:s}=t,i=dee(e),a=Aee(e),c=lee({operationLocation:i,azureAsyncOperation:a}),l=uee(e),u=r?.toLocaleUpperCase();return c!==void 0?{mode:"OperationLocation",operationLocation:c,resourceLocation:dFe({requestMethod:u,location:l,requestPath:n,resourceLocationConfig:s})}:l!==void 0?{mode:"ResourceLocation",operationLocation:l}:u==="PUT"&&n?{mode:"Body",operationLocation:n}:void 0}o(pee,"inferLroMode");function fee(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'tnecessarilyindicatetheoperationhasfailed.CheckyourAzuresubscriptionorresourcestatusformoreinformation.`);switch(e?.toLocaleLowerCase()){case void 0:return jM(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 Qu.verbose(`LRO:unrecognizedoperationstatus:${e}`),e}}o(fee,"transformStatus");function AFe(t){var e;let{status:r}=(e=t.body)!==null&&e!==void 0?e:{};return fee({status:r,statusCode:t.statusCode})}o(AFe,"getStatus");function pFe(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 fee({status:i,statusCode:t.statusCode})}o(pFe,"getProvisioningState");function jM(t){return t===202?"running":t<300?"succeeded":"failed"}o(jM,"toOperationStatus");function hee({rawResponse:t}){let e=t.headers["retry-after"];if(e!==void 0){let r=parseInt(e);return isNaN(r)?fFe(new Date(e)):r*1e3}}o(hee,"parseRetryAfter");function mee(t){let e=t.flatResponse.error;if(!e){Qu.warning("The long-running operation failed but there is no error property in the response's body");return}if(!e.code||!e.message){Qu.warning("The long-running operation failed but the error property in the response's body doesn't contain code or message");return}return e}o(mee,"getErrorFromResponse");function fFe(t){let e=Math.floor(new Date().getTime()),r=t.getTime();if(e<r)return r-e}o(fFe,"calculatePollingIntervalFromDate");function gee(t){let{response:e,state:r,operationLocation:n}=t;function s(){var a;switch((a=r.config.metadata)===null||a===void 0?void 0:a.mode){case void 0:return jM(e.rawResponse.sta
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}o(Dze,"logUnexpecedPropertyAccessOnce");functionOze(){Object.keys(w0).forEach(function(t){deletew0[t]})}o(Oze,"resetLoggedProperties")});varN0=m(Mo=>{"use strict";Mo.__esModule=!0;Mo.HandlebarsEnvironment=uF;functionPse(t){returnt&&t.__esModule?t:{default:t}}o(Pse,"_interopRequireDefault");varUu=cn(),Mze=fs(),cF=Pse(Mze),Lze=sF(),Fze=Qse(),Uze=oF(),S0=Pse(Uze),qze=aF(),Gze="4.7.9";Mo.VERSION=Gze;varHze=8;Mo.COMPILER_REVISION=Hze;varVze=7;Mo.LAST_COMPATIBLE_COMPILER_REVISION=Vze;varzze={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"};Mo.REVISION_CHANGES=zze;varlF="[object Object]";functionuF(t,e,r){this.helpers=t||{},this.partials=e||{},this.decorators=r||{},Lze.registerDefaultHelpers(this),Fze.registerDefaultDecorators(this)}o(uF,"HandlebarsEnvironment");uF.prototype={constructor:uF,logger:S0.default,log:S0.default.log,registerHelper:o(function(e,r){if(Uu.toString.call(e)===lF){if(r)thrownewcF.default("Arg not supported with multiple helpers");Uu.extend(this.helpers,e)}elsethis.helpers[e]=r},"registerHelper"),unregisterHelper:o(function(e){deletethis.helpers[e]},"unregisterHelper"),registerPartial:o(function(e,r){if(Uu.toString.call(e)===lF)Uu.extend(this.partials,e);else{if(typeofr>"u")thrownewcF.default('Attempting to register a partial called "'+e+'" as undefined');this.partials[e]=r}},"registerPartial"),unregisterPartial:o(function(e){deletethis.partials[e]},"unregisterPartial"),registerDecorator:o(function(e,r){if(Uu.toString.call(e)===lF){if(r)thrownewcF.default("Arg not supported with multiple decorators");Uu.extend(this.decorators,e)}elsethis.decorators[e]=r},"registerDecorator"),unregisterDecorator:o(function(e){deletethis.decorators[e]},"unregisterDecorator"),resetLoggedPropertyAccesses:o(function(){qze.resetLoggedProperties()},"resetLoggedPropertyAccesses")};varJze=S0.default.log;Mo.log=Jze;Mo.createFrame=Uu.createFrame;Mo.logger=S0.default});varkse=m((x0,_se)=>{"use strict";x0.__esModule=!0;functiondF(t){this.string=t}o(dF,"SafeString");dF.prototype.toString=dF.prototype.toHTML=function(){return""+this.string};x0.default=dF;_se.exports=x0.default});varDse=m(AF=>{"use strict";AF.__esModule=!0;AF.wrapHelper=$ze;function$ze(t,e){if(typeoft!="function")returnt;varr=o(function(){vars=arguments[arguments.length-1];returnarguments[arguments.length-1]=e(s),t.apply(this,arguments)},"wrapper");returnr}o($ze,"wrapHelper")});varqse=m(jc=>{"use strict";jc.__esModule=!0;jc.checkRevision=Zze;jc.template=eJe;jc.wrapProgram=Q0;jc.resolvePartial=tJe;jc.invokePartial=rJe;jc.noop=Fse;functionYze(t){returnt&&t.__esModule?t:{default:t}}o(Yze,"_interopRequireDefault");functionWze(t){if(t&&t.__esModule)returnt;vare={};if(t!=null)for(varrint)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);returne.default=t,e}o(Wze,"_interopRequireWildcard");varjze=cn(),Pp=Wze(jze),Kze=fs(),Ha=Yze(Kze),Va=N0(),Ose=sF(),Xze=Dse(),Mse=aF();functionZze(t){vare=t&&t[0]||1,r=Va.COMPILER_REVISION;if(!(e>=Va.LAST_COMPATIBLE_COMPILER_REVISION&&e<=Va.COMPILER_REVISION))if(e<Va.LAST_COMPATIBLE_COMPILER_REVISION){varn=Va.REVISION_CHANGES[r],s=Va.REVISION_CHANGES[e];thrownewHa.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+").")}elsethrownewHa.default("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+t[1]+").")}o(Zze,"checkRevision");functioneJe(t,e){if(!e)thrownewHa.default("No environment passed to template");if(!t||!t.main)thrownewHa.default("Unknown template object: "+typeoft);t.main.decorator=t.main_d,e.VM.checkRevision(t.compiler);varr=t.compiler&&t.compiler[0]===7;functionn(a,c,l){l.hash&&(c=Pp.extend({},c,l.hash),l.ids&&(l.ids[0]=!0)),a=e.VM.res
Expecting `+de.join(", ")+", got '"+(this.terminals_[B]||B)+"'":qr="Parse error on line "+(A+1)+": Unexpected "+(B==1?"end of input":"'"+(this.terminals_[B]||B)+"'"),this.parseError(qr,{text:this.lexer.match,token:this.terminals_[B]||B,line:this.lexer.yylineno,loc:y,expected:de})}}if(D[0]instanceofArray&&D.length>1)thrownewError("Parse Error: multiple actions possible at state: "+Q+", token: "+B);switch(D[0]){case1:a.push(B),c.push(this.lexer.yytext),l.push(this.lexer.yylloc),a.push(D[1]),B=null,N?(B=N,N=null):(p=this.lexer.yyleng,d=this.lexer.yytext,A=this.lexer.yylineno,y=this.lexer.yylloc,f>0&&f--);break;case2:if(Ce=this.productions_[D[1]][1],_e.$=c[c.length-Ce],_e._$={first_line:l[l.length-(Ce||1)].first_line,last_line:l[l.length-1].last_line,first_column:l[l.length-(Ce||1)].first_column,last_column:l[l.length-1].last_column},E&&(_e._$.range=[l[l.length-(Ce||1)].range[0],l[l.length-1].range[1]]),Ne=this.performAction.call(_e,d,p,A,this.yy,D[1],c,l),typeofNe<"u")returnNe;Ce&&(a=a.slice(0,-1*Ce*2),c=c.slice(0,-1*Ce),l=l.slice(0,-1*Ce)),a.push(this.productions_[D[1]][0]),c.push(_e.$),l.push(_e._$),Ze=u[a[a.length-2]][a[a.length-1]],a.push(Ze);break;case3:return!0}}return!0},"parse")},e=(function(){varn={EOF:1,parseError:o(function(i,a){if(this.yy.parser)this.yy.parser.parseError(i,a);elsethrownewError(i)},"parseError"),setInput:o(function(i){returnthis._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},"setInput"),input:o(function(){vari=this._input[0];this.yytext+=i,this.yyleng++,this.offset++,this.match+=i,this.matched+=i;vara=i.match(/(?:\r\n?|\n).*/g);returna?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),i},"input"),unput:o(function(i){vara=i.length,c=i.split(/(?:\r\n?|\n)/g);this._input=i+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-a-1),this.offset-=a;varl=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),c.length-1&&(this.yylineno-=c.length-1);varu=this.yylloc.range;returnthis.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:c?(c.length===l.length?this.yylloc.first_column:0)+l[l.length-c.length].length-c[0].length:this.yylloc.first_column-a},this.options.ranges&&(this.yylloc.range=[u[0],u[0]+this.yyleng-a]),this},"unput"),more:o(function(){returnthis._more=!0,this},"more"),less:o(function(i){this.unput(this.match.slice(i))},"less"),pastInput:o(function(){vari=this.matched.substr(0,this.matched.length-this.match.length);return(i.length>20?"...":"")+i.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:o(function(){vari=this.match;returni.length<20&&(i+=this._input.substr(0,20-i.length)),(i.substr(0,20)+(i.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:o(function(){vari=this.pastInput(),a=newArray(i.length+1).join("-");returni+this.upcomingInput()+`
`+a+"^"},"showPosition"),next:o(function(){if(this.done)returnthis.EOF;this._input||(this.done=!0);vari,a,c,l,u,d;this._more||(this.yytext="",this.match="");for(varA=this._currentRules(),p=0;p<A.length&&(c=this._input.match(this.rules[A[p]]),!(c&&(!a||c[0].length>a[0].length)&&(a=c,l=p,!this.options.flex)));p++);returna?(d=a[0].match(/(?:\r\n?|\n).*/g),d&&(this.yylineno+=d.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:d?d[d.length-1].length-d[d.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,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(a[0].length),this.matched+=a[0],i=this.performAction.call(this,this.yy,this,A[l],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i||void0):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:o(function(){vari=this.next();returntypeofi<"u"?i:this.lex()},"lex"),begin:o(function(i){this.conditionStack.push(i)},"begin"),popState:o(function(){returnthis.conditionStack.pop()},"popState"),_currentRules:o(function(){returnthis.conditions[this.conditionStack[this.conditionStack.length-1]].rules},"_currentRules"),topState:o(function(){returnthis.conditionStack[this.conditionStack.length-2]},"topState"),pushState:o(function(i){this.begin(i)},"begin")};returnn.options={},n.performAction=o(function(i,a,c,l){functionu(A,p){returna.yytext=a.yytext.substring(A,a.yyleng-p+A)}o(u,"strip");vard=l;switch(c){case0:if(a.yytext.slice(-2)==="\\\\"?(u(0,1),this.begin("mu")):a.yytext.slice(-1)==="\\"?(u(0,1),this.begin("emu")):this.begin("mu"),a.yytext)return15;break;case1:return15;case2:returnthis.popState(),15;break;case3:returnthis.begin("raw"),15;break;case4:returnthis.popState(),this.conditionStack[this.conditionStack.length-1]==="raw"?15:(u(5,9),"END_RAW_BLOCK");case5:return15;case6:returnthis.popState(),14;break;case7:return65;case8:return68;case9:return19;case10:returnthis.popState(),this.begin("raw"),23;break;case11:return55;case12:return60;case13:return29;case14:return47;case15:returnthis.popState(),44;break;case16:returnthis.popState(),44;break;case17:return34;case18:return39;case19:return51;case20:return48;case21:this.unput(a.yytext),this.popState(),this.begin("com");break;case22:returnthis.popState(),14;break;case23:return48;case24:return73;case25:return72;case26:return72;case27:return87;case28:break;case29:returnthis.popState(),54;break;case30:returnthis.popState(),33;break;case31:returna.yytext=u(1,2).replace(/\\"/g,'"'),80;break;case32:returna.yytext=u(1,2).replace(/\\'/g,"'"),80;break;case33:return85;case34:return82;case35:return82;case36:return83;case37:return84;case38:return81;case39:return75;case40:return77;case41:return72;case42:returna.yytext=a.yytext.replace(/\\([\\\]])/g,"$1"),72;break;case43:return"INVALID";case44:return5}},"anonymous"),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;functionr(){this.yy={}}returno(r,"Parser"),r.prototype=t,t.Parser=r,newr})();_0.default=fJe;jse.exports=_0.default});varM0=m((O0,eie)=>{"use strict";O0.__esModule=!0;functionhJe(t){returnt&&t.__esModule?t:{default:t}}o(hJe,"_interopRequireDefault");varmJe=fs(),EF=hJe(mJe);functionk0(){this.parents=[]}o(k0,"Visitor");k0.prototype={constructor:k0,mutating:!1,acceptKey:o(function(e,r){varn=this.accept(e[r]);if(this.mutating){if(n&&!k0.prototype[n.type])thrownewEF.default('Unexpected node type "'+n.type+'" found when accepting '+r+" on "+e.type);e[r]=n}},"acceptKey"),acceptRequired:o(function(e,r){if(this.a
`])}),e},"merge"),each:o(function(e){for(var r=0,n=this.source.length;r<n;r++)e(this.source[r])},"each"),empty:o(function(){var e=this.currentLocation||{start:{}};return new Vu(e.start.line,e.start.column,this.srcFile)},"empty"),wrap:o(function(e){var r=arguments.length<=1||arguments[1]===void 0?this.currentLocation||{start:{}}:arguments[1];return e instanceof Vu?e:(e=UF(e,this,r),new Vu(r.start.line,r.start.column,this.srcFile,e))},"wrap"),functionCall:o(function(e,r,n){return n=this.generateList(n),this.wrap([e,r?"."+r+"(":"(",n,")"])},"functionCall"),quotedString:o(function(e){return'"'+(e+"").replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")+'"'},"quotedString"),objectLiteral:o(function(e){var r=this,n=[];Object.keys(e).forEach(function(i){var a=UF(e[i],r);a!=="undefined"&&n.push([r.quotedString(i),":",a])});var s=this.generateList(n);return s.prepend("{"),s.add("}"),s},"objectLiteral"),generateList:o(function(e){for(var r=this.empty(),n=0,s=e.length;n<s;n++)n&&r.add(","),r.add(UF(e[n],this));return r},"generateList"),generateArray:o(function(e){var r=this.generateList(e);return r.prepend("["),r.add("]"),r},"generateArray")};z0.default=Die;Oie.exports=z0.default});var Gie=m((J0,qie)=>{"use strict";J0.__esModule=!0;function Uie(t){return t&&t.__esModule?t:{default:t}}o(Uie,"_interopRequireDefault");var Lie=N0(),p$e=fs(),GF=Uie(p$e),f$e=cn(),h$e=Mie(),Fie=Uie(h$e);function Lp(t){this.value=t}o(Lp,"Literal");function Fp(){}o(Fp,"JavaScriptCompiler");Fp.prototype={nameLookup:o(function(e,r){return this.internalNameLookup(e,r)},"nameLookup"),depthedLookup:o(function(e){return[this.aliasable("container.lookup"),"(depths, ",JSON.stringify(e),")"]},"depthedLookup"),compilerInfo:o(function(){var e=Lie.COMPILER_REVISION,r=Lie.REVISION_CHANGES[e];return[e,r]},"compilerInfo"),appendToBuffer:o(function(e,r,n){return f$e.isArray(e)||(e=[e]),e=this.source.wrap(e,r),this.environment.isSimple?["return ",e,";"]:n?["buffer += ",e,";"]:(e.appendToBuffer=!0,e)},"appendToBuffer"),initializeBuffer:o(function(){return this.quotedString("")},"initializeBuffer"),internalNameLookup:o(function(e,r){return this.lookupPropertyFunctionIsUsed=!0,["lookupProperty(",e,",",JSON.stringify(r),")"]},"internalNameLookup"),lookupPropertyFunctionIsUsed:!1,compile:o(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,a=void 0,c=void 0,l=void 0,u=void 0;for(l=0,u=i.length;l<u;l++)a=i[l],this.source.currentLocation=a.loc,c=c||a.loc,this[a.opcode].apply(this,a.args);if(this.source.currentLocation=c,this.pushSource(""),this.stackSlot||this.inlineStack.length||this.compileStack.length)throw new GF.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(),`;
`)}o(Z5e,"fromDER")});varIN=m(pl=>{"use strict";Object.defineProperty(pl,"__esModule",{value:!0});pl.SHA2_HASH_ALGOS=pl.RSA_SIGNATURE_ALGOS=pl.ECDSA_SIGNATURE_ALGOS=void0;pl.ECDSA_SIGNATURE_ALGOS={"1.2.840.10045.4.3.1":"sha224","1.2.840.10045.4.3.2":"sha256","1.2.840.10045.4.3.3":"sha384","1.2.840.10045.4.3.4":"sha512"};pl.RSA_SIGNATURE_ALGOS={"1.2.840.113549.1.1.14":"sha224","1.2.840.113549.1.1.11":"sha256","1.2.840.113549.1.1.12":"sha384","1.2.840.113549.1.1.13":"sha512"};pl.SHA2_HASH_ALGOS={"2.16.840.1.101.3.4.2.1":"sha256","2.16.840.1.101.3.4.2.2":"sha384","2.16.840.1.101.3.4.2.3":"sha512"}});varnq=m(BN=>{"use strict";Object.defineProperty(BN,"__esModule",{value:!0});BN.RFC3161TimestampVerificationError=void0;varrq=classextendsError{static{o(this,"RFC3161TimestampVerificationError")}};BN.RFC3161TimestampVerificationError=rq});varCle=m(zo=>{"use strict";vare8e=zo&&zo.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);vars=Object.getOwnPropertyDescriptor(e,r);(!s||("get"ins?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:o(function(){returne[r]},"get")}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),t8e=zo&&zo.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),r8e=zo&&zo.__importStar||(function(){vart=o(function(e){returnt=Object.getOwnPropertyNames||function(r){varn=[];for(varsinr)Object.prototype.hasOwnProperty.call(r,s)&&(n[n.length]=s);returnn},t(e)},"ownKeys");returnfunction(e){if(e&&e.__esModule)returne;varr={};if(e!=null)for(varn=t(e),s=0;s<n.length;s++)n[s]!=="default"&&e8e(r,e,n[s]);returnt8e(r,e),r}})();Object.defineProperty(zo,"__esModule",{value:!0});zo.TSTInfo=void0;varyle=r8e(mf()),n8e=IN(),s8e=nq(),sq=class{static{o(this,"TSTInfo")}root;constructor(e){this.root=e}getversion(){returnthis.root.subs[0].toInteger()}getgenTime(){returnthis.root.subs[4].toDate()}getmessageImprintHashAlgorithm(){lete=this.messageImprintObj.subs[0].subs[0].toOID();returnn8e.SHA2_HASH_ALGOS[e]}getmessageImprintHashedMessage(){returnthis.messageImprintObj.subs[1].value}getraw(){returnthis.root.toDER()}verify(e){letr=yle.digest(this.messageImprintHashAlgorithm,e);if(!yle.bufferEqual(r,this.messageImprintHashedMessage))thrownews8e.RFC3161TimestampVerificationError("message imprint does not match artifact")}getmessageImprintObj(){returnthis.root.subs[2]}};zo.TSTInfo=sq});varBle=m(Jo=>{"use strict";vari8e=Jo&&Jo.__createBinding||(Object.create?(function(t,e,r,n){n===void0&&(n=r);vars=Object.getOwnPropertyDescriptor(e,r);(!s||("get"ins?!e.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:o(function(){returne[r]},"get")}),Object.defineProperty(t,n,s)}):(function(t,e,r,n){n===void0&&(n=r),t[n]=e[r]})),o8e=Jo&&Jo.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),a8e=Jo&&Jo.__importStar||(function(){vart=o(function(e){returnt=Object.getOwnPropertyNames||function(r){varn=[];for(varsinr)Object.prototype.hasOwnProperty.call(r,s)&&(n[n.length]=s);returnn},t(e)},"ownKeys");returnfunction(e){if(e&&e.__esModule)returne;varr={};if(e!=null)for(varn=t(e),s=0;s<n.length;s++)n[s]!=="default"&&i8e(r,e,n[s]);returno8e(r,e),r}})();Object.defineProperty(Jo,"__esModule",{value:!0});Jo.RFC3161Timestamp=void0;varc8e=EN(),iq=a8e(mf()),Ile=IN(),SE=nq(),l8e=Cle(),u8e="1.2.840.113549.1.7.2",d8e="1.2.840.113549.1.9.16.1.4",A8e="1.2.840.113549.1.9.4",oq=classt{static{o(this,"RFC3161Timestamp")}root;constructor(e){this.root=e}staticparse(e){letr=c8e.ASN1Obj.parseBuffer(e);returnnewt(r)}getstatus(){returnthis.pkiStatusInfoObj.subs[0].toInteger()}getcontentType(){returnthis.contentTypeObj.toOID()}geteContentType(){returnthis.eContentTypeObj.toOID()}getsigningTime(){returnthis.tstInfo.genTime}getsignerIssuer(){returnthis.signerSidObj.subs[0].value}getsignerSerialNumber(){returnthis.signerSidObj.subs[1].value}getsignerDigestAlgorith
`,P9e=/\u2014 (\S+) (\S+)\n/g;function _9e(t,e){let r=t.inclusionProof,n=Oq.fromString(r.checkpoint.envelope),s=GN.fromString(n.note);if(!k9e(n,e))throw new TE.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid checkpoint signature"});return s}o(_9e,"verifyCheckpoint");function k9e(t,e){let r=Buffer.from(t.note,"utf-8");return t.signatures.some(n=>{let s=e.find(i=>rue.crypto.bufferEqual(i.logID.subarray(0,4),n.keyHint)&&i.baseURL.match(n.name));return s?rue.crypto.verify(r,s.publicKey,n.signature):!1})}o(k9e,"verifySignedNote");var Oq=class t{static{o(this,"SignedNote")}note;signatures;constructor(e,r){this.note=e,this.signatures=r}static fromString(e){if(!e.includes(Dq))throw new TE.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"missing checkpoint separator"});let r=e.indexOf(Dq),n=e.slice(0,r+1),i=e.slice(r+Dq.length).matchAll(P9e),a=Array.from(i,c=>{let[,l,u]=c,d=Buffer.from(u,"base64");if(d.length<5)throw new TE.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"malformed checkpoint signature"});return{name:l,keyHint:d.subarray(0,4),signature:d.subarray(4)}});if(a.length===0)throw new TE.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"no signatures found in checkpoint"});return new t(n,a)}},GN=class t{static{o(this,"LogCheckpoint")}origin;logSize;logHash;rest;constructor(e,r,n,s){this.origin=e,this.logSize=r,this.logHash=n,this.rest=s}static fromString(e){let r=e.trimEnd().split(`
`);if(r.length<3)throw new TE.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"too few lines in checkpoint header"});let n=r[0],s=BigInt(r[1]),i=Buffer.from(r[2],"base64"),a=r.slice(3);return new t(n,s,i,a)}};vE.LogCheckpoint=GN});var sue=m(Uq=>{"use strict";Object.defineProperty(Uq,"__esModule",{value:!0});Uq.verifyMerkleInclusion=M9e;var Fq=Pi(),Mq=Ur(),D9e=Buffer.from([0]),O9e=Buffer.from([1]);function M9e(t,e){let r=t.inclusionProof,n=BigInt(r.logIndex),s=BigInt(e.logSize);if(n<0n||n>=s)throw new Mq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:`invalidindex:${n}`});let{inner:i,border:a}=L9e(n,s);if(r.hashes.length!==i+a)throw new Mq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid hash count"});let c=r.hashes.slice(0,i),l=r.hashes.slice(i),u=V9e(t.canonicalizedBody),d=U9e(F9e(u,c,n),l);if(!Fq.crypto.bufferEqual(d,e.logHash))throw new Mq.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"calculated root hash does not match inclusion proof"})}o(M9e,"verifyMerkleInclusion");function L9e(t,e){let r=q9e(t,e),n=G9e(t>>BigInt(r));return{inner:r,border:n}}o(L9e,"decompInclProof");function F9e(t,e,r){return e.reduce((n,s,i)=>r>>BigInt(i)&BigInt(1)?Lq(s,n):Lq(n,s),t)}o(F9e,"chainInner");function U9e(t,e){return e.reduce((r,n)=>Lq(n,r),t)}o(U9e,"chainBorderRight");function q9e(t,e){return H9e(t^e-BigInt(1))}o(q9e,"innerProofSize");function G9e(t){return t.toString(2).split("1").length-1}o(G9e,"onesCount");function H9e(t){return t===0n?0:t.toString(2).length}o(H9e,"bitLength");function Lq(t,e){return Fq.crypto.digest("sha256",O9e,t,e)}o(Lq,"hashChildren");function V9e(t){return Fq.crypto.digest("sha256",D9e,t)}o(V9e,"hashLeaf")});var oue=m(qq=>{"use strict";Object.defineProperty(qq,"__esModule",{value:!0});qq.verifyTLogSET=$9e;var iue=Pi(),z9e=Ur(),J9e=yf();function $9e(t,e){if(!(0,J9e.filterTLogAuthorities)(e,{logID:t.logId.keyId,targetDate:new Date(Number(t.integratedTime)*1e3)}).some(s=>{let i=Y9e(t),a=Buffer.from(iue.json.canonicalize(i),"utf8"),c=t.inclusionPromise.signedEntryTimestamp;return iue.crypto.verify(a,s.publicKey,c)}))throw new z9e.VerificationError({code:"TLOG_INCLUSION_PROMISE_ERROR",message:"inclusion promise could not be verified"})}o($9e,"verifyTLogSET");function Y9e(t){let{integratedTime:e,logIndex:r,logId:n,canonicalizedBody:s}=t;return{body:s.toString("base64"),integratedTime:Number(e),logIndex:Number(r),logID:n.keyId.toString("hex")}}o(Y9e,"toVerificationPayload")});var cue=m(HN=>{"use strict";Object.defineProperty(HN,"__esModule",{value:!0});HN.verifyTLogBody=Z9e;HN.verifyTLogInclusion=e6e;var aue=Xle(),Vq=Ur(),Gq=Zle(),Hq=eue(),W9e=tue(),j9e=nue(),K9e=sue(),X9e=oue();function Z9e(t,e){let{kind:r,version:n}=t.kindVersion,s=JSON.parse(t.canonicalizedBody.toString("utf8"));if(r!==s.kind||n!==s.apiVersion)throw new Vq.VerificationError({code:"TLOG_BODY_ERROR",message:`kind/versionmismatch-expected:${r}/${n},received:${s.kind}/${s.apiVersion}`});switch(r){case"dsse":if(n==Gq.DSSE_API_VERSION_V1)return(0,Gq.verifyDSSETLogBody)(s,e);{let i=aue.Entry.fromJSON(s);return(0,Gq.verifyDSSETLogBodyV2)(i,e)}case"intoto":return(0,W9e.verifyIntotoTLogBody)(s,e);case"hashedrekord":if(n==Hq.HASHEDREKORD_API_VERSION_V1)return(0,Hq.verifyHashedRekordTLogBody)(s,e);{let i=aue.Entry.fromJSON(s);return(0,Hq.verifyHashedRekordTLogBodyV2)(i,e)}default:throw new Vq.VerificationError({code:"TLOG_BODY_ERROR",message:`unsupportedkind:${r}`})}}o(Z9e,"verifyTLogBody");function e6e(t,e){let r=!1;if(t6e(t)&&((0,X9e.verifyTLogSET)(t,e),r=!0),r6e(t)){let n=(0,j9e.verifyCheckpoint)(t,e);(0,K9e.verifyMerkleInclusion)(t,n),r=!0}if(!r)throw new Vq.VerificationError({code:"TLOG_MISSING_INCLUSION_ERROR",message:"inclusion could not be verified"})}o(e6e,"verifyTLogInclusion");function t6e(t){return t.inclusionPromise!==void 0}o(t6e,"isTLogEntryWithInclusionPromise");function r6e(t){return t.inclusionProof!==void 0}o(r6e,"isTLogEntryWithInclusionProof")});var pue=m(VN=>{"use strict";Object.defineProperty(VN,"__esModule",{value:!0});VN.Verifier=void 0;var n6e=require("util"),
`),u}o(lG,"getBlockValue");functionhAe(t,e){if(e.valueStart===cAe)return"";let{valueStart:r,valueEnd:n}=e;if(e.fast)returnt.slice(r,n);switch(e.style){caseyr.SINGLE_QUOTED:returnpAe(t,r,n);caseyr.DOUBLE_QUOTED:returnfAe(t,r,n);caseyr.LITERAL_BLOCK:returnlG(t,r,n,e.indent,e.chomping,!1);caseyr.FOLDED_BLOCK:returnlG(t,r,n,e.indent,e.chomping,!0);default:returnAAe(t,r,n)}}o(hAe,"getScalarValue");varmAe=Object.assign(Object.create(null),{"!":"!","!!":"tag:yaml.org,2002:"});functionBG(t,e){if(t.startsWith("!<")&&t.endsWith(">"))returndecodeURIComponent(t.slice(2,-1));letr=t.indexOf("!",1),n=r===-1?"!":t.slice(0,r+1),s=e?.[n]??mAe[n]??n;returndecodeURIComponent(s)+decodeURIComponent(t.slice(n.length))}o(BG,"tagNameFull");varhd=-1,gAe="tag:yaml.org,2002:merge",bx={filename:"",schema:nAe,json:!1,maxTotalMergeKeys:1e4,maxAliases:-1};functionEAe(t){return"tagStart"int&&t.tagStart!==hd?t.tagStart:"anchorStart"int&&t.anchorStart!==hd?t.anchorStart:"valueStart"int&&t.valueStart!==hd?t.valueStart:"start"int?t.start:0}o(EAe,"eventPosition$1");functionQr(t,e){Il.throwAt(t.source,t.position,e,t.filename)}o(Qr,"throwError$1");functionbG(t,e,r,n){try{returnr.finalize(n)}catch(s){if(sinstanceofIl)throws;Il.throwAt(t.source,e,sinstanceofError?s.message:String(s),t.filename)}}o(bG,"finalizeCollection");functionyAe(t,e){letr=hAe(t.source,e),n=e.tagStart===hd?"":t.source.slice(e.tagStart,e.tagEnd),s=t.schema.defaultScalarTag;if(n!==""){if(n==="!")return{value:r,tag:s};leti=BG(n,t.tagHandlers),a=t.schema.lookupScalarTag(i);if(a){letl=a.resolve(r,!0,i);returnl===Te&&Qr(t,`cannot resolve a node with !<${i}> explicit tag`),{value:l,tag:a}}letc=t.schema.lookupMappingTag(i)??t.schema.lookupSequenceTag(i);if(c){r!==""&&Qr(t,`cannot resolve a node with !<${i}> explicit tag`);letl=c.create(i);return{value:c.carrierIsResult?l:bG(t,t.position,c,l),tag:c}}Qr(t,`unknown scalar tag !<${i}>`)}returne.style===yr.PLAIN?t.schema.resolveImplicitScalarTag(r):{value:s.resolve(r,!1,s.tagName),tag:s}}o(yAe,"constructScalar");functionuG(t,e,r){letn=e.tagStart===hd?"":t.source.slice(e.tagStart,e.tagEnd);returnn===""||n==="!"?r:BG(n,t.tagHandlers)}o(uG,"collectionTagName");functionwG(t){returnt.nodeKind==="mapping"}o(wG,"isMappingTag");functiondG(t,e,r,n){for(letsofn.keys(r)){if(t.maxTotalMergeKeys!==-1&&++t.totalMergeKeys>t.maxTotalMergeKeys&&Qr(t,`merge keys exceeded maxTotalMergeKeys (${t.maxTotalMergeKeys})`),e.tag.has(e.value,s))continue;leti=e.tag.addPair(e.value,s,n.get(r,s));i&&Qr(t,i),(e.overridable??=newSet).add(s)}}o(dG,"mergeKeys");functionCAe(t,e,r,n){if(t.position=e.keyPosition,wG(n))dG(t,e,r,n);elseif(n.nodeKind==="sequence"&&Array.isArray(r))for(letsofr){leti=t.nodeTags.get(s);i||Qr(t,"cannot merge mappings; the provided source object is unacceptable"),dG(t,e,s,i)}elseQr(t,"cannot merge mappings; the provided source object is unacceptable")}o(CAe,"mergeSource");functionIAe(t,e,r,n,s){if(t.position=e.keyPosition,e.keyIsMerge){CAe(t,e,n,s);return}!t.json&&e.tag.has(e.value,r)&&!e.overridable?.has(r)&&Qr(t,"duplicated mapping key");leti=e.tag.addPair(e.value,r,n);i&&Qr(t,i),e.overridable?.delete(r)}o(IAe,"addMappingValue");functiondx(t,e,r){letn=t.frames[t.frames.length-1];if(n.kind==="document")n.value=e,n.hasValue=!0;elseif(n.kind==="sequence"){wG(r)&&t.nodeTags.set(e,r);lets=n.tag.addItem(n.value,e,n.index++);s&&Qr(t,s)}elseif(n.hasKey){lets=n.key;n.key=void0,n.hasKey=!1,IAe(t,n,s,e,r)}elsen.key=e,n.keyPosition=t.position,n.hasKey=!0,n.keyIsMerge=r.tagName===gAe}o(dx,"addValue");functionAx(t,e,r,n,s){if(e.anchorStart!==hd){leti={value:r,tag:n,isValueFinal:s};returnt.anchors.set(t.source.slice(e.anchorStart,e.anchorEnd),i),i}returnnull}o(Ax,"storeAnchor");functionBAe(t,e){letr={...bx,...e,events:t,documents:[],eventIndex:0,position:0,frames:[],anchors:newMap,nodeTags:newMap,tagHandlers:Object.create(null),totalMergeKeys:0,aliasCount:0};for(;r.eventIndex<r.events.length;){letn=r.events[r.eventIndex++];switch(r.position=EAe(n),n.type){casebt.DOCUMENT:r.anchors=newMap,r.nodeTags=ne
Supportbooleaninputlist:\`true | True | TRUE | false | False | FALSE\``)}o(Zl,"getBooleanInput");functionqh(t,e){if(process.env.GITHUB_OUTPUT||"")return$E("OUTPUT",Qx(t,e));process.stdout.write(gv.EOL),na("set-output",{name:t},ra(e))}o(qh,"setOutput");functionkj(t){process.exitCode=mv.Failure,CA(t)}o(kj,"setFailed");functionIa(){returnprocess.env.RUNNER_DEBUG==="1"}o(Ia,"isDebug");functionb(t){na("debug",{},t)}o(b,"debug");functionCA(t,e={}){na("error",Sx(e),tinstanceofError?t.toString():t)}o(CA,"error");functionVe(t,e={}){na("warning",Sx(e),tinstanceofError?t.toString():t)}o(Ve,"warning");functionS(t){process.stdout.write(t+gv.EOL)}o(S,"info");functionTSe(t){xx("group",t)}o(TSe,"startGroup");functionvSe(){xx("endgroup")}o(vSe,"endGroup");functionit(t,e){returnRSe(this,void0,void0,function*(){TSe(t);letr;try{r=yielde()}finally{vSe()}returnr})}o(it,"group");functionyn(t,e){if(process.env.GITHUB_STATE||"")return$E("STATE",Qx(t,e));na("save-state",{name:t},ra(e))}o(yn,"saveState");functionDj(t){returnprocess.env[`STATE_${t}`]||""}o(Dj,"getState");varKw=w(require("fs"),1),S1=w(require("os"),1),N1=w(require("path"),1);varMj=w(require("os"),1);functionGh(t){returnt==null?"":typeoft=="string"||tinstanceofString?t:JSON.stringify(t)}o(Gh,"toCommandValue");functionLj(t,e,r){letn=newEv(t,e,r);process.stdout.write(n.toString()+Mj.EOL)}o(Lj,"issueCommand");varOj="::",Ev=class{static{o(this,"Command")}constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){lete=Oj+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";letr=!0;for(letninthis.properties)if(this.properties.hasOwnProperty(n)){lets=this.properties[n];s&&(r?r=!1:e+=",",e+=`${n}=${_Se(s)}`)}}returne+=`${Oj}${PSe(this.message)}`,e}};functionPSe(t){returnGh(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}o(PSe,"escapeData");function_Se(t){returnGh(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}o(_Se,"escapeProperty");varGj=w(require("os"),1);varUj=require("os"),Hh=require("fs");varyv=function(t,e,r,n){functions(i){returniinstanceofr?i:newr(function(a){a(i)})}returno(s,"adopt"),new(r||(r=Promise))(function(i,a){functionc(d){try{u(n.next(d))}catch(A){a(A)}}o(c,"fulfilled");functionl(d){try{u(n.throw(d))}catch(A){a(A)}}o(l,"rejected");functionu(d){d.done?i(d.value):s(d.value).then(c,l)}o(u,"step"),u((n=n.apply(t,e||[])).next())})},{access:kSe,appendFile:DSe,writeFile:OSe}=Hh.promises,Fj="GITHUB_STEP_SUMMARY";varCv=class{static{o(this,"Summary")}constructor(){this._buffer=""}filePath(){returnyv(this,void0,void0,function*(){if(this._filePath)returnthis._filePath;lete=process.env[Fj];if(!e)thrownewError(`Unable to find environment variable for $${Fj}. Check if your runtime environment supports job summaries.`);try{yieldkSe(e,Hh.constants.R_OK|Hh.constants.W_OK)}catch{thrownewError(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}returnthis._filePath=e,this._filePath})}wrap(e,r,n={}){lets=Object.entries(n).map(([i,a])=>` ${i}="${a}"`).join("");returnr?`<${e}${s}>${r}</${e}>`:`<${e}${s}>`}write(e){returnyv(this,void0,void0,function*(){letr=!!e?.overwrite,n=yieldthis.filePath();returnyield(r?OSe:DSe)(n,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){returnyv(this,void0,void0,function*(){returnthis.emptyBuffer().write({overwrite:!0})})}stringify(){returnthis._buffer}isEmptyBuffer(){returnthis._buffer.length===0}emptyBuffer(){returnthis._buffer="",this}addRaw(e,r=!1){returnthis._buffer+=e,r?this.addEOL():this}addEOL(){returnthis.addRaw(Uj.EOL)}addCodeBlock(e,r){letn=Object.assign({},r&&{lang:r}),s=this.wrap("pre",this.wrap("code",e),n);returnthis.addRaw(s).addEOL()}addList(e,r=!1){letn=r?"ol":"ul",s=e.map(a=>this.wrap("li",a)).join(""),i=this.wrap(n,s);returnthis.addRaw(i).addEOL()}addTable(e){letr=e.map(s=>{leti=s.map(a=>{if(typeofa=="string")returnthis.wrap("td",a);let{header:c,data:
`,"utf-8")],s=Pke(n);s&&t.headers.set("Content-Length",s),t.body=awaitqK(n)}o(_ke,"buildRequestBody");varCm="multipartPolicy",kke=70,Dke=newSet("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");functionOke(t){if(t.length>kke)thrownewError(`Multipart boundary "${t}" exceeds maximum length of 70 characters`);if(Array.from(t).some(e=>!Dke.has(e)))thrownewError(`Multipart boundary "${t}" contains invalid characters`)}o(Oke,"assertValidBoundary");functionAB(){return{name:Cm,asyncsendRequest(t,e){if(!t.multipartBody)returne(t);if(t.body)thrownewError("multipartBody and regular body cannot be set at the same time");letr=t.multipartBody.boundary,n=t.headers.get("Content-Type")??"multipart/mixed",s=n.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!s)thrownewError(`Got multipart request body, but content-type header was not multipart: ${n}`);let[,i,a]=s;if(a&&r&&a!==r)thrownewError(`Multipart boundary was specified as ${a} in the header, but got ${r} in the request body`);returnr??=a,r?Oke(r):r=Rke(),t.headers.set("Content-Type",`${i}; boundary=${r}`),await_ke(t,t.multipartBody.parts,r),t.multipartBody=void0,e(t)}}}o(AB,"multipartPolicy");functionpB(){returnOI()}o(pB,"createEmptyPipeline");varGK=_I({logLevelEnvVarName:"AZURE_LOG_LEVEL",namespace:"azure"}),yut=GK.logger;functionso(t){returnGK.createClientLogger(t)}o(so,"createClientLogger");vario=so("core-rest-pipeline");functionu_(t={}){returnGI({logger:io.info,...t})}o(u_,"logPolicy");vard_=HI;functionA_(t={}){returnVI(t)}o(A_,"redirectPolicy");varfB=w(require("node:os"),1),hB=w(require("node:process"),1);functionHK(){return"User-Agent"}o(HK,"getHeaderName");asyncfunctionVK(t){if(hB.default&&hB.default.versions){lete=`${fB.default.type()}${fB.default.release()}; ${fB.default.arch()}`,r=hB.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})`)}}o(VK,"setPlatformSpecificData");varmB="1.22.2";functionVke(t){lete=[];for(let[r,n]oft){lets=n?`${r}/${n}`:r;e.push(s)}returne.join(" ")}o(Vke,"getUserAgentString");functionzK(){returnHK()}o(zK,"getUserAgentHeaderName");asyncfunctiongB(t){lete=newMap;e.set("core-rest-pipeline",mB),awaitVK(e);letr=Vke(e);returnt?`${t}${r}`:r}o(gB,"getUserAgentValue");varJK=zK(),$K="userAgentPolicy";functionp_(t={}){lete=gB(t.userAgentPrefix);return{name:$K,asyncsendRequest(r,n){returnr.headers.has(JK)||r.headers.set(JK,awaite),n(r)}}}o(p_,"userAgentPolicy");varis=classextendsError{static{o(this,"AbortError")}constructor(e){super(e),this.name="AbortError"}};functionf_(t,e){let{cleanupBeforeAbort:r,abortSignal:n,abortErrorMsg:s}=e??{};returnnewPromise((i,a)=>{functionc(){a(newis(s??"The operation was aborted."))}o(c,"rejectOnAbort");functionl(){n?.removeEventListener("abort",u)}o(l,"removeListeners");functionu(){r?.(),l(),c()}if(o(u,"onAbort"),n?.aborted)returnc();try{t(d=>{l(),i(d)},d=>{l(),a(d)})}catch(d){a(d)}n?.addEventListener("abort",u)})}o(f_,"createAbortablePromise");varWke="The delay was aborted.";functionIm(t,e){letr,{abortSignal:n,abortErrorMsg:s}=e??{};returnf_(i=>{r=setTimeout(i,t)},{cleanupBeforeAbort:o(()=>clearTimeout(r),"cleanupBeforeAbort"),abortSignal:n,abortErrorMsg:s??Wke})}o(Im,"delay");functionkc(t){if(ou(t))returnt.message;{lete;try{typeoft=="object"&&t?e=JSON.stringify(t):e=String(t)}catch{e="[unable to stringify input]"}return`Unknown error ${e}`}}o(kc,"getErrorMessage");functionYK(t){returnou(t)}o(YK,"isError");functionqA(){returniu()}o(qA,"randomUUID");varFe=lu;varWK=Symbol("rawContent");functionm_(t){returntypeoft[WK]=="function"}o(m_,"hasRawContent");functionjK(t){returnm_(t)?t[WK]():t}o(jK,"getRawContent");varEB=Cm;functiong_(){lett=AB();return{name:EB,sendRequest:o(async(e,r)=>{if(e.multipartBody)for(letnofe.multipartBody.parts)m_(n.body)&&(n.body=jK(n.body));returnt.sendRequest(e,r)},"sendRequest")}}o(g_,"multipartPolicy");varE_=zI;functiony_(){returnJI()}o(y_,"decompressResponsePolicy");functionC_(t={}){returnWI(t
`&&t[i]!=="\r";i++)l+=t[i];if(l=l.trim(),l[l.length-1]==="/"&&(l=l.substring(0,l.length-1),i--),!yOe(l)){let A;return l.trim().length===0?A="Invalid space after '<'.":A="Tag '"+l+"' is an invalid name.",Lt("InvalidTag",A,rn(t,i))}let u=fOe(t,i);if(u===!1)return Lt("InvalidAttr","Attributes for '"+l+"' have open quote.",rn(t,i));let d=u.value;if(i=u.index,d[d.length-1]==="/"){let A=i-d.length;d=d.substring(0,d.length-1);let p=DX(d,e);if(p===!0)n=!0;else return Lt(p.err.code,p.err.msg,rn(t,A+p.err.line))}else if(c)if(u.tagClosed){if(d.trim().length>0)return Lt("InvalidTag","Closing tag '"+l+"' can't have attributes or invalid starting.",rn(t,a));if(r.length===0)return Lt("InvalidTag","Closing tag '"+l+"' has not been opened.",rn(t,a));{let A=r.pop();if(l!==A.tagName){let p=rn(t,A.tagStartPos);return Lt("InvalidTag","Expected closing tag '"+A.tagName+"' (opened in line "+p.line+", col "+p.col+") instead of closing tag '"+l+"'.",rn(t,a))}r.length==0&&(s=!0)}}else return Lt("InvalidTag","Closing tag '"+l+"' doesn't have proper closing.",rn(t,i));else{let A=DX(d,e);if(A!==!0)return Lt(A.err.code,A.err.msg,rn(t,i-d.length+A.err.line));if(s===!0)return Lt("InvalidXml","Multiple possible root nodes found.",rn(t,i));e.unpairedTags.indexOf(l)!==-1||r.push({tagName:l,tagStartPos:a}),n=!0}for(i++;i<t.length;i++)if(t[i]==="<")if(t[i+1]==="!"){i++,i=kX(t,i);continue}else if(t[i+1]==="?"){if(i=_X(t,++i),i.err)return i}else break;else if(t[i]==="&"){let A=gOe(t,i);if(A==-1)return Lt("InvalidChar","char '&' is not expected.",rn(t,i));i=A}else if(s===!0&&!PX(t[i]))return Lt("InvalidXml","Extra text at the end",rn(t,i));t[i]==="<"&&i--}}else{if(PX(t[i]))continue;return Lt("InvalidChar","char '"+t[i]+"' is not expected.",rn(t,i))}if(n){if(r.length==1)return Lt("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",rn(t,r[0].tagStartPos));if(r.length>0)return Lt("InvalidXml","Invalid '"+JSON.stringify(r.map(i=>i.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return Lt("InvalidXml","Start tag expected.",1);return!0}o(vB,"validate");function PX(t){return t===" "||t===" "||t===`
`||t==="\r"}o(PX,"isWhiteSpace");function _X(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 Lt("InvalidXml","XML declaration allowed only at the start of the document.",rn(t,e));if(t[e]=="?"&&t[e+1]==">"){e++;break}else continue}return e}o(_X,"readPI");function kX(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}o(kX,"readCommentAndCDATA");var AOe='"',pOe="'";function fOe(t,e){let r="",n="",s=!1;for(;e<t.length;e++){if(t[e]===AOe||t[e]===pOe)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}}o(fOe,"readAttributeStr");var hOe=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function DX(t,e){let r=RB(t,hOe),n={};for(let s=0;s<r.length;s++){if(r[s][1].length===0)return Lt("InvalidAttr","Attribute '"+r[s][2]+"' has no space in starting.",_m(r[s]));if(r[s][3]!==void 0&&r[s][4]===void 0)return Lt("InvalidAttr","Attribute '"+r[s][2]+"' is without value.",_m(r[s]));if(r[s][3]===void 0&&!e.allowBooleanAttributes)return Lt("InvalidAttr","boolean attribute '"+r[s][2]+"' is not allowed.",_m(r[s]));let i=r[s][2];if(!EOe(i))return Lt("InvalidAttr","Attribute '"+i+"' is an invalid name.",_m(r[s]));if(!Object.prototype.hasOwnProperty.call(n,i))n[i]=1;else return Lt("InvalidAttr","Attribute '"+i+"' is repeated.",_m(r[s]))}return!0}o(DX,"validateAttributeString");function mOe(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}o(mOe,"validateNumberAmpersand");function gOe(t,e){if(e++,t[e]===";")return-1;if(t[e]==="#")return e++,mOe(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}o(gOe,"validateAmpersand");function Lt(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}o(Lt,"getErrorObject");function EOe(t){return V_(t)}o(EOe,"validateAttrName");function yOe(t){return V_(t)}o(yOe,"validateTagName");function rn(t,e){let r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}o(rn,"getLineNumberForPosition");function _m(t){return t.startIndex+t[1].length}o(_m,"getPositionFromMatch");var OX={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"},MX={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"
`);let e=new wn("!xml"),r=e,n="";this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let s=this.options,i=new Om(s.processEntities),a=t.length;for(let c=0;c<a;c++)if(t[c]==="<"){let u=t.charCodeAt(c+1);if(u===47){let d=$A(t,">",c,"ClosingTagisnotclosed."),A=t.substring(c+2,d).trim();if(s.removeNSPrefix){let f=A.indexOf(":");f!==-1&&(A=A.substr(f+1))}A=X_(s.transformTagName,A,"",s).tagName,r&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher));let p=this.matcher.getCurrentTag();if(A&&s.unpairedTagsSet.has(A))throw new Error(`Unpaired tag can not be used as closing tag: </${A}>`);p&&s.unpairedTagsSet.has(p)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,r=this.tagsNodeStack.pop(),n="",c=d}else if(u===63){let d=Z_(t,c,!1,"?>");if(!d)throw new Error("PiTagisnotclosed.");n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let A=this.buildAttributesMap(d.tagExp,this.matcher,d.tagName,!0);if(A){let p=A[this.options.attributeNamePrefix+"version"];this.entityDecoder.setXmlVersion(Number(p)||1),i.setXmlVersion(Number(p)||1)}if(!(s.ignoreDeclaration&&d.tagName==="?xml"||s.ignorePiTags)){let p=new wn(d.tagName);p.add(s.textNodeName,""),d.tagName!==d.tagExp&&d.attrExpPresent&&s.ignoreAttributes!==!0&&(p[":@"]=A),this.addChild(r,p,this.readonlyMatcher,c)}c=d.closeIndex+1}else if(u===33&&t.charCodeAt(c+2)===45&&t.charCodeAt(c+3)===45){let d=$A(t,"-->",c+4,"Commentisnotclosed.");if(s.commentPropName){let A=t.substring(c+4,d-2);n=this.saveTextToParentTag(n,r,this.readonlyMatcher),r.add(s.commentPropName,[{[s.textNodeName]:A}])}c=d}else if(u===33&&t.charCodeAt(c+2)===68){let d=i.readDocType(t,c);this.entityDecoder.addInputEntities(d.entities),c=d.i}else if(u===33&&t.charCodeAt(c+2)===91){let d=$A(t,"]]>",c,"CDATAisnotclosed.")-2,A=t.substring(c+9,d);n=this.saveTextToParentTag(n,r,this.readonlyMatcher);let p=this.parseTextData(A,r.tagname,this.readonlyMatcher,!0,!1,!0,!0);p==null&&(p=""),s.cdataPropName?r.add(s.cdataPropName,[{[s.textNodeName]:A}]):r.add(s.textNodeName,p),c=d+2}else{let d=Z_(t,c,s.removeNSPrefix);if(!d){let Q=t.substring(Math.max(0,c-50),Math.min(a,c+50));throw new Error(`readTagExp returned undefined at position ${c}. Context: "${Q}"`)}let A=d.tagName,p=d.rawTagName,f=d.tagExp,h=d.attrExpPresent,g=d.closeIndex;if({tagName:A,tagExp:f}=X_(s.transformTagName,A,f,s),s.strictReservedNames&&(A===s.commentPropName||A===s.cdataPropName||A===s.textNodeName||A===s.attributesGroupName))throw new Error(`Invalid tag name: ${A}`);r&&n&&r.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,r,this.readonlyMatcher,!1));let y=r;y&&s.unpairedTagsSet.has(y.tagname)&&(r=this.tagsNodeStack.pop(),this.matcher.pop());let E=!1;f.length>0&&f.lastIndexOf("/")===f.length-1&&(E=!0,A[A.length-1]==="/"?(A=A.substr(0,A.length-1),f=A):f=f.substr(0,f.length-1),h=A!==f);let C=null,I={},B;B=GOe(p),A!==e.tagname&&this.matcher.push(A,{},B),A!==f&&h&&(C=this.buildAttributesMap(f,this.matcher,A),C&&(I=qOe(C,s))),A!==e.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let N=c;if(this.isCurrentNodeStopNode){let Q="";if(E)c=d.closeIndex;else if(s.unpairedTagsSet.has(A))c=d.closeIndex;else{let ue=this.readStopNodeData(t,p,g+1);if(!ue)throw new Error(`Unexpected end of ${p}`);c=ue.i,Q=ue.tagContent}let D=new wn(A);C&&(D[":@"]=C),D.add(s.textNodeName,Q),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(r,D,this.readonlyMatcher,N)}else{if(E){({tagName:A,tagExp:f}=X_(s.transformTagName,A,f,s));let Q=new wn(A);C&&(Q[":@"]=C),this.addChild(r,Q,this.readonlyMatcher,N),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else if(s.unpairedTagsSet.has(A)){let Q=new wn(A);C&&(Q[":@"]=C),this.addChild(r,Q,this.readonlyMatcher,N),this.matcher.pop(),this.isCurrentNodeStopNode=!1,c=d.closeIndex;continue}else{let Q=new wn(A);if(this.tagsNodeStack.length>s.maxNestedTags)throw new Error("Maximumnestedtagsexceeded");this.tagsNodeStack.push(r),C&&(Q[":@"]=C),this.addChild(r,Q,this.readonlyMatcher,N),r=Q}n="",c=g}}}else n+=t[c];return e.child},"parse
${c}:${decodeURIComponent(i[c])}`}returnn}};varNt=classextendsgu{static{o(this,"StorageSharedKeyCredential")}accountName;accountKey;constructor(e,r){super(),this.accountName=e,this.accountKey=Buffer.from(r,"base64")}create(e,r){returnnewqm(e,r,this)}computeHMACSHA256(e){return(0,fZ.createHmac)("sha256",this.accountKey).update(e,"utf8").digest("base64")}};vartr=so("storage-common");varOs;(function(t){t[t.EXPONENTIAL=0]="EXPONENTIAL",t[t.FIXED=1]="FIXED"})(Os||(Os={}));varUc={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:Os.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void0},IMe=newis("The operation was aborted."),Gm=classextendslo{static{o(this,"StorageRetryPolicy")}retryOptions;constructor(e,r,n=Uc){super(e,r),this.retryOptions={retryPolicyType:n.retryPolicyType?n.retryPolicyType:Uc.retryPolicyType,maxTries:n.maxTries&&n.maxTries>=1?Math.floor(n.maxTries):Uc.maxTries,tryTimeoutInMs:n.tryTimeoutInMs&&n.tryTimeoutInMs>=0?n.tryTimeoutInMs:Uc.tryTimeoutInMs,retryDelayInMs:n.retryDelayInMs&&n.retryDelayInMs>=0?Math.min(n.retryDelayInMs,n.maxRetryDelayInMs?n.maxRetryDelayInMs:Uc.maxRetryDelayInMs):Uc.retryDelayInMs,maxRetryDelayInMs:n.maxRetryDelayInMs&&n.maxRetryDelayInMs>=0?n.maxRetryDelayInMs:Uc.maxRetryDelayInMs,secondaryHost:n.secondaryHost?n.secondaryHost:Uc.secondaryHost}}asyncsendRequest(e){returnthis.attemptSendRequest(e,!1,1)}asyncattemptSendRequest(e,r,n){lets=e.clone(),i=r||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||n%2===1;i||(s.url=HB(s.url,this.retryOptions.secondaryHost)),this.retryOptions.tryTimeoutInMs&&(s.url=Fc(s.url,Ta.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString()));leta;try{if(tr.info(`RetryPolicy: =====> Try=${n}${i?"Primary":"Secondary"}`),a=awaitthis._nextPolicy.sendRequest(s),!this.shouldRetry(i,n,a))returna;r=r||!i&&a.status===404}catch(c){if(tr.error(`RetryPolicy: Caught error, message: ${c.message}, code: ${c.code}`),!this.shouldRetry(i,n,a,c))throwc}returnawaitthis.delay(i,n,e.abortSignal),this.attemptSendRequest(e,r,++n)}shouldRetry(e,r,n,s){if(r>=this.retryOptions.maxTries)returntr.info(`RetryPolicy: Attempt(s) ${r} >= maxTries ${this.retryOptions.maxTries}, no further try.`),!1;leti=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(s){for(letaofi)if(s.name.toUpperCase().includes(a)||s.message.toUpperCase().includes(a)||s.code&&s.code.toString().toUpperCase()===a)returntr.info(`RetryPolicy: Network error ${a} found, will retry.`),!0}if(n||s){leta=n?n.status:s?s.statusCode:0;if(!e&&a===404)returntr.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(a===503||a===500)returntr.info(`RetryPolicy: Will retry for status code ${a}.`),!0}if(n&&n?.status>=400){leta=n.headers.get(ae.X_MS_CopySourceErrorCode);if(a!==void0)switch(a){case"InternalError":case"OperationTimedOut":case"ServerBusy":return!0}}returns?.code==="PARSE_ERROR"&&s?.message.startsWith('Error "Error: Unclosed root tag')?(tr.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0):!1}asyncdelay(e,r,n){lets=0;if(e)switch(this.retryOptions.retryPolicyType){caseOs.EXPONENTIAL:s=Math.min((Math.pow(2,r-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;caseOs.FIXED:s=this.retryOptions.retryDelayInMs;break}elses=Math.random()*1e3;returntr.info(`RetryPolicy: Delay for ${s}ms`),JB(s,n,IMe)}};varHm=class{static{o(this,"StorageRetryPolicyFactory")}retryOptions;constructor(e){this.retryOptions=e}create(e,r){returnnewGm(e,r,this.retryOptions)}};varBMe="storageBrowserPolicy";functionhZ(){return{name:BMe,asyncsendRequest(t,e){returnFe||((t.method==="GET"||t.method==="HEAD")&&(t.url=Fc(t.url,Ta.Parameters.FORCE_BROWSER_NO_CACHE,newDate().getTime().toString())),t.headers.delete(ae.COOKIE),t.headers.delete(ae.CONTENT_LENGTH)),e(t)}}}o(hZ,"storageBrowserPolicy");varbMe="StorageCorrectContentLengthPolicy";functionmZ(){functiont(e){e.body&&(type
`}),c}o(n,"getCanonicalizedHeadersString");function s(i){let a=VB(i.url)||"/",c="";c+=`/${t.accountName}${a}`;let l=zB(i.url),u={};if(l){let d=[];for(let A in l)if(Object.prototype.hasOwnProperty.call(l,A)){let p=A.toLowerCase();u[p]=l[A],d.push(p)}d.sort();for(let A of d)c+=`
`),i=e.computeHMACSHA256(s);return{sasQueryParameters:newSi(t.version,i,n,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:s}}o(v1e,"generateBlobSASQueryParameters20150405");functionP1e(t,e){if(t=Nu(t),!t.identifier&&!(t.permissions&&t.expiresOn))thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));lets;t.permissions&&(t.blobName?s=xo.parse(t.permissions.toString()).toString():s=Qo.parse(t.permissions.toString()).toString());leti=[s||"",t.startsOn?Ue(t.startsOn,!1):"",t.expiresOn?Ue(t.expiresOn,!1):"",Su(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?wi(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(`
`),a=e.computeHMACSHA256(i);return{sasQueryParameters:newSi(t.version,a,s,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:i}}o(P1e,"generateBlobSASQueryParameters20181109");function_1e(t,e){if(t=Nu(t),!t.identifier&&!(t.permissions&&t.expiresOn))thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));lets;t.permissions&&(t.blobName?s=xo.parse(t.permissions.toString()).toString():s=Qo.parse(t.permissions.toString()).toString());leti=[s||"",t.startsOn?Ue(t.startsOn,!1):"",t.expiresOn?Ue(t.expiresOn,!1):"",Su(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?wi(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(`
`),a=e.computeHMACSHA256(i);return{sasQueryParameters:newSi(t.version,a,s,void0,void0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,void0,void0,void0,t.encryptionScope),stringToSign:i}}o(_1e,"generateBlobSASQueryParameters20201206");functionk1e(t,e){if(t=Nu(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));lets;t.permissions&&(t.blobName?s=xo.parse(t.permissions.toString()).toString():s=Qo.parse(t.permissions.toString()).toString());leti=[s||"",t.startsOn?Ue(t.startsOn,!1):"",t.expiresOn?Ue(t.expiresOn,!1):"",Su(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ue(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ue(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.ipRange?wi(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(i);return{sasQueryParameters:newSi(t.version,a,s,void0,void0,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}}o(k1e,"generateBlobSASQueryParametersUDK20181109");functionD1e(t,e){if(t=Nu(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));lets;t.permissions&&(t.blobName?s=xo.parse(t.permissions.toString()).toString():s=Qo.parse(t.permissions.toString()).toString());leti=[s||"",t.startsOn?Ue(t.startsOn,!1):"",t.expiresOn?Ue(t.expiresOn,!1):"",Su(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ue(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ue(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void0,t.correlationId,t.ipRange?wi(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(i);return{sasQueryParameters:newSi(t.version,a,s,void0,void0,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}}o(D1e,"generateBlobSASQueryParametersUDK20200210");functionO1e(t,e){if(t=Nu(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));lets;t.permissions&&(t.blobName?s=xo.parse(t.permissions.toString()).toString():s=Qo.parse(t.permissions.toString()).toString());leti=[s||"",t.startsOn?Ue(t.startsOn,!1):"",t.expiresOn?Ue(t.expiresOn,!1):"",Su(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ue(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ue(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void0,t.correlationId,t.ipRange?wi(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(i);return{sasQueryParameters:newSi(t.version,a,s,void0,void0,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}}o(O1e,"generateBlobSASQueryParametersUDK20201206");functionM1e(t,e){if(t=Nu(t),!t.permissions||!t.expiresOn)thrownewRangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");letr="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));lets;t.permissions&&(t.blobName?s=xo.parse(t.permissions.toString()).toString():s=Qo.parse(t.permissions.toString()).toString());leti=[s||"",t.startsOn?Ue(t.startsOn,!1):"",t.expiresOn?Ue(t.expiresOn,!1):"",Su(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ue(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ue(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void0,t.correlationId,void0,t.delegatedUserObjectId,t.ipRange?wi(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),a=e.computeHMACSHA256(i);return{sasQueryParameters:newSi(t.version,a,s,void0,void0,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}}o(M1e,"generateBlobSASQueryParametersUDK20250705");functionSu(t,e,r){letn=[`/blob/${t}/${e}`];returnr&&n.push(`/${r}`),n.join("")}o(Su,"getCanonicalName");functionNu(t){lete=t.version?t.version:jB;if(t.snapshotTime&&e<"2018-11-09")throwRangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(t.blobName===void0&&t.snapshotTime)throwRangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(t.versionId&&e<"2019-10-10")throwRangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(t.blobName===void0&&t.versionId)throwRangeError("Must provide 'blobName' when providing 'versionId'.");if(t.permissions&&t.permissions.setImmutabilityPolicy&&e<"2020-08-04")throwRangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(t.permissions&&t.permissions.deleteVersion&&e<"2019-10-10")throwRangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(t.permissions&&t.permissions.permanentDelete&&e<"2019-10-10")throwRangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(t.permissions&&t.permissions.tag&&e<"2019-12-12")throwRangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&t.permissions&&(t.permissions.move||t.permissions.execute))throwRangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2021-04-10"&&t.permissions&&t.permissions.filterByTags)throwRangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(e<"2020-02-10"&&(t.preauthorizedAgentObjectId||t.correlationId))throwRangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(t.encryptionScope&&e<"2020-12-06")throwRangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");returnt.version=e,t}o(Nu,"SASSignatureValuesSanityCheckAndAutofill");varrg=class{static{o(this,"BlobLeaseClient")}_leaseId;_url;_containerOrBlobOperation;_isContainer;getleaseId(){returnthis._leaseId}geturl(){returnthis._url}constructor(e,r){letn=e.storageClientContext;this._url=e.url,e.name===void0?(this._isContainer=!0,this._containerOrBlobOperation=n.container):(this._isContainer=!1,this._containerOrBlobOperation=n.blob),r||(r=qA()),this._leaseId=r}asyncacquireLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Ci||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Ci||r.conditions?.tagConditions))thrownewRangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");returnz.withSpan("BlobLeaseClient-acquireLease",r,asyncn=>K(awaitthis._containerOrBlobOperation.acquireLease({abortSignal:r.abortSignal,duration:e,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},proposedLeaseId:this._leaseId,tracingOptions:n.tracingOptions})))}asyncchangeLease(e,r={}){if(this._isContainer&&(r.conditions?.ifMatch&&r.conditions?.ifMatch!==Ci||r.conditions?.ifNoneMatch&&r.conditions?.ifNoneMatch!==Ci||r.conditions?.tagConditions))thrownewRangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");returnz.withSpan("BlobLeaseClient-changeLease",r,asyncn=>{lets=K(awaitthis._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:r.abortSignal,modifiedAccessConditions:{...r.conditions,ifTags:r.conditions?.tagConditions},tracingOptions:n.tracingOptions}));returnthis._leaseId=e,s})}asyncreleaseLease(e={}){if(this._isContainer&&(e.conditions?.ifMat
Ifyouareusingself-hostedrunners,pleasemakesureyourrunnerhasaccesstoallGitHubendpoints: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"}};ap.isNetworkErrorCode=t=>t?["ECONNRESET","ENOTFOUND","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH"].includes(t):!1;var Tu=class extends Error{static{o(this,"UsageError")}constructor(){super(`Cache storage quota has been hit. Unable to upload any new cache entries.
Moreinfoonstoragelimits:https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending`),this.name="UsageError"}};Tu.isUsageErrorMessage=t=>t?t.includes("insufficient usage"):!1;var Ag=class extends Error{static{o(this,"RateLimitError")}constructor(e){super(e),this.name="RateLimitError"}};var kFe=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return o(s,"adopt"),new(r||(r=Promise))(function(i,a){function c(d){try{u(n.next(d))}catch(A){a(A)}}o(c,"fulfilled");function l(d){try{u(n.throw(d))}catch(A){a(A)}}o(l,"rejected");function u(d){d.done?i(d.value):s(d.value).then(c,l)}o(u,"step"),u((n=n.apply(t,e||[])).next())})},tL=class{static{o(this,"UploadProgress")}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);S(`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=o(()=>{this.display(),this.isDone()||(this.timeoutHandle=setTimeout(r,e))},"displayCallback");this.timeoutHandle=setTimeout(r,e)}stopDisplayTimer(){this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=void 0),this.display()}};function vee(t,e,r){return kFe(this,void 0,void 0,function*(){var n;let s=new Fa(t),i=s.getBlockBlobClient(),a=new tL((n=r?.archiveSizeBytes)!==null&&n!==void 0?n:0),c={blockSize:r?.uploadChunkSize,concurrency:r?.uploadConcurrency,maxSingleShotSize:128*1024*1024,onProgress:a.onProgress()};try{a.startDisplayTimer(),b(`BlobClient: ${s.name}:${s.accountName}:${s.containerName}`);let l=yield i.uploadFile(e,c);if(l._response.status>=400)throw new tw(`uploadCacheArchiveSDK: upload failed with status code ${l._response.status}`);return l}catch(l){throw Ve(`uploadCacheArchiveSDK: internal error uploading cache archive: ${l.message}`),l}finally{a.stopDisplayTimer()}})}o(vee,"uploadCacheArchiveSDK");var _ee=w(require("buffer"),1),Ro=w(require("fs"),1),kee=w(require("stream"),1),Dee=w(require("util"),1);var rw=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return o(s,"adopt"),new(r||(r=Promise))(function(i,a){function c(d){try{u(n.next(d))}catch(A){a(A)}}o(c,"fulfilled");function l(d){try{u(n.throw(d))}catch(A){a(A)}}o(l,"rejected");function u(d){d.done?i(d.value):s(d.value).then(c,l)}o(u,"step"),u((n=n.apply(t,e||[])).next())})};function nw(t){return t?t>=200&&t<300:!1}o(nw,"isSuccessStatusCode");function DFe(t){return t?t>=500:!0}o(DFe,"isServerErrorStatusCode");function OFe(t){return t?[St.BadGateway,St.ServiceUnavailable,St.GatewayTimeout].includes(t):!1}o(OFe,"isRetryableStatusCode");function MFe(t){return rw(this,void 0,void 0,function*(){return new Promise(e=>setTimeout(e,t))})}o(MFe,"sleep");function Pee(t,e,r){return rw(this,arguments,void 0,function*(n,s,i,a=xI,c=QI,l=void 0){let u="",d=1;for(;d<=a;){let A,p,f=!1;try{A=yield s()}catch(h){l&&(A=l(h)),f=!0,u=h.message}if(A&&(p=i(A),!DFe(p)))return A;if(p&&(f=OFe(p),u=`Cache service responded with ${p}`),b(`${n} - Attempt ${d} of ${a} failed with error: ${u}`),!f){b(`${n} - Error is not retryable`);break}yield MFe(c),d++}throw Error(`${n} failed: ${u}`)})}o(Pee,"retry");function pg(t,e){return rw(this,arguments,void 0,function*(r,n,s=xI,i=QI){return yield Pee(r,n,a=>a.statusCode,s,i,a=>{if(a instanceof eo)return{statusCode:a.statusCode,result:null,headers:{},error:a}})})}o(pg,"retryTypedResponse");function cp(t,e){return rw(this,arguments,void 0,function*(r,n,s=xI,i=QI){return yield Pee(r,n,a=>a.message.statusCode,s,i)})}o(cp,"retryHttpClientResponse");var qs=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a
Othercacheswithsimilarkey:`);for(let c of i?.artifactCaches||[])b(`CacheKey:${c?.cacheKey},CacheVersion:${c?.cacheVersion},CacheScope:${c?.scope},CacheCreated:${c?.creationTime}`)}}})}o(zFe,"printCachesListForDiagnostics");function iL(t,e,r){return Qn(this,void 0,void 0,function*(){let n=new zee.URL(t),s=Fee(r);n.hostname.endsWith(".blob.core.windows.net")?s.useAzureSdk?yield Mee(t,e,s):s.concurrentBlobDownloads?yield Oee(t,e,s):yield iw(t,e):yield iw(t,e)})}o(iL,"downloadCache");function $ee(t,e,r){return Qn(this,void 0,void 0,function*(){let n=sL(),s=PA(e,r?.compressionMethod,r?.enableCrossOsArchive),i={key:t,version:s,cacheSize:r?.cacheSize};return yield pg("reserveCache",()=>Qn(this,void 0,void 0,function*(){return n.postJson(hg("caches"),i)}))})}o($ee,"reserveCache");function Vee(t,e){return`bytes${t}-${e}/*`}o(Vee,"getContentRange");function JFe(t,e,r,n,s){return Qn(this,void 0,void 0,function*(){b(`Uploading chunk of size ${s-n+1} bytes at offset ${n} with content range: ${Vee(n,s)}`);let i={"Content-Type":"application/octet-stream","Content-Range":Vee(n,s)},a=yield cp(`uploadChunk (start: ${n}, end: ${s})`,()=>Qn(this,void 0,void 0,function*(){return t.sendStream("PATCH",e,r(),i)}));if(!nw(a.message.statusCode))throw new Error(`Cache service responded with ${a.message.statusCode} during upload chunk.`)})}o(JFe,"uploadChunk");function $Fe(t,e,r,n){return Qn(this,void 0,void 0,function*(){let s=Zi(r),i=hg(`caches/${e.toString()}`),a=lp.openSync(r,"r"),c=rL(n),l=vP("uploadConcurrency",c.uploadConcurrency),u=vP("uploadChunkSize",c.uploadChunkSize),d=[...new Array(l).keys()];b("Awaiting all uploads");let A=0;try{yield Promise.all(d.map(()=>Qn(this,void 0,void 0,function*(){for(;A<s;){let p=Math.min(s-A,u),f=A,h=A+p-1;A+=u,yield JFe(t,i,()=>lp.createReadStream(r,{fd:a,start:f,end:h,autoClose:!1}).on("error",g=>{throw new Error(`Cache upload failed because file read failed with ${g.message}`)}),f,h)}})))}finally{lp.closeSync(a)}})}o($Fe,"uploadFile");function YFe(t,e,r){return Qn(this,void 0,void 0,function*(){let n={size:r};return yield pg("commitCache",()=>Qn(this,void 0,void 0,function*(){return t.postJson(hg(`caches/${e.toString()}`),n)}))})}o(YFe,"commitCache");function oL(t,e,r,n){return Qn(this,void 0,void 0,function*(){if(rL(n).useAzureSdk){if(!r)throw new Error("Azure Storage SDK can only be used when a signed URL is provided.");yield vee(r,e,n)}else{let i=sL();b("Upload cache"),yield $Fe(i,t,e,n),b("Commiting cache");let a=Zi(e);S(`Cache Size: ~${Math.round(a/(1024*1024))} MB (${a} B)`);let c=yield YFe(i,t,a);if(!nw(c.statusCode))throw new Error(`Cache service responded with ${c.statusCode} during commit cache.`);S("Cache saved successfully")}})}o(oL,"saveCache");var qte=w(kte(),1),Gt=w(qt(),1),ds=w(qt(),1),Du=w(qt(),1),Ou=w(qt(),1),Mu=w(qt(),1);var e1=w(qt(),1),t1=w(qt(),1),Lte=w(qt(),1),Fte=w(qt(),1),Ute=w(qt(),1);var KL=w(qt(),1),XL=w(qt(),1),Dte=w(qt(),1),Ote=w(qt(),1),Mte=w(qt(),1);var ZL=class extends Mte.MessageType{static{o(this,"CacheScope$Type")}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,Ote.MESSAGE_TYPE,{enumerable:!1,value:this}),e!==void 0&&(0,Dte.reflectionMergePartial)(this,r,e),r}internalBinaryRead(e,r,n,s){let i=s??this.create(),a=e.pos+r;for(;e.pos<a;){let[c,l]=e.tag();switch(c){case 1:i.scope=e.string();break;case 2:i.permission=e.int64().toString();break;default:let u=n.readUnknownField;if(u==="throw")throw new globalThis.Error(`Unknown field ${c} (wire type ${l}) for ${this.typeName}`);let d=e.skip(l);u!==!1&&(u===!0?XL.UnknownFieldHandler.onRead:u)(this.typeName,i,c,l,d)}}return i}internalBinaryWrite(e,r,n){e.scope!==""&&r.tag(1,KL.WireType.LengthDelimited).string(e.scope),e.permission!=="0"&&r.tag(2,KL.WireType.Varint).int64(e.permission);let s=n.writeUnknownFields;return s!==!1&&(s==!0?XL.UnknownFieldHandler.onWrite:s)(this.typeName,e,r),r}},Jw=new ZL;var r1=class extends Ute.Mess
`));let n=yield g1(r,"create");yield E1(n,t)})}o(C1,"createTar");var Np=function(t,e,r,n){function s(i){return i instanceof r?i:new r(function(a){a(i)})}return o(s,"adopt"),new(r||(r=Promise))(function(i,a){function c(d){try{u(n.next(d))}catch(A){a(A)}}o(c,"fulfilled");function l(d){try{u(n.throw(d))}catch(A){a(A)}}o(l,"rejected");function u(d){d.done?i(d.value):s(d.value).then(c,l)}o(u,"step"),u((n=n.apply(t,e||[])).next())})},Qi=class t extends Error{static{o(this,"ValidationError")}constructor(e){super(e),this.name="ValidationError",Object.setPrototypeOf(this,t.prototype)}},Lu=class t extends Error{static{o(this,"ReserveCacheError")}constructor(e){super(e),this.name="ReserveCacheError",Object.setPrototypeOf(this,t.prototype)}},I1="cache write denied:",Sp=class t extends Lu{static{o(this,"CacheWriteDeniedError")}constructor(e){super(e),this.name="CacheWriteDeniedError",Object.setPrototypeOf(this,t.prototype)}},jw=class t extends Error{static{o(this,"FinalizeCacheError")}constructor(e){super(e),this.name="FinalizeCacheError",Object.setPrototypeOf(this,t.prototype)}};function zte(t){if(!t||t.length===0)throw new Qi("Path Validation Error: At least one directory or file path is required")}o(zte,"checkPaths");function B1(t){if(t.length>512)throw new Qi(`Key Validation Error: ${t} cannot be larger than 512 characters.`);if(!/^[^,]*$/.test(t))throw new Qi(`Key Validation Error: ${t} cannot contain commas.`)}o(B1,"checkKey");function b1(){return fg()==="v2"?!!process.env.ACTIONS_RESULTS_URL:!!process.env.ACTIONS_CACHE_URL}o(b1,"isFeatureAvailable");function Jte(t,e,r,n){return Np(this,arguments,void 0,function*(s,i,a,c,l=!1){let u=fg();return b(`Cache service version: ${u}`),zte(s),u==="v2"?yield lqe(s,i,a,c,l):yield cqe(s,i,a,c,l)})}o(Jte,"restoreCache");function cqe(t,e,r,n){return Np(this,arguments,void 0,function*(s,i,a,c,l=!1){a=a||[];let u=[i,...a];if(b("Resolved Keys:"),b(JSON.stringify(u)),u.length>10)throw new Qi("Key Validation Error: Keys are limited to a maximum of 10.");for(let p of u)B1(p);let d=yield pm(),A="";try{let p=yield Jee(u,s,{compressionMethod:d,enableCrossOsArchive:l});if(!p?.archiveLocation)return;if(c?.lookupOnly)return S("Lookup only - skipping download"),p.cacheKey;A=vg.join(yield dm(),vc(d)),b(`Archive Path: ${A}`),yield iL(p.archiveLocation,A,c),Ia()&&(yield Tg(A,d));let f=Zi(A);return S(`Cache Size: ~${Math.round(f/(1024*1024))} MB (${f} B)`),yield y1(A,d),S("Cache restored successfully"),p.cacheKey}catch(p){let f=p;if(f.name===Qi.name)throw p;f instanceof eo&&typeof f.statusCode=="number"&&f.statusCode>=500?CA(`Failed to restore: ${p.message}`):Ve(`Failed to restore: ${p.message}`)}finally{try{yield Am(A)}catch(p){b(`Failed to delete archive: ${p}`)}}})}o(cqe,"restoreCacheV1");function lqe(t,e,r,n){return Np(this,arguments,void 0,function*(s,i,a,c,l=!1){c=Object.assign(Object.assign({},c),{useAzureSdk:!0}),a=a||[];let u=[i,...a];if(b("Resolved Keys:"),b(JSON.stringify(u)),u.length>10)throw new Qi("Key Validation Error: Keys are limited to a maximum of 10.");for(let A of u)B1(A);let d="";try{let A=m1(),p=yield pm(),f={key:i,restoreKeys:a,version:PA(s,p,l)},h=yield A.GetCacheEntryDownloadURL(f);if(!h.ok){b(`Cache not found for version ${f.version} of keys: ${u.join(", ")}`);return}if(f.key!==h.matchedKey?S(`Cache hit for restore-key: ${h.matchedKey}`):S(`Cache hit for: ${h.matchedKey}`),c?.lookupOnly)return S("Lookup only - skipping download"),h.matchedKey;d=vg.join(yield dm(),vc(p)),b(`Archive path: ${d}`),b(`Starting download of archive to: ${d}`),yield iL(h.signedDownloadUrl,d,c);let y=Zi(d);return S(`Cache Size: ~${Math.round(y/(1024*1024))} MB (${y} B)`),Ia()&&(yield Tg(d,p)),yield y1(d,p),S("Cache restored successfully"),h.matchedKey}catch(A){let p=A;if(p.name===Qi.name)throw A;p instanceof eo&&typeof p.statusCode=="number"&&p.statusCode>=500?CA(`Failed to restore: ${A.message}`):Ve(`Failed to restore: ${A.message}`)}finally{try{d&&(yield Am(d))}catch(A){b(`Failed to delete archive: ${A}`)}}})}o(lqe,"restoreCacheV2");function w1(t,e,r){return Np(this,arguments,void 0,function*(n,s,i,a=!1)
`,a).length:A,u?(c===null?0:c.length)+l.length:0,u?l.length+A:0);return p<f},"__needMoreData"),parse:o(function(n,s,i,a){let{bom:c,comment_no_infix:l,delimiter_auto:u,encoding:d,from_line:A,ltrim:p,max_record_size:f,raw:h,relax_quotes:g,rtrim:y,skip_empty_lines:E,to:C,to_line:I}=this.options,{comment:B,escape:N,quote:Q,record_delimiter:D}=this.options,{bomSkipped:ue,delimiterDiscovered:Ne,delimiterBufPrevious:_e,rawBuffer:qe,escapeIsQuote:Ce}=this.state;if(!Ne&&u){let Ge;if(_e===void 0?Ge=n:_e!==void 0&&n===void 0?Ge=_e:Ge=Buffer.concat([_e,n]),n=void 0,s||Ge.length>u.size)this.options.delimiter=[Buffer.from(Zie(Ge,this.options.delimiter_auto))],this.state.previousBuf=Ge,this.state.delimiterBufPrevious=void 0,this.state.delimiterDiscovered=!0;else{this.state.delimiterBufPrevious=Ge;return}}let{previousBuf:Ze}=this.state,de;if(Ze===void 0)if(n===void 0){a();return}else de=n;else Ze!==void 0&&n===void 0?de=Ze:de=Buffer.concat([Ze,n]);if(ue===!1)if(c===!1)this.state.bomSkipped=!0;else if(de.length<3){if(s===!1){this.state.previousBuf=de;return}}else{for(let Ge in Gp)if(Gp[Ge].compare(de,0,Gp[Ge].length)===0){let Di=Gp[Ge].length;this.state.bufBytesStart+=Di,de=de.slice(Di);let nc=qp({...this.original_options,encoding:Ge});for(let Bt in nc)this.options[Bt]=nc[Bt];({comment:B,escape:N,quote:Q}=this.options);break}this.state.bomSkipped=!0}let qr=de.length,J;for(J=0;J<qr&&!this.__needMoreData(J,qr,s);J++){if(this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1),I!==-1&&this.info.lines>I){this.state.stop=!0,a();return}this.state.quoting===!1&&D.length===0&&this.__autoDiscoverRecordDelimiter(de,J)&&(D=this.options.record_delimiter);let Ge=de[J];if(h===!0&&qe.append(Ge),(Ge===_$e||Ge===k$e)&&this.state.wasRowDelimiter===!1&&(this.state.wasRowDelimiter=!0),this.state.escaping===!0)this.state.escaping=!1;else{if(N!==null&&this.state.quoting===!0&&this.__isEscape(de,J,Ge)&&J+N.length<qr)if(Ce){if(this.__isQuote(de,J+N.length)){this.state.escaping=!0,J+=N.length-1;continue}}else{this.state.escaping=!0,J+=N.length-1;continue}if(this.state.commenting===!1&&this.__isQuote(de,J))if(this.state.quoting===!0){let Bt=de[J+Q.length],Oi=y&&this.__isCharTrimable(de,J+Q.length),Fn=B!==null&&this.__compareBytes(B,de,J+Q.length,Bt),El=this.__isDelimiter(de,J+Q.length,Bt),ME=D.length===0?this.__autoDiscoverRecordDelimiter(de,J+Q.length):this.__isRecordDelimiter(Bt,de,J+Q.length);if(N!==null&&this.__isEscape(de,J,Ge)&&this.__isQuote(de,J+N.length))J+=N.length-1;else if(!Bt||El||ME||Fn||Oi){this.state.quoting=!1,this.state.wasQuoting=!0,J+=Q.length-1;continue}else if(g===!1){let nG=this.__error(new be("CSV_INVALID_CLOSING_QUOTE",["Invalid Closing Quote:",`got "${String.fromCharCode(Bt)}"`,`at line ${this.info.lines}`,"instead of delimiter, record delimiter, trimable character","(if activated) or comment"],this.options,this.__infoField()));if(nG!==void 0)return nG}else this.state.quoting=!1,this.state.wasQuoting=!0,this.state.field.prepend(Q),J+=Q.length-1}else if(this.state.field.length!==0){if(g===!1){let Bt=this.__infoField(),Oi=Object.keys(Gp).map(El=>Gp[El].equals(this.state.field.toString())?El:!1).filter(Boolean)[0],Fn=this.__error(new be("INVALID_OPENING_QUOTE",["Invalid Opening Quote:",`a quote is found on field ${JSON.stringify(Bt.column)} at line ${Bt.lines}, value is ${JSON.stringify(this.state.field.toString(d))}`,Oi?`(${Oi} bom)`:void 0],this.options,Bt,{field:this.state.field}));if(Fn!==void 0)return Fn}}else{this.state.quoting=!0,J+=Q.length-1;continue}if(this.state.quoting===!1){let Bt=this.__isRecordDelimiter(Ge,de,J);if(Bt!==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(),J+=Bt-1;continue}if(E===!0&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0){this.info.empty_lines++,J+=Bt-1;continue}this.info.bytes=this.state.bufBytesSt
`)}o(NYe,"_buildMessageForResponseErrors");var xYe=class extends Error{static{o(this,"GraphqlResponseError")}constructor(t,e,r){super(NYe(r)),this.request=t,this.headers=e,this.response=r,this.errors=r.errors,this.data=r.data,Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}name="GraphqlResponseError";errors;data},QYe=["method","baseUrl","url","headers","request","query","mediaType","operationName"],RYe=["query","method","url"],qoe=/\/api\/v3\/?$/;function TYe(t,e,r){if(r){if(typeof e=="string"&&"query"in r)return Promise.reject(new Error('[@octokit/graphql] "query" cannot be used as variable name'));for(let a in r)if(RYe.includes(a))return Promise.reject(new Error(`[@octokit/graphql] "${a}" cannot be used as variable name`))}let n=typeof e=="string"?Object.assign({query:e},r):e,s=Object.keys(n).reduce((a,c)=>QYe.includes(c)?(a[c]=n[c],a):(a.variables||(a.variables={}),a.variables[c]=n[c],a),{}),i=n.baseUrl||t.endpoint.DEFAULTS.baseUrl;return qoe.test(i)&&(s.url=i.replace(qoe,"/api/graphql")),t(s).then(a=>{if(a.data.errors){let c={};for(let l of Object.keys(a.headers))c[l]=a.headers[l];throw new xYe(s,c,a.data)}return a.data.data})}o(TYe,"graphql");function iU(t,e){let r=t.defaults(e);return Object.assign(o((s,i)=>TYe(r,s,i),"newApi"),{defaults:iU.bind(null,r),endpoint:r.endpoint})}o(iU,"withDefaults");var DPt=iU(nE,{headers:{"user-agent":`octokit-graphql.js/${SYe} ${Xc()}`},method:"POST",url:"/graphql"});function Goe(t){return iU(t,{method:"POST",url:"/graphql"})}o(Goe,"withCustomRequest");var oU="(?:[a-zA-Z0-9_-]+)",Hoe="\\.",Voe=new RegExp(`^${oU}${Hoe}${oU}${Hoe}${oU}$`),vYe=Voe.test.bind(Voe);async function PYe(t){let e=vYe(t),r=t.startsWith("v1.")||t.startsWith("ghs_"),n=t.startsWith("ghu_");return{type:"token",token:t,tokenType:e?"app":r?"installation":n?"user-to-server":"oauth"}}o(PYe,"auth");function _Ye(t){return t.split(/\./).length===3?`bearer ${t}`:`token ${t}`}o(_Ye,"withAuthorizationPrefix");async function kYe(t,e,r,n){let s=e.endpoint.merge(r,n);return s.headers.authorization=_Ye(t),e(s)}o(kYe,"hook");var zoe=o(function(e){if(!e)throw new Error("[@octokit/auth-token] No token passed to createTokenAuth");if(typeof e!="string")throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string");return e=e.replace(/^(token|bearer) +/i,""),Object.assign(PYe.bind(null,e),{hook:kYe.bind(null,e)})},"createTokenAuth2");var aU="7.0.6";var Joe=o(()=>{},"noop"),DYe=console.warn.bind(console),OYe=console.error.bind(console);function MYe(t={}){return typeof t.debug!="function"&&(t.debug=Joe),typeof t.info!="function"&&(t.info=Joe),typeof t.warn!="function"&&(t.warn=DYe),typeof t.error!="function"&&(t.error=OYe),t}o(MYe,"createLogger");var $oe=`octokit-core.js/${aU} ${Xc()}`,lS=class{static{o(this,"Octokit")}static VERSION=aU;static defaults(e){return class extends this{static{o(this,"OctokitWithDefaults")}constructor(...n){let s=n[0]||{};if(typeof e=="function"){super(e(s));return}super(Object.assign({},e,s,s.userAgent&&e.userAgent?{userAgent:`${s.userAgent} ${e.userAgent}`}:null))}}}static plugins=[];static plugin(...e){let r=this.plugins;return class extends this{static{o(this,"NewOctokit")}static plugins=r.concat(e.filter(s=>!r.includes(s)))}}constructor(e={}){let r=new Coe.Collection,n={baseUrl:nE.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:r.bind(null,"request")}),mediaType:{previews:[],format:""}};if(n.headers["user-agent"]=e.userAgent?`${e.userAgent} ${$oe}`:$oe,e.baseUrl&&(n.baseUrl=e.baseUrl),e.previews&&(n.mediaType.previews=e.previews),e.timeZone&&(n.headers["time-zone"]=e.timeZone),this.request=nE.defaults(n),this.graphql=Goe(this.request).defaults(n),this.log=MYe(e.log),this.hook=r,e.authStrategy){let{authStrategy:i,...a}=e,c=i(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:a},e.auth));r.wrap("request",c.hook),this.auth=c}else if(!e.auth)this.auth=async()=>({type:"unauthenticated"});else{let i=zoe(e.auth);r.wrap("request",i.hook),this.auth=i}let s=this.constructor;for(let i=0;i<s.plugins.length;++i)
More info: ${l.url}`);let f=l.range&&l.range.length>0?l.range[0]?.start.line:void 0,h=!1;for(let g of a)if(g.remote||g.path.endsWith(u)&&g.content===d){c.push({title:A,message:p,file:g.path,startLine:f}),h=!0;break}h||b(`Buildx.convertWarningsToGitHubAnnotations: skipping warning without matching Dockerfile ${u}: ${A}`)}return c}};var el=class t{static{o(this,"Builder")}buildx;constructor(e){this.buildx=e?.buildx||new Pe}async exists(e){let r=await this.buildx.getCommand(["inspect",e]),n=await Y.getExecOutput(r.command,r.args,{ignoreReturnCode:!0,silent:!0}).then(s=>s.stderr.length>0&&s.exitCode!=0?(b(`Builder.exists cmd err: ${s.stderr.trim()}`),!1):s.exitCode==0).catch(s=>(b(`Builder.exists error: ${s}`),!1));return b(`Builder.exists: ${n}`),n}async inspect(e){let r=Object.assign({},process.env,{DEBUG:"1"}),n=["inspect"];e&&n.push(e);let s=await this.buildx.getCommand(n);return await Y.getExecOutput(s.command,s.args,{ignoreReturnCode:!0,silent:!0,env:r}).then(i=>{if(i.stderr.length>0&&i.exitCode!=0)throw new Error(i.stderr.trim());return t.parseInspect(i.stdout)})}static parseInspect(e){let r={nodes:[]},n,s={},i,a,c;for(let l of e.trim().split(`
`),s.files[c]+=l.replace(/^\s>\s?/,""));break}}}}returna&&s.devices&&s.devices.push(a),i&&s.gcPolicy&&s.gcPolicy.push(i),s.name&&r.nodes.push(s),r}};varWu=w(require("fs"),1),yU=w(require("path"),1);varpS=classt{static{o(this,"Build")}buildx;iidFilename;metadataFilename;constructor(e){this.buildx=e?.buildx||newPe,this.iidFilename=`build-iidfile-${Me.generateRandomString()}.txt`,this.metadataFilename=`build-metadata-${Me.generateRandomString()}.json`}asyncgitContext(e){letr=newSet(["ref","checksum","subdir"]),n=e?.attrs||{},s=Object.entries(n).filter(([f])=>!r.has(f)),i=Me.parseBoolOrDefault(n["fetch-by-commit"]),a=e?.ref||n.ref||un.ref;a.startsWith("refs/")?a.startsWith("refs/pull/")&&Me.parseBoolOrDefault(process.env.DOCKER_DEFAULT_GIT_CONTEXT_PR_HEAD_REF)&&(a=a.replace(/\/merge$/g,"/head")):a=`refs/heads/${a}`;letc=`${je.serverURL}/${un.repo.owner}/${un.repo.repo}.git`,l=e?.checksum||n.checksum,u=e?.subdir||n.subdir,d=e?.format;if(!d){if(d="fragment",s.length>0)d="query";elseif(Me.parseBoolOrDefault(process.env.BUILDX_SEND_GIT_QUERY_AS_INPUT))try{awaitthis.buildx.versionSatisfies(">=0.29.0")&&(d="query")}catch{}}letA=un.sha||a;a.startsWith("refs/pull/")&&a.endsWith("/head")&&(A=typeofun.payload.pull_request?.head?.sha=="string"?un.payload.pull_request.head.sha:a);letp=l||A;if(d==="query"){letf=[`ref=${i||l?a:p}`],h=i?p:l;h&&f.push(`checksum=${h}`),u&&u!=="."&&f.push(`subdir=${u}`);for(let[g,y]ofs)f.push(`${g}=${y}`);return`${c}?${f.join("&")}`}return`${c}#${p}${u&&u!=="."?`:${u}`:""}`}getImageIDFilePath(){returnyU.default.join(Oe.tmpDir(),this.iidFilename)}resolveImageID(){lete=this.getImageIDFilePath();if(Wu.default.existsSync(e))returnWu.default.readFileSync(e,{encoding:"utf-8"}).trim()}getMetadataFilePath(){returnyU.default.join(Oe.tmpDir(),this.metadataFilename)}resolveMetadata(){lete=this.getMetadataFilePath();if(!Wu.default.existsSync(e))return;letr=Wu.default.readFileSync(e,{encoding:"utf-8"}).trim();if(r!=="null")returnJSON.parse(r)}resolveRef(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.ref"ine)returne["buildx.build.ref"]}resolveProvenance(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.provenance"ine)returne["buildx.build.provenance"]}resolveWarnings(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.warnings"ine)returne["buildx.build.warnings"]}resolveDigest(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"containerimage.digest"ine)returne["containerimage.digest"]}staticresolveSecretString(e){let[r,n]=t.resolveSecret(e,{redact:!0});return`id=${r},src=${n}`}staticresolveSecretFile(e){let[r,n]=t.resolveSecret(e,{asFile:!0});return`id=${r},src=${n}`}staticresolveSecretEnv(e){let[r,n]=t.parseSecretKvp(e);return`id=${r},env=${n}`}staticresolveSecret(e,r){let[n,s]=t.parseSecretKvp(e,r?.redact);if(r?.asFile){if(!Wu.default.existsSync(s))thrownewError(`secret file ${s} not found`);return[n,s]}leti=Oe.tmpName({tmpdir:Oe.tmpDir()});returnWu.default.writeFileSync(i,s),[n,i]}staticgetProvenanceInput(e){letr=Pr(e);if(!r)returnr;try{returnZl(e)?`builder-id=${je.workflowRunURL(!0)}`:"false"}catch{returnt.resolveProvenanceAttrs(r)}}staticresolveProvenanceAttrs(e){if(!e)return`builder-id=${je.workflowRunURL(!0)}`;letr=ms(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(letnofr)if(n.toString().split(/(?<=^[^=]+?)=/).map(i=>i.trim())[0]=="builder-id")returne;return`${e},builder-id=${je.workflowRunURL(!0)}`}staticresolveCacheToAttrs(e,r){if(!e)returne;letn="registry",s="",i="",a=ms(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(letcofa){letl=c.toString().split(/(?<=^[^=]+?)=/).map(u=>u.trim());l[0]==="type"?n=l[1]:l[0]==="repository"?s=l[1]:l[0]==="ghtoken"&&(i=l[1])}returnn==="gha"&&(s||(e=`${e},repository=${je.repository}`),!i&&r&&(e=`${e},ghtoken=${r}`)),e}statichasLocalExporter(e){returnt.hasExporterType("local",e)}statichasTarExporter(e){returnt.hasExporterType("tar",e)}statichasDockerExporter(e,r){returnr||t.hasExporterType("docker",e)}statichasExporterType(e,r){letn=ms(r.join(`
`),{delimiter:",",trim:!0,columns:!1,relaxColumnCount:!0});for(letsofn){if(s.length==1&&!s[0].startsWith("type="))returne=="local";for(let[i,a]ofs.map(c=>c.split("=").map(l=>l.trim())))if(i=="type"&&a==e)return!0}return!1}statichasAttestationType(e,r){letn=ms(r,{delimiter:",",trim:!0,columns:!1,relaxColumnCount:!0});for(letsofn)for(let[i,a]ofs.map(c=>c.split("=").map(l=>l.trim())))if(i=="type"&&a==e)return!0;return!1}staticresolveAttestationAttrs(e){letr=ms(e,{delimiter:",",trim:!0,columns:!1,relaxColumnCount:!0}),n=[];for(letsofr)for(letiofs)try{leta=Me.parseBool(i);n.push(`disabled=${!a}`)}catch{n.push(i)}returnn.join(",")}statichasGitAuthTokenSecret(e,r){for(letnofe){if(r&&n.startsWith(`GIT_AUTH_TOKEN.${r}=`))return!0;if(n.startsWith("GIT_AUTH_TOKEN="))return!0}return!1}staticparseSecretKvp(e,r){letn=e.indexOf("="),s=e.substring(0,n),i=e.substring(n+1);if(s.length==0||i.length==0)thrownewError(`${e} is not a valid secret`);returnr&&$i(i),[s,i]}};varCU=w(require("fs"),1),nae=w(require("path"),1);varfS=classt{static{o(this,"Bake")}buildx;metadataFilename;constructor(e){this.buildx=e?.buildx||newPe,this.metadataFilename=`bake-metadata-${Me.generateRandomString()}.json`}getMetadataFilePath(){returnnae.default.join(Oe.tmpDir(),this.metadataFilename)}resolveMetadata(){lete=this.getMetadataFilePath();if(!CU.default.existsSync(e))return;letr=CU.default.readFileSync(e,{encoding:"utf-8"}).trim();if(r!=="null")returnJSON.parse(r)}resolveRefs(e){if(!e&&(e=this.resolveMetadata(),!e))return;letr=newArray;for(letnine)"buildx.build.ref"ine[n]&&r.push(e[n]["buildx.build.ref"]);returnr.length>0?r:void0}resolveWarnings(e){if(!(!e&&(e=this.resolveMetadata(),!e))&&"buildx.build.warnings"ine)returne["buildx.build.warnings"]}asyncgetDefinition(e,r){r=r||{ignoreReturnCode:!0},r.ignoreReturnCode=!0,r.env=Object.assign({},process.env,r.env||{},e.githubToken?{BUILDX_BAKE_GIT_AUTH_TOKEN:e.githubToken}:{});letn=["bake"],s,i=[],a=[...e.files||[],e.source];if(a){for(letlofa.map(u=>u?u.trim():""))if(l.length!=0){if(!Me.isValidRef(l)){i.push(l);continue}if(s)thrownewError("Only one remote bake definition can be defined");s=l}}s&&n.push(s);for(letlofi)n.push("--file",l);if(e.overrides)for(letlofe.overrides)n.push("--set",l);if(e.vars)for(letlofe.vars)n.push("--var",l);if(e.allow)for(letlofe.allow)n.push("--allow",l);e.call&&n.push("--call",e.call),e.load&&n.push("--load"),e.noCache&&n.push("--no-cache"),e.provenance&&n.push("--provenance",e.provenance),e.push&&n.push("--push"),e.sbom&&n.push("--sbom",e.sbom);letc=awaitthis.buildx.getCommand([...n,"--print",...e.targets||[]]);returnawaitY.getExecOutput(c.command,c.args,r).then(l=>{if(l.stderr.length>0&&l.exitCode!=0)thrownewError(`cannot parse bake definitions: ${l.stderr.match(/(.*)\s*$/)?.[0]?.trim()??"unknown error"}`);returnt.parseDefinition(l.stdout.trim())})}staticparseDefinition(e){letr=JSON.parse(e);for(letninr.target){lets=r.target[n];s.attest&&Array.isArray(s.attest)&&(s.attest=s.attest.map(i=>t.parseAttestEntry(i))),s["cache-from"]&&Array.isArray(s["cache-from"])&&(s["cache-from"]=s["cache-from"].map(i=>t.parseCacheEntry(i))),s["cache-to"]&&Array.isArray(s["cache-to"])&&(s["cache-to"]=s["cache-to"].map(i=>t.parseCacheEntry(i))),s.output&&Array.isArray(s.output)&&(s.output=s.output.map(i=>t.parseExportEntry(i))),s.secret&&Array.isArray(s.secret)&&(s.secret=s.secret.map(i=>t.parseSecretEntry(i))),s.ssh&&Array.isArray(s.ssh)&&(s.ssh=s.ssh.map(i=>t.parseSSHEntry(i)))}returnr}staticparseAttestEntry(e){if(typeofe!="string")returne;letr={type:""},n=ms(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];for(letsofn){let[i,a]=s.toString().split(/(?<=^[^=]+?)=/).map(c=>c.trim());switch(i){case"type":r.type=a;break;case"disabled":r.disabled=Me.parseBool(a);break;default:r[i]=a}}returnr}staticparseCacheEntry(e){if(typeofe!="string")returne;letr={type:""},n=ms(e,{relaxColumnCount:!0,skipEmptyLines:!0})[0];if(n.length===1&&!n[0].includes("="))returnr.type="registry",r.ref=n[0],r;for(letsofn){let[i,a]=s.toString().s
`).map(i=>i.trim()).filter(i=>i.length>0);if(s)return`refs/tags/${s}`;throw new Error("Cannot infer ref from detached HEAD")}static async findDetachedTagRef(e,r){let s=(await t.exec(["for-each-ref","--format=%(refname)","--points-at","HEAD","refs/tags/"])).split(`
`).map(i=>i.trim()).filter(i=>i.length>0).sort((i,a)=>a.length-i.length);for(let i of s){let a=`tag:${i.slice(10)}`;if(e===a||e.startsWith(`${a},`))return i}if(s.length===1)return s[0];throw new Error(`Cannotfinddetachedtagrefin"${r}"`)}static async findContainingRef(e){let r=await t.exec(["for-each-ref","--format=%(refname)","--contains","HEAD","--sort=-committerdate",e]),[n]=r.split(`
${h}`)}elsethrownewError(`Cosign attest-blob command failed with: ${A.stderr.trim().split(/\r?\n/).filter(h=>h.length>0).pop()??"unknown error"}`);letf=t.parseBundle((0,wf.bundleFromJSON)(JSON.parse(Ko.default.readFileSync(c,{encoding:"utf-8"}))));S("Provenance blob signed for:");for(lethofl){let[g,y]=Object.entries(h.digest)[0]||[];S(` - ${h.name} (${g}:${y})`)}f.tlogID&&S(`Attestation signature uploaded to Rekor transparency log: ${pd}?logIndex=${f.tlogID}`),S(`Sigstore bundle written to: ${c}`),r[i]={...f,bundlePath:c,subjects:l}})}catch(n){thrownewError(`Signing BuildKit provenance blobs failed: ${n.message}`)}returnr}asyncverifySignedArtifacts(e,r){letn={};if(!awaitthis.cosign.isAvailable())thrownewError("Cosign is required to verify signed artifacts");for(let[s,i]ofObject.entries(e)){leta=Xo.default.dirname(s);awaitit(`Verifying signature bundle ${i.bundlePath}`,async()=>{for(letcofi.subjects){letl=Xo.default.join(a,c.name);S(`Verifying signed artifact ${l}`);letu=["verify-blob-attestation","--new-bundle-format","--certificate-oidc-issuer","https://token.actions.githubusercontent.com","--certificate-identity-regexp",r.certificateIdentityRegexp,"--type",r.predicateType??Eue];(r.noTransparencyLog||!i.tlogID)&&u.push("--use-signed-timestamps","--insecure-ignore-tlog");letd=awaitY.getExecOutput(this.cosign.binPath,[...u,"--bundle",i.bundlePath,l],{ignoreReturnCode:!0});if(d.stderr.length>0&&d.exitCode!=0)thrownewError(d.stderr);n[l]={bundlePath:i.bundlePath,cosignArgs:u}}})}returnn}asyncverifyArtifact(e,r,n){S("Verifying keyless verification bundle signature");lets=JSON.parse(Ko.default.readFileSync(r,"utf-8")),i=(0,wf.bundleFromJSON)(s);S("Fetching Sigstore TUF trusted root metadata");leta=awaitCue.getTrustedRoot(),c=(0,Sf.toTrustMaterial)(a);try{S("Verifying artifact signature");letl=(0,Sf.toSignedEntity)(i,Ko.default.readFileSync(e)),u=t.parseCertificate(i),d=i.verificationMaterial.tlogEntries,A=d.length>0?d[0].logIndex:void0;if(n?.subjectAlternativeName&&n?.subjectAlternativeNameinstanceofRegExp){leth=u.subjectAltName?.replace(/^uri:/i,"");if(h){if(!h.match(n.subjectAlternativeName))thrownewError(`Signing certificate subjectAlternativeName "${h}" does not match expected pattern`)}elsethrownewError("Signing certificate does not contain subjectAltName")}letf=newSf.Verifier(c).verify(l,{subjectAlternativeName:n?.subjectAlternativeName&&typeofn.subjectAlternativeName=="string"?n.subjectAlternativeName:void0,extensions:n?.issuer?{issuer:n.issuer}:void0});returnb(`Sigstore.verifyArtifact signer: ${JSON.stringify(f)}`),{payload:s,certificate:u.toString(),tlogID:A}}catch(l){thrownewError(`Failed to verify artifact signature: ${l}`)}}staticnoTransparencyLog(e){returne??je.context.payload.repository?.private??!1}asynccosignSigningConfigArgs(e){letr=[],n=t.noTransparencyLog(e);returnS(`Upload to transparency log: ${n?"disabled":"enabled"}`),awaitthis.cosign.versionSatisfies(">=3.0.4")?awaitit("Creating Sigstore protobuf signing config",async()=>{lets=Oe.tmpName({template:"signing-config-XXXXXX.json",tmpdir:Oe.tmpDir()}),i=["signing-config","create","--with-default-services=true",`--out=${s}`];n&&i.push("--no-default-rekor=true"),awaitY.exec(this.cosign.binPath,i,{env:Object.assign({},process.env,{COSIGN_EXPERIMENTAL:"1"})}),S(JSON.stringify(JSON.parse(Ko.default.readFileSync(s,{encoding:"utf-8"})),null,2)),r.push(`--signing-config=${s}`)}):(r.push("--use-signing-config"),n&&r.push("--tlog-upload=false")),r}staticgetProvenanceBlobs(e){letr=Xo.default.join(e.localExportDir,"provenance.json");if(Ko.default.existsSync(r))return{[r]:Ko.default.readFileSync(r)};letn=Ko.default.readdirSync(e.localExportDir,{withFileTypes:!0}),s=n.filter(i=>i.isDirectory());if(s.length>0&&s.length===n.length&&s.every(i=>Ko.default.existsSync(Xo.default.join(e.localExportDir,i.name,"provenance.json")))){leti={};for(letaofs){letc=Xo.default.join(e.localExportDir,a.name,"provenance.json");i[c]=Ko.default.readFileSync(c)}returni}thrownewError(`No valid provenance.json found in ${e.lo
`;varZN=classt{static{o(this,"Install")}githubToken;buildx;sigstore;constructor(e){this.githubToken=e?.githubToken||process.env.GITHUB_TOKEN,this.buildx=e?.buildx||newPe,this.sigstore=e?.sigstore||newml}asyncdownload(e){letr=awaitt.getDownloadVersion(e.version);b(`Install.download version: ${r.version}`);letn=awaitt.getRelease(r,this.githubToken);b(`Install.download release tag name: ${n.tag_name}`);lets=awaitthis.vspec(n.tag_name);b(`Install.download vspec: ${s}`);leti=Rf.clean(s)||"";if(!Rf.valid(i))thrownewError(`Invalid Cosign version "${s}".`);leta=newgr({htcName:"cosign-dl-bin",htcVersion:s,baseCacheDir:Qf.default.join(_i.default.homedir(),".bin"),cacheFile:_i.default.platform()=="win32"?"cosign.exe":"cosign",ghaNoCache:e.ghaNoCache}),c=awaita.find();if(c)returnS(`Cosign binary found in ${c}`),c;letl=Kq.format(r.downloadURL,s,this.filename());S(`Downloading ${l}`);letu=awaitQs(l,void0,this.githubToken);b(`Install.download htcDownloadPath: ${u}`),e.verifySignature&&Rf.satisfies(s,">=3.0.1")&&awaitthis.verifySignature(u,l);letd=awaita.save(u,e.skipState);returnS(`Cached to ${d}`),d}asyncbuild(e,r,n){lets=awaitthis.vspec(e);b(`Install.build vspec: ${s}`);leti=newgr({htcName:"cosign-build-bin",htcVersion:s,baseCacheDir:Qf.default.join(_i.default.homedir(),".bin"),cacheFile:_i.default.platform()=="win32"?"cosign.exe":"cosign",ghaNoCache:r}),a=awaiti.find();if(a)returnS(`Cosign binary found in ${a}`),a;letc=Qf.default.join(Oe.tmpDir(),"cosign-build-cache"),l=awaitthis.buildCommand(e,c),u=awaitY.getExecOutput(l.command,l.args,{ignoreReturnCode:!0,input:Buffer.from(Bue)}).then(A=>{if(A.stderr.length>0&&A.exitCode!=0)thrownewError(`build failed with: ${A.stderr.match(/(.*)\s*$/)?.[0]?.trim()??"unknown error"}`);return`${c}/cosign`}),d=awaiti.save(u,n);returnS(`Cached to ${d}`),d}asyncinstall(e,r){r=r||Oe.tmpDir();letn=Qf.default.join(r,"cosign-bin");PE.default.existsSync(n)||PE.default.mkdirSync(n,{recursive:!0});lets=_i.default.platform()=="win32"?"cosign.exe":"cosign",i=Qf.default.join(n,s);returnPE.default.copyFileSync(e,i),S("Fixing perms"),PE.default.chmodSync(i,"0755"),Wi(n),S("Added Cosign to PATH"),S(`Binary path: ${i}`),i}asyncbuildCommand(e,r){letn=awaitnewPe({standalone:!0}).isAvailable(),s=awaitnewPe({standalone:!1}).isAvailable(),i=!1;if(awaitthis.buildx.isStandalone()&&n)b("Install.buildCommand: Buildx standalone found, build with it"),i=!0;elseif(!awaitthis.buildx.isStandalone()&&s)b("Install.buildCommand: Buildx plugin found, build with it"),i=!1;elseif(n)b("Install.buildCommand: Buildx plugin not found, but standalone found so trying to build with it"),i=!0;elseif(s)b("Install.buildCommand: Buildx standalone not found, but plugin found so trying to build with it"),i=!1;elsethrownewError(`Neither buildx standalone or plugin have been found to build from ref ${e}`);leta=["build","--platform","local","--build-arg","BUILDKIT_CONTEXT_KEEP_GIT_DIR=1","--output",`type=local,dest=${r}`];returnprocess.env.GIT_AUTH_TOKEN&&a.push("--secret","id=GIT_AUTH_TOKEN"),a.push("-f-",e),awaitnewPe({standalone:i}).getCommand(a)}asyncverifySignature(e,r){letn=`${r}.sigstore.json`;S(`Downloading keyless verification bundle at ${n}`);lets=awaitQs(n,void0,this.githubToken);b(`Install.verifySignature bundlePath: ${s}`);leti=awaitthis.sigstore.verifyArtifact(e,s,{subjectAlternativeName:"keyless@projectsigstore.iam.gserviceaccount.com",issuer:"https://accounts.google.com"});S(`Cosign binary signature verified! ${i.tlogID?`${pd}?logIndex=${i.tlogID}`:""}`)}filename(){lete;switch(_i.default.arch()){case"x64":{e="amd64";break}case"ppc64":{e="ppc64le";break}default:{e=_i.default.arch();break}}letr=_i.default.platform()=="win32"?"windows":_i.default.platform(),n=_i.default.platform()=="win32"?".exe":"";returnKq.format("cosign-%s-%s%s",r,e,n)}asyncvspec(e){if(!Me.isValidRef(e)){letu=e.replace(/^v+|v+$/g,"");returnS(`Use ${u} version spec cache key for ${e}`),u}let[r,n]=e.split("#");n.length==0&&(n="master");lets;n.match(/^[0-9a-fA-F]{40}$/)?s=n:s=awaitJp.remoteSha(