hyperframes 0.8.143 → 0.8.144

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.
Files changed (187) hide show
  1. package/dist/{add-Q5EYDUAY.js → add-CWRTVGDB.js} +12 -12
  2. package/dist/{animatedGifPrep-H2DUQEZ3.js → animatedGifPrep-JTOHIWI4.js} +7 -7
  3. package/dist/{asset-C7JBYYX4.js → asset-KU2Z4UFM.js} +2 -2
  4. package/dist/{assetCataloger-FRO4G6OU.js → assetCataloger-3CS2P7PA.js} +3 -3
  5. package/dist/{auth-FRWLCO36.js → auth-IDSOIQWG.js} +1 -1
  6. package/dist/{autoUpdate-E4OZXQK6.js → autoUpdate-373B4BA2.js} +2 -2
  7. package/dist/{backgroundChecks-FSUVHN5L.js → backgroundChecks-53Q3NAMG.js} +3 -3
  8. package/dist/backgroundChecksWorker.js +3 -3
  9. package/dist/{batchRender-4U73BYTU.js → batchRender-UKZA6BME.js} +4 -4
  10. package/dist/{beats-U6KJWF35.js → beats-N5JGEOFR.js} +13 -13
  11. package/dist/{benchmark-5ONT7V7B.js → benchmark-CUN3LN4V.js} +9 -9
  12. package/dist/{browser-R4DU46IE.js → browser-NCZT5AP6.js} +39 -55
  13. package/dist/{bundleWithLocalizedFonts-VH55VOAL.js → bundleWithLocalizedFonts-FWC7PE2D.js} +2 -2
  14. package/dist/{capture-26G2DPSI.js → capture-QBLG3VJR.js} +18 -18
  15. package/dist/{capture-OGQAEYKO.js → capture-YLS32UHT.js} +2 -2
  16. package/dist/{catalog-RKORTIUE.js → catalog-HIWNAFHW.js} +12 -12
  17. package/dist/{catch-up-4OBERRQO.js → catch-up-HGS7KIAC.js} +4 -4
  18. package/dist/{check-P2XDN57S.js → check-FH6UYYLO.js} +66 -55
  19. package/dist/{checkBrowser-NTGJGAEA.js → checkBrowser-RNWNOMCZ.js} +81 -30
  20. package/dist/{chunk-LVX6NK36.js → chunk-2DA2BBNY.js} +1 -1
  21. package/dist/{chunk-4M4EC7JX.js → chunk-3VYNNWVA.js} +12 -1
  22. package/dist/{chunk-N3DQEVSI.js → chunk-3XTEXWNN.js} +8 -5
  23. package/dist/{chunk-KO5QBV73.js → chunk-4LAR447G.js} +1 -1
  24. package/dist/{chunk-W35EKBS6.js → chunk-4OC7MQNB.js} +2 -2
  25. package/dist/{chunk-CLOH4LIB.js → chunk-54QISXOC.js} +2 -2
  26. package/dist/{chunk-HC7EVDEL.js → chunk-5HJ343GH.js} +1 -1
  27. package/dist/{chunk-33RZPZ4K.js → chunk-5VMR4WBS.js} +271 -119
  28. package/dist/{chunk-PJU63L6W.js → chunk-5WADG7PR.js} +1 -1
  29. package/dist/{chunk-LW6HO6U3.js → chunk-7RAYSCYT.js} +1 -1
  30. package/dist/{chunk-QRKLPWEX.js → chunk-7SDCIWHQ.js} +11 -2
  31. package/dist/{chunk-LAOCA3MQ.js → chunk-A4Q7W4LV.js} +13 -8
  32. package/dist/{chunk-BT27OYYX.js → chunk-A53CBD24.js} +18 -12
  33. package/dist/{chunk-4PFZPP2N.js → chunk-A6S35NYA.js} +54 -16
  34. package/dist/{chunk-HW4AKJ5F.js → chunk-AUBOF2PN.js} +1 -1
  35. package/dist/{chunk-ZLW2V65P.js → chunk-BSQ7XANM.js} +3 -2
  36. package/dist/{chunk-LCSMOLGX.js → chunk-BYSBRF24.js} +69 -8
  37. package/dist/{chunk-BFDJ63J5.js → chunk-DDIVWXN7.js} +1 -1
  38. package/dist/{chunk-KOEWEFHK.js → chunk-DIRJ322I.js} +10 -5
  39. package/dist/{chunk-PAGIICKN.js → chunk-EX6C672Y.js} +1 -1
  40. package/dist/{chunk-6XMFEICO.js → chunk-F2SMS24Q.js} +34 -19
  41. package/dist/{chunk-QVYVUCWD.js → chunk-GEWKFRFI.js} +1 -1
  42. package/dist/{chunk-P7THMINS.js → chunk-GZM2EFOE.js} +1 -1
  43. package/dist/{chunk-KJJLA674.js → chunk-GZVP4TWN.js} +1 -46
  44. package/dist/{chunk-TAMQYQGJ.js → chunk-I5KY7EZP.js} +1 -1
  45. package/dist/{chunk-XONFUK3M.js → chunk-IEIJRMLZ.js} +47 -35
  46. package/dist/chunk-IR35BCLK.js +13 -0
  47. package/dist/{chunk-2LBBHMKT.js → chunk-JEHFZQYT.js} +1 -1
  48. package/dist/{chunk-KDPYVTEU.js → chunk-KBB4RG6F.js} +6 -1
  49. package/dist/{chunk-VIVBA6E6.js → chunk-KFKZ3ISO.js} +1 -1
  50. package/dist/{sherpa-LVIUEAGF.js → chunk-L5TUCXWR.js} +11 -45
  51. package/dist/{chunk-GNBGPUJ7.js → chunk-LC3RQURJ.js} +3 -3
  52. package/dist/{chunk-I7QGQAZM.js → chunk-LFX2HEYP.js} +7 -7
  53. package/dist/{chunk-U3X3TPBW.js → chunk-MAYCCGMQ.js} +11 -2
  54. package/dist/{chunk-UICWP23D.js → chunk-MXNDKDFT.js} +3 -3
  55. package/dist/{chunk-POLR33RB.js → chunk-NOPBBSLA.js} +15 -17
  56. package/dist/{chunk-DF2BHILQ.js → chunk-NV4RXIQ7.js} +3 -3
  57. package/dist/{chunk-KQLGTGE5.js → chunk-OIDN7G42.js} +2 -2
  58. package/dist/{chunk-F26LCYRY.js → chunk-OUSLVRO4.js} +68 -77
  59. package/dist/{chunk-Y6QL2LGO.js → chunk-P6WH6QTV.js} +1 -1
  60. package/dist/{chunk-OBXQRJWQ.js → chunk-QATWIE4K.js} +1 -1
  61. package/dist/{chunk-QFN7NVWM.js → chunk-RG3QWWIE.js} +1 -1
  62. package/dist/{chunk-HLYOEIWM.js → chunk-RI53TS2Y.js} +2 -2
  63. package/dist/{chunk-5FISWJ37.js → chunk-RVFEDAUV.js} +4 -4
  64. package/dist/{chunk-HMT2RPZU.js → chunk-SLCFKB3Y.js} +13 -9
  65. package/dist/chunk-UPFUC4DB.js +136 -0
  66. package/dist/{chunk-BYK73CR7.js → chunk-VYSUZEJG.js} +5 -5
  67. package/dist/chunk-WJB7WI4J.js +3753 -0
  68. package/dist/{chunk-7UYBQ6NF.js → chunk-XGFHYAYN.js} +14 -10
  69. package/dist/{chunk-OSSHSIMD.js → chunk-XU5GGV6R.js} +1 -1
  70. package/dist/{chunk-FVYXDXEV.js → chunk-Y6UPYWJS.js} +2 -2
  71. package/dist/{chunk-UM2GRYM3.js → chunk-YJXHMIZA.js} +3 -3
  72. package/dist/{chunk-3NE7ZYU2.js → chunk-YUAXFWSQ.js} +3 -3
  73. package/dist/{chunk-TVCRUG2S.js → chunk-ZEUONDQG.js} +1 -1
  74. package/dist/{chunk-ZQQ3SEIE.js → chunk-ZOA2SC4P.js} +99 -31
  75. package/dist/{clean-YHGPY33K.js → clean-KPX27IKJ.js} +18 -18
  76. package/dist/cli.js +68 -56
  77. package/dist/{cloud-DOFI5ISR.js → cloud-P7DAOISN.js} +4 -4
  78. package/dist/{cloudrun-KTZ4XDHL.js → cloudrun-XM56TBOH.js} +4 -4
  79. package/dist/{compare-SMMIZN2C.js → compare-F6YAFZZM.js} +25 -25
  80. package/dist/{compiler-TEXQWW6N.js → compiler-JZ4GNFMG.js} +6 -4
  81. package/dist/{component-B3GCNGSS.js → component-3CFOGIQA.js} +3 -3
  82. package/dist/{compositions-OQNZZTKF.js → compositions-CPCMWF24.js} +11 -11
  83. package/dist/{delete-EL5LVSEP.js → delete-GYVKOKB6.js} +2 -2
  84. package/dist/{dist-5UVIRMSM.js → dist-KDJTFJHA.js} +2 -2
  85. package/dist/{dist-XN234YFQ.js → dist-YPWQDWJ4.js} +4 -4
  86. package/dist/{doctor-UOL3OI2A.js → doctor-GWI3B6JT.js} +13 -13
  87. package/dist/{events-NIZBS6S7.js → events-BRRUDPPT.js} +3 -3
  88. package/dist/{events-K2DB2PBC.js → events-V2QFN4YM.js} +2 -2
  89. package/dist/{feedback-QMP4E6L7.js → feedback-CXMD7FWL.js} +9 -9
  90. package/dist/{ffmpeg-QIUFEFTY.js → ffmpeg-T5SH2EFJ.js} +3 -2
  91. package/dist/{figma-2AUJRNVC.js → figma-YABDWD66.js} +3 -3
  92. package/dist/fontLocalizeCli.js +9 -9
  93. package/dist/{get-P5NC7SRM.js → get-L2SOQKHX.js} +2 -2
  94. package/dist/{gpuPolicy-7N5MCE2G.js → gpuPolicy-NBJNWHYS.js} +11 -9
  95. package/dist/{grade-compare-HV5AFZ6P.js → grade-compare-STXQPKYQ.js} +27 -27
  96. package/dist/{help-3TSTXBLN.js → help-4H6BSFLB.js} +2 -2
  97. package/dist/{history-D65XFJ6D.js → history-4IQOLTHJ.js} +5 -5
  98. package/dist/hyperframe-runtime.js +56 -56
  99. package/dist/hyperframe.manifest.json +1 -1
  100. package/dist/hyperframe.runtime.iife.js +56 -56
  101. package/dist/hyperframes-player.global.js +3 -3
  102. package/dist/{info-TXV7MLFO.js → info-2CZOTNBC.js} +8 -8
  103. package/dist/{init-OSDMJZJV.js → init-6BXK42VS.js} +35 -36
  104. package/dist/{inspect-RQQSAYIJ.js → inspect-VKU47TBH.js} +26 -26
  105. package/dist/{installer-CDOB32HE.js → installer-T2BSSUDY.js} +5 -5
  106. package/dist/{keyframes-V75Q6GRM.js → keyframes-IEYVHRPI.js} +6 -6
  107. package/dist/{lambda-RODV4RCX.js → lambda-TIKG25CK.js} +5 -5
  108. package/dist/{layout-IZAI5SFC.js → layout-XOI4PT7A.js} +26 -26
  109. package/dist/{lint-PLXOXY5R.js → lint-DWCMVIX5.js} +8 -8
  110. package/dist/{lintProject-OQ6H6XBR.js → lintProject-UBZ3TDHU.js} +2 -2
  111. package/dist/{list-BQBPNKDZ.js → list-7GXKG5QM.js} +2 -2
  112. package/dist/{login-NP6F4FHC.js → login-BQ5L2UHX.js} +4 -4
  113. package/dist/{manager-CT3D67CG.js → manager-BPSR6D3V.js} +2 -2
  114. package/dist/{manager-GXYF4AVO.js → manager-YKMHR6LN.js} +8 -5
  115. package/dist/{media-treatment-PXGMZ4A4.js → media-treatment-IFB7OSZ3.js} +12 -12
  116. package/dist/{models-CEZM6XZ7.js → models-TY4PJ545.js} +59 -19
  117. package/dist/{motionShot-R4GHYWYM.js → motionShot-WXMFHICW.js} +21 -22
  118. package/dist/{normalize-H6KUHHEI.js → normalize-U3SL5VG3.js} +2 -2
  119. package/dist/{normalize-audio-MQ7NFCOV.js → normalize-audio-RFD776HQ.js} +6 -6
  120. package/dist/{open-AKQTGNXF.js → open-7IXXGO2E.js} +4 -4
  121. package/dist/parakeetRunner-IHLYYMTZ.js +67 -0
  122. package/dist/{pipeline-SYJYP2RM.js → pipeline-TXKPLL2U.js} +10 -9
  123. package/dist/{play-NBH4B7PL.js → play-J2KP64UK.js} +19 -19
  124. package/dist/{preflight-Y5DN5D37.js → preflight-B4AFK3RG.js} +4 -4
  125. package/dist/{present-XAX55CFS.js → present-MHHNRVRA.js} +15 -15
  126. package/dist/{preview-OLANKNFA.js → preview-CONUOFFQ.js} +19 -19
  127. package/dist/{producer-Q6YNZZUJ.js → producer-ZI46K7HH.js} +1 -1
  128. package/dist/{projectConfig-EM26P45P.js → projectConfig-FGGVG5MV.js} +7 -7
  129. package/dist/{publication-OXWJZKSX.js → publication-TXFBMW6B.js} +3 -3
  130. package/dist/{publish-4VBWP2UB.js → publish-YZSPBFRD.js} +11 -11
  131. package/dist/{remove-background-REB7427G.js → remove-background-4ATVLHLG.js} +11 -10
  132. package/dist/{render-K25YOG3M.js → render-6FBYLYGJ.js} +11 -11
  133. package/dist/{render-3CVZ2SZG.js → render-GFW5BPES.js} +4 -4
  134. package/dist/{render-TSE75QUL.js → render-MH4IUPWB.js} +26 -26
  135. package/dist/{render-batch-GGUOK3DS.js → render-batch-XUCZ2PUJ.js} +4 -4
  136. package/dist/{renderCancellation-PZRWB53I.js → renderCancellation-XF7M7IUP.js} +10 -9
  137. package/dist/renderSetupWorker.js +32 -44
  138. package/dist/{resolver-S5VK6UCB.js → resolver-W7AYCQGS.js} +5 -5
  139. package/dist/sherpa-LDUB5NLY.js +75 -0
  140. package/dist/sherpaWorker.js +2 -1
  141. package/dist/skills/hyperframes-cli/references/lint-validate-inspect.md +1 -1
  142. package/dist/{skills-I65FU5HD.js → skills-VENERS5X.js} +7 -7
  143. package/dist/{skillsUpdateCheck-J57RNNIV.js → skillsUpdateCheck-UXFYTACG.js} +3 -3
  144. package/dist/{snapshot-YROOGY22.js → snapshot-C6T74HTI.js} +28 -28
  145. package/dist/{src-X426BZAG.js → src-FS5RSVEI.js} +8 -8
  146. package/dist/{src-JO5JOV7Y.js → src-VUJ2FUFK.js} +8 -6
  147. package/dist/{staticProjectServer-5VMBS262.js → staticProjectServer-V2RZ4DWD.js} +15 -15
  148. package/dist/studio/assets/{hyperframes-player-BXSuksFh.js → hyperframes-player-Bw_jIaSX.js} +3 -3
  149. package/dist/studio/assets/{index-J7jpL4pj.js → index-BVM9NuWl.js} +141 -141
  150. package/dist/studio/assets/{index-BgOVCqjo.js → index-Cj7W_c7p.js} +1 -1
  151. package/dist/studio/assets/{index-FgyO_5Kv.js → index-DyH9dT7b.js} +1 -1
  152. package/dist/studio/{chunk-TFLU2MGI.js → chunk-3GHTHPZD.js} +8 -1
  153. package/dist/studio/chunk-3GHTHPZD.js.map +1 -0
  154. package/dist/studio/{chunk-H2DUOXTF.js → chunk-G3EDKRZH.js} +3 -3
  155. package/dist/studio/{chunk-UYWON5AX.js → chunk-PEAKCOUW.js} +7 -3
  156. package/dist/studio/chunk-PEAKCOUW.js.map +1 -0
  157. package/dist/studio/{chunk-LOVBLSMR.js → chunk-Y2OHHNM2.js} +35 -19
  158. package/dist/studio/chunk-Y2OHHNM2.js.map +1 -0
  159. package/dist/studio/{domEditingLayers-KBTPQKGA.js → domEditingLayers-PYST4G45.js} +3 -3
  160. package/dist/studio/index.html +1 -1
  161. package/dist/studio/index.js +139 -70
  162. package/dist/studio/index.js.map +1 -1
  163. package/dist/studio/player.js +3 -3
  164. package/dist/studio/ui.d.ts +4 -5
  165. package/dist/studio/ui.js +1 -1
  166. package/dist/{studio-api-VRBZUGAE.js → studio-api-TQE7KWKO.js} +9 -9
  167. package/dist/{studioServer-DBNKZ6I6.js → studioServer-CYKSQK7L.js} +68 -52
  168. package/dist/{telemetry-CXAX3TO3.js → telemetry-A23PPRD6.js} +3 -3
  169. package/dist/{timeline-VQ34WH7J.js → timeline-T3QSGT3A.js} +69 -47
  170. package/dist/{tokens-62R7VFAZ.js → tokens-RT5HWA6C.js} +2 -2
  171. package/dist/{transcribe-XOHPPL2O.js → transcribe-FOLNOC5G.js} +115 -51
  172. package/dist/{transcribe-7KR7IPJA.js → transcribe-HCF64LQK.js} +14 -12
  173. package/dist/{tts-MUV42JXT.js → tts-B6AHFQEO.js} +1 -1
  174. package/dist/{updateCheck-POYNH3B5.js → updateCheck-27PIP3AA.js} +2 -2
  175. package/dist/{upgrade-NBNOT7J2.js → upgrade-TVGXBUPJ.js} +2 -2
  176. package/dist/{urlDownloader-3NS63A7B.js → urlDownloader-KBLBJKRL.js} +6 -6
  177. package/dist/{validate-Y2QDHAEP.js → validate-ZMYGK4QI.js} +20 -20
  178. package/dist/{video-SJDMTSTL.js → video-AVE5GIGM.js} +7 -7
  179. package/package.json +1 -1
  180. package/dist/chunk-6TPZSTCL.js +0 -3681
  181. package/dist/studio/chunk-LOVBLSMR.js.map +0 -1
  182. package/dist/studio/chunk-TFLU2MGI.js.map +0 -1
  183. package/dist/studio/chunk-UYWON5AX.js.map +0 -1
  184. package/dist/{screenshotCapture-TEUIWXWN.js → screenshotCapture-3JXXUZND.js} +3 -3
  185. package/dist/studio/{chunk-H2DUOXTF.js.map → chunk-G3EDKRZH.js.map} +0 -0
  186. package/dist/studio/{domEditingLayers-KBTPQKGA.js.map → domEditingLayers-PYST4G45.js.map} +0 -0
  187. package/dist/{synthesize-C3IWDAXF.js → synthesize-UCI4X5O7.js} +4 -4
