@skyramp/testbot-core 0.13.0-v3.216 → 0.13.0-v3.217

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/dist/post.js CHANGED
@@ -48,7 +48,7 @@ ${A}`,this.dataLineCount++;return}if(Ol(e,s,PG)){GG(e,i)&&(this.setEventFieldSiz
48
48
  Error Code : ${a.statusCode}
49
49
 
50
50
  Error Message: ${a.message}`)})).result)===null||n===void 0?void 0:n.value;if(!i)throw new Error("Response json body do not have ID Token field");return i})}static getIDToken(e){return Wk(this,void 0,void 0,function*(){try{let n=t.getIDTokenUrl();if(e){let s=encodeURIComponent(e);n=`${n}&audience=${s}`}Kk(`ID token url is ${n}`);let r=yield t.getCall(n);return Gr(r),r}catch(n){throw new Error(`Error message: ${n.message}`)}})}}});var Xk,su,$g,P2,O2,$2,Zk,Vg,eK,Gg=kt(()=>{Xk=require("os"),su=require("fs"),$g=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})},{access:P2,appendFile:O2,writeFile:$2}=su.promises,Zk="GITHUB_STEP_SUMMARY",Vg=class{constructor(){this._buffer=""}filePath(){return $g(this,void 0,void 0,function*(){if(this._filePath)return this._filePath;let e=process.env[Zk];if(!e)throw new Error(`Unable to find environment variable for $${Zk}. Check if your runtime environment supports job summaries.`);try{yield P2(e,su.constants.R_OK|su.constants.W_OK)}catch{throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}return this._filePath=e,this._filePath})}wrap(e,n,r={}){let s=Object.entries(r).map(([i,a])=>` ${i}="${a}"`).join("");return n?`<${e}${s}>${n}</${e}>`:`<${e}${s}>`}write(e){return $g(this,void 0,void 0,function*(){let n=!!e?.overwrite,r=yield this.filePath();return yield(n?$2:O2)(r,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){return $g(this,void 0,void 0,function*(){return this.emptyBuffer().write({overwrite:!0})})}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){return this._buffer="",this}addRaw(e,n=!1){return this._buffer+=e,n?this.addEOL():this}addEOL(){return this.addRaw(Xk.EOL)}addCodeBlock(e,n){let r=Object.assign({},n&&{lang:n}),s=this.wrap("pre",this.wrap("code",e),r);return this.addRaw(s).addEOL()}addList(e,n=!1){let r=n?"ol":"ul",s=e.map(a=>this.wrap("li",a)).join(""),i=this.wrap(r,s);return this.addRaw(i).addEOL()}addTable(e){let n=e.map(s=>{let i=s.map(a=>{if(typeof a=="string")return this.wrap("td",a);let{header:c,data:A,colspan:l,rowspan:p}=a,h=c?"th":"td",g=Object.assign(Object.assign({},l&&{colspan:l}),p&&{rowspan:p});return this.wrap(h,A,g)}).join("");return this.wrap("tr",i)}).join(""),r=this.wrap("table",n);return this.addRaw(r).addEOL()}addDetails(e,n){let r=this.wrap("details",this.wrap("summary",e)+n);return this.addRaw(r).addEOL()}addImage(e,n,r){let{width:s,height:i}=r||{},a=Object.assign(Object.assign({},s&&{width:s}),i&&{height:i}),c=this.wrap("img",null,Object.assign({src:e,alt:n},a));return this.addRaw(c).addEOL()}addHeading(e,n){let r=`h${n}`,s=["h1","h2","h3","h4","h5","h6"].includes(r)?r:"h1",i=this.wrap(s,e);return this.addRaw(i).addEOL()}addSeparator(){let e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){let e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,n){let r=Object.assign({},n&&{cite:n}),s=this.wrap("blockquote",e,r);return this.addRaw(s).addEOL()}addLink(e,n){let r=this.wrap("a",e,{href:n});return this.addRaw(r).addEOL()}},eK=new Vg});var ev=kt(()=>{});function Hg(t){return nv(this,void 0,void 0,function*(){try{yield jl(t)}catch(e){if(e.code==="ENOENT")return!1;throw e}return!0})}function Wl(t){if(t=z2(t),!t)throw new Error('isRooted() parameter "p" cannot be empty');return Ri?t.startsWith("\\")||/^[A-Z]:/i.test(t):t.startsWith("/")}function Yg(t,e){return nv(this,void 0,void 0,function*(){let n;try{n=yield jl(t)}catch(s){s.code!=="ENOENT"&&console.log(`Unexpected error attempting to determine if executable file exists '${t}': ${s}`)}if(n&&n.isFile()){if(Ri){let s=ks.extname(t).toUpperCase();if(e.some(i=>i.toUpperCase()===s))return t}else if(tv(n))return t}let r=t;for(let s of e){t=r+s,n=void 0;try{n=yield jl(t)}catch(i){i.code!=="ENOENT"&&console.log(`Unexpected error attempting to determine if executable file exists '${t}': ${i}`)}if(n&&n.isFile()){if(Ri){try{let i=ks.dirname(t),a=ks.basename(t).toUpperCase();for(let c of yield rv(i))if(a===c.toUpperCase()){t=ks.join(i,c);break}}catch(i){console.log(`Unexpected error attempting to determine the actual case of the file '${t}': ${i}`)}return t}else if(tv(n))return t}}return""})}function z2(t){return t=t||"",Ri?(t=t.replace(/\//g,"\\"),t.replace(/\\\\+/g,"\\")):t.replace(/\/\/+/g,"/")}function tv(t){return(t.mode&1)>0||(t.mode&8)>0&&process.getgid!==void 0&&t.gid===process.getgid()||(t.mode&64)>0&&process.getuid!==void 0&&t.uid===process.getuid()}var Jl,ks,nv,V2,G2,H2,Y2,rK,rv,q2,j2,sK,jl,J2,W2,Ri,iK,qg=kt(()=>{Jl=Re(require("fs"),1),ks=Re(require("path"),1),nv=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})},{chmod:V2,copyFile:G2,lstat:H2,mkdir:Y2,open:rK,readdir:rv,rename:q2,rm:j2,rmdir:sK,stat:jl,symlink:J2,unlink:W2}=Jl.promises,Ri=process.platform==="win32",iK=Jl.constants.O_RDONLY});function jg(t,e){return iv(this,void 0,void 0,function*(){if(!t)throw new Error("parameter 'tool' is required");if(e){let r=yield jg(t,!1);if(!r)throw Ri?new Error(`Unable to locate executable file: ${t}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`):new Error(`Unable to locate executable file: ${t}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`);return r}let n=yield K2(t);return n&&n.length>0?n[0]:""})}function K2(t){return iv(this,void 0,void 0,function*(){if(!t)throw new Error("parameter 'tool' is required");let e=[];if(Ri&&process.env.PATHEXT)for(let s of process.env.PATHEXT.split(dr.delimiter))s&&e.push(s);if(Wl(t)){let s=yield Yg(t,e);return s?[s]:[]}if(t.includes(dr.sep))return[];let n=[];if(process.env.PATH)for(let s of process.env.PATH.split(dr.delimiter))s&&n.push(s);let r=[];for(let s of n){let i=yield Yg(dr.join(s,t),e);i&&r.push(i)}return r})}var dr,iv,ov=kt(()=>{dr=Re(require("path"),1);qg();iv=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})}});function lv(t){let e=[],n=!1,r=!1,s="";function i(a){r&&a!=='"'&&(s+="\\"),s+=a,r=!1}for(let a=0;a<t.length;a++){let c=t.charAt(a);if(c==='"'){r?i(c):n=!n;continue}if(c==="\\"&&r){i(c);continue}if(c==="\\"&&n){r=!0;continue}if(c===" "&&!n){s.length>0&&(e.push(s),s="");continue}i(c)}return s.length>0&&e.push(s.trim()),e}var iu,Wg,cv,uv,Av,av,zl,Kl,Jg,dv=kt(()=>{iu=Re(require("os"),1),Wg=Re(require("events"),1),cv=Re(require("child_process"),1),uv=Re(require("path"),1);ov();qg();Av=require("timers"),av=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})},zl=process.platform==="win32",Kl=class extends Wg.EventEmitter{constructor(e,n,r){if(super(),!e)throw new Error("Parameter 'toolPath' cannot be null or empty.");this.toolPath=e,this.args=n||[],this.options=r||{}}_debug(e){this.options.listeners&&this.options.listeners.debug&&this.options.listeners.debug(e)}_getCommandString(e,n){let r=this._getSpawnFileName(),s=this._getSpawnArgs(e),i=n?"":"[command]";if(zl)if(this._isCmdFile()){i+=r;for(let a of s)i+=` ${a}`}else if(e.windowsVerbatimArguments){i+=`"${r}"`;for(let a of s)i+=` ${a}`}else{i+=this._windowsQuoteCmdArg(r);for(let a of s)i+=` ${this._windowsQuoteCmdArg(a)}`}else{i+=r;for(let a of s)i+=` ${a}`}return i}_processLineBuffer(e,n,r){try{let s=n+e.toString(),i=s.indexOf(iu.EOL);for(;i>-1;){let a=s.substring(0,i);r(a),s=s.substring(i+iu.EOL.length),i=s.indexOf(iu.EOL)}return s}catch(s){return this._debug(`error processing line. Failed with error ${s}`),""}}_getSpawnFileName(){return zl&&this._isCmdFile()?process.env.COMSPEC||"cmd.exe":this.toolPath}_getSpawnArgs(e){if(zl&&this._isCmdFile()){let n=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(let r of this.args)n+=" ",n+=e.windowsVerbatimArguments?r:this._windowsQuoteCmdArg(r);return n+='"',[n]}return this.args}_endsWith(e,n){return e.endsWith(n)}_isCmdFile(){let e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile())return this._uvQuoteCmdArg(e);if(!e)return'""';let n=[" "," ","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'],r=!1;for(let a of e)if(n.some(c=>c===a)){r=!0;break}if(!r)return e;let s='"',i=!0;for(let a=e.length;a>0;a--)s+=e[a-1],i&&e[a-1]==="\\"?s+="\\":e[a-1]==='"'?(i=!0,s+='"'):i=!1;return s+='"',s.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e)return'""';if(!e.includes(" ")&&!e.includes(" ")&&!e.includes('"'))return e;if(!e.includes('"')&&!e.includes("\\"))return`"${e}"`;let n='"',r=!0;for(let s=e.length;s>0;s--)n+=e[s-1],r&&e[s-1]==="\\"?n+="\\":e[s-1]==='"'?(r=!0,n+="\\"):r=!1;return n+='"',n.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};let n={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||!1,windowsVerbatimArguments:e.windowsVerbatimArguments||!1,failOnStdErr:e.failOnStdErr||!1,ignoreReturnCode:e.ignoreReturnCode||!1,delay:e.delay||1e4};return n.outStream=e.outStream||process.stdout,n.errStream=e.errStream||process.stderr,n}_getSpawnOptions(e,n){e=e||{};let r={};return r.cwd=e.cwd,r.env=e.env,r.windowsVerbatimArguments=e.windowsVerbatimArguments||this._isCmdFile(),e.windowsVerbatimArguments&&(r.argv0=`"${n}"`),r}exec(){return av(this,void 0,void 0,function*(){return!Wl(this.toolPath)&&(this.toolPath.includes("/")||zl&&this.toolPath.includes("\\"))&&(this.toolPath=uv.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)),this.toolPath=yield jg(this.toolPath,!0),new Promise((e,n)=>av(this,void 0,void 0,function*(){this._debug(`exec tool: ${this.toolPath}`),this._debug("arguments:");for(let l of this.args)this._debug(` ${l}`);let r=this._cloneExecOptions(this.options);!r.silent&&r.outStream&&r.outStream.write(this._getCommandString(r)+iu.EOL);let s=new Jg(r,this.toolPath);if(s.on("debug",l=>{this._debug(l)}),this.options.cwd&&!(yield Hg(this.options.cwd)))return n(new Error(`The cwd: ${this.options.cwd} does not exist!`));let i=this._getSpawnFileName(),a=cv.spawn(i,this._getSpawnArgs(r),this._getSpawnOptions(this.options,i)),c="";a.stdout&&a.stdout.on("data",l=>{this.options.listeners&&this.options.listeners.stdout&&this.options.listeners.stdout(l),!r.silent&&r.outStream&&r.outStream.write(l),c=this._processLineBuffer(l,c,p=>{this.options.listeners&&this.options.listeners.stdline&&this.options.listeners.stdline(p)})});let A="";if(a.stderr&&a.stderr.on("data",l=>{s.processStderr=!0,this.options.listeners&&this.options.listeners.stderr&&this.options.listeners.stderr(l),!r.silent&&r.errStream&&r.outStream&&(r.failOnStdErr?r.errStream:r.outStream).write(l),A=this._processLineBuffer(l,A,p=>{this.options.listeners&&this.options.listeners.errline&&this.options.listeners.errline(p)})}),a.on("error",l=>{s.processError=l.message,s.processExited=!0,s.processClosed=!0,s.CheckComplete()}),a.on("exit",l=>{s.processExitCode=l,s.processExited=!0,this._debug(`Exit code ${l} received from tool '${this.toolPath}'`),s.CheckComplete()}),a.on("close",l=>{s.processExitCode=l,s.processExited=!0,s.processClosed=!0,this._debug(`STDIO streams have closed for tool '${this.toolPath}'`),s.CheckComplete()}),s.on("done",(l,p)=>{c.length>0&&this.emit("stdline",c),A.length>0&&this.emit("errline",A),a.removeAllListeners(),l?n(l):e(p)}),this.options.input){if(!a.stdin)throw new Error("child process missing stdin");a.stdin.end(this.options.input)}}))})}};Jg=class t extends Wg.EventEmitter{constructor(e,n){if(super(),this.processClosed=!1,this.processError="",this.processExitCode=0,this.processExited=!1,this.processStderr=!1,this.delay=1e4,this.done=!1,this.timeout=null,!n)throw new Error("toolPath must not be empty");this.options=e,this.toolPath=n,e.delay&&(this.delay=e.delay)}CheckComplete(){this.done||(this.processClosed?this._setResult():this.processExited&&(this.timeout=(0,Av.setTimeout)(t.HandleTimeout,this.delay,this)))}_debug(e){this.emit("debug",e)}_setResult(){let e;this.processExited&&(this.processError?e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`):this.processExitCode!==0&&!this.options.ignoreReturnCode?e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`):this.processStderr&&this.options.failOnStdErr&&(e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`))),this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.done=!0,this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(!e.done){if(!e.processClosed&&e.processExited){let n=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(n)}e._setResult()}}}});function pv(t,e,n){return eH(this,void 0,void 0,function*(){let r=lv(t);if(r.length===0)throw new Error("Parameter 'commandLine' cannot be null or empty.");let s=r[0];return e=r.slice(1).concat(e||[]),new Kl(s,e,n).exec()})}var eH,zg=kt(()=>{dv();eH=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})}});var Kg,uK,AK,fv=kt(()=>{Kg=Re(require("os"),1);zg();uK=Kg.default.platform(),AK=Kg.default.arch()});function Gr(t){ei("add-mask",{},t)}function he(t,e){let n=process.env[`INPUT_${t.replace(/ /g,"_").toUpperCase()}`]||"";if(e&&e.required&&!n)throw new Error(`Input required and not supplied: ${t}`);return e&&e.trimWhitespace===!1?n:n.trim()}function vs(t,e){let n=["true","True","TRUE"],r=["false","False","FALSE"],s=he(t,e);if(n.includes(s))return!0;if(r.includes(s))return!1;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${t}
51
- Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}function mv(t){process.exitCode=Zg.Failure,rH(t)}function Kk(t){ei("debug",{},t)}function rH(t,e={}){ei("error",Yu(e),t instanceof Error?t.toString():t)}function Pe(t,e={}){ei("warning",Yu(e),t instanceof Error?t.toString():t)}function ou(t,e={}){ei("notice",Yu(e),t instanceof Error?t.toString():t)}function In(t){process.stdout.write(t+gv.EOL)}function Zl(t){ap("group",t)}function Xl(){ap("endgroup")}function Rs(t){return process.env[`STATE_${t}`]||""}function yv(t){return nH(this,void 0,void 0,function*(){return yield ql.getIDToken(t)})}var gv,nH,Zg,Dt=kt(()=>{dE();pE();qu();gv=Re(require("os"),1);zk();Gg();Gg();ev();fv();nH=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})};(function(t){t[t.Success=0]="Success",t[t.Failure=1]="Failure"})(Zg||(Zg={}))});var G9={};ip(G9,{post:()=>JT});module.exports=eD(G9);Dt();var jT=Re(require("path"));Dt();Dt();var Xg;(function(t){t.Pass="Pass",t.Fail="Fail",t.Error="Error",t.Skipped="Skipped",t.Unknown="Unknown"})(Xg||(Xg={}));var Ev;(function(t){t.High="high",t.Medium="medium",t.Low="low"})(Ev||(Ev={}));var Cv;(function(t){t.Skyramp="skyramp",t.External="external"})(Cv||(Cv={}));var em;(function(t){t.Update="UPDATE",t.Regenerate="REGENERATE",t.Delete="DELETE",t.Verify="VERIFY",t.Ignore="IGNORE"})(em||(em={}));var Iv;(function(t){t.Small="Small",t.Medium="Medium",t.Large="Large"})(Iv||(Iv={}));var U={};ip(U,{BRAND:()=>RH,DIRTY:()=>xi,EMPTY_PATH:()=>aH,INVALID:()=>se,NEVER:()=>pY,OK:()=>It,ParseStatus:()=>gt,Schema:()=>Ee,ZodAny:()=>Ds,ZodArray:()=>jr,ZodBigInt:()=>Di,ZodBoolean:()=>Ni,ZodBranded:()=>cu,ZodCatch:()=>Hi,ZodDate:()=>Fi,ZodDefault:()=>Gi,ZodDiscriminatedUnion:()=>nd,ZodEffects:()=>wn,ZodEnum:()=>$i,ZodError:()=>Yt,ZodFirstPartyTypeKind:()=>ue,ZodFunction:()=>sd,ZodIntersection:()=>Li,ZodIssueCode:()=>P,ZodLazy:()=>Pi,ZodLiteral:()=>Oi,ZodMap:()=>Ia,ZodNaN:()=>Qa,ZodNativeEnum:()=>Vi,ZodNever:()=>jn,ZodNull:()=>_i,ZodNullable:()=>fr,ZodNumber:()=>Ti,ZodObject:()=>qt,ZodOptional:()=>Bn,ZodParsedType:()=>W,ZodPipeline:()=>uu,ZodPromise:()=>Ns,ZodReadonly:()=>Yi,ZodRecord:()=>rd,ZodSchema:()=>Ee,ZodSet:()=>Ba,ZodString:()=>Ts,ZodSymbol:()=>Ea,ZodTransformer:()=>wn,ZodTuple:()=>hr,ZodType:()=>Ee,ZodUndefined:()=>Mi,ZodUnion:()=>Ui,ZodUnknown:()=>qr,ZodVoid:()=>Ca,addIssueToContext:()=>j,any:()=>LH,array:()=>VH,bigint:()=>NH,boolean:()=>Dv,coerce:()=>dY,custom:()=>Rv,date:()=>FH,datetimeRegex:()=>kv,defaultErrorMap:()=>Hr,discriminatedUnion:()=>qH,effect:()=>sY,enum:()=>tY,function:()=>ZH,getErrorMap:()=>ga,getParsedType:()=>pr,instanceof:()=>TH,intersection:()=>jH,isAborted:()=>ed,isAsync:()=>ma,isDirty:()=>td,isValid:()=>xs,late:()=>xH,lazy:()=>XH,literal:()=>eY,makeIssue:()=>au,map:()=>zH,nan:()=>DH,nativeEnum:()=>nY,never:()=>OH,null:()=>UH,nullable:()=>oY,number:()=>Tv,object:()=>GH,objectUtil:()=>tm,oboolean:()=>lY,onumber:()=>AY,optional:()=>iY,ostring:()=>uY,pipeline:()=>cY,preprocess:()=>aY,promise:()=>rY,quotelessJson:()=>sH,record:()=>WH,set:()=>KH,setErrorMap:()=>oH,strictObject:()=>HH,string:()=>xv,symbol:()=>MH,transformer:()=>sY,tuple:()=>JH,undefined:()=>_H,union:()=>YH,unknown:()=>PH,util:()=>Qe,void:()=>$H});var Qe;(function(t){t.assertEqual=s=>{};function e(s){}t.assertIs=e;function n(s){throw new Error}t.assertNever=n,t.arrayToEnum=s=>{let i={};for(let a of s)i[a]=a;return i},t.getValidEnumValues=s=>{let i=t.objectKeys(s).filter(c=>typeof s[s[c]]!="number"),a={};for(let c of i)a[c]=s[c];return t.objectValues(a)},t.objectValues=s=>t.objectKeys(s).map(function(i){return s[i]}),t.objectKeys=typeof Object.keys=="function"?s=>Object.keys(s):s=>{let i=[];for(let a in s)Object.prototype.hasOwnProperty.call(s,a)&&i.push(a);return i},t.find=(s,i)=>{for(let a of s)if(i(a))return a},t.isInteger=typeof Number.isInteger=="function"?s=>Number.isInteger(s):s=>typeof s=="number"&&Number.isFinite(s)&&Math.floor(s)===s;function r(s,i=" | "){return s.map(a=>typeof a=="string"?`'${a}'`:a).join(i)}t.joinValues=r,t.jsonStringifyReplacer=(s,i)=>typeof i=="bigint"?i.toString():i})(Qe||(Qe={}));var tm;(function(t){t.mergeShapes=(e,n)=>({...e,...n})})(tm||(tm={}));var W=Qe.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),pr=t=>{switch(typeof t){case"undefined":return W.undefined;case"string":return W.string;case"number":return Number.isNaN(t)?W.nan:W.number;case"boolean":return W.boolean;case"function":return W.function;case"bigint":return W.bigint;case"symbol":return W.symbol;case"object":return Array.isArray(t)?W.array:t===null?W.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?W.promise:typeof Map<"u"&&t instanceof Map?W.map:typeof Set<"u"&&t instanceof Set?W.set:typeof Date<"u"&&t instanceof Date?W.date:W.object;default:return W.unknown}};var P=Qe.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),sH=t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:"),Yt=class t extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=r=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};let n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=e}format(e){let n=e||function(i){return i.message},r={_errors:[]},s=i=>{for(let a of i.issues)if(a.code==="invalid_union")a.unionErrors.map(s);else if(a.code==="invalid_return_type")s(a.returnTypeError);else if(a.code==="invalid_arguments")s(a.argumentsError);else if(a.path.length===0)r._errors.push(n(a));else{let c=r,A=0;for(;A<a.path.length;){let l=a.path[A];A===a.path.length-1?(c[l]=c[l]||{_errors:[]},c[l]._errors.push(n(a))):c[l]=c[l]||{_errors:[]},c=c[l],A++}}};return s(this),r}static assert(e){if(!(e instanceof t))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Qe.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=n=>n.message){let n={},r=[];for(let s of this.issues)if(s.path.length>0){let i=s.path[0];n[i]=n[i]||[],n[i].push(e(s))}else r.push(e(s));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}};Yt.create=t=>new Yt(t);var iH=(t,e)=>{let n;switch(t.code){case P.invalid_type:t.received===W.undefined?n="Required":n=`Expected ${t.expected}, received ${t.received}`;break;case P.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(t.expected,Qe.jsonStringifyReplacer)}`;break;case P.unrecognized_keys:n=`Unrecognized key(s) in object: ${Qe.joinValues(t.keys,", ")}`;break;case P.invalid_union:n="Invalid input";break;case P.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${Qe.joinValues(t.options)}`;break;case P.invalid_enum_value:n=`Invalid enum value. Expected ${Qe.joinValues(t.options)}, received '${t.received}'`;break;case P.invalid_arguments:n="Invalid function arguments";break;case P.invalid_return_type:n="Invalid function return type";break;case P.invalid_date:n="Invalid date";break;case P.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(n=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?n=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?n=`Invalid input: must end with "${t.validation.endsWith}"`:Qe.assertNever(t.validation):t.validation!=="regex"?n=`Invalid ${t.validation}`:n="Invalid";break;case P.too_small:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="bigint"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:n="Invalid input";break;case P.too_big:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?n=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:n="Invalid input";break;case P.custom:n="Invalid input";break;case P.invalid_intersection_types:n="Intersection results could not be merged";break;case P.not_multiple_of:n=`Number must be a multiple of ${t.multipleOf}`;break;case P.not_finite:n="Number must be finite";break;default:n=e.defaultError,Qe.assertNever(t)}return{message:n}},Hr=iH;var Bv=Hr;function oH(t){Bv=t}function ga(){return Bv}var au=t=>{let{data:e,path:n,errorMaps:r,issueData:s}=t,i=[...n,...s.path||[]],a={...s,path:i};if(s.message!==void 0)return{...s,path:i,message:s.message};let c="",A=r.filter(l=>!!l).slice().reverse();for(let l of A)c=l(a,{data:e,defaultError:c}).message;return{...s,path:i,message:c}},aH=[];function j(t,e){let n=ga(),r=au({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,n,n===Hr?void 0:Hr].filter(s=>!!s)});t.common.issues.push(r)}var gt=class t{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,n){let r=[];for(let s of n){if(s.status==="aborted")return se;s.status==="dirty"&&e.dirty(),r.push(s.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,n){let r=[];for(let s of n){let i=await s.key,a=await s.value;r.push({key:i,value:a})}return t.mergeObjectSync(e,r)}static mergeObjectSync(e,n){let r={};for(let s of n){let{key:i,value:a}=s;if(i.status==="aborted"||a.status==="aborted")return se;i.status==="dirty"&&e.dirty(),a.status==="dirty"&&e.dirty(),i.value!=="__proto__"&&(typeof a.value<"u"||s.alwaysSet)&&(r[i.value]=a.value)}return{status:e.value,value:r}}},se=Object.freeze({status:"aborted"}),xi=t=>({status:"dirty",value:t}),It=t=>({status:"valid",value:t}),ed=t=>t.status==="aborted",td=t=>t.status==="dirty",xs=t=>t.status==="valid",ma=t=>typeof Promise<"u"&&t instanceof Promise;var K;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(K||(K={}));var Qn=class{constructor(e,n,r,s){this._cachedPath=[],this.parent=e,this.data=n,this._path=r,this._key=s}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},Qv=(t,e)=>{if(xs(e))return{success:!0,data:e.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let n=new Yt(t.common.issues);return this._error=n,this._error}}};function ge(t){if(!t)return{};let{errorMap:e,invalid_type_error:n,required_error:r,description:s}=t;if(e&&(n||r))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:s}:{errorMap:(a,c)=>{let{message:A}=t;return a.code==="invalid_enum_value"?{message:A??c.defaultError}:typeof c.data>"u"?{message:A??r??c.defaultError}:a.code!=="invalid_type"?{message:c.defaultError}:{message:A??n??c.defaultError}},description:s}}var Ee=class{get description(){return this._def.description}_getType(e){return pr(e.data)}_getOrReturnCtx(e,n){return n||{common:e.parent.common,data:e.data,parsedType:pr(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new gt,ctx:{common:e.parent.common,data:e.data,parsedType:pr(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let n=this._parse(e);if(ma(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(e){let n=this._parse(e);return Promise.resolve(n)}parse(e,n){let r=this.safeParse(e,n);if(r.success)return r.data;throw r.error}safeParse(e,n){let r={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)},s=this._parseSync({data:e,path:r.path,parent:r});return Qv(r,s)}"~validate"(e){let n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:n});return xs(r)?{value:r.value}:{issues:n.common.issues}}catch(r){r?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:n}).then(r=>xs(r)?{value:r.value}:{issues:n.common.issues})}async parseAsync(e,n){let r=await this.safeParseAsync(e,n);if(r.success)return r.data;throw r.error}async safeParseAsync(e,n){let r={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)},s=this._parse({data:e,path:r.path,parent:r}),i=await(ma(s)?s:Promise.resolve(s));return Qv(r,i)}refine(e,n){let r=s=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(s):n;return this._refinement((s,i)=>{let a=e(s),c=()=>i.addIssue({code:P.custom,...r(s)});return typeof Promise<"u"&&a instanceof Promise?a.then(A=>A?!0:(c(),!1)):a?!0:(c(),!1)})}refinement(e,n){return this._refinement((r,s)=>e(r)?!0:(s.addIssue(typeof n=="function"?n(r,s):n),!1))}_refinement(e){return new wn({schema:this,typeName:ue.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return Bn.create(this,this._def)}nullable(){return fr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return jr.create(this)}promise(){return Ns.create(this,this._def)}or(e){return Ui.create([this,e],this._def)}and(e){return Li.create(this,e,this._def)}transform(e){return new wn({...ge(this._def),schema:this,typeName:ue.ZodEffects,effect:{type:"transform",transform:e}})}default(e){let n=typeof e=="function"?e:()=>e;return new Gi({...ge(this._def),innerType:this,defaultValue:n,typeName:ue.ZodDefault})}brand(){return new cu({typeName:ue.ZodBranded,type:this,...ge(this._def)})}catch(e){let n=typeof e=="function"?e:()=>e;return new Hi({...ge(this._def),innerType:this,catchValue:n,typeName:ue.ZodCatch})}describe(e){let n=this.constructor;return new n({...this._def,description:e})}pipe(e){return uu.create(this,e)}readonly(){return Yi.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},cH=/^c[^\s-]{8,}$/i,uH=/^[0-9a-z]+$/,AH=/^[0-9A-HJKMNP-TV-Z]{26}$/i,lH=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,dH=/^[a-z0-9_-]{21}$/i,pH=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,hH=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,fH=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,gH="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",nm,mH=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,yH=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,EH=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,CH=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,IH=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,BH=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,bv="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",QH=new RegExp(`^${bv}$`);function Sv(t){let e="[0-5]\\d";t.precision?e=`${e}\\.\\d{${t.precision}}`:t.precision==null&&(e=`${e}(\\.\\d+)?`);let n=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${e})${n}`}function wH(t){return new RegExp(`^${Sv(t)}$`)}function kv(t){let e=`${bv}T${Sv(t)}`,n=[];return n.push(t.local?"Z?":"Z"),t.offset&&n.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${n.join("|")})`,new RegExp(`^${e}$`)}function bH(t,e){return!!((e==="v4"||!e)&&mH.test(t)||(e==="v6"||!e)&&EH.test(t))}function SH(t,e){if(!pH.test(t))return!1;try{let[n]=t.split(".");if(!n)return!1;let r=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),s=JSON.parse(atob(r));return!(typeof s!="object"||s===null||"typ"in s&&s?.typ!=="JWT"||!s.alg||e&&s.alg!==e)}catch{return!1}}function kH(t,e){return!!((e==="v4"||!e)&&yH.test(t)||(e==="v6"||!e)&&CH.test(t))}var Ts=class t extends Ee{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==W.string){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_type,expected:W.string,received:i.parsedType}),se}let r=new gt,s;for(let i of this._def.checks)if(i.kind==="min")e.data.length<i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="max")e.data.length>i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="length"){let a=e.data.length>i.value,c=e.data.length<i.value;(a||c)&&(s=this._getOrReturnCtx(e,s),a?j(s,{code:P.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):c&&j(s,{code:P.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),r.dirty())}else if(i.kind==="email")fH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"email",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="emoji")nm||(nm=new RegExp(gH,"u")),nm.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"emoji",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="uuid")lH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"uuid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="nanoid")dH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"nanoid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid")cH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"cuid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid2")uH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"cuid2",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="ulid")AH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"ulid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="url")try{new URL(e.data)}catch{s=this._getOrReturnCtx(e,s),j(s,{validation:"url",code:P.invalid_string,message:i.message}),r.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"regex",code:P.invalid_string,message:i.message}),r.dirty())):i.kind==="trim"?e.data=e.data.trim():i.kind==="includes"?e.data.includes(i.value,i.position)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),r.dirty()):i.kind==="toLowerCase"?e.data=e.data.toLowerCase():i.kind==="toUpperCase"?e.data=e.data.toUpperCase():i.kind==="startsWith"?e.data.startsWith(i.value)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:{startsWith:i.value},message:i.message}),r.dirty()):i.kind==="endsWith"?e.data.endsWith(i.value)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:{endsWith:i.value},message:i.message}),r.dirty()):i.kind==="datetime"?kv(i).test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:"datetime",message:i.message}),r.dirty()):i.kind==="date"?QH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:"date",message:i.message}),r.dirty()):i.kind==="time"?wH(i).test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:"time",message:i.message}),r.dirty()):i.kind==="duration"?hH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"duration",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="ip"?bH(e.data,i.version)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"ip",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="jwt"?SH(e.data,i.alg)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"jwt",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="cidr"?kH(e.data,i.version)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"cidr",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="base64"?IH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"base64",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="base64url"?BH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"base64url",code:P.invalid_string,message:i.message}),r.dirty()):Qe.assertNever(i);return{status:r.value,value:e.data}}_regex(e,n,r){return this.refinement(s=>e.test(s),{validation:n,code:P.invalid_string,...K.errToObj(r)})}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...K.errToObj(e)})}url(e){return this._addCheck({kind:"url",...K.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...K.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...K.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...K.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...K.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...K.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...K.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...K.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...K.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...K.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...K.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...K.errToObj(e)})}datetime(e){return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...K.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...K.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...K.errToObj(e)})}regex(e,n){return this._addCheck({kind:"regex",regex:e,...K.errToObj(n)})}includes(e,n){return this._addCheck({kind:"includes",value:e,position:n?.position,...K.errToObj(n?.message)})}startsWith(e,n){return this._addCheck({kind:"startsWith",value:e,...K.errToObj(n)})}endsWith(e,n){return this._addCheck({kind:"endsWith",value:e,...K.errToObj(n)})}min(e,n){return this._addCheck({kind:"min",value:e,...K.errToObj(n)})}max(e,n){return this._addCheck({kind:"max",value:e,...K.errToObj(n)})}length(e,n){return this._addCheck({kind:"length",value:e,...K.errToObj(n)})}nonempty(e){return this.min(1,K.errToObj(e))}trim(){return new t({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new t({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new t({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxLength(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}};Ts.create=t=>new Ts({checks:[],typeName:ue.ZodString,coerce:t?.coerce??!1,...ge(t)});function vH(t,e){let n=(t.toString().split(".")[1]||"").length,r=(e.toString().split(".")[1]||"").length,s=n>r?n:r,i=Number.parseInt(t.toFixed(s).replace(".","")),a=Number.parseInt(e.toFixed(s).replace(".",""));return i%a/10**s}var Ti=class t extends Ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==W.number){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_type,expected:W.number,received:i.parsedType}),se}let r,s=new gt;for(let i of this._def.checks)i.kind==="int"?Qe.isInteger(e.data)||(r=this._getOrReturnCtx(e,r),j(r,{code:P.invalid_type,expected:"integer",received:"float",message:i.message}),s.dirty()):i.kind==="min"?(i.inclusive?e.data<i.value:e.data<=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),s.dirty()):i.kind==="max"?(i.inclusive?e.data>i.value:e.data>=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),s.dirty()):i.kind==="multipleOf"?vH(e.data,i.value)!==0&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.not_multiple_of,multipleOf:i.value,message:i.message}),s.dirty()):i.kind==="finite"?Number.isFinite(e.data)||(r=this._getOrReturnCtx(e,r),j(r,{code:P.not_finite,message:i.message}),s.dirty()):Qe.assertNever(i);return{status:s.value,value:e.data}}gte(e,n){return this.setLimit("min",e,!0,K.toString(n))}gt(e,n){return this.setLimit("min",e,!1,K.toString(n))}lte(e,n){return this.setLimit("max",e,!0,K.toString(n))}lt(e,n){return this.setLimit("max",e,!1,K.toString(n))}setLimit(e,n,r,s){return new t({...this._def,checks:[...this._def.checks,{kind:e,value:n,inclusive:r,message:K.toString(s)}]})}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:K.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:K.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:K.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:K.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:K.toString(e)})}multipleOf(e,n){return this._addCheck({kind:"multipleOf",value:e,message:K.toString(n)})}finite(e){return this._addCheck({kind:"finite",message:K.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:K.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:K.toString(e)})}get minValue(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxValue(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Qe.isInteger(e.value))}get isFinite(){let e=null,n=null;for(let r of this._def.checks){if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;r.kind==="min"?(n===null||r.value>n)&&(n=r.value):r.kind==="max"&&(e===null||r.value<e)&&(e=r.value)}return Number.isFinite(n)&&Number.isFinite(e)}};Ti.create=t=>new Ti({checks:[],typeName:ue.ZodNumber,coerce:t?.coerce||!1,...ge(t)});var Di=class t extends Ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==W.bigint)return this._getInvalidInput(e);let r,s=new gt;for(let i of this._def.checks)i.kind==="min"?(i.inclusive?e.data<i.value:e.data<=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),s.dirty()):i.kind==="max"?(i.inclusive?e.data>i.value:e.data>=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),s.dirty()):i.kind==="multipleOf"?e.data%i.value!==BigInt(0)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.not_multiple_of,multipleOf:i.value,message:i.message}),s.dirty()):Qe.assertNever(i);return{status:s.value,value:e.data}}_getInvalidInput(e){let n=this._getOrReturnCtx(e);return j(n,{code:P.invalid_type,expected:W.bigint,received:n.parsedType}),se}gte(e,n){return this.setLimit("min",e,!0,K.toString(n))}gt(e,n){return this.setLimit("min",e,!1,K.toString(n))}lte(e,n){return this.setLimit("max",e,!0,K.toString(n))}lt(e,n){return this.setLimit("max",e,!1,K.toString(n))}setLimit(e,n,r,s){return new t({...this._def,checks:[...this._def.checks,{kind:e,value:n,inclusive:r,message:K.toString(s)}]})}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:K.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:K.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:K.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:K.toString(e)})}multipleOf(e,n){return this._addCheck({kind:"multipleOf",value:e,message:K.toString(n)})}get minValue(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxValue(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}};Di.create=t=>new Di({checks:[],typeName:ue.ZodBigInt,coerce:t?.coerce??!1,...ge(t)});var Ni=class extends Ee{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==W.boolean){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.boolean,received:r.parsedType}),se}return It(e.data)}};Ni.create=t=>new Ni({typeName:ue.ZodBoolean,coerce:t?.coerce||!1,...ge(t)});var Fi=class t extends Ee{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==W.date){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_type,expected:W.date,received:i.parsedType}),se}if(Number.isNaN(e.data.getTime())){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_date}),se}let r=new gt,s;for(let i of this._def.checks)i.kind==="min"?e.data.getTime()<i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),r.dirty()):i.kind==="max"?e.data.getTime()>i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),r.dirty()):Qe.assertNever(i);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}min(e,n){return this._addCheck({kind:"min",value:e.getTime(),message:K.toString(n)})}max(e,n){return this._addCheck({kind:"max",value:e.getTime(),message:K.toString(n)})}get minDate(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e!=null?new Date(e):null}};Fi.create=t=>new Fi({checks:[],coerce:t?.coerce||!1,typeName:ue.ZodDate,...ge(t)});var Ea=class extends Ee{_parse(e){if(this._getType(e)!==W.symbol){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.symbol,received:r.parsedType}),se}return It(e.data)}};Ea.create=t=>new Ea({typeName:ue.ZodSymbol,...ge(t)});var Mi=class extends Ee{_parse(e){if(this._getType(e)!==W.undefined){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.undefined,received:r.parsedType}),se}return It(e.data)}};Mi.create=t=>new Mi({typeName:ue.ZodUndefined,...ge(t)});var _i=class extends Ee{_parse(e){if(this._getType(e)!==W.null){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.null,received:r.parsedType}),se}return It(e.data)}};_i.create=t=>new _i({typeName:ue.ZodNull,...ge(t)});var Ds=class extends Ee{constructor(){super(...arguments),this._any=!0}_parse(e){return It(e.data)}};Ds.create=t=>new Ds({typeName:ue.ZodAny,...ge(t)});var qr=class extends Ee{constructor(){super(...arguments),this._unknown=!0}_parse(e){return It(e.data)}};qr.create=t=>new qr({typeName:ue.ZodUnknown,...ge(t)});var jn=class extends Ee{_parse(e){let n=this._getOrReturnCtx(e);return j(n,{code:P.invalid_type,expected:W.never,received:n.parsedType}),se}};jn.create=t=>new jn({typeName:ue.ZodNever,...ge(t)});var Ca=class extends Ee{_parse(e){if(this._getType(e)!==W.undefined){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.void,received:r.parsedType}),se}return It(e.data)}};Ca.create=t=>new Ca({typeName:ue.ZodVoid,...ge(t)});var jr=class t extends Ee{_parse(e){let{ctx:n,status:r}=this._processInputParams(e),s=this._def;if(n.parsedType!==W.array)return j(n,{code:P.invalid_type,expected:W.array,received:n.parsedType}),se;if(s.exactLength!==null){let a=n.data.length>s.exactLength.value,c=n.data.length<s.exactLength.value;(a||c)&&(j(n,{code:a?P.too_big:P.too_small,minimum:c?s.exactLength.value:void 0,maximum:a?s.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:s.exactLength.message}),r.dirty())}if(s.minLength!==null&&n.data.length<s.minLength.value&&(j(n,{code:P.too_small,minimum:s.minLength.value,type:"array",inclusive:!0,exact:!1,message:s.minLength.message}),r.dirty()),s.maxLength!==null&&n.data.length>s.maxLength.value&&(j(n,{code:P.too_big,maximum:s.maxLength.value,type:"array",inclusive:!0,exact:!1,message:s.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((a,c)=>s.type._parseAsync(new Qn(n,a,n.path,c)))).then(a=>gt.mergeArray(r,a));let i=[...n.data].map((a,c)=>s.type._parseSync(new Qn(n,a,n.path,c)));return gt.mergeArray(r,i)}get element(){return this._def.type}min(e,n){return new t({...this._def,minLength:{value:e,message:K.toString(n)}})}max(e,n){return new t({...this._def,maxLength:{value:e,message:K.toString(n)}})}length(e,n){return new t({...this._def,exactLength:{value:e,message:K.toString(n)}})}nonempty(e){return this.min(1,e)}};jr.create=(t,e)=>new jr({type:t,minLength:null,maxLength:null,exactLength:null,typeName:ue.ZodArray,...ge(e)});function ya(t){if(t instanceof qt){let e={};for(let n in t.shape){let r=t.shape[n];e[n]=Bn.create(ya(r))}return new qt({...t._def,shape:()=>e})}else return t instanceof jr?new jr({...t._def,type:ya(t.element)}):t instanceof Bn?Bn.create(ya(t.unwrap())):t instanceof fr?fr.create(ya(t.unwrap())):t instanceof hr?hr.create(t.items.map(e=>ya(e))):t}var qt=class t extends Ee{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),n=Qe.objectKeys(e);return this._cached={shape:e,keys:n},this._cached}_parse(e){if(this._getType(e)!==W.object){let l=this._getOrReturnCtx(e);return j(l,{code:P.invalid_type,expected:W.object,received:l.parsedType}),se}let{status:r,ctx:s}=this._processInputParams(e),{shape:i,keys:a}=this._getCached(),c=[];if(!(this._def.catchall instanceof jn&&this._def.unknownKeys==="strip"))for(let l in s.data)a.includes(l)||c.push(l);let A=[];for(let l of a){let p=i[l],h=s.data[l];A.push({key:{status:"valid",value:l},value:p._parse(new Qn(s,h,s.path,l)),alwaysSet:l in s.data})}if(this._def.catchall instanceof jn){let l=this._def.unknownKeys;if(l==="passthrough")for(let p of c)A.push({key:{status:"valid",value:p},value:{status:"valid",value:s.data[p]}});else if(l==="strict")c.length>0&&(j(s,{code:P.unrecognized_keys,keys:c}),r.dirty());else if(l!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let l=this._def.catchall;for(let p of c){let h=s.data[p];A.push({key:{status:"valid",value:p},value:l._parse(new Qn(s,h,s.path,p)),alwaysSet:p in s.data})}}return s.common.async?Promise.resolve().then(async()=>{let l=[];for(let p of A){let h=await p.key,g=await p.value;l.push({key:h,value:g,alwaysSet:p.alwaysSet})}return l}).then(l=>gt.mergeObjectSync(r,l)):gt.mergeObjectSync(r,A)}get shape(){return this._def.shape()}strict(e){return K.errToObj,new t({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(n,r)=>{let s=this._def.errorMap?.(n,r).message??r.defaultError;return n.code==="unrecognized_keys"?{message:K.errToObj(e).message??s}:{message:s}}}:{}})}strip(){return new t({...this._def,unknownKeys:"strip"})}passthrough(){return new t({...this._def,unknownKeys:"passthrough"})}extend(e){return new t({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new t({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:ue.ZodObject})}setKey(e,n){return this.augment({[e]:n})}catchall(e){return new t({...this._def,catchall:e})}pick(e){let n={};for(let r of Qe.objectKeys(e))e[r]&&this.shape[r]&&(n[r]=this.shape[r]);return new t({...this._def,shape:()=>n})}omit(e){let n={};for(let r of Qe.objectKeys(this.shape))e[r]||(n[r]=this.shape[r]);return new t({...this._def,shape:()=>n})}deepPartial(){return ya(this)}partial(e){let n={};for(let r of Qe.objectKeys(this.shape)){let s=this.shape[r];e&&!e[r]?n[r]=s:n[r]=s.optional()}return new t({...this._def,shape:()=>n})}required(e){let n={};for(let r of Qe.objectKeys(this.shape))if(e&&!e[r])n[r]=this.shape[r];else{let i=this.shape[r];for(;i instanceof Bn;)i=i._def.innerType;n[r]=i}return new t({...this._def,shape:()=>n})}keyof(){return vv(Qe.objectKeys(this.shape))}};qt.create=(t,e)=>new qt({shape:()=>t,unknownKeys:"strip",catchall:jn.create(),typeName:ue.ZodObject,...ge(e)});qt.strictCreate=(t,e)=>new qt({shape:()=>t,unknownKeys:"strict",catchall:jn.create(),typeName:ue.ZodObject,...ge(e)});qt.lazycreate=(t,e)=>new qt({shape:t,unknownKeys:"strip",catchall:jn.create(),typeName:ue.ZodObject,...ge(e)});var Ui=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r=this._def.options;function s(i){for(let c of i)if(c.result.status==="valid")return c.result;for(let c of i)if(c.result.status==="dirty")return n.common.issues.push(...c.ctx.common.issues),c.result;let a=i.map(c=>new Yt(c.ctx.common.issues));return j(n,{code:P.invalid_union,unionErrors:a}),se}if(n.common.async)return Promise.all(r.map(async i=>{let a={...n,common:{...n.common,issues:[]},parent:null};return{result:await i._parseAsync({data:n.data,path:n.path,parent:a}),ctx:a}})).then(s);{let i,a=[];for(let A of r){let l={...n,common:{...n.common,issues:[]},parent:null},p=A._parseSync({data:n.data,path:n.path,parent:l});if(p.status==="valid")return p;p.status==="dirty"&&!i&&(i={result:p,ctx:l}),l.common.issues.length&&a.push(l.common.issues)}if(i)return n.common.issues.push(...i.ctx.common.issues),i.result;let c=a.map(A=>new Yt(A));return j(n,{code:P.invalid_union,unionErrors:c}),se}}get options(){return this._def.options}};Ui.create=(t,e)=>new Ui({options:t,typeName:ue.ZodUnion,...ge(e)});var Yr=t=>t instanceof Pi?Yr(t.schema):t instanceof wn?Yr(t.innerType()):t instanceof Oi?[t.value]:t instanceof $i?t.options:t instanceof Vi?Qe.objectValues(t.enum):t instanceof Gi?Yr(t._def.innerType):t instanceof Mi?[void 0]:t instanceof _i?[null]:t instanceof Bn?[void 0,...Yr(t.unwrap())]:t instanceof fr?[null,...Yr(t.unwrap())]:t instanceof cu||t instanceof Yi?Yr(t.unwrap()):t instanceof Hi?Yr(t._def.innerType):[],nd=class t extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e);if(n.parsedType!==W.object)return j(n,{code:P.invalid_type,expected:W.object,received:n.parsedType}),se;let r=this.discriminator,s=n.data[r],i=this.optionsMap.get(s);return i?n.common.async?i._parseAsync({data:n.data,path:n.path,parent:n}):i._parseSync({data:n.data,path:n.path,parent:n}):(j(n,{code:P.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),se)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,n,r){let s=new Map;for(let i of n){let a=Yr(i.shape[e]);if(!a.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let c of a){if(s.has(c))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(c)}`);s.set(c,i)}}return new t({typeName:ue.ZodDiscriminatedUnion,discriminator:e,options:n,optionsMap:s,...ge(r)})}};function rm(t,e){let n=pr(t),r=pr(e);if(t===e)return{valid:!0,data:t};if(n===W.object&&r===W.object){let s=Qe.objectKeys(e),i=Qe.objectKeys(t).filter(c=>s.indexOf(c)!==-1),a={...t,...e};for(let c of i){let A=rm(t[c],e[c]);if(!A.valid)return{valid:!1};a[c]=A.data}return{valid:!0,data:a}}else if(n===W.array&&r===W.array){if(t.length!==e.length)return{valid:!1};let s=[];for(let i=0;i<t.length;i++){let a=t[i],c=e[i],A=rm(a,c);if(!A.valid)return{valid:!1};s.push(A.data)}return{valid:!0,data:s}}else return n===W.date&&r===W.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}var Li=class extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e),s=(i,a)=>{if(ed(i)||ed(a))return se;let c=rm(i.value,a.value);return c.valid?((td(i)||td(a))&&n.dirty(),{status:n.value,value:c.data}):(j(r,{code:P.invalid_intersection_types}),se)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([i,a])=>s(i,a)):s(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}};Li.create=(t,e,n)=>new Li({left:t,right:e,typeName:ue.ZodIntersection,...ge(n)});var hr=class t extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.array)return j(r,{code:P.invalid_type,expected:W.array,received:r.parsedType}),se;if(r.data.length<this._def.items.length)return j(r,{code:P.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),se;!this._def.rest&&r.data.length>this._def.items.length&&(j(r,{code:P.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());let i=[...r.data].map((a,c)=>{let A=this._def.items[c]||this._def.rest;return A?A._parse(new Qn(r,a,r.path,c)):null}).filter(a=>!!a);return r.common.async?Promise.all(i).then(a=>gt.mergeArray(n,a)):gt.mergeArray(n,i)}get items(){return this._def.items}rest(e){return new t({...this._def,rest:e})}};hr.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new hr({items:t,typeName:ue.ZodTuple,rest:null,...ge(e)})};var rd=class t extends Ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.object)return j(r,{code:P.invalid_type,expected:W.object,received:r.parsedType}),se;let s=[],i=this._def.keyType,a=this._def.valueType;for(let c in r.data)s.push({key:i._parse(new Qn(r,c,r.path,c)),value:a._parse(new Qn(r,r.data[c],r.path,c)),alwaysSet:c in r.data});return r.common.async?gt.mergeObjectAsync(n,s):gt.mergeObjectSync(n,s)}get element(){return this._def.valueType}static create(e,n,r){return n instanceof Ee?new t({keyType:e,valueType:n,typeName:ue.ZodRecord,...ge(r)}):new t({keyType:Ts.create(),valueType:e,typeName:ue.ZodRecord,...ge(n)})}},Ia=class extends Ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.map)return j(r,{code:P.invalid_type,expected:W.map,received:r.parsedType}),se;let s=this._def.keyType,i=this._def.valueType,a=[...r.data.entries()].map(([c,A],l)=>({key:s._parse(new Qn(r,c,r.path,[l,"key"])),value:i._parse(new Qn(r,A,r.path,[l,"value"]))}));if(r.common.async){let c=new Map;return Promise.resolve().then(async()=>{for(let A of a){let l=await A.key,p=await A.value;if(l.status==="aborted"||p.status==="aborted")return se;(l.status==="dirty"||p.status==="dirty")&&n.dirty(),c.set(l.value,p.value)}return{status:n.value,value:c}})}else{let c=new Map;for(let A of a){let l=A.key,p=A.value;if(l.status==="aborted"||p.status==="aborted")return se;(l.status==="dirty"||p.status==="dirty")&&n.dirty(),c.set(l.value,p.value)}return{status:n.value,value:c}}}};Ia.create=(t,e,n)=>new Ia({valueType:e,keyType:t,typeName:ue.ZodMap,...ge(n)});var Ba=class t extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.set)return j(r,{code:P.invalid_type,expected:W.set,received:r.parsedType}),se;let s=this._def;s.minSize!==null&&r.data.size<s.minSize.value&&(j(r,{code:P.too_small,minimum:s.minSize.value,type:"set",inclusive:!0,exact:!1,message:s.minSize.message}),n.dirty()),s.maxSize!==null&&r.data.size>s.maxSize.value&&(j(r,{code:P.too_big,maximum:s.maxSize.value,type:"set",inclusive:!0,exact:!1,message:s.maxSize.message}),n.dirty());let i=this._def.valueType;function a(A){let l=new Set;for(let p of A){if(p.status==="aborted")return se;p.status==="dirty"&&n.dirty(),l.add(p.value)}return{status:n.value,value:l}}let c=[...r.data.values()].map((A,l)=>i._parse(new Qn(r,A,r.path,l)));return r.common.async?Promise.all(c).then(A=>a(A)):a(c)}min(e,n){return new t({...this._def,minSize:{value:e,message:K.toString(n)}})}max(e,n){return new t({...this._def,maxSize:{value:e,message:K.toString(n)}})}size(e,n){return this.min(e,n).max(e,n)}nonempty(e){return this.min(1,e)}};Ba.create=(t,e)=>new Ba({valueType:t,minSize:null,maxSize:null,typeName:ue.ZodSet,...ge(e)});var sd=class t extends Ee{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:n}=this._processInputParams(e);if(n.parsedType!==W.function)return j(n,{code:P.invalid_type,expected:W.function,received:n.parsedType}),se;function r(c,A){return au({data:c,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,ga(),Hr].filter(l=>!!l),issueData:{code:P.invalid_arguments,argumentsError:A}})}function s(c,A){return au({data:c,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,ga(),Hr].filter(l=>!!l),issueData:{code:P.invalid_return_type,returnTypeError:A}})}let i={errorMap:n.common.contextualErrorMap},a=n.data;if(this._def.returns instanceof Ns){let c=this;return It(async function(...A){let l=new Yt([]),p=await c._def.args.parseAsync(A,i).catch(C=>{throw l.addIssue(r(A,C)),l}),h=await Reflect.apply(a,this,p);return await c._def.returns._def.type.parseAsync(h,i).catch(C=>{throw l.addIssue(s(h,C)),l})})}else{let c=this;return It(function(...A){let l=c._def.args.safeParse(A,i);if(!l.success)throw new Yt([r(A,l.error)]);let p=Reflect.apply(a,this,l.data),h=c._def.returns.safeParse(p,i);if(!h.success)throw new Yt([s(p,h.error)]);return h.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new t({...this._def,args:hr.create(e).rest(qr.create())})}returns(e){return new t({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,n,r){return new t({args:e||hr.create([]).rest(qr.create()),returns:n||qr.create(),typeName:ue.ZodFunction,...ge(r)})}},Pi=class extends Ee{get schema(){return this._def.getter()}_parse(e){let{ctx:n}=this._processInputParams(e);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};Pi.create=(t,e)=>new Pi({getter:t,typeName:ue.ZodLazy,...ge(e)});var Oi=class extends Ee{_parse(e){if(e.data!==this._def.value){let n=this._getOrReturnCtx(e);return j(n,{received:n.data,code:P.invalid_literal,expected:this._def.value}),se}return{status:"valid",value:e.data}}get value(){return this._def.value}};Oi.create=(t,e)=>new Oi({value:t,typeName:ue.ZodLiteral,...ge(e)});function vv(t,e){return new $i({values:t,typeName:ue.ZodEnum,...ge(e)})}var $i=class t extends Ee{_parse(e){if(typeof e.data!="string"){let n=this._getOrReturnCtx(e),r=this._def.values;return j(n,{expected:Qe.joinValues(r),received:n.parsedType,code:P.invalid_type}),se}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){let n=this._getOrReturnCtx(e),r=this._def.values;return j(n,{received:n.data,code:P.invalid_enum_value,options:r}),se}return It(e.data)}get options(){return this._def.values}get enum(){let e={};for(let n of this._def.values)e[n]=n;return e}get Values(){let e={};for(let n of this._def.values)e[n]=n;return e}get Enum(){let e={};for(let n of this._def.values)e[n]=n;return e}extract(e,n=this._def){return t.create(e,{...this._def,...n})}exclude(e,n=this._def){return t.create(this.options.filter(r=>!e.includes(r)),{...this._def,...n})}};$i.create=vv;var Vi=class extends Ee{_parse(e){let n=Qe.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==W.string&&r.parsedType!==W.number){let s=Qe.objectValues(n);return j(r,{expected:Qe.joinValues(s),received:r.parsedType,code:P.invalid_type}),se}if(this._cache||(this._cache=new Set(Qe.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){let s=Qe.objectValues(n);return j(r,{received:r.data,code:P.invalid_enum_value,options:s}),se}return It(e.data)}get enum(){return this._def.values}};Vi.create=(t,e)=>new Vi({values:t,typeName:ue.ZodNativeEnum,...ge(e)});var Ns=class extends Ee{unwrap(){return this._def.type}_parse(e){let{ctx:n}=this._processInputParams(e);if(n.parsedType!==W.promise&&n.common.async===!1)return j(n,{code:P.invalid_type,expected:W.promise,received:n.parsedType}),se;let r=n.parsedType===W.promise?n.data:Promise.resolve(n.data);return It(r.then(s=>this._def.type.parseAsync(s,{path:n.path,errorMap:n.common.contextualErrorMap})))}};Ns.create=(t,e)=>new Ns({type:t,typeName:ue.ZodPromise,...ge(e)});var wn=class extends Ee{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===ue.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:n,ctx:r}=this._processInputParams(e),s=this._def.effect||null,i={addIssue:a=>{j(r,a),a.fatal?n.abort():n.dirty()},get path(){return r.path}};if(i.addIssue=i.addIssue.bind(i),s.type==="preprocess"){let a=s.transform(r.data,i);if(r.common.async)return Promise.resolve(a).then(async c=>{if(n.value==="aborted")return se;let A=await this._def.schema._parseAsync({data:c,path:r.path,parent:r});return A.status==="aborted"?se:A.status==="dirty"?xi(A.value):n.value==="dirty"?xi(A.value):A});{if(n.value==="aborted")return se;let c=this._def.schema._parseSync({data:a,path:r.path,parent:r});return c.status==="aborted"?se:c.status==="dirty"?xi(c.value):n.value==="dirty"?xi(c.value):c}}if(s.type==="refinement"){let a=c=>{let A=s.refinement(c,i);if(r.common.async)return Promise.resolve(A);if(A instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return c};if(r.common.async===!1){let c=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return c.status==="aborted"?se:(c.status==="dirty"&&n.dirty(),a(c.value),{status:n.value,value:c.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(c=>c.status==="aborted"?se:(c.status==="dirty"&&n.dirty(),a(c.value).then(()=>({status:n.value,value:c.value}))))}if(s.type==="transform")if(r.common.async===!1){let a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!xs(a))return se;let c=s.transform(a.value,i);if(c instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:c}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(a=>xs(a)?Promise.resolve(s.transform(a.value,i)).then(c=>({status:n.value,value:c})):se);Qe.assertNever(s)}};wn.create=(t,e,n)=>new wn({schema:t,typeName:ue.ZodEffects,effect:e,...ge(n)});wn.createWithPreprocess=(t,e,n)=>new wn({schema:e,effect:{type:"preprocess",transform:t},typeName:ue.ZodEffects,...ge(n)});var Bn=class extends Ee{_parse(e){return this._getType(e)===W.undefined?It(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};Bn.create=(t,e)=>new Bn({innerType:t,typeName:ue.ZodOptional,...ge(e)});var fr=class extends Ee{_parse(e){return this._getType(e)===W.null?It(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};fr.create=(t,e)=>new fr({innerType:t,typeName:ue.ZodNullable,...ge(e)});var Gi=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r=n.data;return n.parsedType===W.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};Gi.create=(t,e)=>new Gi({innerType:t,typeName:ue.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...ge(e)});var Hi=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r={...n,common:{...n.common,issues:[]}},s=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return ma(s)?s.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new Yt(r.common.issues)},input:r.data})})):{status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new Yt(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}};Hi.create=(t,e)=>new Hi({innerType:t,typeName:ue.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...ge(e)});var Qa=class extends Ee{_parse(e){if(this._getType(e)!==W.nan){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.nan,received:r.parsedType}),se}return{status:"valid",value:e.data}}};Qa.create=t=>new Qa({typeName:ue.ZodNaN,...ge(t)});var RH=Symbol("zod_brand"),cu=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}},uu=class t extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let i=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return i.status==="aborted"?se:i.status==="dirty"?(n.dirty(),xi(i.value)):this._def.out._parseAsync({data:i.value,path:r.path,parent:r})})();{let s=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return s.status==="aborted"?se:s.status==="dirty"?(n.dirty(),{status:"dirty",value:s.value}):this._def.out._parseSync({data:s.value,path:r.path,parent:r})}}static create(e,n){return new t({in:e,out:n,typeName:ue.ZodPipeline})}},Yi=class extends Ee{_parse(e){let n=this._def.innerType._parse(e),r=s=>(xs(s)&&(s.value=Object.freeze(s.value)),s);return ma(n)?n.then(s=>r(s)):r(n)}unwrap(){return this._def.innerType}};Yi.create=(t,e)=>new Yi({innerType:t,typeName:ue.ZodReadonly,...ge(e)});function wv(t,e){let n=typeof t=="function"?t(e):typeof t=="string"?{message:t}:t;return typeof n=="string"?{message:n}:n}function Rv(t,e={},n){return t?Ds.create().superRefine((r,s)=>{let i=t(r);if(i instanceof Promise)return i.then(a=>{if(!a){let c=wv(e,r),A=c.fatal??n??!0;s.addIssue({code:"custom",...c,fatal:A})}});if(!i){let a=wv(e,r),c=a.fatal??n??!0;s.addIssue({code:"custom",...a,fatal:c})}}):Ds.create()}var xH={object:qt.lazycreate},ue;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(ue||(ue={}));var TH=(t,e={message:`Input not instance of ${t.name}`})=>Rv(n=>n instanceof t,e),xv=Ts.create,Tv=Ti.create,DH=Qa.create,NH=Di.create,Dv=Ni.create,FH=Fi.create,MH=Ea.create,_H=Mi.create,UH=_i.create,LH=Ds.create,PH=qr.create,OH=jn.create,$H=Ca.create,VH=jr.create,GH=qt.create,HH=qt.strictCreate,YH=Ui.create,qH=nd.create,jH=Li.create,JH=hr.create,WH=rd.create,zH=Ia.create,KH=Ba.create,ZH=sd.create,XH=Pi.create,eY=Oi.create,tY=$i.create,nY=Vi.create,rY=Ns.create,sY=wn.create,iY=Bn.create,oY=fr.create,aY=wn.createWithPreprocess,cY=uu.create,uY=()=>xv().optional(),AY=()=>Tv().optional(),lY=()=>Dv().optional(),dY={string:(t=>Ts.create({...t,coerce:!0})),number:(t=>Ti.create({...t,coerce:!0})),boolean:(t=>Ni.create({...t,coerce:!0})),bigint:(t=>Di.create({...t,coerce:!0})),date:(t=>Fi.create({...t,coerce:!0}))};var pY=se;var wa=["playwright","pytest","robot","junit","vitest","jest","mocha","go","rspec","jasmine"];var Nv="skyramp_session_storage.json";var sm;(function(t){t.PYTHON="python",t.TYPESCRIPT="typescript",t.JAVASCRIPT="javascript",t.JAVA="java"})(sm||(sm={}));var gr;(function(t){t.SMOKE="smoke",t.FUZZ="fuzz",t.CONTRACT="contract",t.LOAD="load",t.INTEGRATION="integration",t.E2E="e2e",t.UI="ui",t.UNIT="unit",t.UNKNOWN="unknown"})(gr||(gr={}));var nZ=[gr.CONTRACT,gr.INTEGRATION,gr.E2E,gr.UI];var Fv;(function(t){t.Rest="rest",t.Grpc="grpc",t.Kafka="kafka"})(Fv||(Fv={}));var id;(function(t){t.GET="GET",t.POST="POST",t.PUT="PUT",t.DELETE="DELETE",t.PATCH="PATCH",t.HEAD="HEAD",t.OPTIONS="OPTIONS"})(id||(id={}));var Au;(function(t){t.LOCAL="local",t.DOCKER="docker",t.KUBERNETES="k8s"})(Au||(Au={}));var hY=U.nativeEnum(Au),im=U.preprocess(t=>t==="kubernetes"?Au.KUBERNETES:t,hY);var fY=U.object({language:U.nativeEnum(sm).describe("Programming language for the generated test (default: python). Must be one of: python, typescript, javascript, java"),framework:U.string().describe(`Testing framework to use. Supported: ${wa.join(", ")} (e.g. pytest for python, playwright/vitest/jest for js/ts, junit for java).`)}),Mv=U.object({...fY.shape,deployDashboard:U.boolean().default(!1).describe("Whether to deploy the Skyramp dashboard for test monitoring"),runtime:im.default(Au.LOCAL).describe("Runtime environment (local, docker, or k8s; accepts kubernetes as an alias)"),dockerNetwork:U.string().default("").describe("Docker network name to use for containerized testing"),dockerWorkerPort:U.number().int().min(0).max(65535).default(0).describe("Port number for the Docker worker service"),k8sNamespace:U.string().default("").describe("Kubernetes namespace for deployment"),k8sConfig:U.string().default("").describe("Path to Kubernetes configuration file"),k8sContext:U.string().default("").describe("Kubernetes context to use"),authHeader:U.string().default("").describe("Name of the HTTP header that carries the auth credential. Common values: 'Authorization' (Bearer/Basic/Token auth), 'X-Api-Key', 'X-Auth-Token', 'Cookie'. Other accepted values: 'X-Access-Token', 'X-OAuth-Token', 'X-Client-ID', 'X-Client-Secret', 'X-Client-Token', 'X-GitHub-Token', 'X-Firebase-AppCheck', 'Proxy-Authorization', 'Fastly-Key', 'Heroku-Bearer'. Pass empty string to document an unauthenticated endpoint in the generated test's assertions. This is the header KEY name (e.g., 'X-Api-Key'), NOT the token value."),authScheme:U.string().default("").describe("Only for Authorization headers. The literal prefix before the token (e.g., 'Bearer' produces 'Authorization: Bearer <token>'). Common values: 'Bearer', 'Basic', 'Token'. If the API sends raw tokens with no prefix (e.g., 'Authorization: eyJ...'), leave empty or omit. Ignored when authHeader is not 'Authorization'."),insecure:U.boolean().default(!1).describe("Whether to allow insecure SSL connections for HTTPS endpoints"),output:U.string().optional().refine(t=>!t||t===""?!0:[".py",".ts",".js",".java"].some(n=>t.endsWith(n)),{message:"Output file must have one of these extensions: .py, .ts, .js, .java"}).describe("Name of the output test file. For Playwright, name the file the way the repository names its tests: read the test files already in outputDir and match their spelling. Use *.test.ts where they use it, *.spec.ts otherwise (e.g. contract_math_add.spec.ts, fuzz_orders.test.ts). For other frameworks (pytest, junit), standard extensions are fine (.py, .java). Optional \u2014 when omitted, Skyramp generates a default name."),outputDir:U.string().describe("MUST be absolute path to the directory where test files will be generated. If not provided, the CURRENT WORKING DIRECTORY will be used WITHOUT ANY SUBDIRECTORIES"),force:U.boolean().default(!0).describe("Whether to overwrite existing files in the output directory"),mockPort:U.number().int().min(0).max(65535).default(0).describe("Port number for the mock server"),optionalFields:U.boolean().default(!1).describe("Whether to include optional fields in the generated test/mock"),prompt:U.string().describe("The prompt user provided to generate the test")}),rZ=U.object({playwrightInput:U.string().describe("MUST be absolute path to the playwright input file like /path/to/playwright-ui-test.zip and MUST be a zip file captured using start_trace_collection tool"),playwrightStoragePath:U.string().optional().describe("Path to LOAD existing playwright session storage for trace collection with playwright enabled. THE PATH MUST BE AN ABSOLUTE PATH LIKE /Users/<path>/<filename>.json"),playwrightSaveStoragePath:U.string().optional().describe(`Path to SAVE Playwright session storage after trace collection. Omit this argument to use the default \u2014 \`${Nv}\` resolved against the active outputDir, which produces an absolute path like '/abs/outputDir/${Nv}'. SAVES authentication state (cookies, localStorage, sessionStorage) when the browser closes. To LOAD existing auth state, use playwrightStoragePath instead. Can be a bare filename (joined with outputDir), a relative path, or an absolute path.`),playwrightViewportSize:U.union([U.enum(["","hd","full-hd","2k"]),U.string().regex(/^\d+,\d+$/,"Custom viewport must be 'WIDTH,HEIGHT' format (e.g., '1920,1080')")]).default("").describe("Viewport size for playwright browser. THE VALUE MUST BE IN THE FORMAT ['', 'hd', 'full-hd', '2k', 'x,y' e.g. '1920,1080' for 1920x1080 resolution]. DEFAULT VALUE IS ''. If set to '', the browser will use its default viewport size."),browser:U.enum(["chromium","firefox","webkit"]).default("chromium").describe("Browser to use for Playwright trace collection. Supported browsers: 'chromium' (default), 'firefox', 'webkit'. Choose based on your testing requirements and target browser compatibility."),device:U.string().default("").describe("Device to emulate for Playwright trace collection. Supported devices include: 'iPhone 13', 'iPhone 13 Pro', 'Pixel 5', 'Galaxy S9+', 'iPad Pro', etc. Leave empty for no device emulation (desktop). Use specific device names for mobile/tablet testing.")}),sZ=U.object({trace:U.string().describe("Absolute path to the trace file in JSON format (e.g., /path/to/trace.json). Must use .json extension only. Do not use .jsonl files."),include:U.array(U.string()).default([]).describe("List of endpoints or patterns to include in test generation."),exclude:U.array(U.string()).default([]).describe("List of endpoints or patterns to exclude from test generation."),...Mv.shape}),iZ={endpointURL:U.string().describe("The full endpoint URL to test including base URL and path (e.g., https://demoshop.skyramp.dev/api/v1/products). MUST include both the base URL and the endpoint path \u2014 never just the base URL alone."),method:U.union([U.nativeEnum(id),U.literal("")]).default("").describe('HTTP method to use. DEFAULT: Use empty string ("") to test ALL available methods from OpenAPI schema (recommended). Only specify a specific method (GET, POST, PUT, DELETE, etc.) if user explicitly requests testing a single method only.'),apiSchema:U.string().default("").describe("MUST be absolute path(/path/to/openapi.json) to the OpenAPI/Swagger schema file or a URL to the OpenAPI/Swagger schema file(e.g. https://demoshop.skyramp.dev/openapi.json). DO NOT TRY TO ASSUME THE OPENAPI SCHEMA IF NOT PROVIDED. NOTE TO AI ASSISTANTS: You do not need to read the contents of this file - simply pass the file path as the backend will read and process it."),pathParams:U.string().default("").describe("Comma-separated path parameter values in the form 'key=value,key2=value2' (e.g., 'id=1,name=John'). DO NOT populate this field unless the user has explicitly provided path parameter values. For contract tests, parent path parameters are automatically handled via the parent provisioning mechanism (parentRequestData) \u2014 do NOT invent or guess values for those here. Only supply this field if the user explicitly states specific path parameter values to use."),queryParams:U.string().default("").describe("MUST be string of comma separated values like 'id=1,name=John' for URL query parameters. Workspace-configured api.defaultQueryParams (if set) are merged in automatically, with any api.queryParamOverrides entry whose pathPattern matches this endpoint layered on top \u2014 no need to repeat them here. An explicit value for the same key here overrides both."),formParams:U.string().default("").describe("MUST be string of comma separated values like 'id=1,name=John' for form data parameters"),requestData:U.string().default("").refine(t=>{if(!t||t===""||t.startsWith("@"))return!0;try{return JSON.parse(t),!0}catch{}let e=t.trim();return!!(e.startsWith("---")||/^\w[\w\s]*:/.test(e)||e.startsWith("-"))},{message:"requestData must be valid JSON, YAML, or an absolute file path prefixed with '@'. Received what appears to be plain text. Provide the actual request body as a JSON object."}).describe("Sample request body data, provided either as an inline JSON/YAML string or as an absolute file path prefixed with '@' (e.g., @/absolute/path/to/file). MUST be valid JSON or YAML \u2014 do NOT pass natural language descriptions."),responseStatusCode:U.string().default("").refine(t=>!t||/^[1-5]\d{2}$/.test(t),{message:"Must be a valid HTTP status code in 100-599 (e.g., '200', '404') or empty string"}).describe("Expected HTTP response status code (e.g., '200', '201', '404'). DO NOT ASSUME STATUS CODE IF NOT PROVIDED"),...Mv.shape},oZ=U.object({codeReuse:U.boolean().default(!1).describe("Reuse existing code in the generated test \u2014 consolidates helper functions shared with sibling Skyramp-generated tests into a SkyrampUtils file; for TS/JS Playwright tests with POM reuse enabled it instead refactors the test to use the repo's existing Page Object Model"),modularizeCode:U.boolean().default(!1).describe("Whether to modularize the code")}),aZ=[gr.INTEGRATION,gr.CONTRACT,gr.UI];var od;(function(t){t.Bug="bug",t.Lint="lint",t.Type="type",t.Config="config"})(od||(od={}));var ad;(function(t){t.NotMapped="not-mapped",t.DemotedByVerify="demoted-by-verify"})(ad||(ad={}));var cd;(function(t){t.Passed="passed",t.Failed="failed",t.SkippedNoPom="skipped-no-pom"})(cd||(cd={}));var om;(function(t){t.Passed="passed",t.Failed="failed",t.NoUtilsFile="no-utils-file"})(om||(om={}));Dt();var ud=t=>`${t} POM call${t===1?"":"s"}`,_v={testRecommendationsImplementedHeader:t=>`\u{1F4A1} Test Recommendations Implemented (${t})`,testTypeCellLabels:{},statusLabels:{},severityLabels:{},reuse:{label:"POM reuse",noPomLayer:"skipped \u2014 no page-object layer detected for this test",reusedAndVerified:t=>`${ud(t)} reused and verified`,reusedThenVerified:(t,e)=>`${ud(t)} reused, ${e} of them verified`,reused:t=>`${ud(t)} reused`,verified:t=>`${ud(t)} verified`,unresolved:t=>`${t} not resolvable to POM source (informational, not declines)`,candidates:t=>`${t} candidate POM file${t===1?"":"s"} detected`,verificationPassed:"verification passed",verificationFailed:"\u26A0\uFE0F verification did not pass",keptInline:t=>`kept inline: ${t}`,gate:{"not-mapped":"not mapped","demoted-by-verify":"demoted by verification"}},testMaintenanceHeader:t=>`\u2705 Test Maintenance (${t})`,maintenanceTableHeader:"| Test Type | Endpoint | File | Change | Before | After |",testResultsHeader:t=>`\u{1F9EA} Test Results (${t})`,columnVideo:"Video",videoDownloadLink:t=>`[\u{1F4F9} download](${t})`,videosArtifactFallback:t=>`\u{1F4F9} Recorded UI test videos: [download from run artifacts](${t})`,issuesFoundHeader:t=>`\u26A0\uFE0F Issues Found (${t})`,configErrorsHeader:"\u2699\uFE0F Configuration Errors",nextStepsHeader:"### \u{1F4A1} Next Steps",caveatsHeader:"### \u26A0\uFE0F What this run could not prove",rows:{passed:t=>t?"passed against the running app":"passed",notRun:t=>t?"not run against a live app this run":"not run this run",failedBug:t=>t?"failed against the running app":"failed",executedOf:(t,e)=>e?` and executed ${t} of them against the running app.`:` and executed ${t} of them.`,noneExecuted:t=>t?"; none were executed against a live app this run.":"; none were executed this run."},caveats:{deployFailed:"The app could not be started, so nothing here was checked against a running system.",changeBrokeBringup:"This change appears to have broken the app's start-up: it could not run with the PR applied, so nothing was tested against it.",bringupFailed:"The app could not be started this run, for a reason outside this PR \u2014 nothing was tested against a live app.",testsNotExecuted:"No test was run against a live app this run \u2014 an un-run suite is not evidence the change works.",recipeDrift:"The recorded way to start the app was out of date and had to be corrected before it would come up.",mockedDependency:t=>`${t} was mocked rather than really deployed \u2014 a green run against it is not proof.`,finalizeNotReady:t=>`The tests are not ready to merge as they stand${t?`: ${t}`:"."}`,ciNotCovered:"No CI workflow runs these tests, so they will not execute on future pull requests.",sutNotRequired:"No app was started: validation triage found no deployed behavior this change needs validated.",lintNotCovered:t=>`The repo's linter does not check ${t} \u2014 a style or type issue there would not be caught automatically.`,analysisUnverified:t=>`Part of the change analysis could not be verified (${t} unresolved check${t===1?"":"s"}); the tests were planned treating those claims as unconfirmed.`,unitTestsNotRun:t=>`Testbot could not run the unit tests it selected, so no unit result here is its own re-run: ${t}`,downstreamNotChecked:t=>`Not run: checks of other parts of the app that this change might affect. The change does not alter that behavior itself, so they are not needed to validate it. ${t}`,testsCouldNotRunHere:(t,e)=>`${t} ${t===1?"test exists":"tests exist"} in this change, but this environment could not run ${t===1?"it":"them"}, so ${t===1?"it has":"they have"} no result here (not skipped): ${e}`,modelProviderDenied:(t,e=!1)=>e?`${t}, the model provider, refused a call. The evidence already obtained is sufficient to determine this run\u2019s outcome.`:`${t}, the model provider, refused Testbot's calls, so the run stopped before it finished. Access was denied because of credentials, permissions, or a usage limit. For Skyramp-managed provider access, contact Skyramp support before running again; if you manage the provider account, ask its administrator to resolve access or usage limits. No changes to your code are needed.`,modelProviderUnavailable:(t,e=!1)=>e?`${t}, the model provider, was unavailable for a call. The evidence already obtained is sufficient to determine this run\u2019s outcome.`:`${t}, the model provider, was unavailable to Testbot, so this stage could not finish. Any results already obtained remain in this report. No changes to your code or Testbot setup are needed. Please try again later.`},providerOutageHeadline:(t,e)=>`Testbot could not reach ${t} \u2014 it tried ${e} times without success.`,providerOutageActionStatusPage:t=>`Check ${t}. Once the service is healthy, re-run this workflow from its run page in the Actions tab.`,providerRateLimitHeadline:t=>`Testbot was rate-limited by ${t} (HTTP 429).`,providerRateLimitAction:"Wait for the limit to reset, then re-run this workflow from its run page in the Actions tab. If this repeats, raise the rate limit on the credential this workflow uses or run Testbot on fewer pull requests at once.",providerUsageLimitHeadline:t=>`The account behind ${t} has reached its usage limit.`,providerUsageLimitAction:"Raise the spend or token cap on the account behind this workflow's credential, then re-run this workflow from its run page in the Actions tab.",providerAuthExpiredHeadline:t=>`The credential Testbot uses to reach ${t} expired while the run was still working.`,providerAuthExpiredAction:"The credential is issued with a fixed lifetime, so a longer run can outlive it. Re-run this workflow from its run page in the Actions tab. If runs on this repository regularly last longer than that lifetime, issue the credential per job or split the run so each job stays inside it.",providerTimeoutHeadline:t=>`Testbot ran past its ${t}-minute time limit and was stopped.`,providerTimeoutAction:"Raise the `testbotTimeout` input on the workflow if runs on this repository legitimately need longer.",staged:{testsSourcePullRequest:t=>`Tests for source pull request ${t}`,requestedByPerson:t=>`Requested by ${t}`,requestedByPolicy:t=>`Started by the Validation Policy ${t}`,noLiveApp:t=>`> \u26A0\uFE0F **No live app (SUT) was available this run** \u2014 the ${t} test(s) below were **not executed** (there was no app to run them against). Run them against a running app to confirm they pass (and that any repro test fails as intended).`,unitTestsInFile:(t,e,n)=>`**${t}**: ${e} unit test${e===1?"":"s"}${n?` for ${n}`:""}`,addedToExistingFile:"added to an existing test file",testPackagesHeader:"### \u{1F4E6} Running these tests",testPackageLine:(t,e)=>`\`${t}/\` is a self-contained test package Skyramp Testbot owns and maintains, with its own manifest, lockfile and runner config. Run it with \`${e}\`; to run it on every pull request, add that one command to CI.`,appManifestsUntouched:"The application's own manifests and lockfiles were not changed.",dependencyChangesHeader:"### \u{1F4E6} Changes to the application's dependencies",dependencyChangeLine:(t,e,n)=>`Added \`${t}\` to \`${e}\` (and its lockfile)${n?`: ${n}`:""}`,testMaintenanceHeader:"\u2705 Test Maintenance",keptNot:"kept, not ",declinedPlanned:"(declined the planned ",declinedMaintenanceHeader:"\u21A9\uFE0F Declined Maintenance",existingEvidenceHeader:"\u2705 Existing Evidence",trustedCheckPassed:(t,e)=>`Trusted CI check ${t} passed${e?` on ${e}`:""}, establishing:`,testResultsHeader:"\u{1F9EA} Test Results",resultsTableHeader:"| Test ID | Test Type | Endpoint | Status | Details |",unitResultsTableHeader:"| Test ID | Test Type | Code under test | Test | Cases | Status | Details |",casesPassed:(t,e,n)=>`${t}/${e} passed${n?`, ${n} skipped`:""}`,behaviourCoverageHeader:"\u{1F517} Behaviour Coverage",coverageCaption:(t,e,n,r)=>` (${t} generated \xB7 ${e} modified \xB7 ${n} verified \xB7 ${r} executed)`,coverageTableHeader:"| Behaviour | Source | Tested By | Maintained By |",writtenNotRun:"written, not run",issuesFoundHeader:"\u26A0\uFE0F Issues Found",caveatsHeader:"### \u26A0\uFE0F What This Run Could Not Prove",commentHeader:"### Skyramp Testbot",timedOut:"> \u26A0\uFE0F Run timed out \u2014 the results below are partial.",stopReasons:{},publishFailures:{},maintenanceActions:{},stoppedEarly:(t,e)=>`> \u26A0\uFE0F Run stopped early \u2014 ${t}. The results below are partial.${e}`,viewInSkyramp:t=>` [View in Skyramp](${t})`,descriptionCut:(t,e,n)=>`_\u2026 The rest is left out${e===void 0?", with more test results":e?`, with ${e} more test result${e===1?"":"s"}`:""}: Azure DevOps takes at most ${t} characters.${n?` [Full report](${n})`:""}_`,setupRunEnds:{finished:"Setup run finished. Skyramp is checking the result.",failed:"Setup run failed.",timedOut:"Setup run ran out of time.",cancelledInSkyramp:"Setup run was cancelled in Skyramp.",stoppedToResume:"Setup run stopped. Resume it in Skyramp."},appUnreachable:t=>`Unable to contact the mothership ${t}. Please try again later.`,couldNotStart:t=>`Skyramp Testbot could not start: ${t}`,assembledAfterFailedChecks:t=>`> \u26A0\uFE0F This report was assembled automatically after the write-up step failed its checks; ${t} check(s) remain unmet \u2014 see the run log for details.`,testbotPrLine:(t,e,n)=>`Testbot PR${t?` (${t})`:""} : [${e}](${n})`,viewRun:t=>`_[View run](${t})_`,testsPrNotOpened:(t,e)=>`The tests PR could not be opened (${t}); the tests were pushed to branch \`${e}\`.`,testsNotDelivered:t=>`The tests could not be delivered: ${t}`,testsNotPushed:(t,e)=>`The tests could not be pushed (${t}); they remain on the local branch \`${e}\`.`,testsPrRetargeted:t=>`The dev PR merged while tests were being generated \u2014 the tests PR targets its base branch${t?` (\`${t}\`)`:""} instead.`,testsPrUnchanged:"This push required no new test changes; the tests PR below is from an earlier run and was left as is.",committedNoPr:t=>`The tests were committed but no PR was opened: ${t}.`,testsNotProposed:t=>`The tests were not proposed in a pull request: ${t}.`}};var Uv={testRecommendationsImplementedHeader:t=>`\u{1F4A1} \u5B9F\u88C5\u3057\u305F\u30C6\u30B9\u30C8\u63A8\u5968\uFF08${t}\u4EF6\uFF09`,testTypeCellLabels:{smoke:"\u30B9\u30E2\u30FC\u30AF",fuzz:"\u30D5\u30A1\u30BA",contract:"\u30B3\u30F3\u30C8\u30E9\u30AF\u30C8",load:"\u8CA0\u8377",integration:"\u7D71\u5408",e2e:"E2E",ui:"UI",unit:"\u30E6\u30CB\u30C3\u30C8"},statusLabels:{Pass:"\u5408\u683C",Fail:"\u4E0D\u5408\u683C",Error:"\u30A8\u30E9\u30FC",Skipped:"\u30B9\u30AD\u30C3\u30D7"},severityLabels:{critical:"\u91CD\u5927",high:"\u9AD8",medium:"\u4E2D",low:"\u4F4E"},reuse:{label:"POM \u518D\u5229\u7528",noPomLayer:"\u30B9\u30AD\u30C3\u30D7 \u2014 \u3053\u306E\u30C6\u30B9\u30C8\u306B\u518D\u5229\u7528\u3067\u304D\u308B\u30DA\u30FC\u30B8\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\u5C64\u306F\u691C\u51FA\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F",reusedAndVerified:t=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u518D\u5229\u7528\u30FB\u691C\u8A3C\u6E08\u307F`,reusedThenVerified:(t,e)=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u518D\u5229\u7528\uFF08\u3046\u3061 ${e} \u4EF6\u3092\u691C\u8A3C\u6E08\u307F\uFF09`,reused:t=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u518D\u5229\u7528`,verified:t=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u691C\u8A3C\u6E08\u307F`,unresolved:t=>`${t} \u4EF6\u306F POM \u30BD\u30FC\u30B9\u307E\u3067\u89E3\u6C7A\u3067\u304D\u305A\uFF08\u53C2\u8003\u60C5\u5831\u3067\u3042\u308A\u3001\u9664\u5916\u3067\u306F\u3042\u308A\u307E\u305B\u3093\uFF09`,candidates:t=>`\u5019\u88DC\u3068\u306A\u308B POM \u30D5\u30A1\u30A4\u30EB ${t} \u4EF6\u3092\u691C\u51FA`,verificationPassed:"\u691C\u8A3C\u306B\u5408\u683C",verificationFailed:"\u26A0\uFE0F \u691C\u8A3C\u306B\u5408\u683C\u3057\u307E\u305B\u3093\u3067\u3057\u305F",keptInline:t=>`\u30A4\u30F3\u30E9\u30A4\u30F3\u306E\u307E\u307E: ${t}`,gate:{"not-mapped":"\u30DE\u30C3\u30D4\u30F3\u30B0\u5BFE\u8C61\u5916","demoted-by-verify":"\u691C\u8A3C\u3067\u5DEE\u3057\u623B\u3057"}},testMaintenanceHeader:t=>`\u2705 \u30C6\u30B9\u30C8\u30E1\u30F3\u30C6\u30CA\u30F3\u30B9\uFF08${t}\u4EF6\uFF09`,maintenanceTableHeader:"| \u30C6\u30B9\u30C8\u7A2E\u5225 | \u30A8\u30F3\u30C9\u30DD\u30A4\u30F3\u30C8 | \u30D5\u30A1\u30A4\u30EB | \u5909\u66F4\u5185\u5BB9 | \u5909\u66F4\u524D | \u5909\u66F4\u5F8C |",testResultsHeader:t=>`\u{1F9EA} \u30C6\u30B9\u30C8\u7D50\u679C\uFF08${t}\u4EF6\uFF09`,columnVideo:"\u30D3\u30C7\u30AA",videoDownloadLink:t=>`[\u{1F4F9} \u30C0\u30A6\u30F3\u30ED\u30FC\u30C9](${t})`,videosArtifactFallback:t=>`\u{1F4F9} \u9332\u753B\u3055\u308C\u305F UI \u30C6\u30B9\u30C8\u30D3\u30C7\u30AA: [\u5B9F\u884C\u30A2\u30FC\u30C6\u30A3\u30D5\u30A1\u30AF\u30C8\u304B\u3089\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9](${t})`,issuesFoundHeader:t=>`\u26A0\uFE0F \u691C\u51FA\u3055\u308C\u305F\u554F\u984C\uFF08${t}\u4EF6\uFF09`,configErrorsHeader:"\u2699\uFE0F \u8A2D\u5B9A\u30A8\u30E9\u30FC",nextStepsHeader:"### \u{1F4A1} \u6B21\u306E\u30B9\u30C6\u30C3\u30D7",caveatsHeader:"### \u26A0\uFE0F \u3053\u306E\u5B9F\u884C\u3067\u78BA\u8A8D\u3067\u304D\u306A\u304B\u3063\u305F\u3053\u3068",rows:{passed:t=>t?"\u8D77\u52D5\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u6210\u529F\u3057\u307E\u3057\u305F":"\u6210\u529F\u3057\u307E\u3057\u305F",notRun:t=>t?"\u3053\u306E\u5B9F\u884C\u3067\u306F\u30E9\u30A4\u30D6\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F":"\u3053\u306E\u5B9F\u884C\u3067\u306F\u5B9F\u884C\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F",failedBug:t=>t?"\u8D77\u52D5\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5931\u6557\u3057\u307E\u3057\u305F":"\u5931\u6557\u3057\u307E\u3057\u305F",executedOf:(t,e)=>e?`\u3001\u305D\u306E\u3046\u3061 ${t} \u4EF6\u3092\u8D77\u52D5\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3057\u307E\u3057\u305F\u3002`:`\u3001\u305D\u306E\u3046\u3061 ${t} \u4EF6\u3092\u5B9F\u884C\u3057\u307E\u3057\u305F\u3002`,noneExecuted:t=>t?"\u3002\u3053\u306E\u5B9F\u884C\u3067\u306F\u30E9\u30A4\u30D6\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3055\u308C\u305F\u3082\u306E\u306F\u3042\u308A\u307E\u305B\u3093\u3002":"\u3002\u3053\u306E\u5B9F\u884C\u3067\u306F\u5B9F\u884C\u3055\u308C\u305F\u3082\u306E\u306F\u3042\u308A\u307E\u305B\u3093\u3002"},caveats:{deployFailed:"\u30A2\u30D7\u30EA\u3092\u8D77\u52D5\u3067\u304D\u306A\u304B\u3063\u305F\u305F\u3081\u3001\u3053\u3053\u306B\u793A\u3059\u5185\u5BB9\u306F\u7A3C\u50CD\u4E2D\u306E\u30B7\u30B9\u30C6\u30E0\u306B\u5BFE\u3057\u3066\u691C\u8A3C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002",changeBrokeBringup:"\u3053\u306E\u5909\u66F4\u306B\u3088\u308A\u30A2\u30D7\u30EA\u306E\u8D77\u52D5\u304C\u58CA\u308C\u305F\u3068\u601D\u308F\u308C\u307E\u3059\u3002PR \u3092\u9069\u7528\u3057\u305F\u72B6\u614B\u3067\u8D77\u52D5\u3067\u304D\u305A\u3001\u30C6\u30B9\u30C8\u306F\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002",bringupFailed:"\u3053\u306E PR \u3068\u306F\u7121\u95A2\u4FC2\u306E\u7406\u7531\u3067\u30A2\u30D7\u30EA\u3092\u8D77\u52D5\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3059\u308B\u30C6\u30B9\u30C8\u306F\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002",testsNotExecuted:"\u3053\u306E\u5B9F\u884C\u3067\u306F\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u30C6\u30B9\u30C8\u304C\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002\u672A\u5B9F\u884C\u306E\u30C6\u30B9\u30C8\u306F\u5909\u66F4\u304C\u6B63\u3057\u304F\u52D5\u4F5C\u3059\u308B\u8A3C\u62E0\u306B\u306A\u308A\u307E\u305B\u3093\u3002",recipeDrift:"\u8A18\u9332\u3055\u308C\u3066\u3044\u305F\u30A2\u30D7\u30EA\u306E\u8D77\u52D5\u624B\u9806\u304C\u53E4\u304F\u306A\u3063\u3066\u304A\u308A\u3001\u8D77\u52D5\u524D\u306B\u4FEE\u6B63\u304C\u5FC5\u8981\u3067\u3057\u305F\u3002",mockedDependency:t=>`${t} \u306F\u5B9F\u969B\u306B\u30C7\u30D7\u30ED\u30A4\u3055\u308C\u305A\u30E2\u30C3\u30AF\u5316\u3055\u308C\u307E\u3057\u305F\u3002\u3053\u308C\u306B\u5BFE\u3059\u308B\u6210\u529F\u7D50\u679C\u306F\u8A3C\u660E\u306B\u306F\u306A\u308A\u307E\u305B\u3093\u3002`,finalizeNotReady:t=>`\u30C6\u30B9\u30C8\u306F\u73FE\u72B6\u3067\u306F\u30DE\u30FC\u30B8\u53EF\u80FD\u306A\u72B6\u614B\u3067\u306F\u3042\u308A\u307E\u305B\u3093${t?`: ${t}`:"\u3002"}`,ciNotCovered:"\u3053\u308C\u3089\u306E\u30C6\u30B9\u30C8\u3092\u5B9F\u884C\u3059\u308B CI \u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u304C\u306A\u3044\u305F\u3081\u3001\u4ECA\u5F8C\u306E\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u3067\u306F\u5B9F\u884C\u3055\u308C\u307E\u305B\u3093\u3002",sutNotRequired:"\u30A2\u30D7\u30EA\u306F\u8D77\u52D5\u3057\u3066\u3044\u307E\u305B\u3093\u3002\u691C\u8A3C\u30C8\u30EA\u30A2\u30FC\u30B8\u306B\u3088\u308A\u3001\u3053\u306E\u5909\u66F4\u3067\u691C\u8A3C\u304C\u5FC5\u8981\u306A\u30C7\u30D7\u30ED\u30A4\u5F8C\u306E\u632F\u308B\u821E\u3044\u306F\u306A\u3044\u3068\u5224\u65AD\u3055\u308C\u307E\u3057\u305F\u3002",lintNotCovered:t=>`\u30EA\u30DD\u30B8\u30C8\u30EA\u306E\u30EA\u30F3\u30BF\u30FC\u306F ${t} \u3092\u30C1\u30A7\u30C3\u30AF\u3057\u307E\u305B\u3093\u3002\u30B9\u30BF\u30A4\u30EB\u3084\u578B\u306E\u554F\u984C\u304C\u81EA\u52D5\u7684\u306B\u306F\u691C\u51FA\u3055\u308C\u307E\u305B\u3093\u3002`,analysisUnverified:t=>`\u5909\u66F4\u306E\u5206\u6790\u306E\u4E00\u90E8\u3092\u691C\u8A3C\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\uFF08\u672A\u89E3\u6C7A\u306E\u30C1\u30A7\u30C3\u30AF ${t} \u4EF6\uFF09\u3002\u8A72\u5F53\u3059\u308B\u4E3B\u5F35\u306F\u672A\u78BA\u8A8D\u3068\u3057\u3066\u6271\u3044\u3001\u30C6\u30B9\u30C8\u3092\u8A08\u753B\u3057\u307E\u3057\u305F\u3002`,unitTestsNotRun:t=>`Testbot \u306F\u9078\u629E\u3057\u305F\u30E6\u30CB\u30C3\u30C8\u30C6\u30B9\u30C8\u3092\u5B9F\u884C\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u3053\u3053\u306B\u3042\u308B\u30E6\u30CB\u30C3\u30C8\u30C6\u30B9\u30C8\u306E\u7D50\u679C\u306F Testbot \u81EA\u8EAB\u306E\u518D\u5B9F\u884C\u306B\u3088\u308B\u3082\u306E\u3067\u306F\u3042\u308A\u307E\u305B\u3093: ${t}`,downstreamNotChecked:t=>`\u672A\u5B9F\u884C: \u3053\u306E\u5909\u66F4\u304C\u5F71\u97FF\u3057\u3046\u308B\u3001\u30A2\u30D7\u30EA\u306E\u4ED6\u306E\u90E8\u5206\u306E\u78BA\u8A8D\u3067\u3059\u3002\u3053\u306E\u5909\u66F4\u81EA\u4F53\u306F\u305D\u306E\u52D5\u4F5C\u3092\u5909\u3048\u306A\u3044\u305F\u3081\u3001\u5909\u66F4\u306E\u691C\u8A3C\u306B\u306F\u4E0D\u8981\u3067\u3059\u3002${t}`,testsCouldNotRunHere:(t,e)=>`\u3053\u306E\u5909\u66F4\u306B\u306F ${t} \u4EF6\u306E\u30C6\u30B9\u30C8\u304C\u3042\u308A\u307E\u3059\u304C\u3001\u3053\u306E\u74B0\u5883\u3067\u306F\u5B9F\u884C\u3067\u304D\u306A\u304B\u3063\u305F\u305F\u3081\u7D50\u679C\u304C\u3042\u308A\u307E\u305B\u3093\uFF08\u30B9\u30AD\u30C3\u30D7\u3067\u306F\u3042\u308A\u307E\u305B\u3093\uFF09: ${e}`,modelProviderDenied:(t,e=!1)=>e?`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u304C\u547C\u3073\u51FA\u3057\u3092\u62D2\u5426\u3057\u307E\u3057\u305F\u3002\u3059\u3067\u306B\u5F97\u3089\u308C\u305F\u8A3C\u62E0\u306F\u3001\u3053\u306E\u5B9F\u884C\u306E\u7D50\u679C\u3092\u5224\u65AD\u3059\u308B\u306E\u306B\u5341\u5206\u3067\u3059\u3002`:`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u304C Testbot \u306E\u547C\u3073\u51FA\u3057\u3092\u62D2\u5426\u3057\u305F\u305F\u3081\u3001\u5B9F\u884C\u306F\u5B8C\u4E86\u524D\u306B\u505C\u6B62\u3057\u307E\u3057\u305F\u3002\u8A8D\u8A3C\u60C5\u5831\u3001\u6A29\u9650\u3001\u307E\u305F\u306F\u4F7F\u7528\u91CF\u306E\u4E0A\u9650\u306B\u3088\u308A\u30A2\u30AF\u30BB\u30B9\u304C\u62D2\u5426\u3055\u308C\u307E\u3057\u305F\u3002\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3078\u306E\u30A2\u30AF\u30BB\u30B9\u3092 Skyramp \u304C\u7BA1\u7406\u3057\u3066\u3044\u308B\u5834\u5408\u306F\u3001\u518D\u5B9F\u884C\u3059\u308B\u524D\u306B Skyramp \u30B5\u30DD\u30FC\u30C8\u306B\u304A\u554F\u3044\u5408\u308F\u305B\u304F\u3060\u3055\u3044\u3002\u3054\u81EA\u8EAB\u3067\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u7BA1\u7406\u3057\u3066\u3044\u308B\u5834\u5408\u306F\u3001\u305D\u306E\u7BA1\u7406\u8005\u306B\u30A2\u30AF\u30BB\u30B9\u307E\u305F\u306F\u4F7F\u7528\u91CF\u306E\u4E0A\u9650\u306E\u89E3\u6C7A\u3092\u4F9D\u983C\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u30B3\u30FC\u30C9\u3092\u5909\u66F4\u3059\u308B\u5FC5\u8981\u306F\u3042\u308A\u307E\u305B\u3093\u3002`,modelProviderUnavailable:(t,e=!1)=>e?`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u3092\u547C\u3073\u51FA\u3057\u6642\u306B\u5229\u7528\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u3059\u3067\u306B\u5F97\u3089\u308C\u305F\u8A3C\u62E0\u306F\u3001\u3053\u306E\u5B9F\u884C\u306E\u7D50\u679C\u3092\u5224\u65AD\u3059\u308B\u306E\u306B\u5341\u5206\u3067\u3059\u3002`:`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u3092 Testbot \u304C\u5229\u7528\u3067\u304D\u306A\u304B\u3063\u305F\u305F\u3081\u3001\u3053\u306E\u6BB5\u968E\u3092\u5B8C\u4E86\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u3059\u3067\u306B\u5F97\u3089\u308C\u305F\u7D50\u679C\u306F\u3053\u306E\u30EC\u30DD\u30FC\u30C8\u306B\u6B8B\u3063\u3066\u3044\u307E\u3059\u3002\u30B3\u30FC\u30C9\u3084 Testbot \u306E\u8A2D\u5B9A\u3092\u5909\u66F4\u3059\u308B\u5FC5\u8981\u306F\u3042\u308A\u307E\u305B\u3093\u3002\u3057\u3070\u3089\u304F\u3057\u3066\u304B\u3089\u518D\u5EA6\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002`},providerOutageHeadline:(t,e)=>`${t} \u306B\u63A5\u7D9A\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002Testbot \u306F ${e} \u56DE\u8A66\u884C\u3057\u307E\u3057\u305F\u304C\u5931\u6557\u3057\u307E\u3057\u305F\u3002`,providerOutageActionStatusPage:t=>`${t} \u3067\u72B6\u6CC1\u3092\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u30B5\u30FC\u30D3\u30B9\u304C\u5FA9\u65E7\u3057\u305F\u3089\u3001Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,providerRateLimitHeadline:t=>`${t} \u306E\u30EC\u30FC\u30C8\u5236\u9650\u306B\u3088\u308A\u5B9F\u884C\u304C\u4E2D\u65AD\u3055\u308C\u307E\u3057\u305F (HTTP 429)\u3002`,providerRateLimitAction:"\u5236\u9650\u304C\u89E3\u9664\u3055\u308C\u308B\u307E\u3067\u5F85\u3063\u3066\u304B\u3089\u3001Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u7E70\u308A\u8FD4\u3059\u5834\u5408\u306F\u3001\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u304C\u4F7F\u7528\u3059\u308B\u8A8D\u8A3C\u60C5\u5831\u306E\u30EC\u30FC\u30C8\u5236\u9650\u3092\u5F15\u304D\u4E0A\u3052\u308B\u304B\u3001\u540C\u6642\u306B\u5B9F\u884C\u3059\u308B PR \u306E\u6570\u3092\u6E1B\u3089\u3057\u3066\u304F\u3060\u3055\u3044\u3002",providerUsageLimitHeadline:t=>`${t} \u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u304C\u5229\u7528\u4E0A\u9650\u306B\u9054\u3057\u307E\u3057\u305F\u3002`,providerUsageLimitAction:"\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u306E\u8A8D\u8A3C\u60C5\u5831\u306B\u7D10\u3065\u304F\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u5229\u7528\u4E0A\u9650\u3092\u5F15\u304D\u4E0A\u3052\u3066\u304B\u3089\u3001Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002",providerAuthExpiredHeadline:t=>`\u5B9F\u884C\u4E2D\u306B\u3001Testbot \u304C ${t} \u3078\u63A5\u7D9A\u3059\u308B\u305F\u3081\u306E\u8A8D\u8A3C\u60C5\u5831\u306E\u6709\u52B9\u671F\u9650\u304C\u5207\u308C\u307E\u3057\u305F\u3002`,providerAuthExpiredAction:"\u8A8D\u8A3C\u60C5\u5831\u306E\u6709\u52B9\u671F\u9593\u306F\u56FA\u5B9A\u306E\u305F\u3081\u3001\u5B9F\u884C\u6642\u9593\u304C\u9577\u3044\u3068\u305D\u306E\u671F\u9593\u3092\u8D85\u3048\u308B\u3053\u3068\u304C\u3042\u308A\u307E\u3059\u3002Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u3053\u306E\u30EA\u30DD\u30B8\u30C8\u30EA\u306E\u5B9F\u884C\u304C\u6709\u52B9\u671F\u9593\u3092\u5E38\u306B\u8D85\u3048\u308B\u5834\u5408\u306F\u3001\u30B8\u30E7\u30D6\u3054\u3068\u306B\u8A8D\u8A3C\u60C5\u5831\u3092\u767A\u884C\u3059\u308B\u304B\u3001\u5404\u30B8\u30E7\u30D6\u304C\u6709\u52B9\u671F\u9593\u5185\u306B\u53CE\u307E\u308B\u3088\u3046\u5B9F\u884C\u3092\u5206\u5272\u3057\u3066\u304F\u3060\u3055\u3044\u3002",providerTimeoutHeadline:t=>`Testbot \u306F\u5236\u9650\u6642\u9593 ${t} \u5206\u3092\u8D85\u3048\u305F\u305F\u3081\u505C\u6B62\u3055\u308C\u307E\u3057\u305F\u3002`,providerTimeoutAction:"\u3053\u306E\u30EA\u30DD\u30B8\u30C8\u30EA\u306E\u5B9F\u884C\u306B\u672C\u5F53\u306B\u6642\u9593\u304C\u5FC5\u8981\u306A\u5834\u5408\u306F\u3001\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u306E `testbotTimeout` \u5165\u529B\u5024\u3092\u5927\u304D\u304F\u3057\u3066\u304F\u3060\u3055\u3044\u3002",staged:{testsSourcePullRequest:t=>`\u30BD\u30FC\u30B9\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8 ${t} \u306E\u30C6\u30B9\u30C8`,requestedByPerson:t=>`${t} \u3055\u3093\u306E\u4F9D\u983C\u3067\u5B9F\u884C`,requestedByPolicy:t=>`\u691C\u8A3C\u30DD\u30EA\u30B7\u30FC ${t} \u306B\u3088\u308A\u5B9F\u884C`,noLiveApp:t=>`> \u26A0\uFE0F **\u3053\u306E\u5B9F\u884C\u3067\u306F\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\uFF08SUT\uFF09\u304C\u3042\u308A\u307E\u305B\u3093\u3067\u3057\u305F** \u2014 \u4EE5\u4E0B\u306E ${t} \u4EF6\u306E\u30C6\u30B9\u30C8\u306F**\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093**\uFF08\u5B9F\u884C\u5BFE\u8C61\u306E\u30A2\u30D7\u30EA\u304C\u3042\u308A\u307E\u305B\u3093\u3067\u3057\u305F\uFF09\u3002\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3057\u3001\u5408\u683C\u3059\u308B\u3053\u3068\uFF08\u304A\u3088\u3073\u518D\u73FE\u30C6\u30B9\u30C8\u304C\u610F\u56F3\u3069\u304A\u308A\u5931\u6557\u3059\u308B\u3053\u3068\uFF09\u3092\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,unitTestsInFile:(t,e,n)=>`**${t}**: ${n?`${n} \u306E`:""}\u30E6\u30CB\u30C3\u30C8\u30C6\u30B9\u30C8 ${e} \u4EF6`,addedToExistingFile:"\u65E2\u5B58\u306E\u30C6\u30B9\u30C8\u30D5\u30A1\u30A4\u30EB\u306B\u8FFD\u52A0",testPackagesHeader:"### \u{1F4E6} \u3053\u308C\u3089\u306E\u30C6\u30B9\u30C8\u306E\u5B9F\u884C\u65B9\u6CD5",testPackageLine:(t,e)=>`\`${t}/\` \u306F Skyramp Testbot \u304C\u6240\u6709\u30FB\u4FDD\u5B88\u3059\u308B\u72EC\u7ACB\u3057\u305F\u30C6\u30B9\u30C8\u30D1\u30C3\u30B1\u30FC\u30B8\u3067\u3001\u72EC\u81EA\u306E\u30DE\u30CB\u30D5\u30A7\u30B9\u30C8\u3001\u30ED\u30C3\u30AF\u30D5\u30A1\u30A4\u30EB\u3001\u30E9\u30F3\u30CA\u30FC\u8A2D\u5B9A\u3092\u6301\u3061\u307E\u3059\u3002\`${e}\` \u3067\u5B9F\u884C\u3067\u304D\u307E\u3059\u3002\u3059\u3079\u3066\u306E\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u3067\u5B9F\u884C\u3059\u308B\u306B\u306F\u3001\u3053\u306E\u30B3\u30DE\u30F3\u30C9\u3092 CI \u306B\u8FFD\u52A0\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,appManifestsUntouched:"\u30A2\u30D7\u30EA\u30B1\u30FC\u30B7\u30E7\u30F3\u81EA\u8EAB\u306E\u30DE\u30CB\u30D5\u30A7\u30B9\u30C8\u3068\u30ED\u30C3\u30AF\u30D5\u30A1\u30A4\u30EB\u306F\u5909\u66F4\u3057\u3066\u3044\u307E\u305B\u3093\u3002",dependencyChangesHeader:"### \u{1F4E6} \u30A2\u30D7\u30EA\u30B1\u30FC\u30B7\u30E7\u30F3\u306E\u4F9D\u5B58\u95A2\u4FC2\u306E\u5909\u66F4",dependencyChangeLine:(t,e,n)=>`\`${e}\`\uFF08\u304A\u3088\u3073\u305D\u306E\u30ED\u30C3\u30AF\u30D5\u30A1\u30A4\u30EB\uFF09\u306B \`${t}\` \u3092\u8FFD\u52A0${n?`: ${n}`:""}`,testMaintenanceHeader:"\u2705 \u30C6\u30B9\u30C8\u30E1\u30F3\u30C6\u30CA\u30F3\u30B9",keptNot:"\u5909\u66F4\u305B\u305A\u7DAD\u6301 \u2014 \u898B\u9001\u3063\u305F\u64CD\u4F5C: ",declinedPlanned:"(\u4E88\u5B9A\u3057\u3066\u3044\u305F\u64CD\u4F5C\u3092\u898B\u9001\u308A: ",declinedMaintenanceHeader:"\u21A9\uFE0F \u898B\u9001\u3063\u305F\u30E1\u30F3\u30C6\u30CA\u30F3\u30B9",existingEvidenceHeader:"\u2705 \u65E2\u5B58\u306E\u30A8\u30D3\u30C7\u30F3\u30B9",trustedCheckPassed:(t,e)=>`\u4FE1\u983C\u6E08\u307F\u306E CI \u30C1\u30A7\u30C3\u30AF ${t} \u304C${e?` ${e} \u3067`:""}\u5408\u683C\u3057\u3001\u6B21\u3092\u78BA\u8A8D\u3057\u307E\u3057\u305F:`,testResultsHeader:"\u{1F9EA} \u30C6\u30B9\u30C8\u7D50\u679C",resultsTableHeader:"| \u30C6\u30B9\u30C8 ID | \u30C6\u30B9\u30C8\u7A2E\u5225 | \u30A8\u30F3\u30C9\u30DD\u30A4\u30F3\u30C8 | \u30B9\u30C6\u30FC\u30BF\u30B9 | \u8A73\u7D30 |",unitResultsTableHeader:"| \u30C6\u30B9\u30C8 ID | \u30C6\u30B9\u30C8\u7A2E\u5225 | \u30C6\u30B9\u30C8\u5BFE\u8C61\u306E\u30B3\u30FC\u30C9 | \u30C6\u30B9\u30C8 | \u30B1\u30FC\u30B9\u6570 | \u30B9\u30C6\u30FC\u30BF\u30B9 | \u8A73\u7D30 |",casesPassed:(t,e,n)=>`${e} \u4EF6\u4E2D ${t} \u4EF6\u5408\u683C${n?`\u3001${n} \u4EF6\u30B9\u30AD\u30C3\u30D7`:""}`,behaviourCoverageHeader:"\u{1F517} \u632F\u308B\u821E\u3044\u306E\u30AB\u30D0\u30EC\u30C3\u30B8",coverageCaption:(t,e,n,r)=>`\uFF08\u751F\u6210 ${t} \xB7 \u5909\u66F4 ${e} \xB7 \u691C\u8A3C ${n} \xB7 \u5B9F\u884C ${r}\uFF09`,coverageTableHeader:"| \u632F\u308B\u821E\u3044 | \u30BD\u30FC\u30B9 | \u30C6\u30B9\u30C8 | \u30E1\u30F3\u30C6\u30CA\u30F3\u30B9 |",writtenNotRun:"\u4F5C\u6210\u6E08\u307F\u30FB\u672A\u5B9F\u884C",issuesFoundHeader:"\u26A0\uFE0F \u691C\u51FA\u3055\u308C\u305F\u554F\u984C",caveatsHeader:"### \u26A0\uFE0F \u3053\u306E\u5B9F\u884C\u3067\u78BA\u8A8D\u3067\u304D\u306A\u304B\u3063\u305F\u3053\u3068",commentHeader:"### Skyramp Testbot",timedOut:"> \u26A0\uFE0F \u5B9F\u884C\u304C\u30BF\u30A4\u30E0\u30A2\u30A6\u30C8\u3057\u307E\u3057\u305F \u2014 \u4EE5\u4E0B\u306E\u7D50\u679C\u306F\u4E00\u90E8\u306E\u307F\u3067\u3059\u3002",stopReasons:{"pr-closed":"\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u304C\u30DE\u30FC\u30B8\u3055\u308C\u305A\u306B\u30AF\u30ED\u30FC\u30BA\u3055\u308C\u307E\u3057\u305F",cancelled:"\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u304C\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u305F\u304B\u3001\u30E9\u30F3\u30CA\u30FC\u304C\u505C\u6B62\u3057\u307E\u3057\u305F","attempt-cancelled":"Skyramp \u3067\u3053\u306E\u5B9F\u884C\u304C\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u307E\u3057\u305F","attempt-closed":"Skyramp \u304C\u3053\u306E\u5B9F\u884C\u3092\u7D42\u4E86\u3057\u307E\u3057\u305F"},maintenanceActions:{update:"\u66F4\u65B0",regenerate:"\u518D\u751F\u6210",delete:"\u524A\u9664",verify:"\u691C\u8A3C",updated:"\u66F4\u65B0",regenerated:"\u518D\u751F\u6210",deleted:"\u524A\u9664",verified:"\u691C\u8A3C"},publishFailures:{push:"\u30D7\u30C3\u30B7\u30E5\u306B\u5931\u6557",auth:"\u8A8D\u8A3C\u30A8\u30E9\u30FC",conflict:"\u7AF6\u5408",unknown:"\u4E0D\u660E\u306A\u30A8\u30E9\u30FC"},stoppedEarly:(t,e)=>`> \u26A0\uFE0F \u5B9F\u884C\u304C\u9014\u4E2D\u3067\u505C\u6B62\u3057\u307E\u3057\u305F \u2014 ${t}\u3002\u4EE5\u4E0B\u306E\u7D50\u679C\u306F\u4E00\u90E8\u306E\u307F\u3067\u3059\u3002${e}`,viewInSkyramp:t=>` [Skyramp \u3067\u8868\u793A](${t})`,descriptionCut:(t,e,n)=>`_\u2026 \u6B8B\u308A\u306F\u7701\u7565\u3057\u307E\u3057\u305F${e===void 0?"\uFF08\u30C6\u30B9\u30C8\u7D50\u679C\u3092\u542B\u3080\uFF09":e?`\uFF08\u30C6\u30B9\u30C8\u7D50\u679C ${e} \u4EF6\u3092\u542B\u3080\uFF09`:""}\u3002Azure DevOps \u306E\u8AAC\u660E\u306F ${t} \u6587\u5B57\u307E\u3067\u3067\u3059\u3002${n?` [\u5B8C\u5168\u306A\u30EC\u30DD\u30FC\u30C8](${n})`:""}_`,setupRunEnds:{finished:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u304C\u5B8C\u4E86\u3057\u307E\u3057\u305F\u3002Skyramp \u304C\u7D50\u679C\u3092\u78BA\u8A8D\u3057\u3066\u3044\u307E\u3059\u3002",failed:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002",timedOut:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u304C\u6642\u9593\u5207\u308C\u306B\u306A\u308A\u307E\u3057\u305F\u3002",cancelledInSkyramp:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u306F Skyramp \u3067\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u307E\u3057\u305F\u3002",stoppedToResume:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u3092\u505C\u6B62\u3057\u307E\u3057\u305F\u3002Skyramp \u3067\u518D\u958B\u3067\u304D\u307E\u3059\u3002"},appUnreachable:t=>`Skyramp\uFF08${t}\uFF09\u306B\u63A5\u7D9A\u3067\u304D\u307E\u305B\u3093\u3002\u3057\u3070\u3089\u304F\u3057\u3066\u304B\u3089\u518D\u5EA6\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002`,couldNotStart:t=>`Skyramp Testbot \u3092\u958B\u59CB\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F: ${t}`,assembledAfterFailedChecks:t=>`> \u26A0\uFE0F \u4F5C\u6210\u30B9\u30C6\u30C3\u30D7\u304C\u30C1\u30A7\u30C3\u30AF\u306B\u5408\u683C\u3057\u306A\u304B\u3063\u305F\u305F\u3081\u3001\u3053\u306E\u30EC\u30DD\u30FC\u30C8\u306F\u81EA\u52D5\u3067\u7D44\u307F\u7ACB\u3066\u3089\u308C\u307E\u3057\u305F\u3002${t} \u4EF6\u306E\u30C1\u30A7\u30C3\u30AF\u304C\u672A\u9054\u6210\u3067\u3059 \u2014 \u8A73\u7D30\u306F\u5B9F\u884C\u30ED\u30B0\u3092\u53C2\u7167\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,testbotPrLine:(t,e,n)=>`Testbot PR${t?`\uFF08${t}\uFF09`:""}: [${e}](${n})`,viewRun:t=>`_[\u5B9F\u884C\u3092\u8868\u793A](${t})_`,testsPrNotOpened:(t,e)=>`\u30C6\u30B9\u30C8 PR \u3092\u4F5C\u6210\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\uFF08${t}\uFF09\u3002\u30C6\u30B9\u30C8\u306F\u30D6\u30E9\u30F3\u30C1 \`${e}\` \u306B\u30D7\u30C3\u30B7\u30E5\u3055\u308C\u3066\u3044\u307E\u3059\u3002`,testsNotDelivered:t=>`\u30C6\u30B9\u30C8\u3092\u914D\u4FE1\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F: ${t}`,testsNotPushed:(t,e)=>`\u30C6\u30B9\u30C8\u3092\u30D7\u30C3\u30B7\u30E5\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\uFF08${t}\uFF09\u3002\u30C6\u30B9\u30C8\u306F\u30ED\u30FC\u30AB\u30EB\u30D6\u30E9\u30F3\u30C1 \`${e}\` \u306B\u6B8B\u3063\u3066\u3044\u307E\u3059\u3002`,testsPrRetargeted:t=>`\u30C6\u30B9\u30C8\u306E\u751F\u6210\u4E2D\u306B\u958B\u767A PR \u304C\u30DE\u30FC\u30B8\u3055\u308C\u307E\u3057\u305F \u2014 \u30C6\u30B9\u30C8 PR \u306F\u4EE3\u308F\u308A\u306B\u30D9\u30FC\u30B9\u30D6\u30E9\u30F3\u30C1${t?`\uFF08\`${t}\`\uFF09`:""}\u3092\u5BFE\u8C61\u306B\u3057\u3066\u3044\u307E\u3059\u3002`,testsPrUnchanged:"\u3053\u306E\u30D7\u30C3\u30B7\u30E5\u3067\u306F\u65B0\u3057\u3044\u30C6\u30B9\u30C8\u306E\u5909\u66F4\u306F\u4E0D\u8981\u3067\u3057\u305F\u3002\u4EE5\u4E0B\u306E\u30C6\u30B9\u30C8 PR \u306F\u4EE5\u524D\u306E\u5B9F\u884C\u306E\u3082\u306E\u3067\u3001\u305D\u306E\u307E\u307E\u306B\u3057\u3066\u3044\u307E\u3059\u3002",committedNoPr:t=>`\u30C6\u30B9\u30C8\u306F\u30B3\u30DF\u30C3\u30C8\u3055\u308C\u307E\u3057\u305F\u304C\u3001PR \u306F\u4F5C\u6210\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F: ${t}\u3002`,testsNotProposed:t=>`\u30C6\u30B9\u30C8\u306F PR \u3068\u3057\u3066\u63D0\u6848\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F: ${t}\u3002`}};var am=(n=>(n.En="en",n.Ja="ja",n))(am||{}),gY={en:_v,ja:Uv},mY="en";function cm(t){let e=t.trim().toLowerCase();if(e==="")return"en";let n=Object.values(am);return n.includes(e)?e:(Pe(`Invalid language '${t}'. Supported: ${n.join(", ")}. Falling back to 'en'.`),"en")}function Jn(){return gY[mY]}var Ad=(c=>(c.ProviderOutage="provider_outage",c.ProviderRateLimit="provider_rate_limit",c.ProviderUsageLimit="provider_usage_limit",c.ProviderAuthExpired="provider_auth_expired",c.Timeout="timeout",c.NoReport="no_report",c.RenderFailure="render_failure",c))(Ad||{});(e=>{function t(n,r){switch(n){case"provider_outage":return{headline:Jn().providerOutageHeadline(r.provider.name,r.maxRetries),action:Jn().providerOutageActionStatusPage(r.provider.statusUrl)};case"provider_rate_limit":return{headline:Jn().providerRateLimitHeadline(r.provider.name),action:Jn().providerRateLimitAction};case"provider_usage_limit":return{headline:Jn().providerUsageLimitHeadline(r.provider.name),action:Jn().providerUsageLimitAction};case"provider_auth_expired":return{headline:Jn().providerAuthExpiredHeadline(r.provider.name),action:Jn().providerAuthExpiredAction};case"timeout":return{headline:Jn().providerTimeoutHeadline(r.timeoutMinutes),action:Jn().providerTimeoutAction};case"no_report":case"render_failure":return}}e.buildNotice=t})(Ad||={});var um=(n=>(n.SameBranch="same-branch",n.SeparateBranch="separate-branch",n))(um||{});var Lv=(n=>(n.Sonnet="sonnet",n.Opus="opus",n))(Lv||{}),yY="opus";function Am(t){return Object.values(Lv).includes(t)}function Pv(t){let e=(t??"").trim();if(e==="")return yY;let n=e.toLowerCase();return Am(n)?n:e}var ld=(i=>(i.Low="low",i.Medium="medium",i.High="high",i.XHigh="xhigh",i.Max="max",i))(ld||{}),dd="high";function Ov(t){return Object.values(ld).includes(t)}var $v=5;function EY(t){let e=t.split(/\r?\n/).map(n=>n.trim()).filter(Boolean);if(e.length>$v)throw new Error(`relatedRepoPaths supports at most ${$v} entries (got ${e.length}); the cap limits how much cross-repo context is loaded to avoid overflowing Testbot's context window.`);return e}function CY(t){let e=t.trim().toLowerCase();return e===""?"separate-branch":Object.values(um).includes(e)?e:(Pe(`Invalid generatedTestsMode '${t}'. Falling back to 'separate-branch'.`),"separate-branch")}function IY(t){let e=(t??"").trim();if(e!==""){if(/^(?:[1-9]|10)$/.test(e))return Number(e);Pe(`Ignoring perTestMaxFixAttempts="${t}": expected a whole number from 1 to 10; the Skyramp MCP default applies`)}}function BY(t){let e=(t??"").trim().toLowerCase();return e===""?dd:Ov(e)?e:(Pe(`Ignoring effort="${t}": expected one of ${Object.values(ld).join(", ")}; using "${dd}"`),dd)}function Vv(){let t=Pv(he("model"));return Am(t)||Pe(`model '${t}' is not a tested alias (sonnet, opus); passing it to the agent verbatim as a raw model id.`),{skyrampLicenseFile:he("skyrampLicenseFile"),cursorApiKey:he("cursorApiKey"),copilotApiKey:he("copilotApiKey"),anthropicApiKey:he("anthropicApiKey"),useBedrock:vs("useBedrock"),awsRegion:he("awsRegion"),useLocalAuth:he("useLocalAuth").toLowerCase()==="true",model:t,effort:BY(he("effort")),targetSetupCommand:he("targetSetupCommand"),authTokenCommand:he("authTokenCommand"),uiCredentials:he("uiCredentials"),targetTeardownCommand:he("targetTeardownCommand"),skipTargetTeardown:vs("skipTargetTeardown"),skyrampExecutorVersion:he("skyrampExecutorVersion"),skyrampMcpVersion:he("skyrampMcpVersion"),skyrampMcpSource:he("skyrampMcpSource"),skyrampMcpGithubToken:he("skyrampMcpGithubToken"),skyrampMcpGithubRef:he("skyrampMcpGithubRef"),nodeVersion:he("nodeVersion"),skipTargetSetup:vs("skipTargetSetup"),targetReadyCheckCommand:he("targetReadyCheckCommand"),targetReadyCheckTimeout:(()=>{let n=parseInt(he("targetReadyCheckTimeout"),10)||1800;return n<1?(Pe(`targetReadyCheckTimeout must be at least 1 second, got ${n}. Using 1s.`),1):n})(),targetReadyCheckInterval:(()=>{let n=parseInt(he("targetReadyCheckInterval"),10),r=isNaN(n)?30:n;return r<1?(Pe(`targetReadyCheckInterval must be at least 1 second, got ${r}. Using 1s.`),1):r})(),targetReadyCheckDiagnosticsCommand:(()=>{let n=he("targetReadyCheckDiagnosticsCommand");return n.trim().toLowerCase()==="none"?"":n})(),workingDirectory:he("workingDirectory"),autoCommit:vs("autoCommit"),commitMessage:he("commitMessage"),generatedTestsMode:CY(he("generatedTestsMode")),postPrComment:vs("postPrComment"),testExecutionTimeout:parseInt(he("testExecutionTimeout"),10)||300,maxRecommendations:(()=>{let n=parseInt(he("maxRecommendations"),10);return isNaN(n)?void 0:Math.max(0,n)})(),maxGenerate:(()=>{let n=parseInt(he("maxGenerate"),10);return isNaN(n)?void 0:Math.max(0,n)})(),perTestMaxFixAttempts:IY(he("perTestMaxFixAttempts")),testbotMaxRetries:parseInt(he("testbotMaxRetries"),10)||3,testbotRetryDelay:parseInt(he("testbotRetryDelay"),10)||10,testbotTimeout:parseInt(he("testbotTimeout"),10)||60,targetSetupRetries:parseInt(he("targetSetupRetries"),10)||3,targetSetupRetryDelay:parseInt(he("targetSetupRetryDelay"),10)||10,authTokenRetries:(()=>{let n=parseInt(he("authTokenRetries"),10);return Number.isFinite(n)&&n>=1?n:6})(),authTokenRetryDelay:(()=>{let n=parseInt(he("authTokenRetryDelay"),10);return Number.isFinite(n)&&n>=0?n:10})(),reportCollapsed:vs("reportCollapsed"),language:cm(he("language")),enableDebug:vs("enableDebug"),testRepoPath:he("testRepoPath")||void 0,relatedRepoPaths:EY(he("relatedRepoPaths")),allowedAuthors:he("allowedAuthors").split(/\r?\n/).map(n=>n.trim()).filter(Boolean)}}var QY={useBedrock:"false",skipTargetTeardown:"false",skyrampMcpSource:"npm",skyrampMcpGithubRef:"main",nodeVersion:"lts/*",skipTargetSetup:"false",targetReadyCheckTimeout:"1800",targetReadyCheckInterval:"30",targetReadyCheckDiagnosticsCommand:`docker ps -a --format 'table {{.Names}} {{.Status}} {{.Ports}}' && docker ps -a --format '{{.Names}}' | while read name; do [ -n "$name" ] && echo "--- logs $name (last 30) ---" && docker logs --tail 30 "$name"; done`,workingDirectory:".",autoCommit:"true",commitMessage:"Skyramp Testbot: test maintenance suggestions",generatedTestsMode:"separate-branch",pipeline:"staged",postPrComment:"true",testbotMaxRetries:"3",testbotRetryDelay:"10",testExecutionTimeout:"300",testbotTimeout:"60",targetSetupRetries:"3",targetSetupRetryDelay:"10",authTokenRetries:"6",authTokenRetryDelay:"10",reportCollapsed:"true",language:"en",enableDebug:"true",sutSetupMode:"none"};function Gv(t=process.env){for(let[e,n]of Object.entries(QY)){let r=`INPUT_${e.replace(/ /g,"_").toUpperCase()}`;(t[r]??"").trim()===""&&(t[r]=n)}}Dt();var Tx=Re(require("path"));var ba=require("fs"),Jr=Re(require("path"),1),_R=require("child_process"),UR=require("util");function wY(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Bt={},pd={},Fs={},Hv;function lu(){if(Hv)return Fs;Hv=1;function t(a){return typeof a>"u"||a===null}function e(a){return typeof a=="object"&&a!==null}function n(a){return Array.isArray(a)?a:t(a)?[]:[a]}function r(a,c){if(c){let A=Object.keys(c);for(let l=0,p=A.length;l<p;l+=1){let h=A[l];a[h]=c[h]}}return a}function s(a,c){let A="";for(let l=0;l<c;l+=1)A+=a;return A}function i(a){return a===0&&Number.NEGATIVE_INFINITY===1/a}return Fs.isNothing=t,Fs.isObject=e,Fs.toArray=n,Fs.repeat=s,Fs.isNegativeZero=i,Fs.extend=r,Fs}var lm,Yv;function du(){if(Yv)return lm;Yv=1;function t(n,r){let s="",i=n.reason||"(unknown reason)";return n.mark?(n.mark.name&&(s+='in "'+n.mark.name+'" '),s+="("+(n.mark.line+1)+":"+(n.mark.column+1)+")",!r&&n.mark.snippet&&(s+=`
51
+ Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}function mv(t){process.exitCode=Zg.Failure,rH(t)}function Kk(t){ei("debug",{},t)}function rH(t,e={}){ei("error",Yu(e),t instanceof Error?t.toString():t)}function Pe(t,e={}){ei("warning",Yu(e),t instanceof Error?t.toString():t)}function ou(t,e={}){ei("notice",Yu(e),t instanceof Error?t.toString():t)}function In(t){process.stdout.write(t+gv.EOL)}function Zl(t){ap("group",t)}function Xl(){ap("endgroup")}function Rs(t){return process.env[`STATE_${t}`]||""}function yv(t){return nH(this,void 0,void 0,function*(){return yield ql.getIDToken(t)})}var gv,nH,Zg,Dt=kt(()=>{dE();pE();qu();gv=Re(require("os"),1);zk();Gg();Gg();ev();fv();nH=function(t,e,n,r){function s(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function c(p){try{l(r.next(p))}catch(h){a(h)}}function A(p){try{l(r.throw(p))}catch(h){a(h)}}function l(p){p.done?i(p.value):s(p.value).then(c,A)}l((r=r.apply(t,e||[])).next())})};(function(t){t[t.Success=0]="Success",t[t.Failure=1]="Failure"})(Zg||(Zg={}))});var G9={};ip(G9,{post:()=>JT});module.exports=eD(G9);Dt();var jT=Re(require("path"));Dt();Dt();var Xg;(function(t){t.Pass="Pass",t.Fail="Fail",t.Error="Error",t.Skipped="Skipped",t.Unknown="Unknown"})(Xg||(Xg={}));var Ev;(function(t){t.High="high",t.Medium="medium",t.Low="low"})(Ev||(Ev={}));var Cv;(function(t){t.Skyramp="skyramp",t.External="external"})(Cv||(Cv={}));var em;(function(t){t.Update="UPDATE",t.Regenerate="REGENERATE",t.Delete="DELETE",t.Verify="VERIFY",t.Ignore="IGNORE"})(em||(em={}));var Iv;(function(t){t.Small="Small",t.Medium="Medium",t.Large="Large"})(Iv||(Iv={}));var U={};ip(U,{BRAND:()=>RH,DIRTY:()=>xi,EMPTY_PATH:()=>aH,INVALID:()=>se,NEVER:()=>pY,OK:()=>It,ParseStatus:()=>gt,Schema:()=>Ee,ZodAny:()=>Ds,ZodArray:()=>jr,ZodBigInt:()=>Di,ZodBoolean:()=>Ni,ZodBranded:()=>cu,ZodCatch:()=>Hi,ZodDate:()=>Fi,ZodDefault:()=>Gi,ZodDiscriminatedUnion:()=>nd,ZodEffects:()=>wn,ZodEnum:()=>$i,ZodError:()=>Yt,ZodFirstPartyTypeKind:()=>ue,ZodFunction:()=>sd,ZodIntersection:()=>Li,ZodIssueCode:()=>P,ZodLazy:()=>Pi,ZodLiteral:()=>Oi,ZodMap:()=>Ia,ZodNaN:()=>Qa,ZodNativeEnum:()=>Vi,ZodNever:()=>jn,ZodNull:()=>_i,ZodNullable:()=>fr,ZodNumber:()=>Ti,ZodObject:()=>qt,ZodOptional:()=>Bn,ZodParsedType:()=>W,ZodPipeline:()=>uu,ZodPromise:()=>Ns,ZodReadonly:()=>Yi,ZodRecord:()=>rd,ZodSchema:()=>Ee,ZodSet:()=>Ba,ZodString:()=>Ts,ZodSymbol:()=>Ea,ZodTransformer:()=>wn,ZodTuple:()=>hr,ZodType:()=>Ee,ZodUndefined:()=>Mi,ZodUnion:()=>Ui,ZodUnknown:()=>qr,ZodVoid:()=>Ca,addIssueToContext:()=>j,any:()=>LH,array:()=>VH,bigint:()=>NH,boolean:()=>Dv,coerce:()=>dY,custom:()=>Rv,date:()=>FH,datetimeRegex:()=>kv,defaultErrorMap:()=>Hr,discriminatedUnion:()=>qH,effect:()=>sY,enum:()=>tY,function:()=>ZH,getErrorMap:()=>ga,getParsedType:()=>pr,instanceof:()=>TH,intersection:()=>jH,isAborted:()=>ed,isAsync:()=>ma,isDirty:()=>td,isValid:()=>xs,late:()=>xH,lazy:()=>XH,literal:()=>eY,makeIssue:()=>au,map:()=>zH,nan:()=>DH,nativeEnum:()=>nY,never:()=>OH,null:()=>UH,nullable:()=>oY,number:()=>Tv,object:()=>GH,objectUtil:()=>tm,oboolean:()=>lY,onumber:()=>AY,optional:()=>iY,ostring:()=>uY,pipeline:()=>cY,preprocess:()=>aY,promise:()=>rY,quotelessJson:()=>sH,record:()=>WH,set:()=>KH,setErrorMap:()=>oH,strictObject:()=>HH,string:()=>xv,symbol:()=>MH,transformer:()=>sY,tuple:()=>JH,undefined:()=>_H,union:()=>YH,unknown:()=>PH,util:()=>Qe,void:()=>$H});var Qe;(function(t){t.assertEqual=s=>{};function e(s){}t.assertIs=e;function n(s){throw new Error}t.assertNever=n,t.arrayToEnum=s=>{let i={};for(let a of s)i[a]=a;return i},t.getValidEnumValues=s=>{let i=t.objectKeys(s).filter(c=>typeof s[s[c]]!="number"),a={};for(let c of i)a[c]=s[c];return t.objectValues(a)},t.objectValues=s=>t.objectKeys(s).map(function(i){return s[i]}),t.objectKeys=typeof Object.keys=="function"?s=>Object.keys(s):s=>{let i=[];for(let a in s)Object.prototype.hasOwnProperty.call(s,a)&&i.push(a);return i},t.find=(s,i)=>{for(let a of s)if(i(a))return a},t.isInteger=typeof Number.isInteger=="function"?s=>Number.isInteger(s):s=>typeof s=="number"&&Number.isFinite(s)&&Math.floor(s)===s;function r(s,i=" | "){return s.map(a=>typeof a=="string"?`'${a}'`:a).join(i)}t.joinValues=r,t.jsonStringifyReplacer=(s,i)=>typeof i=="bigint"?i.toString():i})(Qe||(Qe={}));var tm;(function(t){t.mergeShapes=(e,n)=>({...e,...n})})(tm||(tm={}));var W=Qe.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),pr=t=>{switch(typeof t){case"undefined":return W.undefined;case"string":return W.string;case"number":return Number.isNaN(t)?W.nan:W.number;case"boolean":return W.boolean;case"function":return W.function;case"bigint":return W.bigint;case"symbol":return W.symbol;case"object":return Array.isArray(t)?W.array:t===null?W.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?W.promise:typeof Map<"u"&&t instanceof Map?W.map:typeof Set<"u"&&t instanceof Set?W.set:typeof Date<"u"&&t instanceof Date?W.date:W.object;default:return W.unknown}};var P=Qe.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),sH=t=>JSON.stringify(t,null,2).replace(/"([^"]+)":/g,"$1:"),Yt=class t extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=r=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};let n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=e}format(e){let n=e||function(i){return i.message},r={_errors:[]},s=i=>{for(let a of i.issues)if(a.code==="invalid_union")a.unionErrors.map(s);else if(a.code==="invalid_return_type")s(a.returnTypeError);else if(a.code==="invalid_arguments")s(a.argumentsError);else if(a.path.length===0)r._errors.push(n(a));else{let c=r,A=0;for(;A<a.path.length;){let l=a.path[A];A===a.path.length-1?(c[l]=c[l]||{_errors:[]},c[l]._errors.push(n(a))):c[l]=c[l]||{_errors:[]},c=c[l],A++}}};return s(this),r}static assert(e){if(!(e instanceof t))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Qe.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=n=>n.message){let n={},r=[];for(let s of this.issues)if(s.path.length>0){let i=s.path[0];n[i]=n[i]||[],n[i].push(e(s))}else r.push(e(s));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}};Yt.create=t=>new Yt(t);var iH=(t,e)=>{let n;switch(t.code){case P.invalid_type:t.received===W.undefined?n="Required":n=`Expected ${t.expected}, received ${t.received}`;break;case P.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(t.expected,Qe.jsonStringifyReplacer)}`;break;case P.unrecognized_keys:n=`Unrecognized key(s) in object: ${Qe.joinValues(t.keys,", ")}`;break;case P.invalid_union:n="Invalid input";break;case P.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${Qe.joinValues(t.options)}`;break;case P.invalid_enum_value:n=`Invalid enum value. Expected ${Qe.joinValues(t.options)}, received '${t.received}'`;break;case P.invalid_arguments:n="Invalid function arguments";break;case P.invalid_return_type:n="Invalid function return type";break;case P.invalid_date:n="Invalid date";break;case P.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(n=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?n=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?n=`Invalid input: must end with "${t.validation.endsWith}"`:Qe.assertNever(t.validation):t.validation!=="regex"?n=`Invalid ${t.validation}`:n="Invalid";break;case P.too_small:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="bigint"?n=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:n="Invalid input";break;case P.too_big:t.type==="array"?n=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?n=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?n=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?n=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?n=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:n="Invalid input";break;case P.custom:n="Invalid input";break;case P.invalid_intersection_types:n="Intersection results could not be merged";break;case P.not_multiple_of:n=`Number must be a multiple of ${t.multipleOf}`;break;case P.not_finite:n="Number must be finite";break;default:n=e.defaultError,Qe.assertNever(t)}return{message:n}},Hr=iH;var Bv=Hr;function oH(t){Bv=t}function ga(){return Bv}var au=t=>{let{data:e,path:n,errorMaps:r,issueData:s}=t,i=[...n,...s.path||[]],a={...s,path:i};if(s.message!==void 0)return{...s,path:i,message:s.message};let c="",A=r.filter(l=>!!l).slice().reverse();for(let l of A)c=l(a,{data:e,defaultError:c}).message;return{...s,path:i,message:c}},aH=[];function j(t,e){let n=ga(),r=au({issueData:e,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,n,n===Hr?void 0:Hr].filter(s=>!!s)});t.common.issues.push(r)}var gt=class t{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,n){let r=[];for(let s of n){if(s.status==="aborted")return se;s.status==="dirty"&&e.dirty(),r.push(s.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,n){let r=[];for(let s of n){let i=await s.key,a=await s.value;r.push({key:i,value:a})}return t.mergeObjectSync(e,r)}static mergeObjectSync(e,n){let r={};for(let s of n){let{key:i,value:a}=s;if(i.status==="aborted"||a.status==="aborted")return se;i.status==="dirty"&&e.dirty(),a.status==="dirty"&&e.dirty(),i.value!=="__proto__"&&(typeof a.value<"u"||s.alwaysSet)&&(r[i.value]=a.value)}return{status:e.value,value:r}}},se=Object.freeze({status:"aborted"}),xi=t=>({status:"dirty",value:t}),It=t=>({status:"valid",value:t}),ed=t=>t.status==="aborted",td=t=>t.status==="dirty",xs=t=>t.status==="valid",ma=t=>typeof Promise<"u"&&t instanceof Promise;var K;(function(t){t.errToObj=e=>typeof e=="string"?{message:e}:e||{},t.toString=e=>typeof e=="string"?e:e?.message})(K||(K={}));var Qn=class{constructor(e,n,r,s){this._cachedPath=[],this.parent=e,this.data=n,this._path=r,this._key=s}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},Qv=(t,e)=>{if(xs(e))return{success:!0,data:e.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let n=new Yt(t.common.issues);return this._error=n,this._error}}};function ge(t){if(!t)return{};let{errorMap:e,invalid_type_error:n,required_error:r,description:s}=t;if(e&&(n||r))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:s}:{errorMap:(a,c)=>{let{message:A}=t;return a.code==="invalid_enum_value"?{message:A??c.defaultError}:typeof c.data>"u"?{message:A??r??c.defaultError}:a.code!=="invalid_type"?{message:c.defaultError}:{message:A??n??c.defaultError}},description:s}}var Ee=class{get description(){return this._def.description}_getType(e){return pr(e.data)}_getOrReturnCtx(e,n){return n||{common:e.parent.common,data:e.data,parsedType:pr(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new gt,ctx:{common:e.parent.common,data:e.data,parsedType:pr(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let n=this._parse(e);if(ma(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(e){let n=this._parse(e);return Promise.resolve(n)}parse(e,n){let r=this.safeParse(e,n);if(r.success)return r.data;throw r.error}safeParse(e,n){let r={common:{issues:[],async:n?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)},s=this._parseSync({data:e,path:r.path,parent:r});return Qv(r,s)}"~validate"(e){let n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:n});return xs(r)?{value:r.value}:{issues:n.common.issues}}catch(r){r?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:n}).then(r=>xs(r)?{value:r.value}:{issues:n.common.issues})}async parseAsync(e,n){let r=await this.safeParseAsync(e,n);if(r.success)return r.data;throw r.error}async safeParseAsync(e,n){let r={common:{issues:[],contextualErrorMap:n?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)},s=this._parse({data:e,path:r.path,parent:r}),i=await(ma(s)?s:Promise.resolve(s));return Qv(r,i)}refine(e,n){let r=s=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(s):n;return this._refinement((s,i)=>{let a=e(s),c=()=>i.addIssue({code:P.custom,...r(s)});return typeof Promise<"u"&&a instanceof Promise?a.then(A=>A?!0:(c(),!1)):a?!0:(c(),!1)})}refinement(e,n){return this._refinement((r,s)=>e(r)?!0:(s.addIssue(typeof n=="function"?n(r,s):n),!1))}_refinement(e){return new wn({schema:this,typeName:ue.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return Bn.create(this,this._def)}nullable(){return fr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return jr.create(this)}promise(){return Ns.create(this,this._def)}or(e){return Ui.create([this,e],this._def)}and(e){return Li.create(this,e,this._def)}transform(e){return new wn({...ge(this._def),schema:this,typeName:ue.ZodEffects,effect:{type:"transform",transform:e}})}default(e){let n=typeof e=="function"?e:()=>e;return new Gi({...ge(this._def),innerType:this,defaultValue:n,typeName:ue.ZodDefault})}brand(){return new cu({typeName:ue.ZodBranded,type:this,...ge(this._def)})}catch(e){let n=typeof e=="function"?e:()=>e;return new Hi({...ge(this._def),innerType:this,catchValue:n,typeName:ue.ZodCatch})}describe(e){let n=this.constructor;return new n({...this._def,description:e})}pipe(e){return uu.create(this,e)}readonly(){return Yi.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},cH=/^c[^\s-]{8,}$/i,uH=/^[0-9a-z]+$/,AH=/^[0-9A-HJKMNP-TV-Z]{26}$/i,lH=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,dH=/^[a-z0-9_-]{21}$/i,pH=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,hH=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,fH=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,gH="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",nm,mH=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,yH=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,EH=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,CH=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,IH=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,BH=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,bv="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",QH=new RegExp(`^${bv}$`);function Sv(t){let e="[0-5]\\d";t.precision?e=`${e}\\.\\d{${t.precision}}`:t.precision==null&&(e=`${e}(\\.\\d+)?`);let n=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${e})${n}`}function wH(t){return new RegExp(`^${Sv(t)}$`)}function kv(t){let e=`${bv}T${Sv(t)}`,n=[];return n.push(t.local?"Z?":"Z"),t.offset&&n.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${n.join("|")})`,new RegExp(`^${e}$`)}function bH(t,e){return!!((e==="v4"||!e)&&mH.test(t)||(e==="v6"||!e)&&EH.test(t))}function SH(t,e){if(!pH.test(t))return!1;try{let[n]=t.split(".");if(!n)return!1;let r=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),s=JSON.parse(atob(r));return!(typeof s!="object"||s===null||"typ"in s&&s?.typ!=="JWT"||!s.alg||e&&s.alg!==e)}catch{return!1}}function kH(t,e){return!!((e==="v4"||!e)&&yH.test(t)||(e==="v6"||!e)&&CH.test(t))}var Ts=class t extends Ee{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==W.string){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_type,expected:W.string,received:i.parsedType}),se}let r=new gt,s;for(let i of this._def.checks)if(i.kind==="min")e.data.length<i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="max")e.data.length>i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="length"){let a=e.data.length>i.value,c=e.data.length<i.value;(a||c)&&(s=this._getOrReturnCtx(e,s),a?j(s,{code:P.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):c&&j(s,{code:P.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),r.dirty())}else if(i.kind==="email")fH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"email",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="emoji")nm||(nm=new RegExp(gH,"u")),nm.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"emoji",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="uuid")lH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"uuid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="nanoid")dH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"nanoid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid")cH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"cuid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid2")uH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"cuid2",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="ulid")AH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"ulid",code:P.invalid_string,message:i.message}),r.dirty());else if(i.kind==="url")try{new URL(e.data)}catch{s=this._getOrReturnCtx(e,s),j(s,{validation:"url",code:P.invalid_string,message:i.message}),r.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"regex",code:P.invalid_string,message:i.message}),r.dirty())):i.kind==="trim"?e.data=e.data.trim():i.kind==="includes"?e.data.includes(i.value,i.position)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),r.dirty()):i.kind==="toLowerCase"?e.data=e.data.toLowerCase():i.kind==="toUpperCase"?e.data=e.data.toUpperCase():i.kind==="startsWith"?e.data.startsWith(i.value)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:{startsWith:i.value},message:i.message}),r.dirty()):i.kind==="endsWith"?e.data.endsWith(i.value)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:{endsWith:i.value},message:i.message}),r.dirty()):i.kind==="datetime"?kv(i).test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:"datetime",message:i.message}),r.dirty()):i.kind==="date"?QH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:"date",message:i.message}),r.dirty()):i.kind==="time"?wH(i).test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{code:P.invalid_string,validation:"time",message:i.message}),r.dirty()):i.kind==="duration"?hH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"duration",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="ip"?bH(e.data,i.version)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"ip",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="jwt"?SH(e.data,i.alg)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"jwt",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="cidr"?kH(e.data,i.version)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"cidr",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="base64"?IH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"base64",code:P.invalid_string,message:i.message}),r.dirty()):i.kind==="base64url"?BH.test(e.data)||(s=this._getOrReturnCtx(e,s),j(s,{validation:"base64url",code:P.invalid_string,message:i.message}),r.dirty()):Qe.assertNever(i);return{status:r.value,value:e.data}}_regex(e,n,r){return this.refinement(s=>e.test(s),{validation:n,code:P.invalid_string,...K.errToObj(r)})}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...K.errToObj(e)})}url(e){return this._addCheck({kind:"url",...K.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...K.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...K.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...K.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...K.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...K.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...K.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...K.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...K.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...K.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...K.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...K.errToObj(e)})}datetime(e){return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...K.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...K.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...K.errToObj(e)})}regex(e,n){return this._addCheck({kind:"regex",regex:e,...K.errToObj(n)})}includes(e,n){return this._addCheck({kind:"includes",value:e,position:n?.position,...K.errToObj(n?.message)})}startsWith(e,n){return this._addCheck({kind:"startsWith",value:e,...K.errToObj(n)})}endsWith(e,n){return this._addCheck({kind:"endsWith",value:e,...K.errToObj(n)})}min(e,n){return this._addCheck({kind:"min",value:e,...K.errToObj(n)})}max(e,n){return this._addCheck({kind:"max",value:e,...K.errToObj(n)})}length(e,n){return this._addCheck({kind:"length",value:e,...K.errToObj(n)})}nonempty(e){return this.min(1,K.errToObj(e))}trim(){return new t({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new t({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new t({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find(e=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find(e=>e.kind==="base64url")}get minLength(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxLength(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}};Ts.create=t=>new Ts({checks:[],typeName:ue.ZodString,coerce:t?.coerce??!1,...ge(t)});function vH(t,e){let n=(t.toString().split(".")[1]||"").length,r=(e.toString().split(".")[1]||"").length,s=n>r?n:r,i=Number.parseInt(t.toFixed(s).replace(".","")),a=Number.parseInt(e.toFixed(s).replace(".",""));return i%a/10**s}var Ti=class t extends Ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==W.number){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_type,expected:W.number,received:i.parsedType}),se}let r,s=new gt;for(let i of this._def.checks)i.kind==="int"?Qe.isInteger(e.data)||(r=this._getOrReturnCtx(e,r),j(r,{code:P.invalid_type,expected:"integer",received:"float",message:i.message}),s.dirty()):i.kind==="min"?(i.inclusive?e.data<i.value:e.data<=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),s.dirty()):i.kind==="max"?(i.inclusive?e.data>i.value:e.data>=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),s.dirty()):i.kind==="multipleOf"?vH(e.data,i.value)!==0&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.not_multiple_of,multipleOf:i.value,message:i.message}),s.dirty()):i.kind==="finite"?Number.isFinite(e.data)||(r=this._getOrReturnCtx(e,r),j(r,{code:P.not_finite,message:i.message}),s.dirty()):Qe.assertNever(i);return{status:s.value,value:e.data}}gte(e,n){return this.setLimit("min",e,!0,K.toString(n))}gt(e,n){return this.setLimit("min",e,!1,K.toString(n))}lte(e,n){return this.setLimit("max",e,!0,K.toString(n))}lt(e,n){return this.setLimit("max",e,!1,K.toString(n))}setLimit(e,n,r,s){return new t({...this._def,checks:[...this._def.checks,{kind:e,value:n,inclusive:r,message:K.toString(s)}]})}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:K.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:K.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:K.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:K.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:K.toString(e)})}multipleOf(e,n){return this._addCheck({kind:"multipleOf",value:e,message:K.toString(n)})}finite(e){return this._addCheck({kind:"finite",message:K.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:K.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:K.toString(e)})}get minValue(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxValue(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&Qe.isInteger(e.value))}get isFinite(){let e=null,n=null;for(let r of this._def.checks){if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;r.kind==="min"?(n===null||r.value>n)&&(n=r.value):r.kind==="max"&&(e===null||r.value<e)&&(e=r.value)}return Number.isFinite(n)&&Number.isFinite(e)}};Ti.create=t=>new Ti({checks:[],typeName:ue.ZodNumber,coerce:t?.coerce||!1,...ge(t)});var Di=class t extends Ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==W.bigint)return this._getInvalidInput(e);let r,s=new gt;for(let i of this._def.checks)i.kind==="min"?(i.inclusive?e.data<i.value:e.data<=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),s.dirty()):i.kind==="max"?(i.inclusive?e.data>i.value:e.data>=i.value)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),s.dirty()):i.kind==="multipleOf"?e.data%i.value!==BigInt(0)&&(r=this._getOrReturnCtx(e,r),j(r,{code:P.not_multiple_of,multipleOf:i.value,message:i.message}),s.dirty()):Qe.assertNever(i);return{status:s.value,value:e.data}}_getInvalidInput(e){let n=this._getOrReturnCtx(e);return j(n,{code:P.invalid_type,expected:W.bigint,received:n.parsedType}),se}gte(e,n){return this.setLimit("min",e,!0,K.toString(n))}gt(e,n){return this.setLimit("min",e,!1,K.toString(n))}lte(e,n){return this.setLimit("max",e,!0,K.toString(n))}lt(e,n){return this.setLimit("max",e,!1,K.toString(n))}setLimit(e,n,r,s){return new t({...this._def,checks:[...this._def.checks,{kind:e,value:n,inclusive:r,message:K.toString(s)}]})}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:K.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:K.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:K.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:K.toString(e)})}multipleOf(e,n){return this._addCheck({kind:"multipleOf",value:e,message:K.toString(n)})}get minValue(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e}get maxValue(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e}};Di.create=t=>new Di({checks:[],typeName:ue.ZodBigInt,coerce:t?.coerce??!1,...ge(t)});var Ni=class extends Ee{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==W.boolean){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.boolean,received:r.parsedType}),se}return It(e.data)}};Ni.create=t=>new Ni({typeName:ue.ZodBoolean,coerce:t?.coerce||!1,...ge(t)});var Fi=class t extends Ee{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==W.date){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_type,expected:W.date,received:i.parsedType}),se}if(Number.isNaN(e.data.getTime())){let i=this._getOrReturnCtx(e);return j(i,{code:P.invalid_date}),se}let r=new gt,s;for(let i of this._def.checks)i.kind==="min"?e.data.getTime()<i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),r.dirty()):i.kind==="max"?e.data.getTime()>i.value&&(s=this._getOrReturnCtx(e,s),j(s,{code:P.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),r.dirty()):Qe.assertNever(i);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new t({...this._def,checks:[...this._def.checks,e]})}min(e,n){return this._addCheck({kind:"min",value:e.getTime(),message:K.toString(n)})}max(e,n){return this._addCheck({kind:"max",value:e.getTime(),message:K.toString(n)})}get minDate(){let e=null;for(let n of this._def.checks)n.kind==="min"&&(e===null||n.value>e)&&(e=n.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(let n of this._def.checks)n.kind==="max"&&(e===null||n.value<e)&&(e=n.value);return e!=null?new Date(e):null}};Fi.create=t=>new Fi({checks:[],coerce:t?.coerce||!1,typeName:ue.ZodDate,...ge(t)});var Ea=class extends Ee{_parse(e){if(this._getType(e)!==W.symbol){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.symbol,received:r.parsedType}),se}return It(e.data)}};Ea.create=t=>new Ea({typeName:ue.ZodSymbol,...ge(t)});var Mi=class extends Ee{_parse(e){if(this._getType(e)!==W.undefined){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.undefined,received:r.parsedType}),se}return It(e.data)}};Mi.create=t=>new Mi({typeName:ue.ZodUndefined,...ge(t)});var _i=class extends Ee{_parse(e){if(this._getType(e)!==W.null){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.null,received:r.parsedType}),se}return It(e.data)}};_i.create=t=>new _i({typeName:ue.ZodNull,...ge(t)});var Ds=class extends Ee{constructor(){super(...arguments),this._any=!0}_parse(e){return It(e.data)}};Ds.create=t=>new Ds({typeName:ue.ZodAny,...ge(t)});var qr=class extends Ee{constructor(){super(...arguments),this._unknown=!0}_parse(e){return It(e.data)}};qr.create=t=>new qr({typeName:ue.ZodUnknown,...ge(t)});var jn=class extends Ee{_parse(e){let n=this._getOrReturnCtx(e);return j(n,{code:P.invalid_type,expected:W.never,received:n.parsedType}),se}};jn.create=t=>new jn({typeName:ue.ZodNever,...ge(t)});var Ca=class extends Ee{_parse(e){if(this._getType(e)!==W.undefined){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.void,received:r.parsedType}),se}return It(e.data)}};Ca.create=t=>new Ca({typeName:ue.ZodVoid,...ge(t)});var jr=class t extends Ee{_parse(e){let{ctx:n,status:r}=this._processInputParams(e),s=this._def;if(n.parsedType!==W.array)return j(n,{code:P.invalid_type,expected:W.array,received:n.parsedType}),se;if(s.exactLength!==null){let a=n.data.length>s.exactLength.value,c=n.data.length<s.exactLength.value;(a||c)&&(j(n,{code:a?P.too_big:P.too_small,minimum:c?s.exactLength.value:void 0,maximum:a?s.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:s.exactLength.message}),r.dirty())}if(s.minLength!==null&&n.data.length<s.minLength.value&&(j(n,{code:P.too_small,minimum:s.minLength.value,type:"array",inclusive:!0,exact:!1,message:s.minLength.message}),r.dirty()),s.maxLength!==null&&n.data.length>s.maxLength.value&&(j(n,{code:P.too_big,maximum:s.maxLength.value,type:"array",inclusive:!0,exact:!1,message:s.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((a,c)=>s.type._parseAsync(new Qn(n,a,n.path,c)))).then(a=>gt.mergeArray(r,a));let i=[...n.data].map((a,c)=>s.type._parseSync(new Qn(n,a,n.path,c)));return gt.mergeArray(r,i)}get element(){return this._def.type}min(e,n){return new t({...this._def,minLength:{value:e,message:K.toString(n)}})}max(e,n){return new t({...this._def,maxLength:{value:e,message:K.toString(n)}})}length(e,n){return new t({...this._def,exactLength:{value:e,message:K.toString(n)}})}nonempty(e){return this.min(1,e)}};jr.create=(t,e)=>new jr({type:t,minLength:null,maxLength:null,exactLength:null,typeName:ue.ZodArray,...ge(e)});function ya(t){if(t instanceof qt){let e={};for(let n in t.shape){let r=t.shape[n];e[n]=Bn.create(ya(r))}return new qt({...t._def,shape:()=>e})}else return t instanceof jr?new jr({...t._def,type:ya(t.element)}):t instanceof Bn?Bn.create(ya(t.unwrap())):t instanceof fr?fr.create(ya(t.unwrap())):t instanceof hr?hr.create(t.items.map(e=>ya(e))):t}var qt=class t extends Ee{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),n=Qe.objectKeys(e);return this._cached={shape:e,keys:n},this._cached}_parse(e){if(this._getType(e)!==W.object){let l=this._getOrReturnCtx(e);return j(l,{code:P.invalid_type,expected:W.object,received:l.parsedType}),se}let{status:r,ctx:s}=this._processInputParams(e),{shape:i,keys:a}=this._getCached(),c=[];if(!(this._def.catchall instanceof jn&&this._def.unknownKeys==="strip"))for(let l in s.data)a.includes(l)||c.push(l);let A=[];for(let l of a){let p=i[l],h=s.data[l];A.push({key:{status:"valid",value:l},value:p._parse(new Qn(s,h,s.path,l)),alwaysSet:l in s.data})}if(this._def.catchall instanceof jn){let l=this._def.unknownKeys;if(l==="passthrough")for(let p of c)A.push({key:{status:"valid",value:p},value:{status:"valid",value:s.data[p]}});else if(l==="strict")c.length>0&&(j(s,{code:P.unrecognized_keys,keys:c}),r.dirty());else if(l!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let l=this._def.catchall;for(let p of c){let h=s.data[p];A.push({key:{status:"valid",value:p},value:l._parse(new Qn(s,h,s.path,p)),alwaysSet:p in s.data})}}return s.common.async?Promise.resolve().then(async()=>{let l=[];for(let p of A){let h=await p.key,g=await p.value;l.push({key:h,value:g,alwaysSet:p.alwaysSet})}return l}).then(l=>gt.mergeObjectSync(r,l)):gt.mergeObjectSync(r,A)}get shape(){return this._def.shape()}strict(e){return K.errToObj,new t({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(n,r)=>{let s=this._def.errorMap?.(n,r).message??r.defaultError;return n.code==="unrecognized_keys"?{message:K.errToObj(e).message??s}:{message:s}}}:{}})}strip(){return new t({...this._def,unknownKeys:"strip"})}passthrough(){return new t({...this._def,unknownKeys:"passthrough"})}extend(e){return new t({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new t({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:ue.ZodObject})}setKey(e,n){return this.augment({[e]:n})}catchall(e){return new t({...this._def,catchall:e})}pick(e){let n={};for(let r of Qe.objectKeys(e))e[r]&&this.shape[r]&&(n[r]=this.shape[r]);return new t({...this._def,shape:()=>n})}omit(e){let n={};for(let r of Qe.objectKeys(this.shape))e[r]||(n[r]=this.shape[r]);return new t({...this._def,shape:()=>n})}deepPartial(){return ya(this)}partial(e){let n={};for(let r of Qe.objectKeys(this.shape)){let s=this.shape[r];e&&!e[r]?n[r]=s:n[r]=s.optional()}return new t({...this._def,shape:()=>n})}required(e){let n={};for(let r of Qe.objectKeys(this.shape))if(e&&!e[r])n[r]=this.shape[r];else{let i=this.shape[r];for(;i instanceof Bn;)i=i._def.innerType;n[r]=i}return new t({...this._def,shape:()=>n})}keyof(){return vv(Qe.objectKeys(this.shape))}};qt.create=(t,e)=>new qt({shape:()=>t,unknownKeys:"strip",catchall:jn.create(),typeName:ue.ZodObject,...ge(e)});qt.strictCreate=(t,e)=>new qt({shape:()=>t,unknownKeys:"strict",catchall:jn.create(),typeName:ue.ZodObject,...ge(e)});qt.lazycreate=(t,e)=>new qt({shape:t,unknownKeys:"strip",catchall:jn.create(),typeName:ue.ZodObject,...ge(e)});var Ui=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r=this._def.options;function s(i){for(let c of i)if(c.result.status==="valid")return c.result;for(let c of i)if(c.result.status==="dirty")return n.common.issues.push(...c.ctx.common.issues),c.result;let a=i.map(c=>new Yt(c.ctx.common.issues));return j(n,{code:P.invalid_union,unionErrors:a}),se}if(n.common.async)return Promise.all(r.map(async i=>{let a={...n,common:{...n.common,issues:[]},parent:null};return{result:await i._parseAsync({data:n.data,path:n.path,parent:a}),ctx:a}})).then(s);{let i,a=[];for(let A of r){let l={...n,common:{...n.common,issues:[]},parent:null},p=A._parseSync({data:n.data,path:n.path,parent:l});if(p.status==="valid")return p;p.status==="dirty"&&!i&&(i={result:p,ctx:l}),l.common.issues.length&&a.push(l.common.issues)}if(i)return n.common.issues.push(...i.ctx.common.issues),i.result;let c=a.map(A=>new Yt(A));return j(n,{code:P.invalid_union,unionErrors:c}),se}}get options(){return this._def.options}};Ui.create=(t,e)=>new Ui({options:t,typeName:ue.ZodUnion,...ge(e)});var Yr=t=>t instanceof Pi?Yr(t.schema):t instanceof wn?Yr(t.innerType()):t instanceof Oi?[t.value]:t instanceof $i?t.options:t instanceof Vi?Qe.objectValues(t.enum):t instanceof Gi?Yr(t._def.innerType):t instanceof Mi?[void 0]:t instanceof _i?[null]:t instanceof Bn?[void 0,...Yr(t.unwrap())]:t instanceof fr?[null,...Yr(t.unwrap())]:t instanceof cu||t instanceof Yi?Yr(t.unwrap()):t instanceof Hi?Yr(t._def.innerType):[],nd=class t extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e);if(n.parsedType!==W.object)return j(n,{code:P.invalid_type,expected:W.object,received:n.parsedType}),se;let r=this.discriminator,s=n.data[r],i=this.optionsMap.get(s);return i?n.common.async?i._parseAsync({data:n.data,path:n.path,parent:n}):i._parseSync({data:n.data,path:n.path,parent:n}):(j(n,{code:P.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),se)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,n,r){let s=new Map;for(let i of n){let a=Yr(i.shape[e]);if(!a.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let c of a){if(s.has(c))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(c)}`);s.set(c,i)}}return new t({typeName:ue.ZodDiscriminatedUnion,discriminator:e,options:n,optionsMap:s,...ge(r)})}};function rm(t,e){let n=pr(t),r=pr(e);if(t===e)return{valid:!0,data:t};if(n===W.object&&r===W.object){let s=Qe.objectKeys(e),i=Qe.objectKeys(t).filter(c=>s.indexOf(c)!==-1),a={...t,...e};for(let c of i){let A=rm(t[c],e[c]);if(!A.valid)return{valid:!1};a[c]=A.data}return{valid:!0,data:a}}else if(n===W.array&&r===W.array){if(t.length!==e.length)return{valid:!1};let s=[];for(let i=0;i<t.length;i++){let a=t[i],c=e[i],A=rm(a,c);if(!A.valid)return{valid:!1};s.push(A.data)}return{valid:!0,data:s}}else return n===W.date&&r===W.date&&+t==+e?{valid:!0,data:t}:{valid:!1}}var Li=class extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e),s=(i,a)=>{if(ed(i)||ed(a))return se;let c=rm(i.value,a.value);return c.valid?((td(i)||td(a))&&n.dirty(),{status:n.value,value:c.data}):(j(r,{code:P.invalid_intersection_types}),se)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([i,a])=>s(i,a)):s(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}};Li.create=(t,e,n)=>new Li({left:t,right:e,typeName:ue.ZodIntersection,...ge(n)});var hr=class t extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.array)return j(r,{code:P.invalid_type,expected:W.array,received:r.parsedType}),se;if(r.data.length<this._def.items.length)return j(r,{code:P.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),se;!this._def.rest&&r.data.length>this._def.items.length&&(j(r,{code:P.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());let i=[...r.data].map((a,c)=>{let A=this._def.items[c]||this._def.rest;return A?A._parse(new Qn(r,a,r.path,c)):null}).filter(a=>!!a);return r.common.async?Promise.all(i).then(a=>gt.mergeArray(n,a)):gt.mergeArray(n,i)}get items(){return this._def.items}rest(e){return new t({...this._def,rest:e})}};hr.create=(t,e)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new hr({items:t,typeName:ue.ZodTuple,rest:null,...ge(e)})};var rd=class t extends Ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.object)return j(r,{code:P.invalid_type,expected:W.object,received:r.parsedType}),se;let s=[],i=this._def.keyType,a=this._def.valueType;for(let c in r.data)s.push({key:i._parse(new Qn(r,c,r.path,c)),value:a._parse(new Qn(r,r.data[c],r.path,c)),alwaysSet:c in r.data});return r.common.async?gt.mergeObjectAsync(n,s):gt.mergeObjectSync(n,s)}get element(){return this._def.valueType}static create(e,n,r){return n instanceof Ee?new t({keyType:e,valueType:n,typeName:ue.ZodRecord,...ge(r)}):new t({keyType:Ts.create(),valueType:e,typeName:ue.ZodRecord,...ge(n)})}},Ia=class extends Ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.map)return j(r,{code:P.invalid_type,expected:W.map,received:r.parsedType}),se;let s=this._def.keyType,i=this._def.valueType,a=[...r.data.entries()].map(([c,A],l)=>({key:s._parse(new Qn(r,c,r.path,[l,"key"])),value:i._parse(new Qn(r,A,r.path,[l,"value"]))}));if(r.common.async){let c=new Map;return Promise.resolve().then(async()=>{for(let A of a){let l=await A.key,p=await A.value;if(l.status==="aborted"||p.status==="aborted")return se;(l.status==="dirty"||p.status==="dirty")&&n.dirty(),c.set(l.value,p.value)}return{status:n.value,value:c}})}else{let c=new Map;for(let A of a){let l=A.key,p=A.value;if(l.status==="aborted"||p.status==="aborted")return se;(l.status==="dirty"||p.status==="dirty")&&n.dirty(),c.set(l.value,p.value)}return{status:n.value,value:c}}}};Ia.create=(t,e,n)=>new Ia({valueType:e,keyType:t,typeName:ue.ZodMap,...ge(n)});var Ba=class t extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.parsedType!==W.set)return j(r,{code:P.invalid_type,expected:W.set,received:r.parsedType}),se;let s=this._def;s.minSize!==null&&r.data.size<s.minSize.value&&(j(r,{code:P.too_small,minimum:s.minSize.value,type:"set",inclusive:!0,exact:!1,message:s.minSize.message}),n.dirty()),s.maxSize!==null&&r.data.size>s.maxSize.value&&(j(r,{code:P.too_big,maximum:s.maxSize.value,type:"set",inclusive:!0,exact:!1,message:s.maxSize.message}),n.dirty());let i=this._def.valueType;function a(A){let l=new Set;for(let p of A){if(p.status==="aborted")return se;p.status==="dirty"&&n.dirty(),l.add(p.value)}return{status:n.value,value:l}}let c=[...r.data.values()].map((A,l)=>i._parse(new Qn(r,A,r.path,l)));return r.common.async?Promise.all(c).then(A=>a(A)):a(c)}min(e,n){return new t({...this._def,minSize:{value:e,message:K.toString(n)}})}max(e,n){return new t({...this._def,maxSize:{value:e,message:K.toString(n)}})}size(e,n){return this.min(e,n).max(e,n)}nonempty(e){return this.min(1,e)}};Ba.create=(t,e)=>new Ba({valueType:t,minSize:null,maxSize:null,typeName:ue.ZodSet,...ge(e)});var sd=class t extends Ee{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:n}=this._processInputParams(e);if(n.parsedType!==W.function)return j(n,{code:P.invalid_type,expected:W.function,received:n.parsedType}),se;function r(c,A){return au({data:c,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,ga(),Hr].filter(l=>!!l),issueData:{code:P.invalid_arguments,argumentsError:A}})}function s(c,A){return au({data:c,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,ga(),Hr].filter(l=>!!l),issueData:{code:P.invalid_return_type,returnTypeError:A}})}let i={errorMap:n.common.contextualErrorMap},a=n.data;if(this._def.returns instanceof Ns){let c=this;return It(async function(...A){let l=new Yt([]),p=await c._def.args.parseAsync(A,i).catch(C=>{throw l.addIssue(r(A,C)),l}),h=await Reflect.apply(a,this,p);return await c._def.returns._def.type.parseAsync(h,i).catch(C=>{throw l.addIssue(s(h,C)),l})})}else{let c=this;return It(function(...A){let l=c._def.args.safeParse(A,i);if(!l.success)throw new Yt([r(A,l.error)]);let p=Reflect.apply(a,this,l.data),h=c._def.returns.safeParse(p,i);if(!h.success)throw new Yt([s(p,h.error)]);return h.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new t({...this._def,args:hr.create(e).rest(qr.create())})}returns(e){return new t({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,n,r){return new t({args:e||hr.create([]).rest(qr.create()),returns:n||qr.create(),typeName:ue.ZodFunction,...ge(r)})}},Pi=class extends Ee{get schema(){return this._def.getter()}_parse(e){let{ctx:n}=this._processInputParams(e);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}};Pi.create=(t,e)=>new Pi({getter:t,typeName:ue.ZodLazy,...ge(e)});var Oi=class extends Ee{_parse(e){if(e.data!==this._def.value){let n=this._getOrReturnCtx(e);return j(n,{received:n.data,code:P.invalid_literal,expected:this._def.value}),se}return{status:"valid",value:e.data}}get value(){return this._def.value}};Oi.create=(t,e)=>new Oi({value:t,typeName:ue.ZodLiteral,...ge(e)});function vv(t,e){return new $i({values:t,typeName:ue.ZodEnum,...ge(e)})}var $i=class t extends Ee{_parse(e){if(typeof e.data!="string"){let n=this._getOrReturnCtx(e),r=this._def.values;return j(n,{expected:Qe.joinValues(r),received:n.parsedType,code:P.invalid_type}),se}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){let n=this._getOrReturnCtx(e),r=this._def.values;return j(n,{received:n.data,code:P.invalid_enum_value,options:r}),se}return It(e.data)}get options(){return this._def.values}get enum(){let e={};for(let n of this._def.values)e[n]=n;return e}get Values(){let e={};for(let n of this._def.values)e[n]=n;return e}get Enum(){let e={};for(let n of this._def.values)e[n]=n;return e}extract(e,n=this._def){return t.create(e,{...this._def,...n})}exclude(e,n=this._def){return t.create(this.options.filter(r=>!e.includes(r)),{...this._def,...n})}};$i.create=vv;var Vi=class extends Ee{_parse(e){let n=Qe.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==W.string&&r.parsedType!==W.number){let s=Qe.objectValues(n);return j(r,{expected:Qe.joinValues(s),received:r.parsedType,code:P.invalid_type}),se}if(this._cache||(this._cache=new Set(Qe.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){let s=Qe.objectValues(n);return j(r,{received:r.data,code:P.invalid_enum_value,options:s}),se}return It(e.data)}get enum(){return this._def.values}};Vi.create=(t,e)=>new Vi({values:t,typeName:ue.ZodNativeEnum,...ge(e)});var Ns=class extends Ee{unwrap(){return this._def.type}_parse(e){let{ctx:n}=this._processInputParams(e);if(n.parsedType!==W.promise&&n.common.async===!1)return j(n,{code:P.invalid_type,expected:W.promise,received:n.parsedType}),se;let r=n.parsedType===W.promise?n.data:Promise.resolve(n.data);return It(r.then(s=>this._def.type.parseAsync(s,{path:n.path,errorMap:n.common.contextualErrorMap})))}};Ns.create=(t,e)=>new Ns({type:t,typeName:ue.ZodPromise,...ge(e)});var wn=class extends Ee{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===ue.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:n,ctx:r}=this._processInputParams(e),s=this._def.effect||null,i={addIssue:a=>{j(r,a),a.fatal?n.abort():n.dirty()},get path(){return r.path}};if(i.addIssue=i.addIssue.bind(i),s.type==="preprocess"){let a=s.transform(r.data,i);if(r.common.async)return Promise.resolve(a).then(async c=>{if(n.value==="aborted")return se;let A=await this._def.schema._parseAsync({data:c,path:r.path,parent:r});return A.status==="aborted"?se:A.status==="dirty"?xi(A.value):n.value==="dirty"?xi(A.value):A});{if(n.value==="aborted")return se;let c=this._def.schema._parseSync({data:a,path:r.path,parent:r});return c.status==="aborted"?se:c.status==="dirty"?xi(c.value):n.value==="dirty"?xi(c.value):c}}if(s.type==="refinement"){let a=c=>{let A=s.refinement(c,i);if(r.common.async)return Promise.resolve(A);if(A instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return c};if(r.common.async===!1){let c=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return c.status==="aborted"?se:(c.status==="dirty"&&n.dirty(),a(c.value),{status:n.value,value:c.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(c=>c.status==="aborted"?se:(c.status==="dirty"&&n.dirty(),a(c.value).then(()=>({status:n.value,value:c.value}))))}if(s.type==="transform")if(r.common.async===!1){let a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!xs(a))return se;let c=s.transform(a.value,i);if(c instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:c}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(a=>xs(a)?Promise.resolve(s.transform(a.value,i)).then(c=>({status:n.value,value:c})):se);Qe.assertNever(s)}};wn.create=(t,e,n)=>new wn({schema:t,typeName:ue.ZodEffects,effect:e,...ge(n)});wn.createWithPreprocess=(t,e,n)=>new wn({schema:e,effect:{type:"preprocess",transform:t},typeName:ue.ZodEffects,...ge(n)});var Bn=class extends Ee{_parse(e){return this._getType(e)===W.undefined?It(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};Bn.create=(t,e)=>new Bn({innerType:t,typeName:ue.ZodOptional,...ge(e)});var fr=class extends Ee{_parse(e){return this._getType(e)===W.null?It(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}};fr.create=(t,e)=>new fr({innerType:t,typeName:ue.ZodNullable,...ge(e)});var Gi=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r=n.data;return n.parsedType===W.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}};Gi.create=(t,e)=>new Gi({innerType:t,typeName:ue.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...ge(e)});var Hi=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r={...n,common:{...n.common,issues:[]}},s=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return ma(s)?s.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new Yt(r.common.issues)},input:r.data})})):{status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new Yt(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}};Hi.create=(t,e)=>new Hi({innerType:t,typeName:ue.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...ge(e)});var Qa=class extends Ee{_parse(e){if(this._getType(e)!==W.nan){let r=this._getOrReturnCtx(e);return j(r,{code:P.invalid_type,expected:W.nan,received:r.parsedType}),se}return{status:"valid",value:e.data}}};Qa.create=t=>new Qa({typeName:ue.ZodNaN,...ge(t)});var RH=Symbol("zod_brand"),cu=class extends Ee{_parse(e){let{ctx:n}=this._processInputParams(e),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}},uu=class t extends Ee{_parse(e){let{status:n,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let i=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return i.status==="aborted"?se:i.status==="dirty"?(n.dirty(),xi(i.value)):this._def.out._parseAsync({data:i.value,path:r.path,parent:r})})();{let s=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return s.status==="aborted"?se:s.status==="dirty"?(n.dirty(),{status:"dirty",value:s.value}):this._def.out._parseSync({data:s.value,path:r.path,parent:r})}}static create(e,n){return new t({in:e,out:n,typeName:ue.ZodPipeline})}},Yi=class extends Ee{_parse(e){let n=this._def.innerType._parse(e),r=s=>(xs(s)&&(s.value=Object.freeze(s.value)),s);return ma(n)?n.then(s=>r(s)):r(n)}unwrap(){return this._def.innerType}};Yi.create=(t,e)=>new Yi({innerType:t,typeName:ue.ZodReadonly,...ge(e)});function wv(t,e){let n=typeof t=="function"?t(e):typeof t=="string"?{message:t}:t;return typeof n=="string"?{message:n}:n}function Rv(t,e={},n){return t?Ds.create().superRefine((r,s)=>{let i=t(r);if(i instanceof Promise)return i.then(a=>{if(!a){let c=wv(e,r),A=c.fatal??n??!0;s.addIssue({code:"custom",...c,fatal:A})}});if(!i){let a=wv(e,r),c=a.fatal??n??!0;s.addIssue({code:"custom",...a,fatal:c})}}):Ds.create()}var xH={object:qt.lazycreate},ue;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(ue||(ue={}));var TH=(t,e={message:`Input not instance of ${t.name}`})=>Rv(n=>n instanceof t,e),xv=Ts.create,Tv=Ti.create,DH=Qa.create,NH=Di.create,Dv=Ni.create,FH=Fi.create,MH=Ea.create,_H=Mi.create,UH=_i.create,LH=Ds.create,PH=qr.create,OH=jn.create,$H=Ca.create,VH=jr.create,GH=qt.create,HH=qt.strictCreate,YH=Ui.create,qH=nd.create,jH=Li.create,JH=hr.create,WH=rd.create,zH=Ia.create,KH=Ba.create,ZH=sd.create,XH=Pi.create,eY=Oi.create,tY=$i.create,nY=Vi.create,rY=Ns.create,sY=wn.create,iY=Bn.create,oY=fr.create,aY=wn.createWithPreprocess,cY=uu.create,uY=()=>xv().optional(),AY=()=>Tv().optional(),lY=()=>Dv().optional(),dY={string:(t=>Ts.create({...t,coerce:!0})),number:(t=>Ti.create({...t,coerce:!0})),boolean:(t=>Ni.create({...t,coerce:!0})),bigint:(t=>Di.create({...t,coerce:!0})),date:(t=>Fi.create({...t,coerce:!0}))};var pY=se;var wa=["playwright","pytest","robot","junit","vitest","jest","mocha","go","rspec","jasmine"];var Nv="skyramp_session_storage.json";var sm;(function(t){t.PYTHON="python",t.TYPESCRIPT="typescript",t.JAVASCRIPT="javascript",t.JAVA="java"})(sm||(sm={}));var gr;(function(t){t.SMOKE="smoke",t.FUZZ="fuzz",t.CONTRACT="contract",t.LOAD="load",t.INTEGRATION="integration",t.E2E="e2e",t.UI="ui",t.UNIT="unit",t.UNKNOWN="unknown"})(gr||(gr={}));var nZ=[gr.CONTRACT,gr.INTEGRATION,gr.E2E,gr.UI];var Fv;(function(t){t.Rest="rest",t.Grpc="grpc",t.Kafka="kafka"})(Fv||(Fv={}));var id;(function(t){t.GET="GET",t.POST="POST",t.PUT="PUT",t.DELETE="DELETE",t.PATCH="PATCH",t.HEAD="HEAD",t.OPTIONS="OPTIONS"})(id||(id={}));var Au;(function(t){t.LOCAL="local",t.DOCKER="docker",t.KUBERNETES="k8s"})(Au||(Au={}));var hY=U.nativeEnum(Au),im=U.preprocess(t=>t==="kubernetes"?Au.KUBERNETES:t,hY);var fY=U.object({language:U.nativeEnum(sm).describe("Programming language for the generated test (default: python). Must be one of: python, typescript, javascript, java"),framework:U.string().describe(`Testing framework to use. Supported: ${wa.join(", ")} (e.g. pytest for python, playwright/vitest/jest for js/ts, junit for java).`)}),Mv=U.object({...fY.shape,deployDashboard:U.boolean().default(!1).describe("Whether to deploy the Skyramp dashboard for test monitoring"),runtime:im.default(Au.LOCAL).describe("Runtime environment (local, docker, or k8s; accepts kubernetes as an alias)"),dockerNetwork:U.string().default("").describe("Docker network name to use for containerized testing"),dockerWorkerPort:U.number().int().min(0).max(65535).default(0).describe("Port number for the Docker worker service"),k8sNamespace:U.string().default("").describe("Kubernetes namespace for deployment"),k8sConfig:U.string().default("").describe("Path to Kubernetes configuration file"),k8sContext:U.string().default("").describe("Kubernetes context to use"),authHeader:U.string().default("").describe("Name of the HTTP header that carries the auth credential. Common values: 'Authorization' (Bearer/Basic/Token auth), 'X-Api-Key', 'X-Auth-Token', 'Cookie'. Other accepted values: 'X-Access-Token', 'X-OAuth-Token', 'X-Client-ID', 'X-Client-Secret', 'X-Client-Token', 'X-GitHub-Token', 'X-Firebase-AppCheck', 'Proxy-Authorization', 'Fastly-Key', 'Heroku-Bearer'. Pass empty string to document an unauthenticated endpoint in the generated test's assertions. This is the header KEY name (e.g., 'X-Api-Key'), NOT the token value."),authScheme:U.string().default("").describe("Only for Authorization headers. The literal prefix before the token (e.g., 'Bearer' produces 'Authorization: Bearer <token>'). Common values: 'Bearer', 'Basic', 'Token'. If the API sends raw tokens with no prefix (e.g., 'Authorization: eyJ...'), leave empty or omit. Ignored when authHeader is not 'Authorization'."),insecure:U.boolean().default(!1).describe("Whether to allow insecure SSL connections for HTTPS endpoints"),output:U.string().optional().refine(t=>!t||t===""?!0:[".py",".ts",".js",".java"].some(n=>t.endsWith(n)),{message:"Output file must have one of these extensions: .py, .ts, .js, .java"}).describe("Name of the output test file. For Playwright, name the file the way the repository names its tests: read the test files already in outputDir and match their spelling. Use *.test.ts where they use it, *.spec.ts otherwise (e.g. contract_math_add.spec.ts, fuzz_orders.test.ts). For other frameworks (pytest, junit), standard extensions are fine (.py, .java). Optional \u2014 when omitted, Skyramp generates a default name."),outputDir:U.string().describe("MUST be absolute path to the directory where test files will be generated. If not provided, the CURRENT WORKING DIRECTORY will be used WITHOUT ANY SUBDIRECTORIES"),force:U.boolean().default(!0).describe("Whether to overwrite existing files in the output directory"),mockPort:U.number().int().min(0).max(65535).default(0).describe("Port number for the mock server"),optionalFields:U.boolean().default(!1).describe("Whether to include optional fields in the generated test/mock"),prompt:U.string().describe("The prompt user provided to generate the test")}),rZ=U.object({playwrightInput:U.string().describe("MUST be absolute path to the playwright input file like /path/to/playwright-ui-test.zip and MUST be a zip file captured using start_trace_collection tool"),playwrightStoragePath:U.string().optional().describe("Path to LOAD existing playwright session storage for trace collection with playwright enabled. THE PATH MUST BE AN ABSOLUTE PATH LIKE /Users/<path>/<filename>.json"),playwrightSaveStoragePath:U.string().optional().describe(`Path to SAVE Playwright session storage after trace collection. Omit this argument to use the default \u2014 \`${Nv}\` resolved against the active outputDir, which produces an absolute path like '/abs/outputDir/${Nv}'. SAVES authentication state (cookies, localStorage, sessionStorage) when the browser closes. To LOAD existing auth state, use playwrightStoragePath instead. Can be a bare filename (joined with outputDir), a relative path, or an absolute path.`),playwrightViewportSize:U.union([U.enum(["","hd","full-hd","2k"]),U.string().regex(/^\d+,\d+$/,"Custom viewport must be 'WIDTH,HEIGHT' format (e.g., '1920,1080')")]).default("").describe("Viewport size for playwright browser. THE VALUE MUST BE IN THE FORMAT ['', 'hd', 'full-hd', '2k', 'x,y' e.g. '1920,1080' for 1920x1080 resolution]. DEFAULT VALUE IS ''. If set to '', the browser will use its default viewport size."),browser:U.enum(["chromium","firefox","webkit"]).default("chromium").describe("Browser to use for Playwright trace collection. Supported browsers: 'chromium' (default), 'firefox', 'webkit'. Choose based on your testing requirements and target browser compatibility."),device:U.string().default("").describe("Device to emulate for Playwright trace collection. Supported devices include: 'iPhone 13', 'iPhone 13 Pro', 'Pixel 5', 'Galaxy S9+', 'iPad Pro', etc. Leave empty for no device emulation (desktop). Use specific device names for mobile/tablet testing.")}),sZ=U.object({trace:U.string().describe("Absolute path to the trace file in JSON format (e.g., /path/to/trace.json). Must use .json extension only. Do not use .jsonl files."),include:U.array(U.string()).default([]).describe("List of endpoints or patterns to include in test generation."),exclude:U.array(U.string()).default([]).describe("List of endpoints or patterns to exclude from test generation."),...Mv.shape}),iZ={endpointURL:U.string().describe("The full endpoint URL to test including base URL and path (e.g., https://demoshop.skyramp.dev/api/v1/products). MUST include both the base URL and the endpoint path \u2014 never just the base URL alone."),method:U.union([U.nativeEnum(id),U.literal("")]).default("").describe('HTTP method to use. DEFAULT: Use empty string ("") to test ALL available methods from OpenAPI schema (recommended). Only specify a specific method (GET, POST, PUT, DELETE, etc.) if user explicitly requests testing a single method only.'),apiSchema:U.string().default("").describe("MUST be absolute path(/path/to/openapi.json) to the OpenAPI/Swagger schema file or a URL to the OpenAPI/Swagger schema file(e.g. https://demoshop.skyramp.dev/openapi.json). DO NOT TRY TO ASSUME THE OPENAPI SCHEMA IF NOT PROVIDED. NOTE TO AI ASSISTANTS: You do not need to read the contents of this file - simply pass the file path as the backend will read and process it."),pathParams:U.string().default("").describe("Comma-separated path parameter values in the form 'key=value,key2=value2' (e.g., 'id=1,name=John'). DO NOT populate this field unless the user has explicitly provided path parameter values. For contract tests, parent path parameters are automatically handled via the parent provisioning mechanism (parentRequestData) \u2014 do NOT invent or guess values for those here. Only supply this field if the user explicitly states specific path parameter values to use."),queryParams:U.string().default("").describe("MUST be string of comma separated values like 'id=1,name=John' for URL query parameters. Workspace-configured api.defaultQueryParams (if set) are merged in automatically, with any api.queryParamOverrides entry whose pathPattern matches this endpoint layered on top \u2014 no need to repeat them here. An explicit value for the same key here overrides both."),formParams:U.string().default("").describe("MUST be string of comma separated values like 'id=1,name=John' for form data parameters"),requestData:U.string().default("").refine(t=>{if(!t||t===""||t.startsWith("@"))return!0;try{return JSON.parse(t),!0}catch{}let e=t.trim();return!!(e.startsWith("---")||/^\w[\w\s]*:/.test(e)||e.startsWith("-"))},{message:"requestData must be valid JSON, YAML, or an absolute file path prefixed with '@'. Received what appears to be plain text. Provide the actual request body as a JSON object."}).describe("Sample request body data, provided either as an inline JSON/YAML string or as an absolute file path prefixed with '@' (e.g., @/absolute/path/to/file). MUST be valid JSON or YAML \u2014 do NOT pass natural language descriptions."),responseStatusCode:U.string().default("").refine(t=>!t||/^[1-5]\d{2}$/.test(t),{message:"Must be a valid HTTP status code in 100-599 (e.g., '200', '404') or empty string"}).describe("Expected HTTP response status code (e.g., '200', '201', '404'). DO NOT ASSUME STATUS CODE IF NOT PROVIDED"),...Mv.shape},oZ=U.object({codeReuse:U.boolean().default(!1).describe("Reuse existing code in the generated test \u2014 consolidates helper functions shared with sibling Skyramp-generated tests into a SkyrampUtils file; for TS/JS Playwright tests with POM reuse enabled it instead refactors the test to use the repo's existing Page Object Model"),modularizeCode:U.boolean().default(!1).describe("Whether to modularize the code")}),aZ=[gr.INTEGRATION,gr.CONTRACT,gr.UI];var od;(function(t){t.Bug="bug",t.Lint="lint",t.Type="type",t.Config="config"})(od||(od={}));var ad;(function(t){t.NotMapped="not-mapped",t.DemotedByVerify="demoted-by-verify"})(ad||(ad={}));var cd;(function(t){t.Passed="passed",t.Failed="failed",t.SkippedNoPom="skipped-no-pom"})(cd||(cd={}));var om;(function(t){t.Passed="passed",t.Failed="failed",t.NoUtilsFile="no-utils-file"})(om||(om={}));Dt();var ud=t=>`${t} POM call${t===1?"":"s"}`,_v={testRecommendationsImplementedHeader:t=>`\u{1F4A1} Test Recommendations Implemented (${t})`,testTypeCellLabels:{},statusLabels:{},severityLabels:{},reuse:{label:"POM reuse",noPomLayer:"skipped \u2014 no page-object layer detected for this test",reusedAndVerified:t=>`${ud(t)} reused and verified`,reusedThenVerified:(t,e)=>`${ud(t)} reused, ${e} of them verified`,reused:t=>`${ud(t)} reused`,verified:t=>`${ud(t)} verified`,unresolved:t=>`${t} not resolvable to POM source (informational, not declines)`,candidates:t=>`${t} candidate POM file${t===1?"":"s"} detected`,verificationPassed:"verification passed",verificationFailed:"\u26A0\uFE0F verification did not pass",keptInline:t=>`kept inline: ${t}`,gate:{"not-mapped":"not mapped","demoted-by-verify":"demoted by verification"}},testMaintenanceHeader:t=>`\u2705 Test Maintenance (${t})`,maintenanceTableHeader:"| Test Type | Endpoint | File | Change | Before | After |",testResultsHeader:t=>`\u{1F9EA} Test Results (${t})`,columnVideo:"Video",videoDownloadLink:t=>`[\u{1F4F9} download](${t})`,videosArtifactFallback:t=>`\u{1F4F9} Recorded UI test videos: [download from run artifacts](${t})`,issuesFoundHeader:t=>`\u26A0\uFE0F Issues Found (${t})`,configErrorsHeader:"\u2699\uFE0F Configuration Errors",nextStepsHeader:"### \u{1F4A1} Next Steps",caveatsHeader:"### \u26A0\uFE0F What this run could not prove",rows:{passed:t=>t?"passed against the running app":"passed",notRun:t=>t?"not run against a live app this run":"not run this run",failedBug:t=>t?"failed against the running app":"failed",executedOf:(t,e)=>e?` and executed ${t} of them against the running app.`:` and executed ${t} of them.`,noneExecuted:t=>t?"; none were executed against a live app this run.":"; none were executed this run."},caveats:{deployFailed:"The app could not be started, so nothing here was checked against a running system.",changeBrokeBringup:"This change appears to have broken the app's start-up: it could not run with the PR applied, so nothing was tested against it.",bringupFailed:"The app could not be started this run, for a reason outside this PR \u2014 nothing was tested against a live app.",testsNotExecuted:"No test was run against a live app this run \u2014 an un-run suite is not evidence the change works.",recipeDrift:"The recorded way to start the app was out of date and had to be corrected before it would come up.",mockedDependency:t=>`${t} was mocked rather than really deployed \u2014 a green run against it is not proof.`,finalizeNotReady:t=>`The tests are not ready to merge as they stand${t?`: ${t}`:"."}`,ciNotCovered:"No CI workflow runs these tests, so they will not execute on future pull requests.",ciNotCoveredBecause:t=>`The repo's CI will not run some of these tests on future pull requests: ${t}`,sutNotRequired:"No app was started: validation triage found no deployed behavior this change needs validated.",lintNotCovered:t=>`The repo's linter does not check ${t} \u2014 a style or type issue there would not be caught automatically.`,analysisUnverified:t=>`Part of the change analysis could not be verified (${t} unresolved check${t===1?"":"s"}); the tests were planned treating those claims as unconfirmed.`,unitTestsNotRun:t=>`Testbot could not run the unit tests it selected, so no unit result here is its own re-run: ${t}`,downstreamNotChecked:t=>`Not run: checks of other parts of the app that this change might affect. The change does not alter that behavior itself, so they are not needed to validate it. ${t}`,testsCouldNotRunHere:(t,e)=>`${t} ${t===1?"test exists":"tests exist"} in this change, but this environment could not run ${t===1?"it":"them"}, so ${t===1?"it has":"they have"} no result here (not skipped): ${e}`,modelProviderDenied:(t,e=!1)=>e?`${t}, the model provider, refused a call. The evidence already obtained is sufficient to determine this run\u2019s outcome.`:`${t}, the model provider, refused Testbot's calls, so the run stopped before it finished. Access was denied because of credentials, permissions, or a usage limit. For Skyramp-managed provider access, contact Skyramp support before running again; if you manage the provider account, ask its administrator to resolve access or usage limits. No changes to your code are needed.`,modelProviderUnavailable:(t,e=!1)=>e?`${t}, the model provider, was unavailable for a call. The evidence already obtained is sufficient to determine this run\u2019s outcome.`:`${t}, the model provider, was unavailable to Testbot, so this stage could not finish. Any results already obtained remain in this report. No changes to your code or Testbot setup are needed. Please try again later.`},providerOutageHeadline:(t,e)=>`Testbot could not reach ${t} \u2014 it tried ${e} times without success.`,providerOutageActionStatusPage:t=>`Check ${t}. Once the service is healthy, re-run this workflow from its run page in the Actions tab.`,providerRateLimitHeadline:t=>`Testbot was rate-limited by ${t} (HTTP 429).`,providerRateLimitAction:"Wait for the limit to reset, then re-run this workflow from its run page in the Actions tab. If this repeats, raise the rate limit on the credential this workflow uses or run Testbot on fewer pull requests at once.",providerUsageLimitHeadline:t=>`The account behind ${t} has reached its usage limit.`,providerUsageLimitAction:"Raise the spend or token cap on the account behind this workflow's credential, then re-run this workflow from its run page in the Actions tab.",providerAuthExpiredHeadline:t=>`The credential Testbot uses to reach ${t} expired while the run was still working.`,providerAuthExpiredAction:"The credential is issued with a fixed lifetime, so a longer run can outlive it. Re-run this workflow from its run page in the Actions tab. If runs on this repository regularly last longer than that lifetime, issue the credential per job or split the run so each job stays inside it.",providerTimeoutHeadline:t=>`Testbot ran past its ${t}-minute time limit and was stopped.`,providerTimeoutAction:"Raise the `testbotTimeout` input on the workflow if runs on this repository legitimately need longer.",staged:{testsSourcePullRequest:t=>`Tests for source pull request ${t}`,requestedByPerson:t=>`Requested by ${t}`,requestedByPolicy:t=>`Started by the Validation Policy ${t}`,noLiveApp:t=>`> \u26A0\uFE0F **No live app (SUT) was available this run** \u2014 the ${t} test(s) below were **not executed** (there was no app to run them against). Run them against a running app to confirm they pass (and that any repro test fails as intended).`,unitTestsInFile:(t,e,n)=>`**${t}**: ${e} unit test${e===1?"":"s"}${n?` for ${n}`:""}`,addedToExistingFile:"added to an existing test file",testPackagesHeader:"### \u{1F4E6} Running these tests",testPackageLine:(t,e)=>`\`${t}/\` is a self-contained test package Skyramp Testbot owns and maintains, with its own manifest, lockfile and runner config. Run it with \`${e}\`; to run it on every pull request, add that one command to CI.`,appManifestsUntouched:"The application's own manifests and lockfiles were not changed.",dependencyChangesHeader:"### \u{1F4E6} Changes to the application's dependencies",dependencyChangeLine:(t,e,n)=>`Added \`${t}\` to \`${e}\` (and its lockfile)${n?`: ${n}`:""}`,testMaintenanceHeader:"\u2705 Test Maintenance",keptNot:"kept, not ",declinedPlanned:"(declined the planned ",declinedMaintenanceHeader:"\u21A9\uFE0F Declined Maintenance",existingEvidenceHeader:"\u2705 Existing Evidence",trustedCheckPassed:(t,e)=>`Trusted CI check ${t} passed${e?` on ${e}`:""}, establishing:`,testResultsHeader:"\u{1F9EA} Test Results",resultsTableHeader:"| Test ID | Test Type | Endpoint | Status | Details |",unitResultsTableHeader:"| Test ID | Test Type | Code under test | Test | Cases | Status | Details |",casesPassed:(t,e,n)=>`${t}/${e} passed${n?`, ${n} skipped`:""}`,behaviourCoverageHeader:"\u{1F517} Behaviour Coverage",coverageCaption:(t,e,n,r)=>` (${t} generated \xB7 ${e} modified \xB7 ${n} verified \xB7 ${r} executed)`,coverageTableHeader:"| Behaviour | Source | Tested By | Maintained By |",writtenNotRun:"written, not run",issuesFoundHeader:"\u26A0\uFE0F Issues Found",caveatsHeader:"### \u26A0\uFE0F What This Run Could Not Prove",commentHeader:"### Skyramp Testbot",timedOut:"> \u26A0\uFE0F Run timed out \u2014 the results below are partial.",stopReasons:{},publishFailures:{},maintenanceActions:{},stoppedEarly:(t,e)=>`> \u26A0\uFE0F Run stopped early \u2014 ${t}. The results below are partial.${e}`,viewInSkyramp:t=>` [View in Skyramp](${t})`,descriptionCut:(t,e,n)=>`_\u2026 The rest is left out${e===void 0?", with more test results":e?`, with ${e} more test result${e===1?"":"s"}`:""}: Azure DevOps takes at most ${t} characters.${n?` [Full report](${n})`:""}_`,setupRunEnds:{finished:"Setup run finished. Skyramp is checking the result.",failed:"Setup run failed.",timedOut:"Setup run ran out of time.",cancelledInSkyramp:"Setup run was cancelled in Skyramp.",stoppedToResume:"Setup run stopped. Resume it in Skyramp."},appUnreachable:t=>`Unable to contact the mothership ${t}. Please try again later.`,couldNotStart:t=>`Skyramp Testbot could not start: ${t}`,assembledAfterFailedChecks:t=>`> \u26A0\uFE0F This report was assembled automatically after the write-up step failed its checks; ${t} check(s) remain unmet \u2014 see the run log for details.`,testbotPrLine:(t,e,n)=>`Testbot PR${t?` (${t})`:""} : [${e}](${n})`,viewRun:t=>`_[View run](${t})_`,testsPrNotOpened:(t,e)=>`The tests PR could not be opened (${t}); the tests were pushed to branch \`${e}\`.`,testsNotDelivered:t=>`The tests could not be delivered: ${t}`,testsNotPushed:(t,e)=>`The tests could not be pushed (${t}); they remain on the local branch \`${e}\`.`,testsPrRetargeted:t=>`The dev PR merged while tests were being generated \u2014 the tests PR targets its base branch${t?` (\`${t}\`)`:""} instead.`,testsPrUnchanged:"This push required no new test changes; the tests PR below is from an earlier run and was left as is.",committedNoPr:t=>`The tests were committed but no PR was opened: ${t}.`,testsNotProposed:t=>`The tests were not proposed in a pull request: ${t}.`}};var Uv={testRecommendationsImplementedHeader:t=>`\u{1F4A1} \u5B9F\u88C5\u3057\u305F\u30C6\u30B9\u30C8\u63A8\u5968\uFF08${t}\u4EF6\uFF09`,testTypeCellLabels:{smoke:"\u30B9\u30E2\u30FC\u30AF",fuzz:"\u30D5\u30A1\u30BA",contract:"\u30B3\u30F3\u30C8\u30E9\u30AF\u30C8",load:"\u8CA0\u8377",integration:"\u7D71\u5408",e2e:"E2E",ui:"UI",unit:"\u30E6\u30CB\u30C3\u30C8"},statusLabels:{Pass:"\u5408\u683C",Fail:"\u4E0D\u5408\u683C",Error:"\u30A8\u30E9\u30FC",Skipped:"\u30B9\u30AD\u30C3\u30D7"},severityLabels:{critical:"\u91CD\u5927",high:"\u9AD8",medium:"\u4E2D",low:"\u4F4E"},reuse:{label:"POM \u518D\u5229\u7528",noPomLayer:"\u30B9\u30AD\u30C3\u30D7 \u2014 \u3053\u306E\u30C6\u30B9\u30C8\u306B\u518D\u5229\u7528\u3067\u304D\u308B\u30DA\u30FC\u30B8\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\u5C64\u306F\u691C\u51FA\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F",reusedAndVerified:t=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u518D\u5229\u7528\u30FB\u691C\u8A3C\u6E08\u307F`,reusedThenVerified:(t,e)=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u518D\u5229\u7528\uFF08\u3046\u3061 ${e} \u4EF6\u3092\u691C\u8A3C\u6E08\u307F\uFF09`,reused:t=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u518D\u5229\u7528`,verified:t=>`POM \u547C\u3073\u51FA\u3057 ${t} \u4EF6\u3092\u691C\u8A3C\u6E08\u307F`,unresolved:t=>`${t} \u4EF6\u306F POM \u30BD\u30FC\u30B9\u307E\u3067\u89E3\u6C7A\u3067\u304D\u305A\uFF08\u53C2\u8003\u60C5\u5831\u3067\u3042\u308A\u3001\u9664\u5916\u3067\u306F\u3042\u308A\u307E\u305B\u3093\uFF09`,candidates:t=>`\u5019\u88DC\u3068\u306A\u308B POM \u30D5\u30A1\u30A4\u30EB ${t} \u4EF6\u3092\u691C\u51FA`,verificationPassed:"\u691C\u8A3C\u306B\u5408\u683C",verificationFailed:"\u26A0\uFE0F \u691C\u8A3C\u306B\u5408\u683C\u3057\u307E\u305B\u3093\u3067\u3057\u305F",keptInline:t=>`\u30A4\u30F3\u30E9\u30A4\u30F3\u306E\u307E\u307E: ${t}`,gate:{"not-mapped":"\u30DE\u30C3\u30D4\u30F3\u30B0\u5BFE\u8C61\u5916","demoted-by-verify":"\u691C\u8A3C\u3067\u5DEE\u3057\u623B\u3057"}},testMaintenanceHeader:t=>`\u2705 \u30C6\u30B9\u30C8\u30E1\u30F3\u30C6\u30CA\u30F3\u30B9\uFF08${t}\u4EF6\uFF09`,maintenanceTableHeader:"| \u30C6\u30B9\u30C8\u7A2E\u5225 | \u30A8\u30F3\u30C9\u30DD\u30A4\u30F3\u30C8 | \u30D5\u30A1\u30A4\u30EB | \u5909\u66F4\u5185\u5BB9 | \u5909\u66F4\u524D | \u5909\u66F4\u5F8C |",testResultsHeader:t=>`\u{1F9EA} \u30C6\u30B9\u30C8\u7D50\u679C\uFF08${t}\u4EF6\uFF09`,columnVideo:"\u30D3\u30C7\u30AA",videoDownloadLink:t=>`[\u{1F4F9} \u30C0\u30A6\u30F3\u30ED\u30FC\u30C9](${t})`,videosArtifactFallback:t=>`\u{1F4F9} \u9332\u753B\u3055\u308C\u305F UI \u30C6\u30B9\u30C8\u30D3\u30C7\u30AA: [\u5B9F\u884C\u30A2\u30FC\u30C6\u30A3\u30D5\u30A1\u30AF\u30C8\u304B\u3089\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9](${t})`,issuesFoundHeader:t=>`\u26A0\uFE0F \u691C\u51FA\u3055\u308C\u305F\u554F\u984C\uFF08${t}\u4EF6\uFF09`,configErrorsHeader:"\u2699\uFE0F \u8A2D\u5B9A\u30A8\u30E9\u30FC",nextStepsHeader:"### \u{1F4A1} \u6B21\u306E\u30B9\u30C6\u30C3\u30D7",caveatsHeader:"### \u26A0\uFE0F \u3053\u306E\u5B9F\u884C\u3067\u78BA\u8A8D\u3067\u304D\u306A\u304B\u3063\u305F\u3053\u3068",rows:{passed:t=>t?"\u8D77\u52D5\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u6210\u529F\u3057\u307E\u3057\u305F":"\u6210\u529F\u3057\u307E\u3057\u305F",notRun:t=>t?"\u3053\u306E\u5B9F\u884C\u3067\u306F\u30E9\u30A4\u30D6\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F":"\u3053\u306E\u5B9F\u884C\u3067\u306F\u5B9F\u884C\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F",failedBug:t=>t?"\u8D77\u52D5\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5931\u6557\u3057\u307E\u3057\u305F":"\u5931\u6557\u3057\u307E\u3057\u305F",executedOf:(t,e)=>e?`\u3001\u305D\u306E\u3046\u3061 ${t} \u4EF6\u3092\u8D77\u52D5\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3057\u307E\u3057\u305F\u3002`:`\u3001\u305D\u306E\u3046\u3061 ${t} \u4EF6\u3092\u5B9F\u884C\u3057\u307E\u3057\u305F\u3002`,noneExecuted:t=>t?"\u3002\u3053\u306E\u5B9F\u884C\u3067\u306F\u30E9\u30A4\u30D6\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3055\u308C\u305F\u3082\u306E\u306F\u3042\u308A\u307E\u305B\u3093\u3002":"\u3002\u3053\u306E\u5B9F\u884C\u3067\u306F\u5B9F\u884C\u3055\u308C\u305F\u3082\u306E\u306F\u3042\u308A\u307E\u305B\u3093\u3002"},caveats:{deployFailed:"\u30A2\u30D7\u30EA\u3092\u8D77\u52D5\u3067\u304D\u306A\u304B\u3063\u305F\u305F\u3081\u3001\u3053\u3053\u306B\u793A\u3059\u5185\u5BB9\u306F\u7A3C\u50CD\u4E2D\u306E\u30B7\u30B9\u30C6\u30E0\u306B\u5BFE\u3057\u3066\u691C\u8A3C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002",changeBrokeBringup:"\u3053\u306E\u5909\u66F4\u306B\u3088\u308A\u30A2\u30D7\u30EA\u306E\u8D77\u52D5\u304C\u58CA\u308C\u305F\u3068\u601D\u308F\u308C\u307E\u3059\u3002PR \u3092\u9069\u7528\u3057\u305F\u72B6\u614B\u3067\u8D77\u52D5\u3067\u304D\u305A\u3001\u30C6\u30B9\u30C8\u306F\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002",bringupFailed:"\u3053\u306E PR \u3068\u306F\u7121\u95A2\u4FC2\u306E\u7406\u7531\u3067\u30A2\u30D7\u30EA\u3092\u8D77\u52D5\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3059\u308B\u30C6\u30B9\u30C8\u306F\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002",testsNotExecuted:"\u3053\u306E\u5B9F\u884C\u3067\u306F\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u30C6\u30B9\u30C8\u304C\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002\u672A\u5B9F\u884C\u306E\u30C6\u30B9\u30C8\u306F\u5909\u66F4\u304C\u6B63\u3057\u304F\u52D5\u4F5C\u3059\u308B\u8A3C\u62E0\u306B\u306A\u308A\u307E\u305B\u3093\u3002",recipeDrift:"\u8A18\u9332\u3055\u308C\u3066\u3044\u305F\u30A2\u30D7\u30EA\u306E\u8D77\u52D5\u624B\u9806\u304C\u53E4\u304F\u306A\u3063\u3066\u304A\u308A\u3001\u8D77\u52D5\u524D\u306B\u4FEE\u6B63\u304C\u5FC5\u8981\u3067\u3057\u305F\u3002",mockedDependency:t=>`${t} \u306F\u5B9F\u969B\u306B\u30C7\u30D7\u30ED\u30A4\u3055\u308C\u305A\u30E2\u30C3\u30AF\u5316\u3055\u308C\u307E\u3057\u305F\u3002\u3053\u308C\u306B\u5BFE\u3059\u308B\u6210\u529F\u7D50\u679C\u306F\u8A3C\u660E\u306B\u306F\u306A\u308A\u307E\u305B\u3093\u3002`,finalizeNotReady:t=>`\u30C6\u30B9\u30C8\u306F\u73FE\u72B6\u3067\u306F\u30DE\u30FC\u30B8\u53EF\u80FD\u306A\u72B6\u614B\u3067\u306F\u3042\u308A\u307E\u305B\u3093${t?`: ${t}`:"\u3002"}`,ciNotCovered:"\u3053\u308C\u3089\u306E\u30C6\u30B9\u30C8\u3092\u5B9F\u884C\u3059\u308B CI \u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u304C\u306A\u3044\u305F\u3081\u3001\u4ECA\u5F8C\u306E\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u3067\u306F\u5B9F\u884C\u3055\u308C\u307E\u305B\u3093\u3002",ciNotCoveredBecause:t=>`\u30EA\u30DD\u30B8\u30C8\u30EA\u306E CI \u306F\u3001\u4ECA\u5F8C\u306E\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u3067\u3053\u308C\u3089\u306E\u30C6\u30B9\u30C8\u306E\u4E00\u90E8\u3092\u5B9F\u884C\u3057\u307E\u305B\u3093: ${t}`,sutNotRequired:"\u30A2\u30D7\u30EA\u306F\u8D77\u52D5\u3057\u3066\u3044\u307E\u305B\u3093\u3002\u691C\u8A3C\u30C8\u30EA\u30A2\u30FC\u30B8\u306B\u3088\u308A\u3001\u3053\u306E\u5909\u66F4\u3067\u691C\u8A3C\u304C\u5FC5\u8981\u306A\u30C7\u30D7\u30ED\u30A4\u5F8C\u306E\u632F\u308B\u821E\u3044\u306F\u306A\u3044\u3068\u5224\u65AD\u3055\u308C\u307E\u3057\u305F\u3002",lintNotCovered:t=>`\u30EA\u30DD\u30B8\u30C8\u30EA\u306E\u30EA\u30F3\u30BF\u30FC\u306F ${t} \u3092\u30C1\u30A7\u30C3\u30AF\u3057\u307E\u305B\u3093\u3002\u30B9\u30BF\u30A4\u30EB\u3084\u578B\u306E\u554F\u984C\u304C\u81EA\u52D5\u7684\u306B\u306F\u691C\u51FA\u3055\u308C\u307E\u305B\u3093\u3002`,analysisUnverified:t=>`\u5909\u66F4\u306E\u5206\u6790\u306E\u4E00\u90E8\u3092\u691C\u8A3C\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\uFF08\u672A\u89E3\u6C7A\u306E\u30C1\u30A7\u30C3\u30AF ${t} \u4EF6\uFF09\u3002\u8A72\u5F53\u3059\u308B\u4E3B\u5F35\u306F\u672A\u78BA\u8A8D\u3068\u3057\u3066\u6271\u3044\u3001\u30C6\u30B9\u30C8\u3092\u8A08\u753B\u3057\u307E\u3057\u305F\u3002`,unitTestsNotRun:t=>`Testbot \u306F\u9078\u629E\u3057\u305F\u30E6\u30CB\u30C3\u30C8\u30C6\u30B9\u30C8\u3092\u5B9F\u884C\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u3053\u3053\u306B\u3042\u308B\u30E6\u30CB\u30C3\u30C8\u30C6\u30B9\u30C8\u306E\u7D50\u679C\u306F Testbot \u81EA\u8EAB\u306E\u518D\u5B9F\u884C\u306B\u3088\u308B\u3082\u306E\u3067\u306F\u3042\u308A\u307E\u305B\u3093: ${t}`,downstreamNotChecked:t=>`\u672A\u5B9F\u884C: \u3053\u306E\u5909\u66F4\u304C\u5F71\u97FF\u3057\u3046\u308B\u3001\u30A2\u30D7\u30EA\u306E\u4ED6\u306E\u90E8\u5206\u306E\u78BA\u8A8D\u3067\u3059\u3002\u3053\u306E\u5909\u66F4\u81EA\u4F53\u306F\u305D\u306E\u52D5\u4F5C\u3092\u5909\u3048\u306A\u3044\u305F\u3081\u3001\u5909\u66F4\u306E\u691C\u8A3C\u306B\u306F\u4E0D\u8981\u3067\u3059\u3002${t}`,testsCouldNotRunHere:(t,e)=>`\u3053\u306E\u5909\u66F4\u306B\u306F ${t} \u4EF6\u306E\u30C6\u30B9\u30C8\u304C\u3042\u308A\u307E\u3059\u304C\u3001\u3053\u306E\u74B0\u5883\u3067\u306F\u5B9F\u884C\u3067\u304D\u306A\u304B\u3063\u305F\u305F\u3081\u7D50\u679C\u304C\u3042\u308A\u307E\u305B\u3093\uFF08\u30B9\u30AD\u30C3\u30D7\u3067\u306F\u3042\u308A\u307E\u305B\u3093\uFF09: ${e}`,modelProviderDenied:(t,e=!1)=>e?`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u304C\u547C\u3073\u51FA\u3057\u3092\u62D2\u5426\u3057\u307E\u3057\u305F\u3002\u3059\u3067\u306B\u5F97\u3089\u308C\u305F\u8A3C\u62E0\u306F\u3001\u3053\u306E\u5B9F\u884C\u306E\u7D50\u679C\u3092\u5224\u65AD\u3059\u308B\u306E\u306B\u5341\u5206\u3067\u3059\u3002`:`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u304C Testbot \u306E\u547C\u3073\u51FA\u3057\u3092\u62D2\u5426\u3057\u305F\u305F\u3081\u3001\u5B9F\u884C\u306F\u5B8C\u4E86\u524D\u306B\u505C\u6B62\u3057\u307E\u3057\u305F\u3002\u8A8D\u8A3C\u60C5\u5831\u3001\u6A29\u9650\u3001\u307E\u305F\u306F\u4F7F\u7528\u91CF\u306E\u4E0A\u9650\u306B\u3088\u308A\u30A2\u30AF\u30BB\u30B9\u304C\u62D2\u5426\u3055\u308C\u307E\u3057\u305F\u3002\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3078\u306E\u30A2\u30AF\u30BB\u30B9\u3092 Skyramp \u304C\u7BA1\u7406\u3057\u3066\u3044\u308B\u5834\u5408\u306F\u3001\u518D\u5B9F\u884C\u3059\u308B\u524D\u306B Skyramp \u30B5\u30DD\u30FC\u30C8\u306B\u304A\u554F\u3044\u5408\u308F\u305B\u304F\u3060\u3055\u3044\u3002\u3054\u81EA\u8EAB\u3067\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u7BA1\u7406\u3057\u3066\u3044\u308B\u5834\u5408\u306F\u3001\u305D\u306E\u7BA1\u7406\u8005\u306B\u30A2\u30AF\u30BB\u30B9\u307E\u305F\u306F\u4F7F\u7528\u91CF\u306E\u4E0A\u9650\u306E\u89E3\u6C7A\u3092\u4F9D\u983C\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u30B3\u30FC\u30C9\u3092\u5909\u66F4\u3059\u308B\u5FC5\u8981\u306F\u3042\u308A\u307E\u305B\u3093\u3002`,modelProviderUnavailable:(t,e=!1)=>e?`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u3092\u547C\u3073\u51FA\u3057\u6642\u306B\u5229\u7528\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u3059\u3067\u306B\u5F97\u3089\u308C\u305F\u8A3C\u62E0\u306F\u3001\u3053\u306E\u5B9F\u884C\u306E\u7D50\u679C\u3092\u5224\u65AD\u3059\u308B\u306E\u306B\u5341\u5206\u3067\u3059\u3002`:`\u30E2\u30C7\u30EB\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E ${t} \u3092 Testbot \u304C\u5229\u7528\u3067\u304D\u306A\u304B\u3063\u305F\u305F\u3081\u3001\u3053\u306E\u6BB5\u968E\u3092\u5B8C\u4E86\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u3059\u3067\u306B\u5F97\u3089\u308C\u305F\u7D50\u679C\u306F\u3053\u306E\u30EC\u30DD\u30FC\u30C8\u306B\u6B8B\u3063\u3066\u3044\u307E\u3059\u3002\u30B3\u30FC\u30C9\u3084 Testbot \u306E\u8A2D\u5B9A\u3092\u5909\u66F4\u3059\u308B\u5FC5\u8981\u306F\u3042\u308A\u307E\u305B\u3093\u3002\u3057\u3070\u3089\u304F\u3057\u3066\u304B\u3089\u518D\u5EA6\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002`},providerOutageHeadline:(t,e)=>`${t} \u306B\u63A5\u7D9A\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002Testbot \u306F ${e} \u56DE\u8A66\u884C\u3057\u307E\u3057\u305F\u304C\u5931\u6557\u3057\u307E\u3057\u305F\u3002`,providerOutageActionStatusPage:t=>`${t} \u3067\u72B6\u6CC1\u3092\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u30B5\u30FC\u30D3\u30B9\u304C\u5FA9\u65E7\u3057\u305F\u3089\u3001Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,providerRateLimitHeadline:t=>`${t} \u306E\u30EC\u30FC\u30C8\u5236\u9650\u306B\u3088\u308A\u5B9F\u884C\u304C\u4E2D\u65AD\u3055\u308C\u307E\u3057\u305F (HTTP 429)\u3002`,providerRateLimitAction:"\u5236\u9650\u304C\u89E3\u9664\u3055\u308C\u308B\u307E\u3067\u5F85\u3063\u3066\u304B\u3089\u3001Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u7E70\u308A\u8FD4\u3059\u5834\u5408\u306F\u3001\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u304C\u4F7F\u7528\u3059\u308B\u8A8D\u8A3C\u60C5\u5831\u306E\u30EC\u30FC\u30C8\u5236\u9650\u3092\u5F15\u304D\u4E0A\u3052\u308B\u304B\u3001\u540C\u6642\u306B\u5B9F\u884C\u3059\u308B PR \u306E\u6570\u3092\u6E1B\u3089\u3057\u3066\u304F\u3060\u3055\u3044\u3002",providerUsageLimitHeadline:t=>`${t} \u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u304C\u5229\u7528\u4E0A\u9650\u306B\u9054\u3057\u307E\u3057\u305F\u3002`,providerUsageLimitAction:"\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u306E\u8A8D\u8A3C\u60C5\u5831\u306B\u7D10\u3065\u304F\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u5229\u7528\u4E0A\u9650\u3092\u5F15\u304D\u4E0A\u3052\u3066\u304B\u3089\u3001Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002",providerAuthExpiredHeadline:t=>`\u5B9F\u884C\u4E2D\u306B\u3001Testbot \u304C ${t} \u3078\u63A5\u7D9A\u3059\u308B\u305F\u3081\u306E\u8A8D\u8A3C\u60C5\u5831\u306E\u6709\u52B9\u671F\u9650\u304C\u5207\u308C\u307E\u3057\u305F\u3002`,providerAuthExpiredAction:"\u8A8D\u8A3C\u60C5\u5831\u306E\u6709\u52B9\u671F\u9593\u306F\u56FA\u5B9A\u306E\u305F\u3081\u3001\u5B9F\u884C\u6642\u9593\u304C\u9577\u3044\u3068\u305D\u306E\u671F\u9593\u3092\u8D85\u3048\u308B\u3053\u3068\u304C\u3042\u308A\u307E\u3059\u3002Actions \u30BF\u30D6\u306E\u5B9F\u884C\u30DA\u30FC\u30B8\u304B\u3089\u3053\u306E\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u3092\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u3053\u306E\u30EA\u30DD\u30B8\u30C8\u30EA\u306E\u5B9F\u884C\u304C\u6709\u52B9\u671F\u9593\u3092\u5E38\u306B\u8D85\u3048\u308B\u5834\u5408\u306F\u3001\u30B8\u30E7\u30D6\u3054\u3068\u306B\u8A8D\u8A3C\u60C5\u5831\u3092\u767A\u884C\u3059\u308B\u304B\u3001\u5404\u30B8\u30E7\u30D6\u304C\u6709\u52B9\u671F\u9593\u5185\u306B\u53CE\u307E\u308B\u3088\u3046\u5B9F\u884C\u3092\u5206\u5272\u3057\u3066\u304F\u3060\u3055\u3044\u3002",providerTimeoutHeadline:t=>`Testbot \u306F\u5236\u9650\u6642\u9593 ${t} \u5206\u3092\u8D85\u3048\u305F\u305F\u3081\u505C\u6B62\u3055\u308C\u307E\u3057\u305F\u3002`,providerTimeoutAction:"\u3053\u306E\u30EA\u30DD\u30B8\u30C8\u30EA\u306E\u5B9F\u884C\u306B\u672C\u5F53\u306B\u6642\u9593\u304C\u5FC5\u8981\u306A\u5834\u5408\u306F\u3001\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u306E `testbotTimeout` \u5165\u529B\u5024\u3092\u5927\u304D\u304F\u3057\u3066\u304F\u3060\u3055\u3044\u3002",staged:{testsSourcePullRequest:t=>`\u30BD\u30FC\u30B9\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8 ${t} \u306E\u30C6\u30B9\u30C8`,requestedByPerson:t=>`${t} \u3055\u3093\u306E\u4F9D\u983C\u3067\u5B9F\u884C`,requestedByPolicy:t=>`\u691C\u8A3C\u30DD\u30EA\u30B7\u30FC ${t} \u306B\u3088\u308A\u5B9F\u884C`,noLiveApp:t=>`> \u26A0\uFE0F **\u3053\u306E\u5B9F\u884C\u3067\u306F\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\uFF08SUT\uFF09\u304C\u3042\u308A\u307E\u305B\u3093\u3067\u3057\u305F** \u2014 \u4EE5\u4E0B\u306E ${t} \u4EF6\u306E\u30C6\u30B9\u30C8\u306F**\u5B9F\u884C\u3055\u308C\u3066\u3044\u307E\u305B\u3093**\uFF08\u5B9F\u884C\u5BFE\u8C61\u306E\u30A2\u30D7\u30EA\u304C\u3042\u308A\u307E\u305B\u3093\u3067\u3057\u305F\uFF09\u3002\u7A3C\u50CD\u4E2D\u306E\u30A2\u30D7\u30EA\u306B\u5BFE\u3057\u3066\u5B9F\u884C\u3057\u3001\u5408\u683C\u3059\u308B\u3053\u3068\uFF08\u304A\u3088\u3073\u518D\u73FE\u30C6\u30B9\u30C8\u304C\u610F\u56F3\u3069\u304A\u308A\u5931\u6557\u3059\u308B\u3053\u3068\uFF09\u3092\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,unitTestsInFile:(t,e,n)=>`**${t}**: ${n?`${n} \u306E`:""}\u30E6\u30CB\u30C3\u30C8\u30C6\u30B9\u30C8 ${e} \u4EF6`,addedToExistingFile:"\u65E2\u5B58\u306E\u30C6\u30B9\u30C8\u30D5\u30A1\u30A4\u30EB\u306B\u8FFD\u52A0",testPackagesHeader:"### \u{1F4E6} \u3053\u308C\u3089\u306E\u30C6\u30B9\u30C8\u306E\u5B9F\u884C\u65B9\u6CD5",testPackageLine:(t,e)=>`\`${t}/\` \u306F Skyramp Testbot \u304C\u6240\u6709\u30FB\u4FDD\u5B88\u3059\u308B\u72EC\u7ACB\u3057\u305F\u30C6\u30B9\u30C8\u30D1\u30C3\u30B1\u30FC\u30B8\u3067\u3001\u72EC\u81EA\u306E\u30DE\u30CB\u30D5\u30A7\u30B9\u30C8\u3001\u30ED\u30C3\u30AF\u30D5\u30A1\u30A4\u30EB\u3001\u30E9\u30F3\u30CA\u30FC\u8A2D\u5B9A\u3092\u6301\u3061\u307E\u3059\u3002\`${e}\` \u3067\u5B9F\u884C\u3067\u304D\u307E\u3059\u3002\u3059\u3079\u3066\u306E\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u3067\u5B9F\u884C\u3059\u308B\u306B\u306F\u3001\u3053\u306E\u30B3\u30DE\u30F3\u30C9\u3092 CI \u306B\u8FFD\u52A0\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,appManifestsUntouched:"\u30A2\u30D7\u30EA\u30B1\u30FC\u30B7\u30E7\u30F3\u81EA\u8EAB\u306E\u30DE\u30CB\u30D5\u30A7\u30B9\u30C8\u3068\u30ED\u30C3\u30AF\u30D5\u30A1\u30A4\u30EB\u306F\u5909\u66F4\u3057\u3066\u3044\u307E\u305B\u3093\u3002",dependencyChangesHeader:"### \u{1F4E6} \u30A2\u30D7\u30EA\u30B1\u30FC\u30B7\u30E7\u30F3\u306E\u4F9D\u5B58\u95A2\u4FC2\u306E\u5909\u66F4",dependencyChangeLine:(t,e,n)=>`\`${e}\`\uFF08\u304A\u3088\u3073\u305D\u306E\u30ED\u30C3\u30AF\u30D5\u30A1\u30A4\u30EB\uFF09\u306B \`${t}\` \u3092\u8FFD\u52A0${n?`: ${n}`:""}`,testMaintenanceHeader:"\u2705 \u30C6\u30B9\u30C8\u30E1\u30F3\u30C6\u30CA\u30F3\u30B9",keptNot:"\u5909\u66F4\u305B\u305A\u7DAD\u6301 \u2014 \u898B\u9001\u3063\u305F\u64CD\u4F5C: ",declinedPlanned:"(\u4E88\u5B9A\u3057\u3066\u3044\u305F\u64CD\u4F5C\u3092\u898B\u9001\u308A: ",declinedMaintenanceHeader:"\u21A9\uFE0F \u898B\u9001\u3063\u305F\u30E1\u30F3\u30C6\u30CA\u30F3\u30B9",existingEvidenceHeader:"\u2705 \u65E2\u5B58\u306E\u30A8\u30D3\u30C7\u30F3\u30B9",trustedCheckPassed:(t,e)=>`\u4FE1\u983C\u6E08\u307F\u306E CI \u30C1\u30A7\u30C3\u30AF ${t} \u304C${e?` ${e} \u3067`:""}\u5408\u683C\u3057\u3001\u6B21\u3092\u78BA\u8A8D\u3057\u307E\u3057\u305F:`,testResultsHeader:"\u{1F9EA} \u30C6\u30B9\u30C8\u7D50\u679C",resultsTableHeader:"| \u30C6\u30B9\u30C8 ID | \u30C6\u30B9\u30C8\u7A2E\u5225 | \u30A8\u30F3\u30C9\u30DD\u30A4\u30F3\u30C8 | \u30B9\u30C6\u30FC\u30BF\u30B9 | \u8A73\u7D30 |",unitResultsTableHeader:"| \u30C6\u30B9\u30C8 ID | \u30C6\u30B9\u30C8\u7A2E\u5225 | \u30C6\u30B9\u30C8\u5BFE\u8C61\u306E\u30B3\u30FC\u30C9 | \u30C6\u30B9\u30C8 | \u30B1\u30FC\u30B9\u6570 | \u30B9\u30C6\u30FC\u30BF\u30B9 | \u8A73\u7D30 |",casesPassed:(t,e,n)=>`${e} \u4EF6\u4E2D ${t} \u4EF6\u5408\u683C${n?`\u3001${n} \u4EF6\u30B9\u30AD\u30C3\u30D7`:""}`,behaviourCoverageHeader:"\u{1F517} \u632F\u308B\u821E\u3044\u306E\u30AB\u30D0\u30EC\u30C3\u30B8",coverageCaption:(t,e,n,r)=>`\uFF08\u751F\u6210 ${t} \xB7 \u5909\u66F4 ${e} \xB7 \u691C\u8A3C ${n} \xB7 \u5B9F\u884C ${r}\uFF09`,coverageTableHeader:"| \u632F\u308B\u821E\u3044 | \u30BD\u30FC\u30B9 | \u30C6\u30B9\u30C8 | \u30E1\u30F3\u30C6\u30CA\u30F3\u30B9 |",writtenNotRun:"\u4F5C\u6210\u6E08\u307F\u30FB\u672A\u5B9F\u884C",issuesFoundHeader:"\u26A0\uFE0F \u691C\u51FA\u3055\u308C\u305F\u554F\u984C",caveatsHeader:"### \u26A0\uFE0F \u3053\u306E\u5B9F\u884C\u3067\u78BA\u8A8D\u3067\u304D\u306A\u304B\u3063\u305F\u3053\u3068",commentHeader:"### Skyramp Testbot",timedOut:"> \u26A0\uFE0F \u5B9F\u884C\u304C\u30BF\u30A4\u30E0\u30A2\u30A6\u30C8\u3057\u307E\u3057\u305F \u2014 \u4EE5\u4E0B\u306E\u7D50\u679C\u306F\u4E00\u90E8\u306E\u307F\u3067\u3059\u3002",stopReasons:{"pr-closed":"\u30D7\u30EB\u30EA\u30AF\u30A8\u30B9\u30C8\u304C\u30DE\u30FC\u30B8\u3055\u308C\u305A\u306B\u30AF\u30ED\u30FC\u30BA\u3055\u308C\u307E\u3057\u305F",cancelled:"\u30EF\u30FC\u30AF\u30D5\u30ED\u30FC\u304C\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u305F\u304B\u3001\u30E9\u30F3\u30CA\u30FC\u304C\u505C\u6B62\u3057\u307E\u3057\u305F","attempt-cancelled":"Skyramp \u3067\u3053\u306E\u5B9F\u884C\u304C\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u307E\u3057\u305F","attempt-closed":"Skyramp \u304C\u3053\u306E\u5B9F\u884C\u3092\u7D42\u4E86\u3057\u307E\u3057\u305F"},maintenanceActions:{update:"\u66F4\u65B0",regenerate:"\u518D\u751F\u6210",delete:"\u524A\u9664",verify:"\u691C\u8A3C",updated:"\u66F4\u65B0",regenerated:"\u518D\u751F\u6210",deleted:"\u524A\u9664",verified:"\u691C\u8A3C"},publishFailures:{push:"\u30D7\u30C3\u30B7\u30E5\u306B\u5931\u6557",auth:"\u8A8D\u8A3C\u30A8\u30E9\u30FC",conflict:"\u7AF6\u5408",unknown:"\u4E0D\u660E\u306A\u30A8\u30E9\u30FC"},stoppedEarly:(t,e)=>`> \u26A0\uFE0F \u5B9F\u884C\u304C\u9014\u4E2D\u3067\u505C\u6B62\u3057\u307E\u3057\u305F \u2014 ${t}\u3002\u4EE5\u4E0B\u306E\u7D50\u679C\u306F\u4E00\u90E8\u306E\u307F\u3067\u3059\u3002${e}`,viewInSkyramp:t=>` [Skyramp \u3067\u8868\u793A](${t})`,descriptionCut:(t,e,n)=>`_\u2026 \u6B8B\u308A\u306F\u7701\u7565\u3057\u307E\u3057\u305F${e===void 0?"\uFF08\u30C6\u30B9\u30C8\u7D50\u679C\u3092\u542B\u3080\uFF09":e?`\uFF08\u30C6\u30B9\u30C8\u7D50\u679C ${e} \u4EF6\u3092\u542B\u3080\uFF09`:""}\u3002Azure DevOps \u306E\u8AAC\u660E\u306F ${t} \u6587\u5B57\u307E\u3067\u3067\u3059\u3002${n?` [\u5B8C\u5168\u306A\u30EC\u30DD\u30FC\u30C8](${n})`:""}_`,setupRunEnds:{finished:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u304C\u5B8C\u4E86\u3057\u307E\u3057\u305F\u3002Skyramp \u304C\u7D50\u679C\u3092\u78BA\u8A8D\u3057\u3066\u3044\u307E\u3059\u3002",failed:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002",timedOut:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u304C\u6642\u9593\u5207\u308C\u306B\u306A\u308A\u307E\u3057\u305F\u3002",cancelledInSkyramp:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u306F Skyramp \u3067\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u307E\u3057\u305F\u3002",stoppedToResume:"\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u5B9F\u884C\u3092\u505C\u6B62\u3057\u307E\u3057\u305F\u3002Skyramp \u3067\u518D\u958B\u3067\u304D\u307E\u3059\u3002"},appUnreachable:t=>`Skyramp\uFF08${t}\uFF09\u306B\u63A5\u7D9A\u3067\u304D\u307E\u305B\u3093\u3002\u3057\u3070\u3089\u304F\u3057\u3066\u304B\u3089\u518D\u5EA6\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002`,couldNotStart:t=>`Skyramp Testbot \u3092\u958B\u59CB\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F: ${t}`,assembledAfterFailedChecks:t=>`> \u26A0\uFE0F \u4F5C\u6210\u30B9\u30C6\u30C3\u30D7\u304C\u30C1\u30A7\u30C3\u30AF\u306B\u5408\u683C\u3057\u306A\u304B\u3063\u305F\u305F\u3081\u3001\u3053\u306E\u30EC\u30DD\u30FC\u30C8\u306F\u81EA\u52D5\u3067\u7D44\u307F\u7ACB\u3066\u3089\u308C\u307E\u3057\u305F\u3002${t} \u4EF6\u306E\u30C1\u30A7\u30C3\u30AF\u304C\u672A\u9054\u6210\u3067\u3059 \u2014 \u8A73\u7D30\u306F\u5B9F\u884C\u30ED\u30B0\u3092\u53C2\u7167\u3057\u3066\u304F\u3060\u3055\u3044\u3002`,testbotPrLine:(t,e,n)=>`Testbot PR${t?`\uFF08${t}\uFF09`:""}: [${e}](${n})`,viewRun:t=>`_[\u5B9F\u884C\u3092\u8868\u793A](${t})_`,testsPrNotOpened:(t,e)=>`\u30C6\u30B9\u30C8 PR \u3092\u4F5C\u6210\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\uFF08${t}\uFF09\u3002\u30C6\u30B9\u30C8\u306F\u30D6\u30E9\u30F3\u30C1 \`${e}\` \u306B\u30D7\u30C3\u30B7\u30E5\u3055\u308C\u3066\u3044\u307E\u3059\u3002`,testsNotDelivered:t=>`\u30C6\u30B9\u30C8\u3092\u914D\u4FE1\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F: ${t}`,testsNotPushed:(t,e)=>`\u30C6\u30B9\u30C8\u3092\u30D7\u30C3\u30B7\u30E5\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\uFF08${t}\uFF09\u3002\u30C6\u30B9\u30C8\u306F\u30ED\u30FC\u30AB\u30EB\u30D6\u30E9\u30F3\u30C1 \`${e}\` \u306B\u6B8B\u3063\u3066\u3044\u307E\u3059\u3002`,testsPrRetargeted:t=>`\u30C6\u30B9\u30C8\u306E\u751F\u6210\u4E2D\u306B\u958B\u767A PR \u304C\u30DE\u30FC\u30B8\u3055\u308C\u307E\u3057\u305F \u2014 \u30C6\u30B9\u30C8 PR \u306F\u4EE3\u308F\u308A\u306B\u30D9\u30FC\u30B9\u30D6\u30E9\u30F3\u30C1${t?`\uFF08\`${t}\`\uFF09`:""}\u3092\u5BFE\u8C61\u306B\u3057\u3066\u3044\u307E\u3059\u3002`,testsPrUnchanged:"\u3053\u306E\u30D7\u30C3\u30B7\u30E5\u3067\u306F\u65B0\u3057\u3044\u30C6\u30B9\u30C8\u306E\u5909\u66F4\u306F\u4E0D\u8981\u3067\u3057\u305F\u3002\u4EE5\u4E0B\u306E\u30C6\u30B9\u30C8 PR \u306F\u4EE5\u524D\u306E\u5B9F\u884C\u306E\u3082\u306E\u3067\u3001\u305D\u306E\u307E\u307E\u306B\u3057\u3066\u3044\u307E\u3059\u3002",committedNoPr:t=>`\u30C6\u30B9\u30C8\u306F\u30B3\u30DF\u30C3\u30C8\u3055\u308C\u307E\u3057\u305F\u304C\u3001PR \u306F\u4F5C\u6210\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F: ${t}\u3002`,testsNotProposed:t=>`\u30C6\u30B9\u30C8\u306F PR \u3068\u3057\u3066\u63D0\u6848\u3055\u308C\u307E\u305B\u3093\u3067\u3057\u305F: ${t}\u3002`}};var am=(n=>(n.En="en",n.Ja="ja",n))(am||{}),gY={en:_v,ja:Uv},mY="en";function cm(t){let e=t.trim().toLowerCase();if(e==="")return"en";let n=Object.values(am);return n.includes(e)?e:(Pe(`Invalid language '${t}'. Supported: ${n.join(", ")}. Falling back to 'en'.`),"en")}function Jn(){return gY[mY]}var Ad=(c=>(c.ProviderOutage="provider_outage",c.ProviderRateLimit="provider_rate_limit",c.ProviderUsageLimit="provider_usage_limit",c.ProviderAuthExpired="provider_auth_expired",c.Timeout="timeout",c.NoReport="no_report",c.RenderFailure="render_failure",c))(Ad||{});(e=>{function t(n,r){switch(n){case"provider_outage":return{headline:Jn().providerOutageHeadline(r.provider.name,r.maxRetries),action:Jn().providerOutageActionStatusPage(r.provider.statusUrl)};case"provider_rate_limit":return{headline:Jn().providerRateLimitHeadline(r.provider.name),action:Jn().providerRateLimitAction};case"provider_usage_limit":return{headline:Jn().providerUsageLimitHeadline(r.provider.name),action:Jn().providerUsageLimitAction};case"provider_auth_expired":return{headline:Jn().providerAuthExpiredHeadline(r.provider.name),action:Jn().providerAuthExpiredAction};case"timeout":return{headline:Jn().providerTimeoutHeadline(r.timeoutMinutes),action:Jn().providerTimeoutAction};case"no_report":case"render_failure":return}}e.buildNotice=t})(Ad||={});var um=(n=>(n.SameBranch="same-branch",n.SeparateBranch="separate-branch",n))(um||{});var Lv=(n=>(n.Sonnet="sonnet",n.Opus="opus",n))(Lv||{}),yY="opus";function Am(t){return Object.values(Lv).includes(t)}function Pv(t){let e=(t??"").trim();if(e==="")return yY;let n=e.toLowerCase();return Am(n)?n:e}var ld=(i=>(i.Low="low",i.Medium="medium",i.High="high",i.XHigh="xhigh",i.Max="max",i))(ld||{}),dd="high";function Ov(t){return Object.values(ld).includes(t)}var $v=5;function EY(t){let e=t.split(/\r?\n/).map(n=>n.trim()).filter(Boolean);if(e.length>$v)throw new Error(`relatedRepoPaths supports at most ${$v} entries (got ${e.length}); the cap limits how much cross-repo context is loaded to avoid overflowing Testbot's context window.`);return e}function CY(t){let e=t.trim().toLowerCase();return e===""?"separate-branch":Object.values(um).includes(e)?e:(Pe(`Invalid generatedTestsMode '${t}'. Falling back to 'separate-branch'.`),"separate-branch")}function IY(t){let e=(t??"").trim();if(e!==""){if(/^(?:[1-9]|10)$/.test(e))return Number(e);Pe(`Ignoring perTestMaxFixAttempts="${t}": expected a whole number from 1 to 10; the Skyramp MCP default applies`)}}function BY(t){let e=(t??"").trim().toLowerCase();return e===""?dd:Ov(e)?e:(Pe(`Ignoring effort="${t}": expected one of ${Object.values(ld).join(", ")}; using "${dd}"`),dd)}function Vv(){let t=Pv(he("model"));return Am(t)||Pe(`model '${t}' is not a tested alias (sonnet, opus); passing it to the agent verbatim as a raw model id.`),{skyrampLicenseFile:he("skyrampLicenseFile"),cursorApiKey:he("cursorApiKey"),copilotApiKey:he("copilotApiKey"),anthropicApiKey:he("anthropicApiKey"),useBedrock:vs("useBedrock"),awsRegion:he("awsRegion"),useLocalAuth:he("useLocalAuth").toLowerCase()==="true",model:t,effort:BY(he("effort")),targetSetupCommand:he("targetSetupCommand"),authTokenCommand:he("authTokenCommand"),uiCredentials:he("uiCredentials"),targetTeardownCommand:he("targetTeardownCommand"),skipTargetTeardown:vs("skipTargetTeardown"),skyrampExecutorVersion:he("skyrampExecutorVersion"),skyrampMcpVersion:he("skyrampMcpVersion"),skyrampMcpSource:he("skyrampMcpSource"),skyrampMcpGithubToken:he("skyrampMcpGithubToken"),skyrampMcpGithubRef:he("skyrampMcpGithubRef"),nodeVersion:he("nodeVersion"),skipTargetSetup:vs("skipTargetSetup"),targetReadyCheckCommand:he("targetReadyCheckCommand"),targetReadyCheckTimeout:(()=>{let n=parseInt(he("targetReadyCheckTimeout"),10)||1800;return n<1?(Pe(`targetReadyCheckTimeout must be at least 1 second, got ${n}. Using 1s.`),1):n})(),targetReadyCheckInterval:(()=>{let n=parseInt(he("targetReadyCheckInterval"),10),r=isNaN(n)?30:n;return r<1?(Pe(`targetReadyCheckInterval must be at least 1 second, got ${r}. Using 1s.`),1):r})(),targetReadyCheckDiagnosticsCommand:(()=>{let n=he("targetReadyCheckDiagnosticsCommand");return n.trim().toLowerCase()==="none"?"":n})(),workingDirectory:he("workingDirectory"),autoCommit:vs("autoCommit"),commitMessage:he("commitMessage"),generatedTestsMode:CY(he("generatedTestsMode")),postPrComment:vs("postPrComment"),testExecutionTimeout:parseInt(he("testExecutionTimeout"),10)||300,maxRecommendations:(()=>{let n=parseInt(he("maxRecommendations"),10);return isNaN(n)?void 0:Math.max(0,n)})(),maxGenerate:(()=>{let n=parseInt(he("maxGenerate"),10);return isNaN(n)?void 0:Math.max(0,n)})(),perTestMaxFixAttempts:IY(he("perTestMaxFixAttempts")),testbotMaxRetries:parseInt(he("testbotMaxRetries"),10)||3,testbotRetryDelay:parseInt(he("testbotRetryDelay"),10)||10,testbotTimeout:parseInt(he("testbotTimeout"),10)||60,targetSetupRetries:parseInt(he("targetSetupRetries"),10)||3,targetSetupRetryDelay:parseInt(he("targetSetupRetryDelay"),10)||10,authTokenRetries:(()=>{let n=parseInt(he("authTokenRetries"),10);return Number.isFinite(n)&&n>=1?n:6})(),authTokenRetryDelay:(()=>{let n=parseInt(he("authTokenRetryDelay"),10);return Number.isFinite(n)&&n>=0?n:10})(),reportCollapsed:vs("reportCollapsed"),language:cm(he("language")),enableDebug:vs("enableDebug"),testRepoPath:he("testRepoPath")||void 0,relatedRepoPaths:EY(he("relatedRepoPaths")),allowedAuthors:he("allowedAuthors").split(/\r?\n/).map(n=>n.trim()).filter(Boolean)}}var QY={useBedrock:"false",skipTargetTeardown:"false",skyrampMcpSource:"npm",skyrampMcpGithubRef:"main",nodeVersion:"lts/*",skipTargetSetup:"false",targetReadyCheckTimeout:"1800",targetReadyCheckInterval:"30",targetReadyCheckDiagnosticsCommand:`docker ps -a --format 'table {{.Names}} {{.Status}} {{.Ports}}' && docker ps -a --format '{{.Names}}' | while read name; do [ -n "$name" ] && echo "--- logs $name (last 30) ---" && docker logs --tail 30 "$name"; done`,workingDirectory:".",autoCommit:"true",commitMessage:"Skyramp Testbot: test maintenance suggestions",generatedTestsMode:"separate-branch",pipeline:"staged",postPrComment:"true",testbotMaxRetries:"3",testbotRetryDelay:"10",testExecutionTimeout:"300",testbotTimeout:"60",targetSetupRetries:"3",targetSetupRetryDelay:"10",authTokenRetries:"6",authTokenRetryDelay:"10",reportCollapsed:"true",language:"en",enableDebug:"true",sutSetupMode:"none"};function Gv(t=process.env){for(let[e,n]of Object.entries(QY)){let r=`INPUT_${e.replace(/ /g,"_").toUpperCase()}`;(t[r]??"").trim()===""&&(t[r]=n)}}Dt();var Tx=Re(require("path"));var ba=require("fs"),Jr=Re(require("path"),1),_R=require("child_process"),UR=require("util");function wY(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Bt={},pd={},Fs={},Hv;function lu(){if(Hv)return Fs;Hv=1;function t(a){return typeof a>"u"||a===null}function e(a){return typeof a=="object"&&a!==null}function n(a){return Array.isArray(a)?a:t(a)?[]:[a]}function r(a,c){if(c){let A=Object.keys(c);for(let l=0,p=A.length;l<p;l+=1){let h=A[l];a[h]=c[h]}}return a}function s(a,c){let A="";for(let l=0;l<c;l+=1)A+=a;return A}function i(a){return a===0&&Number.NEGATIVE_INFINITY===1/a}return Fs.isNothing=t,Fs.isObject=e,Fs.toArray=n,Fs.repeat=s,Fs.isNegativeZero=i,Fs.extend=r,Fs}var lm,Yv;function du(){if(Yv)return lm;Yv=1;function t(n,r){let s="",i=n.reason||"(unknown reason)";return n.mark?(n.mark.name&&(s+='in "'+n.mark.name+'" '),s+="("+(n.mark.line+1)+":"+(n.mark.column+1)+")",!r&&n.mark.snippet&&(s+=`
52
52
 
53
53
  `+n.mark.snippet),i+" "+s):i}function e(n,r){Error.call(this),this.name="YAMLException",this.reason=n,this.mark=r,this.message=t(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e.prototype.toString=function(r){return this.name+": "+t(this,r)},lm=e,lm}var dm,qv;function bY(){if(qv)return dm;qv=1;let t=lu();function e(s,i,a,c,A){let l="",p="",h=Math.floor(A/2)-1;return c-i>h&&(l=" ... ",i=c-h+l.length),a-c>h&&(p=" ...",a=c+h-p.length),{str:l+s.slice(i,a).replace(/\t/g,"\u2192")+p,pos:c-i+l.length}}function n(s,i){return t.repeat(" ",i-s.length)+s}function r(s,i){if(i=Object.create(i||null),!s.buffer)return null;i.maxLength||(i.maxLength=79),typeof i.indent!="number"&&(i.indent=1),typeof i.linesBefore!="number"&&(i.linesBefore=3),typeof i.linesAfter!="number"&&(i.linesAfter=2);let a=/\r?\n|\r|\0/g,c=[0],A=[],l,p=-1;for(;l=a.exec(s.buffer);)A.push(l.index),c.push(l.index+l[0].length),s.position<=l.index&&p<0&&(p=c.length-2);p<0&&(p=c.length-1);let h="",g=Math.min(s.line+i.linesAfter,A.length).toString().length,C=i.maxLength-(i.indent+g+3);for(let v=1;v<=i.linesBefore&&!(p-v<0);v++){let T=e(s.buffer,c[p-v],A[p-v],s.position-(c[p]-c[p-v]),C);h=t.repeat(" ",i.indent)+n((s.line-v+1).toString(),g)+" | "+T.str+`
54
54
  `+h}let S=e(s.buffer,c[p],A[p],s.position,C);h+=t.repeat(" ",i.indent)+n((s.line+1).toString(),g)+" | "+S.str+`
@@ -117,7 +117,7 @@ Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}fun
117
117
  `)){let n=e.trim();if(n)try{let r=JSON.parse(n);if(r.type==="system"&&r.subtype==="init"&&Array.isArray(r.mcp_servers))return Object.fromEntries(r.mcp_servers.filter(s=>typeof s.name=="string").map(s=>[s.name,typeof s.status=="string"?s.status:"unknown"]))}catch{}}return{}}function g0(t){let e=$j(t).skyramp;return e===void 0||e==="connected"}function Vj(t){if(!po.existsSync(t))return[];let e=[];for(let n of po.readFileSync(t,"utf-8").split(`
118
118
  `)){let r=n.trim();if(!r)continue;let s;try{s=JSON.parse(r)}catch{continue}let i=s.message?.content;Array.isArray(i)&&e.push(...i)}return e}var m0=Re(require("path"));var bt=u.string().trim().min(1),by=(n=>(n.TestbotManaged="testbot_managed",n.CustomerDeployed="customer_deployed",n))(by||{}),_d=[".skyramp/sut/setup.sh",".skyramp/sut/teardown.sh"],Sy=u.object({schemaVersion:u.literal(1),type:u.nativeEnum(by).optional(),status:u.enum(["ready","blocked"]),environment:Oa.optional(),components:u.array(u.object({name:bt,repository:bt.describe(`owner/repo, or "${zt}" for a customer-deployed component no repository builds`),healthy:u.boolean(),url:u.string().min(1).nullable(),...hy,credentials:u.array(u.string().regex(La)).max(50).optional(),deployed:bt.nullable().optional().describe("customer_deployed only: the revision the component runs, as setup read it (WF-SETUP-22's Deployed now), or null when it could not tell")}).strict()),suites:u.array(u.object({framework:bt,file:bt,result:u.enum(["pass","fail","error"])}).strict()),inputsUsed:u.array(bt),inputsUsedHow:u.array(u.object({input:bt,how:bt}).strict()).optional(),inputsNotUsed:u.array(u.object({input:bt,reason:bt}).strict()),blockers:u.array(u.object({component:bt,problem:bt,evidence:bt,fix:bt}).strict()),replay:u.object({outcome:bt,durationSeconds:u.number().nonnegative().nullable()}).strict().nullable(),files:u.array(u.object({path:bt,content:u.string()}).strict())}).strict().superRefine((t,e)=>{t.inputsUsedHow?.forEach((s,i)=>{t.inputsUsed.includes(s.input)||e.addIssue({code:u.ZodIssueCode.custom,path:["inputsUsedHow",i,"input"],message:"not one of inputsUsed"})}),t.components.forEach((s,i)=>{s.credentials&&new Set(s.credentials).size!==s.credentials.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["components",i,"credentials"],message:"names a credential twice"})});let n=t.type==="customer_deployed";n!==(t.environment!==void 0)&&e.addIssue({code:u.ZodIssueCode.custom,path:["environment"],message:"an environment exactly when the plan's type is customer_deployed"}),t.environment&&new Set(t.environment.credentials).size!==t.environment.credentials.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["environment","credentials"],message:"names a credential twice"});let r=new Set(t.components.map(s=>s.name));if(t.environment?.revisionSources.forEach((s,i)=>{s.components.forEach((a,c)=>{r.has(a)||e.addIssue({code:u.ZodIssueCode.custom,path:["environment","revisionSources",i,"components",c],message:"not one of components"})})}),t.components.forEach((s,i)=>{s.deployed!==void 0!==n&&e.addIssue({code:u.ZodIssueCode.custom,path:["components",i,"deployed"],message:"what a component runs exactly when the plan is customer_deployed"}),s.repository===zt&&!n&&e.addIssue({code:u.ZodIssueCode.custom,path:["components",i,"repository"],message:`only a customer_deployed component is ${zt}`})}),n&&(t.components.forEach((s,i)=>{t.components.findIndex(a=>a.name===s.name)!==i&&e.addIssue({code:u.ZodIssueCode.custom,path:["components",i,"name"],message:"names a component twice"})}),t.replay!==null&&e.addIssue({code:u.ZodIssueCode.custom,path:["replay"],message:"a customer_deployed plan is never replayed"}),t.files.forEach((s,i)=>{_d.includes(s.path)&&e.addIssue({code:u.ZodIssueCode.custom,path:["files",i,"path"],message:"a customer_deployed plan has no script that starts or stops the system"})})),n&&t.status==="ready"){let s=new Set(t.environment?.revisionSources.flatMap(i=>i.components));t.components.forEach((i,a)=>{i.repository!==zt&&!s.has(i.name)&&e.addIssue({code:u.ZodIssueCode.custom,path:["components",a,"name"],message:"a ready customer_deployed plan reads what every component a repository builds runs"})})}});var K5=["clean","recipe-drift"];function Ru(t){let e=m0.posix.normalize(t);return e===t&&(e===".skyramp/workspace.yml"||e.startsWith(".skyramp/sut/")&&e.length>13)}var ky=[".skyramp/sut",".skyramp/workspace.yml"];var sX=["--",":/",...ky.map(t=>`:(exclude)${t}`)];var Gj=u.object({route:u.string().describe('the page this step happens on, e.g. "/products/:id"'),action:u.string().describe('what the user does there, through the UI, e.g. "clicks Add to cart"'),clauses:u.array(u.string()).optional().describe("the plan clause ids this step exercises"),check:u.string().optional().describe("what the user then sees that shows the step worked; the test asserts it")}),xu=(n=>(n.InProcess="in-process",n.Browser="browser",n))(xu||{}),y0=(r=>(r.Spec="spec",r.PrDescription="pr-description",r.Inferred="inferred",r))(y0||{}),E0=u.object({id:u.string().describe('e.g. "J1"'),name:u.string().describe(`the flow in a user's words, e.g. "buy a product with a coupon"`),entry:u.string().describe("the route the user starts the flow on: the app's normal starting page for it, never a deep link into its middle"),steps:u.array(Gj).describe("every step, in order, from the entry page to the outcome: at least two"),outcome:u.string().describe("what the user sees at the end that shows the flow worked: every part of it"),finishes:u.string().optional().describe('the user action that completes the task, verb first, e.g. "places the order"; the journey walks on to it'),kind:u.nativeEnum(xu).optional().describe("in-process when the repo's in-process tests (components, app routes) can walk the whole flow and check it; else browser"),source:u.nativeEnum(y0).optional().describe("spec or pr-description when one describes this flow (quote it under evidence), else inferred"),evidence:u.string().optional().describe("for spec or pr-description: its words that describe the flow"),testFile:u.string().describe("the browser test file it goes in, beside the repo's existing e2e tests")}),Ud=u.object({journey:u.string().describe("the plan's journey id"),file:u.string().describe("the browser test file that walks it"),brokeAt:u.object({step:u.number().int().describe("the 1-based step whose check failed first"),expected:u.string(),actual:u.string().describe("what the app did instead, from the runner's output"),notReached:u.array(u.number().int()).optional().describe("later steps the test could not get to")}).optional().describe("only when the journey's test failed on a check: where"),test:u.string().describe("the title of the one test in that file that walks it end to end")});var Ry=(s=>(s.RestApi="rest-api",s.Frontend="frontend",s.FullStack="full-stack",s.Other="other",s))(Ry||{}),Tu=(s=>(s.Critical="critical",s.High="high",s.Medium="medium",s.Low="low",s))(Tu||{}),Ld=(r=>(r.Suspected="suspected",r.Latent="latent",r.Refuted="refuted",r))(Ld||{}),I0=(r=>(r.Skyramp="skyramp",r.External="external",r.Unknown="unknown",r))(I0||{}),B0=(s=>(s.Cascade="cascade",s.Restrict="restrict",s.Orphan="orphan",s.Unknown="unknown",s))(B0||{}),Va=(s=>(s.RequirementReference="requirement-reference",s.Spec="spec",s.PrDescription="pr-description",s.CouldBreak="could-break",s))(Va||{}),Fe=u.string().trim().min(1),Ga=Fe.describe("file:line"),C0=t=>Fe.refine(e=>e.length<=400,e=>({message:`is ${e.length} characters, over the 400 cap \u2014 ${t}`})),Du=Fe.optional().describe('multi-repo only: the OTHER checkout this lives in \u2014 its "owner/repo" slug, or the directory name if the run discovered it; omit for the working checkout'),vy=u.object({method:Fe,path:Fe,service:u.string().optional(),evidence:Ga,repository:Du}),Hj=u.object({id:Fe.describe("short-slug, e.g. R9"),statement:Fe.max(400,"exceeds 400 characters \u2014 state the requirement, do not paste the spec section").describe("a testable obligation, not a summary"),source:u.nativeEnum(Va).describe("spec outranks pr-description when both state it"),evidence:Fe.describe("spec: file:line or a section locator. pr-description: the quoted phrase it comes from.")}),Yj=u.object({id:Fe.describe("short-slug"),statement:Fe.max(400,"exceeds 400 characters \u2014 state the behaviour, do not paste the code").describe("what the change makes true"),surface:Fe.describe("METHOD /path, or a component/page name"),evidence:Fe.describe("file:line from the diff that introduces it"),repository:Du,satisfies:u.array(Fe).optional().describe("requirement ids (from `requirements`) this behaviour correctly implements \u2014 a requirement met only in part is ALSO named by the finding that shows the rest (conflictsWith)")}),qj=u.object({id:Fe.describe("short-slug"),file:Fe,line:u.number().optional(),claim:C0("shorten it to the one sentence that states the defect, and move the supporting detail into `evidence`"),severity:u.nativeEnum(Tu),evidence:C0("cite the file:line and the one line that shows it, rather than reproducing the surrounding code").describe("quoted diff/code line"),status:u.nativeEnum(Ld),repository:Du,conflictsWith:u.array(Fe).optional().describe("requirement ids (from `requirements`) this defect contradicts or leaves unimplemented \u2014 a lower-precedence source (the diff, or the PR description) lost")}),jj=u.object({name:Fe,language:u.string().optional(),framework:u.string().optional(),evidence:Ga,repository:Du}),Jj=u.object({dir:Fe,framework:u.string().optional(),kind:u.nativeEnum(I0),evidence:Ga,repository:Du}),Wj=u.object({from:Fe,to:Fe,onDelete:u.nativeEnum(B0),evidence:Ga}),zj=u.object({entity:Fe,field:Fe,values:u.array(u.string()),evidence:Ga}),Kj=u.object({entities:u.array(u.object({name:Fe,evidence:Ga})),references:u.array(Wj).describe("INBOUND references \u2014 what still points at an entity when it is deleted"),stateFields:u.array(zj)}),hX=u.object({schemaVersion:u.literal(1),repository:u.object({path:Fe.describe("absolute repo path"),currentBranch:Fe,baseBranch:Fe}),project:u.object({type:u.nativeEnum(Ry),primaryLanguage:Fe,languages:u.array(u.string()),frameworks:u.array(u.string())}),services:u.array(jj),infrastructure:u.object({containerized:u.boolean(),hasDockerCompose:u.boolean(),composeFiles:u.array(u.string()),hasCiCd:u.boolean()}),diff:u.object({changedFiles:u.array(u.string()).describe("as git reports them; a file in another checkout may carry that repo's name"),nonApplicationOnly:u.boolean(),summary:Fe.describe("\u2264400 chars")}),endpoints:u.object({new:u.array(vy),modified:u.array(vy),removed:u.array(vy)}),existingTests:u.object({locations:u.array(Jj)}),entityMap:Kj,requirements:u.array(Hj).describe("from a spec (attached or linked) and/or the PR description; empty when neither states a testable obligation"),behaviors:u.array(Yj),findings:u.array(qj),unexamined:u.array(u.string()).describe("files or areas outside this change you did not open"),summary:Fe.describe("one paragraph on what this change does and its test-relevant risk")});var Pd=(n=>(n.Skyramp="skyramp",n.Llm="llm",n))(Pd||{}),ss=u.string().trim().min(1),Zj=u.object({case:ss.describe("recommend id this assertion enforces"),evidence:ss.describe("the exact assertion line from the file that checks that case's observable")}),xy=u.object({kind:u.nativeEnum(Id).describe("seed: data the test creates in the app; runtime_mock: a mock on a Skyramp worker, which other tests reach too; env_override: an env value the app runs with. A stub inside the test's own process, such as a browser page's route, is none of these"),target:ss.describe("the dependency, endpoint or data it affects"),mechanism:u.nativeEnum(Bd).describe("test_code: the test applies and undoes it; skyramp_mocker: a mock the test applies on a Skyramp worker; recipe_override: the mocker cannot reach the dependency (its URL is fixed in the build)"),detail:ss.describe("what it sets up"),worker:ss.optional().describe("skyramp_mocker: host:port of the worker the test applies the mock to (default localhost:35142)"),cleanup:ss.optional().describe("seed: a command, without a shell, that removes the data when the test does not")}),Xj=u.object({file:ss.describe("staged path under .skyramp/staged/"),source:u.nativeEnum(Pd),language:ss,covers:u.array(u.string()).min(1,"must be a non-empty array of recommend ids").describe("recommend ids this test covers"),assertions:u.array(Zj).min(1,"must be a non-empty array").describe("one per case covered, citing the real line"),context:u.array(xy).optional().describe("what the test sets up against the running app, in order: data it seeds, Skyramp mocks it applies, env overrides; omit when none")}),Ty=u.object({schemaVersion:u.literal(1),tests:u.array(Xj),deferredUi:u.array(u.string()).describe("recommend ui ids left for the UI stage (generate) \u2014 [] for generate-ui"),summary:ss.describe("one paragraph")});var is=u.string().trim().min(1),Nu=72,eJ=u.object({repository:is.optional().describe("owner/repo of the checkout this lint ran in, when the run has several; omit for the working checkout"),tool:u.string(),command:u.string().describe("the exact command you ran, scoped to the changed files"),clean:u.boolean(),fixed:u.array(u.string()).optional().describe("files you fixed"),uncovered:u.array(u.string()).describe("changed/new files this linter's own config does not match (wrong extension, wrong directory) \u2014 so `clean` never examined them, even though CI may still execute them. Empty array, not omitted, when every changed/new file IS covered.")}),QX=u.object({schemaVersion:u.literal(1),lint:u.array(eJ).min(1).describe("one entry per checkout this run wrote tests in, each run from that checkout"),fileConventions:u.object({ok:u.boolean(),notes:u.string().optional()}),ciReadiness:u.object({covered:u.boolean().describe("will the repo's CI run these tests?"),notes:u.string().optional()}),dependencies:u.object({added:u.array(u.object({package:u.string(),manifest:u.string(),repository:is.optional().describe("owner/repo of the manifest's checkout; omit for the working checkout"),reason:is.optional().describe("why the test must run inside the application's own test environment, so its manifest had to change \u2014 required for every entry")})).describe("every package added to an APPLICATION manifest (an exception, surfaced in the report); never the Testbot test package's own")}),support:u.array(u.object({file:is,repository:is.optional().describe("owner/repo of the file's checkout; omit for the working checkout")})).optional().describe("the files the tests need besides themselves (helper modules, page objects, fixtures, snapshots), delivered with them"),commit:u.object({message:is.refine(t=>t.split(`
119
119
  `)[0].length<=Nu,{message:`subject line must be <= ${Nu} chars`})}),pr:u.object({title:is.max(Nu,`must be <= ${Nu} chars`),body:is}),ready:u.boolean().describe("a statement of fact: true only if the tests are fit to commit as they stand"),blockers:u.array(u.string()).describe("what blocks the commit \u2014 required non-empty when ready is false"),summary:is.describe("one paragraph")});var qs=Re(require("fs")),qa=Re(require("path")),v0=require("child_process");var Zn="{junit}",w0=(r=>(r.Junit="junit",r.Trx="trx",r.GoTestJson="go-test-json",r))(w0||{}),b0=(e=>(e.Minitest="minitest",e))(b0||{}),Q0=u.string().trim().min(1),Ha=u.object({cwd:Q0.describe('repo-relative directory the command starts in ("." for the root)'),argv:u.array(Q0).min(1).describe(`the command as separate arguments, run without a shell; for a junit or trx report an argument or env value holds ${Zn}, where the report is written (not for Maven or Gradle, whose build writes its own)`),env:u.record(u.string(),u.string()).optional().describe("plain test or reporter settings beyond the repository's CI test job (RAILS_ENV=test, PLAYWRIGHT_JUNIT_OUTPUT_FILE={junit}); never a credential, PATH, or a tool's install path"),report:u.object({format:u.nativeEnum(w0).describe(`junit (JUnit XML to ${Zn}), trx (to ${Zn}), or go-test-json (go test -json on the command's output)`),reporter:u.nativeEnum(b0).optional().describe("a reporter Testbot loads for a runner that writes no report: minitest")}).optional().describe("the report the command writes; junit when omitted")});var Ya="a framework other than pytest, jest, vitest and node --test (go test, rails test, mvn, dotnet test), or one the repository's test script runs through another command (ng test, nx test)",kX=`pytest, Jest, Vitest and node --test tests run as the run already knows them, unless the repository's test script runs them through another command (ng test, nx test), which may be the only one that compiles them. A test in any other framework, or one run that way, also gives "run": the repository's own command for only those tests, from the directory the repository runs it in, as separate arguments without a shell. Its "report" says what the runner writes: junit (JUnit XML to ${Zn} in the reporter's argument or env setting), trx (a TRX file to ${Zn}, which every dotnet test writes with its built-in logger), or go-test-json (go test -json, read from the command's output). A Maven or Gradle command names no ${Zn}: its build writes JUnit XML to its own report directory, which the run reads. Use a reporter the repository already has, or one of those; a reporter or converter the command fetches is the version the repository pins, or else its latest release (an older one may not build with the repository's toolchain). For minitest, which writes none, give report.reporter "minitest" and the run fills ${Zn} itself. A setting the tests or reporter read goes in "env" (RAILS_ENV=test, or PLAYWRIGHT_JUNIT_OUTPUT_FILE=${Zn} with playwright test --reporter=junit): the run sets it, so never wrap the command in a shell to set one. The run replaces ${Zn} in argv and env with its report path, executes the command, and reads that report.`;var ho=(s=>(s.ExistingEvidenceSufficient="existing_evidence_sufficient",s.TargetedUnit="targeted_unit",s.RuntimeRequired="runtime_required",s.BlockedPreflight="blocked_preflight",s))(ho||{}),Ys=(i=>(i.ExistingEvidence="existing_evidence",i.Unaffected="unaffected",i.ExistingUnit="existing_unit",i.NewUnit="new_unit",i.Runtime="runtime",i))(Ys||{}),Ny=(n=>(n.Repository="repository",n.Testbot="testbot",n))(Ny||{}),Fy=(r=>(r.Identified="identified",r.Passed="passed",r.Failed="failed",r))(Fy||{}),Kt=u.string().trim().min(1),tJ=u.string().regex(/^[a-z0-9][a-z0-9-]*$/,"must be a short lowercase slug").describe("short-slug");var nJ=u.object({id:tJ,source:u.nativeEnum(Ny),kind:u.nativeEnum(_s),outcome:u.nativeEnum(Fy),summary:Kt.max(400).describe("one line: what it shows"),tests:u.array(Kt).optional().describe("source repository: the existing tests, as repo-relative paths, optionally path::test-name"),repository:Kt.optional().describe("source repository: owner/repo the tests live in, when the run has several checkouts; omit for the working checkout"),command:Kt.optional().describe("source testbot: the exact command you ran, as you ran it"),run:Ha.optional().describe(`source repository, for tests in ${Ya}: how the run executes only these tests, all of them in one command, with the repository's own runner writing JUnit XML to {junit}. Name each test (path::test-name): a test is credited to a file only by its name or by a report that names the file`)}),rJ=u.object({behaviorId:Kt.describe("an id from analyze's behaviors"),mechanism:u.nativeEnum(Ys),evidenceIds:u.array(Kt).default([]).describe("existing_evidence: the ci-<n> or evidence ids that establish it; existing_unit: the evidence id naming the tests to run"),covers:u.string().trim().optional().describe('new_unit / runtime: the missing evidence this obtains, e.g. "the boundary the change moved"; unaffected: why the change cannot reach it, citing path:line')}),sJ=u.object({behaviorId:u.string().trim().optional().describe("an id from analyze's behaviors, when it is about one"),missing:Kt.max(600).describe("the evidence that is required and cannot be obtained in this run")}),iJ=u.object({file:Kt.describe("the changed file the failure is in"),repository:Kt.optional().describe("owner/repo the file is in, when the run has several checkouts; omit for the working checkout"),reason:Kt.max(300).describe("what prerequisite the change fails"),evidence:Kt.max(400).describe("the error line, quoted")}),oJ=u.object({behaviorId:Kt.describe("an id from analyze's behaviors"),reason:Kt.max(600).describe("\u2264600 characters: why this change leaves the behavior's result as it was, citing the unchanged line that decides it (path:line)")}),Fu=u.object({schemaVersion:u.literal(1),decision:u.nativeEnum(ho),evidence:u.array(nJ).describe("evidence this session found or produced; CI results are the ci-<n> items and are not restated here"),plan:u.array(rJ).describe("how each changed behavior's evidence is obtained"),gaps:u.array(sJ),outOfScope:u.array(oJ).optional().describe("behaviors analyze found that this change neither changes nor states"),blocked:iJ.optional().describe("only for blocked_preflight"),rationale:Kt.max(1200).describe("\u22641200 characters: why this evidence is enough, or what it still lacks \u2014 the scope you chose and why")});function $d(t){let e=bn(t,"recommend.json");if(!e||!Array.isArray(e.generate)||!Array.isArray(e.maintenance))return;let n=e;return{...n,maintenance:n.maintenance.map(({repository:r,...s})=>({...s,test:s.test.trim().replace(/^\.\//,""),...r?.trim()?{repository:r.trim()}:{}}))}}function AJ(t){return ts(Ty,t).errors}function lJ(t,e=[]){let{value:n,error:r}=jt(t,e);if(r)return{errors:[r]};let s=AJ(n);return s.length>0?{errors:s}:{generate:n,errors:[]}}function Vd(t,e=[]){return lJ(t.stdout,e)}function dJ(t){return t.generate.filter(e=>e.type!=="ui").map(e=>e.id)}function R0(t){return t.generate.filter(e=>e.type==="ui").map(e=>e.id)}var Gd={backend:{stage:"generate",cases:dJ,noRecommendCoverage:"recommend.json missing or malformed \u2014 cannot check coverage",noRecommendIntent:"recommend.json missing or malformed \u2014 cannot check intent",uncovered:t=>`recommend case "${t}" is not covered by any generated test`,unknownCovered:t=>`test covers unknown recommend id "${t}"`,unasserted:t=>`case "${t}" has no verified assertion enforcing its expected_observable`,usedCodegen:h0,codegenHint:"These tests were hand-written. Skyramp codegen (skyramp_contract_test_generation / skyramp_integration_test_generation) was available but not used \u2014 it computes valid sample data and response correlations. Prefer scaffolding with it and then refining, especially for the failures above."},ui:{stage:"generate-ui",cases:R0,noRecommendCoverage:"recommend.json not found \u2014 cannot check UI coverage",noRecommendIntent:"recommend.json not found \u2014 cannot check UI intent",uncovered:t=>`UI case "${t}" is not covered by any generated UI test`,unknownCovered:t=>`test covers "${t}" which is not a recommend UI case`,unasserted:t=>`UI case "${t}" has no verified assertion enforcing its expected_observable`,usedCodegen:f0,codegenHint:"This UI test was hand-authored. Skyramp UI codegen (skyramp_ui_test_generation) was available but not used. Prefer scaffolding with it and then refining, especially for the failures above."}},a6=Us("generate-schema",(t,e)=>Vd(e,t.secretValues));function pJ(t){let e=Gd[t];return{name:`${e.stage}-coverage`,verify(n,r){let{generate:s,errors:i}=Vd(r,n.secretValues);if(!s)return Mt(this.name,i);let a=$d(n);if(!a)return Mt(this.name,[e.noRecommendCoverage]);let c=new Set(s.tests.flatMap(h=>h.covers)),A=[],l=e.cases(a);for(let h of l)c.has(h)||A.push(e.uncovered(h));let p=new Set(t==="ui"?l:a.generate.map(h=>h.id));for(let h of c)p.has(h)||A.push(e.unknownCovered(h));if(t==="backend"){let h=new Set(s.deferredUi),g=new Set(R0(a));for(let C of g)!h.has(C)&&!c.has(C)&&A.push(`UI case "${C}" is neither covered nor deferred to the UI stage`);for(let C of h)g.has(C)||A.push(`deferredUi lists "${C}" which is not a UI case`)}return A.length===0?{name:this.name,passed:!0}:Mt(this.name,A)}}}function hJ(t){let e=Gd[t];return{name:`${e.stage}-intent`,verify(n,r){let{generate:s,errors:i}=Vd(r,n.secretValues);if(!s)return Mt(this.name,i);let a=$d(n);if(!a)return Mt(this.name,[e.noRecommendIntent]);let{asserted:c,errors:A,badFiles:l}=IJ(s,n.inputs.repositoryPath),p=A.length;for(let g of e.cases(a))c.has(g)||A.push(e.unasserted(g));if(A.length===0)return{name:this.name,passed:!0};let h=Mt(this.name,A);return p>0&&p===A.length&&l.size>0?{...h,droppable:[...l]}:h}}}function fJ(t){let e=Gd[t];return n=>{if(!n.inputs.skyrampMcp?.command||t==="backend"&&!By(n))return;let r=qa.join(n.outputsDir,`${e.stage}-stream.ndjson`);if(!(!qs.existsSync(r)||e.usedCodegen(r)))return g0(r)?e.codegenHint:"Skyramp codegen tools were configured but the MCP server did not connect this session, so they were not available. Hand-authoring was the only option; this is an environment problem, not yours."}}var c6=pJ("backend"),u6=hJ("backend"),A6=fJ("backend");var k0=t=>t.replace(/\s+/g,"");var My={python:[/\bassert\s*[({\w"'`]/g,/\bpytest\.raises\s*\(/g,/\bself\.assert\w*\s*\(/g],typescript:[/\bexpect\s*\(/g,/\.should\b/g,/\bassert\s*[.(]/g],go:[/\bt\.(Error|Errorf|Fatal|Fatalf|Fail|FailNow)\s*\(/g,/\b(assert|require)\.\w+\s*\(/g],java:[/\bassert\w*\s*\(/g,/\bassertThat\s*\(/g],ruby:[/\bexpect\s*[({]/g,/\bassert\w*\b/g,/\.should\b/g]};for(let[t,e]of[["javascript","typescript"],["kotlin","java"]])My[t]=My[e];function gJ(t,e){if(t.includes(Iu(e))||k0(t).includes(k0(e)))return!0;let n=e.split(/\r?\n/).map(r=>r.trim()).filter(r=>r&&!/^(\/\/|#|\*|\/\*)/.test(r));return n.length>0&&n.every(r=>t.includes(Iu(r)))?!0:CJ(t,e)}var mJ=/\bassert\w*\b|\bexpect\s*\(|\.should\b|\brequire\s*\(/i,yJ=12,EJ=/,\s*\(\s*#|,\s*f?["'`]|\s+#\s|\s+\/\/|\s*\((?:line|lines|at line)\b|\s*,\s*$/i;function CJ(t,e){let n=e.split(/\s*;\s*|\s*\.\.\.\s*|\r?\n/),r=0;for(let s of n){let i=mJ.exec(s);if(!i)continue;let a=s.slice(i.index),c=EJ.exec(a);if(c&&(a=a.slice(0,c.index)),a=Iu(a).replace(/[,\s]+$/,""),a.length<yJ||!t.includes(a))return!1;r++}return r>0}function IJ(t,e){let n=new Set,r=[],s=new Set;for(let i of t.tests){let a=qa.resolve(e,i.file);if(!qs.existsSync(a))continue;let c=Iu(qs.readFileSync(a,"utf-8"));for(let A of i.assertions??[]){if(!gJ(c,A.evidence)){r.push(`assertion evidence for "${A.case}" not found in ${i.file} \u2014 cite the real assertion line`),s.add(i.file);continue}i.covers.includes(A.case)?n.add(A.case):(r.push(`assertion cites case "${A.case}" not in that test's covers[]`),s.add(i.file))}}return{asserted:n,errors:r,badFiles:s}}var BJ=/\.(spec|test)\.[cm]?[jt]sx?$/i;function x0(t){let e;try{e=(0,v0.execFileSync)("git",[...Dd,"status","--porcelain","--untracked-files=all"],{env:zn(),cwd:t,encoding:"utf-8",stdio:["ignore","pipe","ignore"]})}catch{return}let n=s=>/_scaffold/i.test(s)||Sd.test(s),r=[];for(let s of e.split(`
120
- `)){if(!s.trim()||s.length>1&&s[1]==="D")continue;let i=s.slice(3).trim(),a=i.indexOf(" -> ");if(a!==-1&&(i=i.slice(a+4).trim()),i=i.replace(/^"|"$/g,""),!i)continue;let c=i.replace(/^\.\//,"");c.startsWith(".skyramp/")||!n(c)||r.push(c)}return r}function QJ(t){let e=Gd[t],n=t==="ui";return{name:`${e.stage}-no-litter`,verify(r){let s=x0(r.inputs.repositoryPath);if(s===void 0)return{name:this.name,passed:!0};let i=s.filter(a=>BJ.test(a)===n);return i.length===0?{name:this.name,passed:!0}:Mt(this.name,[`${e.stage} left files outside .skyramp/ \u2014 move the staged test into .skyramp/staged/ and delete any codegen draft (e.g. *_scaffold.*): ${i.slice(0,6).join(", ")}`])}}}var l6=QJ("backend");var Mu=Re(require("fs")),fo=Re(require("path"));function N0(t){return ts(Qy,t).errors}function SJ(t,e=[]){let{value:n,error:r}=jt(t,e);if(r)return{errors:[r]};let s=N0(n);return s.length>0?{errors:s}:{adapt:n,errors:[]}}var kJ="adapt-scratch",T0=`${kJ}/adapt-result.json`;function F0(t,e){let n=fo.join(t.outputsDir,T0),r;try{r=Mu.readFileSync(n,"utf-8")}catch{r=void 0}if(r!==void 0&&(t.secretValues??[]).some(a=>r.includes(a)))return{errors:[`${T0} contains a secret value (token / credential) \u2014 never write it anywhere`]};let s=SJ(e.stdout,t.secretValues);if(s.adapt)return s;let i=r!==void 0?va(n):void 0;return i!==void 0&&N0(i).length===0?{adapt:i,errors:[]}:s}var F6=Us("adapt-schema",F0);var G6=2*1024*1024;var le=u.string().trim().min(1),RJ=t=>{if(!t||typeof t!="object")return t;let e=t;return typeof e.skip=="string"&&e.skip.trim()&&(e.expected===void 0||e.expected===null)?{...e,expected:"(not tested)"}:t},xJ=u.preprocess(RJ,u.object({id:le.describe(`its requirement's id plus a letter, e.g. "R1a", "AC-3a"`),clause:le.describe("one testable part of the requirement"),expected:le.describe("the outcome the requirement calls for \u2014 taken from the requirement, never from what the code does"),skip:u.string().optional().describe("only when no test can check this clause here: why"),type:u.nativeEnum(Gs).optional().describe("the test that checks this clause: contract / integration (the API, or code called directly in-process: a function, hook or module) or ui (a page)"),target:u.string().optional().describe('its "METHOD /path", or the page / flow'),steps:u.string().optional().describe("what that test does; its expected outcome is this clause's"),finding:u.string().optional().describe("the finding id, when this clause's test also catches that defect (the defect still gets a case of its own)"),code:u.string().optional().describe("path:line of the code that decides this clause, when there is one"),mutates:u.boolean().optional().describe("true when its test changes state, in the test or its setup: an API POST, PUT, PATCH or DELETE, or a UI flow that submits, creates, edits or deletes"),browserOnly:u.boolean().optional().describe("true when its behaviour happens only in a browser: real clicks or keys driving page script, client-side sorting or filtering, script-driven DOM updates, focus, drag-and-drop, navigation, rendering that depends on CSS or JavaScript"),browserHarness:u.string().optional().describe("browserOnly, off the runtime path: the path of the repo's in-process browser suite its test goes in (e.g. a Django StaticLiveServerTestCase test that drives Selenium)")})),TJ=u.object({id:le.describe('the label its source gives it ("AC-3", "REQ-12"; item 4 of a numbered list is "R4"), else "R1", "R2"\u2026 in order'),statement:le,source:u.nativeEnum(Va).describe("requirement-reference (an item the run was given), spec, pr-description (also for what the change is evidently meant to do when nothing is written down), or could-break (what the change could break that no requirement mentions)"),reference:u.string().optional().describe('requirement-reference only: the key of its item as listed, e.g. "PAY-184", or a Confluence page id such as "3021"'),evidence:le.describe("where it is stated: for requirement-reference, the item's own words, copied exactly; else file:line, a doc section, or the quoted phrase"),criterion:u.number().int().positive().optional().describe("requirement-reference only: leave it out; Testbot numbers each criterion by the item's own label (AC2, 2.), else after the item's labels"),notInChange:u.string().optional().describe("requirement-reference only: when the change does not touch this criterion at all (e.g. a later step of a staged rollout), why; give it no clauses"),overrules:u.array(u.object({spec:u.string().optional().describe("file:line of the spec in the repository; leave it out for a PR description"),prDescription:u.boolean().optional().describe("true when a pull request description says otherwise"),says:le.describe("what the spec or the PR description says there, in its own words, copied exactly")}).refine(t=>!!(t.prDescription||t.spec?.trim()),{message:'names no source: give "spec" its file:line, or set "prDescription"'})).optional().describe("requirement-reference only: each spec in the repository, and each PR description, that says otherwise; the item wins, so test what it says"),clauses:u.array(xJ)}),M0=(s=>(s.ServerError="server-error",s.DataLost="data-lost",s.FinalState="final-state",s.DerivedValues="derived-values",s))(M0||{}),DJ=u.object({id:le.describe('e.g. "F1"'),file:le,line:u.number().optional(),claim:le.describe("the defect, in one sentence"),severity:u.nativeEnum(Tu),evidence:le.describe("the code line, or the probe request and response, that shows it"),conflictsWith:u.array(le).optional().describe("requirement or clause ids it violates"),keeps:u.string().optional().describe("for a defect no requirement or clause states: path:line of the code beside the change that keeps the rule it breaks"),rule:u.nativeEnum(M0).optional().describe("for a defect that breaks a rule every app keeps, which nothing needs to state: which one"),existing:u.string().optional().describe("only when the base already does this, in code the change left as it was: where the base does it (its file:line); such a defect gets no case"),needsApp:u.enum(["browser","live-api"]).optional().describe("only when the running app alone can show this defect and the repo has no in-process test that can: browser (page script, what the user sees after a click or a save) or live-api (code the repo tests only against the running app's API)")}),NJ=u.object({id:le.describe('e.g. "Q1"'),question:le.describe("what is unsettled, as a question the PR author can answer"),readings:u.array(le).min(2).describe("each reasonable behaviour, with what points to it (file:line, or the words that suggest it)"),about:u.string().optional().describe("the requirement or clause id it is about, when there is one")}),FJ=u.object({id:le.describe('unique, a short kebab-case name for what the case checks, e.g. "ship-twice-409"'),type:u.nativeEnum(Gs).describe("contract / integration: checks the API, or calls code directly in-process (a function, hook or module); ui: checks what a user sees or does on a page"),target:le.describe('"METHOD /path", or the page / flow'),clause:u.string().optional().describe("the clause id this case checks"),finding:u.string().optional().describe("the finding id this case catches"),steps:le.describe("what the test does"),expected:le.describe("the expected outcome, from the clause"),mutates:u.boolean().optional().describe("true when its test changes state, in the test or its setup: an API POST, PUT, PATCH or DELETE, or a UI flow that submits, creates, edits or deletes")}),MJ=u.object({test:le.describe("existing test file"),action:u.nativeEnum(uo),reason:le,mutates:u.boolean().optional().describe("true when the maintained test changes state"),clauses:u.array(le).optional().describe("the clause ids this test checks")}),_J=u.object({outcome:u.nativeEnum(ns).describe("clean | recipe-drift (you had to fix the recipe) | change-broke-bringup (this PR broke start-up) | bringup-failed (the environment, not the PR)"),baseUrls:u.record(u.string()).optional().describe("service \u2192 base URL of the running app"),health:u.object({url:u.string().optional(),command:u.string().optional(),output:u.string().optional()}).optional().describe("the check that shows the app serves real data, and what it returned"),teardown:u.string().optional().describe("command that stops the app"),dependencies:u.record(u.boolean()).optional().describe("every backing service: true = really running, false = mocked"),recipeFixes:u.array(u.string()).optional().describe("what you changed in the recipe"),error:u.string().optional().describe("when it did not come up: the failing command and what it printed"),suspectFiles:u.array(u.string()).optional().describe("change-broke-bringup: the changed files to blame"),login:u.object({username:le,password:u.string()}).optional().describe("the account the tests sign in as, when they sign in: each a literal value the recipe seeds, or $VARIABLE when a secret in the environment holds it"),revisions:py.optional()}),C7=u.object({schemaVersion:u.literal(1),requirements:u.array(TJ),findings:u.array(DJ),cases:u.array(FJ).describe("a second test for a clause, and one case per finding that fails on this branch"),questions:u.array(NJ).optional().describe("behaviours the change leaves unsettled; no case asserts any of them"),maintenance:u.array(MJ),journeys:u.array(E0).optional().describe("the user journeys that, together, pass through everything the change alters that a user sees or does; empty when it alters nothing a user sees"),notInJourney:u.array(u.object({clause:le,why:le})).optional().describe("a clause a user sees or does that no journey can reach through the UI, and why"),triage:Fu.optional().describe("the validation triage decision, made before the app is started; its behaviorIds are clause ids"),app:_J.optional().describe("omit when no app was needed or none was started"),summary:le.describe("one paragraph: what the change does and where the risk is")});var _0=(n=>(n.Backend="backend",n.Ui="ui",n))(_0||{});var _y=(s=>(s.Added="added",s.Updated="updated",s.Deleted="deleted",s.Unchanged="unchanged",s))(_y||{}),UJ=u.object({file:le.describe("repo-relative path; in another repo of the change, that repo's directory name then its path"),kind:u.nativeEnum(_0),change:u.nativeEnum(_y).describe("added: a file you created; updated / deleted / unchanged: an existing test"),covers:u.array(u.string()).describe("the plan case ids this file tests"),defect:u.boolean().optional().describe("true when a case of it fails because the app is wrong and the test is right \u2014 kept failing on purpose"),staleBecause:u.object({requirement:le.describe("the requirement or clause id the change deliberately alters"),line:le.describe("path:line (or path) of the application code the change altered that makes this test's old expectation wrong")}).optional().describe("for an existing test you updated: why it is out of date"),result:u.object({exit:u.number().nullable().describe("exit code of your last run of this file; null if it could not be run"),cases:u.array(u.object({case:le,status:u.nativeEnum(Kn),defect:u.boolean().optional().describe("for a failing case: true when the app is wrong and the test is right; false when the test is at fault and you could not fix it"),failure:u.string().optional().describe("for a failing case: the runner's failure for it as printed (the error and the line it was raised at), not a summary"),cause:u.string().optional().describe("for a case you keep as a defect: path:line of the application code that makes it fail"),requires:u.string().optional().describe("for a case you keep as a defect: the words of the PR description, a requirement or clause of the plan, or the code a finding's keeps names, that state what its failing check expects, quoted exactly")})).describe("one entry per covered case, from the runner's own output"),details:u.string().optional().describe("what failed and why, or why it was not run")}),assertions:u.array(u.object({case:le,evidence:le})).optional().describe("per covered case, the assertion line that checks its expected outcome"),functions:u.array(u.object({name:le.describe("the test function as the runner names it within its file, without the file (test_x, TestClass::test_x, TestSuite/TestCase)"),cases:u.array(le).describe("the plan case ids it checks")})).optional().describe("for a file you added or updated: each test function in it and the plan case ids it checks"),skyramp:u.object({draft:u.union([u.string(),u.array(u.string())]).optional().describe("the draft path the Skyramp helper returned for this test, or each path when the test was made from several drafts"),handWritten:u.string().optional().describe("why it is written by hand: the helper call you made and what it returned")}).optional().describe("only for a test of a case the Skyramp API block lists: where it came from"),context:u.array(xy).optional().describe("what the test sets up outside its own process that another test could run into: data it creates in the app, a Skyramp mock, an env override; omit when none"),isolatedRun:le.optional().describe("for a test with a context: the command, from its checkout's root and without a shell, that runs only this file"),run:Ha.optional().describe(`for a file in ${Ya}, added, updated or re-run: how the run executes only this file's tests, with the repository's own runner and the report it writes (junit or trx to ${Zn}, or go-test-json); Testbot runs it before write ends and re-runs the tests with it`)}),LJ=u.object({description:le.describe("what is wrong and how to reproduce it: endpoint or page, input, what you got vs what was expected"),severity:u.nativeEnum(Tu).optional(),sourceFile:u.string().optional().describe("the app file at fault"),sourceLine:u.number().optional(),test:u.string().optional().describe("the test file that shows it"),finding:u.string().optional().describe("the plan's finding id, when it is one"),requirements:u.array(le).optional().describe("the plan's requirement or clause ids it violates")}),I7=u.object({schemaVersion:u.literal(1),tests:u.array(UJ),notWritten:u.array(u.object({case:le,reason:le})).describe("every plan case no test covers, and why"),journeys:u.array(Ud).optional().describe("one entry per planned user journey: the browser test that walks it end to end"),lint:u.object({command:u.string(),clean:u.boolean()}).optional().describe("the linter/formatter you ran on your test files, if the repo has one: the exact command, with its file paths (Testbot re-runs it)"),dependenciesAdded:u.array(u.object({package:le,manifest:le.describe("the manifest file's path relative to its checkout (e.g. package.json, pom.xml or pyproject.toml), and nothing else; name another checkout in repository"),repository:le.optional().describe("owner/repo of the manifest's checkout; omit for the repo under test"),reason:le.optional().describe("why the test must run inside the application's own test environment, so its manifest had to change \u2014 required for every entry")})).optional().describe("every package you added to an APPLICATION manifest (an exception, surfaced in the report); never the Testbot test package's own"),supportFiles:u.array(le).optional().describe("every file that is not a test you created or changed for your tests, which they need to compile or run (a helper module, page object, fixture, or a snapshot the runner wrote for them), named as you name a test; Testbot delivers only the tests you list and the files under supportFiles"),ciRunsTests:u.boolean().optional().describe("will the repo's CI pick these tests up as they are?"),commit:u.object({message:le.describe('"Skyramp Testbot: \u2026", subject line at most 72 characters'),prTitle:le.describe("at most 72 characters"),prBody:le.describe("what the tests cover and what they found")}),report:u.object({summary:le.describe("1-2 sentences for the PR author: does the change do what it says?"),issues:u.array(LJ).describe("every defect the tests found"),nextSteps:u.array(u.string())})});var B7={added:"place",updated:"update",deleted:"delete",unchanged:"verify"};var L0=(r=>(r.Requirement="requirement",r.PrDescription="pr_description",r.Code="code",r))(L0||{}),yt=u.string().trim().min(1),PJ=u.object({expectation:yt.max(300).describe("the behavior this assertion pins, in words"),source:u.nativeEnum(L0),expected:yt.max(200).describe("the exact value or outcome asserted, as the test asserts it")}),OJ=u.object({file:yt.describe("path of the NEW test file you wrote, relative to its repository"),repository:yt.optional().describe("owner/repo the file lives in, when the run has several checkouts; omit for the working checkout"),framework:yt.describe("the framework the repository runs this file with: pytest, jest, vitest, node-test, or the name of any other"),run:Ha.optional().describe(`for ${Ya}: how the run executes only the tests in names, with the repository's own runner writing JUnit XML to {junit}`),covers:u.array(yt).length(1).describe("the ONE behavior id, or defect id, from the plan that the tests in names provide evidence for; a file covering several is listed once per id"),names:u.array(yt).min(1).describe("the test functions/cases in the file that provide evidence for that behavior, as the framework names them"),assertions:u.array(PJ).min(1)}),Uy=(n=>(n.Updated="updated",n.Deleted="deleted",n))(Uy||{}),U0=300,$J=u.object({file:yt.describe("path of the EXISTING test file you updated or deleted, relative to its repository"),repository:yt.optional().describe("owner/repo the file lives in, when the run has several checkouts; omit for the working checkout"),change:u.nativeEnum(Uy),staleBecause:u.object({requirement:yt.describe("the requirement or clause id the change deliberately alters"),line:yt.describe("path:line (or path) of the application code the change altered that makes this test's old expectation wrong")}).optional().describe("for an existing test you updated: why it is out of date"),reason:u.preprocess(t=>typeof t=="string"?t.trim().slice(0,U0):t,yt.max(U0)).describe("what the change deliberately altered that made the test wrong")}),Ly=u.object({schemaVersion:u.literal(1),tests:u.array(OJ),maintained:u.array($J).optional().describe("existing tests the change made stale that you updated or deleted; omit when there were none"),defectsNotTested:u.array(u.object({id:yt,reason:yt.max(300)})).optional().describe("defects the plan found that no in-process test can reach, each with why; omit when every defect has a test"),journeys:u.array(Ud).optional().describe("one entry per planned user journey: the in-process test that walks it end to end"),journeysNotWritten:u.array(u.object({journey:yt,missing:yt.transform(t=>t.length>300?`${t.slice(0,299)}\u2026`:t)})).optional().describe("a planned journey no in-process test can walk here, with what it needs that is missing; it is reported as not covered"),lint:u.object({command:u.string(),clean:u.boolean()}).optional().describe("the linter/formatter you ran on your test files, if the repository has one you can run; omit otherwise"),commitMessage:yt.optional().describe("the commit message for your tests: a subject line of at most 72 characters, then what they cover")});var G7=5*6e4;function HJ(t){let{value:e,error:n}=jt(t);if(n)return{errors:[n]};let{value:r,errors:s}=ts(Ly,e);return s.length?{errors:s}:{output:r,errors:[]}}function YJ(t){return HJ(t.stdout)}var jee=Us("generate-unit-schema",(t,e)=>YJ(e));var Hd=String.raw`(?:node:)?(?:http|https|http2|net|tls|dgram)`,Jee=[[/\b(localhost|127\.0\.0\.1|0\.0\.0\.0)\b/,"a local server address"],[/^\s*(import|from)\s+(requests|aiohttp|urllib3|websockets?)\b/m,"an HTTP client"],[/^\s*(?:import|from)\s+(?:urllib\.request|http\.client|http\.server|socket|ssl|ftplib|smtplib|telnetlib)\b|^\s*from\s+urllib\s+import\b[^\n]*\brequest\b|\burlopen\s*\(/m,"a standard-library network client"],[/\bfrom\s+["'](axios|node-fetch|undici|ws)["']|require\(\s*["'](axios|node-fetch|undici|ws)["']\s*\)/,"an HTTP client"],[new RegExp(String.raw`\bfrom\s+["']${Hd}["']|\bimport\s+["']${Hd}["']|require\(\s*["']${Hd}["']\s*\)|\bimport\(\s*["']${Hd}["']\s*\)`),"Node's network modules"],[/\bfetch\s*\(|\bnew\s+(XMLHttpRequest|WebSocket)\b/,"a network call (fetch, XMLHttpRequest, WebSocket)"],[/\bskyramp\b/i,"the Skyramp runtime (a runtime mock or client)"]];var O0=String.raw`\b(?:real browser|browser|javascript|js|htmx|client-side)\b`,$0=String.raw`\b(?:not|isn't|aren't|never|no)\s+(?:be\s+)?(?:covered|tested|exercised|verified|checked|walked|executed|run)\b|\buncovered\b|\bunverified\b`,ute=[new RegExp(`${O0}[^.;\\n]{0,100}(?:${$0})`,"i"),new RegExp(`(?:${$0})[^.;\\n]{0,100}${O0}`,"i")];var Ate=new Set(["targeted_unit","existing_evidence_sufficient"]);var Kte=new Set(["existing_evidence","unaffected","existing_unit","new_unit","runtime"]),Zte={existing_evidence:"existing evidence",unaffected:"showing the change cannot reach it",existing_unit:"running the existing unit tests",new_unit:"a new unit test",runtime:"tests against the running application"};function zJ(t){let{value:e,error:n}=jt(t);if(n)return{errors:[n]};let{value:r,errors:s}=ts(Fu,e);return s.length?{errors:s}:{triage:r,errors:[]}}function KJ(t){return zJ(t.stdout)}var Xte=Us("triage-schema",(t,e)=>KJ(e));var ene=new Set(["deploy","recommend","generate","generate-ui","adapt","generate-unit","native-run","finalize","deliver"]);Dt();Dt();var XJ="Skyramp-Pull-Request",eW="Skyramp-Delivery-Base",tW="Skyramp-Tested-Revision";var Ene=["%H","%P","%an","%ae","%ce",`%(trailers:key=${XJ},valueonly,separator=%x2C)`,"%s",`%(trailers:key=${eW},valueonly,separator=%x2C)`,`%(trailers:key=${tW},valueonly,separator=%x2C)`];var qd=(n=>(n.GitHub="github",n.AzureDevOps="azure-devops",n))(qd||{}),$y=(i=>(i.Trigger="TRIGGER",i.Baseline="BASELINE",i.AuthoritativeRelatedChange="AUTHORITATIVE_RELATED_CHANGE",i.ConfiguredSharedDependency="CONFIGURED_SHARED_DEPENDENCY",i.ManualOverride="MANUAL_OVERRIDE",i))($y||{}),Uu=(a=>(a.PullRequest="pull_request",a.ReadyForReview="ready_for_review",a.Schedule="schedule",a.Manual="manual",a.SutSetup="sut_setup",a.RevisionRead="revision_read",a))(Uu||{}),sW=["sut_setup"],iW=["sut_setup","schedule","revision_read"];var jd=(e=>(e.PullRequest="pull_request",e))(jd||{}),Lu=(s=>(s.ModelProvider="model_provider",s.SutAccess="sut_access",s.Skyramp="skyramp",s.Other="other",s))(Lu||{});var Jd=(i=>(i.ReportUploaded="report_uploaded",i.NoReport="no_report",i.Cancelled="cancelled",i.RecipeUploaded="recipe_uploaded",i.RevisionsUploaded="revisions_uploaded",i))(Jd||{}),X0=(n=>(n.Running="running",n.Ended="ended",n))(X0||{}),Wd=(p=>(p.TimedOut="timed_out",p.AgentFailed="agent_failed",p.SetupFailed="setup_failed",p.CredentialMissing="credential_missing",p.RunnerLost="runner_lost",p.CheckoutFailed="checkout_failed",p.EnvironmentUnverified="environment_unverified",p.ModelProviderDenied="model_provider_denied",p.ModelProviderUnavailable="model_provider_unavailable",p.RunnerProviderNotReady="runner_provider_not_ready",p))(Wd||{}),Vy=(r=>(r.Onboard="onboard",r.Deploy="deploy",r.Recheck="recheck",r))(Vy||{}),Gy=(n=>(n.Started="started",n.Finished="finished",n))(Gy||{}),Hy=(r=>(r.Passed="passed",r.Failed="failed",r.Skipped="skipped",r))(Hy||{});var Yy=(r=>(r.ChooseCredential="choose_credential",r.FreeText="free_text",r.ChooseSource="choose_source",r))(Yy||{});var zd=(r=>(r.Discover="discover",r.Start="start",r.Check="check",r))(zd||{}),Kd=(s=>(s.ValidationPlan="validation_plan",s.TestEnvironment="test_environment",s.TestConditions="test_conditions",s.Tests="tests",s))(Kd||{}),Pu=(s=>(s.Found="found",s.Starting="starting",s.Up="up",s.OutOfScope="out_of_scope",s))(Pu||{}),Xn=u.string().regex(/^[1-9][0-9]{0,18}$/),as=u.string().regex(/^(?:[0-9a-f]{40}|[0-9a-f]{64})$/),Ja=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/,_t=u.string().regex(Ja),Ut=u.string().regex(/^[0-9a-f]{64}$/),Yd=u.object({id:_t,revision:Xn}).strict(),Zd={provider:u.literal("github"),providerAccountId:Xn,providerRepositoryId:Xn},Xd={provider:u.literal("azure-devops"),providerAccountId:_t,providerRepositoryId:_t},er=u.discriminatedUnion("provider",[u.object(Zd).strict(),u.object(Xd).strict()]),qy=u.discriminatedUnion("provider",[u.object(Zd).passthrough(),u.object(Xd).passthrough()]),go=t=>`${t.provider}:${t.providerRepositoryId}`,V0={namespace:u.string().min(1),name:u.string().min(1)},eT=u.discriminatedUnion("provider",[u.object({...Zd,...V0}).strict(),u.object({...Xd,...V0}).strict()]),G0=u.object({ref:u.string().min(1),revision:as}).strict(),oW=u.object({repository:eT,revision:as,ref:u.string().nullable(),reason:u.nativeEnum($y),change:u.object({kind:u.nativeEnum(jd),number:Xn,base:G0.optional()}).strict().nullable(),compareWith:G0.optional()}).strict();function aW(t){if(t.trigger.kind==="revision_read"!=!t.baseline)return t.baseline?"a revision_read run names no baseline":"names its baseline";if(!t.baseline)return null;let{confirmedRunId:e,initialBaselineId:n,sources:r}=t.baseline;if(e!==null&&n!==void 0)return"a run compares with one baseline";let s=t.trigger.kind==="schedule"&&e!==null||n!==void 0;if(!r)return s?"names every source of the snapshot, once":null;if(e===null&&n===void 0)return"a run with no Confirmed Baseline names no baseline sources";let i=new Set(t.sources.map(A=>go(A.repository))),a=new Set(r.map(A=>go(A.repository)));return a.size===r.length&&a.size===i.size&&[...a].every(A=>i.has(A))?null:"names every source of the snapshot, once"}var tT=/^[A-Z][A-Z0-9_]+-[1-9][0-9]*$/,nT=/^[1-9][0-9]{0,18}$/,H0=new RegExp(`${tT.source}|${nT.source}`),Y0=/^https:\/\/[a-z0-9-]+(\.[a-z0-9-]+)+$/,cW=u.union([u.object({source:u.literal("jira"),site:u.string().regex(Y0),key:u.string().regex(tT),updated:u.string().datetime(),contentHash:Ut}).strict(),u.object({source:u.literal("confluence"),site:u.string().regex(Y0),key:u.string().regex(nT),version:u.number().int().positive(),contentHash:Ut}).strict(),u.object({source:u.literal("other"),key:u.string().regex(Ed),contentHash:Ut}).strict(),u.object({source:u.literal("other"),key:u.string().regex(mu),contentHash:Ut,fileName:u.string().min(1).max(255),mediaType:u.nativeEnum(yu)}).strict()]),q0=u.union([u.literal("jira"),u.literal("confluence")]),uW=u.object({schemaVersion:u.literal(1),items:u.array(u.union([u.object({source:q0,site:u.string(),key:u.string().regex(H0),state:u.literal("read"),text:u.string(),version:u.string().min(1),contentMatches:u.boolean()}).strict(),u.object({source:q0,site:u.string(),key:u.string().regex(H0),state:u.literal("not_read"),reason:u.nativeEnum(qi)}).strict(),u.object({source:u.literal("other"),key:u.string().regex(Ed),state:u.literal("read"),text:u.string(),version:u.string().min(1),contentMatches:u.boolean()}).strict(),u.object({source:u.literal("other"),key:u.string().regex(Ed),state:u.literal("not_read"),reason:u.nativeEnum(qi)}).strict(),u.object({source:u.literal("other"),key:u.string().regex(mu),state:u.literal("read"),version:Ut,fileName:u.string().min(1).max(255),mediaType:u.nativeEnum(yu)}).strict(),u.object({source:u.literal("other"),key:u.string().regex(mu),state:u.literal("not_read"),reason:u.nativeEnum(qi)}).strict()])),instructions:u.array(u.string()).optional()}).strict(),AW=u.object({schemaVersion:u.literal(1),runId:_t,skyrampOrgId:_t,target:Yd,policy:Yd.nullable(),trigger:u.object({kind:u.nativeEnum(Uu),requestedAt:u.string().datetime()}).strict(),configuration:u.object({captureId:_t,revision:Xn.nullable(),hash:Ut}).strict(),baseline:u.object({confirmedRunId:_t.nullable(),initialBaselineId:_t.optional(),sources:u.array(u.object({repository:er,revision:as}).strict()).optional()}).strict().optional(),sources:u.array(oW).min(1),execution:u.object({provider:u.nativeEnum(qd),repository:eT,workflowPath:u.string(),ref:u.string()}).strict(),credentials:u.array(u.object({name:u.string(),purpose:u.nativeEnum(Lu),required:u.boolean()}).strict()),requirements:u.array(cW).min(1).optional(),instructions:u.object({contentHash:Ut}).strict().optional(),deployedRevisions:u.array(u.object({repository:er,revision:as}).strict()).min(1).optional()}).strict().superRefine((t,e)=>{let n=new Set;(t.requirements??[]).forEach((A,l)=>{let p="fileName"in A?"file":"pasted";A.source==="other"&&A.key!==`${p}-${A.contentHash.slice(0,16)}`&&e.addIssue({code:u.ZodIssueCode.custom,message:"is not the key of its content hash",path:["requirements",l,"key"]});let h=oy({source:A.source,key:A.key});n.has(h)&&e.addIssue({code:u.ZodIssueCode.custom,message:"names an item that the run already names",path:["requirements",l,"key"]}),n.add(h)});let r=t.trigger.kind,s=sW.includes(r);s!==(t.policy===null)&&e.addIssue({code:u.ZodIssueCode.custom,path:["policy"],message:s?`a ${r} run has no policy`:"names the policy revision"});let i=aW(t);i&&e.addIssue({code:u.ZodIssueCode.custom,path:t.baseline?["baseline","sources"]:["baseline"],message:i}),iW.includes(r)&&t.sources.forEach((A,l)=>{A.reason!=="BASELINE"&&e.addIssue({code:u.ZodIssueCode.custom,path:["sources",l,"reason"],message:`a ${r} run selects only BASELINE sources`})}),t.deployedRevisions&&r!=="manual"&&e.addIssue({code:u.ZodIssueCode.custom,path:["deployedRevisions"],message:"only a manual run pins deployed revisions"});let a=new Set(t.sources.map(A=>go(A.repository))),c=new Set;(t.deployedRevisions??[]).forEach((A,l)=>{let p=go(A.repository);a.has(p)?c.has(p)&&e.addIssue({code:u.ZodIssueCode.custom,path:["deployedRevisions",l,"repository"],message:"repository appears twice"}):e.addIssue({code:u.ZodIssueCode.custom,path:["deployedRevisions",l,"repository"],message:"names a repository outside the snapshot"}),c.add(p)}),t.sources.forEach((A,l)=>{A.compareWith&&(A.reason!=="MANUAL_OVERRIDE"||A.change)&&e.addIssue({code:u.ZodIssueCode.custom,path:["sources",l,"compareWith"],message:"only a MANUAL_OVERRIDE source without a change names a revision to compare with"})})});var rT=(n=>(n.Person="person",n.Policy="policy",n))(rT||{}),lW=u.object({kind:u.nativeEnum(rT),name:u.string().min(1).max(256)}).strict(),zne=u.object({schemaVersion:u.literal(1),attempt:u.object({id:_t,number:u.number().int().positive(),deadlineAt:u.string().datetime()}).strict(),manifest:AW,manifestHash:Ut,entitlements:u.array(u.string()).optional(),runToken:u.string().min(1).optional(),requestedBy:lW.nullable().optional(),writeAllowed:u.boolean().optional(),claudeCodeVersion:u.string().regex(/^[0-9]+\.[0-9]+\.[0-9]+$/,"an exact version, such as 2.1.290").nullable().optional(),deployedRevisions:u.array(u.object({repository:er,revision:as}).strict()).optional(),statedRevisions:u.array(u.object({repository:er,revision:as}).strict()).optional()}).strict(),j0={providerRunAttempt:u.number().int().positive(),workflowRef:u.string().min(1)},dW=u.string().regex(/^[^/]+\/[^/]+\/[1-9][0-9]{0,15}\/[1-9][0-9]{0,15}$/),Kne=u.object({schemaVersion:u.literal(1),runId:_t,execution:u.discriminatedUnion("provider",[u.object({...j0,provider:u.literal("github"),repository:u.object(Zd).strict(),providerRunId:Xn}).strict(),u.object({...j0,provider:u.literal("azure-devops"),repository:u.object(Xd).strict(),providerRunId:dW}).strict()]),requester:u.literal(!0).optional(),writeCheck:u.literal(!0).optional(),claudeCodePin:u.literal(!0).optional(),deployedPins:u.literal(!0).optional(),statedPins:u.literal(!0).optional()}).strict(),J0=u.object({repository:er,number:Xn}).strict(),pW=u.discriminatedUnion("status",[u.object({status:u.literal("none")}).strict(),u.object({status:u.literal("delivered"),pullRequests:u.array(J0).min(1)}).strict(),u.object({status:u.literal("partial"),pullRequests:u.array(J0).min(1),failures:u.array(u.object({repository:er,message:u.string()}).strict()).min(1)}).strict(),u.object({status:u.literal("failed"),message:u.string()}).strict()]),hW=u.object({blockedPreflight:u.object({file:u.string().min(1),repository:u.string().min(1).optional(),reason:u.string().min(1).max(300),evidence:u.string().min(1).max(400)}).strict().optional(),sufficiency:u.nativeEnum(Sa),rationale:u.string().min(1),gaps:u.array(u.string().min(1)),acceptedEvidence:u.array(u.object({kind:u.nativeEnum(_s),repository:u.string().min(1),revision:as,reference:u.string().min(1),summary:u.string().min(1)}).strict()),actionRequired:u.array(u.nativeEnum(ka))}).strict().superRefine((t,e)=>{t.sufficiency==="insufficient"!=t.gaps.length>0&&e.addIssue({code:u.ZodIssueCode.custom,path:["gaps"],message:"only insufficient evidence names gaps, and it names at least one"}),new Set(t.actionRequired).size!==t.actionRequired.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["actionRequired"],message:"a reason appears twice"})}),Py=500,fW=2048,gW=1e3,mW=/[\\/:*?"<>|;#$*{},+=[\]%\p{Cc}\p{Cf}]/u,W0=t=>t.length>0&&t.length<=64&&t===t.trim()&&!mW.test(t)&&!/[^\S ]/u.test(t)&&!/^[._]/.test(t)&&!t.endsWith("."),yW=t=>{if(/^[A-Za-z0-9._-]{1,100}\/[A-Za-z0-9._-]{1,100}$/.test(t))return!0;let[e,n,r,...s]=t.split("/");return t.length<=201&&s.length===0&&r!==void 0&&/^[A-Za-z0-9](?:[A-Za-z0-9-]{0,48}[A-Za-z0-9])?$/.test(e)&&W0(n)&&W0(r)},EW=u.object({testResults:u.array(u.object({resultId:u.string().regex(/^[^\u0000-\u001f]{1,512}$/),repository:u.string().refine(yW,"Invalid"),testType:u.string(),endpoint:u.string(),status:u.enum(["Pass","Fail","Skipped"]),details:u.string(),fileName:u.string().optional(),testId:u.string().regex(/^[^\u0000-\u001f]{1,512}$/).optional(),failureCause:u.object({kind:u.nativeEnum(cy),family:u.nativeEnum(uy).optional()}).strict().optional(),origin:u.nativeEnum(ay).optional()}).strict()),validation:hW,changes:u.array(u.object({id:u.string().min(1).max(512),text:u.string().max(16384),source:u.string().max(fW),testedBy:u.array(u.string().min(1).max(1024)).max(Py),writtenBy:u.array(u.string().min(1).max(1024)).max(Py),maintainedBy:u.array(u.string().min(1).max(1024)).max(Py)}).strict()).max(gW).optional(),traceVersion:u.literal(1)}).passthrough().superRefine((t,e)=>{let n=new Set;t.testResults.forEach((r,s)=>{let i=r.failureCause;i&&r.status==="Pass"&&e.addIssue({code:u.ZodIssueCode.custom,path:["testResults",s,"failureCause"],message:"a passing result has no failure cause"}),i&&i.kind==="environment"!=(i.family!==void 0)&&e.addIssue({code:u.ZodIssueCode.custom,path:["testResults",s,"failureCause"],message:"an environment cause names its family, and no other cause does"});let a=["testResults",s,"resultId"],c=r.resultId.slice(`${r.repository}:${r.testType}:`.length);(!r.resultId.startsWith(`${r.repository}:${r.testType}:`)||c===""||c.startsWith("/")||c.startsWith("#"))&&e.addIssue({code:u.ZodIssueCode.custom,path:a,message:"is not repository:testType:path for this result"}),n.has(r.resultId)&&e.addIssue({code:u.ZodIssueCode.custom,path:a,message:"stable identity repeated"}),n.add(r.resultId)})});var sT=50,z0=u.string().regex(/^(?!.*\.\.)(?!\/)(?!.*\/$)[A-Za-z0-9._/-]{1,255}$/),iT=u.discriminatedUnion("kind",[u.object({kind:u.literal("branch_pushed"),repository:er,branch:z0,commit:as}).strict(),u.object({kind:u.enum(["pull_request_opened","pull_request_edited"]),repository:er,number:Xn,branch:z0}).strict()]),CW=u.object({schemaVersion:u.literal(1),run:u.object({runId:_t,attemptNumber:u.number().int().positive(),manifestHash:Ut}).strict(),target:Yd,policy:Yd,provenance:u.object({sources:u.array(u.object({repository:er,revision:as}).strict()),firstQualification:u.literal(!0).optional()}).strict(),delivery:u.object({generatedTests:pW}).strict(),producer:u.object({testbot:u.string().regex(/^[0-9A-Za-z.+-]{1,64}$/),mcp:u.string().regex(/^[0-9A-Za-z.+-]{1,64}$/)}).strict(),report:EW,githubWrites:u.array(iT).max(sT).optional()}).strict(),Zne=CW.pick({schemaVersion:!0,run:!0,target:!0,provenance:!0,producer:!0}).extend({recipe:Sy}).strict().superRefine(({recipe:t},e)=>{let n=(i,a)=>e.addIssue({code:u.ZodIssueCode.custom,path:["recipe",...i],message:a});t.status==="blocked"&&t.blockers.length===0&&n(["blockers"],"a blocked recipe names at least one blocker");let r=new Set,s=0;t.files.forEach((i,a)=>{Ru(i.path)||n(["files",a,"path"],"is not .skyramp/workspace.yml or a file under .skyramp/sut/"),r.has(i.path)&&n(["files",a,"path"],"file repeated"),r.add(i.path),fy.test(i.content)&&n(["files",a,"content"],"is not text");let c=Buffer.byteLength(i.content,"utf8");s+=c,c>ku&&n(["files",a,"content"],`larger than ${ku} bytes`)}),s>vu&&n(["files"],`recipe text over ${vu} bytes in total`)}),Xne=u.object({components:u.array(u.object({name:u.string().min(1),repository:u.string().regex(/^[A-Za-z0-9._-]{1,100}\/[A-Za-z0-9._-]{1,100}$/),observedRevision:u.string().regex(/^[0-9a-f]{7,64}$/).nullable(),source:u.nativeEnum(Cd),evidence:u.string()}).strict().refine(t=>t.source!=="agent"||t.observedRevision===null,{path:["observedRevision"],message:"a component only an agent session can read names no revision"}))}).strict();var IW=u.object({schemaVersion:u.literal(1),stage:u.nativeEnum(Vy),event:u.nativeEnum(Gy),status:u.nativeEnum(Hy).optional()}).strict().refine(t=>t.status===void 0||t.event==="finished",{path:["status"],message:"only a finished stage has a status"}),Wa=100,jy=5e3,_u=2e3,Oy=100,Jy=/^[A-Za-z0-9_-]{1,64}$/,oT=20,aT=200,cT=100,uT=100,BW=200,K0="[^/\\s](?:(?:[^/\\s]| )*[^/\\s])?",QW=new RegExp(`^(?:[^/\\s]+/[^/\\s]+|[^/\\s]+/${K0}/${K0})$`),AT=500,lT=50,Ou=/[\u0000-\u0008\u000b\u000c\u000e-\u001f\u007f]|[\ud800-\udbff](?![\udc00-\udfff])|(?<![\ud800-\udbff])[\udc00-\udfff]/,xn=t=>u.string().max(t).refine(e=>e.trim().length>0&&!Ou.test(e),"blank, or not text"),os={sequence:u.number().int().min(1).max(jy),at:u.string().regex(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d{1,6})?Z$/)},dT=u.discriminatedUnion("kind",[u.object({...os,kind:u.literal("log"),phase:u.nativeEnum(zd),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("component"),name:xn(Oy),repository:xn(BW).refine(t=>QW.test(t)||t===zt,"not owner/name"),file:xn(AT).nullable(),status:u.nativeEnum(Pu),version:xn(uT).optional()}).strict(),u.object({...os,kind:u.literal("reply"),to:u.string().uuid(),accepted:u.boolean(),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("question"),id:u.string().regex(Jy),type:u.nativeEnum(Yy),text:xn(_u),component:xn(Oy).nullable(),choices:u.array(xn(aT)).max(oT),placeholder:xn(cT).optional()}).strict(),u.object({...os,kind:u.literal("delivered"),ids:u.array(u.string().uuid()).max(Wa)}).strict(),u.object({...os,kind:u.literal("credentials"),names:u.array(u.string().regex(La)).min(1).max(lT)}).strict()]).superRefine((t,e)=>{t.kind==="credentials"&&new Set(t.names).size!==t.names.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["names"],message:"a name twice"}),t.kind==="question"&&(t.type==="free_text"!=(t.choices.length===0)&&e.addIssue({code:u.ZodIssueCode.custom,path:["choices"],message:"choices exactly when the question is not free_text"}),new Set(t.choices).size!==t.choices.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["choices"],message:"a choice twice"}))}),wW=u.object({schemaVersion:u.literal(1),events:u.array(dT).max(Wa)}).strict(),pT=u.discriminatedUnion("kind",[u.object({...os,kind:u.literal("log"),stage:u.nativeEnum(Kd),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("reply"),to:u.string().uuid(),accepted:u.boolean(),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("delivered"),ids:u.array(u.string().uuid()).max(Wa)}).strict()]),bW=u.object({schemaVersion:u.literal(1),events:u.array(pT).max(Wa)}).strict(),Z0={id:u.string().uuid(),text:u.string(),by:u.string().nullable(),at:u.string(),replied:u.literal(!0).optional()},hT=u.discriminatedUnion("kind",[u.object({...Z0,kind:u.literal("instruction"),question:u.null()}),u.object({...Z0,kind:u.literal("answer"),question:u.string().regex(Jy)})]),fT=u.string().regex(/^[A-Za-z0-9+/]{43}=$/),SW=u.object({id:u.string().uuid(),revision:u.string(),by:u.string().nullable(),at:u.string(),target:u.string(),own:u.object({source:u.enum(["policy","test_environment"]),text:u.string()}).nullable()}),kW=u.object({schemaVersion:u.literal(1),leftOut:u.array(u.string()),messages:u.array(hT).optional(),stop:u.object({key:fT}).optional(),notes:SW.optional()}),vW=u.object({schemaVersion:u.literal(1),messages:u.array(hT).optional()});var gT=500*1024*1024,mT=u.object({id:Xn,name:u.string().regex(/^[A-Za-z0-9._-]{1,200}$/),providerRunId:Xn,expiresAt:u.string().datetime()}).strict(),RW=u.object({schemaVersion:u.literal(1),artifact:mT,sessionId:_t,contentHash:Ut,bytes:u.number().int().min(1).max(gT)}).strict(),xW=u.object({schemaVersion:u.literal(1),checkpoint:u.object({artifact:mT,repository:u.object({namespace:u.string().min(1),name:u.string().min(1)}).strict(),sessionId:_t,contentHash:Ut,key:fT}).strict().nullable()}).strict(),TW=200,ja=100,Wy=(r=>(r.Resume="resume",r.Retry="retry",r.Update="update",r))(Wy||{}),DW=u.object({kind:u.nativeEnum(Wy),setup:u.object({runId:_t,endedAt:u.string().nullable(),outcome:u.string().nullable()}).strict(),components:u.array(u.object({name:u.string().min(1),repository:u.string().min(1),status:u.nativeEnum(Pu)}).strict()).max(ja),credentials:u.array(u.string().min(1)).max(ja),answers:u.array(u.object({question:u.string(),answer:u.string().nullable()}).strict()).max(ja),instructions:u.array(u.object({text:u.string(),reply:u.string().nullable()}).strict()).max(ja),log:u.array(u.object({phase:u.nativeEnum(zd),text:u.string()}).strict()).max(TW),recipe:u.object({files:u.array(u.object({path:u.string().min(1),content:u.string()}).strict()).max(ja),blockers:u.array(u.object({component:u.string(),problem:u.string(),evidence:u.string(),fix:u.string()}).strict()).max(ja)}).strict().optional()}).strict(),NW=u.object({schemaVersion:u.literal(1),context:DW.nullable()}).strict(),FW=u.object({schemaVersion:u.literal(1),configuration:u.object({captureId:_t,revision:Xn.nullable(),hash:Ut}).strict(),capture:u.object({schemaVersion:u.literal(1),settings:u.object({target:u.object({environment:u.unknown()}).passthrough(),timeoutMinutes:u.number().int().positive(),answerWaitMinutes:u.number().int().positive().optional(),testEnvironment:u.object({name:u.string().min(1),address:u.string().min(1).optional(),readyWhen:u.string().min(1).optional()}).passthrough().optional()}).passthrough(),provenance:u.object({}).passthrough(),hash:Ut}).strict()}).strict(),MW=Oa.extend({version:u.number().int().positive(),components:u.array(u.object({name:u.string().min(1),repository:u.string().min(1)}).strict()),contentHash:Ut.optional(),files:u.array(u.object({path:u.string().refine(t=>Ru(t)&&!_d.includes(t),"not a file of a customer_deployed plan"),content:u.string()}).strict()).optional()}).strict(),_W=u.object({schemaVersion:u.literal(1),testEnvironment:MW.nullable().optional(),runtimePlan:u.object({version:u.number().int().positive(),contentHash:Ut,files:u.array(u.object({path:u.string().refine(Ru,"not a recipe file path"),content:u.string()}).strict()).min(1),recipe:u.record(u.unknown()).optional()}).strict().nullable()}).strict().refine(t=>!(t.runtimePlan&&t.testEnvironment),{message:"a run pins a recipe or a customer's Test Environment, never both",path:["testEnvironment"]}),UW=u.object({schemaVersion:u.literal(1),state:u.nativeEnum(X0),ending:u.nativeEnum(Jd).nullable(),cause:u.nativeEnum(Wd).nullable(),deadlineAt:u.string().datetime()}).strict();function yT(t){return t.reportUploaded?{schemaVersion:1,reason:"report_uploaded",cause:null}:t.recipeUploaded?{schemaVersion:1,reason:"recipe_uploaded",cause:null}:t.revisionsUploaded?{schemaVersion:1,reason:"revisions_uploaded",cause:null}:t.cancelled?{schemaVersion:1,reason:"cancelled",cause:null}:{schemaVersion:1,reason:"no_report",cause:LW(t)}}function LW(t){return t.runnerProviderNotReady?"runner_provider_not_ready":t.credentialMissing?"credential_missing":t.checkoutFailed?"checkout_failed":t.environmentUnverified?"environment_unverified":t.setupFailed?"setup_failed":t.timedOut?"timed_out":t.modelProviderDenied?"model_provider_denied":t.modelProviderUnavailable?"model_provider_unavailable":"agent_failed"}var rre={"application/pdf":"PDF","text/csv":"CSV","application/vnd.openxmlformats-officedocument.wordprocessingml.document":"DOCX","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"XLSX"};var OW=10*1024*1024;var ET=Re(require("fs")),$u="SKYRAMP_AZURE_SUPERVISED",zy=3;function ep(t){return t.replace(/##(?=(?:vso)?\[)/gi,"#\u200B#")}function Ky(t,e=process.env){e[$u]==="1"?ET.writeSync(zy,`${JSON.stringify(t)}
120
+ `)){if(!s.trim()||s.length>1&&s[1]==="D")continue;let i=s.slice(3).trim(),a=i.indexOf(" -> ");if(a!==-1&&(i=i.slice(a+4).trim()),i=i.replace(/^"|"$/g,""),!i)continue;let c=i.replace(/^\.\//,"");c.startsWith(".skyramp/")||!n(c)||r.push(c)}return r}function QJ(t){let e=Gd[t],n=t==="ui";return{name:`${e.stage}-no-litter`,verify(r){let s=x0(r.inputs.repositoryPath);if(s===void 0)return{name:this.name,passed:!0};let i=s.filter(a=>BJ.test(a)===n);return i.length===0?{name:this.name,passed:!0}:Mt(this.name,[`${e.stage} left files outside .skyramp/ \u2014 move the staged test into .skyramp/staged/ and delete any codegen draft (e.g. *_scaffold.*): ${i.slice(0,6).join(", ")}`])}}}var l6=QJ("backend");var Mu=Re(require("fs")),fo=Re(require("path"));function N0(t){return ts(Qy,t).errors}function SJ(t,e=[]){let{value:n,error:r}=jt(t,e);if(r)return{errors:[r]};let s=N0(n);return s.length>0?{errors:s}:{adapt:n,errors:[]}}var kJ="adapt-scratch",T0=`${kJ}/adapt-result.json`;function F0(t,e){let n=fo.join(t.outputsDir,T0),r;try{r=Mu.readFileSync(n,"utf-8")}catch{r=void 0}if(r!==void 0&&(t.secretValues??[]).some(a=>r.includes(a)))return{errors:[`${T0} contains a secret value (token / credential) \u2014 never write it anywhere`]};let s=SJ(e.stdout,t.secretValues);if(s.adapt)return s;let i=r!==void 0?va(n):void 0;return i!==void 0&&N0(i).length===0?{adapt:i,errors:[]}:s}var F6=Us("adapt-schema",F0);var G6=2*1024*1024;var le=u.string().trim().min(1),RJ=t=>{if(!t||typeof t!="object")return t;let e=t;return typeof e.skip=="string"&&e.skip.trim()&&(e.expected===void 0||e.expected===null)?{...e,expected:"(not tested)"}:t},xJ=u.preprocess(RJ,u.object({id:le.describe(`its requirement's id plus a letter, e.g. "R1a", "AC-3a"`),clause:le.describe("one testable part of the requirement"),expected:le.describe("the outcome the requirement calls for \u2014 taken from the requirement, never from what the code does"),skip:u.string().optional().describe("only when no test can check this clause here: why"),type:u.nativeEnum(Gs).optional().describe("the test that checks this clause: contract / integration (the API, or code called directly in-process: a function, hook or module) or ui (a page)"),target:u.string().optional().describe('its "METHOD /path", or the page / flow'),steps:u.string().optional().describe("what that test does; its expected outcome is this clause's"),finding:u.string().optional().describe("the finding id, when this clause's test also catches that defect (the defect still gets a case of its own)"),code:u.string().optional().describe("path:line of the code that decides this clause, when there is one"),mutates:u.boolean().optional().describe("true when its test changes state, in the test or its setup: an API POST, PUT, PATCH or DELETE, or a UI flow that submits, creates, edits or deletes"),browserOnly:u.boolean().optional().describe("true when its behaviour happens only in a browser: real clicks or keys driving page script, client-side sorting or filtering, script-driven DOM updates, focus, drag-and-drop, navigation, rendering that depends on CSS or JavaScript"),browserHarness:u.string().optional().describe("browserOnly, off the runtime path: the path of the repo's in-process browser suite its test goes in (e.g. a Django StaticLiveServerTestCase test that drives Selenium)")})),TJ=u.object({id:le.describe('the label its source gives it ("AC-3", "REQ-12"; item 4 of a numbered list is "R4"), else "R1", "R2"\u2026 in order'),statement:le,source:u.nativeEnum(Va).describe("requirement-reference (an item the run was given), spec, pr-description (also for what the change is evidently meant to do when nothing is written down), or could-break (what the change could break that no requirement mentions)"),reference:u.string().optional().describe('requirement-reference only: the key of its item as listed, e.g. "PAY-184", or a Confluence page id such as "3021"'),evidence:le.describe("where it is stated: for requirement-reference, the item's own words, copied exactly; else file:line, a doc section, or the quoted phrase"),criterion:u.number().int().positive().optional().describe("requirement-reference only: leave it out; Testbot numbers each criterion by the item's own label (AC2, 2.), else after the item's labels"),notInChange:u.string().optional().describe("requirement-reference only: when the change does not touch this criterion at all (e.g. a later step of a staged rollout), why; give it no clauses"),overrules:u.array(u.object({spec:u.string().optional().describe("file:line of the spec in the repository; leave it out for a PR description"),prDescription:u.boolean().optional().describe("true when a pull request description says otherwise"),says:le.describe("what the spec or the PR description says there, in its own words, copied exactly")}).refine(t=>!!(t.prDescription||t.spec?.trim()),{message:'names no source: give "spec" its file:line, or set "prDescription"'})).optional().describe("requirement-reference only: each spec in the repository, and each PR description, that says otherwise; the item wins, so test what it says"),clauses:u.array(xJ)}),M0=(s=>(s.ServerError="server-error",s.DataLost="data-lost",s.FinalState="final-state",s.DerivedValues="derived-values",s))(M0||{}),DJ=u.object({id:le.describe('e.g. "F1"'),file:le,line:u.number().optional(),claim:le.describe("the defect, in one sentence"),severity:u.nativeEnum(Tu),evidence:le.describe("the code line, or the probe request and response, that shows it"),conflictsWith:u.array(le).optional().describe("requirement or clause ids it violates"),keeps:u.string().optional().describe("for a defect no requirement or clause states: path:line of the code beside the change that keeps the rule it breaks"),rule:u.nativeEnum(M0).optional().describe("for a defect that breaks a rule every app keeps, which nothing needs to state: which one"),existing:u.string().optional().describe("only when the base already does this, in code the change left as it was: where the base does it (its file:line); such a defect gets no case"),needsApp:u.enum(["browser","live-api"]).optional().describe("only when the running app alone can show this defect and the repo has no in-process test that can: browser (page script, what the user sees after a click or a save) or live-api (code the repo tests only against the running app's API)")}),NJ=u.object({id:le.describe('e.g. "Q1"'),question:le.describe("what is unsettled, as a question the PR author can answer"),readings:u.array(le).min(2).describe("each reasonable behaviour, with what points to it (file:line, or the words that suggest it)"),about:u.string().optional().describe("the requirement or clause id it is about, when there is one")}),FJ=u.object({id:le.describe('unique, a short kebab-case name for what the case checks, e.g. "ship-twice-409"'),type:u.nativeEnum(Gs).describe("contract / integration: checks the API, or calls code directly in-process (a function, hook or module); ui: checks what a user sees or does on a page"),target:le.describe('"METHOD /path", or the page / flow'),clause:u.string().optional().describe("the clause id this case checks"),finding:u.string().optional().describe("the finding id this case catches"),steps:le.describe("what the test does"),expected:le.describe("the expected outcome, from the clause"),mutates:u.boolean().optional().describe("true when its test changes state, in the test or its setup: an API POST, PUT, PATCH or DELETE, or a UI flow that submits, creates, edits or deletes")}),MJ=u.object({test:le.describe("existing test file"),action:u.nativeEnum(uo),reason:le,mutates:u.boolean().optional().describe("true when the maintained test changes state"),clauses:u.array(le).optional().describe("the clause ids this test checks")}),_J=u.object({outcome:u.nativeEnum(ns).describe("clean | recipe-drift (you had to fix the recipe) | change-broke-bringup (this PR broke start-up) | bringup-failed (the environment, not the PR)"),baseUrls:u.record(u.string()).optional().describe("service \u2192 base URL of the running app"),health:u.object({url:u.string().optional(),command:u.string().optional(),output:u.string().optional()}).optional().describe("the check that shows the app serves real data, and what it returned"),teardown:u.string().optional().describe("command that stops the app"),dependencies:u.record(u.boolean()).optional().describe("every backing service: true = really running, false = mocked"),recipeFixes:u.array(u.string()).optional().describe("what you changed in the recipe"),error:u.string().optional().describe("when it did not come up: the failing command and what it printed"),suspectFiles:u.array(u.string()).optional().describe("change-broke-bringup: the changed files to blame"),login:u.object({username:le,password:u.string()}).optional().describe("the account the tests sign in as, when they sign in: each a literal value the recipe seeds, or $VARIABLE when a secret in the environment holds it"),revisions:py.optional()}),C7=u.object({schemaVersion:u.literal(1),requirements:u.array(TJ),findings:u.array(DJ),cases:u.array(FJ).describe("a second test for a clause, and one case per finding that fails on this branch"),questions:u.array(NJ).optional().describe("behaviours the change leaves unsettled; no case asserts any of them"),maintenance:u.array(MJ),journeys:u.array(E0).optional().describe("the user journeys that, together, pass through everything the change alters that a user sees or does; empty when it alters nothing a user sees"),notInJourney:u.array(u.object({clause:le,why:le})).optional().describe("a clause a user sees or does that no journey can reach through the UI, and why"),triage:Fu.optional().describe("the validation triage decision, made before the app is started; its behaviorIds are clause ids"),app:_J.optional().describe("omit when no app was needed or none was started"),summary:le.describe("one paragraph: what the change does and where the risk is")});var _0=(n=>(n.Backend="backend",n.Ui="ui",n))(_0||{});var _y=(s=>(s.Added="added",s.Updated="updated",s.Deleted="deleted",s.Unchanged="unchanged",s))(_y||{}),UJ=u.object({file:le.describe("repo-relative path; in another repo of the change, that repo's directory name then its path"),kind:u.nativeEnum(_0),change:u.nativeEnum(_y).describe("added: a file you created; updated / deleted / unchanged: an existing test"),covers:u.array(u.string()).describe("the plan case ids this file tests"),defect:u.boolean().optional().describe("true when a case of it fails because the app is wrong and the test is right \u2014 kept failing on purpose"),staleBecause:u.object({requirement:le.describe("the requirement or clause id the change deliberately alters"),line:le.describe("path:line (or path) of the application code the change altered that makes this test's old expectation wrong")}).optional().describe("for an existing test you updated: why it is out of date"),result:u.object({exit:u.number().nullable().describe("exit code of your last run of this file; null if it could not be run"),cases:u.array(u.object({case:le,status:u.nativeEnum(Kn),defect:u.boolean().optional().describe("for a failing case: true when the app is wrong and the test is right; false when the test is at fault and you could not fix it"),failure:u.string().optional().describe("for a failing case: the runner's failure for it as printed (the error and the line it was raised at), not a summary"),cause:u.string().optional().describe("for a case you keep as a defect: path:line of the application code that makes it fail"),requires:u.string().optional().describe("for a case you keep as a defect: the words of the PR description, a requirement or clause of the plan, or the code a finding's keeps names, that state what its failing check expects, quoted exactly")})).describe("one entry per covered case, from the runner's own output"),details:u.string().optional().describe("what failed and why, or why it was not run")}),assertions:u.array(u.object({case:le,evidence:le})).optional().describe("per covered case, the assertion line that checks its expected outcome"),functions:u.array(u.object({name:le.describe("the test function as the runner names it within its file, without the file (test_x, TestClass::test_x, TestSuite/TestCase)"),cases:u.array(le).describe("the plan case ids it checks")})).optional().describe("for a file you added or updated: each test function in it and the plan case ids it checks"),skyramp:u.object({draft:u.union([u.string(),u.array(u.string())]).optional().describe("the draft path the Skyramp helper returned for this test, or each path when the test was made from several drafts"),handWritten:u.string().optional().describe("why it is written by hand: the helper call you made and what it returned")}).optional().describe("only for a test of a case the Skyramp API block lists: where it came from"),context:u.array(xy).optional().describe("what the test sets up outside its own process that another test could run into: data it creates in the app, a Skyramp mock, an env override; omit when none"),isolatedRun:le.optional().describe("for a test with a context: the command, from its checkout's root and without a shell, that runs only this file"),run:Ha.optional().describe(`for a file in ${Ya}, added, updated or re-run: how the run executes only this file's tests, with the repository's own runner and the report it writes (junit or trx to ${Zn}, or go-test-json); Testbot runs it before write ends and re-runs the tests with it`)}),LJ=u.object({description:le.describe("what is wrong and how to reproduce it: endpoint or page, input, what you got vs what was expected"),severity:u.nativeEnum(Tu).optional(),sourceFile:u.string().optional().describe("the app file at fault"),sourceLine:u.number().optional(),test:u.string().optional().describe("the test file that shows it"),finding:u.string().optional().describe("the plan's finding id, when it is one"),requirements:u.array(le).optional().describe("the plan's requirement or clause ids it violates")}),I7=u.object({schemaVersion:u.literal(1),tests:u.array(UJ),notWritten:u.array(u.object({case:le,reason:le})).describe("every plan case no test covers, and why"),journeys:u.array(Ud).optional().describe("one entry per planned user journey: the browser test that walks it end to end"),lint:u.object({command:u.string(),clean:u.boolean()}).optional().describe("the linter/formatter you ran on your test files, if the repo has one: the exact command, with its file paths (Testbot re-runs it)"),dependenciesAdded:u.array(u.object({package:le,manifest:le.describe("the manifest file's path relative to its checkout (e.g. package.json, pom.xml or pyproject.toml), and nothing else; name another checkout in repository"),repository:le.optional().describe("owner/repo of the manifest's checkout; omit for the repo under test"),reason:le.optional().describe("why the test must run inside the application's own test environment, so its manifest had to change \u2014 required for every entry")})).optional().describe("every package you added to an APPLICATION manifest (an exception, surfaced in the report); never the Testbot test package's own"),supportFiles:u.array(le).optional().describe("every file that is not a test you created or changed for your tests, which they need to compile or run (a helper module, page object, fixture, or a snapshot the runner wrote for them), named as you name a test; Testbot delivers only the tests you list and the files under supportFiles"),ciRunsTests:u.boolean().optional().describe("will the repo's CI pick these tests up as they are?"),ciNotes:u.string().optional().describe("when ciRunsTests is false: which of your tests the repo's CI will not collect, why, and the exact change the author must make for CI to run them"),commit:u.object({message:le.describe('"Skyramp Testbot: \u2026", subject line at most 72 characters'),prTitle:le.describe("at most 72 characters"),prBody:le.describe("what the tests cover and what they found")}),report:u.object({summary:le.describe("1-2 sentences for the PR author: does the change do what it says?"),issues:u.array(LJ).describe("every defect the tests found"),nextSteps:u.array(u.string())})});var B7={added:"place",updated:"update",deleted:"delete",unchanged:"verify"};var L0=(r=>(r.Requirement="requirement",r.PrDescription="pr_description",r.Code="code",r))(L0||{}),yt=u.string().trim().min(1),PJ=u.object({expectation:yt.max(300).describe("the behavior this assertion pins, in words"),source:u.nativeEnum(L0),expected:yt.max(200).describe("the exact value or outcome asserted, as the test asserts it")}),OJ=u.object({file:yt.describe("path of the NEW test file you wrote, relative to its repository"),repository:yt.optional().describe("owner/repo the file lives in, when the run has several checkouts; omit for the working checkout"),framework:yt.describe("the framework the repository runs this file with: pytest, jest, vitest, node-test, or the name of any other"),run:Ha.optional().describe(`for ${Ya}: how the run executes only the tests in names, with the repository's own runner writing JUnit XML to {junit}`),covers:u.array(yt).length(1).describe("the ONE behavior id, or defect id, from the plan that the tests in names provide evidence for; a file covering several is listed once per id"),names:u.array(yt).min(1).describe("the test functions/cases in the file that provide evidence for that behavior, as the framework names them"),assertions:u.array(PJ).min(1)}),Uy=(n=>(n.Updated="updated",n.Deleted="deleted",n))(Uy||{}),U0=300,$J=u.object({file:yt.describe("path of the EXISTING test file you updated or deleted, relative to its repository"),repository:yt.optional().describe("owner/repo the file lives in, when the run has several checkouts; omit for the working checkout"),change:u.nativeEnum(Uy),staleBecause:u.object({requirement:yt.describe("the requirement or clause id the change deliberately alters"),line:yt.describe("path:line (or path) of the application code the change altered that makes this test's old expectation wrong")}).optional().describe("for an existing test you updated: why it is out of date"),reason:u.preprocess(t=>typeof t=="string"?t.trim().slice(0,U0):t,yt.max(U0)).describe("what the change deliberately altered that made the test wrong")}),Ly=u.object({schemaVersion:u.literal(1),tests:u.array(OJ),maintained:u.array($J).optional().describe("existing tests the change made stale that you updated or deleted; omit when there were none"),defectsNotTested:u.array(u.object({id:yt,reason:yt.max(300)})).optional().describe("defects the plan found that no in-process test can reach, each with why; omit when every defect has a test"),journeys:u.array(Ud).optional().describe("one entry per planned user journey: the in-process test that walks it end to end"),journeysNotWritten:u.array(u.object({journey:yt,missing:yt.transform(t=>t.length>300?`${t.slice(0,299)}\u2026`:t)})).optional().describe("a planned journey no in-process test can walk here, with what it needs that is missing; it is reported as not covered"),lint:u.object({command:u.string(),clean:u.boolean()}).optional().describe("the linter/formatter you ran on your test files, if the repository has one you can run; omit otherwise"),commitMessage:yt.optional().describe("the commit message for your tests: a subject line of at most 72 characters, then what they cover")});var G7=5*6e4;function HJ(t){let{value:e,error:n}=jt(t);if(n)return{errors:[n]};let{value:r,errors:s}=ts(Ly,e);return s.length?{errors:s}:{output:r,errors:[]}}function YJ(t){return HJ(t.stdout)}var jee=Us("generate-unit-schema",(t,e)=>YJ(e));var Hd=String.raw`(?:node:)?(?:http|https|http2|net|tls|dgram)`,Jee=[[/\b(localhost|127\.0\.0\.1|0\.0\.0\.0)\b/,"a local server address"],[/^\s*(import|from)\s+(requests|aiohttp|urllib3|websockets?)\b/m,"an HTTP client"],[/^\s*(?:import|from)\s+(?:urllib\.request|http\.client|http\.server|socket|ssl|ftplib|smtplib|telnetlib)\b|^\s*from\s+urllib\s+import\b[^\n]*\brequest\b|\burlopen\s*\(/m,"a standard-library network client"],[/\bfrom\s+["'](axios|node-fetch|undici|ws)["']|require\(\s*["'](axios|node-fetch|undici|ws)["']\s*\)/,"an HTTP client"],[new RegExp(String.raw`\bfrom\s+["']${Hd}["']|\bimport\s+["']${Hd}["']|require\(\s*["']${Hd}["']\s*\)|\bimport\(\s*["']${Hd}["']\s*\)`),"Node's network modules"],[/\bfetch\s*\(|\bnew\s+(XMLHttpRequest|WebSocket)\b/,"a network call (fetch, XMLHttpRequest, WebSocket)"],[/\bskyramp\b/i,"the Skyramp runtime (a runtime mock or client)"]];var O0=String.raw`\b(?:real browser|browser|javascript|js|htmx|client-side)\b`,$0=String.raw`\b(?:not|isn't|aren't|never|no)\s+(?:be\s+)?(?:covered|tested|exercised|verified|checked|walked|executed|run)\b|\buncovered\b|\bunverified\b`,ute=[new RegExp(`${O0}[^.;\\n]{0,100}(?:${$0})`,"i"),new RegExp(`(?:${$0})[^.;\\n]{0,100}${O0}`,"i")];var Ate=new Set(["targeted_unit","existing_evidence_sufficient"]);var Kte=new Set(["existing_evidence","unaffected","existing_unit","new_unit","runtime"]),Zte={existing_evidence:"existing evidence",unaffected:"showing the change cannot reach it",existing_unit:"running the existing unit tests",new_unit:"a new unit test",runtime:"tests against the running application"};function zJ(t){let{value:e,error:n}=jt(t);if(n)return{errors:[n]};let{value:r,errors:s}=ts(Fu,e);return s.length?{errors:s}:{triage:r,errors:[]}}function KJ(t){return zJ(t.stdout)}var Xte=Us("triage-schema",(t,e)=>KJ(e));var ene=new Set(["deploy","recommend","generate","generate-ui","adapt","generate-unit","native-run","finalize","deliver"]);Dt();Dt();var XJ="Skyramp-Pull-Request",eW="Skyramp-Delivery-Base",tW="Skyramp-Tested-Revision";var Ene=["%H","%P","%an","%ae","%ce",`%(trailers:key=${XJ},valueonly,separator=%x2C)`,"%s",`%(trailers:key=${eW},valueonly,separator=%x2C)`,`%(trailers:key=${tW},valueonly,separator=%x2C)`];var qd=(n=>(n.GitHub="github",n.AzureDevOps="azure-devops",n))(qd||{}),$y=(i=>(i.Trigger="TRIGGER",i.Baseline="BASELINE",i.AuthoritativeRelatedChange="AUTHORITATIVE_RELATED_CHANGE",i.ConfiguredSharedDependency="CONFIGURED_SHARED_DEPENDENCY",i.ManualOverride="MANUAL_OVERRIDE",i))($y||{}),Uu=(a=>(a.PullRequest="pull_request",a.ReadyForReview="ready_for_review",a.Schedule="schedule",a.Manual="manual",a.SutSetup="sut_setup",a.RevisionRead="revision_read",a))(Uu||{}),sW=["sut_setup"],iW=["sut_setup","schedule","revision_read"];var jd=(e=>(e.PullRequest="pull_request",e))(jd||{}),Lu=(s=>(s.ModelProvider="model_provider",s.SutAccess="sut_access",s.Skyramp="skyramp",s.Other="other",s))(Lu||{});var Jd=(i=>(i.ReportUploaded="report_uploaded",i.NoReport="no_report",i.Cancelled="cancelled",i.RecipeUploaded="recipe_uploaded",i.RevisionsUploaded="revisions_uploaded",i))(Jd||{}),X0=(n=>(n.Running="running",n.Ended="ended",n))(X0||{}),Wd=(p=>(p.TimedOut="timed_out",p.AgentFailed="agent_failed",p.SetupFailed="setup_failed",p.CredentialMissing="credential_missing",p.RunnerLost="runner_lost",p.CheckoutFailed="checkout_failed",p.EnvironmentUnverified="environment_unverified",p.ModelProviderDenied="model_provider_denied",p.ModelProviderUnavailable="model_provider_unavailable",p.RunnerProviderNotReady="runner_provider_not_ready",p))(Wd||{}),Vy=(r=>(r.Onboard="onboard",r.Deploy="deploy",r.Recheck="recheck",r))(Vy||{}),Gy=(n=>(n.Started="started",n.Finished="finished",n))(Gy||{}),Hy=(r=>(r.Passed="passed",r.Failed="failed",r.Skipped="skipped",r))(Hy||{});var Yy=(r=>(r.ChooseCredential="choose_credential",r.FreeText="free_text",r.ChooseSource="choose_source",r))(Yy||{});var zd=(r=>(r.Discover="discover",r.Start="start",r.Check="check",r))(zd||{}),Kd=(s=>(s.ValidationPlan="validation_plan",s.TestEnvironment="test_environment",s.TestConditions="test_conditions",s.Tests="tests",s))(Kd||{}),Pu=(s=>(s.Found="found",s.Starting="starting",s.Up="up",s.OutOfScope="out_of_scope",s))(Pu||{}),Xn=u.string().regex(/^[1-9][0-9]{0,18}$/),as=u.string().regex(/^(?:[0-9a-f]{40}|[0-9a-f]{64})$/),Ja=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/,_t=u.string().regex(Ja),Ut=u.string().regex(/^[0-9a-f]{64}$/),Yd=u.object({id:_t,revision:Xn}).strict(),Zd={provider:u.literal("github"),providerAccountId:Xn,providerRepositoryId:Xn},Xd={provider:u.literal("azure-devops"),providerAccountId:_t,providerRepositoryId:_t},er=u.discriminatedUnion("provider",[u.object(Zd).strict(),u.object(Xd).strict()]),qy=u.discriminatedUnion("provider",[u.object(Zd).passthrough(),u.object(Xd).passthrough()]),go=t=>`${t.provider}:${t.providerRepositoryId}`,V0={namespace:u.string().min(1),name:u.string().min(1)},eT=u.discriminatedUnion("provider",[u.object({...Zd,...V0}).strict(),u.object({...Xd,...V0}).strict()]),G0=u.object({ref:u.string().min(1),revision:as}).strict(),oW=u.object({repository:eT,revision:as,ref:u.string().nullable(),reason:u.nativeEnum($y),change:u.object({kind:u.nativeEnum(jd),number:Xn,base:G0.optional()}).strict().nullable(),compareWith:G0.optional()}).strict();function aW(t){if(t.trigger.kind==="revision_read"!=!t.baseline)return t.baseline?"a revision_read run names no baseline":"names its baseline";if(!t.baseline)return null;let{confirmedRunId:e,initialBaselineId:n,sources:r}=t.baseline;if(e!==null&&n!==void 0)return"a run compares with one baseline";let s=t.trigger.kind==="schedule"&&e!==null||n!==void 0;if(!r)return s?"names every source of the snapshot, once":null;if(e===null&&n===void 0)return"a run with no Confirmed Baseline names no baseline sources";let i=new Set(t.sources.map(A=>go(A.repository))),a=new Set(r.map(A=>go(A.repository)));return a.size===r.length&&a.size===i.size&&[...a].every(A=>i.has(A))?null:"names every source of the snapshot, once"}var tT=/^[A-Z][A-Z0-9_]+-[1-9][0-9]*$/,nT=/^[1-9][0-9]{0,18}$/,H0=new RegExp(`${tT.source}|${nT.source}`),Y0=/^https:\/\/[a-z0-9-]+(\.[a-z0-9-]+)+$/,cW=u.union([u.object({source:u.literal("jira"),site:u.string().regex(Y0),key:u.string().regex(tT),updated:u.string().datetime(),contentHash:Ut}).strict(),u.object({source:u.literal("confluence"),site:u.string().regex(Y0),key:u.string().regex(nT),version:u.number().int().positive(),contentHash:Ut}).strict(),u.object({source:u.literal("other"),key:u.string().regex(Ed),contentHash:Ut}).strict(),u.object({source:u.literal("other"),key:u.string().regex(mu),contentHash:Ut,fileName:u.string().min(1).max(255),mediaType:u.nativeEnum(yu)}).strict()]),q0=u.union([u.literal("jira"),u.literal("confluence")]),uW=u.object({schemaVersion:u.literal(1),items:u.array(u.union([u.object({source:q0,site:u.string(),key:u.string().regex(H0),state:u.literal("read"),text:u.string(),version:u.string().min(1),contentMatches:u.boolean()}).strict(),u.object({source:q0,site:u.string(),key:u.string().regex(H0),state:u.literal("not_read"),reason:u.nativeEnum(qi)}).strict(),u.object({source:u.literal("other"),key:u.string().regex(Ed),state:u.literal("read"),text:u.string(),version:u.string().min(1),contentMatches:u.boolean()}).strict(),u.object({source:u.literal("other"),key:u.string().regex(Ed),state:u.literal("not_read"),reason:u.nativeEnum(qi)}).strict(),u.object({source:u.literal("other"),key:u.string().regex(mu),state:u.literal("read"),version:Ut,fileName:u.string().min(1).max(255),mediaType:u.nativeEnum(yu)}).strict(),u.object({source:u.literal("other"),key:u.string().regex(mu),state:u.literal("not_read"),reason:u.nativeEnum(qi)}).strict()])),instructions:u.array(u.string()).optional()}).strict(),AW=u.object({schemaVersion:u.literal(1),runId:_t,skyrampOrgId:_t,target:Yd,policy:Yd.nullable(),trigger:u.object({kind:u.nativeEnum(Uu),requestedAt:u.string().datetime()}).strict(),configuration:u.object({captureId:_t,revision:Xn.nullable(),hash:Ut}).strict(),baseline:u.object({confirmedRunId:_t.nullable(),initialBaselineId:_t.optional(),sources:u.array(u.object({repository:er,revision:as}).strict()).optional()}).strict().optional(),sources:u.array(oW).min(1),execution:u.object({provider:u.nativeEnum(qd),repository:eT,workflowPath:u.string(),ref:u.string()}).strict(),credentials:u.array(u.object({name:u.string(),purpose:u.nativeEnum(Lu),required:u.boolean()}).strict()),requirements:u.array(cW).min(1).optional(),instructions:u.object({contentHash:Ut}).strict().optional(),deployedRevisions:u.array(u.object({repository:er,revision:as}).strict()).min(1).optional()}).strict().superRefine((t,e)=>{let n=new Set;(t.requirements??[]).forEach((A,l)=>{let p="fileName"in A?"file":"pasted";A.source==="other"&&A.key!==`${p}-${A.contentHash.slice(0,16)}`&&e.addIssue({code:u.ZodIssueCode.custom,message:"is not the key of its content hash",path:["requirements",l,"key"]});let h=oy({source:A.source,key:A.key});n.has(h)&&e.addIssue({code:u.ZodIssueCode.custom,message:"names an item that the run already names",path:["requirements",l,"key"]}),n.add(h)});let r=t.trigger.kind,s=sW.includes(r);s!==(t.policy===null)&&e.addIssue({code:u.ZodIssueCode.custom,path:["policy"],message:s?`a ${r} run has no policy`:"names the policy revision"});let i=aW(t);i&&e.addIssue({code:u.ZodIssueCode.custom,path:t.baseline?["baseline","sources"]:["baseline"],message:i}),iW.includes(r)&&t.sources.forEach((A,l)=>{A.reason!=="BASELINE"&&e.addIssue({code:u.ZodIssueCode.custom,path:["sources",l,"reason"],message:`a ${r} run selects only BASELINE sources`})}),t.deployedRevisions&&r!=="manual"&&e.addIssue({code:u.ZodIssueCode.custom,path:["deployedRevisions"],message:"only a manual run pins deployed revisions"});let a=new Set(t.sources.map(A=>go(A.repository))),c=new Set;(t.deployedRevisions??[]).forEach((A,l)=>{let p=go(A.repository);a.has(p)?c.has(p)&&e.addIssue({code:u.ZodIssueCode.custom,path:["deployedRevisions",l,"repository"],message:"repository appears twice"}):e.addIssue({code:u.ZodIssueCode.custom,path:["deployedRevisions",l,"repository"],message:"names a repository outside the snapshot"}),c.add(p)}),t.sources.forEach((A,l)=>{A.compareWith&&(A.reason!=="MANUAL_OVERRIDE"||A.change)&&e.addIssue({code:u.ZodIssueCode.custom,path:["sources",l,"compareWith"],message:"only a MANUAL_OVERRIDE source without a change names a revision to compare with"})})});var rT=(n=>(n.Person="person",n.Policy="policy",n))(rT||{}),lW=u.object({kind:u.nativeEnum(rT),name:u.string().min(1).max(256)}).strict(),zne=u.object({schemaVersion:u.literal(1),attempt:u.object({id:_t,number:u.number().int().positive(),deadlineAt:u.string().datetime()}).strict(),manifest:AW,manifestHash:Ut,entitlements:u.array(u.string()).optional(),runToken:u.string().min(1).optional(),requestedBy:lW.nullable().optional(),writeAllowed:u.boolean().optional(),claudeCodeVersion:u.string().regex(/^[0-9]+\.[0-9]+\.[0-9]+$/,"an exact version, such as 2.1.290").nullable().optional(),deployedRevisions:u.array(u.object({repository:er,revision:as}).strict()).optional(),statedRevisions:u.array(u.object({repository:er,revision:as}).strict()).optional()}).strict(),j0={providerRunAttempt:u.number().int().positive(),workflowRef:u.string().min(1)},dW=u.string().regex(/^[^/]+\/[^/]+\/[1-9][0-9]{0,15}\/[1-9][0-9]{0,15}$/),Kne=u.object({schemaVersion:u.literal(1),runId:_t,execution:u.discriminatedUnion("provider",[u.object({...j0,provider:u.literal("github"),repository:u.object(Zd).strict(),providerRunId:Xn}).strict(),u.object({...j0,provider:u.literal("azure-devops"),repository:u.object(Xd).strict(),providerRunId:dW}).strict()]),requester:u.literal(!0).optional(),writeCheck:u.literal(!0).optional(),claudeCodePin:u.literal(!0).optional(),deployedPins:u.literal(!0).optional(),statedPins:u.literal(!0).optional()}).strict(),J0=u.object({repository:er,number:Xn}).strict(),pW=u.discriminatedUnion("status",[u.object({status:u.literal("none")}).strict(),u.object({status:u.literal("delivered"),pullRequests:u.array(J0).min(1)}).strict(),u.object({status:u.literal("partial"),pullRequests:u.array(J0).min(1),failures:u.array(u.object({repository:er,message:u.string()}).strict()).min(1)}).strict(),u.object({status:u.literal("failed"),message:u.string()}).strict()]),hW=u.object({blockedPreflight:u.object({file:u.string().min(1),repository:u.string().min(1).optional(),reason:u.string().min(1).max(300),evidence:u.string().min(1).max(400)}).strict().optional(),sufficiency:u.nativeEnum(Sa),rationale:u.string().min(1),gaps:u.array(u.string().min(1)),acceptedEvidence:u.array(u.object({kind:u.nativeEnum(_s),repository:u.string().min(1),revision:as,reference:u.string().min(1),summary:u.string().min(1)}).strict()),actionRequired:u.array(u.nativeEnum(ka))}).strict().superRefine((t,e)=>{t.sufficiency==="insufficient"!=t.gaps.length>0&&e.addIssue({code:u.ZodIssueCode.custom,path:["gaps"],message:"only insufficient evidence names gaps, and it names at least one"}),new Set(t.actionRequired).size!==t.actionRequired.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["actionRequired"],message:"a reason appears twice"})}),Py=500,fW=2048,gW=1e3,mW=/[\\/:*?"<>|;#$*{},+=[\]%\p{Cc}\p{Cf}]/u,W0=t=>t.length>0&&t.length<=64&&t===t.trim()&&!mW.test(t)&&!/[^\S ]/u.test(t)&&!/^[._]/.test(t)&&!t.endsWith("."),yW=t=>{if(/^[A-Za-z0-9._-]{1,100}\/[A-Za-z0-9._-]{1,100}$/.test(t))return!0;let[e,n,r,...s]=t.split("/");return t.length<=201&&s.length===0&&r!==void 0&&/^[A-Za-z0-9](?:[A-Za-z0-9-]{0,48}[A-Za-z0-9])?$/.test(e)&&W0(n)&&W0(r)},EW=u.object({testResults:u.array(u.object({resultId:u.string().regex(/^[^\u0000-\u001f]{1,512}$/),repository:u.string().refine(yW,"Invalid"),testType:u.string(),endpoint:u.string(),status:u.enum(["Pass","Fail","Skipped"]),details:u.string(),fileName:u.string().optional(),testId:u.string().regex(/^[^\u0000-\u001f]{1,512}$/).optional(),failureCause:u.object({kind:u.nativeEnum(cy),family:u.nativeEnum(uy).optional()}).strict().optional(),origin:u.nativeEnum(ay).optional()}).strict()),validation:hW,changes:u.array(u.object({id:u.string().min(1).max(512),text:u.string().max(16384),source:u.string().max(fW),testedBy:u.array(u.string().min(1).max(1024)).max(Py),writtenBy:u.array(u.string().min(1).max(1024)).max(Py),maintainedBy:u.array(u.string().min(1).max(1024)).max(Py)}).strict()).max(gW).optional(),traceVersion:u.literal(1)}).passthrough().superRefine((t,e)=>{let n=new Set;t.testResults.forEach((r,s)=>{let i=r.failureCause;i&&r.status==="Pass"&&e.addIssue({code:u.ZodIssueCode.custom,path:["testResults",s,"failureCause"],message:"a passing result has no failure cause"}),i&&i.kind==="environment"!=(i.family!==void 0)&&e.addIssue({code:u.ZodIssueCode.custom,path:["testResults",s,"failureCause"],message:"an environment cause names its family, and no other cause does"});let a=["testResults",s,"resultId"],c=r.resultId.slice(`${r.repository}:${r.testType}:`.length);(!r.resultId.startsWith(`${r.repository}:${r.testType}:`)||c===""||c.startsWith("/")||c.startsWith("#"))&&e.addIssue({code:u.ZodIssueCode.custom,path:a,message:"is not repository:testType:path for this result"}),n.has(r.resultId)&&e.addIssue({code:u.ZodIssueCode.custom,path:a,message:"stable identity repeated"}),n.add(r.resultId)})});var sT=50,z0=u.string().regex(/^(?!.*\.\.)(?!\/)(?!.*\/$)[A-Za-z0-9._/-]{1,255}$/),iT=u.discriminatedUnion("kind",[u.object({kind:u.literal("branch_pushed"),repository:er,branch:z0,commit:as}).strict(),u.object({kind:u.enum(["pull_request_opened","pull_request_edited"]),repository:er,number:Xn,branch:z0}).strict()]),CW=u.object({schemaVersion:u.literal(1),run:u.object({runId:_t,attemptNumber:u.number().int().positive(),manifestHash:Ut}).strict(),target:Yd,policy:Yd,provenance:u.object({sources:u.array(u.object({repository:er,revision:as}).strict()),firstQualification:u.literal(!0).optional()}).strict(),delivery:u.object({generatedTests:pW}).strict(),producer:u.object({testbot:u.string().regex(/^[0-9A-Za-z.+-]{1,64}$/),mcp:u.string().regex(/^[0-9A-Za-z.+-]{1,64}$/)}).strict(),report:EW,githubWrites:u.array(iT).max(sT).optional()}).strict(),Zne=CW.pick({schemaVersion:!0,run:!0,target:!0,provenance:!0,producer:!0}).extend({recipe:Sy}).strict().superRefine(({recipe:t},e)=>{let n=(i,a)=>e.addIssue({code:u.ZodIssueCode.custom,path:["recipe",...i],message:a});t.status==="blocked"&&t.blockers.length===0&&n(["blockers"],"a blocked recipe names at least one blocker");let r=new Set,s=0;t.files.forEach((i,a)=>{Ru(i.path)||n(["files",a,"path"],"is not .skyramp/workspace.yml or a file under .skyramp/sut/"),r.has(i.path)&&n(["files",a,"path"],"file repeated"),r.add(i.path),fy.test(i.content)&&n(["files",a,"content"],"is not text");let c=Buffer.byteLength(i.content,"utf8");s+=c,c>ku&&n(["files",a,"content"],`larger than ${ku} bytes`)}),s>vu&&n(["files"],`recipe text over ${vu} bytes in total`)}),Xne=u.object({components:u.array(u.object({name:u.string().min(1),repository:u.string().regex(/^[A-Za-z0-9._-]{1,100}\/[A-Za-z0-9._-]{1,100}$/),observedRevision:u.string().regex(/^[0-9a-f]{7,64}$/).nullable(),source:u.nativeEnum(Cd),evidence:u.string()}).strict().refine(t=>t.source!=="agent"||t.observedRevision===null,{path:["observedRevision"],message:"a component only an agent session can read names no revision"}))}).strict();var IW=u.object({schemaVersion:u.literal(1),stage:u.nativeEnum(Vy),event:u.nativeEnum(Gy),status:u.nativeEnum(Hy).optional()}).strict().refine(t=>t.status===void 0||t.event==="finished",{path:["status"],message:"only a finished stage has a status"}),Wa=100,jy=5e3,_u=2e3,Oy=100,Jy=/^[A-Za-z0-9_-]{1,64}$/,oT=20,aT=200,cT=100,uT=100,BW=200,K0="[^/\\s](?:(?:[^/\\s]| )*[^/\\s])?",QW=new RegExp(`^(?:[^/\\s]+/[^/\\s]+|[^/\\s]+/${K0}/${K0})$`),AT=500,lT=50,Ou=/[\u0000-\u0008\u000b\u000c\u000e-\u001f\u007f]|[\ud800-\udbff](?![\udc00-\udfff])|(?<![\ud800-\udbff])[\udc00-\udfff]/,xn=t=>u.string().max(t).refine(e=>e.trim().length>0&&!Ou.test(e),"blank, or not text"),os={sequence:u.number().int().min(1).max(jy),at:u.string().regex(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d{1,6})?Z$/)},dT=u.discriminatedUnion("kind",[u.object({...os,kind:u.literal("log"),phase:u.nativeEnum(zd),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("component"),name:xn(Oy),repository:xn(BW).refine(t=>QW.test(t)||t===zt,"not owner/name"),file:xn(AT).nullable(),status:u.nativeEnum(Pu),version:xn(uT).optional()}).strict(),u.object({...os,kind:u.literal("reply"),to:u.string().uuid(),accepted:u.boolean(),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("question"),id:u.string().regex(Jy),type:u.nativeEnum(Yy),text:xn(_u),component:xn(Oy).nullable(),choices:u.array(xn(aT)).max(oT),placeholder:xn(cT).optional()}).strict(),u.object({...os,kind:u.literal("delivered"),ids:u.array(u.string().uuid()).max(Wa)}).strict(),u.object({...os,kind:u.literal("credentials"),names:u.array(u.string().regex(La)).min(1).max(lT)}).strict()]).superRefine((t,e)=>{t.kind==="credentials"&&new Set(t.names).size!==t.names.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["names"],message:"a name twice"}),t.kind==="question"&&(t.type==="free_text"!=(t.choices.length===0)&&e.addIssue({code:u.ZodIssueCode.custom,path:["choices"],message:"choices exactly when the question is not free_text"}),new Set(t.choices).size!==t.choices.length&&e.addIssue({code:u.ZodIssueCode.custom,path:["choices"],message:"a choice twice"}))}),wW=u.object({schemaVersion:u.literal(1),events:u.array(dT).max(Wa)}).strict(),pT=u.discriminatedUnion("kind",[u.object({...os,kind:u.literal("log"),stage:u.nativeEnum(Kd),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("reply"),to:u.string().uuid(),accepted:u.boolean(),text:xn(_u)}).strict(),u.object({...os,kind:u.literal("delivered"),ids:u.array(u.string().uuid()).max(Wa)}).strict()]),bW=u.object({schemaVersion:u.literal(1),events:u.array(pT).max(Wa)}).strict(),Z0={id:u.string().uuid(),text:u.string(),by:u.string().nullable(),at:u.string(),replied:u.literal(!0).optional()},hT=u.discriminatedUnion("kind",[u.object({...Z0,kind:u.literal("instruction"),question:u.null()}),u.object({...Z0,kind:u.literal("answer"),question:u.string().regex(Jy)})]),fT=u.string().regex(/^[A-Za-z0-9+/]{43}=$/),SW=u.object({id:u.string().uuid(),revision:u.string(),by:u.string().nullable(),at:u.string(),target:u.string(),own:u.object({source:u.enum(["policy","test_environment"]),text:u.string()}).nullable()}),kW=u.object({schemaVersion:u.literal(1),leftOut:u.array(u.string()),messages:u.array(hT).optional(),stop:u.object({key:fT}).optional(),notes:SW.optional()}),vW=u.object({schemaVersion:u.literal(1),messages:u.array(hT).optional()});var gT=500*1024*1024,mT=u.object({id:Xn,name:u.string().regex(/^[A-Za-z0-9._-]{1,200}$/),providerRunId:Xn,expiresAt:u.string().datetime()}).strict(),RW=u.object({schemaVersion:u.literal(1),artifact:mT,sessionId:_t,contentHash:Ut,bytes:u.number().int().min(1).max(gT)}).strict(),xW=u.object({schemaVersion:u.literal(1),checkpoint:u.object({artifact:mT,repository:u.object({namespace:u.string().min(1),name:u.string().min(1)}).strict(),sessionId:_t,contentHash:Ut,key:fT}).strict().nullable()}).strict(),TW=200,ja=100,Wy=(r=>(r.Resume="resume",r.Retry="retry",r.Update="update",r))(Wy||{}),DW=u.object({kind:u.nativeEnum(Wy),setup:u.object({runId:_t,endedAt:u.string().nullable(),outcome:u.string().nullable()}).strict(),components:u.array(u.object({name:u.string().min(1),repository:u.string().min(1),status:u.nativeEnum(Pu)}).strict()).max(ja),credentials:u.array(u.string().min(1)).max(ja),answers:u.array(u.object({question:u.string(),answer:u.string().nullable()}).strict()).max(ja),instructions:u.array(u.object({text:u.string(),reply:u.string().nullable()}).strict()).max(ja),log:u.array(u.object({phase:u.nativeEnum(zd),text:u.string()}).strict()).max(TW),recipe:u.object({files:u.array(u.object({path:u.string().min(1),content:u.string()}).strict()).max(ja),blockers:u.array(u.object({component:u.string(),problem:u.string(),evidence:u.string(),fix:u.string()}).strict()).max(ja)}).strict().optional()}).strict(),NW=u.object({schemaVersion:u.literal(1),context:DW.nullable()}).strict(),FW=u.object({schemaVersion:u.literal(1),configuration:u.object({captureId:_t,revision:Xn.nullable(),hash:Ut}).strict(),capture:u.object({schemaVersion:u.literal(1),settings:u.object({target:u.object({environment:u.unknown()}).passthrough(),timeoutMinutes:u.number().int().positive(),answerWaitMinutes:u.number().int().positive().optional(),testEnvironment:u.object({name:u.string().min(1),address:u.string().min(1).optional(),readyWhen:u.string().min(1).optional()}).passthrough().optional()}).passthrough(),provenance:u.object({}).passthrough(),hash:Ut}).strict()}).strict(),MW=Oa.extend({version:u.number().int().positive(),components:u.array(u.object({name:u.string().min(1),repository:u.string().min(1)}).strict()),contentHash:Ut.optional(),files:u.array(u.object({path:u.string().refine(t=>Ru(t)&&!_d.includes(t),"not a file of a customer_deployed plan"),content:u.string()}).strict()).optional()}).strict(),_W=u.object({schemaVersion:u.literal(1),testEnvironment:MW.nullable().optional(),runtimePlan:u.object({version:u.number().int().positive(),contentHash:Ut,files:u.array(u.object({path:u.string().refine(Ru,"not a recipe file path"),content:u.string()}).strict()).min(1),recipe:u.record(u.unknown()).optional()}).strict().nullable()}).strict().refine(t=>!(t.runtimePlan&&t.testEnvironment),{message:"a run pins a recipe or a customer's Test Environment, never both",path:["testEnvironment"]}),UW=u.object({schemaVersion:u.literal(1),state:u.nativeEnum(X0),ending:u.nativeEnum(Jd).nullable(),cause:u.nativeEnum(Wd).nullable(),deadlineAt:u.string().datetime()}).strict();function yT(t){return t.reportUploaded?{schemaVersion:1,reason:"report_uploaded",cause:null}:t.recipeUploaded?{schemaVersion:1,reason:"recipe_uploaded",cause:null}:t.revisionsUploaded?{schemaVersion:1,reason:"revisions_uploaded",cause:null}:t.cancelled?{schemaVersion:1,reason:"cancelled",cause:null}:{schemaVersion:1,reason:"no_report",cause:LW(t)}}function LW(t){return t.runnerProviderNotReady?"runner_provider_not_ready":t.credentialMissing?"credential_missing":t.checkoutFailed?"checkout_failed":t.environmentUnverified?"environment_unverified":t.setupFailed?"setup_failed":t.timedOut?"timed_out":t.modelProviderDenied?"model_provider_denied":t.modelProviderUnavailable?"model_provider_unavailable":"agent_failed"}var rre={"application/pdf":"PDF","text/csv":"CSV","application/vnd.openxmlformats-officedocument.wordprocessingml.document":"DOCX","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"XLSX"};var OW=10*1024*1024;var ET=Re(require("fs")),$u="SKYRAMP_AZURE_SUPERVISED",zy=3;function ep(t){return t.replace(/##(?=(?:vso)?\[)/gi,"#\u200B#")}function Ky(t,e=process.env){e[$u]==="1"?ET.writeSync(zy,`${JSON.stringify(t)}
121
121
  `):process.stdout.write(t.command!==void 0?`${t.command}
122
122
  `:t.text??"")}function Zy(t){Ky({command:t})}function CT(t){return t.replace(/%/g,"%AZP25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function $W(t){return CT(t).replace(/;/g,"%3B").replace(/]/g,"%5D")}function tp(t,e,n){let r=Object.entries(e).map(([s,i])=>`${s}=${$W(i)}`).join(";");return`##vso[${t}${r?` ${r}`:""}]${CT(n)}`}function IT(t){if(!t)return[];let e=t.split(/\r?\n/).filter(n=>n.trim()&&n!==t);return[t,...e].map(n=>tp("task.setsecret",{},n))}function BT(t,e=Zy){for(let n of IT(t))e(n)}function VW(t){return t.replace(/%0D/g,"\r").replace(/%0A/g,`
123
123
  `).replace(/%25/g,"%")}function QT(t){let e=/^::([a-z-]+)(?: [^:]*)?::(.*)$/s.exec(t.replace(/\r?\n$/,""));if(!e)return;let[,n,r]=e,s=VW(r),i=ep(s);switch(n){case"add-mask":return IT(s);case"warning":case"error":return[tp("task.logissue",{type:n},i)];case"notice":return[i];case"debug":return i.split(`