@reason-machines/cli-linux-x64 0.2.459 → 0.2.463
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/THIRD_PARTY_NOTICES.txt +2 -2
- package/bin/reason +1 -1
- package/bin/runtime/srt/sandbox-runtime.mjs +40 -40
- package/bin/runtime/srt/vendor/seccomp/x64/apply-seccomp +0 -0
- package/bin/vm-hands/api-7xy672j8.js +2 -0
- package/bin/vm-hands/api-credentials-bbmmmkwx.js +2 -0
- package/bin/vm-hands/connect-cli-2rvwbw01.js +2 -0
- package/bin/vm-hands/credentials-gr9jn270.js +2 -0
- package/bin/vm-hands/custom-endpoint-device-r2nn1xj9.js +2 -0
- package/bin/vm-hands/desktop-account-3cc0bhw8.js +2 -0
- package/bin/vm-hands/device-workspace-s50q53sz.js +2 -0
- package/bin/vm-hands/{fsevents-5c1c8fc6.js → fsevents-sxsgn7s9.js} +1 -1
- package/bin/vm-hands/hands-worker-source-k8v5kmmw.js +2 -0
- package/bin/vm-hands/{index-0dp6x9h4.js → index-d5n50g8b.js} +19 -19
- package/bin/vm-hands/install-receipt-gvdzhm17.js +2 -0
- package/bin/vm-hands/local-automation-34vdgq8d.js +2 -0
- package/bin/vm-hands/local-capabilities-41n0pspr.js +2 -0
- package/bin/vm-hands/local-desktop-users-qskbh51j.js +2 -0
- package/bin/vm-hands/local-display-mac-m77mftqy.js +2 -0
- package/bin/vm-hands/local-display-session-g81fwns5.js +2 -0
- package/bin/vm-hands/local-display-video-1xd1fqch.js +2 -0
- package/bin/vm-hands/local-managed-process-30k1x92d.js +2 -0
- package/bin/vm-hands/local-pty-session-k6kab3tc.js +2 -0
- package/bin/vm-hands/managed-runtime-hk53v8j5.js +2 -0
- package/bin/vm-hands/network-contract-y2eybfhn.js +2 -0
- package/bin/vm-hands/package-8v6gpwas.js +2 -0
- package/bin/vm-hands/permissions-t3e7bp9x.js +2 -0
- package/bin/vm-hands/reason-hands-protocol-r3wtcjed.js +2 -0
- package/bin/vm-hands/serve-service-hr1x43p8.js +2 -0
- package/bin/vm-hands/status-h3bk00m3.js +10 -0
- package/bin/vm-hands/version-qja79041.js +2 -0
- package/bin/vm-hands/vm-hands-entry-lite-03d1fhxv.js +3 -0
- package/bin/vm-hands/{vm-hands-entry-lite-eycfxb2c.js → vm-hands-entry-lite-0yj63trb.js} +12 -12
- package/bin/vm-hands/{vm-hands-entry-lite-njs8k65s.js → vm-hands-entry-lite-1f0v3jb4.js} +4 -4
- package/bin/vm-hands/{vm-hands-entry-lite-4g9k69a7.js → vm-hands-entry-lite-1k16ct2y.js} +5 -5
- package/bin/vm-hands/{vm-hands-entry-lite-hc5ccj2h.js → vm-hands-entry-lite-1y629eqh.js} +5 -5
- package/bin/vm-hands/{vm-hands-entry-lite-r7zs4ce2.js → vm-hands-entry-lite-3krzmhkk.js} +2 -2
- package/bin/vm-hands/vm-hands-entry-lite-3pxmmb7z.js +3 -0
- package/bin/vm-hands/{vm-hands-entry-lite-gcjjhsm2.js → vm-hands-entry-lite-44qha2rt.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-2ctydt7v.js → vm-hands-entry-lite-4x8j1xp9.js} +9 -9
- package/bin/vm-hands/{vm-hands-entry-lite-t5q30ne0.js → vm-hands-entry-lite-52x189kf.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-ba3qq0bs.js → vm-hands-entry-lite-5agyspqp.js} +4 -4
- package/bin/vm-hands/{vm-hands-entry-lite-j4kapgvr.js → vm-hands-entry-lite-5zdybh8s.js} +1 -1
- package/bin/vm-hands/{vm-hands-entry-lite-g9z467dk.js → vm-hands-entry-lite-7ja63pfz.js} +3 -3
- package/bin/vm-hands/{vm-hands-entry-lite-1f2cam25.js → vm-hands-entry-lite-8qvsnkvv.js} +4 -4
- package/bin/vm-hands/vm-hands-entry-lite-9fzydv1p.js +2 -0
- package/bin/vm-hands/{vm-hands-entry-lite-etbsze1k.js → vm-hands-entry-lite-9vv5knh4.js} +3 -3
- package/bin/vm-hands/{vm-hands-entry-lite-3pnjdh8m.js → vm-hands-entry-lite-abfb6nms.js} +1 -1
- package/bin/vm-hands/{vm-hands-entry-lite-3rwtqr28.js → vm-hands-entry-lite-arrmd8qx.js} +2 -2
- package/bin/vm-hands/vm-hands-entry-lite-b139fhbg.js +5 -0
- package/bin/vm-hands/{vm-hands-entry-lite-tqc2ezda.js → vm-hands-entry-lite-b8yapqfn.js} +5 -5
- package/bin/vm-hands/vm-hands-entry-lite-bvb4nvxr.js +3 -0
- package/bin/vm-hands/{vm-hands-entry-lite-mv9nkj11.js → vm-hands-entry-lite-c7ka2d1c.js} +3 -3
- package/bin/vm-hands/{vm-hands-entry-lite-9sa1knn7.js → vm-hands-entry-lite-cf1x5cbr.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-07vak0wy.js → vm-hands-entry-lite-d2fveq6h.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-2j7he8gn.js → vm-hands-entry-lite-eay4tbg0.js} +33 -33
- package/bin/vm-hands/{vm-hands-entry-lite-4fwf7wgb.js → vm-hands-entry-lite-egax7vw4.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-dh8f2h2d.js → vm-hands-entry-lite-h6rhk6h1.js} +5 -5
- package/bin/vm-hands/{vm-hands-entry-lite-a3w8m8nb.js → vm-hands-entry-lite-hzh8fdxx.js} +3 -3
- package/bin/vm-hands/{vm-hands-entry-lite-jcf61cb4.js → vm-hands-entry-lite-jyvmw8b7.js} +5 -5
- package/bin/vm-hands/vm-hands-entry-lite-k83rkcys.js +3 -0
- package/bin/vm-hands/{vm-hands-entry-lite-b8k78r34.js → vm-hands-entry-lite-kz48x6p0.js} +32 -32
- package/bin/vm-hands/{vm-hands-entry-lite-n68srzhw.js → vm-hands-entry-lite-m753n72c.js} +16 -16
- package/bin/vm-hands/{vm-hands-entry-lite-5rx9b5rg.js → vm-hands-entry-lite-me5w88km.js} +14 -9
- package/bin/vm-hands/{vm-hands-entry-lite-9z3v15d2.js → vm-hands-entry-lite-mmrdd8gk.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-n4x7reax.js → vm-hands-entry-lite-n1k1njzh.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-2yz6b0n3.js → vm-hands-entry-lite-np07qyeq.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-d9g1pzzx.js → vm-hands-entry-lite-r3yp6cr9.js} +3 -3
- package/bin/vm-hands/{vm-hands-entry-lite-em7mk9tn.js → vm-hands-entry-lite-rfz60hb3.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-9z0skx2w.js → vm-hands-entry-lite-rzhqftyg.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-2sx9smm8.js → vm-hands-entry-lite-t0exw1jk.js} +20 -20
- package/bin/vm-hands/{vm-hands-entry-lite-dcxvxpne.js → vm-hands-entry-lite-tn8v3yfj.js} +1 -1
- package/bin/vm-hands/{vm-hands-entry-lite-qyp2a4c3.js → vm-hands-entry-lite-txd50spx.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-8j7p91hr.js → vm-hands-entry-lite-vdhgwmmp.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-12rzrd95.js → vm-hands-entry-lite-wrvz9jxy.js} +2 -2
- package/bin/vm-hands/{vm-hands-entry-lite-vrp0t24n.js → vm-hands-entry-lite-x9wy77vd.js} +2 -2
- package/bin/vm-hands/vm-hands-entry-lite.js +2 -2
- package/bin/vm-hands/{vm-hands-executor-81e32jtv.js → vm-hands-executor-ksf4ragj.js} +3 -3
- package/bin/vm-hands/vm-hands-op-runner-q5x9gpmt.js +2 -0
- package/bin/vm-hands/{vm-hands-runtime-w8j74jv4.js → vm-hands-runtime-dg696564.js} +3 -3
- package/bin/vm-hands/worker-preview-readiness-6hzzjnk7.js +2 -0
- package/bin/vm-hands/worker-sandbox-1g7jheqm.js +2 -0
- package/package.json +1 -1
- package/bin/vm-hands/api-credentials-skdwhmrz.js +0 -2
- package/bin/vm-hands/api-s23qevwq.js +0 -2
- package/bin/vm-hands/connect-cli-3t4w2fht.js +0 -2
- package/bin/vm-hands/custom-endpoint-device-2s9qxe6t.js +0 -2
- package/bin/vm-hands/desktop-account-nb7g2ek5.js +0 -2
- package/bin/vm-hands/device-workspace-6av4wa2e.js +0 -2
- package/bin/vm-hands/hands-worker-source-v7ds6vp1.js +0 -2
- package/bin/vm-hands/install-receipt-4sjr0jhg.js +0 -2
- package/bin/vm-hands/local-automation-16beqqtc.js +0 -2
- package/bin/vm-hands/local-capabilities-5prfxmwj.js +0 -2
- package/bin/vm-hands/local-desktop-users-2azpqr2m.js +0 -2
- package/bin/vm-hands/local-display-mac-1ddx6s3j.js +0 -2
- package/bin/vm-hands/local-display-session-9mkfnt2c.js +0 -2
- package/bin/vm-hands/local-display-video-pg5tzfwz.js +0 -2
- package/bin/vm-hands/local-managed-process-0ay1z599.js +0 -2
- package/bin/vm-hands/local-pty-session-gvnfgrxt.js +0 -2
- package/bin/vm-hands/managed-runtime-wr322d0v.js +0 -2
- package/bin/vm-hands/network-contract-8fkzm0t0.js +0 -2
- package/bin/vm-hands/package-k6jdrvn6.js +0 -2
- package/bin/vm-hands/permissions-q60sq4a3.js +0 -2
- package/bin/vm-hands/reason-hands-protocol-nkj7481a.js +0 -2
- package/bin/vm-hands/serve-service-vk54esde.js +0 -2
- package/bin/vm-hands/status-dyaae8hz.js +0 -10
- package/bin/vm-hands/version-x56y54v3.js +0 -2
- package/bin/vm-hands/vm-hands-entry-lite-04b2bmem.js +0 -2
- package/bin/vm-hands/vm-hands-entry-lite-9jgf223h.js +0 -5
- package/bin/vm-hands/vm-hands-entry-lite-cm497v4t.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-hw26gewc.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-t7pnq2e5.js +0 -3
- package/bin/vm-hands/vm-hands-op-runner-xdmre6dn.js +0 -2
- package/bin/vm-hands/worker-preview-readiness-kmwcrttt.js +0 -2
- package/bin/vm-hands/worker-sandbox-epre0fnv.js +0 -2
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{zr,Hn,qr,zn}from"./vm-hands-entry-lite-3pnjdh8m.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";export{zr as installationReceiptPath,qr as installerReasonAlias,Hn as installerReceiptLauncher,zn as loadInstallationReceipt};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{xn,As,Ps,Ts,Rs,kn}from"./vm-hands-entry-lite-5rx9b5rg.js";import"./vm-hands-entry-lite-eycfxb2c.js";import"./vm-hands-entry-lite-2ctydt7v.js";import"./vm-hands-entry-lite-gcjjhsm2.js";import"./vm-hands-entry-lite-1f2cam25.js";import"./vm-hands-entry-lite-12rzrd95.js";import"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-d9g1pzzx.js";import"./vm-hands-entry-lite-n68srzhw.js";import"./vm-hands-entry-lite-3pnjdh8m.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-vrp0t24n.js";import"./vm-hands-entry-lite-jcf61cb4.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-tqc2ezda.js";import"./vm-hands-entry-lite-g9z467dk.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";export{Ps as ensureLocalBrowser,xn as localAutomationAvailable,Ts as localBrowserProfile,As as localUserChromeHost,Rs as runAutomationCallLocally,kn as runLocalAutomation};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{zo,Li,cn,qo,Wo,Vo,Go,vs,Ss,Es,xs}from"./vm-hands-entry-lite-2j7he8gn.js";import"./vm-hands-entry-lite-mv9nkj11.js";import"./vm-hands-entry-lite-2sx9smm8.js";import"./vm-hands-entry-lite-b8k78r34.js";import"./vm-hands-entry-lite-dh8f2h2d.js";import"./vm-hands-entry-lite-njs8k65s.js";import"./vm-hands-entry-lite-a3w8m8nb.js";import"./vm-hands-entry-lite-t5q30ne0.js";import"./vm-hands-entry-lite-dcxvxpne.js";import"./vm-hands-entry-lite-5rx9b5rg.js";import"./vm-hands-entry-lite-eycfxb2c.js";import"./vm-hands-entry-lite-2ctydt7v.js";import"./vm-hands-entry-lite-gcjjhsm2.js";import"./vm-hands-entry-lite-1f2cam25.js";import"./vm-hands-entry-lite-12rzrd95.js";import"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-d9g1pzzx.js";import"./vm-hands-entry-lite-n68srzhw.js";import"./vm-hands-entry-lite-3pnjdh8m.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-vrp0t24n.js";import"./vm-hands-entry-lite-jcf61cb4.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-tqc2ezda.js";import"./vm-hands-entry-lite-g9z467dk.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";import{r}from"./vm-hands-entry-lite-qy9xg6em.js";export{r as LocalCapabilityError,zo as SHORT_REQUEST_CAPABILITIES,vs as capabilityInventoryForRoots,Li as confinedExecutionShell,qo as defaultLocalCommandRunner,Ss as deliverLocalHandsEnvironment,Go as enrolledRootPaths,xs as executeLocalOperation,Es as rebindLocalHandsControl,Wo as runFileCapability,Vo as runTransferCapability,cn as spawnCaptured};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Et,aa,ca,Ri,Oi}from"./vm-hands-entry-lite-g9z467dk.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";export{aa as forgetLocalDesktopUse,Oi as holdLocalDesktop,Et as noteLocalDesktopUse,ca as releaseLocalDesktop,Ri as trackDesktopRun};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Lt,Os,G,ze,Mt}from"./vm-hands-entry-lite-eycfxb2c.js";import"./vm-hands-entry-lite-2ctydt7v.js";import"./vm-hands-entry-lite-gcjjhsm2.js";import"./vm-hands-entry-lite-1f2cam25.js";import"./vm-hands-entry-lite-12rzrd95.js";import"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-d9g1pzzx.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-vrp0t24n.js";import"./vm-hands-entry-lite-jcf61cb4.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-g9z467dk.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";export{ze as ensureLinuxDesktop,Lt as localDisplayAvailable,Os as localDisplayReady,G as privateDirectory,Mt as runLocalDisplayStream};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{An,Pn,Tn,Rn,Cr}from"./vm-hands-entry-lite-2ctydt7v.js";import"./vm-hands-entry-lite-d9g1pzzx.js";import"./vm-hands-entry-lite-vrp0t24n.js";import"./vm-hands-entry-lite-jcf61cb4.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";export{An as MAC_SCREEN,Pn as WINDOWS_SCREEN,Tn as createDisplayVideoLane,Cr as localDisplayVideoAvailable,Rn as simulatorVideoFfmpeg};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{rt,cr,ks,Cs}from"./vm-hands-entry-lite-mv9nkj11.js";import"./vm-hands-entry-lite-2sx9smm8.js";import"./vm-hands-entry-lite-b8k78r34.js";import"./vm-hands-entry-lite-dh8f2h2d.js";import"./vm-hands-entry-lite-a3w8m8nb.js";import"./vm-hands-entry-lite-t5q30ne0.js";import"./vm-hands-entry-lite-1f2cam25.js";import"./vm-hands-entry-lite-12rzrd95.js";import"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-d9g1pzzx.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-tqc2ezda.js";import"./vm-hands-entry-lite-g9z467dk.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";export{rt as ManagedProcessStoppedError,ks as controlManagedDeviceProcess,Cs as retireManagedDeviceProcess,cr as runManagedDeviceProcess};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Pr,Bt,Tr,Jo,On,Rr,In}from"./vm-hands-entry-lite-gcjjhsm2.js";import"./vm-hands-entry-lite-1f2cam25.js";import"./vm-hands-entry-lite-12rzrd95.js";import"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";export{Bt as LOCAL_PTY_MAX_BUFFERED_OUTPUT_BYTES,Tr as LOCAL_PTY_MAX_SESSIONS,Pr as LOCAL_PTY_MAX_SESSION_MS,Rr as defaultConnect,Jo as defaultLoginShell,On as ptyRuntimeSupported,In as runLocalPtySession};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{hs,fs,ms,gs,_s,ys,bs}from"./vm-hands-entry-lite-etbsze1k.js";import"./vm-hands-entry-lite-t5q30ne0.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";export{_s as acquireManagedRuntimeDirectoryLock,ms as currentManagedRuntimeVersion,bs as flushManagedRuntimeLifecycleEvents,gs as isManagedRuntimeVersionExecutable,fs as legacyManagedRuntimePaths,hs as managedRuntimePaths,ys as recordManagedRuntimeLifecycle};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{et,Te,Us,Hs,zs,Yn,qs,en,Qn,wt,ei,ti,ri,ni,ii,oi,si,ai,ci,li,ui,di,pi,hi,fi,mi,pe,Y,Re,q,gi,_i,yi,Q,wi,bi,vi,Si,Ei,bt,xi,Ws,nr,ki,Vs,Qo,Gs,Ks,Js,Zs,Xs,Ys,Qs,ea,ta,ra,na,ia,oa,sa}from"./vm-hands-entry-lite-tqc2ezda.js";export{xi as AUTOMATION_CLOUD_SESSIONS,bt as AUTOMATION_USER_CHROME,ui as HANDS_CLOUD_ACCESS,di as HANDS_CLOUD_ACCESS_KEY,pe as HANDS_CONFINEMENT,Y as HANDS_CONFINEMENT_KEY,ni as HANDS_ENVIRONMENT_AT_CLAIM,ii as HANDS_ENVIRONMENT_AT_CLAIM_KEY,Qn as HANDS_ENVIRONMENT_DELIVERY,wt as HANDS_ENVIRONMENT_DELIVER_CONTROL,pi as HANDS_HEADLESS_BROWSER,hi as HANDS_HEADLESS_BROWSER_KEY,gi as HANDS_JOBS_USER,_i as HANDS_JOBS_USER_KEY,fi as HANDS_LARGE_ENVIRONMENT,mi as HANDS_LARGE_ENVIRONMENT_KEY,Re as HANDS_MODEL_JOBS_EGRESS,q as HANDS_MODEL_JOBS_EGRESS_KEY,ai as HANDS_REBIND,li as HANDS_REBIND_CONTROL,ci as HANDS_REBIND_KEY,wi as HANDS_SESSION_CAP_KEY,bi as HANDS_SESSION_CAP_NONE,yi as HANDS_SESSION_GROUP,Q as HANDS_SESSION_GROUP_KEY,oi as HANDS_WORKSPACE_CHECK,si as HANDS_WORKSPACE_CHECK_KEY,Si as JOBS_START_WAIT,Ei as JOBS_START_WAIT_KEY,Te as LOCAL_OPERATION_MAX_BYTES,et as LOCAL_RUNTIME_PROTOCOL_VERSION,zs as LOCAL_RUNTIME_ROUTES,en as LOCAL_RUNTIME_SESSION_CLAIM_WAIT_MAX_MS,Yn as LOCAL_RUNTIME_SESSION_PATH,nr as LOCAL_RUNTIME_WORKER_STARTUP_MAX_MS,Us as RELAY_HOST_ALIAS_HEADER,Hs as RELAY_HOST_ALIAS_VERSION,ri as VM_HANDS_UNBIND_UNVERIFIED_EVENT,ei as VM_HANDS_WORKSPACE_DEFERRED_KEY,ti as VM_HANDS_WORKSPACE_GRANT_CONTROL,vi as WORKER_PREVIEW_CARRIED_JOBS,Ws as WORKER_STARTUP_TIMING_STAGES,ki as buildLocalRuntimeDeviceProofBytes,qs as localRuntimeSessionRoutable,Qs as parseLocalRuntimeDisconnectResponse,Ks as parseLocalRuntimeEnrollmentResponse,Vs as parseLocalRuntimeErrorEnvelope,Zs as parseLocalRuntimeFirstHeartbeat,Js as parseLocalRuntimeHeartbeatResponse,Ys as parseLocalRuntimeIdentityResponse,ta as parseLocalRuntimeLifecycleResponse,ea as parseLocalRuntimeLocalSubscriptionResponse,ra as parseLocalRuntimeOperationClaim,sa as parseLocalRuntimeOperationCompletionResponse,oa as parseLocalRuntimeOperationEnvironmentResponse,ia as parseLocalRuntimeOperationEventsResponse,na as parseLocalRuntimeOperationHeartbeatResponse,Qo as parseLocalRuntimeProofChallenge,Gs as parseLocalRuntimeRegistrationResponse,Xs as parseLocalRuntimeRootsSyncResponse};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Xo,Yo,Fs,js}from"./vm-hands-entry-lite-vrp0t24n.js";import"./vm-hands-entry-lite-jcf61cb4.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";export{js as allowMacPermissions,Fs as permissionsSummary,Yo as readMacPermissions,Xo as reasonIdentity};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{P,Nr,Lr,Dn,lt,Nn,Mr,Ge,ve,Ln,Ke,zt,ne,Je,Mn,Se,qt,$r,Wt,Br,$n,ae,U,N,ce,Fr,jr,Bn}from"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-r7zs4ce2.js";export{Br as REASON_HANDS_CLOSE_CODES,Ke as REASON_HANDS_JOB_CONTROL_MAX_FRAME_BYTES,Mr as REASON_HANDS_JOB_MAX_INPUT_CHARS,Ge as REASON_HANDS_JOB_MAX_OUTPUT_CHARS,ve as REASON_HANDS_JOB_MAX_OUTPUT_CHUNKS,Ln as REASON_HANDS_JOB_MAX_RECORDS,Nn as REASON_HANDS_MAX_ERROR_CHARS,Nr as REASON_HANDS_MAX_FRAME_BYTES,Lr as REASON_HANDS_MAX_INPUT_CHARS,lt as REASON_HANDS_MAX_OUTPUT_CHARS,Dn as REASON_HANDS_MAX_STRUCTURED_INPUT_CHARS,P as REASON_HANDS_PROTOCOL_VERSION,$r as REASON_HANDS_PTY_ANCHOR_EXIT_MS,Wt as REASON_HANDS_PTY_CLEANUP_RECEIPT_MS,qt as REASON_HANDS_PTY_CLEANUP_SWEEP_MS,Se as REASON_HANDS_PTY_MAX_DIMENSION,ne as REASON_HANDS_PTY_MAX_INPUT_BYTES,Je as REASON_HANDS_PTY_MAX_OUTPUT_BYTES,Mn as REASON_HANDS_PTY_MAX_PENDING_INPUT_BYTES,zt as REASON_HANDS_PTY_PROTOCOL_VERSION,$n as REASON_HANDS_WORKSPACE_BEFORE_MAX_OUTPUT_CHARS,U as isReasonHandsGeneration,ce as isReasonHandsPtyJobId,ae as isReasonHandsRequestId,N as isReasonHandsUuid,Fr as parseReasonHandsJobRequest,jr as parseReasonHandsJobResult,Bn as parseReasonHandsPtyReceipt};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Ur,Ee,J,jn,Ds,uo,Ns,Ze,Zo,Un,Ls,Ms,Hr,$s,Bs}from"./vm-hands-entry-lite-n68srzhw.js";import"./vm-hands-entry-lite-3pnjdh8m.js";import"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-fcvf8md1.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-9sa1knn7.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-8j7p91hr.js";import"./vm-hands-entry-lite-em7mk9tn.js";export{Ur as WORKER_SERVICE_ENV,J as WorkerServiceError,uo as connectServiceLabel,Ee as defaultWorkerServiceHost,Ms as installWorkerService,Ze as installedWorkerService,Ns as isConnectServiceLabel,Bs as removeWorkerService,Hr as restartWorkerService,$s as retargetWorkerServiceLogs,Zo as retireLegacyWorkerService,Ls as workerServiceDefinitionCurrent,jn as workerServiceLauncher,Un as workerServiceProcessRunning,Ds as workerServiceRetargetPending};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import"./vm-hands-entry-lite-9jgf223h.js";import"./vm-hands-entry-lite-fcvf8md1.js";import{g}from"./vm-hands-entry-lite-hw26gewc.js";import"./vm-hands-entry-lite-r7zs4ce2.js";import"./vm-hands-entry-lite-em7mk9tn.js";import"./vm-hands-entry-lite-n4x7reax.js";import{jt,ct}from"./vm-hands-entry-lite-1f2cam25.js";import{w,M,ar,Be,tt}from"./vm-hands-entry-lite-4g9k69a7.js";import"./vm-hands-entry-lite-tqc2ezda.js";import"./vm-hands-entry-lite-2j7he8gn.js";import"./vm-hands-entry-lite-2sx9smm8.js";import"./vm-hands-entry-lite-04b2bmem.js";import"./vm-hands-entry-lite-a3w8m8nb.js";import"./vm-hands-entry-lite-njs8k65s.js";import"./vm-hands-entry-lite-cm497v4t.js";import"./vm-hands-entry-lite-2ctydt7v.js";import"./vm-hands-entry-lite-jcf61cb4.js";import"./vm-hands-entry-lite-hc5ccj2h.js";import"./vm-hands-entry-lite-vrp0t24n.js";import"./vm-hands-entry-lite-d9g1pzzx.js";import"./vm-hands-entry-lite-etbsze1k.js";import"./vm-hands-entry-lite-3pnjdh8m.js";import"./vm-hands-entry-lite-n68srzhw.js";import"./vm-hands-entry-lite-dcxvxpne.js";import"./vm-hands-entry-lite-j4kapgvr.js";import"./vm-hands-entry-lite-b8k78r34.js";import"./vm-hands-entry-lite-12rzrd95.js";import"./vm-hands-entry-lite-mv9nkj11.js";import"./vm-hands-entry-lite-g9z467dk.js";import"./vm-hands-entry-lite-gcjjhsm2.js";import"./vm-hands-entry-lite-eycfxb2c.js";import"./vm-hands-entry-lite-5rx9b5rg.js";import"./vm-hands-entry-lite-4fwf7wgb.js";import"./vm-hands-entry-lite-dh8f2h2d.js";import"./vm-hands-entry-lite-t5q30ne0.js";import{a}from"./vm-hands-entry-lite-9sa1knn7.js";import{t,o,u,i,s,n}from"./vm-hands-entry-lite-ba3qq0bs.js";import"./vm-hands-entry-lite-8j7p91hr.js";import{readFileSync as me,realpathSync as k,renameSync as ge,unlinkSync as fe,writeFileSync as he}from"fs";import{dirname as ye,join as I}from"path";function h(e){return`claude mcp add --transport http reason ${e}`}function C(e){return`codex mcp add reason --url ${e}
|
|
3
|
-
codex mcp login reason`}var F=h("https://mcp.reasonmachines.com/mcp"),z=C("https://mcp.reasonmachines.com/mcp"),B=`https://claude.ai/settings/connectors?add=custom&url=${encodeURIComponent("https://mcp.reasonmachines.com/mcp")}`,H=`https://cursor.com/install-mcp?name=reason&config=${encodeURIComponent(btoa(JSON.stringify({url:"https://mcp.reasonmachines.com/mcp"})))}`;var b="https://github.com/reason-machines/reason-plugins",X=`Connect a coding agent to Reason over MCP
|
|
4
|
-
|
|
5
|
-
Usage:
|
|
6
|
-
reason mcp Show how to connect Claude Code, Codex, or another MCP client
|
|
7
|
-
reason mcp uninstall Remove only this machine's registrations of the earlier, retired server
|
|
8
|
-
|
|
9
|
-
Plugins for Claude Code and Codex: ${b}
|
|
10
|
-
`;var P=s(["granted","not_granted","unknown"]),y=i({status:P,checkedAt:o().finite(),executablePath:t().min(1)});var Oe=i({version:n(1),key:t(),at:o(),self:i({principal_type:t(),user_id:t().optional(),user_name:t().nullish(),email:t().nullish(),org_id:t(),organization_name:t().nullish(),organization_slug:t().nullish(),mcp_connections:u(i({client_id:t(),client_name:t(),last_used_at:t().nullable()})).optional()})});var x=30000;function L(e,c=Date.now(),R=null){let r=ct(e),d=(()=>{if(r?.state!=="connected"&&r?.state!=="starting")return!1;try{return process.kill(r.pid,0),!0}catch{return!1}})(),S=d&&r?.state==="connected",p=(f)=>S&&c-f>=0&&c-f<x,l=y.safeParse(r?.fullDiskAccess),m=jt(r,R,c);return{...m?{permission_recovery:m}:{},full_disk_access:l.success&&p(l.data.checkedAt)?l.data.status:"unknown",keep_awake:{enabled:ar(e)==="battery_and_ac",holding:r?.idleSleepHold===!0&&p(Date.parse(r.lastHeartbeatAt??""))},executable:d&&l.success?l.data.executablePath:null}}function De(e=g()){if(process.platform!=="darwin")return null;let c=Be(I(tt(k(a()),e),"worker.json"));return c?L(w(c).daemon,Date.now(),M(c)):null}export{De as connectionMacState};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{T}from"./vm-hands-entry-lite-fcvf8md1.js";import{g,Wr,ho,xe}from"./vm-hands-entry-lite-hw26gewc.js";import{t,o,d,u,i,ts,W,_,s,n}from"./vm-hands-entry-lite-ba3qq0bs.js";var J=/^(0|[1-9][0-9]{0,5})\.(0|[1-9][0-9]{0,5})$/;function v(e){let r=typeof e==="string"?J.exec(e):null;return r?{major:Number(r[1]),minor:Number(r[2])}:null}var Q=25,Le=i({machine:t().min(1).max(200),person:t().min(1).max(200),team:t().min(1).max(200),version:t().max(64).optional(),wait_seconds:o().int().min(0).max(Q).optional()}),K=_("kind",[i({id:t(),kind:n("who"),all:d().optional()}),i({id:t(),kind:n("send"),to:t(),body:t(),from_name:t(),from_agent:t(),wake:d(),reply_to:t().max(100).optional(),notify:d().optional()})]),P=i({job:K.nullable(),retry_after_seconds:o().optional()}),V=i({address:t(),person:t(),machine:t(),agent:t(),repo:t().nullable(),branch:t().nullable(),status:t(),since:o().nullable(),doing:t().nullable(),worker:d(),tier:t().max(10).optional()}),Y=i({person:t(),machine:t(),online:d()}),X=i({team:t().nullable(),sessions:u(V).max(2000),machines:u(Y).max(500),all:d().optional()}),Z=i({address:t().max(300),state:t().max(40),note:t().max(500)}),Ne=W([i({who:X}),i({sent:i({ids:u(t().max(100)).max(500),recipients:u(t().max(300)).max(500),from:t().max(300),deliveries:u(Z).max(500).optional()})}),i({error:t().min(1).max(2000)})]),ee=i({id:t().max(100),from:t().max(300),from_agent:t().max(100).nullable(),to:t().max(300),reply_to:t().max(100).nullable(),body:t().max(64000),sent_at:o()}),De=i({messages:u(ee).max(100)});import{randomBytes as ne}from"crypto";import{chmodSync as C,existsSync as A,lstatSync as te,mkdirSync as se,readFileSync as U,renameSync as oe,unlinkSync as q,writeFileSync as O}from"fs";import{homedir as re}from"os";import{dirname as ie,join as x}from"path";function b(e=process.env,r=re()){let a=e.XDG_CONFIG_HOME?.trim()||x(r,".config"),c=g({env:e})==="staging"?["staging"]:[];return x(xe(a,...c),"credentials.json")}function z(e,r=b()){return se(ie(r),{recursive:!0,mode:448}),O(r,`${JSON.stringify(e,null,2)}
|
|
3
|
-
`,{mode:384}),C(r,384),r}function k(e=b()){if(!A(e))return null;try{let r=U(e,"utf8"),a=JSON.parse(r);if(typeof a.apiOrigin!=="string"||typeof a.clientId!=="string"||typeof a.accessToken!=="string"||typeof a.refreshToken!=="string"||typeof a.expiresAt!=="string"||typeof a.orgId!=="string"||!Array.isArray(a.scopes))return null;let l=new URL(a.apiOrigin).origin,c=Wr(l);if(c!==l)ae(e,r,c);return{apiOrigin:c,clientId:a.clientId,accessToken:a.accessToken,refreshToken:a.refreshToken,expiresAt:a.expiresAt,scopes:a.scopes.filter((m)=>typeof m==="string"),orgId:a.orgId}}catch{return null}}function ae(e,r,a){let l=`${e}.${process.pid}.${ne(6).toString("hex")}.tmp`;try{let c=te(e);if(!c.isFile()||process.platform!=="win32"&&c.uid!==process.geteuid?.())return;let m=JSON.parse(r);if(O(l,`${JSON.stringify({...m,apiOrigin:a},null,2)}
|
|
4
|
-
`,{mode:384,flag:"wx"}),C(l,384),U(e,"utf8")!==r)throw Error("credentials_changed");oe(l,e)}catch{try{q(l)}catch{}}}function M(e=b()){if(!A(e))return!1;return q(e),!0}var j=["run","mcp:read","mcp:write","secrets:read","secrets:write","sessions:read","sessions:debug","devices:read","devices:write","devices:use","ssh:write","knowledge:read","memory:read","memory:write","skills:read","skills:write","repos:read","repos:write","reviews:read","reviews:write","deployment:read","analytics:read","org:read","org:write","attachments:read","attachments:write","guardrails:read","guardrails:write","network:read","network:write","automations:read","automations:write","agent_auth:read"];var cn=j.filter((e)=>e!=="network:read"&&e!=="network:write");class R extends Error{oauthCode;constructor(e,r=null){super(e);this.oauthCode=r;this.name="LoginError"}}function le(e,r){let a=typeof e.error==="string"?e.error:null,l=typeof e.error_description==="string"?e.error_description:a?a:r;return new R(l,a)}async function ce(e,r,a,l){let c=await a(`${e}/mcp/oauth/token`,{method:"POST",redirect:"error",headers:{"content-type":"application/x-www-form-urlencoded"},body:r,signal:l}),m=await c.json().catch(()=>({}));if(!c.ok)throw le(m,`OAuth token request failed (${c.status})`);return m}var de=1e4;async function me(e,r={}){let a=r.fetchImpl??fetch,l=await ce(e.apiOrigin,new URLSearchParams({grant_type:"refresh_token",client_id:e.clientId,refresh_token:e.refreshToken}),a,AbortSignal.timeout(de)).catch((m)=>{if(m instanceof Error&&m.name==="TimeoutError")throw new R("Reason did not answer the login refresh in time. Check the network and retry.");throw m});if(typeof l.access_token!=="string"||typeof l.refresh_token!=="string"||typeof l.expires_in!=="number")throw new R("Reason returned an incomplete refreshed login.");let c={...e,accessToken:l.access_token,refreshToken:l.refresh_token,expiresAt:new Date(Date.now()+l.expires_in*1000).toISOString(),scopes:typeof l.scope==="string"?l.scope.split(/\s+/).filter(Boolean):e.scopes};return z(c,r.path??b()),c}var w=new Map;function E(e,r){if(!r)return e;if(r.aborted)return Promise.reject(r.reason);return new Promise((a,l)=>{let c=()=>l(r.reason);r.addEventListener("abort",c,{once:!0}),e.then(a,l).finally(()=>r.removeEventListener("abort",c))})}async function At(e={}){let r=e.path??b(),a=k(r);if(!a)return null;let l=e.apiOrigin??T(process.env,"REASON_API_URL")?.trim();if(l&&!ho(a.apiOrigin,new URL(l).origin))return null;let c=Date.parse(a.expiresAt)<=Date.now()+60000;if(!e.forceRefresh&&!c)return a;let m=[r,a.apiOrigin,a.clientId,a.refreshToken].join("\x00"),p=w.get(m);if(p)return E(p,e.signal);let f;return f=me(a,{fetchImpl:e.fetchImpl,path:r}).catch(async(y)=>{if(!(y instanceof R)||y.oauthCode!=="invalid_grant"&&y.oauthCode!=="invalid_client")throw y;let S=k(r),B=y.oauthCode==="invalid_client"?S?.clientId!==a.clientId:S?.refreshToken!==a.refreshToken;if(S&&B)return At({fetchImpl:e.fetchImpl,path:r});return M(r),null}).finally(()=>{if(w.get(m)===f)w.delete(m)}),w.set(m,f),E(f,e.signal)}var ue=i({label:t(),used_percent:o().min(0).max(100).nullable(),resets_at:t().nullable(),exhausted:d().nullable()}),ge=i({groups:u(i({selectable:d().optional(),accounts:u(i({source_id:t().min(1),model_ids:u(t().min(1)).optional()}))}))});function he(e){let r=ge.safeParse(e);if(!r.success)return;return r.data.groups.some((a)=>a.selectable!==!1&&a.accounts.some((l)=>l.model_ids===void 0||l.model_ids.length>0))}class I extends Error{status;code;suggestedModel;retryAfterMs;resolutionReason;constructor(e,r,a,l,c,m){super(a);this.status=e;this.code=r;this.suggestedModel=l;this.retryAfterMs=c;this.resolutionReason=m;this.name="ApiError"}static rateLimitDelayMs(e,r){if(!(e instanceof I)||e.status!==429)return null;return Math.min(60000,Math.max(r,e.retryAfterMs??0))}}var pe=["minimal","low","medium","high","xhigh","max"],fe=i({id:t().min(1),kind:t(),name:t(),custom_name:t().nullish(),status:t(),online:d(),compatible:d().optional(),compatibility_reason:t().nullish(),folder_lane_of:t().nullish(),roots:u(i({id:t().min(1),label:t()}))}),ye=i({devices:u(fe),end_cursor:t().nullish(),has_next_page:d().optional()}),_e=i({id:t().min(1),name:t()}),be=i({items:u(_e)}),Re=i({id:t().min(1),name:t(),main:d(),mine:d(),session_id:t().nullish(),appearance:i({color:t().nullish()}).nullish().catch(null)}),we=i({items:u(Re)}),Se=i({skill_id:t().min(1),name:t(),description:t().nullish(),activation_keywords:u(t()).default([]),is_enabled:d().default(!0)}),ke=i({items:u(Se).default([])}),ve=i({id:t().min(1),kind:t(),enabled:d(),schedule:i({expression:t().nullish(),every_seconds:o().nullish(),next_run_at:t().nullish()}).nullish(),github:i({event:t().nullish(),action:t().nullish(),repo:t().nullish()}).nullish(),last_fired_at:t().nullish()}),N=i({id:t().min(1),name:t().nullish(),instructions:t().nullish(),enabled:d(),triggers:u(ve).default([])}),Pe=i({items:u(N).default([]),end_cursor:t().nullish(),has_next_page:d().optional()}),Ie=i({id:t().min(1),slug:t().nullish(),name:t(),description:t().nullish(),transport:t().nullish(),url:t().nullish(),enabled:d()}),Ce=i({items:u(Ie).default([])}),$e=i({status:t(),summary:t().nullish(),category:t().nullish(),outcome:t().nullish(),message_count:o().nullish(),pr_url:t().nullish(),cost_usd:o().nullish(),generated_at:t().nullish()}),L=i({tags:u(t()).default([])}),Ae=s(["linux","macos"]),D=i({id:t().min(1),name:t().min(1),platform:Ae.nullable(),workers:i({total:o().int(),online:o().int(),busy:o().int(),idle:o().int()}),sessions:i({queued:o().int(),running:o().int()})}),Ue=i({machines:u(D)}),Te=i({machine:D}),qe=i({deleted:n(!0),revoked_workers:o().int(),revoked_tokens:o().int()}),Oe=i({token:i({id:t().min(1),machine_id:t().min(1),token_prefix:t()}),secret:t().startsWith("rmt_")}),H=ts({machine_id:t().min(1),machine_name:t().min(1)}),ze=H.extend({organization_id:t().min(1)}),pn=i({id:t().min(1),name:t().min(1),state:s(["waiting","placed"]),queue_position:o().int().nullable()});var fn=W([i({kind:n("cloud")}),i({kind:s(["mac","headless"]),device_id:t().min(1),root_id:t().min(1)})]);function h(e,r,a){let l=e.safeParse(r);if(!l.success)throw new I(502,a,"Reason returned an unexpected response.");return l.data}var Me=i({error:i({type:t(),message:t()})});function F(e,r,a){let l=Me.safeParse(r),c=typeof r.error==="string"?r.error:l.success?l.data.error.type:`http_${e}`,m=typeof r.detail==="string"?r.detail:typeof r.message==="string"?r.message:l.success?l.data.error.message:`Reason request failed (${e}${typeof r.error==="string"?` ${r.error}`:""})`,p=c==="github_connection_required"&&typeof r.connect_url==="string"&&/^https?:\/\//.test(r.connect_url)?` Connect it at ${r.connect_url}`:"",f=a===null||a.trim()===""?NaN:Number(a);return new I(e,c,`${m}${p}`,typeof r.suggested_model==="string"?r.suggested_model:void 0,Number.isFinite(f)&&f>=0?f*1000:void 0,typeof r.resolution_reason==="string"?r.resolution_reason:void 0)}async function ps(e){let r=await(e.fetchImpl??fetch)(`${e.apiOrigin}/v3/machines/enrollment-tickets`,{method:"POST",headers:{authorization:`Bearer ${e.token}`,accept:"application/json","content-type":"application/json"},body:JSON.stringify(e.body),signal:AbortSignal.timeout(30000),redirect:"error"}),a=await r.json().catch(()=>({}));if(!r.ok)throw F(r.status,a,r.headers.get("retry-after"));return h(ze,a,"invalid_machine_ticket")}class Ho{options;credentials;constructor(e,r={}){this.options=r;this.credentials=e}trackEvent(e,r={}){}async request(e,r={},a=!1){let l=this.options.fetchImpl??fetch,c=await l(`${this.credentials.apiOrigin}/v3${e}`,{method:r.method??"GET",headers:{authorization:`Bearer ${this.credentials.accessToken}`,accept:"application/json","user-agent":"reason-cli","x-reason-agent":"Reason CLI",...r.raw?{"content-type":r.raw.contentType}:r.body===void 0?{}:{"content-type":"application/json"},...r.headers},body:r.raw?r.raw.bytes:r.body===void 0?void 0:JSON.stringify(r.body),signal:r.signal,redirect:"error"}),m=await c.json().catch(()=>({}));if(c.status===401&&!a&&r.retryUnauthorized!==!1&&this.credentials.credentialKind!=="api_key"){let p=await At({fetchImpl:l,path:this.options.credentialsPath,forceRefresh:!0,signal:r.signal});if(p)return this.credentials=p,this.request(e,r,!0)}if(!c.ok)throw F(c.status,m,c.headers.get("retry-after"));return m}createHeadlessDeviceEnrollmentTicket(e){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/devices/enrollment-tickets`,{method:"POST",body:e,signal:AbortSignal.timeout(30000),retryUnauthorized:!1})}async enrollHeadlessDevice(e){try{return await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/devices/enrollments`,{method:"POST",body:e,signal:AbortSignal.timeout(30000),retryUnauthorized:!1})}catch(r){if(r instanceof I&&(r.status===404||r.status===405||r.status===403&&r.code==="endpoint_not_available"))return null;throw r}}addDeviceRoot(e,r){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/devices/${encodeURIComponent(e)}/roots`,{method:"POST",body:r,signal:AbortSignal.timeout(30000)})}removeDeviceRoot(e,r){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/devices/${encodeURIComponent(e)}/roots/${encodeURIComponent(r)}`,{method:"DELETE",signal:AbortSignal.timeout(30000)})}machinePath(e,r=""){let a=`/organizations/${encodeURIComponent(this.credentials.orgId)}/machines`;return e===void 0?a:`${a}/${encodeURIComponent(e)}${r}`}async listMachines(){return h(Ue,await this.request(this.machinePath()),"invalid_machine_list").machines}async createMachine(e){let r=await this.request(this.machinePath(),{method:"POST",body:{name:e.name,...e.platform?{platform:e.platform}:{}}});return h(Te,r,"invalid_machine").machine}async deleteMachine(e){let r=await this.request(this.machinePath(e),{method:"DELETE"});return h(qe,r,"invalid_machine_deletion")}async createMachineToken(e){let r=await this.request(this.machinePath(e,"/tokens"),{method:"POST",body:{}});return h(Oe,r,"invalid_machine_token")}async createMachineEnrollmentTicket(e,r){let a=await this.request(this.machinePath(e,"/enrollment-tickets"),{method:"POST",body:r,signal:AbortSignal.timeout(30000),retryUnauthorized:!1});return h(H,a,"invalid_machine_ticket")}self(e){return this.request("/self",{signal:e})}agentNetwork(){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-network`,{signal:AbortSignal.timeout(30000)})}startAgentNetwork(e){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-network`,{method:"POST",body:e,signal:AbortSignal.timeout(30000)})}rotateAgentNetwork(e){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-network`,{method:"PUT",body:e,signal:AbortSignal.timeout(30000)})}async claimAgentNetworkRelayJob(e,r){let a=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-network/relay/claim`,{method:"POST",body:e,signal:r});return h(P,a,"invalid_agent_network_job")}async completeAgentNetworkRelayJob(e,r){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-network/relay/jobs/${encodeURIComponent(e)}`,{method:"POST",body:r,signal:AbortSignal.timeout(30000)})}async recordAgentNetworkRelayReplies(e){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-network/relay/replies`,{method:"POST",body:{messages:e},signal:AbortSignal.timeout(30000)})}async workspaceMembers(){return((await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/members/users`,{signal:AbortSignal.timeout(30000)})).items??[]).flatMap((r)=>typeof r.email==="string"?[{email:r.email,role:typeof r.role==="string"?r.role:"member"}]:[])}claimExistingCliPairing(e){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/onboarding/import/pairing/claim-existing`,{method:"POST",body:{pairing_code:e}})}async claudeCodeSignIn(e){return(await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/provider-credentials`,{retryUnauthorized:!1,signal:e?AbortSignal.any([e,AbortSignal.timeout(15000)]):AbortSignal.timeout(15000)})).claude_code_sign_in===!0}connectAnthropicProvider(e,r,a={}){let l=e.kind==="setup_token"?{setup_token:e.token}:{access_token:e.credential.access,refresh_token:e.credential.refresh,expires_at:new Date(e.credential.expires).toISOString()};return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/provider-credentials/anthropic`,{method:"POST",retryUnauthorized:a.retryUnauthorized,signal:a.signal,body:{...l,...r?{account_key:r}:{}}})}async listRepositories(){return((await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/repositories`)).items??[]).flatMap((r)=>{let a=typeof r.full_name==="string"?r.full_name:typeof r.repo_full_name==="string"?r.repo_full_name:null;if(!a)return[];return[{repo_id:typeof r.repo_id==="string"?r.repo_id:void 0,full_name:a,provider:r.provider==="gitlab"?"gitlab":"github",default_branch:typeof r.default_branch==="string"?r.default_branch:null,private:typeof r.private==="boolean"?r.private:void 0}]})}async listProjects(){let e=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/projects`),r=be.safeParse(e);if(!r.success)throw new I(502,"invalid_project_list","Reason returned an unexpected project list.");return r.data.items}async listReasons(){let e=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/reasons`);return h(we,e,"invalid_reason_list").items}async openReasonConversation(e){let r=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/reasons/${encodeURIComponent(e)}/conversation`,{method:"POST"});return h(i({session_id:t().min(1)}),r,"invalid_reason_conversation").session_id}async listSkills(){try{let e=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/skills`);return h(ke,e,"invalid_skill_list").items}catch(e){if(e instanceof I&&(e.status===403||e.status===404))return[];throw e}}async listDevices(){let e=[],r=null;for(let a=0;a<50;a+=1){let l=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/devices${r?`?after=${encodeURIComponent(r)}`:""}`),c=ye.safeParse(l);if(!c.success)throw new I(502,"invalid_device_list","Reason returned an unexpected machine list.");if(e.push(...c.data.devices),r=c.data.has_next_page?c.data.end_cursor??null:null,!r)break}return e}async listModels(){try{let r=((await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-auth/models`)).models??[]).filter((c)=>c.hidden!==!0),a=r.filter((c)=>c.available!==!1).map(({reasoning_efforts:c,hidden:m,available:p,...f})=>({...f,...Array.isArray(c)?{reasoning_efforts:pe.filter((y)=>c.includes(y))}:{}})),l=new Set(a.map((c)=>c.detail));return{models:a.length>1&&l.size===1?a.map(({detail:c,...m})=>m):a,runnable:a.length>0||r.length===0}}catch(e){if(e instanceof I&&(e.status===403||e.status===404))return{models:[],runnable:!0};throw e}}async getAgentVersion(e){try{let r=await this.request("/deployment",{signal:e,retryUnauthorized:!1});return v(r.reason_version)?r.reason_version:null}catch{return null}}async getUsageQuota(){try{let e=ue.safeParse(await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/usage/quota`));if(!e.success)return null;let r;try{r=he(await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/agent-auth/models`))}catch{}return{...e.data,own_inference:r}}catch(e){if(e instanceof I&&(e.status===403||e.status===404))return null;throw e}}async listSessions(e=50,r,a={}){let l=new URLSearchParams({first:String(Math.min(Math.max(e,1),200)),status:a.status??"active"});if(r)l.set("project_id",r);if(a.origin)l.set("origin",a.origin);return(await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions?${l.toString()}`)).items??[]}getSession(e,r){let a=r?.fields.length?`?fields=${encodeURIComponent(r.fields.join(","))}`:"";return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}${a}`)}async prestartSession(e){let r=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/prestart`,{method:"POST",body:{client_session_id:e}});return r?.status==="starting"||r?.status==="ready"}async createSession(e){let r=e.mode==="ephemeral"||e.workspaceOwnership==="externally-managed";if(e.attachments?.length)await this.requireSessionAttachments();if(r||e.runtimeProfile){let c=await this.request("/deployment");if(r&&(!Array.isArray(c.session_modes)||!c.session_modes.includes(e.mode??"standard")||!Array.isArray(c.workspace_ownerships)||!c.workspace_ownerships.includes(e.workspaceOwnership??"managed")))throw Error("Deployment does not support the requested Session policy; refusing to create a Session.");if(e.runtimeProfile&&(!Array.isArray(c.experimental_runtime_profiles)||!c.experimental_runtime_profiles.includes(e.runtimeProfile)))throw Error("Deployment does not support the requested runtime profile; refusing to create a Session.")}let a=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions`,{method:"POST",body:{prompt:e.prompt,...e.attachments?.length?{attachments:e.attachments}:{},...e.mode?{mode:e.mode}:{},...e.workspaceOwnership?{workspace_ownership:e.workspaceOwnership}:{},...e.target?{target:e.target}:{},...e.repo?{repo:e.repo}:{},...e.provider?{provider:e.provider}:{},...e.model?{model:e.model}:{},...e.reasoningEffort?{reasoning_effort:e.reasoningEffort}:{},...e.runtimeProfile?{experimental_runtime_profile:e.runtimeProfile}:{},...e.ref?{ref:e.ref}:{},...e.branch?{branch:e.branch}:{},...e.completionMode?{completion_mode:e.completionMode}:{},...e.env&&Object.keys(e.env).length>0?{env:e.env}:{},...e.clientSessionId?{client_session_id:e.clientSessionId}:{},...e.longRunning?{long_running:{enabled:!0}}:{},...e.spendLimitRcu?{spend_limit_rcu:e.spendLimitRcu}:{},idempotency_key:`cli-${crypto.randomUUID()}`}}),l=await this.getSession(a.session_id);if(r){let c=l.session_policy,m=["memoryRead","memoryWrite","skills","inheritedInstructions","integrations","secretInjection"];if(!c||c.version!==1||c.mode!==(e.mode??"standard")||c.workspaceOwnership!==(e.workspaceOwnership??"managed")||!c.components||m.some((p)=>c.components[p]!==!0))throw await this.cancelSession(a.session_id),Error("Server did not attest the requested Session policy; cancellation requested.")}if(e.runtimeProfile&&l.experimental_runtime_profile!==e.runtimeProfile)throw await this.cancelSession(a.session_id),Error("Server did not attest the requested runtime profile; cancellation requested.");return l}async getEvents(e,r=-1,a={}){try{return await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/events?after_seq=${r}&limit=500${a.waitMs?`&wait_ms=${a.waitMs}`:""}`,a.signal?{signal:a.signal}:{})}catch(l){if(!(l instanceof I)||l.status!==403&&l.status!==404)throw l;return{session:await this.getSession(e),items:[],next_seq:r}}}async getMessages(e,r){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/messages?first=500${r===void 0?"":`&after_seq=${r}`}`)}async getAttachments(e,r){try{return(await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/attachments${r?`?view=${r}`:""}`)).items??[]}catch(a){if(a instanceof I&&(a.status===403||a.status===404))return[];throw a}}async requireSessionAttachments(){let e=await this.request("/deployment",{headers:{"cache-control":"no-cache"}});if(e.session_attachments!==!0){let r=typeof e.reason_version==="string"&&/^\d+\.\d+(?:\.\d+)?$/.test(e.reason_version)?`Agent ${e.reason_version}`:null,a=typeof e.commit_sha==="string"&&/^[a-f0-9]{40,64}$/i.test(e.commit_sha)?`server ${e.commit_sha.slice(0,12)}`:null,l=[r,a].filter(Boolean).join(", ");throw Error(`This server does not support Session image attachments: ${new URL(this.credentials.apiOrigin).host}${l?` (${l})`:""}. The API server needs an attachment-capable deployment; updating the Agent version alone is not enough. Your image was not sent; retry after the server update.`)}}async sendMessage(e,r,a={}){if(a.attachments?.length)await this.requireSessionAttachments();return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/messages`,{method:"POST",body:{message:r,...a.attachments?.length?{attachments:a.attachments}:{},...a.model?{model:a.model}:{},...a.reasoningEffort?{reasoning_effort:a.reasoningEffort}:{},...a.target?{target:a.target}:{},...a.delivery?{delivery:a.delivery}:{}}})}async steerQueuedMessage(e,r){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/messages/${encodeURIComponent(r)}/steer`,{method:"POST",body:{}})}async withdrawQueuedMessage(e,r){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/messages/${encodeURIComponent(r)}/queued`,{method:"DELETE"})}async getConversation(e){let r=[],a=null;for(let l=0;l<50;l+=1){let c=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/conversation${a?`?after=${encodeURIComponent(a)}`:""}`);if(r.push(...c.items??[]),!c.has_next_page||!c.end_cursor)break;a=c.end_cursor}return r}createSharedLink(e,r){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/shared-links`,{method:"POST",body:{url:r.url,...r.label?{label:r.label}:{},...r.expiresInSeconds!==void 0?{expires_in_seconds:r.expiresInSeconds}:{}}})}sessionAction(e,r,a={}){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/${r}`,{method:"POST",body:a})}renameSession(e,r){return this.sessionAction(e,"rename",{title:r||null})}moveSessionToProject(e,r){return this.sessionAction(e,"project",{project_id:r})}compactSession(e){return this.sessionAction(e,"compact")}retrySession(e){return this.sessionAction(e,"retry")}rewindSession(e,r){return this.sessionAction(e,"rewind",{message_id:r.messageId,content:r.content,request_id:r.requestId})}forkSession(e,r){return this.sessionAction(e,"fork",{...r.message?{message:r.message}:{},client_session_id:r.clientSessionId})}cancelSession(e,r={}){return this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}/cancel`,{method:"POST",body:r.mode==="hard"?{mode:"hard"}:{}})}sessionPath(e,r=""){return`/organizations/${encodeURIComponent(this.credentials.orgId)}/sessions/${encodeURIComponent(e)}${r}`}async archiveSession(e){await this.request(this.sessionPath(e,"/archive"),{method:"POST",body:{}})}async unarchiveSession(e){await this.request(this.sessionPath(e,"/unarchive"),{method:"POST",body:{}})}async deleteSession(e){await this.request(this.sessionPath(e),{method:"DELETE"})}async listSessionTags(e){return h(L,await this.request(this.sessionPath(e,"/tags")),"invalid_session_tags").tags}async appendSessionTags(e,r){let a=await this.request(this.sessionPath(e,"/tags"),{method:"POST",body:{tags:r}});return h(L,a,"invalid_session_tags").tags}async sessionInsight(e,r=!1){let a=await this.request(this.sessionPath(e,r?"/insights/generate":"/insights"),r?{method:"POST",body:{}}:{});return h($e,a,"invalid_session_insight")}async listAutomations(){let e=[],r=null;for(let a=0;a<20;a+=1){let l=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/automations?first=100${r?`&after=${encodeURIComponent(r)}`:""}`),c=h(Pe,l,"invalid_automation_list");if(e.push(...c.items),r=c.has_next_page?c.end_cursor??null:null,!r)break}return e}async createScheduledAutomation(e,r){let a=`/organizations/${encodeURIComponent(this.credentials.orgId)}/automations`,l=h(N,await this.request(a,{method:"POST",body:{name:e.name,instructions:e.instructions,...e.repo?{repo:e.repo.full_name,provider:e.repo.provider}:{}}}),"invalid_automation");try{await this.request(`${a}/${encodeURIComponent(l.id)}/triggers`,{method:"POST",body:r})}catch(c){throw await this.deleteAutomation(l.id).catch(()=>{return}),c}return l}async setAutomationEnabled(e,r){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/automations/${encodeURIComponent(e)}`,{method:"PATCH",body:{enabled:r}})}async deleteAutomation(e){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/automations/${encodeURIComponent(e)}`,{method:"DELETE"})}async transcribe(e,r){let a=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/transcribe`,{method:"POST",raw:{bytes:e,contentType:r}});return h(i({transcript:t()}),a,"invalid_transcript").transcript}async listMcpServers(){let e=await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/mcp-servers`);return h(Ce,e,"invalid_mcp_server_list").items}async setSkillEnabled(e,r){await this.request(`/organizations/${encodeURIComponent(this.credentials.orgId)}/skills/${encodeURIComponent(e)}`,{method:"PUT",body:{is_enabled:r}})}}
|
|
5
|
-
export{At,I,ps,Ho};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{T}from"./vm-hands-entry-lite-fcvf8md1.js";import{basename as ln}from"path";var dt=["production","staging"],un="https://api.reasonmachines.com",fn="https://staging-api.reasonmachines.com";var A={production:{api:"https://api.reasonmachines.ai",app:"https://reasonmachines.ai"},staging:{api:"https://staging-api.reasonmachines.ai",app:"https://staging.reasonmachines.ai"}},gn=new Set(["ara-staging","ara-staging.exe","reason-staging","reason-staging.exe"]);function g(n={}){let e=T(n.env??process.env,"REASON_CLI_CHANNEL")?.trim().toLowerCase();if(e){if(dt.includes(e))return e;throw Error(`Unknown Reason CLI channel: ${e}`)}let r=ln(n.executablePath??process.execPath).toLowerCase();return gn.has(r)?"staging":"production"}function Vt(n){return n==="staging"?fn:un}var U={production:["https://api.ara.so",A.production.api],staging:["https://api-staging.ara.so",A.staging.api]};function Wr(n){let e;try{e=new URL(n).origin}catch{return n}let r=dt.find((t)=>U[t].includes(e));return r?Vt(r):e}function ho(n,e){return n===e||Wr(n)===Wr(e)}function fo(n,e){return dt.some((r)=>U[r].includes(n)&&e===Vt(r))}function mo(n,e){try{let r=new URL(e);return!r.username&&!r.password&&(r.origin===Vt(n)||r.origin===A[n].api)}catch{return!1}}function qn(n){try{let e=new URL(n).hostname.replace(/^\[|\]$/g,"").toLowerCase();return e==="localhost"||e==="127.0.0.1"||e==="::1"}catch{return!1}}import{randomBytes as J}from"crypto";import{chmodSync as q,closeSync as B,constants as bn,linkSync as V,lstatSync as w,mkdirSync as z,openSync as En,readdirSync as L,readFileSync as Wn,readlinkSync as _,renameSync as k,rmdirSync as Q,symlinkSync as S,unlinkSync as y}from"fs";import{createRequire as Nn}from"module";import{constants as Sn}from"os";import{basename as R,join as l,sep as kn}from"path";import{existsSync as O,lstatSync as j,readdirSync as pn,readFileSync as mn,readlinkSync as dn,realpathSync as yn}from"fs";import{join as d,sep as hn}from"path";function G(n,...e){let r=d(n,"ara"),t=d(n,"reason");if(!Vr(r))return d(t,...e);if(!O(t))return d(r,...e);return O(d(r,...e))&&!O(d(t,...e))?d(r,...e):d(t,...e)}function Vr(n){try{let e=j(n);if(!e.isSymbolicLink())return e.isDirectory();return dn(n)!=="reason"&&O(n)}catch{return!1}}function X(n,e=[]){if(!Vr(n))return!1;let r;try{r=[n,...pn(n,{withFileTypes:!0}).filter((t)=>t.isDirectory()).map((t)=>d(n,t.name))]}catch{return!1}return r.some((t)=>["connect","connect-once"].filter((i)=>!e.includes(d(t,i))).some((i)=>{let s=d(t,i,"worker.json");try{j(s)}catch{return!1}try{let a=JSON.parse(mn(s,"utf8"))?.stateDirectory;if(typeof a!=="string")return!0;let c=(o,u)=>o===u||o.startsWith(u+hn);return c(a,n)||c(M(a),M(n))}catch{return!0}}))}function M(n){try{return yn(n)}catch{return n}}var P=new Set(["credentials.json","local-device.json","local-device.revoked.json","local-device.auth-migration.json","local-device.json.registration-pending.json","local-daemon.json","local-daemon.json.workspaces.json","local-root-fingerprint-key.json","instances","workspaces"]),Z=new Set(["local-device.proxy.json"]),Cn=new Set(["local-device.key","local-device.binding"]),W=new Map;function pt(n,e,r){let t=l(n,"ara");if(process.platform==="win32"||/[/\\]\.reason-ssh[/\\][^/\\]+[/\\]installer-home[/\\]\.config$/.test(n))return{state:m(t)?.isDirectory()?"kept":"absent"};return vn(t,l(n,"reason"),{linkAlways:!0,kept:(i)=>X(i,r??[]),native:e===void 0?An:()=>e},r!==void 0)}function xe(n,...e){return pt(n),G(n,...e)}var nn="config_rename_unavailable:busy";function vn(n,e,r,t=!1){let i=t?void 0:W.get(n);if(i)return i;let s;try{s=_n(n,e,r)}catch(a){let c=`config_rename_unavailable:${E(a)??"failed"}`;try{return{state:m(n)?.isDirectory()?"kept":"absent",problem:c}}catch{return{state:"kept",problem:c}}}if(!(s.state==="absent"&&r.linkAlways)&&s.problem!==nn&&!(s.state==="kept"&&!s.problem))W.set(n,s);return s}function _n(n,e,r){wn(e,r.native);let t=!1;for(let i=0;i<8;i+=1){let s=m(n);if(s?.isSymbolicLink())return _(n)===R(e)?{state:t?"renamed":"linked"}:{state:"kept"};if(!s){if(D(e))f(()=>y(e),"ENOENT");if(!(t||r.linkAlways)||!x(e))return{state:"absent"};let o=v(e,"link");S(R(e),o);try{f(()=>k(o,n),"EISDIR","ENOTEMPTY","EEXIST","ENOTDIR")}finally{f(()=>y(o),"ENOENT")}continue}if(!s.isDirectory())return{state:"absent"};if(r.kept(n))return K(e),{state:"kept"};let a=r.native();if(!a)return K(e),{state:"kept",problem:"config_rename_unavailable:no_native"};let c=In(a,n);if(!c)return{state:"kept",problem:nn};try{if(w(n).isSymbolicLink())continue;let o=Rn(a,n,e);if(o)return{state:"kept",problem:o};t=!0}finally{c()}}throw Object.assign(Error("legacy directory rename did not settle"),{code:"unsettled"})}function Rn(n,e,r){let t=m(r);if(!t||D(r)){if(!t)S(R(r),r);try{n.exchange(e,r)}catch(o){if(D(r))f(()=>y(r),"ENOENT");return`config_rename_unavailable:${E(o)??"exchange_failed"}`}return null}if(!t.isDirectory())return"config_rename_unavailable:ENOTDIR";if(t.dev!==w(e).dev)return"config_rename_unavailable:EXDEV";let i=[v(r,"probe"),v(r,"probe")];try{S("a",i[0]),S("b",i[1]),n.exchange(i[0],i[1])}catch(o){return`config_rename_unavailable:${E(o)??"exchange_failed"}`}finally{for(let o of i)f(()=>y(o),"ENOENT")}let s=cn(r);for(let o of Cn){let u=m(l(r,o)),p=m(l(e,o));if(u&&p&&u.ino!==p.ino)z(`${s}-replaced`,{mode:448,recursive:!0}),k(l(r,o),l(`${s}-replaced`,o))}let a={linked:new Map,unitsKept:new Set};rn(e,r,"",a);let c=v(r,"rename");S(R(r),c);try{n.exchange(e,c)}catch(o){return f(()=>y(c),"ENOENT"),`config_rename_unavailable:${E(o)??"exchange_failed"}`}return tn(c,r,a,s),null}function en(n){return n===""||!n.includes(kn)}function rn(n,e,r,t){let i=en(r)&&sn(l(e,r),l(n,r));if(i)t.unitsKept.add(r);for(let s of L(l(n,r))){if(i&&(P.has(s)||Z.has(s)))continue;let a=l(r,s),c=l(n,a),o=l(e,a),u=m(c);if(!u)continue;let p=m(o);if(u.isDirectory()){if(!p)f(()=>z(o,{mode:u.mode&4095}),"EEXIST"),q(o,u.mode&4095);if(x(o))rn(n,e,a,t)}else if(!p){if(u.isSymbolicLink())f(()=>S(_(c),o),"EEXIST");else if(f(()=>V(c,o),"EEXIST","ENOENT"))t.linked.set(a,u.ino)}}}function wn(n,e){let r;try{if(!x(n))return;r=L(n)}catch{return}for(let t of r){let i=/^\.(rename|link|probe|claim)-(\d+)-[0-9a-f]+$/.exec(t);if(!i)continue;let s=l(n,t),a=m(s);if(!a)continue;if(!a.isDirectory()){if(!Y(Number(i[2])))f(()=>y(s),"ENOENT");continue}let c=e(),o=null;if(c){try{o=c.lock(s)}catch{continue}if(!o)continue}else if(Y(Number(i[2])))continue;try{let u=v(n,"claim");if(f(()=>k(s,u),"ENOENT"))tn(u,n,null,cn(n))}finally{o?.()}}}function tn(n,e,r,t){for(let[i,s]of r?.linked??[])if(!m(l(n,i))&&m(l(e,i))?.ino===s)f(()=>y(l(e,i)),"ENOENT");if(on(n,e,"",r),f(()=>Q(n),"ENOTEMPTY","EEXIST"))return;k(n,t),q(t,448)}function on(n,e,r,t){let i=en(r)&&(t?t.unitsKept.has(r):sn(l(e,r),l(n,r)));for(let s of L(l(n,r))){let a=l(r,s),c=l(n,a),o=l(e,a),u=w(c),p=m(o);if(p&&u.ino===p.ino&&u.dev===p.dev){y(c);continue}if(u.isFile()&&p?.isFile()&&t?.linked.get(a)===p.ino){k(c,o);continue}if(i&&(P.has(s)||Z.has(s)))continue;if(!p){if(u.isFile()){if(f(()=>V(c,o),"EEXIST"))y(c)}else f(()=>k(c,o),"EEXIST","ENOTEMPTY");continue}if(u.isDirectory()&&p.isDirectory())on(n,e,a,t),f(()=>Q(c),"ENOTEMPTY","EEXIST")}}function sn(n,e){for(let r of P)if(an(l(n,r),l(e,r)))return!0;return!1}function an(n,e){let r=m(n);if(!r)return!1;let t=m(e);if(!t)return!0;if(r.isDirectory()){if(!t.isDirectory())return!0;return L(n).some((i)=>an(l(n,i),l(e,i)))}if(r.isSymbolicLink())return!t.isSymbolicLink()||_(n)!==_(e);return r.ino!==t.ino||r.dev!==t.dev}function K(n){if(D(n))f(()=>y(n),"ENOENT")}function cn(n){return l(n,`.pre-rename-${new Date().toISOString().replace(/[:.]/g,"-")}-${J(3).toString("hex")}`)}function D(n){try{return w(n).isSymbolicLink()&&_(n)===R(n)}catch{return!1}}function x(n){let e=m(n);return e!==null&&e.isDirectory()}function In(n,e){for(let r=0;r<40;r+=1){let t=n.lock(e);if(t)return t;Atomics.wait(new Int32Array(new SharedArrayBuffer(4)),0,0,50)}return null}function v(n,e){return l(n,`.${e}-${process.pid}-${J(6).toString("hex")}`)}function Y(n){if(n===process.pid)return!1;try{return process.kill(n,0),!0}catch(e){return E(e)==="EPERM"}}function m(n){try{return w(n)}catch(e){if(E(e)==="ENOENT"||E(e)==="ENOTDIR")return null;throw e}}function f(n,...e){try{return n(),!0}catch(r){if(e.includes(E(r)??""))return!1;throw r}}function E(n){return n instanceof Error&&"code"in n&&typeof n.code==="string"?n.code:void 0}var C,On=2,Dn=4,Ln=2,Tn=2,H=-100;function An(){if(C!==void 0)return C;if(C=null,process.platform!=="linux"&&process.platform!=="darwin")return null;let n;try{n=Nn(import.meta.url)("bun:ffi")}catch{return null}let e=process.platform==="darwin",r=e?"__error":"__errno_location",t=e?["/usr/lib/libSystem.B.dylib"]:["libc.so.6",`libc.musl-${process.arch==="arm64"?"aarch64":"x86_64"}.so.1`],{FFIType:i}=n;for(let s of t)try{let a=e?"renamex_np":"renameat2",o=n.dlopen(s,{flock:{args:[i.i32,i.i32],returns:i.i32},[r]:{args:[],returns:i.ptr},[a]:e?{args:[i.ptr,i.ptr,i.u32],returns:i.i32}:{args:[i.i32,i.ptr,i.i32,i.ptr,i.u32],returns:i.i32}}).symbols,u=o[r]();if(u===null)continue;let p=(N)=>{let b=n.read.i32(u),h=Object.entries(Sn.errno).find(([,I])=>I===b)?.[0]??`errno_${b}`;return Object.assign(Error(`${N} failed: ${h}`),{code:h})},F=(N)=>Buffer.from(`${N}\x00`,"utf8");return C={exchange(N,b){let h=F(N),I=F(b);if((e?o[a](n.ptr(h),n.ptr(I),Ln):o[a](H,n.ptr(h),H,n.ptr(I),Tn))!==0)throw p("exchange")},lock(N){let b=En(N,bn.O_RDONLY);if(o.flock(b,On|Dn)===0)return()=>B(b);let h=p("lock");if(B(b),h.code==="EWOULDBLOCK"||h.code==="EAGAIN")return null;throw h}},C}catch{}return null}
|
|
3
|
-
export{dt,g,Vt,Wr,ho,fo,mo,qn,Vr,pt,xe};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
var Yt={name:"github-native-engineer-device-worker-production",version:"0.2.459",private:!0,type:"module",engines:{node:">=22",bun:">=1.3.0"},workspaces:["../../packages/runtime-distribution"],dependencies:{"@anthropic-ai/sandbox-runtime":"^0.0.73","@earendil-works/pi-tui":"1.0.0","@modelcontextprotocol/sdk":"^1.29.0","@reason/runtime-distribution":"workspace:*","playwright-core":"1.60.0",zod:"^4.4.3"},overrides:{"@hono/node-server":"^1.19.15","@earendil-works/pi-agent-core":"1.0.0","@earendil-works/pi-ai":"1.0.0","@earendil-works/pi-coding-agent":"1.0.0","@earendil-works/chord":"1.0.0","@earendil-works/pi-codemode":"1.0.0","@earendil-works/pi-mcp":"1.0.0","@earendil-works/pi-telemetry":"1.0.0","@earendil-works/pi-tui":"1.0.0","brace-expansion":"2.1.7",axios:"^1.20.0","basic-ftp":"^6.2.1","@grpc/grpc-js":"^1.14.5",browserslist:"^4.28.8","engine.io":"^6.6.7","fast-uri":"^3.1.8",hono:"^4.13.7","ip-address":"^10.7.1",nanoid:"^3.3.18",dompurify:"^3.4.17",postcss:"^8.5.23",qs:"^6.16.0","shell-quote":"^1.11.0","socket.io-parser":"^4.2.7",tmp:"^0.2.7",toml:"^4.2.0",undici:"^8.10.2",ws:"^8.21.0","js-yaml":"^4.3.2","@modelcontextprotocol/sdk":"^1.31.0","proxy-addr":"^2.0.8","source-map-js":"^1.2.2"}};
|
|
3
|
-
export{Yt};
|