@@ -16,7 +16,7 @@ import {
16
16
  import {
17
17
  formatVariableValidationIssue,
18
18
  validateVariables
19
- } from "./chunk-4M4EC7JX.js";
19
+ } from "./chunk-3VYNNWVA.js";
20
20
  import {
21
21
  extractCompositionMetadata
22
22
  } from "./chunk-MQZVBHEY.js";
@@ -4,6 +4,10 @@ import { dirname as __hf_dirname } from "node:path";
4
4
  var require = __hf_createRequire(import.meta.url);
5
5
  var __filename = __hf_fileURLToPath(import.meta.url);
6
6
  var __dirname = __hf_dirname(__filename);
7
+ import {
8
+ resolveConfig,
9
+ usesSoftwareWebGpu
10
+ } from "./chunk-5VMR4WBS.js";
7
11
 
8
12
  // src/browser/gpuPolicy.ts
9
13
  function resolveLocalBrowserGpuMode(browserGpuArg, envMode = process.env.PRODUCER_BROWSER_GPU_MODE) {
@@ -13,11 +17,16 @@ function resolveLocalBrowserGpuMode(browserGpuArg, envMode = process.env.PRODUCE
13
17
  return "auto";
14
18
  }
15
19
  async function resolveCaptureBrowserGpuMode(requestedMode, chromePath) {
16
- const { resolveBrowserGpuMode } = await import("./src-JO5JOV7Y.js");
20
+ const { resolveBrowserGpuMode } = await import("./src-VUJ2FUFK.js");
17
21
  return resolveBrowserGpuMode(requestedMode, { chromePath });
18
22
  }
23
+ function resolveLocalWebGpu(browserGpuMode, requiresWebGpu) {
24
+ const gpuConfig = { browserGpuMode, allowSoftwareWebGpu: resolveConfig().allowSoftwareWebGpu };
25
+ return { gpuConfig, softwareWebGpu: usesSoftwareWebGpu(requiresWebGpu, gpuConfig) };
26
+ }
19
27
 
20
28
  export {
21
29
  resolveLocalBrowserGpuMode,
22
- resolveCaptureBrowserGpuMode
30
+ resolveCaptureBrowserGpuMode,
31
+ resolveLocalWebGpu
23
32
  };
@@ -7,7 +7,7 @@ var __dirname = __hf_dirname(__filename);
7
7
  import {
8
8
  runRenderSetupWorker,
9
9
  terminateProcessTree
10
- } from "./chunk-LCSMOLGX.js";
10
+ } from "./chunk-BYSBRF24.js";
11
11
 
