"use strict";var p=Object.defineProperty;var o=(n,s)=>p(n,"name",{value:s,configurable:!0});var f=require("./get-pipe-path-D4YM6rQt.cjs"),h=require("node:os"),q=require("node:worker_threads"),H=require("./client-D3mGB526.cjs");require("./suppress-warnings.cjs"),require("module"),require("node:path"),require("./temporary-directory-B83uKxJF.cjs"),require("node:net");const T=o((n,s)=>{const i=new Map;for(const e of n){const r=o(t=>{s(t),process.listenerCount(e)===0&&process.exit(128+h.constants.signals[e])},"hiddenHandler");process.prependListener(e,r),i.set(e,r)}const{listenerCount:l,listeners:u}=process;process.listenerCount=function(e){let r=Reflect.apply(l,this,arguments);const t=i.get(e),c=arguments[1],a=l.length===1||arguments.length<2||c===void 0||c===null;if(t&&(a||c===t)){const d=Reflect.apply(u,this,[e]).filter(g=>g===t).length;r-=d}return r},process.listeners=function(e){const r=Reflect.apply(u,this,arguments);return n.includes(e)?r.filter(t=>t!==i.get(e)):r}},"bindHiddenSignalsHandler");q.isMainThread&&(f.require("./cjs/index.cjs"),(async()=>{const n=await H.connectingToServer;n&&T(["SIGINT","SIGTERM"],s=>{n({type:"signal",signal:s})})})());
