@bigbinary/neeto-playwright-reporter 1.8.6 → 1.8.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs.js +1 -1
- package/index.cjs.js.map +1 -1
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -6,5 +6,5 @@ import e from"os";import n from"domain";import t,{readFileSync as a}from"fs";imp
|
|
|
6
6
|
* MIT Licensed
|
|
7
7
|
*/
|
|
8
8
|
function(e){var n,t,a,o=Qt.exports,r=i.extname,s=/^\s*([^;\s]*)(?:;|\s|$)/,c=/^text\//i;function u(e){if(!e||"string"!=typeof e)return!1;var n=s.exec(e),t=n&&o[n[1].toLowerCase()];return t&&t.charset?t.charset:!(!n||!c.test(n[1]))&&"UTF-8"}e.charset=u,e.charsets={lookup:u},e.contentType=function(n){if(!n||"string"!=typeof n)return!1;var t=-1===n.indexOf("/")?e.lookup(n):n;if(!t)return!1;if(-1===t.indexOf("charset")){var a=e.charset(t);a&&(t+="; charset="+a.toLowerCase())}return t},e.extension=function(n){if(!n||"string"!=typeof n)return!1;var t=s.exec(n),a=t&&e.extensions[t[1].toLowerCase()];if(!a||!a.length)return!1;return a[0]},e.extensions=Object.create(null),e.lookup=function(n){if(!n||"string"!=typeof n)return!1;var t=r("x."+n).toLowerCase().substr(1);if(!t)return!1;return e.types[t]||!1},e.types=Object.create(null),n=e.extensions,t=e.types,a=["nginx","apache",void 0,"iana"],Object.keys(o).forEach((function(e){var i=o[e],r=i.extensions;if(r&&r.length){n[e]=r;for(var s=0;s<r.length;s++){var c=r[s];if(t[c]){var u=a.indexOf(o[t[c]].source),p=a.indexOf(i.source);if("application/octet-stream"!==t[c]&&(u>p||u===p&&"application/"===t[c].substr(0,12)))continue}t[c]=e}}}))}(Zt);var ea=function(e){var n="function"==typeof setImmediate?setImmediate:"object"==typeof process&&"function"==typeof process.nextTick?process.nextTick:null;n?n(e):setTimeout(e,0)},na=function(e){var n=!1;return ea((function(){n=!0})),function(t,a){n?e(t,a):ea((function(){e(t,a)}))}};var ta=function(e){Object.keys(e.jobs).forEach(aa.bind(e)),e.jobs={}};function aa(e){"function"==typeof this.jobs[e]&&this.jobs[e]()}var ia=na,oa=ta,ra=function(e,n,t,a){var i=t.keyedList?t.keyedList[t.index]:t.index;t.jobs[i]=function(e,n,t,a){var i;i=2==e.length?e(t,ia(a)):e(t,n,ia(a));return i}(n,i,e[i],(function(e,n){i in t.jobs&&(delete t.jobs[i],e?oa(t):t.results[i]=n,a(e,t.results))}))};var sa=function(e,n){var t=!Array.isArray(e),a={index:0,keyedList:t||n?Object.keys(e):null,jobs:{},results:t?{}:[],size:t?Object.keys(e).length:e.length};n&&a.keyedList.sort(t?n:function(t,a){return n(e[t],e[a])});return a};var ca=ta,ua=na,pa=function(e){if(!Object.keys(this.jobs).length)return;this.index=this.size,ca(this),ua(e)(null,this.results)};var la=ra,da=sa,ma=pa,fa=function(e,n,t){var a=da(e);for(;a.index<(a.keyedList||e).length;)la(e,n,a,(function(e,n){e?t(e,n):0!==Object.keys(a.jobs).length||t(null,a.results)})),a.index++;return ma.bind(a,t)};var ha={exports:{}},va=ra,xa=sa,ba=pa;function ga(e,n){return e<n?-1:e>n?1:0}ha.exports=function(e,n,t,a){var i=xa(e,t);return va(e,n,i,(function t(o,r){o?a(o,r):(i.index++,i.index<(i.keyedList||e).length?va(e,n,i,t):a(null,i.results))})),ba.bind(i,a)},ha.exports.ascending=ga,ha.exports.descending=function(e,n){return-1*ga(e,n)};var ya=ha.exports;var Da,wa,_a={parallel:fa,serial:function(e,n,t){return ya(e,n,null,t)},serialOrdered:ha.exports},Ea=Object,Ca=Error,Fa=EvalError,ja=RangeError,ka=ReferenceError,Aa=SyntaxError;function Ta(){return wa?Da:(wa=1,Da=TypeError)}var Sa=URIError,Oa=Math.abs,Ra=Math.floor,Ba=Math.max,Pa=Math.min,La=Math.pow,Ia=Math.round,Na=Number.isNaN||function(e){return e!=e},Ua=Object.getOwnPropertyDescriptor;if(Ua)try{Ua([],"length")}catch(e){Ua=null}var za=Ua,qa=Object.defineProperty||!1;if(qa)try{qa({},"a",{value:1})}catch(e){qa=!1}var Ma,Ha,$a,Ga,Wa,Ka,Va,Ja,Ya,Xa,Za,Qa,ei,ni,ti,ai,ii,oi,ri,si,ci,ui,pi,li,di,mi,fi,hi,vi,xi=qa;function bi(){return Ha?Ma:(Ha=1,Ma=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},n=Symbol("test"),t=Object(n);if("string"==typeof n)return!1;if("[object Symbol]"!==Object.prototype.toString.call(n))return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;for(var a in e[n]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==n)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,n))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,n);if(42!==o.value||!0!==o.enumerable)return!1}return!0})}function gi(){return Ka?Wa:(Ka=1,Wa="undefined"!=typeof Reflect&&Reflect.getPrototypeOf||null)}function yi(){return Ja?Va:(Ja=1,Va=Ea.getPrototypeOf||null)}function Di(){if(Xa)return Ya;Xa=1;var e=Object.prototype.toString,n=Math.max,t=function(e,n){for(var t=[],a=0;a<e.length;a+=1)t[a]=e[a];for(var i=0;i<n.length;i+=1)t[i+e.length]=n[i];return t};return Ya=function(a){var i=this;if("function"!=typeof i||"[object Function]"!==e.apply(i))throw new TypeError("Function.prototype.bind called on incompatible "+i);for(var o,r=function(e,n){for(var t=[],a=n,i=0;a<e.length;a+=1,i+=1)t[i]=e[a];return t}(arguments,1),s=n(0,i.length-r.length),c=[],u=0;u<s;u++)c[u]="$"+u;if(o=Function("binder","return function ("+function(e,n){for(var t="",a=0;a<e.length;a+=1)t+=e[a],a+1<e.length&&(t+=n);return t}(c,",")+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof o){var e=i.apply(this,t(r,arguments));return Object(e)===e?e:this}return i.apply(a,t(r,arguments))})),i.prototype){var p=function(){};p.prototype=i.prototype,o.prototype=new p,p.prototype=null}return o},Ya}function wi(){if(Qa)return Za;Qa=1;var e=Di();return Za=Function.prototype.bind||e}function _i(){return ni?ei:(ni=1,ei=Function.prototype.call)}function Ei(){return ai?ti:(ai=1,ti=Function.prototype.apply)}function Ci(){if(si)return ri;si=1;var e=wi(),n=Ei(),t=_i(),a=oi?ii:(oi=1,ii="undefined"!=typeof Reflect&&Reflect&&Reflect.apply);return ri=a||e.call(t,n)}function Fi(){if(li)return pi;li=1;var e,n=function(){if(ui)return ci;ui=1;var e=wi(),n=Ta(),t=_i(),a=Ci();return ci=function(i){if(i.length<1||"function"!=typeof i[0])throw new n("a function is required");return a(e,t,i)}}(),t=za;try{e=[].__proto__===Array.prototype}catch(e){if(!e||"object"!=typeof e||!("code"in e)||"ERR_PROTO_ACCESS"!==e.code)throw e}var a=!!e&&t&&t(Object.prototype,"__proto__"),i=Object,o=i.getPrototypeOf;return pi=a&&"function"==typeof a.get?n([a.get]):"function"==typeof o&&function(e){return o(null==e?e:i(e))}}function ji(){if(hi)return fi;hi=1;var e=Function.prototype.call,n=Object.prototype.hasOwnProperty,t=wi();return fi=t.call(e,n)}var ki=Ea,Ai=Ca,Ti=Fa,Si=ja,Oi=ka,Ri=Aa,Bi=Ta(),Pi=Sa,Li=Oa,Ii=Ra,Ni=Ba,Ui=Pa,zi=La,qi=Ia,Mi=function(e){return Na(e)||0===e?e:e<0?-1:1},Hi=Function,$i=function(e){try{return Hi('"use strict"; return ('+e+").constructor;")()}catch(e){}},Gi=za,Wi=xi,Ki=function(){throw new Bi},Vi=Gi?function(){try{return Ki}catch(e){try{return Gi(arguments,"callee").get}catch(e){return Ki}}}():Ki,Ji=function(){if(Ga)return $a;Ga=1;var e="undefined"!=typeof Symbol&&Symbol,n=bi();return $a=function(){return"function"==typeof e&&("function"==typeof Symbol&&("symbol"==typeof e("foo")&&("symbol"==typeof Symbol("bar")&&n())))}}()(),Yi=function(){if(mi)return di;mi=1;var e=gi(),n=yi(),t=Fi();return di=e?function(n){return e(n)}:n?function(e){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new TypeError("getProto: not an object");return n(e)}:t?function(e){return t(e)}:null}(),Xi=yi(),Zi=gi(),Qi=Ei(),eo=_i(),no={},to="undefined"!=typeof Uint8Array&&Yi?Yi(Uint8Array):vi,ao={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?vi:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?vi:ArrayBuffer,"%ArrayIteratorPrototype%":Ji&&Yi?Yi([][Symbol.iterator]()):vi,"%AsyncFromSyncIteratorPrototype%":vi,"%AsyncFunction%":no,"%AsyncGenerator%":no,"%AsyncGeneratorFunction%":no,"%AsyncIteratorPrototype%":no,"%Atomics%":"undefined"==typeof Atomics?vi:Atomics,"%BigInt%":"undefined"==typeof BigInt?vi:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?vi:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?vi:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?vi:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Ai,"%eval%":eval,"%EvalError%":Ti,"%Float16Array%":"undefined"==typeof Float16Array?vi:Float16Array,"%Float32Array%":"undefined"==typeof Float32Array?vi:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?vi:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?vi:FinalizationRegistry,"%Function%":Hi,"%GeneratorFunction%":no,"%Int8Array%":"undefined"==typeof Int8Array?vi:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?vi:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?vi:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Ji&&Yi?Yi(Yi([][Symbol.iterator]())):vi,"%JSON%":"object"==typeof JSON?JSON:vi,"%Map%":"undefined"==typeof Map?vi:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&Ji&&Yi?Yi((new Map)[Symbol.iterator]()):vi,"%Math%":Math,"%Number%":Number,"%Object%":ki,"%Object.getOwnPropertyDescriptor%":Gi,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?vi:Promise,"%Proxy%":"undefined"==typeof Proxy?vi:Proxy,"%RangeError%":Si,"%ReferenceError%":Oi,"%Reflect%":"undefined"==typeof Reflect?vi:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?vi:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&Ji&&Yi?Yi((new Set)[Symbol.iterator]()):vi,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?vi:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Ji&&Yi?Yi(""[Symbol.iterator]()):vi,"%Symbol%":Ji?Symbol:vi,"%SyntaxError%":Ri,"%ThrowTypeError%":Vi,"%TypedArray%":to,"%TypeError%":Bi,"%Uint8Array%":"undefined"==typeof Uint8Array?vi:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?vi:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?vi:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?vi:Uint32Array,"%URIError%":Pi,"%WeakMap%":"undefined"==typeof WeakMap?vi:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?vi:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?vi:WeakSet,"%Function.prototype.call%":eo,"%Function.prototype.apply%":Qi,"%Object.defineProperty%":Wi,"%Object.getPrototypeOf%":Xi,"%Math.abs%":Li,"%Math.floor%":Ii,"%Math.max%":Ni,"%Math.min%":Ui,"%Math.pow%":zi,"%Math.round%":qi,"%Math.sign%":Mi,"%Reflect.getPrototypeOf%":Zi};if(Yi)try{null.error}catch(e){var io=Yi(Yi(e));ao["%Error.prototype%"]=io}var oo,ro,so=function e(n){var t;if("%AsyncFunction%"===n)t=$i("async function () {}");else if("%GeneratorFunction%"===n)t=$i("function* () {}");else if("%AsyncGeneratorFunction%"===n)t=$i("async function* () {}");else if("%AsyncGenerator%"===n){var a=e("%AsyncGeneratorFunction%");a&&(t=a.prototype)}else if("%AsyncIteratorPrototype%"===n){var i=e("%AsyncGenerator%");i&&Yi&&(t=Yi(i.prototype))}return ao[n]=t,t},co={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},uo=wi(),po=ji(),lo=uo.call(eo,Array.prototype.concat),mo=uo.call(Qi,Array.prototype.splice),fo=uo.call(eo,String.prototype.replace),ho=uo.call(eo,String.prototype.slice),vo=uo.call(eo,RegExp.prototype.exec),xo=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,bo=/\\(\\)?/g,go=function(e,n){var t,a=e;if(po(co,a)&&(a="%"+(t=co[a])[0]+"%"),po(ao,a)){var i=ao[a];if(i===no&&(i=so(a)),void 0===i&&!n)throw new Bi("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:t,name:a,value:i}}throw new Ri("intrinsic "+e+" does not exist!")};var yo=function(e,n){if("string"!=typeof e||0===e.length)throw new Bi("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof n)throw new Bi('"allowMissing" argument must be a boolean');if(null===vo(/^%?[^%]*%?$/,e))throw new Ri("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var t=function(e){var n=ho(e,0,1),t=ho(e,-1);if("%"===n&&"%"!==t)throw new Ri("invalid intrinsic syntax, expected closing `%`");if("%"===t&&"%"!==n)throw new Ri("invalid intrinsic syntax, expected opening `%`");var a=[];return fo(e,xo,(function(e,n,t,i){a[a.length]=t?fo(i,bo,"$1"):n||e})),a}(e),a=t.length>0?t[0]:"",i=go("%"+a+"%",n),o=i.name,r=i.value,s=!1,c=i.alias;c&&(a=c[0],mo(t,lo([0,1],c)));for(var u=1,p=!0;u<t.length;u+=1){var l=t[u],d=ho(l,0,1),m=ho(l,-1);if(('"'===d||"'"===d||"`"===d||'"'===m||"'"===m||"`"===m)&&d!==m)throw new Ri("property names with quotes must have matching quotes");if("constructor"!==l&&p||(s=!0),po(ao,o="%"+(a+="."+l)+"%"))r=ao[o];else if(null!=r){if(!(l in r)){if(!n)throw new Bi("base intrinsic for "+e+" exists, but the property is not available.");return}if(Gi&&u+1>=t.length){var f=Gi(r,l);r=(p=!!f)&&"get"in f&&!("originalValue"in f.get)?f.get:r[l]}else p=po(r,l),r=r[l];p&&!s&&(ao[o]=r)}}return r}("%Object.defineProperty%",!0),Do=function(){if(ro)return oo;ro=1;var e=bi();return oo=function(){return e()&&!!Symbol.toStringTag}}()(),wo=ji(),_o=Ta(),Eo=Do?Symbol.toStringTag:null,Co=Yt,Fo=r,jo=i,ko=c,Ao=u,To=s.parse,So=t,Oo=l.Stream,Ro=Zt,Bo=_a,Po=function(e,n){var t=arguments.length>2&&!!arguments[2]&&arguments[2].force,a=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(void 0!==t&&"boolean"!=typeof t||void 0!==a&&"boolean"!=typeof a)throw new _o("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");!Eo||!t&&wo(e,Eo)||(yo?yo(e,Eo,{configurable:!a,enumerable:!1,value:n,writable:!1}):e[Eo]=n)},Lo=function(e,n){return Object.keys(n).forEach((function(t){e[t]=e[t]||n[t]})),e},Io=No;function No(e){if(!(this instanceof No))return new No(e);for(var n in this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],Co.call(this),e=e||{})this[n]=e[n]}function Uo(e){return zt.isPlainObject(e)||zt.isArray(e)}function zo(e){return zt.endsWith(e,"[]")?e.slice(0,-2):e}function qo(e,n,t){return e?e.concat(n).map((function(e,n){return e=zo(e),!t&&n?"["+e+"]":e})).join(t?".":""):n}Fo.inherits(No,Co),No.LINE_BREAK="\r\n",No.DEFAULT_CONTENT_TYPE="application/octet-stream",No.prototype.append=function(e,n,t){"string"==typeof(t=t||{})&&(t={filename:t});var a=Co.prototype.append.bind(this);if("number"==typeof n&&(n=""+n),Array.isArray(n))this._error(new Error("Arrays are not supported."));else{var i=this._multiPartHeader(e,n,t),o=this._multiPartFooter();a(i),a(n),a(o),this._trackLength(i,n,t)}},No.prototype._trackLength=function(e,n,t){var a=0;null!=t.knownLength?a+=+t.knownLength:Buffer.isBuffer(n)?a=n.length:"string"==typeof n&&(a=Buffer.byteLength(n)),this._valueLength+=a,this._overheadLength+=Buffer.byteLength(e)+No.LINE_BREAK.length,n&&(n.path||n.readable&&Object.prototype.hasOwnProperty.call(n,"httpVersion")||n instanceof Oo)&&(t.knownLength||this._valuesToMeasure.push(n))},No.prototype._lengthRetriever=function(e,n){Object.prototype.hasOwnProperty.call(e,"fd")?null!=e.end&&e.end!=1/0&&null!=e.start?n(null,e.end+1-(e.start?e.start:0)):So.stat(e.path,(function(t,a){var i;t?n(t):(i=a.size-(e.start?e.start:0),n(null,i))})):Object.prototype.hasOwnProperty.call(e,"httpVersion")?n(null,+e.headers["content-length"]):Object.prototype.hasOwnProperty.call(e,"httpModule")?(e.on("response",(function(t){e.pause(),n(null,+t.headers["content-length"])})),e.resume()):n("Unknown stream")},No.prototype._multiPartHeader=function(e,n,t){if("string"==typeof t.header)return t.header;var a,i=this._getContentDisposition(n,t),o=this._getContentType(n,t),r="",s={"Content-Disposition":["form-data",'name="'+e+'"'].concat(i||[]),"Content-Type":[].concat(o||[])};for(var c in"object"==typeof t.header&&Lo(s,t.header),s)if(Object.prototype.hasOwnProperty.call(s,c)){if(null==(a=s[c]))continue;Array.isArray(a)||(a=[a]),a.length&&(r+=c+": "+a.join("; ")+No.LINE_BREAK)}return"--"+this.getBoundary()+No.LINE_BREAK+r+No.LINE_BREAK},No.prototype._getContentDisposition=function(e,n){var t,a;return"string"==typeof n.filepath?t=jo.normalize(n.filepath).replace(/\\/g,"/"):n.filename||e.name||e.path?t=jo.basename(n.filename||e.name||e.path):e.readable&&Object.prototype.hasOwnProperty.call(e,"httpVersion")&&(t=jo.basename(e.client._httpMessage.path||"")),t&&(a='filename="'+t+'"'),a},No.prototype._getContentType=function(e,n){var t=n.contentType;return!t&&e.name&&(t=Ro.lookup(e.name)),!t&&e.path&&(t=Ro.lookup(e.path)),!t&&e.readable&&Object.prototype.hasOwnProperty.call(e,"httpVersion")&&(t=e.headers["content-type"]),t||!n.filepath&&!n.filename||(t=Ro.lookup(n.filepath||n.filename)),t||"object"!=typeof e||(t=No.DEFAULT_CONTENT_TYPE),t},No.prototype._multiPartFooter=function(){return function(e){var n=No.LINE_BREAK;0===this._streams.length&&(n+=this._lastBoundary()),e(n)}.bind(this)},No.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+No.LINE_BREAK},No.prototype.getHeaders=function(e){var n,t={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n.toLowerCase()]=e[n]);return t},No.prototype.setBoundary=function(e){this._boundary=e},No.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary},No.prototype.getBuffer=function(){for(var e=new Buffer.alloc(0),n=this.getBoundary(),t=0,a=this._streams.length;t<a;t++)"function"!=typeof this._streams[t]&&(e=Buffer.isBuffer(this._streams[t])?Buffer.concat([e,this._streams[t]]):Buffer.concat([e,Buffer.from(this._streams[t])]),"string"==typeof this._streams[t]&&this._streams[t].substring(2,n.length+2)===n||(e=Buffer.concat([e,Buffer.from(No.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])},No.prototype._generateBoundary=function(){for(var e="--------------------------",n=0;n<24;n++)e+=Math.floor(10*Math.random()).toString(16);this._boundary=e},No.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;return this._streams.length&&(e+=this._lastBoundary().length),this.hasKnownLength()||this._error(new Error("Cannot calculate proper length in synchronous way.")),e},No.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e},No.prototype.getLength=function(e){var n=this._overheadLength+this._valueLength;this._streams.length&&(n+=this._lastBoundary().length),this._valuesToMeasure.length?Bo.parallel(this._valuesToMeasure,this._lengthRetriever,(function(t,a){t?e(t):(a.forEach((function(e){n+=e})),e(null,n))})):process.nextTick(e.bind(this,null,n))},No.prototype.submit=function(e,n){var t,a,i={method:"post"};return"string"==typeof e?(e=To(e),a=Lo({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},i)):(a=Lo(e,i)).port||(a.port="https:"==a.protocol?443:80),a.headers=this.getHeaders(e.headers),t="https:"==a.protocol?Ao.request(a):ko.request(a),this.getLength(function(e,a){if(e&&"Unknown stream"!==e)this._error(e);else if(a&&t.setHeader("Content-Length",a),this.pipe(t),n){var i,o=function(e,a){return t.removeListener("error",o),t.removeListener("response",i),n.call(this,e,a)};i=o.bind(this,null),t.on("error",o),t.on("response",i)}}.bind(this)),t},No.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))},No.prototype.toString=function(){return"[object FormData]"},Po(No,"FormData");const Mo=zt.toFlatObject(zt,{},null,(function(e){return/^is[A-Z]/.test(e)}));function Ho(e,n,t){if(!zt.isObject(e))throw new TypeError("target must be an object");n=n||new(Io||FormData);const a=(t=zt.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,n){return!zt.isUndefined(n[e])}))).metaTokens,i=t.visitor||u,o=t.dots,r=t.indexes,s=(t.Blob||"undefined"!=typeof Blob&&Blob)&&zt.isSpecCompliantForm(n);if(!zt.isFunction(i))throw new TypeError("visitor must be a function");function c(e){if(null===e)return"";if(zt.isDate(e))return e.toISOString();if(!s&&zt.isBlob(e))throw new qt("Blob is not supported. Use a Buffer instead.");return zt.isArrayBuffer(e)||zt.isTypedArray(e)?s&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function u(e,t,i){let s=e;if(e&&!i&&"object"==typeof e)if(zt.endsWith(t,"{}"))t=a?t:t.slice(0,-2),e=JSON.stringify(e);else if(zt.isArray(e)&&function(e){return zt.isArray(e)&&!e.some(Uo)}(e)||(zt.isFileList(e)||zt.endsWith(t,"[]"))&&(s=zt.toArray(e)))return t=zo(t),s.forEach((function(e,a){!zt.isUndefined(e)&&null!==e&&n.append(!0===r?qo([t],a,o):null===r?t:t+"[]",c(e))})),!1;return!!Uo(e)||(n.append(qo(i,t,o),c(e)),!1)}const p=[],l=Object.assign(Mo,{defaultVisitor:u,convertValue:c,isVisitable:Uo});if(!zt.isObject(e))throw new TypeError("data must be an object");return function e(t,a){if(!zt.isUndefined(t)){if(-1!==p.indexOf(t))throw Error("Circular reference detected in "+a.join("."));p.push(t),zt.forEach(t,(function(t,o){!0===(!(zt.isUndefined(t)||null===t)&&i.call(n,t,zt.isString(o)?o.trim():o,a,l))&&e(t,a?a.concat(o):[o])})),p.pop()}}(e),n}function $o(e){const n={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return n[e]}))}function Go(e,n){this._pairs=[],e&&Ho(e,this,n)}const Wo=Go.prototype;function Ko(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Vo(e,n,t){if(!n)return e;const a=t&&t.encode||Ko;zt.isFunction(t)&&(t={serialize:t});const i=t&&t.serialize;let o;if(o=i?i(n,t):zt.isURLSearchParams(n)?n.toString():new Go(n,t).toString(a),o){const n=e.indexOf("#");-1!==n&&(e=e.slice(0,n)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}Wo.append=function(e,n){this._pairs.push([e,n])},Wo.toString=function(e){const n=e?function(n){return e.call(this,n,$o)}:$o;return this._pairs.map((function(e){return n(e[0])+"="+n(e[1])}),"").join("&")};class Jo{constructor(){this.handlers=[]}use(e,n,t){return this.handlers.push({fulfilled:e,rejected:n,synchronous:!!t&&t.synchronous,runWhen:t?t.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){zt.forEach(this.handlers,(function(n){null!==n&&e(n)}))}}var Yo={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Xo=s.URLSearchParams;const Zo="abcdefghijklmnopqrstuvwxyz",Qo="0123456789",er={DIGIT:Qo,ALPHA:Zo,ALPHA_DIGIT:Zo+Zo.toUpperCase()+Qo};var nr={isNode:!0,classes:{URLSearchParams:Xo,FormData:Io,Blob:"undefined"!=typeof Blob&&Blob||null},ALPHABET:er,generateString:(e=16,n=er.ALPHA_DIGIT)=>{let t="";const{length:a}=n,i=new Uint32Array(e);p.randomFillSync(i);for(let o=0;o<e;o++)t+=n[i[o]%a];return t},protocols:["http","https","file","data"]};const tr="undefined"!=typeof window&&"undefined"!=typeof document,ar="object"==typeof navigator&&navigator||void 0,ir=tr&&(!ar||["ReactNative","NativeScript","NS"].indexOf(ar.product)<0),or="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,rr=tr&&window.location.href||"http://localhost";var sr={...Object.freeze({__proto__:null,hasBrowserEnv:tr,hasStandardBrowserEnv:ir,hasStandardBrowserWebWorkerEnv:or,navigator:ar,origin:rr}),...nr};function cr(e){function n(e,t,a,i){let o=e[i++];if("__proto__"===o)return!0;const r=Number.isFinite(+o),s=i>=e.length;if(o=!o&&zt.isArray(a)?a.length:o,s)return zt.hasOwnProp(a,o)?a[o]=[a[o],t]:a[o]=t,!r;a[o]&&zt.isObject(a[o])||(a[o]=[]);return n(e,t,a[o],i)&&zt.isArray(a[o])&&(a[o]=function(e){const n={},t=Object.keys(e);let a;const i=t.length;let o;for(a=0;a<i;a++)o=t[a],n[o]=e[o];return n}(a[o])),!r}if(zt.isFormData(e)&&zt.isFunction(e.entries)){const t={};return zt.forEachEntry(e,((e,a)=>{n(function(e){return zt.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),a,t,0)})),t}return null}const ur={transitional:Yo,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const t=n.getContentType()||"",a=t.indexOf("application/json")>-1,i=zt.isObject(e);i&&zt.isHTMLForm(e)&&(e=new FormData(e));if(zt.isFormData(e))return a?JSON.stringify(cr(e)):e;if(zt.isArrayBuffer(e)||zt.isBuffer(e)||zt.isStream(e)||zt.isFile(e)||zt.isBlob(e)||zt.isReadableStream(e))return e;if(zt.isArrayBufferView(e))return e.buffer;if(zt.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(i){if(t.indexOf("application/x-www-form-urlencoded")>-1)return function(e,n){return Ho(e,new sr.classes.URLSearchParams,Object.assign({visitor:function(e,n,t,a){return sr.isNode&&zt.isBuffer(e)?(this.append(n,e.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},n))}(e,this.formSerializer).toString();if((o=zt.isFileList(e))||t.indexOf("multipart/form-data")>-1){const n=this.env&&this.env.FormData;return Ho(o?{"files[]":e}:e,n&&new n,this.formSerializer)}}return i||a?(n.setContentType("application/json",!1),function(e,n,t){if(zt.isString(e))try{return(n||JSON.parse)(e),zt.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(t||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const n=this.transitional||ur.transitional,t=n&&n.forcedJSONParsing,a="json"===this.responseType;if(zt.isResponse(e)||zt.isReadableStream(e))return e;if(e&&zt.isString(e)&&(t&&!this.responseType||a)){const t=!(n&&n.silentJSONParsing)&&a;try{return JSON.parse(e)}catch(e){if(t){if("SyntaxError"===e.name)throw qt.from(e,qt.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:sr.classes.FormData,Blob:sr.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};zt.forEach(["delete","get","head","post","put","patch"],(e=>{ur.headers[e]={}}));const pr=zt.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]);const lr=Symbol("internals");function dr(e){return e&&String(e).trim().toLowerCase()}function mr(e){return!1===e||null==e?e:zt.isArray(e)?e.map(mr):String(e)}function fr(e,n,t,a,i){return zt.isFunction(a)?a.call(this,n,t):(i&&(n=t),zt.isString(n)?zt.isString(a)?-1!==n.indexOf(a):zt.isRegExp(a)?a.test(n):void 0:void 0)}let hr=class{constructor(e){e&&this.set(e)}set(e,n,t){const a=this;function i(e,n,t){const i=dr(n);if(!i)throw new Error("header name must be a non-empty string");const o=zt.findKey(a,i);(!o||void 0===a[o]||!0===t||void 0===t&&!1!==a[o])&&(a[o||n]=mr(e))}const o=(e,n)=>zt.forEach(e,((e,t)=>i(e,t,n)));if(zt.isPlainObject(e)||e instanceof this.constructor)o(e,n);else if(zt.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))o((e=>{const n={};let t,a,i;return e&&e.split("\n").forEach((function(e){i=e.indexOf(":"),t=e.substring(0,i).trim().toLowerCase(),a=e.substring(i+1).trim(),!t||n[t]&&pr[t]||("set-cookie"===t?n[t]?n[t].push(a):n[t]=[a]:n[t]=n[t]?n[t]+", "+a:a)})),n})(e),n);else if(zt.isHeaders(e))for(const[n,a]of e.entries())i(a,n,t);else null!=e&&i(n,e,t);return this}get(e,n){if(e=dr(e)){const t=zt.findKey(this,e);if(t){const e=this[t];if(!n)return e;if(!0===n)return function(e){const n=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let a;for(;a=t.exec(e);)n[a[1]]=a[2];return n}(e);if(zt.isFunction(n))return n.call(this,e,t);if(zt.isRegExp(n))return n.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=dr(e)){const t=zt.findKey(this,e);return!(!t||void 0===this[t]||n&&!fr(0,this[t],t,n))}return!1}delete(e,n){const t=this;let a=!1;function i(e){if(e=dr(e)){const i=zt.findKey(t,e);!i||n&&!fr(0,t[i],i,n)||(delete t[i],a=!0)}}return zt.isArray(e)?e.forEach(i):i(e),a}clear(e){const n=Object.keys(this);let t=n.length,a=!1;for(;t--;){const i=n[t];e&&!fr(0,this[i],i,e,!0)||(delete this[i],a=!0)}return a}normalize(e){const n=this,t={};return zt.forEach(this,((a,i)=>{const o=zt.findKey(t,i);if(o)return n[o]=mr(a),void delete n[i];const r=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,n,t)=>n.toUpperCase()+t))}(i):String(i).trim();r!==i&&delete n[i],n[r]=mr(a),t[r]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return zt.forEach(this,((t,a)=>{null!=t&&!1!==t&&(n[a]=e&&zt.isArray(t)?t.join(", "):t)})),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,n])=>e+": "+n)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...n){const t=new this(e);return n.forEach((e=>t.set(e))),t}static accessor(e){const n=(this[lr]=this[lr]={accessors:{}}).accessors,t=this.prototype;function a(e){const a=dr(e);n[a]||(!function(e,n){const t=zt.toCamelCase(" "+n);["get","set","has"].forEach((a=>{Object.defineProperty(e,a+t,{value:function(e,t,i){return this[a].call(this,n,e,t,i)},configurable:!0})}))}(t,e),n[a]=!0)}return zt.isArray(e)?e.forEach(a):a(e),this}};function vr(e,n){const t=this||ur,a=n||t,i=hr.from(a.headers);let o=a.data;return zt.forEach(e,(function(e){o=e.call(t,o,i.normalize(),n?n.status:void 0)})),i.normalize(),o}function xr(e){return!(!e||!e.__CANCEL__)}function br(e,n,t){qt.call(this,null==e?"canceled":e,qt.ERR_CANCELED,n,t),this.name="CanceledError"}function gr(e,n,t){const a=t.config.validateStatus;t.status&&a&&!a(t.status)?n(new qt("Request failed with status code "+t.status,[qt.ERR_BAD_REQUEST,qt.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t)):e(t)}function yr(e,n,t){let a=!function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}(n);return e&&(a||0==t)?function(e,n){return n?e.replace(/\/?\/$/,"")+"/"+n.replace(/^\/+/,""):e}(e,n):n}hr.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),zt.reduceDescriptors(hr.prototype,(({value:e},n)=>{let t=n[0].toUpperCase()+n.slice(1);return{get:()=>e,set(e){this[t]=e}}})),zt.freezeMethods(hr),zt.inherits(br,qt,{__CANCEL__:!0});var Dr={},wr=s.parse,_r={ftp:21,gopher:70,http:80,https:443,ws:80,wss:443},Er=String.prototype.endsWith||function(e){return e.length<=this.length&&-1!==this.indexOf(e,this.length-e.length)};function Cr(e){return process.env[e.toLowerCase()]||process.env[e.toUpperCase()]||""}Dr.getProxyForUrl=function(e){var n="string"==typeof e?wr(e):e||{},t=n.protocol,a=n.host,i=n.port;if("string"!=typeof a||!a||"string"!=typeof t)return"";if(t=t.split(":",1)[0],!function(e,n){var t=(Cr("npm_config_no_proxy")||Cr("no_proxy")).toLowerCase();if(!t)return!0;if("*"===t)return!1;return t.split(/[,\s]/).every((function(t){if(!t)return!0;var a=t.match(/^(.+):(\d+)$/),i=a?a[1]:t,o=a?parseInt(a[2]):0;return!(!o||o===n)||(/^[.*]/.test(i)?("*"===i.charAt(0)&&(i=i.slice(1)),!Er.call(e,i)):e!==i)}))}(a=a.replace(/:\d*$/,""),i=parseInt(i)||_r[t]||0))return"";var o=Cr("npm_config_"+t+"_proxy")||Cr(t+"_proxy")||Cr("npm_config_proxy")||Cr("all_proxy");return o&&-1===o.indexOf("://")&&(o=t+"://"+o),o};var Fr,jr,kr,Ar,Tr,Sr={exports:{}},Or={exports:{}},Rr={exports:{}};function Br(){if(jr)return Fr;jr=1;var e=1e3,n=60*e,t=60*n,a=24*t,i=7*a,o=365.25*a;function r(e,n,t,a){var i=n>=1.5*t;return Math.round(e/t)+" "+a+(i?"s":"")}return Fr=function(s,c){c=c||{};var u=typeof s;if("string"===u&&s.length>0)return function(r){if((r=String(r)).length>100)return;var s=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(r);if(!s)return;var c=parseFloat(s[1]);switch((s[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return c*o;case"weeks":case"week":case"w":return c*i;case"days":case"day":case"d":return c*a;case"hours":case"hour":case"hrs":case"hr":case"h":return c*t;case"minutes":case"minute":case"mins":case"min":case"m":return c*n;case"seconds":case"second":case"secs":case"sec":case"s":return c*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return c;default:return}}(s);if("number"===u&&isFinite(s))return c.long?function(i){var o=Math.abs(i);if(o>=a)return r(i,o,a,"day");if(o>=t)return r(i,o,t,"hour");if(o>=n)return r(i,o,n,"minute");if(o>=e)return r(i,o,e,"second");return i+" ms"}(s):function(i){var o=Math.abs(i);if(o>=a)return Math.round(i/a)+"d";if(o>=t)return Math.round(i/t)+"h";if(o>=n)return Math.round(i/n)+"m";if(o>=e)return Math.round(i/e)+"s";return i+"ms"}(s);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(s))},Fr}function Pr(){if(Ar)return kr;return Ar=1,kr=function(e){function n(e){let a,i,o,r=null;function s(...e){if(!s.enabled)return;const t=s,i=Number(new Date),o=i-(a||i);t.diff=o,t.prev=a,t.curr=i,a=i,e[0]=n.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let r=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((a,i)=>{if("%%"===a)return"%";r++;const o=n.formatters[i];if("function"==typeof o){const n=e[r];a=o.call(t,n),e.splice(r,1),r--}return a})),n.formatArgs.call(t,e);(t.log||n.log).apply(t,e)}return s.namespace=e,s.useColors=n.useColors(),s.color=n.selectColor(e),s.extend=t,s.destroy=n.destroy,Object.defineProperty(s,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==r?r:(i!==n.namespaces&&(i=n.namespaces,o=n.enabled(e)),o),set:e=>{r=e}}),"function"==typeof n.init&&n.init(s),s}function t(e,t){const a=n(this.namespace+(void 0===t?":":t)+e);return a.log=this.log,a}function a(e,n){let t=0,a=0,i=-1,o=0;for(;t<e.length;)if(a<n.length&&(n[a]===e[t]||"*"===n[a]))"*"===n[a]?(i=a,o=t,a++):(t++,a++);else{if(-1===i)return!1;a=i+1,o++,t=o}for(;a<n.length&&"*"===n[a];)a++;return a===n.length}return n.debug=n,n.default=n,n.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},n.disable=function(){const e=[...n.names,...n.skips.map((e=>"-"+e))].join(",");return n.enable(""),e},n.enable=function(e){n.save(e),n.namespaces=e,n.names=[],n.skips=[];const t=("string"==typeof e?e:"").trim().replace(" ",",").split(",").filter(Boolean);for(const e of t)"-"===e[0]?n.skips.push(e.slice(1)):n.names.push(e)},n.enabled=function(e){for(const t of n.skips)if(a(e,t))return!1;for(const t of n.names)if(a(e,t))return!0;return!1},n.humanize=Br(),n.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((t=>{n[t]=e[t]})),n.names=[],n.skips=[],n.formatters={},n.selectColor=function(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return n.colors[Math.abs(t)%n.colors.length]},n.enable(n.load()),n},kr}var Lr,Ir,Nr,Ur,zr,qr,Mr,Hr={exports:{}};function $r(){return Ir?Lr:(Ir=1,Lr=(e,n=process.argv)=>{const t=e.startsWith("-")?"":1===e.length?"-":"--",a=n.indexOf(t+e),i=n.indexOf("--");return-1!==a&&(-1===i||a<i)})}function Gr(){return zr||(zr=1,function(n,t){const a=f,i=r;t.init=function(e){e.inspectOpts={};const n=Object.keys(t.inspectOpts);for(let a=0;a<n.length;a++)e.inspectOpts[n[a]]=t.inspectOpts[n[a]]},t.log=function(...e){return process.stderr.write(i.formatWithOptions(t.inspectOpts,...e)+"\n")},t.formatArgs=function(e){const{namespace:a,useColors:i}=this;if(i){const t=this.color,i="[3"+(t<8?t:"8;5;"+t),o=` ${i};1m${a} [0m`;e[0]=o+e[0].split("\n").join("\n"+o),e.push(i+"m+"+n.exports.humanize(this.diff)+"[0m")}else e[0]=function(){if(t.inspectOpts.hideDate)return"";return(new Date).toISOString()+" "}()+a+" "+e[0]},t.save=function(e){e?process.env.DEBUG=e:delete process.env.DEBUG},t.load=function(){return process.env.DEBUG},t.useColors=function(){return"colors"in t.inspectOpts?Boolean(t.inspectOpts.colors):a.isatty(process.stderr.fd)},t.destroy=i.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),t.colors=[6,2,3,4,5,1];try{const n=function(){if(Ur)return Nr;Ur=1;const n=e,t=f,a=$r(),{env:i}=process;let o;function r(e){return 0!==e&&{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function s(e,t){if(0===o)return 0;if(a("color=16m")||a("color=full")||a("color=truecolor"))return 3;if(a("color=256"))return 2;if(e&&!t&&void 0===o)return 0;const r=o||0;if("dumb"===i.TERM)return r;if("win32"===process.platform){const e=n.release().split(".");return Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if("CI"in i)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((e=>e in i))||"codeship"===i.CI_NAME?1:r;if("TEAMCITY_VERSION"in i)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(i.TEAMCITY_VERSION)?1:0;if("truecolor"===i.COLORTERM)return 3;if("TERM_PROGRAM"in i){const e=parseInt((i.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(i.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(i.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(i.TERM)||"COLORTERM"in i?1:r}return a("no-color")||a("no-colors")||a("color=false")||a("color=never")?o=0:(a("color")||a("colors")||a("color=true")||a("color=always"))&&(o=1),"FORCE_COLOR"in i&&(o="true"===i.FORCE_COLOR?1:"false"===i.FORCE_COLOR?0:0===i.FORCE_COLOR.length?1:Math.min(parseInt(i.FORCE_COLOR,10),3)),Nr={supportsColor:function(e){return r(s(e,e&&e.isTTY))},stdout:r(s(!0,t.isatty(1))),stderr:r(s(!0,t.isatty(2)))},Nr}();n&&(n.stderr||n).level>=2&&(t.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(e){}t.inspectOpts=Object.keys(process.env).filter((e=>/^debug_/i.test(e))).reduce(((e,n)=>{const t=n.substring(6).toLowerCase().replace(/_([a-z])/g,((e,n)=>n.toUpperCase()));let a=process.env[n];return a=!!/^(yes|on|true|enabled)$/i.test(a)||!/^(no|off|false|disabled)$/i.test(a)&&("null"===a?null:Number(a)),e[t]=a,e}),{}),n.exports=Pr()(t);const{formatters:o}=n.exports;o.o=function(e){return this.inspectOpts.colors=this.useColors,i.inspect(e,this.inspectOpts).split("\n").map((e=>e.trim())).join(" ")},o.O=function(e){return this.inspectOpts.colors=this.useColors,i.inspect(e,this.inspectOpts)}}(Hr,Hr.exports)),Hr.exports}function Wr(){return qr||(qr=1,e=Or,"undefined"==typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?e.exports=(Tr||(Tr=1,function(e,n){n.formatArgs=function(n){if(n[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+n[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const t="color: "+this.color;n.splice(1,0,t,"color: inherit");let a=0,i=0;n[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(a++,"%c"===e&&(i=a))})),n.splice(i,0,t)},n.save=function(e){try{e?n.storage.setItem("debug",e):n.storage.removeItem("debug")}catch(e){}},n.load=function(){let e;try{e=n.storage.getItem("debug")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e},n.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},n.storage=function(){try{return localStorage}catch(e){}}(),n.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),n.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],n.log=console.debug||console.log||(()=>{}),e.exports=Pr()(n);const{formatters:t}=e.exports;t.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}(Rr,Rr.exports)),Rr.exports):e.exports=Gr()),Or.exports;var e}var Kr,Vr,Jr,Yr=s,Xr=Yr.URL,Zr=c,Qr=u,es=l.Writable,ns=m,ts=function(){if(!Mr){try{Mr=Wr()("follow-redirects")}catch(e){}"function"!=typeof Mr&&(Mr=function(){})}Mr.apply(null,arguments)};Kr="undefined"!=typeof process,Vr="undefined"!=typeof window&&"undefined"!=typeof document,Jr=_s(Error.captureStackTrace),Kr||!Vr&&Jr||console.warn("The follow-redirects package should be excluded from browser builds.");var as=!1;try{ns(new Xr(""))}catch(e){as="ERR_INVALID_URL"===e.code}var is=["auth","host","hostname","href","path","pathname","port","protocol","query","search","hash"],os=["abort","aborted","connect","error","socket","timeout"],rs=Object.create(null);os.forEach((function(e){rs[e]=function(n,t,a){this._redirectable.emit(e,n,t,a)}}));var ss=ys("ERR_INVALID_URL","Invalid URL",TypeError),cs=ys("ERR_FR_REDIRECTION_FAILURE","Redirected request failed"),us=ys("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded",cs),ps=ys("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),ls=ys("ERR_STREAM_WRITE_AFTER_END","write after end"),ds=es.prototype.destroy||hs;function ms(e,n){es.call(this),this._sanitizeOptions(e),this._options=e,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],n&&this.on("response",n);var t=this;this._onNativeResponse=function(e){try{t._processResponse(e)}catch(e){t.emit("error",e instanceof cs?e:new cs({cause:e}))}},this._performRequest()}function fs(e){var n={maxRedirects:21,maxBodyLength:10485760},t={};return Object.keys(e).forEach((function(a){var i=a+":",o=t[i]=e[a],r=n[a]=Object.create(o);Object.defineProperties(r,{request:{value:function(e,a,o){var r;return r=e,Xr&&r instanceof Xr?e=bs(e):ws(e)?e=bs(vs(e)):(o=a,a=xs(e),e={protocol:i}),_s(a)&&(o=a,a=null),(a=Object.assign({maxRedirects:n.maxRedirects,maxBodyLength:n.maxBodyLength},e,a)).nativeProtocols=t,ws(a.host)||ws(a.hostname)||(a.hostname="::1"),ns.equal(a.protocol,i,"protocol mismatch"),ts("options",a),new ms(a,o)},configurable:!0,enumerable:!0,writable:!0},get:{value:function(e,n,t){var a=r.request(e,n,t);return a.end(),a},configurable:!0,enumerable:!0,writable:!0}})})),n}function hs(){}function vs(e){var n;if(as)n=new Xr(e);else if(!ws((n=xs(Yr.parse(e))).protocol))throw new ss({input:e});return n}function xs(e){if(/^\[/.test(e.hostname)&&!/^\[[:0-9a-f]+\]$/i.test(e.hostname))throw new ss({input:e.href||e});if(/^\[/.test(e.host)&&!/^\[[:0-9a-f]+\](:\d+)?$/i.test(e.host))throw new ss({input:e.href||e});return e}function bs(e,n){var t=n||{};for(var a of is)t[a]=e[a];return t.hostname.startsWith("[")&&(t.hostname=t.hostname.slice(1,-1)),""!==t.port&&(t.port=Number(t.port)),t.path=t.search?t.pathname+t.search:t.pathname,t}function gs(e,n){var t;for(var a in n)e.test(a)&&(t=n[a],delete n[a]);return null==t?void 0:String(t).trim()}function ys(e,n,t){function a(t){_s(Error.captureStackTrace)&&Error.captureStackTrace(this,this.constructor),Object.assign(this,t||{}),this.code=e,this.message=this.cause?n+": "+this.cause.message:n}return a.prototype=new(t||Error),Object.defineProperties(a.prototype,{constructor:{value:a,enumerable:!1},name:{value:"Error ["+e+"]",enumerable:!1}}),a}function Ds(e,n){for(var t of os)e.removeListener(t,rs[t]);e.on("error",hs),e.destroy(n)}function ws(e){return"string"==typeof e||e instanceof String}function _s(e){return"function"==typeof e}ms.prototype=Object.create(es.prototype),ms.prototype.abort=function(){Ds(this._currentRequest),this._currentRequest.abort(),this.emit("abort")},ms.prototype.destroy=function(e){return Ds(this._currentRequest,e),ds.call(this,e),this},ms.prototype.write=function(e,n,t){if(this._ending)throw new ls;if(!ws(e)&&("object"!=typeof(a=e)||!("length"in a)))throw new TypeError("data should be a string, Buffer or Uint8Array");var a;_s(n)&&(t=n,n=null),0!==e.length?this._requestBodyLength+e.length<=this._options.maxBodyLength?(this._requestBodyLength+=e.length,this._requestBodyBuffers.push({data:e,encoding:n}),this._currentRequest.write(e,n,t)):(this.emit("error",new ps),this.abort()):t&&t()},ms.prototype.end=function(e,n,t){if(_s(e)?(t=e,e=n=null):_s(n)&&(t=n,n=null),e){var a=this,i=this._currentRequest;this.write(e,n,(function(){a._ended=!0,i.end(null,null,t)})),this._ending=!0}else this._ended=this._ending=!0,this._currentRequest.end(null,null,t)},ms.prototype.setHeader=function(e,n){this._options.headers[e]=n,this._currentRequest.setHeader(e,n)},ms.prototype.removeHeader=function(e){delete this._options.headers[e],this._currentRequest.removeHeader(e)},ms.prototype.setTimeout=function(e,n){var t=this;function a(n){n.setTimeout(e),n.removeListener("timeout",n.destroy),n.addListener("timeout",n.destroy)}function i(n){t._timeout&&clearTimeout(t._timeout),t._timeout=setTimeout((function(){t.emit("timeout"),o()}),e),a(n)}function o(){t._timeout&&(clearTimeout(t._timeout),t._timeout=null),t.removeListener("abort",o),t.removeListener("error",o),t.removeListener("response",o),t.removeListener("close",o),n&&t.removeListener("timeout",n),t.socket||t._currentRequest.removeListener("socket",i)}return n&&this.on("timeout",n),this.socket?i(this.socket):this._currentRequest.once("socket",i),this.on("socket",a),this.on("abort",o),this.on("error",o),this.on("response",o),this.on("close",o),this},["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach((function(e){ms.prototype[e]=function(n,t){return this._currentRequest[e](n,t)}})),["aborted","connection","socket"].forEach((function(e){Object.defineProperty(ms.prototype,e,{get:function(){return this._currentRequest[e]}})})),ms.prototype._sanitizeOptions=function(e){if(e.headers||(e.headers={}),e.host&&(e.hostname||(e.hostname=e.host),delete e.host),!e.pathname&&e.path){var n=e.path.indexOf("?");n<0?e.pathname=e.path:(e.pathname=e.path.substring(0,n),e.search=e.path.substring(n))}},ms.prototype._performRequest=function(){var e=this._options.protocol,n=this._options.nativeProtocols[e];if(!n)throw new TypeError("Unsupported protocol "+e);if(this._options.agents){var t=e.slice(0,-1);this._options.agent=this._options.agents[t]}var a=this._currentRequest=n.request(this._options,this._onNativeResponse);for(var i of(a._redirectable=this,os))a.on(i,rs[i]);if(this._currentUrl=/^\//.test(this._options.path)?Yr.format(this._options):this._options.path,this._isRedirect){var o=0,r=this,s=this._requestBodyBuffers;!function e(n){if(a===r._currentRequest)if(n)r.emit("error",n);else if(o<s.length){var t=s[o++];a.finished||a.write(t.data,t.encoding,e)}else r._ended&&a.end()}()}},ms.prototype._processResponse=function(e){var n=e.statusCode;this._options.trackRedirects&&this._redirects.push({url:this._currentUrl,headers:e.headers,statusCode:n});var t,a=e.headers.location;if(!a||!1===this._options.followRedirects||n<300||n>=400)return e.responseUrl=this._currentUrl,e.redirects=this._redirects,this.emit("response",e),void(this._requestBodyBuffers=[]);if(Ds(this._currentRequest),e.destroy(),++this._redirectCount>this._options.maxRedirects)throw new us;var i=this._options.beforeRedirect;i&&(t=Object.assign({Host:e.req.getHeader("host")},this._options.headers));var o=this._options.method;((301===n||302===n)&&"POST"===this._options.method||303===n&&!/^(?:GET|HEAD)$/.test(this._options.method))&&(this._options.method="GET",this._requestBodyBuffers=[],gs(/^content-/i,this._options.headers));var r,s,c=gs(/^host$/i,this._options.headers),u=vs(this._currentUrl),p=c||u.host,l=/^\w+:/.test(a)?this._currentUrl:Yr.format(Object.assign(u,{host:p})),d=(r=a,s=l,as?new Xr(r,s):vs(Yr.resolve(s,r)));if(ts("redirecting to",d.href),this._isRedirect=!0,bs(d,this._options),(d.protocol!==u.protocol&&"https:"!==d.protocol||d.host!==p&&!function(e,n){ns(ws(e)&&ws(n));var t=e.length-n.length-1;return t>0&&"."===e[t]&&e.endsWith(n)}(d.host,p))&&gs(/^(?:(?:proxy-)?authorization|cookie)$/i,this._options.headers),_s(i)){var m={headers:e.headers,statusCode:n},f={url:l,method:o,headers:t};i(this._options,m,f),this._sanitizeOptions(this._options)}this._performRequest()},Sr.exports=fs({http:Zr,https:Qr}),Sr.exports.wrap=fs;const Es="1.8.4";function Cs(e){const n=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return n&&n[1]||""}const Fs=/^(?:([^;]+);)?(?:[^;]+;)?(base64|),([\s\S]*)$/;const js=Symbol("internals");class ks extends l.Transform{constructor(e){e=zt.toFlatObject(e,{maxRate:0,chunkSize:65536,minChunkSize:100,timeWindow:500,ticksRate:2,samplesCount:15},null,((e,n)=>!zt.isUndefined(n[e]))),super({readableHighWaterMark:e.chunkSize});const n=this[js]={timeWindow:e.timeWindow,chunkSize:e.chunkSize,maxRate:e.maxRate,minChunkSize:e.minChunkSize,bytesSeen:0,isCaptured:!1,notifiedBytesLoaded:0,ts:Date.now(),bytes:0,onReadCallback:null};this.on("newListener",(e=>{"progress"===e&&(n.isCaptured||(n.isCaptured=!0))}))}_read(e){const n=this[js];return n.onReadCallback&&n.onReadCallback(),super._read(e)}_transform(e,n,t){const a=this[js],i=a.maxRate,o=this.readableHighWaterMark,r=a.timeWindow,s=i/(1e3/r),c=!1!==a.minChunkSize?Math.max(a.minChunkSize,.01*s):0,u=(e,n)=>{const t=Buffer.byteLength(e);a.bytesSeen+=t,a.bytes+=t,a.isCaptured&&this.emit("progress",a.bytesSeen),this.push(e)?process.nextTick(n):a.onReadCallback=()=>{a.onReadCallback=null,process.nextTick(n)}},p=(e,n)=>{const t=Buffer.byteLength(e);let p,l=null,d=o,m=0;if(i){const e=Date.now();(!a.ts||(m=e-a.ts)>=r)&&(a.ts=e,p=s-a.bytes,a.bytes=p<0?-p:0,m=0),p=s-a.bytes}if(i){if(p<=0)return setTimeout((()=>{n(null,e)}),r-m);p<d&&(d=p)}d&&t>d&&t-d>c&&(l=e.subarray(d),e=e.subarray(0,d)),u(e,l?()=>{process.nextTick(n,null,l)}:n)};p(e,(function e(n,a){if(n)return t(n);a?p(a,e):t(null)}))}}const{asyncIterator:As}=Symbol,Ts=async function*(e){e.stream?yield*e.stream():e.arrayBuffer?yield await e.arrayBuffer():e[As]?yield*e[As]():yield e},Ss=sr.ALPHABET.ALPHA_DIGIT+"-_",Os="function"==typeof TextEncoder?new TextEncoder:new r.TextEncoder,Rs="\r\n",Bs=Os.encode(Rs);class Ps{constructor(e,n){const{escapeName:t}=this.constructor,a=zt.isString(n);let i=`Content-Disposition: form-data; name="${t(e)}"${!a&&n.name?`; filename="${t(n.name)}"`:""}${Rs}`;a?n=Os.encode(String(n).replace(/\r?\n|\r\n?/g,Rs)):i+=`Content-Type: ${n.type||"application/octet-stream"}${Rs}`,this.headers=Os.encode(i+Rs),this.contentLength=a?n.byteLength:n.size,this.size=this.headers.byteLength+this.contentLength+2,this.name=e,this.value=n}async*encode(){yield this.headers;const{value:e}=this;zt.isTypedArray(e)?yield e:yield*Ts(e),yield Bs}static escapeName(e){return String(e).replace(/[\r\n"]/g,(e=>({"\r":"%0D","\n":"%0A",'"':"%22"}[e])))}}class Ls extends l.Transform{__transform(e,n,t){this.push(e),t()}_transform(e,n,t){if(0!==e.length&&(this._transform=this.__transform,120!==e[0])){const e=Buffer.alloc(2);e[0]=120,e[1]=156,this.push(e,n)}this.__transform(e,n,t)}}const Is=(e,n)=>zt.isAsyncFn(e)?function(...t){const a=t.pop();e.apply(this,t).then((e=>{try{n?a(null,...n(e)):a(null,e)}catch(e){a(e)}}),a)}:e;const Ns=(e,n,t=3)=>{let a=0;const i=function(e,n){e=e||10;const t=new Array(e),a=new Array(e);let i,o=0,r=0;return n=void 0!==n?n:1e3,function(s){const c=Date.now(),u=a[r];i||(i=c),t[o]=s,a[o]=c;let p=r,l=0;for(;p!==o;)l+=t[p++],p%=e;if(o=(o+1)%e,o===r&&(r=(r+1)%e),c-i<n)return;const d=u&&c-u;return d?Math.round(1e3*l/d):void 0}}(50,250);return function(e,n){let t,a,i=0,o=1e3/n;const r=(n,o=Date.now())=>{i=o,t=null,a&&(clearTimeout(a),a=null),e.apply(null,n)};return[(...e)=>{const n=Date.now(),s=n-i;s>=o?r(e,n):(t=e,a||(a=setTimeout((()=>{a=null,r(t)}),o-s)))},()=>t&&r(t)]}((t=>{const o=t.loaded,r=t.lengthComputable?t.total:void 0,s=o-a,c=i(s);a=o;e({loaded:o,total:r,progress:r?o/r:void 0,bytes:s,rate:c||void 0,estimated:c&&r&&o<=r?(r-o)/c:void 0,event:t,lengthComputable:null!=r,[n?"download":"upload"]:!0})}),t)},Us=(e,n)=>{const t=null!=e;return[a=>n[0]({lengthComputable:t,total:e,loaded:a}),n[1]]},zs=e=>(...n)=>zt.asap((()=>e(...n))),qs={flush:h.constants.Z_SYNC_FLUSH,finishFlush:h.constants.Z_SYNC_FLUSH},Ms={flush:h.constants.BROTLI_OPERATION_FLUSH,finishFlush:h.constants.BROTLI_OPERATION_FLUSH},Hs=zt.isFunction(h.createBrotliDecompress),{http:$s,https:Gs}=Sr.exports,Ws=/https:?/,Ks=sr.protocols.map((e=>e+":")),Vs=(e,[n,t])=>(e.on("end",t).on("error",t),n);function Js(e,n){e.beforeRedirects.proxy&&e.beforeRedirects.proxy(e),e.beforeRedirects.config&&e.beforeRedirects.config(e,n)}function Ys(e,n,t){let a=n;if(!a&&!1!==a){const e=Dr.getProxyForUrl(t);e&&(a=new URL(e))}if(a){if(a.username&&(a.auth=(a.username||"")+":"+(a.password||"")),a.auth){(a.auth.username||a.auth.password)&&(a.auth=(a.auth.username||"")+":"+(a.auth.password||""));const n=Buffer.from(a.auth,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+n}e.headers.host=e.hostname+(e.port?":"+e.port:"");const n=a.hostname||a.host;e.hostname=n,e.host=n,e.port=a.port,e.path=t,a.protocol&&(e.protocol=a.protocol.includes(":")?a.protocol:`${a.protocol}:`)}e.beforeRedirects.proxy=function(e){Ys(e,n,e.href)}}const Xs="undefined"!=typeof process&&"process"===zt.kindOf(process),Zs=(e,n)=>(({address:e,family:n})=>{if(!zt.isString(e))throw TypeError("address must be a string");return{address:e,family:n||(e.indexOf(".")<0?6:4)}})(zt.isObject(e)?e:{address:e,family:n});var Qs=Xs&&function(e){return n=async function(n,t,a){let{data:i,lookup:o,family:s}=e;const{responseType:p,responseEncoding:m}=e,f=e.method.toUpperCase();let v,b,g=!1;if(o){const e=Is(o,(e=>zt.isArray(e)?e:[e]));o=(n,t,a)=>{e(n,t,((e,n,i)=>{if(e)return a(e);const o=zt.isArray(n)?n.map((e=>Zs(e))):[Zs(n,i)];t.all?a(e,o):a(e,o[0].address,o[0].family)}))}}const y=new x,D=()=>{e.cancelToken&&e.cancelToken.unsubscribe(w),e.signal&&e.signal.removeEventListener("abort",w),y.removeAllListeners()};function w(n){y.emit("abort",!n||n.type?new br(null,e,b):n)}a(((e,n)=>{v=!0,n&&(g=!0,D())})),y.once("abort",t),(e.cancelToken||e.signal)&&(e.cancelToken&&e.cancelToken.subscribe(w),e.signal&&(e.signal.aborted?w():e.signal.addEventListener("abort",w)));const _=yr(e.baseURL,e.url,e.allowAbsoluteUrls),E=new URL(_,sr.hasBrowserEnv?sr.origin:void 0),C=E.protocol||Ks[0];if("data:"===C){let a;if("GET"!==f)return gr(n,t,{status:405,statusText:"method not allowed",headers:{},config:e});try{a=function(e,n,t){const a=t&&t.Blob||sr.classes.Blob,i=Cs(e);if(void 0===n&&a&&(n=!0),"data"===i){e=i.length?e.slice(i.length+1):e;const t=Fs.exec(e);if(!t)throw new qt("Invalid URL",qt.ERR_INVALID_URL);const o=t[1],r=t[2],s=t[3],c=Buffer.from(decodeURIComponent(s),r?"base64":"utf8");if(n){if(!a)throw new qt("Blob is not supported",qt.ERR_NOT_SUPPORT);return new a([c],{type:o})}return c}throw new qt("Unsupported protocol "+i,qt.ERR_NOT_SUPPORT)}(e.url,"blob"===p,{Blob:e.env&&e.env.Blob})}catch(n){throw qt.from(n,qt.ERR_BAD_REQUEST,e)}return"text"===p?(a=a.toString(m),m&&"utf8"!==m||(a=zt.stripBOM(a))):"stream"===p&&(a=l.Readable.from(a)),gr(n,t,{data:a,status:200,statusText:"OK",headers:new hr,config:e})}if(-1===Ks.indexOf(C))return t(new qt("Unsupported protocol "+C,qt.ERR_BAD_REQUEST,e));const F=hr.from(e.headers).normalize();F.set("User-Agent","axios/"+Es,!1);const{onUploadProgress:j,onDownloadProgress:k}=e,A=e.maxRate;let T,S;if(zt.isSpecCompliantForm(i)){const e=F.getContentType(/boundary=([-_\w\d]{10,70})/i);i=((e,n,t)=>{const{tag:a="form-data-boundary",size:i=25,boundary:o=a+"-"+sr.generateString(i,Ss)}=t||{};if(!zt.isFormData(e))throw TypeError("FormData instance required");if(o.length<1||o.length>70)throw Error("boundary must be 10-70 characters long");const r=Os.encode("--"+o+Rs),s=Os.encode("--"+o+"--"+Rs+Rs);let c=s.byteLength;const u=Array.from(e.entries()).map((([e,n])=>{const t=new Ps(e,n);return c+=t.size,t}));c+=r.byteLength*u.length,c=zt.toFiniteNumber(c);const p={"Content-Type":`multipart/form-data; boundary=${o}`};return Number.isFinite(c)&&(p["Content-Length"]=c),n&&n(p),d.from(async function*(){for(const e of u)yield r,yield*e.encode();yield s}())})(i,(e=>{F.set(e)}),{tag:`axios-${Es}-boundary`,boundary:e&&e[1]||void 0})}else if(zt.isFormData(i)&&zt.isFunction(i.getHeaders)){if(F.set(i.getHeaders()),!F.hasContentLength())try{const e=await r.promisify(i.getLength).call(i);Number.isFinite(e)&&e>=0&&F.setContentLength(e)}catch(e){}}else if(zt.isBlob(i)||zt.isFile(i))i.size&&F.setContentType(i.type||"application/octet-stream"),F.setContentLength(i.size||0),i=l.Readable.from(Ts(i));else if(i&&!zt.isStream(i)){if(Buffer.isBuffer(i));else if(zt.isArrayBuffer(i))i=Buffer.from(new Uint8Array(i));else{if(!zt.isString(i))return t(new qt("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",qt.ERR_BAD_REQUEST,e));i=Buffer.from(i,"utf-8")}if(F.setContentLength(i.length,!1),e.maxBodyLength>-1&&i.length>e.maxBodyLength)return t(new qt("Request body larger than maxBodyLength limit",qt.ERR_BAD_REQUEST,e))}const O=zt.toFiniteNumber(F.getContentLength());let R,B;zt.isArray(A)?(T=A[0],S=A[1]):T=S=A,i&&(j||T)&&(zt.isStream(i)||(i=l.Readable.from(i,{objectMode:!1})),i=l.pipeline([i,new ks({maxRate:zt.toFiniteNumber(T)})],zt.noop),j&&i.on("progress",Vs(i,Us(O,Ns(zs(j),!1,3))))),e.auth&&(R=(e.auth.username||"")+":"+(e.auth.password||"")),!R&&E.username&&(R=E.username+":"+E.password),R&&F.delete("authorization");try{B=Vo(E.pathname+E.search,e.params,e.paramsSerializer).replace(/^\?/,"")}catch(n){const a=new Error(n.message);return a.config=e,a.url=e.url,a.exists=!0,t(a)}F.set("Accept-Encoding","gzip, compress, deflate"+(Hs?", br":""),!1);const P={path:B,method:f,headers:F.toJSON(),agents:{http:e.httpAgent,https:e.httpsAgent},auth:R,protocol:C,family:s,beforeRedirect:Js,beforeRedirects:{}};let L;!zt.isUndefined(o)&&(P.lookup=o),e.socketPath?P.socketPath=e.socketPath:(P.hostname=E.hostname.startsWith("[")?E.hostname.slice(1,-1):E.hostname,P.port=E.port,Ys(P,e.proxy,C+"//"+E.hostname+(E.port?":"+E.port:"")+P.path));const I=Ws.test(P.protocol);if(P.agent=I?e.httpsAgent:e.httpAgent,e.transport?L=e.transport:0===e.maxRedirects?L=I?u:c:(e.maxRedirects&&(P.maxRedirects=e.maxRedirects),e.beforeRedirect&&(P.beforeRedirects.config=e.beforeRedirect),L=I?Gs:$s),e.maxBodyLength>-1?P.maxBodyLength=e.maxBodyLength:P.maxBodyLength=1/0,e.insecureHTTPParser&&(P.insecureHTTPParser=e.insecureHTTPParser),b=L.request(P,(function(a){if(b.destroyed)return;const i=[a],o=+a.headers["content-length"];if(k||S){const e=new ks({maxRate:zt.toFiniteNumber(S)});k&&e.on("progress",Vs(e,Us(o,Ns(zs(k),!0,3)))),i.push(e)}let r=a;const s=a.req||b;if(!1!==e.decompress&&a.headers["content-encoding"])switch("HEAD"!==f&&204!==a.statusCode||delete a.headers["content-encoding"],(a.headers["content-encoding"]||"").toLowerCase()){case"gzip":case"x-gzip":case"compress":case"x-compress":i.push(h.createUnzip(qs)),delete a.headers["content-encoding"];break;case"deflate":i.push(new Ls),i.push(h.createUnzip(qs)),delete a.headers["content-encoding"];break;case"br":Hs&&(i.push(h.createBrotliDecompress(Ms)),delete a.headers["content-encoding"])}r=i.length>1?l.pipeline(i,zt.noop):i[0];const c=l.finished(r,(()=>{c(),D()})),u={status:a.statusCode,statusText:a.statusMessage,headers:new hr(a.headers),config:e,request:s};if("stream"===p)u.data=r,gr(n,t,u);else{const a=[];let i=0;r.on("data",(function(n){a.push(n),i+=n.length,e.maxContentLength>-1&&i>e.maxContentLength&&(g=!0,r.destroy(),t(new qt("maxContentLength size of "+e.maxContentLength+" exceeded",qt.ERR_BAD_RESPONSE,e,s)))})),r.on("aborted",(function(){if(g)return;const n=new qt("stream has been aborted",qt.ERR_BAD_RESPONSE,e,s);r.destroy(n),t(n)})),r.on("error",(function(n){b.destroyed||t(qt.from(n,null,e,s))})),r.on("end",(function(){try{let e=1===a.length?a[0]:Buffer.concat(a);"arraybuffer"!==p&&(e=e.toString(m),m&&"utf8"!==m||(e=zt.stripBOM(e))),u.data=e}catch(n){return t(qt.from(n,null,e,u.request,u))}gr(n,t,u)}))}y.once("abort",(e=>{r.destroyed||(r.emit("error",e),r.destroy())}))})),y.once("abort",(e=>{t(e),b.destroy(e)})),b.on("error",(function(n){t(qt.from(n,null,e,b))})),b.on("socket",(function(e){e.setKeepAlive(!0,6e4)})),e.timeout){const n=parseInt(e.timeout,10);if(Number.isNaN(n))return void t(new qt("error trying to parse `config.timeout` to int",qt.ERR_BAD_OPTION_VALUE,e,b));b.setTimeout(n,(function(){if(v)return;let n=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const a=e.transitional||Yo;e.timeoutErrorMessage&&(n=e.timeoutErrorMessage),t(new qt(n,a.clarifyTimeoutError?qt.ETIMEDOUT:qt.ECONNABORTED,e,b)),w()}))}if(zt.isStream(i)){let n=!1,t=!1;i.on("end",(()=>{n=!0})),i.once("error",(e=>{t=!0,b.destroy(e)})),i.on("close",(()=>{n||t||w(new br("Request stream has been aborted",e,b))})),i.pipe(b)}else b.end(i)},new Promise(((e,t)=>{let a,i;const o=(e,n)=>{i||(i=!0,a&&a(e,n))},r=e=>{o(e,!0),t(e)};n((n=>{o(n),e(n)}),r,(e=>a=e)).catch(r)}));var n},ec=sr.hasStandardBrowserEnv?((e,n)=>t=>(t=new URL(t,sr.origin),e.protocol===t.protocol&&e.host===t.host&&(n||e.port===t.port)))(new URL(sr.origin),sr.navigator&&/(msie|trident)/i.test(sr.navigator.userAgent)):()=>!0,nc=sr.hasStandardBrowserEnv?{write(e,n,t,a,i,o){const r=[e+"="+encodeURIComponent(n)];zt.isNumber(t)&&r.push("expires="+new Date(t).toGMTString()),zt.isString(a)&&r.push("path="+a),zt.isString(i)&&r.push("domain="+i),!0===o&&r.push("secure"),document.cookie=r.join("; ")},read(e){const n=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read:()=>null,remove(){}};const tc=e=>e instanceof hr?{...e}:e;function ac(e,n){n=n||{};const t={};function a(e,n,t,a){return zt.isPlainObject(e)&&zt.isPlainObject(n)?zt.merge.call({caseless:a},e,n):zt.isPlainObject(n)?zt.merge({},n):zt.isArray(n)?n.slice():n}function i(e,n,t,i){return zt.isUndefined(n)?zt.isUndefined(e)?void 0:a(void 0,e,0,i):a(e,n,0,i)}function o(e,n){if(!zt.isUndefined(n))return a(void 0,n)}function r(e,n){return zt.isUndefined(n)?zt.isUndefined(e)?void 0:a(void 0,e):a(void 0,n)}function s(t,i,o){return o in n?a(t,i):o in e?a(void 0,t):void 0}const c={url:o,method:o,data:o,baseURL:r,transformRequest:r,transformResponse:r,paramsSerializer:r,timeout:r,timeoutMessage:r,withCredentials:r,withXSRFToken:r,adapter:r,responseType:r,xsrfCookieName:r,xsrfHeaderName:r,onUploadProgress:r,onDownloadProgress:r,decompress:r,maxContentLength:r,maxBodyLength:r,beforeRedirect:r,transport:r,httpAgent:r,httpsAgent:r,cancelToken:r,socketPath:r,responseEncoding:r,validateStatus:s,headers:(e,n,t)=>i(tc(e),tc(n),0,!0)};return zt.forEach(Object.keys(Object.assign({},e,n)),(function(a){const o=c[a]||i,r=o(e[a],n[a],a);zt.isUndefined(r)&&o!==s||(t[a]=r)})),t}var ic=e=>{const n=ac({},e);let t,{data:a,withXSRFToken:i,xsrfHeaderName:o,xsrfCookieName:r,headers:s,auth:c}=n;if(n.headers=s=hr.from(s),n.url=Vo(yr(n.baseURL,n.url,n.allowAbsoluteUrls),e.params,e.paramsSerializer),c&&s.set("Authorization","Basic "+btoa((c.username||"")+":"+(c.password?unescape(encodeURIComponent(c.password)):""))),zt.isFormData(a))if(sr.hasStandardBrowserEnv||sr.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if(!1!==(t=s.getContentType())){const[e,...n]=t?t.split(";").map((e=>e.trim())).filter(Boolean):[];s.setContentType([e||"multipart/form-data",...n].join("; "))}if(sr.hasStandardBrowserEnv&&(i&&zt.isFunction(i)&&(i=i(n)),i||!1!==i&&ec(n.url))){const e=o&&r&&nc.read(r);e&&s.set(o,e)}return n};var oc="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(n,t){const a=ic(e);let i=a.data;const o=hr.from(a.headers).normalize();let r,s,c,u,p,{responseType:l,onUploadProgress:d,onDownloadProgress:m}=a;function f(){u&&u(),p&&p(),a.cancelToken&&a.cancelToken.unsubscribe(r),a.signal&&a.signal.removeEventListener("abort",r)}let h=new XMLHttpRequest;function v(){if(!h)return;const a=hr.from("getAllResponseHeaders"in h&&h.getAllResponseHeaders());gr((function(e){n(e),f()}),(function(e){t(e),f()}),{data:l&&"text"!==l&&"json"!==l?h.response:h.responseText,status:h.status,statusText:h.statusText,headers:a,config:e,request:h}),h=null}h.open(a.method.toUpperCase(),a.url,!0),h.timeout=a.timeout,"onloadend"in h?h.onloadend=v:h.onreadystatechange=function(){h&&4===h.readyState&&(0!==h.status||h.responseURL&&0===h.responseURL.indexOf("file:"))&&setTimeout(v)},h.onabort=function(){h&&(t(new qt("Request aborted",qt.ECONNABORTED,e,h)),h=null)},h.onerror=function(){t(new qt("Network Error",qt.ERR_NETWORK,e,h)),h=null},h.ontimeout=function(){let n=a.timeout?"timeout of "+a.timeout+"ms exceeded":"timeout exceeded";const i=a.transitional||Yo;a.timeoutErrorMessage&&(n=a.timeoutErrorMessage),t(new qt(n,i.clarifyTimeoutError?qt.ETIMEDOUT:qt.ECONNABORTED,e,h)),h=null},void 0===i&&o.setContentType(null),"setRequestHeader"in h&&zt.forEach(o.toJSON(),(function(e,n){h.setRequestHeader(n,e)})),zt.isUndefined(a.withCredentials)||(h.withCredentials=!!a.withCredentials),l&&"json"!==l&&(h.responseType=a.responseType),m&&([c,p]=Ns(m,!0),h.addEventListener("progress",c)),d&&h.upload&&([s,u]=Ns(d),h.upload.addEventListener("progress",s),h.upload.addEventListener("loadend",u)),(a.cancelToken||a.signal)&&(r=n=>{h&&(t(!n||n.type?new br(null,e,h):n),h.abort(),h=null)},a.cancelToken&&a.cancelToken.subscribe(r),a.signal&&(a.signal.aborted?r():a.signal.addEventListener("abort",r)));const x=Cs(a.url);x&&-1===sr.protocols.indexOf(x)?t(new qt("Unsupported protocol "+x+":",qt.ERR_BAD_REQUEST,e)):h.send(i||null)}))};const rc=(e,n)=>{const{length:t}=e=e?e.filter(Boolean):[];if(n||t){let t,a=new AbortController;const i=function(e){if(!t){t=!0,r();const n=e instanceof Error?e:this.reason;a.abort(n instanceof qt?n:new br(n instanceof Error?n.message:n))}};let o=n&&setTimeout((()=>{o=null,i(new qt(`timeout ${n} of ms exceeded`,qt.ETIMEDOUT))}),n);const r=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach((e=>{e.unsubscribe?e.unsubscribe(i):e.removeEventListener("abort",i)})),e=null)};e.forEach((e=>e.addEventListener("abort",i)));const{signal:s}=a;return s.unsubscribe=()=>zt.asap(r),s}},sc=function*(e,n){let t=e.byteLength;if(t<n)return void(yield e);let a,i=0;for(;i<t;)a=i+n,yield e.slice(i,a),i=a},cc=async function*(e){if(e[Symbol.asyncIterator])return void(yield*e);const n=e.getReader();try{for(;;){const{done:e,value:t}=await n.read();if(e)break;yield t}}finally{await n.cancel()}},uc=(e,n,t,a)=>{const i=async function*(e,n){for await(const t of cc(e))yield*sc(t,n)}(e,n);let o,r=0,s=e=>{o||(o=!0,a&&a(e))};return new ReadableStream({async pull(e){try{const{done:n,value:a}=await i.next();if(n)return s(),void e.close();let o=a.byteLength;if(t){let e=r+=o;t(e)}e.enqueue(new Uint8Array(a))}catch(e){throw s(e),e}},cancel:e=>(s(e),i.return())},{highWaterMark:2})},pc="function"==typeof fetch&&"function"==typeof Request&&"function"==typeof Response,lc=pc&&"function"==typeof ReadableStream,dc=pc&&("function"==typeof TextEncoder?(mc=new TextEncoder,e=>mc.encode(e)):async e=>new Uint8Array(await new Response(e).arrayBuffer()));var mc;const fc=(e,...n)=>{try{return!!e(...n)}catch(e){return!1}},hc=lc&&fc((()=>{let e=!1;const n=new Request(sr.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!n})),vc=lc&&fc((()=>zt.isReadableStream(new Response("").body))),xc={stream:vc&&(e=>e.body)};var bc;pc&&(bc=new Response,["text","arrayBuffer","blob","formData","stream"].forEach((e=>{!xc[e]&&(xc[e]=zt.isFunction(bc[e])?n=>n[e]():(n,t)=>{throw new qt(`Response type '${e}' is not supported`,qt.ERR_NOT_SUPPORT,t)})})));const gc=async(e,n)=>{const t=zt.toFiniteNumber(e.getContentLength());return null==t?(async e=>{if(null==e)return 0;if(zt.isBlob(e))return e.size;if(zt.isSpecCompliantForm(e)){const n=new Request(sr.origin,{method:"POST",body:e});return(await n.arrayBuffer()).byteLength}return zt.isArrayBufferView(e)||zt.isArrayBuffer(e)?e.byteLength:(zt.isURLSearchParams(e)&&(e+=""),zt.isString(e)?(await dc(e)).byteLength:void 0)})(n):t};var yc=pc&&(async e=>{let{url:n,method:t,data:a,signal:i,cancelToken:o,timeout:r,onDownloadProgress:s,onUploadProgress:c,responseType:u,headers:p,withCredentials:l="same-origin",fetchOptions:d}=ic(e);u=u?(u+"").toLowerCase():"text";let m,f=rc([i,o&&o.toAbortSignal()],r);const h=f&&f.unsubscribe&&(()=>{f.unsubscribe()});let v;try{if(c&&hc&&"get"!==t&&"head"!==t&&0!==(v=await gc(p,a))){let e,t=new Request(n,{method:"POST",body:a,duplex:"half"});if(zt.isFormData(a)&&(e=t.headers.get("content-type"))&&p.setContentType(e),t.body){const[e,n]=Us(v,Ns(zs(c)));a=uc(t.body,65536,e,n)}}zt.isString(l)||(l=l?"include":"omit");const i="credentials"in Request.prototype;m=new Request(n,{...d,signal:f,method:t.toUpperCase(),headers:p.normalize().toJSON(),body:a,duplex:"half",credentials:i?l:void 0});let o=await fetch(m);const r=vc&&("stream"===u||"response"===u);if(vc&&(s||r&&h)){const e={};["status","statusText","headers"].forEach((n=>{e[n]=o[n]}));const n=zt.toFiniteNumber(o.headers.get("content-length")),[t,a]=s&&Us(n,Ns(zs(s),!0))||[];o=new Response(uc(o.body,65536,t,(()=>{a&&a(),h&&h()})),e)}u=u||"text";let x=await xc[zt.findKey(xc,u)||"text"](o,e);return!r&&h&&h(),await new Promise(((n,t)=>{gr(n,t,{data:x,headers:hr.from(o.headers),status:o.status,statusText:o.statusText,config:e,request:m})}))}catch(n){if(h&&h(),n&&"TypeError"===n.name&&/fetch/i.test(n.message))throw Object.assign(new qt("Network Error",qt.ERR_NETWORK,e,m),{cause:n.cause||n});throw qt.from(n,n&&n.code,e,m)}});const Dc={http:Qs,xhr:oc,fetch:yc};zt.forEach(Dc,((e,n)=>{if(e){try{Object.defineProperty(e,"name",{value:n})}catch(e){}Object.defineProperty(e,"adapterName",{value:n})}}));const wc=e=>`- ${e}`,_c=e=>zt.isFunction(e)||null===e||!1===e;var Ec=e=>{e=zt.isArray(e)?e:[e];const{length:n}=e;let t,a;const i={};for(let o=0;o<n;o++){let n;if(t=e[o],a=t,!_c(t)&&(a=Dc[(n=String(t)).toLowerCase()],void 0===a))throw new qt(`Unknown adapter '${n}'`);if(a)break;i[n||"#"+o]=a}if(!a){const e=Object.entries(i).map((([e,n])=>`adapter ${e} `+(!1===n?"is not supported by the environment":"is not available in the build")));throw new qt("There is no suitable adapter to dispatch the request "+(n?e.length>1?"since :\n"+e.map(wc).join("\n"):" "+wc(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return a};function Cc(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new br(null,e)}function Fc(e){Cc(e),e.headers=hr.from(e.headers),e.data=vr.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1);return Ec(e.adapter||ur.adapter)(e).then((function(n){return Cc(e),n.data=vr.call(e,e.transformResponse,n),n.headers=hr.from(n.headers),n}),(function(n){return xr(n)||(Cc(e),n&&n.response&&(n.response.data=vr.call(e,e.transformResponse,n.response),n.response.headers=hr.from(n.response.headers))),Promise.reject(n)}))}const jc={};["object","boolean","number","function","string","symbol"].forEach(((e,n)=>{jc[e]=function(t){return typeof t===e||"a"+(n<1?"n ":" ")+e}}));const kc={};jc.transitional=function(e,n,t){function a(e,n){return"[Axios v1.8.4] Transitional option '"+e+"'"+n+(t?". "+t:"")}return(t,i,o)=>{if(!1===e)throw new qt(a(i," has been removed"+(n?" in "+n:"")),qt.ERR_DEPRECATED);return n&&!kc[i]&&(kc[i]=!0,console.warn(a(i," has been deprecated since v"+n+" and will be removed in the near future"))),!e||e(t,i,o)}},jc.spelling=function(e){return(n,t)=>(console.warn(`${t} is likely a misspelling of ${e}`),!0)};var Ac={assertOptions:function(e,n,t){if("object"!=typeof e)throw new qt("options must be an object",qt.ERR_BAD_OPTION_VALUE);const a=Object.keys(e);let i=a.length;for(;i-- >0;){const o=a[i],r=n[o];if(r){const n=e[o],t=void 0===n||r(n,o,e);if(!0!==t)throw new qt("option "+o+" must be "+t,qt.ERR_BAD_OPTION_VALUE)}else if(!0!==t)throw new qt("Unknown option "+o,qt.ERR_BAD_OPTION)}},validators:jc};const Tc=Ac.validators;let Sc=class{constructor(e){this.defaults=e,this.interceptors={request:new Jo,response:new Jo}}async request(e,n){try{return await this._request(e,n)}catch(e){if(e instanceof Error){let n={};Error.captureStackTrace?Error.captureStackTrace(n):n=new Error;const t=n.stack?n.stack.replace(/^.+\n/,""):"";try{e.stack?t&&!String(e.stack).endsWith(t.replace(/^.+\n.+\n/,""))&&(e.stack+="\n"+t):e.stack=t}catch(e){}}throw e}}_request(e,n){"string"==typeof e?(n=n||{}).url=e:n=e||{},n=ac(this.defaults,n);const{transitional:t,paramsSerializer:a,headers:i}=n;void 0!==t&&Ac.assertOptions(t,{silentJSONParsing:Tc.transitional(Tc.boolean),forcedJSONParsing:Tc.transitional(Tc.boolean),clarifyTimeoutError:Tc.transitional(Tc.boolean)},!1),null!=a&&(zt.isFunction(a)?n.paramsSerializer={serialize:a}:Ac.assertOptions(a,{encode:Tc.function,serialize:Tc.function},!0)),void 0!==n.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),Ac.assertOptions(n,{baseUrl:Tc.spelling("baseURL"),withXsrfToken:Tc.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=i&&zt.merge(i.common,i[n.method]);i&&zt.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete i[e]})),n.headers=hr.concat(o,i);const r=[];let s=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(n)||(s=s&&e.synchronous,r.unshift(e.fulfilled,e.rejected))}));const c=[];let u;this.interceptors.response.forEach((function(e){c.push(e.fulfilled,e.rejected)}));let p,l=0;if(!s){const e=[Fc.bind(this),void 0];for(e.unshift.apply(e,r),e.push.apply(e,c),p=e.length,u=Promise.resolve(n);l<p;)u=u.then(e[l++],e[l++]);return u}p=r.length;let d=n;for(l=0;l<p;){const e=r[l++],n=r[l++];try{d=e(d)}catch(e){n.call(this,e);break}}try{u=Fc.call(this,d)}catch(e){return Promise.reject(e)}for(l=0,p=c.length;l<p;)u=u.then(c[l++],c[l++]);return u}getUri(e){return Vo(yr((e=ac(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}};zt.forEach(["delete","get","head","options"],(function(e){Sc.prototype[e]=function(n,t){return this.request(ac(t||{},{method:e,url:n,data:(t||{}).data}))}})),zt.forEach(["post","put","patch"],(function(e){function n(n){return function(t,a,i){return this.request(ac(i||{},{method:e,headers:n?{"Content-Type":"multipart/form-data"}:{},url:t,data:a}))}}Sc.prototype[e]=n(),Sc.prototype[e+"Form"]=n(!0)}));const Oc={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Oc).forEach((([e,n])=>{Oc[n]=e}));const Rc=function e(n){const t=new Sc(n),a=et(Sc.prototype.request,t);return zt.extend(a,Sc.prototype,t,{allOwnKeys:!0}),zt.extend(a,t,null,{allOwnKeys:!0}),a.create=function(t){return e(ac(n,t))},a}(ur);Rc.Axios=Sc,Rc.CanceledError=br,Rc.CancelToken=class e{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let n;this.promise=new Promise((function(e){n=e}));const t=this;this.promise.then((e=>{if(!t._listeners)return;let n=t._listeners.length;for(;n-- >0;)t._listeners[n](e);t._listeners=null})),this.promise.then=e=>{let n;const a=new Promise((e=>{t.subscribe(e),n=e})).then(e);return a.cancel=function(){t.unsubscribe(n)},a},e((function(e,a,i){t.reason||(t.reason=new br(e,a,i),n(t.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);-1!==n&&this._listeners.splice(n,1)}toAbortSignal(){const e=new AbortController,n=n=>{e.abort(n)};return this.subscribe(n),e.signal.unsubscribe=()=>this.unsubscribe(n),e.signal}static source(){let n;return{token:new e((function(e){n=e})),cancel:n}}},Rc.isCancel=xr,Rc.VERSION=Es,Rc.toFormData=Ho,Rc.AxiosError=qt,Rc.Cancel=Rc.CanceledError,Rc.all=function(e){return Promise.all(e)},Rc.spread=function(e){return function(n){return e.apply(null,n)}},Rc.isAxiosError=function(e){return zt.isObject(e)&&!0===e.isAxiosError},Rc.mergeConfig=ac,Rc.AxiosHeaders=hr,Rc.formToJSON=e=>cr(zt.isHTMLForm(e)?new FormData(e):e),Rc.getAdapter=Ec,Rc.HttpStatusCode=Oc,Rc.default=Rc;const{Axios:Bc,AxiosError:Pc,CanceledError:Lc,isCancel:Ic,CancelToken:Nc,VERSION:Uc,all:zc,Cancel:qc,isAxiosError:Mc,spread:Hc,toFormData:$c,AxiosHeaders:Gc,HttpStatusCode:Wc,formToJSON:Kc,getAdapter:Vc,mergeConfig:Jc}=Rc,Yc="/api/v1",Xc=e=>{const n=(t=e,Object.entries(t).reduce(((e,n)=>(e[$n(n[0])]=n[1],e)),{}));var t;return Rc.post(`${Yc}/reporter/runs`,{run:n},{skipSnakeCaseConversion:!0})},Zc=(e,n)=>Rc.put(`${Yc}/reporter/runs/${e}`,{run:n}),Qc=e=>Rc.get(`${Yc}/reporter/runs/${e}/heartbeat`),eu=(e,n)=>Rc.post(`${Yc}/reporter/runs/${e}/test_entities`,{testEntity:n}),nu="=".repeat(10),tu={testData:(e,n)=>{let t=`\n-------Started reporting to NeetoPlaydash 🎭-------\nCI Build ID: ${e}\n`;return n&&(t+=`Total shards: ${n.total}\nCurrent shards: ${n.current}\n`),t+=`${"-".repeat(50)}\n`,t}},au={startingTest:({titlePath:e,historyId:n,retry:t,repeatEachIndex:a})=>`${nu}Starting ${e}${nu}\n Time: ${(new Date).toUTCString()}\n History ID: ${n}${t&&`\nRetry: ${t}`}${a&&`\nRepeat index: ${a}`}`},iu={reportedTest:({title:e,status:n,historyId:t,completedAt:a,error:i,isTestReported:o=!0,retry:r,repeatEachIndex:s})=>{let c=`\n\n${o?"------------Reported to NeetoPlaydash------------":"-".repeat(49)}\n Title: ${e}\n History id: ${t}\n Status: ${n}\n Completed at: ${a}${r&&`\nRetry: ${r}`}${s&&`\nRepeat index: ${s}`}\n`;return c=i?c.concat(` Error:\n\n ${i.replaceAll("\n","\n ")}`):c,c.concat(`\n${"-".repeat(49)}\n`)}},ou={runReported:"Run completed and reported to NeetoPlaydash 🎉\n\n",finalStatus:({currentShard:e,status:n,duration:t})=>{let a=`------------------Run completed-------------------\n Status: ${n}\n Duration: ${(e=>{const n={hour:Math.floor(e/36e5),minute:Math.floor(e/6e4)%60,second:Math.floor(e/1e3)%60,millisecond:Math.floor(e)%1e3};return Object.entries(n).filter((([e,n])=>0!==n)).map((([e,n])=>n+" "+(1!==n?`${e}s`:e))).join(", ")})(null!=t?t:0)}\n`;return a=0!==e?a.concat(` Shard: ${e}`):a,a.concat(`\n${"-".repeat(50)}\n`)}},ru=({command:e,messageOnError:n,shouldThrowError:t=!1,logLevel:a="warning"})=>{try{return b.execSync(e).toString().trim()}catch(e){if(t)throw e;I[a](n)}},su=(e,n)=>{var t;const{title:a,parent:o,location:{file:r}}=e,s=e.titlePath(),c=null===(t=o.project())||void 0===t?void 0:t.name,u=i.relative(n,r),p=(({titlePath:e,title:n,project:t,rootDir:a,file:o})=>e.filter(((e,r)=>0!==r&&e!==n&&e!==t&&e!==i.relative(a,o))))({titlePath:s,title:a,project:c,rootDir:n,file:r});return{title:a,describe:p,project:c,spec:u,historyId:(({projectId:e,specName:n,describeTitles:t,testTitle:a})=>{const i=`[project=${e}]${n}${[...t,a].join("")}`,o=Jn(i);return`${Jn(n)}-${o}`})({projectId:null!=c?c:"",specName:u,describeTitles:p,testTitle:a})}},cu=({rootDir:e},n)=>Ne(n.allTests().map((n=>su(n,e)))),uu=async e=>{try{await Qc(e)}catch(e){I.error(e.message),I.error(JSON.stringify(e,null,4)),I.redText(R.stopped),process.exit(1)}},pu=async(e,n,t)=>{var a,i,o;const r=n.shard;e.config=n;const s=e.currentShard=null!==(a=null==r?void 0:r.current)&&void 0!==a?a:0;A.setContext({ciBuildId:e.ciBuildId,currentShard:null==r?void 0:r.current,rootDir:n.rootDir}),e.totalTestCount=t.allTests().length,e.rootDir=n.rootDir;const c={commitId:ru({command:"git rev-parse HEAD",messageOnError:T.failedToGetCommitSha}),commitName:ru({command:"git show-branch --no-name HEAD",messageOnError:T.failedToGetCommitMessage}),author:ru({command:"git show -s --format='%an' HEAD",messageOnError:T.failedToGetBranch}),branch:ru({command:"git branch --show-current",messageOnError:T.failedToGetBranch}),tags:"string"==typeof e.tags?e.tags.split(","):e.tags,ciBuildId:e.ciBuildId,configuration:{...n,baseDir:process.cwd()},shards:Wn({currentShard:s})};try{if(await Xc(c),e.hasRunStarted=!0,0===e.totalTestCount)return void I.redText(T.noTestsToReport);await uu(e.ciBuildId),e.heartbeatInterval=setInterval((async()=>await uu(e.ciBuildId)),45e3);const{data:a}=await eu(e.ciBuildId,{testEntities:cu(n,t),shard:s});e.attempts=a,I.log(tu.testData(e.ciBuildId,r))}catch(a){e.shouldNotReportTest=!0;const r=a,s=null===(i=r.response)||void 0===i?void 0:i.data;I.error(null!==(o=null==s?void 0:s.error)&&void 0!==o?o:r.message),I.error(T.failedToInitializeRun),await Qn({context:{...c,testEntities:cu(n,t)},error:a,title:"onBegin"}),((e,n)=>{var t,a;const{error:i}=e&&(e instanceof Pc&&(null===(t=null==e?void 0:e.response)||void 0===t?void 0:t.data)||{error:void 0}),o=e&&(e instanceof Pc?null===(a=null==e?void 0:e.response)||void 0===a?void 0:a.status:void 0);n.shouldNotReportTest=!0,"Project does not exist."===i&&404===o?(I.redText(T.invalidProjectKey),process.exit(1)):"Could not authenticate, invalid API Key"===i&&401===o||"api-key"===n.apiKey?(I.redText(T.invalidApiKey),process.exit(1)):[_,E].includes(i||"")&&422===o?(I.redText(T.duplicateCiBuildId),process.exit(1)):(422===o&&(process.kill(process.pid,"SIGKILL"),process.exit(1)),Zn(o)&&I.yellowText(null!=i?i:null==e?void 0:e.message),I.yellowText(T.testsWillNotBeReported))})(r,e),clearInterval(e.heartbeatInterval)}},lu=(e,n,t)=>Rc.post(`${Yc}/reporter/runs/${e}/test_entities/${n}/attempts`,t),du=({ciBuildId:e,historyId:n,id:t,payload:a})=>Rc.put(`${Yc}/reporter/runs/${e}/test_entities/${n}/attempts/${t}`,a),mu=["screenshot","video","trace","lighthouse"],fu=({location:e,snippet:n})=>{if(!e)return null;const{file:t,line:a,column:i}=e;return`# ${t} (${a}:${i}) \n\n\n ${n}`},hu={KB:1024,MB:Math.pow(1024,2)},vu=(e,n)=>parseFloat((e/hu[n]).toFixed(2));var xu=class{constructor(e,n,t){this.etaBufferLength=e||100,this.valueBuffer=[t],this.timeBuffer=[n],this.eta="0"}update(e,n,t){this.valueBuffer.push(n),this.timeBuffer.push(e),this.calculate(t-n)}getTime(){return this.eta}calculate(e){const n=this.valueBuffer.length,t=Math.min(this.etaBufferLength,n),a=(this.valueBuffer[n-1]-this.valueBuffer[n-t])/(this.timeBuffer[n-1]-this.timeBuffer[n-t]);this.valueBuffer=this.valueBuffer.slice(-this.etaBufferLength),this.timeBuffer=this.timeBuffer.slice(-this.etaBufferLength);const i=Math.ceil(e/a/1e3);isNaN(i)?this.eta="NULL":isFinite(i)?this.eta=i>1e7?"INF":i<0?0:i:this.eta="INF"}};const bu=g;var gu=class{constructor(e){this.stream=e,this.linewrap=!0,this.dy=0}cursorSave(){this.stream.isTTY&&this.stream.write("7")}cursorRestore(){this.stream.isTTY&&this.stream.write("8")}cursor(e){this.stream.isTTY&&(e?this.stream.write("[?25h"):this.stream.write("[?25l"))}cursorTo(e=null,n=null){this.stream.isTTY&&bu.cursorTo(this.stream,e,n)}cursorRelative(e=null,n=null){this.stream.isTTY&&(this.dy=this.dy+n,bu.moveCursor(this.stream,e,n))}cursorRelativeReset(){this.stream.isTTY&&(bu.moveCursor(this.stream,0,-this.dy),bu.cursorTo(this.stream,0,null),this.dy=0)}clearRight(){this.stream.isTTY&&bu.clearLine(this.stream,1)}clearLine(){this.stream.isTTY&&bu.clearLine(this.stream,0)}clearBottom(){this.stream.isTTY&&bu.clearScreenDown(this.stream)}newline(){this.stream.write("\n"),this.dy++}write(e,n=!1){!0===this.linewrap&&!1===n?this.stream.write(e.substr(0,this.getWidth())):this.stream.write(e)}lineWrapping(e){this.stream.isTTY&&(this.linewrap=e,e?this.stream.write("[?7h"):this.stream.write("[?7l"))}isTTY(){return!0===this.stream.isTTY}getWidth(){return this.stream.columns||(this.stream.isTTY?80:200)}},yu={exports:{}};const Du=({onlyFirst:e=!1}={})=>{const n=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(n,e?void 0:"g")};var wu={exports:{}};const _u=e=>!Number.isNaN(e)&&(e>=4352&&(e<=4447||9001===e||9002===e||11904<=e&&e<=12871&&12351!==e||12880<=e&&e<=19903||19968<=e&&e<=42182||43360<=e&&e<=43388||44032<=e&&e<=55203||63744<=e&&e<=64255||65040<=e&&e<=65049||65072<=e&&e<=65131||65281<=e&&e<=65376||65504<=e&&e<=65510||110592<=e&&e<=110593||127488<=e&&e<=127569||131072<=e&&e<=262141));wu.exports=_u,wu.exports.default=_u;const Eu=e=>"string"==typeof e?e.replace(Du(),""):e,Cu=wu.exports,Fu=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF4\uD83C\uDDF2|\uD83C\uDDF6\uD83C\uDDE6|[#\*0-9]\uFE0F\u20E3|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83D\uDC69(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270A-\u270D]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC70\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDCAA\uDD74\uDD7A\uDD90\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD36\uDDB5\uDDB6\uDDBB\uDDD2-\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5\uDEEB\uDEEC\uDEF4-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g},ju=e=>{if("string"!=typeof e||0===e.length)return 0;if(0===(e=Eu(e)).length)return 0;e=e.replace(Fu()," ");let n=0;for(let t=0;t<e.length;t++){const a=e.codePointAt(t);a<=31||a>=127&&a<=159||(a>=768&&a<=879||(a>65535&&t++,n+=Cu(a)?2:1))}return n};yu.exports=ju,yu.exports.default=ju;var ku=function(e,n,t){if(!0!==n.autopadding)return e;return"percentage"===t?(a=e,(n.autopaddingChar+a).slice(-3)):e;var a},Au=function(e,n){const t=Math.round(e*n.barsize),a=n.barsize-t;return n.barCompleteString.substr(0,t)+n.barGlue+n.barIncompleteString.substr(0,a)},Tu=function(e,n,t){function a(e){return t?t*Math.round(e/t):e}function i(e){return(n.autopaddingChar+e).slice(-2)}return e>3600?i(Math.floor(e/3600))+"h"+i(a(e%3600/60))+"m":e>60?i(Math.floor(e/60))+"m"+i(a(e%60))+"s":e>10?i(a(e))+"s":i(e)+"s"};const Su=yu.exports,Ou=ku,Ru=Au,Bu=Tu;var Pu=function(e,n,t){let a=e.format;const i=e.formatTime||Bu,o=e.formatValue||Ou,r=e.formatBar||Ru,s=Math.floor(100*n.progress)+"",c=n.stopTime||Date.now(),u=Math.round((c-n.startTime)/1e3),p=Object.assign({},t,{bar:r(n.progress,e),percentage:o(s,e,"percentage"),total:o(n.total,e,"total"),value:o(n.value,e,"value"),eta:o(n.eta,e,"eta"),eta_formatted:i(n.eta,e,5),duration:o(u,e,"duration"),duration_formatted:i(u,e,1)});a=a.replace(/\{(\w+)\}/g,(function(e,n){return void 0!==p[n]?p[n]:e}));const l=Math.max(0,n.maxWidth-Su(a)-2),d=Math.floor(l/2);switch(e.align){case"right":a=l>0?" ".repeat(l)+a:a;break;case"center":a=d>0?" ".repeat(d)+a:a}return a};function Lu(e,n){return null==e?n:e}var Iu={parse:function(e,n){const t={},a=Object.assign({},n,e);return t.throttleTime=1e3/Lu(a.fps,10),t.stream=Lu(a.stream,process.stderr),t.terminal=Lu(a.terminal,null),t.clearOnComplete=Lu(a.clearOnComplete,!1),t.stopOnComplete=Lu(a.stopOnComplete,!1),t.barsize=Lu(a.barsize,40),t.align=Lu(a.align,"left"),t.hideCursor=Lu(a.hideCursor,!1),t.linewrap=Lu(a.linewrap,!1),t.barGlue=Lu(a.barGlue,""),t.barCompleteChar=Lu(a.barCompleteChar,"="),t.barIncompleteChar=Lu(a.barIncompleteChar,"-"),t.format=Lu(a.format,"progress [{bar}] {percentage}% | ETA: {eta}s | {value}/{total}"),t.formatTime=Lu(a.formatTime,null),t.formatValue=Lu(a.formatValue,null),t.formatBar=Lu(a.formatBar,null),t.etaBufferLength=Lu(a.etaBuffer,10),t.etaAsynchronousUpdate=Lu(a.etaAsynchronousUpdate,!1),t.progressCalculationRelative=Lu(a.progressCalculationRelative,!1),t.synchronousUpdate=Lu(a.synchronousUpdate,!0),t.noTTYOutput=Lu(a.noTTYOutput,!1),t.notTTYSchedule=Lu(a.notTTYSchedule,2e3),t.emptyOnZero=Lu(a.emptyOnZero,!1),t.forceRedraw=Lu(a.forceRedraw,!1),t.autopadding=Lu(a.autopadding,!1),t.gracefulExit=Lu(a.gracefulExit,!1),t},assignDerivedOptions:function(e){return e.barCompleteString=e.barCompleteChar.repeat(e.barsize+1),e.barIncompleteString=e.barIncompleteChar.repeat(e.barsize+1),e.autopaddingChar=e.autopadding?Lu(e.autopaddingChar," "):"",e}};const Nu=xu,Uu=gu,zu=Pu,qu=Iu,Mu=v;var Hu=class extends Mu{constructor(e){super(),this.options=qu.assignDerivedOptions(e),this.terminal=this.options.terminal?this.options.terminal:new Uu(this.options.stream),this.value=0,this.startValue=0,this.total=100,this.lastDrawnString=null,this.startTime=null,this.stopTime=null,this.lastRedraw=Date.now(),this.eta=new Nu(this.options.etaBufferLength,0,0),this.payload={},this.isActive=!1,this.formatter="function"==typeof this.options.format?this.options.format:zu}render(e=!1){const n={progress:this.getProgress(),eta:this.eta.getTime(),startTime:this.startTime,stopTime:this.stopTime,total:this.total,value:this.value,maxWidth:this.terminal.getWidth()};this.options.etaAsynchronousUpdate&&this.updateETA();const t=this.formatter(this.options,n,this.payload);(e||this.options.forceRedraw||this.options.noTTYOutput&&!this.terminal.isTTY()||this.lastDrawnString!=t)&&(this.emit("redraw-pre"),this.terminal.cursorTo(0,null),this.terminal.write(t),this.terminal.clearRight(),this.lastDrawnString=t,this.lastRedraw=Date.now(),this.emit("redraw-post"))}start(e,n,t){this.value=n||0,this.total=void 0!==e&&e>=0?e:100,this.startValue=n||0,this.payload=t||{},this.startTime=Date.now(),this.stopTime=null,this.lastDrawnString="",this.eta=new Nu(this.options.etaBufferLength,this.startTime,this.value),this.isActive=!0,this.emit("start",e,n)}stop(){this.isActive=!1,this.stopTime=Date.now(),this.emit("stop",this.total,this.value)}update(e,n={}){"number"==typeof e&&(this.value=e,this.eta.update(Date.now(),e,this.total));const t=("object"==typeof e?e:n)||{};this.emit("update",this.total,this.value);for(const e in t)this.payload[e]=t[e];this.value>=this.getTotal()&&this.options.stopOnComplete&&this.stop()}getProgress(){let e=this.value/this.total;return this.options.progressCalculationRelative&&(e=(this.value-this.startValue)/(this.total-this.startValue)),isNaN(e)&&(e=this.options&&this.options.emptyOnZero?0:1),e=Math.min(Math.max(e,0),1),e}increment(e=1,n={}){"object"==typeof e?this.update(this.value+1,e):this.update(this.value+e,n)}getTotal(){return this.total}setTotal(e){void 0!==e&&e>=0&&(this.total=e)}updateETA(){this.eta.update(Date.now(),this.value,this.total)}};const $u=Hu,Gu=Iu;const Wu=gu,Ku=Hu,Vu=Iu,Ju=v;var Yu={legacy:{format:"progress [{bar}] {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"=",barIncompleteChar:"-"},shades_classic:{format:" {bar} {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"█",barIncompleteChar:"░"},shades_grey:{format:" [90m{bar}[0m {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"█",barIncompleteChar:"░"},rect:{format:" {bar}■ {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"■",barIncompleteChar:" "}};const Xu=class extends $u{constructor(e,n){super(Gu.parse(e,n)),this.timer=null,this.options.noTTYOutput&&!1===this.terminal.isTTY()&&(this.options.synchronousUpdate=!1),this.schedulingRate=this.terminal.isTTY()?this.options.throttleTime:this.options.notTTYSchedule,this.sigintCallback=null}render(){this.timer&&(clearTimeout(this.timer),this.timer=null),super.render(),this.options.noTTYOutput&&!1===this.terminal.isTTY()&&this.terminal.newline(),this.timer=setTimeout(this.render.bind(this),this.schedulingRate)}update(e,n){this.timer&&(super.update(e,n),this.options.synchronousUpdate&&this.lastRedraw+2*this.options.throttleTime<Date.now()&&this.render())}start(e,n,t){!1===this.options.noTTYOutput&&!1===this.terminal.isTTY()||(null===this.sigintCallback&&this.options.gracefulExit&&(this.sigintCallback=this.stop.bind(this),process.once("SIGINT",this.sigintCallback),process.once("SIGTERM",this.sigintCallback)),this.terminal.cursorSave(),!0===this.options.hideCursor&&this.terminal.cursor(!1),!1===this.options.linewrap&&this.terminal.lineWrapping(!1),super.start(e,n,t),this.render())}stop(){this.timer&&(this.sigintCallback&&(process.removeListener("SIGINT",this.sigintCallback),process.removeListener("SIGTERM",this.sigintCallback),this.sigintCallback=null),this.render(),super.stop(),clearTimeout(this.timer),this.timer=null,!0===this.options.hideCursor&&this.terminal.cursor(!0),!1===this.options.linewrap&&this.terminal.lineWrapping(!0),this.terminal.cursorRestore(),this.options.clearOnComplete?(this.terminal.cursorTo(0,null),this.terminal.clearLine()):this.terminal.newline())}},Zu=class extends Ju{constructor(e,n){super(),this.bars=[],this.options=Vu.parse(e,n),this.options.synchronousUpdate=!1,this.terminal=this.options.terminal?this.options.terminal:new Wu(this.options.stream),this.timer=null,this.isActive=!1,this.schedulingRate=this.terminal.isTTY()?this.options.throttleTime:this.options.notTTYSchedule,this.loggingBuffer=[],this.sigintCallback=null}create(e,n,t,a={}){const i=new Ku(Object.assign({},this.options,{terminal:this.terminal},a));return this.bars.push(i),!1===this.options.noTTYOutput&&!1===this.terminal.isTTY()||(null===this.sigintCallback&&this.options.gracefulExit&&(this.sigintCallback=this.stop.bind(this),process.once("SIGINT",this.sigintCallback),process.once("SIGTERM",this.sigintCallback)),this.isActive||(!0===this.options.hideCursor&&this.terminal.cursor(!1),!1===this.options.linewrap&&this.terminal.lineWrapping(!1),this.timer=setTimeout(this.update.bind(this),this.schedulingRate)),this.isActive=!0,i.start(e,n,t),this.emit("start")),i}remove(e){const n=this.bars.indexOf(e);return!(n<0)&&(this.bars.splice(n,1),this.update(),this.terminal.newline(),this.terminal.clearBottom(),!0)}update(){if(this.timer&&(clearTimeout(this.timer),this.timer=null),this.emit("update-pre"),this.terminal.cursorRelativeReset(),this.emit("redraw-pre"),this.loggingBuffer.length>0)for(this.terminal.clearLine();this.loggingBuffer.length>0;)this.terminal.write(this.loggingBuffer.shift(),!0);for(let e=0;e<this.bars.length;e++)e>0&&this.terminal.newline(),this.bars[e].render();this.emit("redraw-post"),this.options.noTTYOutput&&!1===this.terminal.isTTY()&&(this.terminal.newline(),this.terminal.newline()),this.timer=setTimeout(this.update.bind(this),this.schedulingRate),this.emit("update-post"),this.options.stopOnComplete&&!this.bars.find((e=>e.isActive))&&this.stop()}stop(){if(clearTimeout(this.timer),this.timer=null,this.sigintCallback&&(process.removeListener("SIGINT",this.sigintCallback),process.removeListener("SIGTERM",this.sigintCallback),this.sigintCallback=null),this.isActive=!1,!0===this.options.hideCursor&&this.terminal.cursor(!0),!1===this.options.linewrap&&this.terminal.lineWrapping(!0),this.terminal.cursorRelativeReset(),this.emit("stop-pre-clear"),this.options.clearOnComplete)this.terminal.clearBottom();else{for(let e=0;e<this.bars.length;e++)e>0&&this.terminal.newline(),this.bars[e].render(),this.bars[e].stop();this.terminal.newline()}this.emit("stop")}log(e){this.loggingBuffer.push(e)}};var Qu={Bar:Xu,SingleBar:Xu,MultiBar:Zu,Presets:Yu,Format:{Formatter:Pu,BarFormat:Au,ValueFormat:ku,TimeFormat:Tu}};const ep=(e,n)=>"flaky"===e?e:n,np=async(e,{url:n,headers:t},a)=>{const i=e.byteLength/1024>1024?"MB":"KB";const o=new Qu.Bar({format:`Uploading ${a} [{bar}] | {value}/{total} ${i} - ETA: {eta_formatted}`,clearOnComplete:!0},Qu.Presets.rect);return o.start(vu(e.byteLength,i),0),await((e,{url:n,headers:t},a)=>Rc.put(n,e,{...a,headers:t}))(e,{url:n,headers:t},{onUploadProgress:e=>{e.total&&e.lengthComputable&&o.update(vu(e.loaded,i))}}),o};var tp,ap,ip={exports:{}};
|
|
9
|
-
/*! https://mths.be/wtf8 v1.0.1 by @mathias */tp=ip,ap=ip.exports,function(e){var n=ap,t=tp&&tp.exports==n&&tp,a="object"==typeof C&&C;a.global!==a&&a.window!==a||(e=a);var i,o,r,s=String.fromCharCode;function c(e){for(var n,t,a=[],i=0,o=e.length;i<o;)(n=e.charCodeAt(i++))>=55296&&n<=56319&&i<o?56320==(64512&(t=e.charCodeAt(i++)))?a.push(((1023&n)<<10)+(1023&t)+65536):(a.push(n),i--):a.push(n);return a}function u(e,n){return s(e>>n&63|128)}function p(e){if(!(4294967168&e))return s(e);var n="";return 4294965248&e?4294901760&e?4292870144&e||(n=s(e>>18&7|240),n+=u(e,12),n+=u(e,6)):(n=s(e>>12&15|224),n+=u(e,6)):n=s(e>>6&31|192),n+=s(63&e|128)}function l(){if(r>=o)throw Error("Invalid byte index");var e=255&i[r];if(r++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function d(){var e,n;if(r>o)throw Error("Invalid byte index");if(r==o)return!1;if(e=255&i[r],r++,!(128&e))return e;if(192==(224&e)){if((n=(31&e)<<6|l())>=128)return n;throw Error("Invalid continuation byte")}if(224==(240&e)){if((n=(15&e)<<12|l()<<6|l())>=2048)return n;throw Error("Invalid continuation byte")}if(240==(248&e)&&(n=(15&e)<<18|l()<<12|l()<<6|l())>=65536&&n<=1114111)return n;throw Error("Invalid WTF-8 detected")}var m={version:"1.0.1",encode:function(e){for(var n=c(e),t=n.length,a=-1,i="";++a<t;)i+=p(n[a]);return i},decode:function(e){i=c(e),o=i.length,r=0;for(var n,t=[];!1!==(n=d());)t.push(n);return function(e){for(var n,t=e.length,a=-1,i="";++a<t;)(n=e[a])>65535&&(i+=s((n-=65536)>>>10&1023|55296),n=56320|1023&n),i+=s(n);return i}(t)}};if(n&&!n.nodeType)if(t)t.exports=m;else{var f={}.hasOwnProperty;for(var h in m)f.call(m,h)&&(n[h]=m[h])}else e.wtf8=m}(C);var op=ip.exports;const rp=async(e,n,{status:t,duration:i,errors:o,error:r,retry:s,attachments:c})=>{const u=new Date,{currentShard:l,rootDir:d,ciBuildId:m}=e,{title:f,repeatEachIndex:h}=n,{historyId:v}=su(n,d),x=n.outcome(),b=Yn(s,h),g={shard:l,isExpected:"expected"===x,repeatEachIndex:h,status:ep(x,t)};try{const n={outcome:g,status:t,duration:i,log:op.encode(o.map((e=>{var n;return null!==(n=e.message)&&void 0!==n?n:""})).join("\n")),screenshots:[],videos:[],traces:[],lighthouses:[],completedAt:u.toString(),errorSnippet:r&&fu(r)};if(e.shouldNotReportTest)return;await Vn((()=>e.startedAttempts.has(Yn(v,b)))),I.underline(f);const s=c.map((({name:e,path:n,body:t,contentType:i})=>{if(!mu.includes(e))return;const o=n?a(n):t,r=((e,n,t)=>(null!=e?e:`${n}.${t.split("/")[1]}`).replaceAll("/","-"))(n,e,i),{file:s,...c}=((e,n,t)=>{const a=e.byteLength;return{file:e,filename:t,checksum:p.createHash("md5").update(e).digest("base64"),byteSize:a,contentType:n}})(o,i,r);return{file:s,metadata:c,name:e}})).filter(Hn(void 0)),l={metadata:be("metadata",s)},{data:d}=await(({ciBuildId:e,historyId:n},t)=>Rc.post(`/api/v2/reporter/runs/${e}/test_entities/${n}/direct_uploads`,{blob:t}))({ciBuildId:e.ciBuildId,historyId:v},l),h=await Promise.all(d.map((async({signedId:e,directUpload:t},a)=>{var i,o;return n[`${null===(i=s[a])||void 0===i?void 0:i.name}s`].push(e),np(s[a].file,t,`${f} - ${null===(o=s[a])||void 0===o?void 0:o.name}`)})));e.progressBars.push(...h);const x=du({ciBuildId:m,historyId:v,id:e.attempts[v][b],payload:n});e.testResultCalls.push(x),await x}catch(r){await Qn({context:{historyId:v,attemptIndex:b,title:f,status:t,outcome:g,duration:i,completedAt:u},error:r,title:"onTestEnd"}),I.error(r.message),I.error(S.failedToReportTest(f,v)),await uu(m)}finally{I.log(iu.reportedTest({title:f,status:t,historyId:v,completedAt:u,error:r&&fu(r),isTestReported:!e.shouldNotReportTest,retry:s,repeatEachIndex:h})),e.unreportedAttemptCount--,e.startedAttempts.delete(Yn(v,b))}},sp=y.extend({generateLighthouseMetaData:async({},e,n)=>{let t=0;const{title:a,outputDir:i}=n;await e((()=>{const e=a.replace(/[:]/g,"_");return{formats:{html:!0},name:t?e:`${e}-${t++}`,directory:i,get pathToLightHouseHTMLReport(){return`${i}/${this.name}.html`}}}))},attachLighthouseReport:async({},e,n)=>{await e((async e=>{e.endsWith(".html")?await n.attach("lighthouse",{path:e,contentType:"text/html"}):I.redText(P.attachLightHouseReport.unsupportedFileType(e))}))}}),cp=new Set(["ENOTFOUND","ENETUNREACH","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_CRL","UNABLE_TO_DECRYPT_CERT_SIGNATURE","UNABLE_TO_DECRYPT_CRL_SIGNATURE","UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY","CERT_SIGNATURE_FAILURE","CRL_SIGNATURE_FAILURE","CERT_NOT_YET_VALID","CERT_HAS_EXPIRED","CRL_NOT_YET_VALID","CRL_HAS_EXPIRED","ERROR_IN_CERT_NOT_BEFORE_FIELD","ERROR_IN_CERT_NOT_AFTER_FIELD","ERROR_IN_CRL_LAST_UPDATE_FIELD","ERROR_IN_CRL_NEXT_UPDATE_FIELD","OUT_OF_MEM","DEPTH_ZERO_SELF_SIGNED_CERT","SELF_SIGNED_CERT_IN_CHAIN","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","UNABLE_TO_VERIFY_LEAF_SIGNATURE","CERT_CHAIN_TOO_LONG","CERT_REVOKED","INVALID_CA","PATH_LENGTH_EXCEEDED","INVALID_PURPOSE","CERT_UNTRUSTED","CERT_REJECTED","HOSTNAME_MISMATCH"]);const up="axios-retry";function pp(e){return!e.response&&(!!e.code&&(!["ERR_CANCELED","ECONNABORTED"].includes(e.code)&&(e=>!cp.has(e&&e.code))(e)))}const lp=["get","head","options"],dp=lp.concat(["put","delete"]);function mp(e){return"ECONNABORTED"!==e.code&&(!e.response||429===e.response.status||e.response.status>=500&&e.response.status<=599)}function fp(e){return!!e.config?.method&&(mp(e)&&-1!==dp.indexOf(e.config.method))}function hp(e){return pp(e)||fp(e)}function vp(e=void 0){const n=e?.response?.headers["retry-after"];if(!n)return 0;let t=1e3*(Number(n)||0);return 0===t&&(t=(new Date(n).valueOf()||0)-Date.now()),Math.max(0,t)}const xp={retries:3,retryCondition:hp,retryDelay:function(e=0,n=void 0){return Math.max(0,vp(n))},shouldResetTimeout:!1,onRetry:()=>{},onMaxRetryTimesExceeded:()=>{},validateResponse:null};function bp(e,n,t=!1){const a=function(e,n){return{...xp,...n,...e[up]}}(e,n||{});return a.retryCount=a.retryCount||0,a.lastRequestTime&&!t||(a.lastRequestTime=Date.now()),e[up]=a,a}const gp=(e,n)=>{const t=e.interceptors.request.use((e=>(bp(e,n,!0),e[up]?.validateResponse&&(e.validateStatus=()=>!1),e))),a=e.interceptors.response.use(null,(async t=>{const{config:a}=t;if(!a)return Promise.reject(t);const i=bp(a,n);return t.response&&i.validateResponse?.(t.response)?t.response:await async function(e,n){const{retries:t,retryCondition:a}=e,i=(e.retryCount||0)<t&&a(n);if("object"==typeof i)try{return!1!==await i}catch(e){return!1}return i}(i,t)?async function(e,n,t,a){n.retryCount+=1;const{retryDelay:i,shouldResetTimeout:o,onRetry:r}=n,s=i(n.retryCount,t);if(function(e,n){e.defaults.agent===n.agent&&delete n.agent,e.defaults.httpAgent===n.httpAgent&&delete n.httpAgent,e.defaults.httpsAgent===n.httpsAgent&&delete n.httpsAgent}(e,a),!o&&a.timeout&&n.lastRequestTime){const e=Date.now()-n.lastRequestTime,i=a.timeout-e-s;if(i<=0)return Promise.reject(t);a.timeout=i}return a.transformRequest=[e=>e],await r(n.retryCount,t,a),a.signal?.aborted?Promise.resolve(e(a)):new Promise((n=>{const t=()=>{clearTimeout(i),n(e(a))},i=setTimeout((()=>{n(e(a)),a.signal?.removeEventListener&&a.signal.removeEventListener("abort",t)}),s);a.signal?.addEventListener&&a.signal.addEventListener("abort",t,{once:!0})}))}(e,i,t,a):(await async function(e,n){e.retryCount>=e.retries&&await e.onMaxRetryTimesExceeded(n,e.retryCount)}(i,t),Promise.reject(t))}));return{requestInterceptorId:t,responseInterceptorId:a}};gp.isNetworkError=pp,gp.isSafeRequestError=function(e){return!!e.config?.method&&(mp(e)&&-1!==lp.indexOf(e.config.method))},gp.isIdempotentRequestError=fp,gp.isNetworkOrIdempotentRequestError=hp,gp.exponentialDelay=function(e=0,n=void 0,t=100){const a=2**e*t,i=Math.max(a,vp(n));return i+.2*i*Math.random()},gp.linearDelay=function(e=100){return(n=0,t=void 0)=>{const a=n*e;return Math.max(a,vp(t))}},gp.isRetryableError=mp;const yp="Content-Type",Dp="Accept",wp="X-Api-Key",_p="Project-Key",Ep="Reporter-Version",Cp=e=>e===Object(e)&&!(e instanceof Buffer);function Fp({projectKey:e,baseURL:n,apiKey:t}){Rc.defaults.baseURL=null!=n?n:"https://connect.neetoplaydash.com",Rc.defaults.skipSnakeCaseConversion=!1,(({projectKey:e,apiKey:n})=>{Rc.defaults.headers={...Rc.defaults.headers,[_p]:e,[Ep]:JSON.parse(a(o(__dirname,"./package.json"),"utf8")).version,[wp]:null!=n?n:"",[Dp]:"application/json",[yp]:"application/json"}})({projectKey:e,apiKey:t}),Rc.interceptors.request.use((e=>{const n=e.data;return Cp(n)&&!e.skipSnakeCaseConversion&&(e.data=Gn(n,(function(e,n){return[$n(e),n]}))),e})),Rc.interceptors.response.use((e=>{const n=e.data;return Cp(n)&&(e.data=Gn(n,(function(e,n){return[(t=e,t.replace(/(_\w)/g,(function(e){return e[1].toUpperCase()}))),n];var t}))),e})),gp(Rc,{retryDelay:gp.exponentialDelay,retryCondition:e=>{var n;const t=null===(n=e.status)||void 0===n?void 0:n.toString();return!!t&&(t.startsWith("5")||"404"===t)},retries:5})}class jp{constructor(e){var n;this.onBegin=(e,n)=>pu(this,e,n),this.onTestBegin=(e,n)=>(async(e,n,{retry:t})=>{var a,i;const{title:o,repeatEachIndex:r}=n,{rootDir:s,currentShard:c,ciBuildId:u}=e,{historyId:p}=su(n,s),l=(new Date).toString(),d=Yn(t,r);if(e.unreportedAttemptCount++,e.shouldNotReportTest)I.invertBackground(au.startingTest({titlePath:o,historyId:p,retry:t,repeatEachIndex:r}));else try{if(await Vn((()=>{var n,t;return Mn(e.attempts)&&ze(null===(t=null===(n=e.attempts)||void 0===n?void 0:n[p])||void 0===t?void 0:t["0-0"])})),I.invertBackground(au.startingTest({titlePath:o,historyId:p,retry:t,repeatEachIndex:r})),e.shouldNotReportTest)return;const n={status:"running",startedAt:l,shard:c,repeatEachIndex:r};if(0===t&&0===r)await du({ciBuildId:u,historyId:p,id:null===(i=null===(a=e.attempts)||void 0===a?void 0:a[p])||void 0===i?void 0:i["0-0"],payload:n});else{const{data:{attemptId:t}}=await lu(u,p,n);e.attempts=He(e.attempts,{[p]:{[d]:t}})}}catch(e){await Qn({context:{historyId:p,attemptIndex:d,title:o},error:e,title:"onTestBegin"}),I.error(e.message),I.error(S.failedToReportTest(o,p)),await uu(u)}finally{e.startedAttempts.add(Yn(p,d))}})(this,e,n),this.onTestEnd=async(e,n)=>rp(this,e,n),this.onEnd=async e=>(async(e,{status:n,duration:t})=>{var a,i;const{currentShard:o}=e;try{if(await Vn((()=>(e.hasRunStarted||e.shouldNotReportTest)&&0===e.unreportedAttemptCount)),I.bold(ou.finalStatus({currentShard:o,status:n,duration:t})),e.shouldNotReportTest)return;if(0===e.totalTestCount)return void await Zc(e.ciBuildId,{shards:Wn({currentShard:o,status:"passed",duration:t})});await Promise.allSettled(e.testResultCalls),await Zc(e.ciBuildId,{shards:Wn({currentShard:o,status:n,duration:t})})}catch(e){const o=null===(a=e.response)||void 0===a?void 0:a.data;await Qn({context:{runStatus:n,runDuration:t},error:e,title:"onEnd"}),I.error(null!==(i=o.error)&&void 0!==i?i:e.message),I.error(O.failedToReportRunStatus)}finally{e.shouldNotReportTest||0===e.totalTestCount||I.invertBackground(ou.runReported),clearInterval(e.heartbeatInterval)}})(this,e),this.attempts={},this.tags=e.tags,this.ciBuildId=e.ciBuildId,this.testResultCalls=[],this.totalTestCount=0,this.unreportedAttemptCount=0,this.hasRunStarted=!1,this.heartbeatInterval=null,this.rootDir="",this.currentShard=0,this.progressBars=[],this.startedAttempts=new Set,this.shouldNotReportTest=!1,this.apiKey=e.apiKey,A.configure({apiKey:Xn("9d5d98e72929dae3c8b3701f50032da1a02b80f9dc29a8e448a601871e5c82fd0ac2fa33c46443709cdb3eabc54a06ab"),environment:(null===(n=null==e?void 0:e.baseURL)||void 0===n?void 0:n.includes(".net"))?"staging":"production"}),A.setContext(e),((e,n)=>{D.setDefaultResultOrder("ipv4first"),Fp(n),process.on("unhandledRejection",(async n=>{var t,a,i;const o=null===(t=n.response)||void 0===t?void 0:t.data;await Qn({context:{},error:n,title:"unhandledRejection"}),await uu(e.ciBuildId),I.error(null!==(i=null!==(a=null==o?void 0:o.error)&&void 0!==a?a:n.message)&&void 0!==i?i:JSON.stringify(n))}))})(this,e)}onStdOut(e,n){n&&I.bold(`Log from test "${n.title}"`),I.log(e.toString())}}export{jp as default,sp as test};
|
|
9
|
+
/*! https://mths.be/wtf8 v1.0.1 by @mathias */tp=ip,ap=ip.exports,function(e){var n=ap,t=tp&&tp.exports==n&&tp,a="object"==typeof C&&C;a.global!==a&&a.window!==a||(e=a);var i,o,r,s=String.fromCharCode;function c(e){for(var n,t,a=[],i=0,o=e.length;i<o;)(n=e.charCodeAt(i++))>=55296&&n<=56319&&i<o?56320==(64512&(t=e.charCodeAt(i++)))?a.push(((1023&n)<<10)+(1023&t)+65536):(a.push(n),i--):a.push(n);return a}function u(e,n){return s(e>>n&63|128)}function p(e){if(!(4294967168&e))return s(e);var n="";return 4294965248&e?4294901760&e?4292870144&e||(n=s(e>>18&7|240),n+=u(e,12),n+=u(e,6)):(n=s(e>>12&15|224),n+=u(e,6)):n=s(e>>6&31|192),n+=s(63&e|128)}function l(){if(r>=o)throw Error("Invalid byte index");var e=255&i[r];if(r++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function d(){var e,n;if(r>o)throw Error("Invalid byte index");if(r==o)return!1;if(e=255&i[r],r++,!(128&e))return e;if(192==(224&e)){if((n=(31&e)<<6|l())>=128)return n;throw Error("Invalid continuation byte")}if(224==(240&e)){if((n=(15&e)<<12|l()<<6|l())>=2048)return n;throw Error("Invalid continuation byte")}if(240==(248&e)&&(n=(15&e)<<18|l()<<12|l()<<6|l())>=65536&&n<=1114111)return n;throw Error("Invalid WTF-8 detected")}var m={version:"1.0.1",encode:function(e){for(var n=c(e),t=n.length,a=-1,i="";++a<t;)i+=p(n[a]);return i},decode:function(e){i=c(e),o=i.length,r=0;for(var n,t=[];!1!==(n=d());)t.push(n);return function(e){for(var n,t=e.length,a=-1,i="";++a<t;)(n=e[a])>65535&&(i+=s((n-=65536)>>>10&1023|55296),n=56320|1023&n),i+=s(n);return i}(t)}};if(n&&!n.nodeType)if(t)t.exports=m;else{var f={}.hasOwnProperty;for(var h in m)f.call(m,h)&&(n[h]=m[h])}else e.wtf8=m}(C);var op=ip.exports;const rp=async(e,n,{status:t,duration:i,errors:o,error:r,retry:s,attachments:c})=>{const u=new Date,{currentShard:l,rootDir:d,ciBuildId:m}=e,{title:f,repeatEachIndex:h}=n,{historyId:v}=su(n,d),x=n.outcome(),b=Yn(s,h),g={shard:l,isExpected:"expected"===x,repeatEachIndex:h,status:ep(x,t)};try{const n={outcome:g,status:t,duration:i,log:op.encode(o.map((e=>{var n;return null!==(n=e.message)&&void 0!==n?n:""})).join("\n")),screenshots:[],videos:[],traces:[],lighthouses:[],completedAt:u.toString(),errorSnippet:r&&fu(r)};if(e.shouldNotReportTest)return;await Vn((()=>e.startedAttempts.has(Yn(v,b)))),I.underline(f);const s=c.map((({name:e,path:n,body:t,contentType:i})=>{if(!mu.includes(e))return;const o=n?a(n):t,r=((e,n,t)=>(null!=e?e:`${n}.${t.split("/")[1]}`).replaceAll("/","-"))(n,e,i),{file:s,...c}=((e,n,t)=>{const a=e.byteLength;return{file:e,filename:t,checksum:p.createHash("md5").update(e).digest("base64"),byteSize:a,contentType:n}})(o,i,r);return{file:s,metadata:c,name:e}})).filter(Hn(void 0)),l={metadata:be("metadata",s)},{data:d}=await(({ciBuildId:e,historyId:n},t)=>Rc.post(`/api/v2/reporter/runs/${e}/test_entities/${n}/direct_uploads`,{blob:t}))({ciBuildId:e.ciBuildId,historyId:v},l),h=await Promise.all(d.map((async({signedId:e,directUpload:t},a)=>{var i,o;return n[`${null===(i=s[a])||void 0===i?void 0:i.name}s`].push(e),np(s[a].file,t,`${f} - ${null===(o=s[a])||void 0===o?void 0:o.name}`)})));e.progressBars.push(...h);const x=du({ciBuildId:m,historyId:v,id:e.attempts[v][b],payload:n});e.testResultCalls.push(x),await x}catch(r){await Qn({context:{historyId:v,attemptIndex:b,title:f,status:t,outcome:g,duration:i,completedAt:u},error:r,title:"onTestEnd"}),I.error(r.message),I.error(S.failedToReportTest(f,v)),await uu(m)}finally{I.log(iu.reportedTest({title:f,status:t,historyId:v,completedAt:u,error:r&&fu(r),isTestReported:!e.shouldNotReportTest,retry:s,repeatEachIndex:h})),e.unreportedAttemptCount--,e.startedAttempts.delete(Yn(v,b))}},sp=y.extend({generateLighthouseMetaData:async({},e,n)=>{let t=0;const{title:a,outputDir:i}=n;await e((()=>{const e=a.replace(/[:]/g,"_");return{formats:{html:!0},name:t?e:`${e}-${t++}`,directory:i,get pathToLightHouseHTMLReport(){return`${i}/${this.name}.html`}}}))},attachLighthouseReport:async({},e,n)=>{await e((async e=>{e.endsWith(".html")?await n.attach("lighthouse",{path:e,contentType:"text/html"}):I.redText(P.attachLightHouseReport.unsupportedFileType(e))}))}}),cp=new Set(["ENOTFOUND","ENETUNREACH","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_CRL","UNABLE_TO_DECRYPT_CERT_SIGNATURE","UNABLE_TO_DECRYPT_CRL_SIGNATURE","UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY","CERT_SIGNATURE_FAILURE","CRL_SIGNATURE_FAILURE","CERT_NOT_YET_VALID","CERT_HAS_EXPIRED","CRL_NOT_YET_VALID","CRL_HAS_EXPIRED","ERROR_IN_CERT_NOT_BEFORE_FIELD","ERROR_IN_CERT_NOT_AFTER_FIELD","ERROR_IN_CRL_LAST_UPDATE_FIELD","ERROR_IN_CRL_NEXT_UPDATE_FIELD","OUT_OF_MEM","DEPTH_ZERO_SELF_SIGNED_CERT","SELF_SIGNED_CERT_IN_CHAIN","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","UNABLE_TO_VERIFY_LEAF_SIGNATURE","CERT_CHAIN_TOO_LONG","CERT_REVOKED","INVALID_CA","PATH_LENGTH_EXCEEDED","INVALID_PURPOSE","CERT_UNTRUSTED","CERT_REJECTED","HOSTNAME_MISMATCH"]);const up="axios-retry";function pp(e){return!e.response&&(!!e.code&&(!["ERR_CANCELED","ECONNABORTED"].includes(e.code)&&(e=>!cp.has(e&&e.code))(e)))}const lp=["get","head","options"],dp=lp.concat(["put","delete"]);function mp(e){return"ECONNABORTED"!==e.code&&(!e.response||429===e.response.status||e.response.status>=500&&e.response.status<=599)}function fp(e){return!!e.config?.method&&(mp(e)&&-1!==dp.indexOf(e.config.method))}function hp(e){return pp(e)||fp(e)}function vp(e=void 0){const n=e?.response?.headers["retry-after"];if(!n)return 0;let t=1e3*(Number(n)||0);return 0===t&&(t=(new Date(n).valueOf()||0)-Date.now()),Math.max(0,t)}const xp={retries:3,retryCondition:hp,retryDelay:function(e=0,n=void 0){return Math.max(0,vp(n))},shouldResetTimeout:!1,onRetry:()=>{},onMaxRetryTimesExceeded:()=>{},validateResponse:null};function bp(e,n,t=!1){const a=function(e,n){return{...xp,...n,...e[up]}}(e,n||{});return a.retryCount=a.retryCount||0,a.lastRequestTime&&!t||(a.lastRequestTime=Date.now()),e[up]=a,a}const gp=(e,n)=>{const t=e.interceptors.request.use((e=>(bp(e,n,!0),e[up]?.validateResponse&&(e.validateStatus=()=>!1),e))),a=e.interceptors.response.use(null,(async t=>{const{config:a}=t;if(!a)return Promise.reject(t);const i=bp(a,n);return t.response&&i.validateResponse?.(t.response)?t.response:await async function(e,n){const{retries:t,retryCondition:a}=e,i=(e.retryCount||0)<t&&a(n);if("object"==typeof i)try{return!1!==await i}catch(e){return!1}return i}(i,t)?async function(e,n,t,a){n.retryCount+=1;const{retryDelay:i,shouldResetTimeout:o,onRetry:r}=n,s=i(n.retryCount,t);if(function(e,n){e.defaults.agent===n.agent&&delete n.agent,e.defaults.httpAgent===n.httpAgent&&delete n.httpAgent,e.defaults.httpsAgent===n.httpsAgent&&delete n.httpsAgent}(e,a),!o&&a.timeout&&n.lastRequestTime){const e=Date.now()-n.lastRequestTime,i=a.timeout-e-s;if(i<=0)return Promise.reject(t);a.timeout=i}return a.transformRequest=[e=>e],await r(n.retryCount,t,a),a.signal?.aborted?Promise.resolve(e(a)):new Promise((n=>{const t=()=>{clearTimeout(i),n(e(a))},i=setTimeout((()=>{n(e(a)),a.signal?.removeEventListener&&a.signal.removeEventListener("abort",t)}),s);a.signal?.addEventListener&&a.signal.addEventListener("abort",t,{once:!0})}))}(e,i,t,a):(await async function(e,n){e.retryCount>=e.retries&&await e.onMaxRetryTimesExceeded(n,e.retryCount)}(i,t),Promise.reject(t))}));return{requestInterceptorId:t,responseInterceptorId:a}};gp.isNetworkError=pp,gp.isSafeRequestError=function(e){return!!e.config?.method&&(mp(e)&&-1!==lp.indexOf(e.config.method))},gp.isIdempotentRequestError=fp,gp.isNetworkOrIdempotentRequestError=hp,gp.exponentialDelay=function(e=0,n=void 0,t=100){const a=2**e*t,i=Math.max(a,vp(n));return i+.2*i*Math.random()},gp.linearDelay=function(e=100){return(n=0,t=void 0)=>{const a=n*e;return Math.max(a,vp(t))}},gp.isRetryableError=mp;const yp="Content-Type",Dp="Accept",wp="X-Api-Key",_p="Project-Key",Ep="Reporter-Version",Cp=e=>e===Object(e)&&!(e instanceof Buffer);function Fp({projectKey:e,baseURL:n,apiKey:t}){Rc.defaults.baseURL=null!=n?n:"https://connect.neetoplaydash.com",Rc.defaults.skipSnakeCaseConversion=!1,(({projectKey:e,apiKey:n})=>{Rc.defaults.headers={...Rc.defaults.headers,[_p]:e,[Ep]:JSON.parse(a(o(__dirname,"./package.json"),"utf8")).version,[wp]:null!=n?n:"",[Dp]:"application/json",[yp]:"application/json"}})({projectKey:e,apiKey:t}),Rc.interceptors.request.use((e=>{const n=e.data;return Cp(n)&&!e.skipSnakeCaseConversion&&(e.data=Gn(n,(function(e,n){return[$n(e),n]}))),e})),Rc.interceptors.response.use((e=>{const n=e.data;return Cp(n)&&(e.data=Gn(n,(function(e,n){return[(t=e,t.replace(/(_\w)/g,(function(e){return e[1].toUpperCase()}))),n];var t}))),e})),gp(Rc,{retryDelay:gp.exponentialDelay,retryCondition:e=>{var n;const t=null===(n=e.status)||void 0===n?void 0:n.toString();return!!t&&(t.startsWith("5")||"404"===t)},retries:5})}class jp{constructor(e){var n;this.onBegin=(e,n)=>pu(this,e,n),this.onTestBegin=(e,n)=>(async(e,n,{retry:t})=>{var a,i;const{title:o,repeatEachIndex:r}=n,{rootDir:s,currentShard:c,ciBuildId:u}=e,{historyId:p}=su(n,s),l=(new Date).toString(),d=Yn(t,r);if(e.shouldNotReportTest)I.invertBackground(au.startingTest({titlePath:o,historyId:p,retry:t,repeatEachIndex:r}));else{e.unreportedAttemptCount++;try{if(await Vn((()=>{var n,t;return Mn(e.attempts)&&ze(null===(t=null===(n=e.attempts)||void 0===n?void 0:n[p])||void 0===t?void 0:t["0-0"])})),I.invertBackground(au.startingTest({titlePath:o,historyId:p,retry:t,repeatEachIndex:r})),e.shouldNotReportTest)return;const n={status:"running",startedAt:l,shard:c,repeatEachIndex:r};if(0===t&&0===r)await du({ciBuildId:u,historyId:p,id:null===(i=null===(a=e.attempts)||void 0===a?void 0:a[p])||void 0===i?void 0:i["0-0"],payload:n});else{const{data:{attemptId:t}}=await lu(u,p,n);e.attempts=He(e.attempts,{[p]:{[d]:t}})}}catch(e){await Qn({context:{historyId:p,attemptIndex:d,title:o},error:e,title:"onTestBegin"}),I.error(e.message),I.error(S.failedToReportTest(o,p)),await uu(u)}finally{e.startedAttempts.add(Yn(p,d))}}})(this,e,n),this.onTestEnd=async(e,n)=>rp(this,e,n),this.onEnd=async e=>(async(e,{status:n,duration:t})=>{var a,i;const{currentShard:o}=e;try{if(await Vn((()=>(e.hasRunStarted||e.shouldNotReportTest)&&0===e.startedAttempts.size)),I.bold(ou.finalStatus({currentShard:o,status:n,duration:t})),e.shouldNotReportTest)return;if(0===e.totalTestCount)return void await Zc(e.ciBuildId,{shards:Wn({currentShard:o,status:"passed",duration:t})});await Promise.allSettled(e.testResultCalls),await Zc(e.ciBuildId,{shards:Wn({currentShard:o,status:n,duration:t})})}catch(e){const o=null===(a=e.response)||void 0===a?void 0:a.data;await Qn({context:{runStatus:n,runDuration:t},error:e,title:"onEnd"}),I.error(null!==(i=o.error)&&void 0!==i?i:e.message),I.error(O.failedToReportRunStatus)}finally{e.shouldNotReportTest||0===e.totalTestCount||I.invertBackground(ou.runReported),clearInterval(e.heartbeatInterval)}})(this,e),this.attempts={},this.tags=e.tags,this.ciBuildId=e.ciBuildId,this.testResultCalls=[],this.totalTestCount=0,this.unreportedAttemptCount=0,this.hasRunStarted=!1,this.heartbeatInterval=null,this.rootDir="",this.currentShard=0,this.progressBars=[],this.startedAttempts=new Set,this.shouldNotReportTest=!1,this.apiKey=e.apiKey,A.configure({apiKey:Xn("9d5d98e72929dae3c8b3701f50032da1a02b80f9dc29a8e448a601871e5c82fd0ac2fa33c46443709cdb3eabc54a06ab"),environment:(null===(n=null==e?void 0:e.baseURL)||void 0===n?void 0:n.includes(".net"))?"staging":"production"}),A.setContext(e),((e,n)=>{D.setDefaultResultOrder("ipv4first"),Fp(n),process.on("unhandledRejection",(async n=>{var t,a,i;const o=null===(t=n.response)||void 0===t?void 0:t.data;await Qn({context:{},error:n,title:"unhandledRejection"}),await uu(e.ciBuildId),I.error(null!==(i=null!==(a=null==o?void 0:o.error)&&void 0!==a?a:n.message)&&void 0!==i?i:JSON.stringify(n))}))})(this,e)}onStdOut(e,n){n&&I.bold(`Log from test "${n.title}"`),I.log(e.toString())}}export{jp as default,sp as test};
|
|
10
10
|
//# sourceMappingURL=index.js.map
|