12
12
  // src/utils/orphanCleanup.ts
13
13
  import { execFileSync } from "child_process";
@@ -62,17 +62,19 @@ function processIdentity(pid) {
62
62
  return null;
63
63
  }
64
64
  }
65
+ var holdsReusedPid = (parent, child) => parent.startedAt !== void 0 && child?.startedAt !== void 0 && parent.startedAt > child.startedAt;
65
66
  function recordsToAncestors(pid, records) {
66
67
  const byPid = new Map(records.map((record) => [record.pid, record]));
67
68
  const ancestors = [];
68
69
  const visited = /* @__PURE__ */ new Set([pid]);
69
70
  let current = pid;
70
71
  for (let depth = 0; depth < 64; depth++) {
71
- const parent = byPid.get(current)?.parentPid;
72
+ const child = byPid.get(current);
73
+ const parent = child?.parentPid;
72
74
  if (parent === void 0 || parent <= 1 || visited.has(parent)) break;
73
75
  visited.add(parent);
74
76
  const ancestor = byPid.get(parent);
75
- if (!ancestor) break;
77
+ if (!ancestor || holdsReusedPid(ancestor, child)) break;
76
78
  ancestors.push({ pid: ancestor.pid, identity: ancestor.identity });
77
79
  current = parent;
78
80
  }
@@ -92,11 +94,14 @@ function processAncestorSnapshot(pid) {
92
94
  ],
93
95
  { encoding: "utf8", timeout: 2e3, stdio: ["pipe", "pipe", "ignore"], windowsHide: true }
94
96
  );
95
- const records2 = output2.split(/\r?\n/).map((line) => line.trim().split(/\s+/)).map(([processId, parentProcessId, creationDate]) => ({
96
- pid: Number(processId),
97
- parentPid: Number(parentProcessId),
98
- identity: creationDate ? `windows:${creationDate}` : ""
99
- })).filter(
97
+ const records2 = output2.split(/\r?\n/).map((line) => line.trim().split(/\s+/)).map(
98
+ ([processId, parentProcessId, creationDate]) => ({
99
+ pid: Number(processId),
100
+ parentPid: Number(parentProcessId),
101
+ identity: creationDate ? `windows:${creationDate}` : "",
102
+ startedAt: creationDate && /^\d+$/.test(creationDate) ? BigInt(creationDate) : void 0
103
+ })
104
+ ).filter(
100
105
  (record) => Number.isInteger(record.pid) && record.pid > 0 && Number.isInteger(record.parentPid) && record.parentPid > 0 && record.identity !== ""
101
106
  );
102
107
  return recordsToAncestors(pid, records2);
@@ -6,24 +6,24 @@ var __filename = __hf_fileURLToPath(import.meta.url);
6
6
  var __dirname = __hf_dirname(__filename);
7
7
  import {
8
8
  serveStaticProjectHtml
9
- } from "./chunk-5FISWJ37.js";
9
+ } from "./chunk-RVFEDAUV.js";
10
10
  import {
11
11
  resolveProject
12
- } from "./chunk-VIVBA6E6.js";
12
+ } from "./chunk-KFKZ3ISO.js";
13
13
  import {
14
14
  AUDIT_SEEK_OPTIONS,
15
15
  installPageFunctionGuard,
16
16
  seekCompositionTimeline,
17
17
  waitForCompositionFonts,
18
18
  waitForRuntimeReady
19
- } from "./chunk-HMT2RPZU.js";
19
+ } from "./chunk-SLCFKB3Y.js";
20
20
  import {
21
21
  launchManagedBrowser,
22
22
  resolveManagedGpuMode
23
- } from "./chunk-PJU63L6W.js";
23
+ } from "./chunk-5WADG7PR.js";
24
24
  import {
25
25
  resolveDiagnosticNavigationTimeoutMs
26
- } from "./chunk-P7THMINS.js";
26
+ } from "./chunk-GZM2EFOE.js";
27
27
  import {
28
28
  defineCommand
29
29
  } from "./chunk-S3S4TGEH.js";
@@ -34,7 +34,7 @@ import {
34
34
  import {
35
35
  printDeprecationNotice,
36
36
  withMeta
37
- } from "./chunk-Y6QL2LGO.js";
37
+ } from "./chunk-P6WH6QTV.js";
38
38
  import {
39
39
  normalizeErrorMessage
40
40
  } from "./chunk-KNU5COPB.js";
@@ -707,7 +707,7 @@ async function collectTweenBoundaries(page) {
707
707
  });
708
708
  }
709
709
  async function bundleProjectHtml(projectDir) {
710
- const { bundleToSingleHtml } = await import("./compiler-TEXQWW6N.js");
710
+ const { bundleToSingleHtml } = await import("./compiler-JZ4GNFMG.js");
711
711
  return bundleToSingleHtml(projectDir);
712
712
  }
713
713
  async function alignViewportToComposition(page, url) {
@@ -727,10 +727,15 @@ async function alignViewportToComposition(page, url) {
727
727
  });
728
728
  }
729
729
  async function runLayoutAudit(projectDir, opts) {
730
- const { ensureBrowser } = await import("./manager-CT3D67CG.js");
730
+ const { ensureBrowser } = await import("./manager-BPSR6D3V.js");
731
731
  const puppeteer = await import("puppeteer-core");
732
- const { buildChromeArgs } = await import("./src-JO5JOV7Y.js");
733
- const { assertWebGpuAdapterAvailable, compositionRequiresWebGpu, resolveLocalBrowserGpuMode } = await import("./gpuPolicy-7N5MCE2G.js");
732
+ const { buildChromeArgs } = await import("./src-VUJ2FUFK.js");
733
+ const {
734
+ assertWebGpuAdapterAvailable,
735
+ compositionRequiresWebGpu,
736
+ resolveLocalBrowserGpuMode,
737
+ resolveLocalWebGpu
738
+ } = await import("./gpuPolicy-NBJNWHYS.js");
734
739
  const html = await bundleProjectHtml(projectDir);
735
740
  const server = await serveStaticProjectHtml(
736
741
  projectDir,
@@ -743,12 +748,13 @@ async function runLayoutAudit(projectDir, opts) {
743
748
  const requestedGpuMode = resolveLocalBrowserGpuMode();
744
749
  const resolvedGpuMode = await resolveManagedGpuMode(requestedGpuMode, browser.executablePath);
745
750
  const requiresWebGpu = compositionRequiresWebGpu(html);
751
+ const { gpuConfig, softwareWebGpu } = resolveLocalWebGpu(resolvedGpuMode, requiresWebGpu);
746
752
  chromeBrowser = await launchManagedBrowser(puppeteer.default, {
747
753
  headless: true,
748
754
  executablePath: browser.executablePath,
749
755
  args: buildChromeArgs(
750
756
  { width: 1920, height: 1080, captureMode: "screenshot", requiresWebGpu },
751
- { browserGpuMode: resolvedGpuMode }
757
+ gpuConfig
752
758
  )
753
759
  });
754
760
  const page = await chromeBrowser.newPage();
@@ -758,7 +764,7 @@ async function runLayoutAudit(projectDir, opts) {
758
764
  waitUntil: "domcontentloaded",
759
765
  timeout: resolveDiagnosticNavigationTimeoutMs()
760
766
  });
761
- await assertWebGpuAdapterAvailable(page, requiresWebGpu);
767
+ await assertWebGpuAdapterAvailable(page, requiresWebGpu, softwareWebGpu);
762
768
  await alignViewportToComposition(page, server.url);
763
769
  await waitForRuntimeReady(page, opts.timeout);
764
770
  await waitForCompositionFonts(page, 750);
@@ -6,7 +6,7 @@ var __filename = __hf_fileURLToPath(import.meta.url);
6
6
  var __dirname = __hf_dirname(__filename);
7
7
  import {
8
8
  runRenderSetupWorker
9
- } from "./chunk-LCSMOLGX.js";
9
+ } from "./chunk-BYSBRF24.js";
10
10
  import {
11
11
  chromeMajorCeiling,
12
12
  exceedsChromeCeiling
@@ -30,6 +30,7 @@ import {
30
30
  writeFileSync
31
31
  } from "fs";
32
32
  import { homedir } from "os";
33
+ import { debuglog } from "util";
33
34
  import { basename, dirname, join, relative } from "path";
34
35
  async function loadPuppeteerBrowsers() {
35
36
  try {
@@ -234,7 +235,7 @@ async function findFromHyperframesCache() {
234
235
  const match = installed.find(
235
236
  (b) => b.browser === Browser.CHROMEHEADLESSSHELL && b.buildId === managedChromeVersion() && b.platform === hostPlatform
236
237
  );
237
- if (match && existsSync(match.executablePath)) {
238
+ if (match && isUsableExecutable(match.executablePath)) {
238
239
  return { result: { executablePath: match.executablePath, source: "cache" } };
239
240
  }
240
241
  if (match) {
@@ -301,7 +302,7 @@ function findFromPuppeteerCache() {
301
302
  for (const version of versions) {
302
303
  if (exceedsChromeCeiling(version, ceiling)) continue;
303
304
  const binary = join(PUPPETEER_CACHE_DIR, version, ...executable);
304
- if (existsSync(binary)) {
305
+ if (isUsableExecutable(binary)) {
305
306
  return { executablePath: binary, source: "cache" };
306
307
  }
307
308
  }
@@ -345,14 +346,14 @@ async function findBrowser() {
345
346
  if (fromCache.result) return fromCache.result;
346
347
  if (fromCache.staleHyperframesCachePath) {
347
348
  console.warn(
348
- `[browser] Cached binary missing at ${fromCache.staleHyperframesCachePath} \u2014 re-downloading...`
349
+ `[browser] Cached binary unusable (missing, empty or not a file) at ${fromCache.staleHyperframesCachePath} \u2014 re-downloading...`
349
350
  );
350
351
  try {
351
352
  return await withInstallLock(() => downloadBrowser());
352
353
  } catch (err) {
353
354
  const cause = normalizeErrorMessage(err);
354
355
  throw new Error(
355
- `Cached Chrome binary was missing at ${fromCache.staleHyperframesCachePath}, and re-download failed: ${cause}
356
+ `Cached Chrome binary was unusable at ${fromCache.staleHyperframesCachePath}, and re-download failed: ${cause}
356
357
  Run \`hyperframes browser ensure --force\` to re-download.`
357
358
  );
358
359
  }
@@ -414,7 +415,7 @@ async function ensureBrowserInCurrentProcess(options) {
414
415
  if (fromCache.result) return fromCache.result;
415
416
  if (fromCache.staleHyperframesCachePath) {
416
417
  console.warn(
417
- `[browser] Cached binary missing at ${fromCache.staleHyperframesCachePath} \u2014 re-downloading...`
418
+ `[browser] Cached binary unusable (missing, empty or not a file) at ${fromCache.staleHyperframesCachePath} \u2014 re-downloading...`
418
419
  );
419
420
  return withInstallLock(() => downloadBrowser(options));
420
421
  }
@@ -478,10 +479,11 @@ function browserPathHintForPlatform() {
478
479
  }
479
480
  return "/usr/bin/google-chrome";
480
481
  }
481
- function wrapDownloadFailureWithBrowserPathHint(cause) {
482
+ function wrapDownloadFailureWithBrowserPathHint(cause, unzipLog) {
482
483
  const original = normalizeErrorMessage(cause);
484
+ const unzipErrors = unzipLog.length > 0 ? ` Unzip errors: ${unzipLog.join("; ")}` : "";
483
485
  const example = browserPathHintForPlatform();
484
- const message = `Failed to download chrome-headless-shell ${managedChromeVersion()}: ${original}
486
+ const message = `Failed to install chrome-headless-shell ${managedChromeVersion()}: ${original}${unzipErrors}
485
487
 
486
488
  Point hyperframes at an already-installed Chrome/Chromium instead:
487
489
 
@@ -502,13 +504,27 @@ async function downloadBrowser(options) {
502
504
  removeInstallLeftovers();
503
505
  const stagingDir = join(CACHE_ROOT_DIR, `${STAGING_PREFIX}${randomUUID()}`);
504
506
  const clearStaging = () => rmSync(stagingDir, { recursive: true, force: true });
505
- const runInstall = () => install({
506
- cacheDir: stagingDir,
507
- browser: Browser.CHROMEHEADLESSSHELL,
508
- buildId: managedChromeVersion(),
509
- platform,
510
- downloadProgressCallback: options?.onProgress
511
- });
507
+ let unzipLog = [];
508
+ const runInstall = () => {
509
+ unzipLog = [];
510
+ return install({
511
+ cacheDir: stagingDir,
512
+ browser: Browser.CHROMEHEADLESSSHELL,
513
+ buildId: managedChromeVersion(),
514
+ platform,
515
+ downloadProgressCallback: options?.onProgress,
516
+ logger: (prefix) => {
517
+ const debug = debuglog(prefix);
518
+ const isUnzip = prefix === "puppeteer:browsers:fileUtil";
519
+ if (!isUnzip && !debug.enabled) return void 0;
520
+ return (...args) => {
521
+ const line = args.join(" ");
522
+ if (isUnzip) unzipLog.push(line);
523
+ if (debug.enabled) debug(line);
524
+ };
525
+ }
526
+ });
527
+ };
512
528
  try {
513
529
  const staged = await installWithCorruptArchiveRecovery(
514
530
  runInstall,
@@ -517,13 +533,35 @@ async function downloadBrowser(options) {
517
533
  `[hyperframes] Downloaded browser archive was corrupt (${normalizeErrorMessage(err)}); re-downloading.`
518
534
  )
519
535
  );
536
+ assertExecutableUnpacked(stagingDir, staged.executablePath);
537
+ unzipLog = [];
520
538
  return { executablePath: moveStagedInstallIntoCache(stagingDir, staged), source: "download" };
521
539
  } catch (err) {
522
- throw wrapDownloadFailureWithBrowserPathHint(err);
540
+ throw wrapDownloadFailureWithBrowserPathHint(err, unzipLog);
523
541
  } finally {
524
542
  clearStaging();
525
543
  }
526
544
  }
545
+ function executableState(path) {
546
+ const stat = statSync(path, { throwIfNoEntry: false });
547
+ if (!stat) return "is missing";
548
+ if (!stat.isFile()) return "is not a file";
549
+ return stat.size > 0 ? "usable" : "is empty";
550
+ }
551
+ function isUsableExecutable(path) {
552
+ try {
553
+ return executableState(path) === "usable";
554
+ } catch {
555
+ return false;
556
+ }
557
+ }
558
+ function assertExecutableUnpacked(stagingDir, executablePath) {
559
+ const state = executableState(executablePath);
560
+ if (state === "usable") return;
561
+ throw new Error(
562
+ `the archive downloaded, but ${relative(stagingDir, executablePath)} ${state} after unzipping.`
563
+ );
564
+ }
527
565
  function moveStagedInstallIntoCache(stagingDir, staged) {
528
566
  const target = join(CACHE_DIR, relative(stagingDir, staged.path));
529
567
  const aside = join(CACHE_ROOT_DIR, `${REPLACED_PREFIX}${randomUUID()}`);
@@ -8,7 +8,7 @@ import {
8
8
  DEFAULT_REGISTRY_URL,
9
9
  fetchItemManifest,
10
10
  fetchRegistryManifest
11
- } from "./chunk-TAMQYQGJ.js";
11
+ } from "./chunk-I5KY7EZP.js";
12
12
 
13
13
  // src/registry/resolver.ts
14
14
  function defaultWarn(message) {
@@ -144,8 +144,9 @@ function rewriteAssetPath(compSrcPath, relativePath, assetExists) {
144
144
  const compDir = dirname(compSrcPath);
145
145
  if (!compDir || compDir === ".") return relativePath;
146
146
  const { basePath, suffix } = splitUrlSuffix(relativePath);
147
- if (!basePath) return relativePath;
148
- const filePath = decodeWellFormedEscapes(basePath);
147
+ const slashed = basePath.replace(/\\/g, "/");
148
+ if (!slashed || slashed.startsWith("/")) return relativePath;
149
+ const filePath = decodeWellFormedEscapes(slashed);
149
150
  const sibling = resolve2("/", join(compDir, filePath)).slice(1);
150
151
  if (!needsRewrite(filePath) && (!assetExists || !assetExists(sibling))) return relativePath;
151
152
  return encodeUrlPath(sibling) + suffix;
@@ -4,6 +4,9 @@ import { dirname as __hf_dirname } from "node:path";
4
4
  var require = __hf_createRequire(import.meta.url);
5
5
  var __filename = __hf_fileURLToPath(import.meta.url);
6
6
  var __dirname = __hf_dirname(__filename);
7
+ import {
8
+ normalizeErrorMessage
9
+ } from "./chunk-KNU5COPB.js";
7
10
 
8
11
  // src/utils/processTree.ts
9
12
  import { execFileSync, spawn } from "child_process";
@@ -121,6 +124,57 @@ async function terminateProcessTree(pid, options = {}) {
121
124
  return options.processGroup ? terminateProcessGroup(pid, signal) : terminatePidTree(pid, signal);
122
125
  }
123
126
 
127
+ // src/renderSetupWorkerLifecycle.ts
128
+ var RENDER_SETUP_SIGNALS = ["SIGINT", "SIGTERM", "SIGHUP"];
129
+ var RENDER_SETUP_RESULT_PREFIX = "HYPERFRAMES_RENDER_SETUP_RESULT:";
130
+ var RENDER_SETUP_ERROR_PREFIX = "HYPERFRAMES_RENDER_SETUP_ERROR:";
131
+ function installRenderSetupSignalHandlers(signalTarget, releaseLock, resendSignal, handleHangup = true) {
132
+ const handlers = /* @__PURE__ */ new Map();
133
+ const handledSignals = handleHangup ? RENDER_SETUP_SIGNALS : RENDER_SETUP_SIGNALS.filter((signal) => signal !== "SIGHUP");
134
+ for (const signal of handledSignals) {
135
+ const handler = () => {
136
+ releaseLock();
137
+ signalTarget.off(signal, handler);
138
+ resendSignal(signal);
139
+ };
140
+ handlers.set(signal, handler);
141
+ signalTarget.on(signal, handler);
142
+ }
143
+ return () => {
144
+ for (const [signal, handler] of handlers) signalTarget.off(signal, handler);
145
+ };
146
+ }
147
+ function prefixedLine(prefix, value) {
148
+ return prefix + JSON.stringify(value) + "\n";
149
+ }
150
+ function parseJson(text) {
151
+ try {
152
+ return JSON.parse(text);
153
+ } catch {
154
+ return void 0;
155
+ }
156
+ }
157
+ function prefixedValue(output, prefix) {
158
+ const line = output.split(/\r?\n/).find((text) => text.startsWith(prefix));
159
+ return line === void 0 ? void 0 : parseJson(line.slice(prefix.length));
160
+ }
161
+ function renderSetupResultLine(result) {
162
+ return prefixedLine(RENDER_SETUP_RESULT_PREFIX, result);
163
+ }
164
+ function renderSetupResultFrom(stdout) {
165
+ return prefixedValue(stdout, RENDER_SETUP_RESULT_PREFIX);
166
+ }
167
+ function renderSetupErrorLine(error) {
168
+ return "\n" + prefixedLine(RENDER_SETUP_ERROR_PREFIX, normalizeErrorMessage(error));
169
+ }
170
+ function renderSetupFailureFrom(stderr) {
171
+ const lines = stderr.split(/\r?\n/);
172
+ const at = lines.findIndex((text) => text.startsWith(RENDER_SETUP_ERROR_PREFIX));
173
+ const reason = at === -1 ? void 0 : parseJson(lines[at].slice(RENDER_SETUP_ERROR_PREFIX.length));
174
+ if (typeof reason !== "string" || reason === "") return void 0;
175
+ return { reason, earlierOutput: lines.slice(0, at).join("\n") };
176
+ }
177
+
124
178
  // src/utils/cancellableProcess.ts
125
179
  import { spawn as spawn2 } from "child_process";
126
180
  import { fileURLToPath } from "url";
@@ -269,7 +323,14 @@ function runCancellableProcess(command, args, options = {}) {
269
323
  }
270
324
  });
271
325
  }
272
- var SETUP_RESULT_PREFIX = "HYPERFRAMES_RENDER_SETUP_RESULT:";
326
+ function renderSetupError(error) {
327
+ if (!(error instanceof CancellableProcessError)) return error;
328
+ const failure = renderSetupFailureFrom(error.stderr);
329
+ if (failure?.earlierOutput.trim()) process.stderr.write(`${failure.earlierOutput.trimEnd()}
330
+ `);
331
+ const reason = failure?.reason ?? error.stderr.trim();
332
+ return reason ? new Error(reason, { cause: error }) : error;
333
+ }
273
334
  async function runRenderSetupWorker(mode, input, options) {
274
335
  const sourceMode = import.meta.url.endsWith(".ts");
275
336
  const workerUrl = new URL(
@@ -293,20 +354,20 @@ async function runRenderSetupWorker(mode, input, options) {
293
354
  );
294
355
  } catch (error) {
295
356
  if (options.signal?.aborted) options.signal.throwIfAborted();
296
- if (error instanceof CancellableProcessError && error.stderr.trim()) {
297
- throw new Error(error.stderr.trim(), { cause: error });
298
- }
299
- throw error;
357
+ throw renderSetupError(error);
300
358
  }
301
359
  if (result.stderr) process.stderr.write(result.stderr);
302
- const encoded = result.stdout.split(/\r?\n/).find((line) => line.startsWith(SETUP_RESULT_PREFIX))?.slice(SETUP_RESULT_PREFIX.length);
303
- if (!encoded) throw new Error(`${mode} setup process exited without a result`);
304
- return JSON.parse(encoded);
360
+ const value = renderSetupResultFrom(result.stdout);
361
+ if (value === void 0) throw new Error(`${mode} setup process exited without a result`);
362
+ return value;
305
363
  }
306
364
 
307
365
  export {
308
366
  processIsAlive,
309
367
  terminateProcessTree,
368
+ installRenderSetupSignalHandlers,
369
+ renderSetupResultLine,
370
+ renderSetupErrorLine,
310
371
  runCancellableProcess,
311
372
  runRenderSetupWorker
312
373
  };
@@ -19,7 +19,7 @@ import {
19
19
  decodeWellFormedEscapes,
20
20
  decodedUrlPath,
21
21
  readMediaOffsetSeconds
22
- } from "./chunk-ZLW2V65P.js";
22
+ } from "./chunk-BSQ7XANM.js";
23
23
 
24
24
  // ../studio-server/dist/chunk-32IH7WBY.js
25
25
  import { execFile } from "child_process";
@@ -10,22 +10,25 @@ import {
10
10
  distroLabel,
11
11
  getFFmpegInstallHint,
12
12
  parseLddMissingLibs
13
- } from "./chunk-TVCRUG2S.js";
13
+ } from "./chunk-ZEUONDQG.js";
14
14
  import {
15
15
  getFreeDiskMb
16
16
  } from "./chunk-GQJZORQP.js";
17
17
  import {
18
18
  ensureBrowser,
19
19
  findBrowser
20
- } from "./chunk-4PFZPP2N.js";
20
+ } from "./chunk-A6S35NYA.js";
21
21
  import {
22
22
  runCancellableProcess
23
- } from "./chunk-LCSMOLGX.js";
23
+ } from "./chunk-BYSBRF24.js";
24
24
  import {
25
25
  FFMPEG_PATH_ENV,
26
26
  FFPROBE_PATH_ENV,
27
27
  findFfBinary
28
28
  } from "./chunk-PJ3HDUCY.js";
29
+ import {
30
+ normalizeErrorMessage
31
+ } from "./chunk-KNU5COPB.js";
29
32
 
30
33
  // src/browser/preflight.ts
31
34
  import { existsSync } from "fs";
@@ -254,11 +257,13 @@ async function checkChrome(browserPath, signal) {
254
257
  };
255
258
  }
256
259
  let info;
260
+ let failure;
257
261
  try {
258
262
  info = signal ? await ensureBrowser({ preferManagedChrome: true, signal }) : await findBrowser();
259
- } catch {
263
+ } catch (error) {
260
264
  if (signal?.aborted) signal.throwIfAborted();
261
265
  info = void 0;
266
+ failure = normalizeErrorMessage(error);
262
267
  }
263
268
  if (info) {
264
269
  return chromeLaunchOutcome(
@@ -278,7 +283,7 @@ async function checkChrome(browserPath, signal) {
278
283
  ok: false,
279
284
  level: "error",
280
285
  title: "Chrome not found",
281
- detail: "Chrome Headless Shell is required for local rendering.",
286
+ detail: failure ?? "Chrome Headless Shell is required for local rendering.",
282
287
  hint: "Run: npx hyperframes browser ensure"
283
288
  };
284
289
  }
@@ -14,7 +14,7 @@ import {
14
14
  } from "./chunk-AWDFDFI3.js";
15
15
  import {
16
16
  isBlockedNetworkHost
17
- } from "./chunk-33RZPZ4K.js";
17
+ } from "./chunk-5VMR4WBS.js";
18
18
  import {
19
19
  DOMParser,
20
20
  parseHTML