failproofai 1.0.11-beta.0 → 1.0.11-beta.2

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 (975) hide show
  1. package/.next/standalone/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/build-manifest.json +109 -9
  3. package/.next/standalone/.next/prerender-manifest.json +6 -6
  4. package/.next/standalone/.next/required-server-files.json +17 -2
  5. package/.next/standalone/.next/server/app/_global-error/page/build-manifest.json +8 -6
  6. package/.next/standalone/.next/server/app/_global-error/page/server-reference-manifest.json +2 -3
  7. package/.next/standalone/.next/server/app/_global-error/page.js +13 -8
  8. package/.next/standalone/.next/server/app/_global-error/page.js.nft.json +1 -1
  9. package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
  10. package/.next/standalone/.next/server/app/_global-error.html +1 -1
  11. package/.next/standalone/.next/server/app/_global-error.rsc +17 -13
  12. package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +19 -15
  13. package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +17 -13
  14. package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +2 -1
  15. package/.next/standalone/.next/server/app/_not-found/page/build-manifest.json +8 -6
  16. package/.next/standalone/.next/server/app/_not-found/page/server-reference-manifest.json +2 -3
  17. package/.next/standalone/.next/server/app/_not-found/page.js +17 -12
  18. package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
  19. package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  20. package/.next/standalone/.next/server/app/_not-found.html +1 -1
  21. package/.next/standalone/.next/server/app/_not-found.rsc +32 -21
  22. package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +32 -21
  23. package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +37 -27
  24. package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +4 -2
  25. package/.next/standalone/.next/server/app/api/audit/invite/route.js +11 -7
  26. package/.next/standalone/.next/server/app/api/audit/invite/route.js.nft.json +1 -1
  27. package/.next/standalone/.next/server/app/api/audit/run/route.js +38 -11
  28. package/.next/standalone/.next/server/app/api/audit/run/route.js.nft.json +1 -1
  29. package/.next/standalone/.next/server/app/api/audit/status/route.js +6 -4
  30. package/.next/standalone/.next/server/app/api/audit/status/route.js.nft.json +1 -1
  31. package/.next/standalone/.next/server/app/api/auth/login-request/route.js +10 -6
  32. package/.next/standalone/.next/server/app/api/auth/login-request/route.js.nft.json +1 -1
  33. package/.next/standalone/.next/server/app/api/auth/login-verify/route.js +11 -7
  34. package/.next/standalone/.next/server/app/api/auth/login-verify/route.js.nft.json +1 -1
  35. package/.next/standalone/.next/server/app/api/auth/logout/route.js +11 -6
  36. package/.next/standalone/.next/server/app/api/auth/logout/route.js.nft.json +1 -1
  37. package/.next/standalone/.next/server/app/api/auth/status/route.js +11 -6
  38. package/.next/standalone/.next/server/app/api/auth/status/route.js.nft.json +1 -1
  39. package/.next/standalone/.next/server/app/api/download/[project]/[session]/route.js +6 -4
  40. package/.next/standalone/.next/server/app/api/download/[project]/[session]/route.js.nft.json +1 -1
  41. package/.next/standalone/.next/server/app/audit/page/build-manifest.json +8 -6
  42. package/.next/standalone/.next/server/app/audit/page/server-reference-manifest.json +4 -6
  43. package/.next/standalone/.next/server/app/audit/page.js +26 -19
  44. package/.next/standalone/.next/server/app/audit/page.js.nft.json +1 -1
  45. package/.next/standalone/.next/server/app/audit/page_client-reference-manifest.js +1 -1
  46. package/.next/standalone/.next/server/app/index.html +1 -1
  47. package/.next/standalone/.next/server/app/index.rsc +30 -20
  48. package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +34 -25
  49. package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +30 -20
  50. package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +3 -2
  51. package/.next/standalone/.next/server/app/page/build-manifest.json +8 -6
  52. package/.next/standalone/.next/server/app/page/server-reference-manifest.json +2 -3
  53. package/.next/standalone/.next/server/app/page.js +20 -14
  54. package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
  55. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  56. package/.next/standalone/.next/server/app/policies/page/build-manifest.json +8 -6
  57. package/.next/standalone/.next/server/app/policies/page/server-reference-manifest.json +28 -42
  58. package/.next/standalone/.next/server/app/policies/page.js +30 -21
  59. package/.next/standalone/.next/server/app/policies/page.js.nft.json +1 -1
  60. package/.next/standalone/.next/server/app/policies/page_client-reference-manifest.js +1 -1
  61. package/.next/standalone/.next/server/app/project/[name]/page/build-manifest.json +8 -6
  62. package/.next/standalone/.next/server/app/project/[name]/page/server-reference-manifest.json +2 -3
  63. package/.next/standalone/.next/server/app/project/[name]/page.js +44 -20
  64. package/.next/standalone/.next/server/app/project/[name]/page.js.nft.json +1 -1
  65. package/.next/standalone/.next/server/app/project/[name]/page_client-reference-manifest.js +1 -1
  66. package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/build-manifest.json +8 -6
  67. package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/react-loadable-manifest.json +2 -2
  68. package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/server-reference-manifest.json +4 -6
  69. package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page.js +39 -23
  70. package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page.js.nft.json +1 -1
  71. package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page_client-reference-manifest.js +1 -1
  72. package/.next/standalone/.next/server/app/projects/page/build-manifest.json +8 -6
  73. package/.next/standalone/.next/server/app/projects/page/server-reference-manifest.json +2 -3
  74. package/.next/standalone/.next/server/app/projects/page.js +24 -16
  75. package/.next/standalone/.next/server/app/projects/page.js.nft.json +1 -1
  76. package/.next/standalone/.next/server/app/projects/page_client-reference-manifest.js +1 -1
  77. package/.next/standalone/.next/server/app/settings/page/build-manifest.json +8 -6
  78. package/.next/standalone/.next/server/app/settings/page/server-reference-manifest.json +16 -24
  79. package/.next/standalone/.next/server/app/settings/page.js +30 -22
  80. package/.next/standalone/.next/server/app/settings/page.js.nft.json +1 -1
  81. package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  82. package/.next/standalone/.next/server/chunks/1oeh_server_app_api_download_[project]_[session]_route_actions_1is7vs762er-g.js +3 -0
  83. package/.next/standalone/.next/server/chunks/[externals]__08d8xc5bifn8z._.js +3 -0
  84. package/.next/standalone/.next/server/chunks/{[externals]__0h0p9dm._.js → [externals]__0h0p9dmv_e7r7._.js} +1 -1
  85. package/.next/standalone/.next/server/chunks/{[externals]__0hjaw70._.js → [externals]__0hjaw70fchx66._.js} +1 -1
  86. package/.next/standalone/.next/server/chunks/{[externals]__1oenfmn._.js → [externals]__0qkp92tjfvw8r._.js} +1 -1
  87. package/.next/standalone/.next/server/chunks/[externals]__105ihae9i2b_d._.js +3 -0
  88. package/.next/standalone/.next/server/chunks/{[externals]__0sds_16._.js → [externals]__1_407huhlmj1m._.js} +1 -1
  89. package/.next/standalone/.next/server/chunks/[externals]__1k8s9m68ew993._.js +3 -0
  90. package/.next/standalone/.next/server/chunks/{[externals]__0d7i9ea._.js → [externals]__1rlxpymm37wel._.js} +1 -1
  91. package/.next/standalone/.next/server/chunks/{[externals]__1s462yl._.js → [externals]__1s462ylxpc7-5._.js} +1 -1
  92. package/.next/standalone/.next/server/chunks/[externals]_node_net_1yam_zj43-40b._.js +3 -0
  93. package/.next/standalone/.next/server/chunks/{[externals]_node_os_0by37l-._.js → [externals]_node_os_0by37l-11q5ls._.js} +1 -1
  94. package/.next/standalone/.next/server/chunks/[root-of-the-server]__07l68zv0hqdiu._.js +3 -0
  95. package/.next/standalone/.next/server/chunks/[root-of-the-server]__08dchfudh2_4f._.js +3 -0
  96. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0_0xu5zkw15bs._.js +3 -0
  97. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0car70pylmvor._.js +3 -0
  98. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0jz5xqu-p_lfc._.js +3 -0
  99. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0spt0kv8azrpl._.js +3 -0
  100. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0swiyzbmvja2d._.js +327 -0
  101. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0u3i025_setk_._.js +3 -0
  102. package/.next/standalone/.next/server/chunks/[root-of-the-server]__10a2f6s636yc7._.js +3 -0
  103. package/.next/standalone/.next/server/chunks/[root-of-the-server]__168oo8wb5n23f._.js +3 -0
  104. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1ey11fel2q2qw._.js +3 -0
  105. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1izwqj_ij_9x_._.js +3 -0
  106. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1qt5u58xrcuk6._.js +3 -0
  107. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1r7kbfkiw2xmu._.js +322 -0
  108. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1ztigqa01tigq._.js +3 -0
  109. package/.next/standalone/.next/server/chunks/[turbopack]_runtime.js +146 -16
  110. package/.next/standalone/.next/server/chunks/_09dz7xva4ce_2._.js +27 -0
  111. package/.next/standalone/.next/server/chunks/_0hf5q4xzyg40j._.js +3 -0
  112. package/.next/standalone/.next/server/chunks/_0p53ge1jmkucy._.js +3 -0
  113. package/.next/standalone/.next/server/chunks/_0tovk6q0miud6._.js +3 -0
  114. package/.next/standalone/.next/server/chunks/_0trp3ycqv17cl._.js +3 -0
  115. package/.next/standalone/.next/server/chunks/_1-2owkp-1_987._.js +3 -0
  116. package/.next/standalone/.next/server/chunks/_13ltj8a9z92o8._.js +3 -0
  117. package/.next/standalone/.next/server/chunks/_15k37au70vjvg._.js +3 -0
  118. package/.next/standalone/.next/server/chunks/_18rfu4__wjhwb._.js +3 -0
  119. package/.next/standalone/.next/server/chunks/_19011-u44143j._.js +3 -0
  120. package/.next/standalone/.next/server/chunks/_1ek68lnh2daur._.js +33 -0
  121. package/.next/standalone/.next/server/chunks/_1fz8m31sndkcu._.js +3 -0
  122. package/.next/standalone/.next/server/chunks/_1ixl-kxq_ctsa._.js +3 -0
  123. package/.next/standalone/.next/server/chunks/_1ogwigfb0163w._.js +3 -0
  124. package/.next/standalone/.next/server/chunks/_1vslkoe35wok6._.js +3 -0
  125. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_audit_invite_route_actions_0-2n5sy.js → _next-internal_server_app_api_audit_invite_route_actions_0-2n5sycrn1ab.js} +1 -1
  126. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_audit_run_route_actions_1qgp9io.js → _next-internal_server_app_api_audit_run_route_actions_1qgp9iombfpdn.js} +1 -1
  127. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_audit_status_route_actions_1f7pjof.js → _next-internal_server_app_api_audit_status_route_actions_1f7pjofwh4n7b.js} +1 -1
  128. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_auth_login-request_route_actions_1c49co0.js → _next-internal_server_app_api_auth_login-request_route_actions_1c49co0x3-dl8.js} +1 -1
  129. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_auth_login-verify_route_actions_1r3slzk.js → _next-internal_server_app_api_auth_login-verify_route_actions_1r3slzk0v320p.js} +1 -1
  130. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_auth_logout_route_actions_0regwyr.js → _next-internal_server_app_api_auth_logout_route_actions_0regwyrnie28t.js} +1 -1
  131. package/.next/standalone/.next/server/chunks/{_next-internal_server_app_api_auth_status_route_actions_1aho9zu.js → _next-internal_server_app_api_auth_status_route_actions_1aho9zu4gx9_5.js} +1 -1
  132. package/.next/standalone/.next/server/chunks/lib_11qmqmccehybz._.js +3 -0
  133. package/.next/standalone/.next/server/chunks/lib_1sezqnatvr8j-._.js +3 -0
  134. package/.next/standalone/.next/server/chunks/lib_antigravity-projects_ts_0hdx6fkrln72c._.js +3 -0
  135. package/.next/standalone/.next/server/chunks/lib_antigravity-sessions_ts_0jayregp7h3h5._.js +3 -0
  136. package/.next/standalone/.next/server/chunks/lib_auth_api-server-client_ts_1r1w6kn8-org8._.js +3 -0
  137. package/.next/standalone/.next/server/chunks/lib_auth_auth-store_ts_03o40zz0emkkg._.js +3 -0
  138. package/.next/standalone/.next/server/chunks/lib_codex-projects_ts_0di6zenec7h7n._.js +3 -0
  139. package/.next/standalone/.next/server/chunks/lib_codex-sessions_ts_17znrhpys8lz9._.js +3 -0
  140. package/.next/standalone/.next/server/chunks/lib_copilot-projects_ts_00-tojoja20ke._.js +3 -0
  141. package/.next/standalone/.next/server/chunks/lib_copilot-sessions_ts_200_qjwcll3_i._.js +3 -0
  142. package/.next/standalone/.next/server/chunks/lib_cursor-projects_ts_1carno5mv3ix_._.js +3 -0
  143. package/.next/standalone/.next/server/chunks/lib_cursor-sessions_ts_1lq8fkhczl3_y._.js +3 -0
  144. package/.next/standalone/.next/server/chunks/lib_devin-sessions_ts_0kirblxnhsnmd._.js +3 -0
  145. package/.next/standalone/.next/server/chunks/lib_factory-projects_ts_1eo_bk-vm4wdz._.js +3 -0
  146. package/.next/standalone/.next/server/chunks/lib_factory-sessions_ts_0lwe8buimuthh._.js +3 -0
  147. package/.next/standalone/.next/server/chunks/lib_goose-sessions_ts_15jnf4alr5isl._.js +3 -0
  148. package/.next/standalone/.next/server/chunks/lib_hermes-profiles_ts_0jki1620x7wxh._.js +3 -0
  149. package/.next/standalone/.next/server/chunks/lib_hermes-projects_ts_0h9ny-woruqft._.js +3 -0
  150. package/.next/standalone/.next/server/chunks/lib_hermes-sessions_ts_1bo14h38efuti._.js +3 -0
  151. package/.next/standalone/.next/server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js +3 -0
  152. package/.next/standalone/.next/server/chunks/{lib_logger_ts_07e65t5._.js → lib_logger_ts_07e65t5sy13vi._.js} +1 -1
  153. package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0faqz9x._.js → lib_openclaw-db_ts_0nax8ld9h9ii8._.js} +5 -5
  154. package/.next/standalone/.next/server/chunks/lib_openclaw-projects_ts_0gc-p24z7gzy8._.js +3 -0
  155. package/.next/standalone/.next/server/chunks/lib_openclaw-sessions_ts_06lc8rgfj4huq._.js +3 -0
  156. package/.next/standalone/.next/server/chunks/lib_opencode-projects_ts_1r-bu98cz4660._.js +3 -0
  157. package/.next/standalone/.next/server/chunks/lib_opencode-sessions_ts_0fdxj6q_np7ll._.js +3 -0
  158. package/.next/standalone/.next/server/chunks/lib_pi-projects_ts_1_cy5lfxd21kv._.js +3 -0
  159. package/.next/standalone/.next/server/chunks/lib_pi-sessions_ts_09ha0x-gi38y1._.js +3 -0
  160. package/.next/standalone/.next/server/chunks/lib_projects_ts_01v279z8xccq4._.js +3 -0
  161. package/.next/standalone/.next/server/chunks/lib_telemetry-id_ts_1k8gj9ot530oy._.js +3 -0
  162. package/.next/standalone/.next/server/chunks/lib_telemetry_ts_0dctyyw_s81oo._.js +3 -0
  163. package/.next/standalone/.next/server/chunks/lib_telemetry_ts_1cx7iwiprqsm6._.js +3 -0
  164. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_01r25oigsgz07._.js +4 -0
  165. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_077n_4ip5__fu._.js +3 -0
  166. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_09z9-p77cu37y._.js +4 -0
  167. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0mqvvxcn6v0op._.js +3 -0
  168. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0pb7ds5g0vzgn._.js +3 -0
  169. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_1gasm5xkeqmm3._.js +3 -0
  170. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_1q1heqmkhh8l4._.js +3 -0
  171. package/.next/standalone/.next/server/chunks/{package_json_[json]_cjs_1nxcc4v._.js → package_json_[json]_cjs_1nxcc4vkpxxu7._.js} +2 -2
  172. package/.next/standalone/.next/server/chunks/src_hooks_1aveq0uhs2t1b._.js +5 -0
  173. package/.next/standalone/.next/server/chunks/src_hooks_1eem5a7cyqlb2._.js +3 -0
  174. package/.next/standalone/.next/server/chunks/src_hooks_custom-hooks-loader_ts_0lnb3n3h94wnn._.js +12 -0
  175. package/.next/standalone/.next/server/chunks/src_hooks_daemon-client_ts_0il_yu1zc0291._.js +3 -0
  176. package/.next/standalone/.next/server/chunks/src_hooks_fp-config_ts_0ow57t1myy6o_._.js +3 -0
  177. package/.next/standalone/.next/server/chunks/src_hooks_fp-home_ts_09kv0bn_4twyh._.js +3 -0
  178. package/.next/standalone/.next/server/chunks/ssr/{[externals]__0ilfh9m._.js → [externals]__0ilfh9mfnzsth._.js} +1 -1
  179. package/.next/standalone/.next/server/chunks/ssr/{[externals]__0ohnuzs._.js → [externals]__0ohnuzsaozaca._.js} +1 -1
  180. package/.next/standalone/.next/server/chunks/ssr/{[externals]__0vmspq5._.js → [externals]__12qr51qgrrt6o._.js} +2 -2
  181. package/.next/standalone/.next/server/chunks/ssr/[externals]_fs_promises_03norioyty3bq._.js +3 -0
  182. package/.next/standalone/.next/server/chunks/ssr/[externals]_node_net_1yam_zj43-40b._.js +3 -0
  183. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__075uro8t92s0_._.js +14 -0
  184. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0888k4s6spfmh._.js +3 -0
  185. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__08ch3staq3ejw._.js +3 -0
  186. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__08t6vt57mg_42._.js +3 -0
  187. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_bflu046ep5j._.js +3 -0
  188. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0bigvy9xmv2ka._.js +3 -0
  189. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0fdwgktjfhedo._.js +3 -0
  190. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0h1jw32uvrhh0._.js +3 -0
  191. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0h86bl2qf0k_o._.js +3 -0
  192. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0hvw4ifjuhdn7._.js +3 -0
  193. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0pia5h3p8re4c._.js +3 -0
  194. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0s4deza787asx._.js +3 -0
  195. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0vcyntk4snf0f._.js +3 -0
  196. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1-9s1nsw-5q8o._.js +3 -0
  197. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1-ey9fgesfbc0._.js +3 -0
  198. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__11ujqychsg_3_._.js +3 -0
  199. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__123o89o2a1ht0._.js +3 -0
  200. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__13whohpm024qr._.js +3 -0
  201. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__15bi9em2xe0x2._.js +3 -0
  202. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__15usvs-ms-0hf._.js +3 -0
  203. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__16gb3_92zvk5x._.js +3 -0
  204. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__18qe-hu0gwqm4._.js +3 -0
  205. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1_p_9xe520fex._.js +3 -0
  206. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1_xbg2kx30wp-._.js +3 -0
  207. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1avi2kypusyb_._.js +3 -0
  208. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1czstykkitjd8._.js +3 -0
  209. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1fmhm8_s9i4re._.js +3 -0
  210. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1g76awtnmimd1._.js +3 -0
  211. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1l1qgu5mfapkh._.js +3 -0
  212. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1ob2uzmms1adf._.js +3 -0
  213. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1pczevlpk5lxh._.js +3 -0
  214. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1r7drlqli-ado._.js +3 -0
  215. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1vxwetblyf8vp._.js +3 -0
  216. package/.next/standalone/.next/server/chunks/ssr/[turbopack]_runtime.js +146 -16
  217. package/.next/standalone/.next/server/chunks/ssr/_0-f9uotv7v2n9._.js +3 -0
  218. package/.next/standalone/.next/server/chunks/ssr/_00e4_rvim31u_._.js +3 -0
  219. package/.next/standalone/.next/server/chunks/ssr/_00qm74p9x8cwt._.js +3 -0
  220. package/.next/standalone/.next/server/chunks/ssr/_0bseae9u7g98r._.js +3 -0
  221. package/.next/standalone/.next/server/chunks/ssr/_0eoura3_9gjb-._.js +25 -0
  222. package/.next/standalone/.next/server/chunks/ssr/_0kqw2_f1ywmpo._.js +3 -0
  223. package/.next/standalone/.next/server/chunks/ssr/_0mouhaflye1ro._.js +3 -0
  224. package/.next/standalone/.next/server/chunks/ssr/_0pedwblqdoh58._.js +3 -0
  225. package/.next/standalone/.next/server/chunks/ssr/_0tfqha481f033._.js +4 -0
  226. package/.next/standalone/.next/server/chunks/ssr/_1_ozgifqv1ssi._.js +3 -0
  227. package/.next/standalone/.next/server/chunks/ssr/_1a516zcgtqius._.js +3 -0
  228. package/.next/standalone/.next/server/chunks/ssr/_1ddpc5gj57uuf._.js +3 -0
  229. package/.next/standalone/.next/server/chunks/ssr/_1djqs9i27e4kg._.js +3 -0
  230. package/.next/standalone/.next/server/chunks/ssr/_1ew6ra24vt-ij._.js +3 -0
  231. package/.next/standalone/.next/server/chunks/ssr/_1gb0ifpkowwub._.js +234 -0
  232. package/.next/standalone/.next/server/chunks/ssr/_1or8gixmrpv5i._.js +3 -0
  233. package/.next/standalone/.next/server/chunks/ssr/_1s8zk-upxzp00._.js +3 -0
  234. package/.next/standalone/.next/server/chunks/ssr/_1u9tpla2o6utw._.js +3 -0
  235. package/.next/standalone/.next/server/chunks/ssr/_1v4_ul3sj2lq_._.js +3 -0
  236. package/.next/standalone/.next/server/chunks/ssr/_1y3xzro8ca8t6._.js +3 -0
  237. package/.next/standalone/.next/server/chunks/ssr/_20hn4gn87nsjc._.js +3 -0
  238. package/.next/standalone/.next/server/chunks/ssr/_next-internal_server_app_policies_page_actions_1sp2-yo5_vm5f.js +17 -0
  239. package/.next/standalone/.next/server/chunks/ssr/app_087bt9wus25zs._.js +3 -0
  240. package/.next/standalone/.next/server/chunks/ssr/app_0trz6ik19xz5_._.js +3 -0
  241. package/.next/standalone/.next/server/chunks/ssr/app_1fvisnppn1unv._.js +3 -0
  242. package/.next/standalone/.next/server/chunks/ssr/app_209u41o446my6._.js +3 -0
  243. package/.next/standalone/.next/server/chunks/ssr/app_actions_get-scheduled-audit_ts_0ei9snixb5fd-._.js +3 -0
  244. package/.next/standalone/.next/server/chunks/ssr/app_audit_0hku_y73ischw._.js +3 -0
  245. package/.next/standalone/.next/server/chunks/ssr/{app_audit__components_audit-dashboard_tsx_0p9ud47._.js → app_audit__components_audit-dashboard_tsx_0p9ud47q0xq5w._.js} +3 -3
  246. package/.next/standalone/.next/server/chunks/ssr/{app_audit_loading_tsx_1j1kc6j._.js → app_audit_loading_tsx_1j1kc6j4v4-rl._.js} +1 -1
  247. package/.next/standalone/.next/server/chunks/ssr/app_components_project-list_tsx_1ke6anr0vt64h._.js +3 -0
  248. package/.next/standalone/.next/server/chunks/ssr/app_components_sessions-list_tsx_0gysftd_pn1m8._.js +3 -0
  249. package/.next/standalone/.next/server/chunks/ssr/app_error_tsx_15zfp7nrwf_b6._.js +3 -0
  250. package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_0w002m_ccu8zg._.js +3 -0
  251. package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_1kp6l3x33jqb6._.js +3 -0
  252. package/.next/standalone/.next/server/chunks/ssr/app_policies_hooks-client_tsx_19dqvpcz0uxur._.js +8 -0
  253. package/.next/standalone/.next/server/chunks/ssr/app_project_[name]_error_tsx_08qg6ncy93-17._.js +3 -0
  254. package/.next/standalone/.next/server/chunks/ssr/{app_project_[name]_loading_tsx_05-l4uf._.js → app_project_[name]_loading_tsx_05-l4uf5vgzpv._.js} +1 -1
  255. package/.next/standalone/.next/server/chunks/ssr/app_project_[name]_session_[sessionId]_error_tsx_0rf4j1nefwesi._.js +3 -0
  256. package/.next/standalone/.next/server/chunks/ssr/{app_project_[name]_session_[sessionId]_loading_tsx_0l4aixs._.js → app_project_[name]_session_[sessionId]_loading_tsx_0l4aixs89x_2g._.js} +1 -1
  257. package/.next/standalone/.next/server/chunks/ssr/{app_projects_loading_tsx_20-3u8b._.js → app_projects_loading_tsx_20-3u8bb2wqz2._.js} +1 -1
  258. package/.next/standalone/.next/server/chunks/ssr/app_settings_02tf1h47jmhhd._.js +3 -0
  259. package/.next/standalone/.next/server/chunks/ssr/lib_16jvhmthj_k3a._.js +3 -0
  260. package/.next/standalone/.next/server/chunks/ssr/lib_antigravity-projects_ts_0_6zf11xjo990._.js +3 -0
  261. package/.next/standalone/.next/server/chunks/ssr/lib_antigravity-sessions_ts_1xf7so6xrlevb._.js +3 -0
  262. package/.next/standalone/.next/server/chunks/ssr/lib_codex-projects_ts_0pqlw37q6qrb-._.js +3 -0
  263. package/.next/standalone/.next/server/chunks/ssr/lib_copilot-projects_ts_19wl7tpiv2zyg._.js +3 -0
  264. package/.next/standalone/.next/server/chunks/ssr/lib_cursor-projects_ts_18-iwyks4twze._.js +3 -0
  265. package/.next/standalone/.next/server/chunks/ssr/lib_devin-projects_ts_0a64qdyjacs0k._.js +3 -0
  266. package/.next/standalone/.next/server/chunks/ssr/lib_devin-sessions_ts_02u5rpzqjmxdw._.js +3 -0
  267. package/.next/standalone/.next/server/chunks/ssr/lib_factory-projects_ts_1uyaahq_zte1q._.js +3 -0
  268. package/.next/standalone/.next/server/chunks/ssr/lib_factory-sessions_ts_1tx9qelwapqun._.js +3 -0
  269. package/.next/standalone/.next/server/chunks/ssr/lib_format-duration_ts_09vnd_qdginp7._.js +3 -0
  270. package/.next/standalone/.next/server/chunks/ssr/lib_goose-projects_ts_0zkscrisyu15q._.js +3 -0
  271. package/.next/standalone/.next/server/chunks/ssr/lib_goose-sessions_ts_0-aebo0qkd1z9._.js +3 -0
  272. package/.next/standalone/.next/server/chunks/ssr/lib_hermes-profiles_ts_01q9fd6hz34il._.js +3 -0
  273. package/.next/standalone/.next/server/chunks/ssr/lib_hermes-projects_ts_05b8-itvkrig2._.js +3 -0
  274. package/.next/standalone/.next/server/chunks/ssr/lib_hermes-sessions_ts_076dzms3cnx9r._.js +3 -0
  275. package/.next/standalone/.next/server/chunks/ssr/lib_log-entries_ts_0vp7lm0yx4iba._.js +3 -0
  276. package/.next/standalone/.next/server/chunks/ssr/lib_openclaw-projects_ts_0qxq3bp7gsa2t._.js +3 -0
  277. package/.next/standalone/.next/server/chunks/ssr/lib_openclaw-sessions_ts_1f78qf2fle0uv._.js +22 -0
  278. package/.next/standalone/.next/server/chunks/ssr/lib_opencode-db_ts_18dv-h5ry0uo9._.js +3 -0
  279. package/.next/standalone/.next/server/chunks/ssr/lib_opencode-projects_ts_15bjxkmp2wls4._.js +3 -0
  280. package/.next/standalone/.next/server/chunks/ssr/lib_pi-projects_ts_1wikofbccx6w1._.js +3 -0
  281. package/.next/standalone/.next/server/chunks/ssr/lib_projects_ts_0f-jqrg5ftipx._.js +3 -0
  282. package/.next/standalone/.next/server/chunks/ssr/{lib_utils_ts_0az0sfq._.js → lib_utils_ts_0az0sfq5wo-3f._.js} +2 -2
  283. package/.next/standalone/.next/server/chunks/ssr/node_modules_05vgn62--7c5e._.js +3 -0
  284. package/.next/standalone/.next/server/chunks/ssr/node_modules_09s4n108bqreq._.js +3 -0
  285. package/.next/standalone/.next/server/chunks/ssr/node_modules_0dad4au22rq0p._.js +3 -0
  286. package/.next/standalone/.next/server/chunks/ssr/node_modules_0gxlxpuufujz9._.js +33 -0
  287. package/.next/standalone/.next/server/chunks/ssr/node_modules_html-to-image_es_index_15q9vt1a-slcq.js +3 -0
  288. package/.next/standalone/.next/server/chunks/ssr/{node_modules_html-to-image_es_index_1ao30b1.js → node_modules_html-to-image_es_index_1ao30b1e-jmzy.js} +2 -2
  289. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_0zuikgt2xho-v._.js +271 -0
  290. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_0janj0i6dqko7._.js +6 -0
  291. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_158jo-9mwvgad._.js +291 -0
  292. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_19r82zsxo2jj1._.js +291 -0
  293. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_1dupwucoqt5qm._.js +3 -0
  294. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_1et9oq9q9-y3v._.js +3 -0
  295. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_client_components_0wpq8j32_ibz4._.js +3 -0
  296. package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_client_components_builtin_forbidden_0symwr9.js → node_modules_next_dist_client_components_builtin_forbidden_0symwr9mbf-fh.js} +1 -1
  297. package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_client_components_builtin_unauthorized_0l_sp0x.js → node_modules_next_dist_client_components_builtin_unauthorized_0l_sp0xky89qu.js} +1 -1
  298. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_compiled_@edge-runtime_cookies_index_1kiz_an963mbg.js +3 -0
  299. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0-uvagv_giw2o.js +3 -0
  300. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_03c7gi5rntgf9.js +3 -0
  301. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_09p-8omsyjg4b.js +3 -0
  302. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0dwo94s84hht0.js +3 -0
  303. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0v-kfiu0qiy63.js +3 -0
  304. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0xrgzyzq__1k6.js +3 -0
  305. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_1806lsc28_bd0.js +3 -0
  306. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_1j6dd-erq474h.js +3 -0
  307. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_1sa65r-crehoe.js +3 -0
  308. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_shared_lib_03w27x2kh17_8._.js +23 -0
  309. package/.next/standalone/.next/server/chunks/ssr/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0dagmbznysrc2._.js +3 -0
  310. package/.next/standalone/.next/server/chunks/ssr/node_modules_posthog-node_dist_entrypoints_index_node_mjs_11bnuznb72p7z._.js +4 -0
  311. package/.next/standalone/.next/server/chunks/ssr/package_json_[json]_cjs_013tntikdft59._.js +3 -0
  312. package/.next/standalone/.next/server/chunks/ssr/src_audit_dashboard-cache_ts_1-v0y_pr_b4vx._.js +3 -0
  313. package/.next/standalone/.next/server/chunks/ssr/src_hooks_0-q0ummbuhlg5._.js +3 -0
  314. package/.next/standalone/.next/server/chunks/ssr/src_hooks_06kzv9ddabn3_._.js +12 -0
  315. package/.next/standalone/.next/server/chunks/ssr/src_hooks_0g194syq7r7ql._.js +3 -0
  316. package/.next/standalone/.next/server/chunks/ssr/src_hooks_1cv9_c4l1tzrm._.js +12 -0
  317. package/.next/standalone/.next/server/chunks/ssr/src_hooks_1kx9e0dx_1-8o._.js +3 -0
  318. package/.next/standalone/.next/server/chunks/ssr/src_hooks_daemon-client_ts_0k41_i7jg6ndv._.js +3 -0
  319. package/.next/standalone/.next/server/chunks/ssr/src_hooks_daemon-service_ts_0ibufora3s_bw._.js +3 -0
  320. package/.next/standalone/.next/server/chunks/ssr/src_hooks_effective-reviewers_ts_1h4wtvo55j16x._.js +5 -0
  321. package/.next/standalone/.next/server/chunks/ssr/src_hooks_fp-config_ts_04t589gp4p60j._.js +4 -0
  322. package/.next/standalone/.next/server/chunks/ssr/src_hooks_fp-home_ts_0je3xkv_2e7f7._.js +3 -0
  323. package/.next/standalone/.next/server/chunks/ssr/src_hooks_hook-activity-store_ts_178ewqzp9cvrg._.js +3 -0
  324. package/.next/standalone/.next/server/chunks/ssr/src_hooks_pack-cli_ts_0t7me658zqmh_._.js +3 -0
  325. package/.next/standalone/.next/server/chunks/ssr/src_hooks_semantic_pack-policies_ts_0gh_bu_3oswax._.js +3 -0
  326. package/.next/standalone/.next/server/instrumentation.js +1 -1
  327. package/.next/standalone/.next/server/middleware-build-manifest.js +109 -9
  328. package/.next/standalone/.next/server/middleware.js +2 -2
  329. package/.next/standalone/.next/server/pages/404.html +1 -1
  330. package/.next/standalone/.next/server/pages/500.html +1 -1
  331. package/.next/standalone/.next/server/preview-props.json +5 -0
  332. package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
  333. package/.next/standalone/.next/server/server-reference-manifest.json +54 -85
  334. package/.next/standalone/.next/static/chunks/08fodmjweitv-.js +6 -0
  335. package/.next/standalone/.next/static/chunks/0dr6b-sp478i9.js +1 -0
  336. package/.next/standalone/.next/static/chunks/0m-tv1y6ghhtk.js +1 -0
  337. package/.next/standalone/.next/static/chunks/0qeojb9uu_8_e.js +1 -0
  338. package/.next/standalone/.next/static/chunks/0zw6_ase89dfk.js +1 -0
  339. package/.next/standalone/.next/static/chunks/1024g0jaymm46.js +1 -0
  340. package/.next/standalone/.next/static/chunks/165ezyyx0j1ft.js +22 -0
  341. package/.next/standalone/.next/static/chunks/{1mylcr99gccyz.js → 1v1mi4-0ziecn.js} +2 -2
  342. package/.next/standalone/.next/static/chunks/{3_e_wg5_oay87.css → 26c4gmdpsthv6.css} +1 -1
  343. package/.next/standalone/.next/static/chunks/276ifklxc2-x4.js +1 -0
  344. package/.next/standalone/.next/static/chunks/281u-2vtn53n5.js +1 -0
  345. package/.next/standalone/.next/static/chunks/2_sj5ssr_m_wm.js +1 -0
  346. package/.next/standalone/.next/static/chunks/2cn0x2d6tyiuq.js +31 -0
  347. package/.next/standalone/.next/static/chunks/{34jpdb2xjm-x7.js → 2j5zpvs3pd7mw.js} +1 -1
  348. package/.next/standalone/.next/static/chunks/2l7j1dpmejuqn.js +1 -0
  349. package/.next/standalone/.next/static/chunks/2ojf3r8g4tn7s.js +1 -0
  350. package/.next/standalone/.next/static/chunks/2zyrjasvbmwpq.js +1 -0
  351. package/.next/standalone/.next/static/chunks/31fan-ze541d1.js +1 -0
  352. package/.next/standalone/.next/static/chunks/32s3y34p0t2pe.js +1 -0
  353. package/.next/standalone/.next/static/chunks/36re0fegaocq-.js +1 -0
  354. package/.next/standalone/.next/static/chunks/3fhk60ouw_ae6.js +1 -0
  355. package/.next/standalone/.next/static/chunks/3oin924a_3ohe.js +1 -0
  356. package/.next/standalone/.next/static/chunks/{3zkg2s2vzxc3d.js → 3vpfbqzaue6_i.js} +1 -1
  357. package/.next/standalone/.next/static/chunks/3xhybr6ywsmdf.js +1 -0
  358. package/.next/standalone/.next/static/chunks/turbopack-3-ry682tkyiqk.js +1 -0
  359. package/.next/standalone/fp-cloud-cli/uv.lock +6 -6
  360. package/.next/standalone/hermes-plugin/plugin.yaml +1 -1
  361. package/.next/standalone/node_modules/@next/env/package.json +1 -1
  362. package/.next/standalone/node_modules/next/dist/build/define-env.js +12 -18
  363. package/.next/standalone/node_modules/next/dist/build/next-config-ts/transpile-config.js +1 -5
  364. package/.next/standalone/node_modules/next/dist/build/nft.js +119 -0
  365. package/.next/standalone/node_modules/next/dist/build/segment-config/app/app-segment-config.js +19 -5
  366. package/.next/standalone/node_modules/next/dist/build/segment-config/app/app-segments.js +120 -29
  367. package/.next/standalone/node_modules/next/dist/build/segment-config/app/collect-root-param-keys.js +1 -5
  368. package/.next/standalone/node_modules/next/dist/build/static-paths/app/extract-pathname-route-param-segments-from-loader-tree.js +8 -2
  369. package/.next/standalone/node_modules/next/dist/build/static-paths/app.js +230 -133
  370. package/.next/standalone/node_modules/next/dist/build/static-paths/pages.js +8 -40
  371. package/.next/standalone/node_modules/next/dist/build/static-paths/param-matching.js +200 -0
  372. package/.next/standalone/node_modules/next/dist/build/swc/index.js +92 -162
  373. package/.next/standalone/node_modules/next/dist/build/utils.js +180 -90
  374. package/.next/standalone/node_modules/next/dist/cli/next-test.js +4 -0
  375. package/.next/standalone/node_modules/next/dist/client/app-call-server.js +16 -18
  376. package/.next/standalone/node_modules/next/dist/client/components/app-router-instance.js +43 -187
  377. package/.next/standalone/node_modules/next/dist/client/components/{segment-cache/navigation.js → app-router-state.js} +88 -334
  378. package/.next/standalone/node_modules/next/dist/client/components/app-router-utils.js +1 -5
  379. package/.next/standalone/node_modules/next/dist/client/components/app-router.js +83 -74
  380. package/.next/standalone/node_modules/next/dist/client/components/dev-root-http-access-fallback-boundary.js +1 -5
  381. package/.next/standalone/node_modules/next/dist/client/components/forbidden.js +2 -10
  382. package/.next/standalone/node_modules/next/dist/client/components/handle-isr-error.js +19 -4
  383. package/.next/standalone/node_modules/next/dist/client/components/instant-samples.js +4 -11
  384. package/.next/standalone/node_modules/next/dist/client/components/links.js +6 -7
  385. package/.next/standalone/node_modules/next/dist/client/components/navigation-dynamic-rendering.js +3 -3
  386. package/.next/standalone/node_modules/next/dist/client/components/navigation-untracked.js +1 -2
  387. package/.next/standalone/node_modules/next/dist/client/components/navigation.js +2 -6
  388. package/.next/standalone/node_modules/next/dist/client/components/navigation.react-server.js +1 -5
  389. package/.next/standalone/node_modules/next/dist/client/components/navigator.js +73 -0
  390. package/.next/standalone/node_modules/next/dist/client/components/not-found.js +1 -5
  391. package/.next/standalone/node_modules/next/dist/client/components/prefetch.js +83 -0
  392. package/.next/standalone/node_modules/next/dist/client/components/readonly-url-search-params.js +0 -5
  393. package/.next/standalone/node_modules/next/dist/client/components/redirect.js +3 -15
  394. package/.next/standalone/node_modules/next/dist/client/components/{router-reducer/ppr-navigations.js → render-tree.js} +365 -400
  395. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/compute-changed-path.js +13 -5
  396. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/create-initial-router-state.js +67 -54
  397. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/create-router-cache-key.js +1 -7
  398. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/create-segment-key.js +42 -0
  399. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/fetch-server-response.js +71 -50
  400. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/is-navigating-to-new-root-layout.js +4 -4
  401. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/hmr-refresh-reducer.js +2 -2
  402. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/navigate-reducer.js +5 -5
  403. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/refresh-reducer.js +11 -8
  404. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/restore-reducer.js +12 -9
  405. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/server-action-reducer.js +30 -29
  406. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/server-patch-reducer.js +5 -5
  407. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/router-reducer.js +2 -10
  408. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/bfcache.js +11 -21
  409. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/cache.js +1168 -1181
  410. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/decode-server-response.js +419 -0
  411. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/navigation-testing-lock.js +1 -1
  412. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/optimistic-routes.js +77 -82
  413. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/scheduler.js +464 -425
  414. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/types.js +12 -3
  415. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/vary-path.js +140 -126
  416. package/.next/standalone/node_modules/next/dist/client/components/sequential-router-queue.js +163 -0
  417. package/.next/standalone/node_modules/next/dist/client/components/unauthorized.js +2 -10
  418. package/.next/standalone/node_modules/next/dist/client/components/unstable-rethrow.js +1 -2
  419. package/.next/standalone/node_modules/next/dist/client/components/use-action-queue.js +2 -10
  420. package/.next/standalone/node_modules/next/dist/client/dev/debug-channel.js +6 -323
  421. package/.next/standalone/node_modules/next/dist/client/flight-data-helpers.js +41 -94
  422. package/.next/standalone/node_modules/next/dist/client/route-params.js +34 -12
  423. package/.next/standalone/node_modules/next/dist/client/sequential-call-server.js +45 -0
  424. package/.next/standalone/node_modules/next/dist/compiled/@mswjs/interceptors/ClientRequest/index.js +1 -1
  425. package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js +203 -59
  426. package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js +203 -59
  427. package/.next/standalone/node_modules/next/dist/compiled/next-server/app-route-turbo.runtime.prod.js +5 -3
  428. package/.next/standalone/node_modules/next/dist/compiled/next-server/pages-turbo.runtime.prod.js +13 -13
  429. package/.next/standalone/node_modules/next/dist/compiled/react-is/package.json +1 -1
  430. package/.next/standalone/node_modules/next/dist/compiled/stacktrace-parser/stack-trace-parser.cjs.js +1 -1
  431. package/.next/standalone/node_modules/next/dist/experimental/testmode/fetch.js +2 -10
  432. package/.next/standalone/node_modules/next/dist/export/helpers/create-incremental-cache.js +21 -16
  433. package/.next/standalone/node_modules/next/dist/export/utils.js +37 -0
  434. package/.next/standalone/node_modules/next/dist/lib/batcher.js +2 -2
  435. package/.next/standalone/node_modules/next/dist/lib/dist-dir.js +88 -0
  436. package/.next/standalone/node_modules/next/dist/lib/download-swc.js +2 -10
  437. package/.next/standalone/node_modules/next/dist/lib/fallback.js +3 -15
  438. package/.next/standalone/node_modules/next/dist/lib/find-pages-dir.js +2 -10
  439. package/.next/standalone/node_modules/next/dist/lib/helpers/get-cache-directory.js +1 -5
  440. package/.next/standalone/node_modules/next/dist/lib/helpers/get-npx-command.js +1 -1
  441. package/.next/standalone/node_modules/next/dist/lib/helpers/get-registry.js +1 -5
  442. package/.next/standalone/node_modules/next/dist/lib/helpers/git.js +52 -7
  443. package/.next/standalone/node_modules/next/dist/lib/inline-static-env.js +1 -5
  444. package/.next/standalone/node_modules/next/dist/lib/is-error.js +3 -15
  445. package/.next/standalone/node_modules/next/dist/lib/is-serializable-props.js +6 -35
  446. package/.next/standalone/node_modules/next/dist/lib/metadata/index.js +18 -0
  447. package/.next/standalone/node_modules/next/dist/lib/metadata/metadata-elements.js +1498 -0
  448. package/.next/standalone/node_modules/next/dist/lib/metadata/metadata-parallel.js +175 -0
  449. package/.next/standalone/node_modules/next/dist/lib/metadata/metadata-resolution-primitives.js +467 -0
  450. package/.next/standalone/node_modules/next/dist/lib/metadata/metadata.js +30 -1516
  451. package/.next/standalone/node_modules/next/dist/lib/metadata/resolve-metadata-parallel.js +632 -0
  452. package/.next/standalone/node_modules/next/dist/lib/metadata/resolve-metadata.js +15 -414
  453. package/.next/standalone/node_modules/next/dist/lib/mkcert.js +4 -20
  454. package/.next/standalone/node_modules/next/dist/lib/patch-incorrect-lockfile.js +4 -8
  455. package/.next/standalone/node_modules/next/dist/lib/picocolors.js +10 -0
  456. package/.next/standalone/node_modules/next/dist/lib/pretty-bytes.js +1 -5
  457. package/.next/standalone/node_modules/next/dist/lib/recursive-delete.js +50 -11
  458. package/.next/standalone/node_modules/next/dist/lib/resolve-build-paths.js +1 -5
  459. package/.next/standalone/node_modules/next/dist/lib/resolve-from.js +2 -10
  460. package/.next/standalone/node_modules/next/dist/lib/static-env.js +1 -5
  461. package/.next/standalone/node_modules/next/dist/lib/typescript/getTypeScriptConfiguration.js +3 -15
  462. package/.next/standalone/node_modules/next/dist/lib/typescript/missingDependencyError.js +1 -5
  463. package/.next/standalone/node_modules/next/dist/lib/typescript/runTypeCheck.js +1 -9
  464. package/.next/standalone/node_modules/next/dist/lib/typescript/runTypeCheckCli.js +0 -1
  465. package/.next/standalone/node_modules/next/dist/lib/typescript/runTypeScriptCli.js +4 -16
  466. package/.next/standalone/node_modules/next/dist/lib/verify-partytown-setup.js +1 -5
  467. package/.next/standalone/node_modules/next/dist/lib/warn-missing-react-dependencies.js +33 -0
  468. package/.next/standalone/node_modules/next/dist/lib/worker.js +1 -5
  469. package/.next/standalone/node_modules/next/dist/server/accept-header.js +3 -15
  470. package/.next/standalone/node_modules/next/dist/server/after/after-context.js +5 -25
  471. package/.next/standalone/node_modules/next/dist/server/after/after.js +1 -5
  472. package/.next/standalone/node_modules/next/dist/server/after/awaiter.js +1 -5
  473. package/.next/standalone/node_modules/next/dist/server/after/run-with-after.js +2 -2
  474. package/.next/standalone/node_modules/next/dist/server/api-utils/index.js +1 -10
  475. package/.next/standalone/node_modules/next/dist/server/api-utils/node/api-resolver.js +10 -50
  476. package/.next/standalone/node_modules/next/dist/server/api-utils/node/parse-body.js +3 -15
  477. package/.next/standalone/node_modules/next/dist/server/app-render/action-async-storage-instance.js +1 -1
  478. package/.next/standalone/node_modules/next/dist/server/app-render/action-handler.js +104 -141
  479. package/.next/standalone/node_modules/next/dist/server/app-render/after-task-async-storage-instance.js +1 -1
  480. package/.next/standalone/node_modules/next/dist/server/app-render/app-render-prerender-utils.js +6 -30
  481. package/.next/standalone/node_modules/next/dist/server/app-render/app-render-render-utils.js +1 -5
  482. package/.next/standalone/node_modules/next/dist/server/app-render/app-render-scheduling.js +3 -15
  483. package/.next/standalone/node_modules/next/dist/server/app-render/app-render.js +1346 -1211
  484. package/.next/standalone/node_modules/next/dist/server/app-render/async-local-storage.js +11 -6
  485. package/.next/standalone/node_modules/next/dist/server/app-render/blocking-route-messages.js +119 -70
  486. package/.next/standalone/node_modules/next/dist/server/app-render/cache-signal.js +61 -35
  487. package/.next/standalone/node_modules/next/dist/server/app-render/collect-segment-data.js +326 -260
  488. package/.next/standalone/node_modules/next/dist/server/app-render/console-async-storage-instance.js +1 -1
  489. package/.next/standalone/node_modules/next/dist/server/app-render/create-component-tree.js +136 -160
  490. package/.next/standalone/node_modules/next/dist/server/app-render/create-error-handler.js +12 -6
  491. package/.next/standalone/node_modules/next/dist/server/app-render/create-transport-tree-from-loader-tree.js +190 -0
  492. package/.next/standalone/node_modules/next/dist/server/app-render/debug-channel-server.web.js +1 -5
  493. package/.next/standalone/node_modules/next/dist/server/app-render/dev-validation-error-delivery.js +1 -10
  494. package/.next/standalone/node_modules/next/dist/server/app-render/dev-validation-scheduler.js +4 -5
  495. package/.next/standalone/node_modules/next/dist/server/app-render/dev-validation-worker-snapshot.js +3 -1
  496. package/.next/standalone/node_modules/next/dist/server/app-render/dynamic-access-async-storage-instance.js +1 -1
  497. package/.next/standalone/node_modules/next/dist/server/app-render/dynamic-access-async-storage.external.js +26 -3
  498. package/.next/standalone/node_modules/next/dist/server/app-render/dynamic-rendering-client.js +124 -0
  499. package/.next/standalone/node_modules/next/dist/server/app-render/dynamic-rendering.js +260 -329
  500. package/.next/standalone/node_modules/next/dist/server/app-render/encryption-utils.js +1 -5
  501. package/.next/standalone/node_modules/next/dist/server/app-render/encryption.js +4 -17
  502. package/.next/standalone/node_modules/next/dist/server/app-render/entry-base.js +1 -6
  503. package/.next/standalone/node_modules/next/dist/server/app-render/instant-validation/boundary-impl.js +3 -12
  504. package/.next/standalone/node_modules/next/dist/server/app-render/instant-validation/boundary-tracking.js +2 -2
  505. package/.next/standalone/node_modules/next/dist/server/app-render/instant-validation/instant-config.js +4 -12
  506. package/.next/standalone/node_modules/next/dist/server/app-render/instant-validation/instant-samples.js +13 -62
  507. package/.next/standalone/node_modules/next/dist/server/app-render/instant-validation/instant-validation.js +145 -206
  508. package/.next/standalone/node_modules/next/dist/server/app-render/instant-validation/stream-utils.js +2 -10
  509. package/.next/standalone/node_modules/next/dist/server/app-render/manifests-singleton.js +110 -38
  510. package/.next/standalone/node_modules/next/dist/server/app-render/module-loading/track-dynamic-import.js +2 -10
  511. package/.next/standalone/node_modules/next/dist/server/app-render/module-loading/track-module-loading.instance.js +1 -1
  512. package/.next/standalone/node_modules/next/dist/server/app-render/parse-and-validate-flight-router-state.js +3 -15
  513. package/.next/standalone/node_modules/next/dist/server/app-render/postponed-state.js +87 -51
  514. package/.next/standalone/node_modules/next/dist/server/app-render/prospective-render-utils.js +2 -6
  515. package/.next/standalone/node_modules/next/dist/server/app-render/render-in-browser.js +27 -0
  516. package/.next/standalone/node_modules/next/dist/server/app-render/required-scripts.js +1 -5
  517. package/.next/standalone/node_modules/next/dist/server/app-render/rsc/taint.js +1 -5
  518. package/.next/standalone/node_modules/next/dist/server/app-render/segment-config/ensure-static.js +206 -0
  519. package/.next/standalone/node_modules/next/dist/server/app-render/staged-rendering.js +46 -54
  520. package/.next/standalone/node_modules/next/dist/server/app-render/stream-ops.node.js +18 -12
  521. package/.next/standalone/node_modules/next/dist/server/app-render/stream-ops.web.js +4 -20
  522. package/.next/standalone/node_modules/next/dist/server/app-render/sync-io-messages.js +2 -10
  523. package/.next/standalone/node_modules/next/dist/server/app-render/types.js +2 -1
  524. package/.next/standalone/node_modules/next/dist/server/app-render/use-flight-response.js +4 -17
  525. package/.next/standalone/node_modules/next/dist/server/app-render/vary-params.js +12 -11
  526. package/.next/standalone/node_modules/next/dist/server/app-render/walk-tree-with-flight-router-state.js +95 -97
  527. package/.next/standalone/node_modules/next/dist/server/app-render/work-async-storage-instance.js +1 -1
  528. package/.next/standalone/node_modules/next/dist/server/app-render/work-unit-async-storage-instance.js +1 -1
  529. package/.next/standalone/node_modules/next/dist/server/app-render/work-unit-async-storage.external.js +36 -26
  530. package/.next/standalone/node_modules/next/dist/server/async-storage/draft-mode-provider.js +1 -5
  531. package/.next/standalone/node_modules/next/dist/server/async-storage/request-store.js +6 -5
  532. package/.next/standalone/node_modules/next/dist/server/async-storage/work-store.js +24 -26
  533. package/.next/standalone/node_modules/next/dist/server/base-http/node.js +1 -5
  534. package/.next/standalone/node_modules/next/dist/server/base-http/web.js +4 -12
  535. package/.next/standalone/node_modules/next/dist/server/base-server.js +346 -155
  536. package/.next/standalone/node_modules/next/dist/server/client-component-renderer-logger.js +129 -28
  537. package/.next/standalone/node_modules/next/dist/server/config-schema.js +61 -9
  538. package/.next/standalone/node_modules/next/dist/server/config-shared.js +26 -4
  539. package/.next/standalone/node_modules/next/dist/server/config.js +154 -332
  540. package/.next/standalone/node_modules/next/dist/server/dev/debug-channel.js +1 -5
  541. package/.next/standalone/node_modules/next/dist/server/dev/dev-validation-worker-pool.js +1 -0
  542. package/.next/standalone/node_modules/next/dist/server/dev/get-source-map-from-file.js +5 -25
  543. package/.next/standalone/node_modules/next/dist/server/dev/hot-middleware.js +27 -1
  544. package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-turbopack.js +338 -200
  545. package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-types.js +3 -0
  546. package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-webpack.js +26 -20
  547. package/.next/standalone/node_modules/next/dist/server/dev/messages.js +2 -10
  548. package/.next/standalone/node_modules/next/dist/server/dev/middleware-turbopack.js +4 -20
  549. package/.next/standalone/node_modules/next/dist/server/dev/middleware-webpack.js +2 -10
  550. package/.next/standalone/node_modules/next/dist/server/dev/node-stack-frames.js +2 -19
  551. package/.next/standalone/node_modules/next/dist/server/dev/on-demand-entry-handler.js +12 -12
  552. package/.next/standalone/node_modules/next/dist/server/dev/runtime-error-state.js +220 -0
  553. package/.next/standalone/node_modules/next/dist/server/dev/serialized-errors.js +1 -5
  554. package/.next/standalone/node_modules/next/dist/server/dev/static-paths-worker.js +16 -15
  555. package/.next/standalone/node_modules/next/dist/server/dev/turbopack-utils.js +20 -36
  556. package/.next/standalone/node_modules/next/dist/server/dev/use-cache-probe-pool.js +1 -0
  557. package/.next/standalone/node_modules/next/dist/server/dev/use-cache-probe-worker.js +4 -3
  558. package/.next/standalone/node_modules/next/dist/server/dynamic-rendering-utils.js +298 -55
  559. package/.next/standalone/node_modules/next/dist/server/image-optimizer/detect-content-type.js +229 -0
  560. package/.next/standalone/node_modules/next/dist/server/image-optimizer/extract-etag.js +53 -0
  561. package/.next/standalone/node_modules/next/dist/server/image-optimizer/get-image-size.js +25 -0
  562. package/.next/standalone/node_modules/next/dist/server/image-optimizer/get-max-age.js +41 -0
  563. package/.next/standalone/node_modules/next/dist/server/image-optimizer/get-previously-cached-image-or-null.js +22 -0
  564. package/.next/standalone/node_modules/next/dist/server/image-optimizer/image-error.js +23 -0
  565. package/.next/standalone/node_modules/next/dist/server/image-optimizer/image-type.js +86 -0
  566. package/.next/standalone/node_modules/next/dist/server/image-optimizer/transform.js +227 -0
  567. package/.next/standalone/node_modules/next/dist/server/image-optimizer.js +78 -674
  568. package/.next/standalone/node_modules/next/dist/server/lib/app-info-log.js +19 -9
  569. package/.next/standalone/node_modules/next/dist/server/lib/cache-handlers/default.js +9 -13
  570. package/.next/standalone/node_modules/next/dist/server/lib/chrome-devtools-workspace.js +1 -5
  571. package/.next/standalone/node_modules/next/dist/server/lib/dedupe-fetch.js +1 -5
  572. package/.next/standalone/node_modules/next/dist/server/lib/dev-bundler-service.js +6 -6
  573. package/.next/standalone/node_modules/next/dist/server/lib/generate-agent-files.js +158 -35
  574. package/.next/standalone/node_modules/next/dist/server/lib/i18n-provider.js +1 -5
  575. package/.next/standalone/node_modules/next/dist/server/lib/incremental-cache/file-system-cache.js +14 -20
  576. package/.next/standalone/node_modules/next/dist/server/lib/incremental-cache/index.js +19 -29
  577. package/.next/standalone/node_modules/next/dist/server/lib/incremental-cache/memory-cache.external.js +1 -5
  578. package/.next/standalone/node_modules/next/dist/server/lib/lazy-module.js +1 -5
  579. package/.next/standalone/node_modules/next/dist/server/lib/lru-cache.js +1 -5
  580. package/.next/standalone/node_modules/next/dist/server/lib/mock-request.js +24 -120
  581. package/.next/standalone/node_modules/next/dist/server/lib/module-loader/node-module-loader.js +1 -5
  582. package/.next/standalone/node_modules/next/dist/server/lib/module-loader/route-module-loader.js +1 -5
  583. package/.next/standalone/node_modules/next/dist/server/lib/params-utils.js +0 -18
  584. package/.next/standalone/node_modules/next/dist/server/lib/patch-fetch.js +44 -38
  585. package/.next/standalone/node_modules/next/dist/server/lib/postponed-request-body.js +1 -5
  586. package/.next/standalone/node_modules/next/dist/server/lib/render-server.js +2 -10
  587. package/.next/standalone/node_modules/next/dist/server/lib/router-server.js +106 -36
  588. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/build-data-route.js +26 -3
  589. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/cache-life-type-utils.js +14 -45
  590. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/decode-path-params.js +1 -5
  591. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/filesystem.js +212 -31
  592. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/instrumentation-globals.external.js +61 -1
  593. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/instrumentation-node-extensions.js +1 -5
  594. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/normalize-catchall-routes.js +320 -0
  595. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/proxy-request.js +2 -2
  596. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/resolve-routes.js +17 -11
  597. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/strict-route-matching-config.js +28 -0
  598. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/typegen.js +56 -10
  599. package/.next/standalone/node_modules/next/dist/server/lib/start-server.js +48 -38
  600. package/.next/standalone/node_modules/next/dist/server/lib/trace/constants.js +40 -0
  601. package/.next/standalone/node_modules/next/dist/server/lib/trace/request-insights-identity.js +1 -3
  602. package/.next/standalone/node_modules/next/dist/server/lib/trace/tracer.js +10 -10
  603. package/.next/standalone/node_modules/next/dist/server/lib/utils.js +66 -15
  604. package/.next/standalone/node_modules/next/dist/server/lib/worker-utils.js +1 -5
  605. package/.next/standalone/node_modules/next/dist/server/load-components.js +7 -2
  606. package/.next/standalone/node_modules/next/dist/server/load-manifest.external.js +16 -17
  607. package/.next/standalone/node_modules/next/dist/server/mcp/tools/utils/browser-communication.js +2 -10
  608. package/.next/standalone/node_modules/next/dist/server/mcp/tools/utils/format-errors.js +5 -5
  609. package/.next/standalone/node_modules/next/dist/server/next-server.js +130 -124
  610. package/.next/standalone/node_modules/next/dist/server/next.js +25 -37
  611. package/.next/standalone/node_modules/next/dist/server/node-environment-extensions/console-dim.external.js +1 -2
  612. package/.next/standalone/node_modules/next/dist/server/node-environment-extensions/fast-set-immediate.external.js +115 -62
  613. package/.next/standalone/node_modules/next/dist/server/node-environment-extensions/global-behaviors.js +1 -5
  614. package/.next/standalone/node_modules/next/dist/server/node-environment-extensions/io-utils.js +11 -10
  615. package/.next/standalone/node_modules/next/dist/server/node-environment-extensions/process-error-handlers.js +0 -9
  616. package/.next/standalone/node_modules/next/dist/server/node-environment-extensions/unhandled-rejection.external.js +1 -12
  617. package/.next/standalone/node_modules/next/dist/server/normalizers/built/app/app-page-normalizer.js +1 -1
  618. package/.next/standalone/node_modules/next/dist/server/normalizers/request/base-path.js +1 -5
  619. package/.next/standalone/node_modules/next/dist/server/normalizers/request/next-data.js +1 -5
  620. package/.next/standalone/node_modules/next/dist/server/normalizers/request/prefix.js +1 -5
  621. package/.next/standalone/node_modules/next/dist/server/og/cache-image-response.js +2 -7
  622. package/.next/standalone/node_modules/next/dist/server/patch-error-inspect.js +19 -11
  623. package/.next/standalone/node_modules/next/dist/server/pipe-readable.js +42 -30
  624. package/.next/standalone/node_modules/next/dist/server/render-result.js +5 -17
  625. package/.next/standalone/node_modules/next/dist/server/render.js +37 -183
  626. package/.next/standalone/node_modules/next/dist/server/request/cache-stages.js +250 -0
  627. package/.next/standalone/node_modules/next/dist/server/request/connection.js +9 -40
  628. package/.next/standalone/node_modules/next/dist/server/request/cookies.js +11 -46
  629. package/.next/standalone/node_modules/next/dist/server/request/draft-mode.js +14 -60
  630. package/.next/standalone/node_modules/next/dist/server/request/fallback-params.js +23 -9
  631. package/.next/standalone/node_modules/next/dist/server/request/headers.js +10 -44
  632. package/.next/standalone/node_modules/next/dist/server/request/io.js +2 -11
  633. package/.next/standalone/node_modules/next/dist/server/request/params.js +62 -196
  634. package/.next/standalone/node_modules/next/dist/server/request/pathname.js +9 -61
  635. package/.next/standalone/node_modules/next/dist/server/request/root-params.js +25 -81
  636. package/.next/standalone/node_modules/next/dist/server/request/search-params.js +42 -119
  637. package/.next/standalone/node_modules/next/dist/server/request/utils.js +3 -10
  638. package/.next/standalone/node_modules/next/dist/server/response-cache/index.js +54 -32
  639. package/.next/standalone/node_modules/next/dist/server/response-cache/utils.js +1 -5
  640. package/.next/standalone/node_modules/next/dist/server/response-cache/web.js +5 -2
  641. package/.next/standalone/node_modules/next/dist/server/resume-data-cache/cache-store.js +18 -0
  642. package/.next/standalone/node_modules/next/dist/server/resume-data-cache/resume-data-cache.js +51 -49
  643. package/.next/standalone/node_modules/next/dist/server/revalidation-utils.js +15 -13
  644. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/dev-render-context.js +23 -0
  645. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/helpers/prerender-manifest-matcher.js +5 -4
  646. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/module.js +13 -1
  647. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/module.render.js +26 -11
  648. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/parse-request-headers.js +58 -0
  649. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/vendored/rsc/entrypoints.js +1 -5
  650. package/.next/standalone/node_modules/next/dist/server/route-modules/app-page/vendored/ssr/entrypoints.js +1 -5
  651. package/.next/standalone/node_modules/next/dist/server/route-modules/app-route/helpers/auto-implement-methods.js +1 -5
  652. package/.next/standalone/node_modules/next/dist/server/route-modules/app-route/module.js +399 -432
  653. package/.next/standalone/node_modules/next/dist/server/route-modules/pages/module.render.js +1 -5
  654. package/.next/standalone/node_modules/next/dist/server/route-modules/pages/pages-handler.js +20 -16
  655. package/.next/standalone/node_modules/next/dist/server/route-modules/pages-api/module.js +1 -5
  656. package/.next/standalone/node_modules/next/dist/server/route-modules/route-module.js +57 -61
  657. package/.next/standalone/node_modules/next/dist/server/serve-static.js +1 -5
  658. package/.next/standalone/node_modules/next/dist/server/setup-http-agent-env.js +1 -5
  659. package/.next/standalone/node_modules/next/dist/server/stream-utils/encoded-tags.js +1 -1
  660. package/.next/standalone/node_modules/next/dist/server/stream-utils/node-web-streams-helper.js +7 -11
  661. package/.next/standalone/node_modules/next/dist/server/typescript/constant.js +2 -0
  662. package/.next/standalone/node_modules/next/dist/server/typescript/rules/config.js +29 -2
  663. package/.next/standalone/node_modules/next/dist/server/use-cache/cache-life-profile.js +6 -30
  664. package/.next/standalone/node_modules/next/dist/server/use-cache/cache-life.js +9 -32
  665. package/.next/standalone/node_modules/next/dist/server/use-cache/cache-tag.js +6 -12
  666. package/.next/standalone/node_modules/next/dist/server/use-cache/constants.js +1 -5
  667. package/.next/standalone/node_modules/next/dist/server/use-cache/handlers.js +27 -36
  668. package/.next/standalone/node_modules/next/dist/server/use-cache/tiered-cache-handler.js +6 -4
  669. package/.next/standalone/node_modules/next/dist/server/use-cache/use-cache-errors.js +18 -19
  670. package/.next/standalone/node_modules/next/dist/server/use-cache/use-cache-messages.js +190 -0
  671. package/.next/standalone/node_modules/next/dist/server/use-cache/use-cache-wrapper.js +485 -407
  672. package/.next/standalone/node_modules/next/dist/server/web/adapter.js +14 -35
  673. package/.next/standalone/node_modules/next/dist/server/web/edge-route-module-wrapper.js +6 -7
  674. package/.next/standalone/node_modules/next/dist/server/web/error.js +0 -15
  675. package/.next/standalone/node_modules/next/dist/server/web/globals.js +3 -15
  676. package/.next/standalone/node_modules/next/dist/server/web/next-url.js +1 -5
  677. package/.next/standalone/node_modules/next/dist/server/web/sandbox/context.js +10 -34
  678. package/.next/standalone/node_modules/next/dist/server/web/sandbox/sandbox.js +1 -5
  679. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/adapters/headers.js +0 -5
  680. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/adapters/next-request.js +1 -5
  681. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/adapters/request-cookies.js +0 -5
  682. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/fetch-event.js +2 -10
  683. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/image-response.js +1 -5
  684. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/response.js +2 -10
  685. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/revalidate.js +28 -66
  686. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/unstable-cache.js +14 -22
  687. package/.next/standalone/node_modules/next/dist/server/web/spec-extension/unstable-no-store.js +1 -2
  688. package/.next/standalone/node_modules/next/dist/server/web/utils.js +1 -5
  689. package/.next/standalone/node_modules/next/dist/server/web/web-on-close.js +2 -10
  690. package/.next/standalone/node_modules/next/dist/shared/lib/app-router-types.js +38 -28
  691. package/.next/standalone/node_modules/next/dist/shared/lib/constants.js +5 -0
  692. package/.next/standalone/node_modules/next/dist/shared/lib/deployment-id.js +1 -1
  693. package/.next/standalone/node_modules/next/dist/shared/lib/errors/code-frame.js +3 -2
  694. package/.next/standalone/node_modules/next/dist/shared/lib/errors/empty-generate-static-params-error.js +1 -5
  695. package/.next/standalone/node_modules/next/dist/shared/lib/errors/ensure-static-gsp-errors.js +30 -0
  696. package/.next/standalone/node_modules/next/dist/shared/lib/errors/hard-deprecated-config-error.js +0 -5
  697. package/.next/standalone/node_modules/next/dist/shared/lib/html-context.shared-runtime.js +1 -5
  698. package/.next/standalone/node_modules/next/dist/shared/lib/image-config.js +52 -1
  699. package/.next/standalone/node_modules/next/dist/shared/lib/instant-messages.js +2 -10
  700. package/.next/standalone/node_modules/next/dist/shared/lib/invariant-error.js +0 -5
  701. package/.next/standalone/node_modules/next/dist/shared/lib/lazy-dynamic/react-browser-bailout.js +45 -0
  702. package/.next/standalone/node_modules/next/dist/shared/lib/magic-identifier.js +198 -0
  703. package/.next/standalone/node_modules/next/dist/shared/lib/match-remote-pattern.js +1 -5
  704. package/.next/standalone/node_modules/next/dist/shared/lib/router/routes/app.js +3 -15
  705. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/app-paths.js +6 -1
  706. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/get-dynamic-param.js +4 -12
  707. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/interception-routes.js +63 -20
  708. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js +1 -5
  709. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/prepare-destination.js +1 -5
  710. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/querystring.js +31 -0
  711. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/resolve-param-value.js +1 -5
  712. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/route-matcher.js +1 -5
  713. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/sorted-routes.js +11 -55
  714. package/.next/standalone/node_modules/next/dist/shared/lib/rsc-transport.js +108 -0
  715. package/.next/standalone/node_modules/next/dist/shared/lib/segment-cache/segment-value-encoding.js +0 -13
  716. package/.next/standalone/node_modules/next/dist/shared/lib/segment-cache/vary-params-decoding.js +48 -27
  717. package/.next/standalone/node_modules/next/dist/shared/lib/segment.js +1 -13
  718. package/.next/standalone/node_modules/next/dist/shared/lib/turbopack/internal-error.js +2 -7
  719. package/.next/standalone/node_modules/next/dist/shared/lib/utils.js +2 -11
  720. package/.next/standalone/node_modules/next/dist/shared/lib/zod.js +2 -6
  721. package/.next/standalone/node_modules/next/dist/telemetry/anonymous-meta.js +1 -1
  722. package/.next/standalone/node_modules/next/dist/telemetry/detached-flush.js +8 -15
  723. package/.next/standalone/node_modules/next/dist/telemetry/events/build.js +1 -2
  724. package/.next/standalone/node_modules/next/dist/telemetry/events/swc-load-failure.js +1 -1
  725. package/.next/standalone/node_modules/next/dist/telemetry/events/version.js +2 -2
  726. package/.next/standalone/node_modules/next/dist/telemetry/post-telemetry-payload.js +1 -5
  727. package/.next/standalone/node_modules/next/dist/telemetry/storage.js +31 -19
  728. package/.next/standalone/node_modules/next/dist/trace/report/index.js +5 -2
  729. package/.next/standalone/node_modules/next/dist/trace/report/to-json-build.js +4 -2
  730. package/.next/standalone/node_modules/next/dist/trace/report/to-json.js +141 -97
  731. package/.next/standalone/node_modules/next/dist/trace/trace.js +14 -9
  732. package/.next/standalone/node_modules/next/package.json +11 -10
  733. package/.next/standalone/package.json +11 -11
  734. package/.next/standalone/sdk/python/uv.lock +30 -115
  735. package/.next/standalone/sdk/typescript/CHANGELOG.md +11 -0
  736. package/.next/standalone/sdk/typescript/integration/fixtures/mastra-1/package-lock.json +16 -4
  737. package/.next/standalone/sdk/typescript/integration/fixtures/mastra-1/package.json +3 -0
  738. package/.next/standalone/server.js +1 -1
  739. package/bin/failproofai.mjs +2 -2
  740. package/dist/cli.mjs +27125 -26785
  741. package/dist/worker.mjs +117 -111
  742. package/hermes-plugin/plugin.yaml +1 -1
  743. package/package.json +11 -11
  744. package/scripts/skew-log-filter.ts +5 -1
  745. package/src/hooks/cloud-connection.ts +86 -17
  746. package/src/hooks/cloud-enrollment.ts +4 -3
  747. package/src/hooks/cloud-managed-policies.ts +15 -11
  748. package/src/hooks/codex-system-hooks.ts +687 -0
  749. package/src/hooks/collector-config.ts +5 -4
  750. package/src/hooks/config-status.ts +47 -114
  751. package/src/hooks/configure-wizard.ts +55 -65
  752. package/src/hooks/credential-recovery.ts +36 -0
  753. package/src/hooks/daemon-service.ts +2 -2
  754. package/src/hooks/delivery-health.ts +20 -9
  755. package/src/hooks/fp-config.ts +17 -5
  756. package/src/hooks/fp-home.ts +1 -1
  757. package/src/hooks/integrations.ts +16 -0
  758. package/src/hooks/manager.ts +62 -2
  759. package/src/hooks/otel-cli.ts +51 -20
  760. package/src/hooks/otel-writers.ts +26 -17
  761. package/src/hooks/uninstall-cli.ts +28 -7
  762. package/.next/standalone/.next/server/chunks/[externals]__1_9ze9b._.js +0 -3
  763. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0--lkk6._.js +0 -3
  764. package/.next/standalone/.next/server/chunks/[root-of-the-server]__03r-lqq._.js +0 -3
  765. package/.next/standalone/.next/server/chunks/[root-of-the-server]__08dchfu._.js +0 -3
  766. package/.next/standalone/.next/server/chunks/[root-of-the-server]__08w4wmd._.js +0 -3
  767. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0_0xu5z._.js +0 -3
  768. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0f7mikp._.js +0 -3
  769. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0g6bbuw._.js +0 -3
  770. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0ga9hs7._.js +0 -3
  771. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0l3yhx4._.js +0 -160
  772. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0moxohc._.js +0 -22
  773. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0o07qi9._.js +0 -3
  774. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0q-v9z2._.js +0 -3
  775. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0q0qzx1._.js +0 -3
  776. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0rv7m0k._.js +0 -3
  777. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0z2ll-a._.js +0 -3
  778. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0zlqo2t._.js +0 -3
  779. package/.next/standalone/.next/server/chunks/[root-of-the-server]__12021ot._.js +0 -3
  780. package/.next/standalone/.next/server/chunks/[root-of-the-server]__17g9wh7._.js +0 -3
  781. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1adacul._.js +0 -165
  782. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1anxb5k._.js +0 -3
  783. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1autwno._.js +0 -3
  784. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1ffkmds._.js +0 -3
  785. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1jm9fw6._.js +0 -3
  786. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1l71g3y._.js +0 -22
  787. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1legmza._.js +0 -3
  788. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1ou2ehh._.js +0 -3
  789. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1qb590j._.js +0 -3
  790. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1shcqgr._.js +0 -3
  791. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1v25n-6._.js +0 -3
  792. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1w9zl9-._.js +0 -3
  793. package/.next/standalone/.next/server/chunks/[root-of-the-server]__1xuedea._.js +0 -3
  794. package/.next/standalone/.next/server/chunks/_09dz7xv._.js +0 -27
  795. package/.next/standalone/.next/server/chunks/_0p53ge1._.js +0 -3
  796. package/.next/standalone/.next/server/chunks/_0tovk6q._.js +0 -3
  797. package/.next/standalone/.next/server/chunks/_0trp3yc._.js +0 -3
  798. package/.next/standalone/.next/server/chunks/_1ek68ln._.js +0 -33
  799. package/.next/standalone/.next/server/chunks/_1fz8m31._.js +0 -3
  800. package/.next/standalone/.next/server/chunks/_1jrv3hg._.js +0 -3
  801. package/.next/standalone/.next/server/chunks/_1nx8fim._.js +0 -3
  802. package/.next/standalone/.next/server/chunks/_1ogwigf._.js +0 -3
  803. package/.next/standalone/.next/server/chunks/_1q27azx._.js +0 -3
  804. package/.next/standalone/.next/server/chunks/_1vslkoe._.js +0 -3
  805. package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_download_[project]_[session]_route_actions_1is7vs7.js +0 -3
  806. package/.next/standalone/.next/server/chunks/lib_16xa545._.js +0 -3
  807. package/.next/standalone/.next/server/chunks/lib_factory-projects_ts_1eo_bk-._.js +0 -3
  808. package/.next/standalone/.next/server/chunks/lib_openclaw-projects_ts_0gc-p24._.js +0 -3
  809. package/.next/standalone/.next/server/chunks/lib_telemetry-id_ts_1k8gj9o._.js +0 -3
  810. package/.next/standalone/.next/server/chunks/lib_telemetry_ts_0dctyyw._.js +0 -3
  811. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_01r25oi._.js +0 -4
  812. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_09z9-p7._.js +0 -4
  813. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0ol5pa3._.js +0 -3
  814. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_1rqmk27._.js +0 -3
  815. package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_1w7tiq4._.js +0 -3
  816. package/.next/standalone/.next/server/chunks/src_hooks_1aveq0u._.js +0 -5
  817. package/.next/standalone/.next/server/chunks/src_hooks_1eem5a7._.js +0 -3
  818. package/.next/standalone/.next/server/chunks/src_hooks_custom-hooks-loader_ts_0lnb3n3._.js +0 -12
  819. package/.next/standalone/.next/server/chunks/src_hooks_fp-home_ts_09kv0bn._.js +0 -3
  820. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__04usis8._.js +0 -4
  821. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0502lat._.js +0 -3
  822. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0576iuy._.js +0 -3
  823. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__059yza8._.js +0 -3
  824. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__05r_17v._.js +0 -3
  825. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__06pflha._.js +0 -3
  826. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_gn5iz._.js +0 -4
  827. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0e2l3c1._.js +0 -3
  828. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0eip4_k._.js +0 -22
  829. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0er05u0._.js +0 -3
  830. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0f765xr._.js +0 -4
  831. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0h38gzz._.js +0 -3
  832. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0hci7t3._.js +0 -3
  833. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0hoaz1g._.js +0 -4
  834. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0mxmwtx._.js +0 -3
  835. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0p84xee._.js +0 -3
  836. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0qcb0mg._.js +0 -3
  837. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0sjzdjg._.js +0 -3
  838. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0uescqv._.js +0 -3
  839. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__13d-wb6._.js +0 -3
  840. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1484zv2._.js +0 -3
  841. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__19dutr7._.js +0 -14
  842. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1_qv8oh._.js +0 -3
  843. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1ab4ifb._.js +0 -3
  844. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1b2dbet._.js +0 -33
  845. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1dinjii._.js +0 -3
  846. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1fbrk56._.js +0 -4
  847. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1kaotix._.js +0 -22
  848. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1pprgri._.js +0 -4
  849. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1py795m._.js +0 -3
  850. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1qapotl._.js +0 -3
  851. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1qiz0e4._.js +0 -3
  852. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1um4yxn._.js +0 -4
  853. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1v185mo._.js +0 -3
  854. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1wb4yt2._.js +0 -4
  855. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1y3n3cn._.js +0 -4
  856. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1zl_r0t._.js +0 -3
  857. package/.next/standalone/.next/server/chunks/ssr/_0-yi74u._.js +0 -3
  858. package/.next/standalone/.next/server/chunks/ssr/_08x1r5t._.js +0 -3
  859. package/.next/standalone/.next/server/chunks/ssr/_0bqoto4._.js +0 -3
  860. package/.next/standalone/.next/server/chunks/ssr/_0lnpwk8._.js +0 -23
  861. package/.next/standalone/.next/server/chunks/ssr/_0uyu3jf._.js +0 -3
  862. package/.next/standalone/.next/server/chunks/ssr/_0wso5d3._.js +0 -3
  863. package/.next/standalone/.next/server/chunks/ssr/_1-3unkg._.js +0 -3
  864. package/.next/standalone/.next/server/chunks/ssr/_15y8myg._.js +0 -3
  865. package/.next/standalone/.next/server/chunks/ssr/_1_ozgif._.js +0 -3
  866. package/.next/standalone/.next/server/chunks/ssr/_1ddpc5g._.js +0 -3
  867. package/.next/standalone/.next/server/chunks/ssr/_1gb0ifp._.js +0 -232
  868. package/.next/standalone/.next/server/chunks/ssr/_1o95rf0._.js +0 -3
  869. package/.next/standalone/.next/server/chunks/ssr/_1q46vxx._.js +0 -22
  870. package/.next/standalone/.next/server/chunks/ssr/_1thr5rf._.js +0 -3
  871. package/.next/standalone/.next/server/chunks/ssr/_1y3xzro._.js +0 -3
  872. package/.next/standalone/.next/server/chunks/ssr/_1ylae7o._.js +0 -3
  873. package/.next/standalone/.next/server/chunks/ssr/_next-internal_server_app_policies_page_actions_1sp2-yo.js +0 -16
  874. package/.next/standalone/.next/server/chunks/ssr/app_087bt9w._.js +0 -3
  875. package/.next/standalone/.next/server/chunks/ssr/app_1fvisnp._.js +0 -3
  876. package/.next/standalone/.next/server/chunks/ssr/app_209u41o._.js +0 -3
  877. package/.next/standalone/.next/server/chunks/ssr/app_actions_get-scheduled-audit_ts_0ei9sni._.js +0 -3
  878. package/.next/standalone/.next/server/chunks/ssr/app_components_project-list_tsx_1ke6anr._.js +0 -3
  879. package/.next/standalone/.next/server/chunks/ssr/app_error_tsx_15zfp7n._.js +0 -3
  880. package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_0w002m_._.js +0 -3
  881. package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_1kp6l3x._.js +0 -3
  882. package/.next/standalone/.next/server/chunks/ssr/app_policies_hooks-client_tsx_19dqvpc._.js +0 -8
  883. package/.next/standalone/.next/server/chunks/ssr/app_project_[name]_error_tsx_08qg6nc._.js +0 -3
  884. package/.next/standalone/.next/server/chunks/ssr/app_project_[name]_session_[sessionId]_error_tsx_0rf4j1n._.js +0 -3
  885. package/.next/standalone/.next/server/chunks/ssr/app_settings_02tf1h4._.js +0 -3
  886. package/.next/standalone/.next/server/chunks/ssr/lib_1cf5ya2._.js +0 -3
  887. package/.next/standalone/.next/server/chunks/ssr/lib_antigravity-projects_ts_0_6zf11._.js +0 -3
  888. package/.next/standalone/.next/server/chunks/ssr/lib_codex-projects_ts_0pqlw37._.js +0 -3
  889. package/.next/standalone/.next/server/chunks/ssr/lib_copilot-projects_ts_19wl7tp._.js +0 -3
  890. package/.next/standalone/.next/server/chunks/ssr/lib_cursor-projects_ts_18-iwyk._.js +0 -3
  891. package/.next/standalone/.next/server/chunks/ssr/lib_devin-projects_ts_0a64qdy._.js +0 -3
  892. package/.next/standalone/.next/server/chunks/ssr/lib_factory-projects_ts_1uyaahq._.js +0 -3
  893. package/.next/standalone/.next/server/chunks/ssr/lib_goose-projects_ts_0zkscri._.js +0 -3
  894. package/.next/standalone/.next/server/chunks/ssr/lib_hermes-projects_ts_05b8-it._.js +0 -3
  895. package/.next/standalone/.next/server/chunks/ssr/lib_openclaw-projects_ts_0qxq3bp._.js +0 -3
  896. package/.next/standalone/.next/server/chunks/ssr/lib_opencode-projects_ts_15bjxkm._.js +0 -3
  897. package/.next/standalone/.next/server/chunks/ssr/lib_pi-projects_ts_1wikofb._.js +0 -3
  898. package/.next/standalone/.next/server/chunks/ssr/node_modules_1hl81y4._.js +0 -3
  899. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_0aiy-os._.js +0 -131
  900. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_0nkkbfv._.js +0 -6
  901. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_0w6mzq5._.js +0 -151
  902. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_18_d8l1._.js +0 -151
  903. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_1v8aef8._.js +0 -3
  904. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_client_components_0wpq8j3._.js +0 -3
  905. package/.next/standalone/.next/server/chunks/ssr/node_modules_posthog-node_dist_entrypoints_index_node_mjs_11bnuzn._.js +0 -4
  906. package/.next/standalone/.next/server/chunks/ssr/src_hooks_0-q0umm._.js +0 -3
  907. package/.next/standalone/.next/server/chunks/ssr/src_hooks_06kzv9d._.js +0 -12
  908. package/.next/standalone/.next/server/chunks/ssr/src_hooks_0g194sy._.js +0 -3
  909. package/.next/standalone/.next/server/chunks/ssr/src_hooks_1cv9_c4._.js +0 -12
  910. package/.next/standalone/.next/server/chunks/ssr/src_hooks_1kx9e0d._.js +0 -3
  911. package/.next/standalone/.next/server/chunks/ssr/src_hooks_effective-reviewers_ts_1h4wtvo._.js +0 -5
  912. package/.next/standalone/.next/server/chunks/ssr/src_hooks_fp-config_ts_04t589g._.js +0 -4
  913. package/.next/standalone/.next/server/chunks/ssr/src_hooks_fp-home_ts_0je3xkv._.js +0 -3
  914. package/.next/standalone/.next/server/chunks/ssr/src_hooks_pack-cli_ts_0t7me65._.js +0 -3
  915. package/.next/standalone/.next/server/chunks/ssr/src_hooks_semantic_pack-policies_ts_0gh_bu_._.js +0 -3
  916. package/.next/standalone/.next/static/chunks/0pra9i676pym1.js +0 -1
  917. package/.next/standalone/.next/static/chunks/1-lpi0m-hc1kb.js +0 -1
  918. package/.next/standalone/.next/static/chunks/17yvyyblr_eb5.js +0 -1
  919. package/.next/standalone/.next/static/chunks/1c6aptmytnu6q.js +0 -1
  920. package/.next/standalone/.next/static/chunks/1eyl7fzkmnkf_.js +0 -1
  921. package/.next/standalone/.next/static/chunks/1wozchtn2etvh.js +0 -1
  922. package/.next/standalone/.next/static/chunks/1xacnwjkbekn7.js +0 -1
  923. package/.next/standalone/.next/static/chunks/23thtelz1a-ur.js +0 -6
  924. package/.next/standalone/.next/static/chunks/2bc17tohgs4bs.js +0 -1
  925. package/.next/standalone/.next/static/chunks/2hg_bp8z_vm2g.js +0 -1
  926. package/.next/standalone/.next/static/chunks/2xq-ejo8kti18.js +0 -1
  927. package/.next/standalone/.next/static/chunks/2yuzx8716maf0.js +0 -1
  928. package/.next/standalone/.next/static/chunks/3-_pth_c9n938.js +0 -1
  929. package/.next/standalone/.next/static/chunks/35fgpd_feci6x.js +0 -1
  930. package/.next/standalone/.next/static/chunks/3n46e45atic-m.js +0 -22
  931. package/.next/standalone/.next/static/chunks/3q7sndqftqhw9.js +0 -1
  932. package/.next/standalone/.next/static/chunks/3qfoeqhy5l10x.js +0 -1
  933. package/.next/standalone/.next/static/chunks/3sg07wnn969xq.js +0 -31
  934. package/.next/standalone/.next/static/chunks/3xpjn3cdgm-7m.js +0 -1
  935. package/.next/standalone/.next/static/chunks/4448_qq7bd963.js +0 -1
  936. package/.next/standalone/.next/static/chunks/turbopack-1opxka4dtjbc5.js +0 -1
  937. package/.next/standalone/node_modules/next/dist/client/components/match-segments.js +0 -32
  938. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/reducers/find-head-in-cache.js +0 -63
  939. package/.next/standalone/node_modules/next/dist/client/components/segment-cache/prefetch.js +0 -32
  940. package/.next/standalone/node_modules/next/dist/lib/detached-promise.js +0 -32
  941. package/.next/standalone/node_modules/next/dist/lib/error-telemetry-utils.js +0 -42
  942. package/.next/standalone/node_modules/next/dist/server/app-render/create-flight-router-state-from-loader-tree.js +0 -154
  943. package/.next/standalone/node_modules/next/dist/server/app-render/rsc/postpone.js +0 -18
  944. package/.next/standalone/node_modules/next/dist/server/lib/experimental/ppr.js +0 -47
  945. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/is-postpone.js +0 -16
  946. package/.next/standalone/node_modules/next/dist/server/route-matcher-managers/default-route-matcher-manager.js +0 -239
  947. package/.next/standalone/node_modules/next/dist/server/route-matcher-managers/dev-route-matcher-manager.js +0 -120
  948. package/.next/standalone/node_modules/next/dist/server/route-matcher-managers/route-matcher-manager.js +0 -6
  949. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/app-page-route-matcher-provider.js +0 -55
  950. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/app-route-route-matcher-provider.js +0 -43
  951. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/dev-app-page-route-matcher-provider.js +0 -91
  952. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/dev-app-route-route-matcher-provider.js +0 -112
  953. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/dev-pages-api-route-matcher-provider.js +0 -77
  954. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/dev-pages-route-matcher-provider.js +0 -77
  955. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/file-cache-route-matcher-provider.js +0 -28
  956. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/helpers/file-reader/batched-file-reader.js +0 -106
  957. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/helpers/file-reader/default-file-reader.js +0 -42
  958. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/dev/helpers/file-reader/file-reader.js +0 -6
  959. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/helpers/cached-route-matcher-provider.js +0 -30
  960. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/helpers/manifest-loaders/manifest-loader.js +0 -6
  961. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/helpers/manifest-loaders/node-manifest-loader.js +0 -34
  962. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/helpers/manifest-loaders/server-manifest-loader.js +0 -20
  963. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/manifest-route-matcher-provider.js +0 -21
  964. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/pages-api-route-matcher-provider.js +0 -55
  965. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/pages-route-matcher-provider.js +0 -64
  966. package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/route-matcher-provider.js +0 -6
  967. package/.next/standalone/node_modules/next/dist/server/route-matchers/app-page-route-matcher.js +0 -18
  968. package/.next/standalone/node_modules/next/dist/server/route-matchers/app-route-route-matcher.js +0 -15
  969. package/.next/standalone/node_modules/next/dist/server/route-matchers/locale-route-matcher.js +0 -68
  970. package/.next/standalone/node_modules/next/dist/server/route-matchers/pages-api-route-matcher.js +0 -30
  971. package/.next/standalone/node_modules/next/dist/server/route-matchers/pages-route-matcher.js +0 -30
  972. package/.next/standalone/node_modules/next/dist/server/route-matchers/route-matcher.js +0 -54
  973. /package/.next/standalone/.next/static/{xtcpqBNBdjQVerPMkI2HI → RrRjb2981tB2X7pKdNBUm}/_buildManifest.js +0 -0
  974. /package/.next/standalone/.next/static/{xtcpqBNBdjQVerPMkI2HI → RrRjb2981tB2X7pKdNBUm}/_clientMiddlewareManifest.js +0 -0
  975. /package/.next/standalone/.next/static/{xtcpqBNBdjQVerPMkI2HI → RrRjb2981tB2X7pKdNBUm}/_ssgManifest.js +0 -0
@@ -5,12 +5,12 @@ Object.defineProperty(exports, "__esModule", {
5
5
  0 && (module.exports = {
6
6
  cancelPrefetchTask: null,
7
7
  isPrefetchTaskDirty: null,
8
+ needsSpeculativePrefetch: null,
8
9
  pingPrefetchScheduler: null,
9
10
  pingPrefetchTask: null,
10
11
  reschedulePrefetchTask: null,
11
12
  schedulePrefetchTask: null,
12
- startRevalidationCooldown: null,
13
- subtreeHasSpeculativePrefetch: null
13
+ startRevalidationCooldown: null
14
14
  });
15
15
  function _export(target, all) {
16
16
  for(var name in all)Object.defineProperty(target, name, {
@@ -25,6 +25,9 @@ _export(exports, {
25
25
  isPrefetchTaskDirty: function() {
26
26
  return isPrefetchTaskDirty;
27
27
  },
28
+ needsSpeculativePrefetch: function() {
29
+ return needsSpeculativePrefetch;
30
+ },
28
31
  pingPrefetchScheduler: function() {
29
32
  return pingPrefetchScheduler;
30
33
  },
@@ -39,18 +42,13 @@ _export(exports, {
39
42
  },
40
43
  startRevalidationCooldown: function() {
41
44
  return startRevalidationCooldown;
42
- },
43
- subtreeHasSpeculativePrefetch: function() {
44
- return subtreeHasSpeculativePrefetch;
45
45
  }
46
46
  });
47
+ const _varypath = require("./vary-path");
47
48
  const _approutertypes = require("../../../shared/lib/app-router-types");
48
- const _matchsegments = require("../match-segments");
49
49
  const _cache = require("./cache");
50
50
  const _cachekey = require("./cache-key");
51
- const _routeparams = require("../../route-params");
52
51
  const _types = require("./types");
53
- const _segment = require("../../../shared/lib/segment");
54
52
  const _lru = require("./lru");
55
53
  const scheduleMicrotask = typeof queueMicrotask === 'function' ? queueMicrotask : (fn)=>Promise.resolve().then(fn).catch((error)=>setTimeout(()=>{
56
54
  throw error;
@@ -81,7 +79,7 @@ function startRevalidationCooldown() {
81
79
  pingPrefetchScheduler();
82
80
  }, REVALIDATION_COOLDOWN_MS);
83
81
  }
84
- function schedulePrefetchTask(key, treeAtTimeOfPrefetch, fetchStrategy, priority, onInvalidate, navigationLockPrefetch) {
82
+ function schedulePrefetchTask(key, renderTreeAtTimeOfPrefetch, fetchStrategy, priority, onInvalidate, navigationLockPrefetch) {
85
83
  // Bind the task to the segment cache map that is active right now: the
86
84
  // shared map, unless the Instant Navigation Testing lock is held, in which
87
85
  // case the task gets the lock scope's private map. This is the single
@@ -98,7 +96,7 @@ function schedulePrefetchTask(key, treeAtTimeOfPrefetch, fetchStrategy, priority
98
96
  // Spawn a new prefetch task
99
97
  const task = {
100
98
  key,
101
- treeAtTimeOfPrefetch,
99
+ renderTreeAtTimeOfPrefetch,
102
100
  routeCacheVersion: (0, _cache.getCurrentRouteCacheVersion)(),
103
101
  segmentCacheVersion: (0, _cache.getCurrentSegmentCacheVersion)(),
104
102
  segmentCacheMap: taskSegmentCacheMap,
@@ -140,7 +138,7 @@ function cancelPrefetchTask(task) {
140
138
  // bails (settling its status to Rejected), so there's nothing to clean up here.
141
139
  heapDelete(taskHeap, task);
142
140
  }
143
- function reschedulePrefetchTask(task, treeAtTimeOfPrefetch, fetchStrategy, priority) {
141
+ function reschedulePrefetchTask(task, renderTreeAtTimeOfPrefetch, fetchStrategy, priority) {
144
142
  // Bump the prefetch task to the top of the queue, as if it were a fresh
145
143
  // task. This is essentially the same as canceling the task and scheduling
146
144
  // a new one, except it reuses the original object.
@@ -160,7 +158,7 @@ function reschedulePrefetchTask(task, treeAtTimeOfPrefetch, fetchStrategy, prior
160
158
  task.priority = // If this task is the most recently hovered link, maintain its
161
159
  // Intent priority, even if the rescheduled priority is lower.
162
160
  task === mostRecentlyHoveredLink ? _types.PrefetchPriority.Intent : priority;
163
- task.treeAtTimeOfPrefetch = treeAtTimeOfPrefetch;
161
+ task.renderTreeAtTimeOfPrefetch = renderTreeAtTimeOfPrefetch;
164
162
  task.fetchStrategy = fetchStrategy;
165
163
  trackMostRecentlyHoveredLink(task);
166
164
  if (task._heapIndex !== -1) {
@@ -171,13 +169,13 @@ function reschedulePrefetchTask(task, treeAtTimeOfPrefetch, fetchStrategy, prior
171
169
  }
172
170
  pingPrefetchScheduler();
173
171
  }
174
- function isPrefetchTaskDirty(task, nextUrl, tree) {
172
+ function isPrefetchTaskDirty(task, nextUrl, root) {
175
173
  // This is used to quickly bail out of a prefetch task if the result is
176
174
  // guaranteed to not have changed since the task was initiated. This is
177
175
  // strictly an optimization — theoretically, if it always returned true, no
178
176
  // behavior should change because a full prefetch task will effectively
179
177
  // perform the same checks.
180
- return task.routeCacheVersion !== (0, _cache.getCurrentRouteCacheVersion)() || task.segmentCacheVersion !== (0, _cache.getCurrentSegmentCacheVersion)() || task.treeAtTimeOfPrefetch !== tree || task.key.nextUrl !== nextUrl;
178
+ return task.routeCacheVersion !== (0, _cache.getCurrentRouteCacheVersion)() || task.segmentCacheVersion !== (0, _cache.getCurrentSegmentCacheVersion)() || task.renderTreeAtTimeOfPrefetch !== root || task.key.nextUrl !== nextUrl;
181
179
  }
182
180
  function trackMostRecentlyHoveredLink(task) {
183
181
  // Track the mostly recently hovered link, i.e. the most recently scheduled
@@ -321,15 +319,14 @@ function processQueueInMicrotask() {
321
319
  // Finished prefetching the route tree. The two-phase (Shell then
322
320
  // Speculative) flow only applies to routes that have opted into
323
321
  // Partial Prefetching — either globally via the `partialPrefetching`
324
- // config or per segment (`prefetch: 'partial'` or
325
- // `'unstable_eager'`), all surfaced as the
322
+ // config or per segment (`prefetch: 'partial'`), both surfaced as the
326
323
  // `SubtreeHasPartialPrefetching` hint on the route tree. Every other
327
324
  // route skips the Shell phase and goes straight to Speculative.
328
325
  //
329
326
  // The route entry is fulfilled at this point (the RouteTree phase
330
327
  // just completed), so its prefetch hints are available.
331
328
  const route = (0, _cache.readRouteCacheEntry)(now, task.key);
332
- const routeHasPartialPrefetching = route !== null && route.status === _cache.EntryStatus.Fulfilled && (route.tree.prefetchHints & _approutertypes.PrefetchHint.SubtreeHasPartialPrefetching) !== 0;
329
+ const routeHasPartialPrefetching = route !== null && route.status === _cache.EntryStatus.Fulfilled && (route.root.tree.prefetchHints & _approutertypes.PrefetchHint.SubtreeHasPartialPrefetching) !== 0;
333
330
  task.phase = routeHasPartialPrefetching ? 1 : 0;
334
331
  heapResift(taskHeap, task);
335
332
  } else if (task.phase === 1) {
@@ -433,7 +430,7 @@ function pingRoute(now, task) {
433
430
  {
434
431
  if (background(task)) {
435
432
  routeWithoutSearch.status = _cache.EntryStatus.Pending;
436
- spawnPrefetchSubtask((0, _cache.fetchRouteOnCacheMiss)(routeWithoutSearch, keyWithoutSearch, task.segmentCacheMap));
433
+ spawnPrefetchSubtask((0, _cache.fetchRouteOnCacheMiss)(routeWithoutSearch, keyWithoutSearch));
437
434
  }
438
435
  break;
439
436
  }
@@ -472,7 +469,7 @@ function pingRootRouteTree(now, task, route) {
472
469
  // behavior if PPR is disabled for a route (via the incremental opt-in).
473
470
  //
474
471
  // Those cases will be handled here.
475
- spawnPrefetchSubtask((0, _cache.fetchRouteOnCacheMiss)(route, task.key, task.segmentCacheMap));
472
+ spawnPrefetchSubtask((0, _cache.fetchRouteOnCacheMiss)(route, task.key));
476
473
  // If the request takes longer than a minute, a subsequent request should
477
474
  // retry instead of waiting for this one. When the response is received,
478
475
  // this value will be replaced by a new value based on the stale time sent
@@ -515,7 +512,7 @@ function pingRootRouteTree(now, task, route) {
515
512
  // Stop prefetching segments until there's more bandwidth.
516
513
  return 0;
517
514
  }
518
- const tree = route.tree;
515
+ const tree = route.root.tree;
519
516
  // A task's fetch strategy gets set to `PPR` for any "auto" prefetch.
520
517
  // If it turned out that the route isn't PPR-enabled, we need to use `LoadingBoundary` instead.
521
518
  // We don't need to do this for runtime prefetches, because those are only available in
@@ -553,51 +550,64 @@ function pingRootRouteTree(now, task, route) {
553
550
  // do another pass to perform a runtime prefetch.
554
551
  // Derive the static walk's parameters once per pass; the walk
555
552
  // functions below receive them as arguments and are phase-agnostic.
556
- // During the Shell phase the walk targets the App Shell variant of
557
- // each segment (keyed at the shell vary paths); otherwise it's the
558
- // ordinary per-segment static strategy. This is the only place the
559
- // phase is consulted — everything below keys off the strategy.
553
+ // During the Shell phase the walk requests each segment's
554
+ // shell-stage variant (keyed at the shell vary paths); otherwise
555
+ // it's the ordinary per-segment static strategy. This is the only
556
+ // place the phase is consulted — everything below keys off
557
+ // the strategy.
560
558
  const staticWalkStrategy = task.phase === 1 ? _types.FetchStrategy.StaticShell : _types.FetchStrategy.PPR;
561
- if (staticWalkStrategy === _types.FetchStrategy.PPR && !subtreeHasSpeculativePrefetch(task.fetchStrategy, tree.prefetchHints)) {
562
- // Nothing in the target route needs to be speculatively prefetched.
563
- // Bail out. (A PPR walk is the Speculative pass; same check as
564
- // the per-subtree bail in pingNewPartOfCacheComponentsTree.)
559
+ // In PPF, links may skip speculative prefetching if they only need a shell.
560
+ if (staticWalkStrategy === _types.FetchStrategy.PPR && !needsSpeculativePrefetch(task.fetchStrategy, route.root.tree.prefetchHints)) {
565
561
  return 2;
566
562
  }
567
- pingStaticHead(now, task, route, staticWalkStrategy);
568
- const exitStatus = pingSharedPartOfCacheComponentsTree(now, task, route, task.treeAtTimeOfPrefetch, tree, null, staticWalkStrategy);
563
+ // The head is a one-node tree beside the route tree (see
564
+ // createMetadataRouteTree in cache.ts); it takes the same walk as
565
+ // a segment the current page doesn't have. If the head was inlined
566
+ // into a page's bundle (HeadOutlined is NOT set on the root), skip
567
+ // the standalone walk — the head data will arrive as part of that
568
+ // page's response, and its runtime-completeness signal is carried
569
+ // by that page's own entries.
570
+ const head = route.root.head;
571
+ if (!process.env.__NEXT_PREFETCH_INLINING || (route.root.tree.prefetchHints & _approutertypes.PrefetchHint.HeadOutlined) !== 0 || // An inlined head that can't attempt a static fetch still deopts
572
+ // to the runtime request (the first check of the decision point
573
+ // in pingSegmentInCacheComponentsTree); only the static fetch
574
+ // itself is skipped for an inlined head.
575
+ walkCanUseRuntimeRequests(staticWalkStrategy, route) && !shouldSegmentAttemptStaticRequest(staticWalkStrategy, head)) {
576
+ const headExitStatus = pingNewPartOfCacheComponentsTree(now, task, route, head, null, staticWalkStrategy);
577
+ if (headExitStatus === 0) {
578
+ return 0;
579
+ }
580
+ }
581
+ const exitStatus = pingSharedPartOfCacheComponentsTree(now, task, route, task.renderTreeAtTimeOfPrefetch.tree, tree, null, staticWalkStrategy);
569
582
  if (exitStatus === 0) {
570
583
  // Child yielded without finishing.
571
584
  return 0;
572
585
  }
573
- // We may need to do a runtime prefetch for one or more segments.
574
- // Before checking, we can do some fast checks to bail out of this
575
- // branch early.
576
- //
577
- // Runtime prefetches are only issued for walks that require runtime
578
- // completeness — the same per-pass predicate that produced the
579
- // deopt registrations during the traversal above; see the decision
580
- // point in pingNewPartOfCacheComponentsTree. Which segments
581
- // actually need a runtime request — registered directly, or only
582
- // as the fallback after an insufficient static attempt — was
583
- // decided there.
584
- if (walkRequiresRuntimeCompleteness(staticWalkStrategy, route)) {
586
+ // `pingSegmentInCacheComponentsTree` may have determined that
587
+ // we need to do a runtime prefetch for one or more segments.
588
+ // Bail out early if runtime prefetches are not permitted for this route.
589
+ if (walkCanUseRuntimeRequests(staticWalkStrategy, route)) {
585
590
  const runtimeStrategy = staticWalkStrategy === _types.FetchStrategy.StaticShell ? _types.FetchStrategy.RuntimeShell : _types.FetchStrategy.PPRRuntime;
586
591
  // spawnedRuntimePrefetches was populated during the traversal
587
592
  // above: every subtree in the new part of the tree that needs a
588
- // runtime prefetch — plus, during the Shell phase, the head, if
589
- // its static attempt was insufficient (see above).
593
+ // runtime prefetch, the head included — it registers under its
594
+ // own request key, like any segment, when its own static attempt
595
+ // was insufficient or never happened.
590
596
  //
591
597
  // If it's null, nothing in the new part of the tree is a candidate
592
598
  // for runtime prefetching, and we don't fetch the head, either —
593
- // the head is runtime prefetched only if one of the segments is.
599
+ // the head is runtime prefetched only if something is.
594
600
  const spawnedRuntimePrefetches = task.spawnedRuntimePrefetches;
595
601
  if (spawnedRuntimePrefetches !== null) {
596
602
  const spawnedEntries = new Map();
597
- pingRuntimeHead(now, task, route, spawnedEntries, runtimeStrategy);
603
+ // The head has no position in the request tree — a runtime
604
+ // response carries it beside the segments (see
605
+ // writeServerResponseIntoCache in cache.ts) — so the head's
606
+ // own request tree is discarded.
607
+ pingRouteTreeAndIncludeDynamicData(now, task, route, head, false, spawnedEntries, runtimeStrategy);
598
608
  const requestTree = pingRuntimePrefetches(now, task, route, tree, spawnedRuntimePrefetches, spawnedEntries, runtimeStrategy);
599
609
  if (spawnedEntries.size > 0) {
600
- spawnPrefetchSubtask((0, _cache.fetchSegmentPrefetchesUsingDynamicRequest)(task, route, runtimeStrategy, requestTree, spawnedEntries));
610
+ spawnPrefetchSubtask((0, _cache.fetchSegmentPrefetchesUsingRuntimeRequest)(task, route, runtimeStrategy, requestTree, spawnedEntries));
601
611
  }
602
612
  }
603
613
  }
@@ -613,7 +623,7 @@ function pingRootRouteTree(now, task, route) {
613
623
  // and fall through to Speculative.
614
624
  return 2;
615
625
  }
616
- // Prefetch multiple segments using a single dynamic request.
626
+ // Prefetch multiple segments using a single runtime request.
617
627
  // TODO: We can consolidate this branch with previous one by modeling
618
628
  // it as if the first segment in the new tree has runtime prefetching
619
629
  // enabled. Will do this as a follow-up refactor. Might want to remove
@@ -621,11 +631,18 @@ function pingRootRouteTree(now, task, route) {
621
631
  // really that much duplication, just would be nice to remove one of
622
632
  // these codepaths.
623
633
  const spawnedEntries = new Map();
624
- pingRuntimeHead(now, task, route, spawnedEntries, fetchStrategy);
625
- const dynamicRequestTree = diffRouteTreeAgainstCurrent(now, task, route, task.treeAtTimeOfPrefetch, tree, spawnedEntries, fetchStrategy);
634
+ // The head has no position in the request tree — a runtime response
635
+ // carries it beside the segments (see writeServerResponseIntoCache
636
+ // in cache.ts) — so the head's own request tree is discarded.
637
+ const head = route.root.head;
638
+ pingRouteTreeAndIncludeDynamicData(now, task, route, head, false, spawnedEntries, // When prefetching the head, there's no difference between Full
639
+ // and LoadingBoundary: the head has no loading boundary, so a
640
+ // LoadingBoundary request would skip it.
641
+ fetchStrategy === _types.FetchStrategy.LoadingBoundary ? _types.FetchStrategy.Full : fetchStrategy);
642
+ const dynamicRequestTree = diffRouteTreeAgainstCurrent(now, task, route, task.renderTreeAtTimeOfPrefetch.tree, tree, spawnedEntries, fetchStrategy);
626
643
  let needsDynamicRequest = spawnedEntries.size > 0;
627
644
  if (needsDynamicRequest) {
628
- spawnPrefetchSubtask((0, _cache.fetchSegmentPrefetchesUsingDynamicRequest)(task, route, fetchStrategy, dynamicRequestTree, spawnedEntries));
645
+ spawnPrefetchSubtask((0, _cache.fetchSegmentPrefetchesUsingRuntimeRequest)(task, route, fetchStrategy, dynamicRequestTree, spawnedEntries));
629
646
  }
630
647
  return 2;
631
648
  }
@@ -642,99 +659,53 @@ function pingRootRouteTree(now, task, route) {
642
659
  return 2;
643
660
  }
644
661
  /**
645
- * Prefetches the Head data for a page (metadata, viewport). The Head is not
646
- * really a route segment, in the sense that it doesn't appear in the route
647
- * tree, but we store it in the cache as if it were, using a special key.
662
+ * Whether the task can use runtime requests to prefetch the content.
648
663
  *
649
- * Symmetric with the per-segment decision point in
650
- * pingNewPartOfCacheComponentsTree: the head deopts to the runtime prefetch
651
- * path either when it requires runtime completeness and no static attempt is
652
- * happening, or when a fulfilled static head entry reported that a runtime
653
- * request would return more content than the entry contains. Deopting
654
- * registers the head under its metadata request key, which makes the runtime
655
- * gate in pingRootRouteTree fire even when every tree segment was
656
- * sufficient; pingRuntimeHead performs the actual head work.
657
- */ function pingStaticHead(now, task, route, // The per-pass static walk strategy; see pingRootRouteTree where
658
- // it's derived.
659
- fetchStrategy) {
660
- // The head is subject to the same per-pass runtime-completeness contract
661
- // as the route's segments: during an App Shell walk, and during any walk
662
- // of a Partial Prefetching route, the head needs a response at least as
663
- // complete as a runtime one.
664
- const headRequiresRuntimeCompleteness = walkRequiresRuntimeCompleteness(fetchStrategy, route);
665
- if (headRequiresRuntimeCompleteness && // The head is not a tree node — it hangs off the route root — so the
666
- // static-attempt hint is read from the root's node. (Segments read the
667
- // bit from their own node; see the decision point in
668
- // pingNewPartOfCacheComponentsTree.)
669
- (route.tree.prefetchHints & _approutertypes.PrefetchHint.ShouldAttemptStaticPrefetch) === 0) {
670
- // No static attempt: the head arrives via the runtime request instead.
671
- addSpawnedRuntimePrefetch(task, route.metadata.requestKey);
672
- return;
673
- }
674
- if (// If the head was inlined into a page's bundle (HeadOutlined is NOT set
675
- // on the root), skip the standalone fetch — the head data will arrive
676
- // as part of that page's response, and its runtime-completeness signal
677
- // is carried by that page's own entries.
678
- process.env.__NEXT_PREFETCH_INLINING && !(route.tree.prefetchHints & _approutertypes.PrefetchHint.HeadOutlined)) {
679
- return;
680
- }
681
- const segments = {
682
- tree: route.metadata,
683
- entry: (0, _cache.readOrCreateSegmentCacheEntry)(now, task.segmentCacheMap, fetchStrategy, route.metadata),
684
- parent: null
685
- };
686
- const needsRuntimeRequest = pingSegmentBundle(now, task, route, task.key, route.metadata, segments, fetchStrategy, true);
687
- if (headRequiresRuntimeCompleteness && needsRuntimeRequest) {
688
- // The static attempt was insufficient for the head. Deopt to a
689
- // runtime prefetch. (Outside of runtime-completeness contexts the
690
- // head's signal is unused — a partial static head is filled in by the
691
- // navigation-time request, as with any other static segment.)
692
- addSpawnedRuntimePrefetch(task, route.metadata.requestKey);
664
+ * This is true for every walk of a route that opts into Partial Prefetching
665
+ * (any segment with a partial-prefetching config, or the global `partialPrefetching`
666
+ * flag, indicated by `SubtreeHasPartialPrefetching` on the route root),
667
+ * in both the Shell and Speculative phases.
668
+ *
669
+ * Note that this does not mean that the route *will* use runtime requests --
670
+ * it might be optimized statically, either because it does not use runtime data
671
+ * in the shell/prefetch, or if it's forced to use static requests by
672
+ * `export const ensureStatic = "shell" | "prefetch" | "navigation"`.
673
+ *
674
+ * Routes without Partial Prefetching never use runtime requests for prefetches
675
+ * (excluding `Full` prefetches)
676
+ */ function walkCanUseRuntimeRequests(staticWalkStrategy, route) {
677
+ if (staticWalkStrategy === _types.FetchStrategy.StaticShell) {
678
+ // `FetchStrategy.StaticShell` is only used on PPF routes.
679
+ return true;
693
680
  }
681
+ // `FetchStrategy.PPR` can only use runtime requests if PPF is enabled on the route.
682
+ return (route.root.tree.prefetchHints & _approutertypes.PrefetchHint.SubtreeHasPartialPrefetching) !== 0;
694
683
  }
695
684
  /**
696
- * Whether the task needs a cache entry at least as complete as a runtime
697
- * response for every segment it walks before the prefetch counts as done.
698
- * Runtime completeness is the universal contract for Partial Prefetching,
699
- * so the predicate is per pass, not per segment:
700
- *
701
- * - Every walk of a route that opts into Partial Prefetching (any segment
702
- * with a partial-prefetching config, or the global `partialPrefetching`
703
- * flag — both surfaced as SubtreeHasPartialPrefetching on the route
704
- * root), in both the Shell and Speculative phases.
705
- * - Every App Shell (StaticShell) walk, because the App Shell must be
706
- * reusable across all params by definition. (In practice this is implied
707
- * by the first case — the Shell phase only runs for Partial Prefetching
708
- * routes.)
709
- *
710
- * Routes without Partial Prefetching keep the static-only contract: their
711
- * walks prefetch static data and partial entries are acceptable — the
712
- * dynamic holes are filled by the navigation-time request.
713
- *
714
- * Note that on a Partial Prefetching route, non-eager subtrees are still
715
- * skipped by the Speculative pass of a default (auto) link — eagerness is
716
- * unaffected by this predicate. But every segment the pass DOES walk (eager
717
- * segments, and everything on a `prefetch={true}` walk) is held to the
718
- * runtime-completeness contract. The contract is affordable because most
719
- * routes carry the ShouldAttemptStaticPrefetch hint: their segments are
720
- * prefetched statically and the responses' own sufficiency signal makes a
721
- * runtime request rare. On a hint-unset route, a walked segment deopts
722
- * directly to the batched runtime request — which then serves the segment's
723
- * whole subtree, so navigations into it are complete without a
724
- * navigation-time request.
685
+ * Whether a static request for this segment should be attempted.
686
+ * This may vary on the static walk's strategy, because we might e.g.
687
+ * have a shell that's static, but a prefetch that requires runtime requests.
725
688
  *
726
- * This is also the gate for the batched runtime request at the end of
727
- * pingRootRouteTree; requiring runtime completeness does not itself mean a
728
- * runtime request is issued for a given segment — see the decision point in
729
- * pingNewPartOfCacheComponentsTree.
730
- */ function walkRequiresRuntimeCompleteness(staticWalkStrategy, route) {
731
- return staticWalkStrategy === _types.FetchStrategy.StaticShell || (route.tree.prefetchHints & _approutertypes.PrefetchHint.SubtreeHasPartialPrefetching) !== 0;
689
+ * NOTE: Should only be used on Partial Prefetching routes, where
690
+ * `walkCanUseRuntimeRequests` is true.
691
+ * */ function shouldSegmentAttemptStaticRequest(staticWalkStrategy, tree) {
692
+ const { prefetchHints } = tree;
693
+ switch(staticWalkStrategy){
694
+ case _types.FetchStrategy.StaticShell:
695
+ return (prefetchHints & _approutertypes.PrefetchHint.ShouldAttemptStaticShell) !== 0;
696
+ case _types.FetchStrategy.PPR:
697
+ return (prefetchHints & _approutertypes.PrefetchHint.ShouldAttemptStaticPrefetch) !== 0;
698
+ default:
699
+ staticWalkStrategy;
700
+ return false;
701
+ }
732
702
  }
733
703
  /**
734
704
  * The runtime counterpart of a pass's static walk strategy: the strategy the
735
705
  * batched runtime request uses if this walk deopts. Each phase has exactly one
736
- * — the Shell phase escalates to a runtime App Shell, the Speculative phase to
737
- * a per-link concrete runtime prefetch.
706
+ * — the Shell phase escalates to a shell-scoped runtime request
707
+ * (RuntimeShell), the Speculative phase to a per-link concrete
708
+ * runtime prefetch.
738
709
  */ function getRuntimeStrategyForWalk(staticWalkStrategy) {
739
710
  return staticWalkStrategy === _types.FetchStrategy.StaticShell ? _types.FetchStrategy.RuntimeShell : _types.FetchStrategy.PPRRuntime;
740
711
  }
@@ -752,8 +723,36 @@ fetchStrategy) {
752
723
  return (0, _cache.canNewFetchStrategyProvideMoreContent)(entry.fetchStrategy, getRuntimeStrategyForWalk(staticWalkStrategy));
753
724
  }
754
725
  /**
755
- * Register a subtree root (or the head's metadata key) for the batched
756
- * runtime request issued by the gate at the end of pingRootRouteTree.
726
+ * Whether a fulfilled shell-tier entry should take a static attempt (a
727
+ * spawned revalidation at the walk's static tier) before its position deopts
728
+ * to a runtime request. A shell-tier recorded entry (StaticShell or
729
+ * RuntimeShell) is not evidence that a static attempt would be pointless —
730
+ * unlike a concrete static (PPR) entry, where a static re-fetch would return
731
+ * the same bytes — so when the segment's hint says a static attempt is
732
+ * worthwhile (the build-time prerender accessed no runtime data), the
733
+ * attempt is taken and its response's own verdict decides whether to
734
+ * escalate afterward.
735
+ *
736
+ * Consults the revalidation slot so an attempt that already ran and settled
737
+ * without healing the entry (a rejected attempt: server miss or network
738
+ * error; a successful one upserts over the shell-tier entry, so the caller
739
+ * reads the healed entry instead) doesn't suppress the runtime deopt
740
+ * forever. The slot read creates an Empty placeholder on first evaluation —
741
+ * there is no read-only variant — which is harmless: when the entry is
742
+ * eligible, the spawn that follows claims the same slot.
743
+ */ function isShellEntryEligibleForStaticAttempt(now, map, entry, tree, fetchStrategy) {
744
+ if (!((entry.fetchStrategy === _types.FetchStrategy.StaticShell || entry.fetchStrategy === _types.FetchStrategy.RuntimeShell) && shouldSegmentAttemptStaticRequest(fetchStrategy, tree) && // if the `fetchStrategy` is `FetchStrategy.PPR`, it might provide more content
745
+ // (e.g. static params that this shell doesn't have)
746
+ (0, _cache.canNewFetchStrategyProvideMoreContent)(entry.fetchStrategy, fetchStrategy))) {
747
+ return false;
748
+ }
749
+ const revalidatingEntry = (0, _cache.readOrCreateRevalidatingSegmentEntry)(now, map, fetchStrategy, tree);
750
+ return revalidatingEntry.status === _cache.EntryStatus.Empty || revalidatingEntry.status === _cache.EntryStatus.Pending;
751
+ }
752
+ /**
753
+ * Register a subtree root (the head is one, under its own request key) for
754
+ * the batched runtime request issued by the gate at the end of
755
+ * pingRootRouteTree.
757
756
  */ function addSpawnedRuntimePrefetch(task, requestKey) {
758
757
  if (task.spawnedRuntimePrefetches === null) {
759
758
  task.spawnedRuntimePrefetches = new Set([
@@ -763,70 +762,81 @@ fetchStrategy) {
763
762
  task.spawnedRuntimePrefetches.add(requestKey);
764
763
  }
765
764
  }
766
- function pingRuntimeHead(now, task, route, spawnedEntries, fetchStrategy) {
767
- pingRouteTreeAndIncludeDynamicData(now, task, route, route.metadata, false, spawnedEntries, // When prefetching the head, there's no difference between Full
768
- // and LoadingBoundary
769
- fetchStrategy === _types.FetchStrategy.LoadingBoundary ? _types.FetchStrategy.Full : fetchStrategy);
770
- }
771
765
  // TODO: Rename dynamic -> runtime throughout this module
772
- function pingSharedPartOfCacheComponentsTree(now, task, route, oldTree, newTree, parentBundle, // The per-pass static walk strategy; see pingRootRouteTree where
766
+ /**
767
+ * The static walk over the part of the target route that also exists on the
768
+ * current page: the current page's node and the target route's node at the
769
+ * same position in the tree. It mirrors the navigation's traversal order (see
770
+ * updateRenderTreeOnNavigation in render-tree.ts): first whether the route
771
+ * position still matches — if not, this node begins the new part of the route
772
+ * (pingNewPartOfCacheComponentsTree) — and then whether any of the node's
773
+ * param values changed — if so, the node and everything below it begin the
774
+ * new part of the route too. The walk does not consult which params a
775
+ * segment read, so it prefetches more than the navigation replaces: the
776
+ * navigation keeps data whose read params did not change and decides each
777
+ * descendant on its own. A node the walk keeps is prefetched at the ordinary
778
+ * static tier.
779
+ * Its children continue here wherever the current page has a child in the
780
+ * same slot; a child in a slot the current page doesn't have enters the new
781
+ * part of the route directly.
782
+ *
783
+ * Bundle chains must not cross the strategy boundary: a kept node walks at
784
+ * PPR while a Shell-phase new part walks at StaticShell, and a chain spanning
785
+ * both would fulfill the kept node's concrete-path entry with shell-variant
786
+ * data. Nor may the chain be finished by fetching the new-part node at PPR
787
+ * — that would prefetch new-part segments at the concrete tier during the
788
+ * Shell phase, which only the Speculative phase is allowed to do. So the
789
+ * chain is dropped wherever the walk hands off to the new part during a
790
+ * StaticShell walk, exactly like the drop sites in
791
+ * pingSegmentInCacheComponentsTree: nothing in a dropped chain was upgraded
792
+ * to Pending, so no entry is stranded, and the inlined kept data is fetched
793
+ * by the Speculative pass whenever its walk of the new part permits the
794
+ * child fetch.
795
+ */ function pingSharedPartOfCacheComponentsTree(now, task, route, currentTree, newTree, parentBundle, // The per-pass static walk strategy; see pingRootRouteTree where
773
796
  // it's derived.
774
797
  fetchStrategy) {
775
- // When Cache Components is enabled (or PPR, or a fully static route when PPR
776
- // is disabled; those cases are treated equivalently to Cache Components), we
777
- // start by prefetching each segment individually. Once we reach the "new"
778
- // part of the tree — the part that doesn't exist on the current page — we
779
- // may choose to switch to a runtime prefetch instead, based on the
780
- // information sent by the server in the route tree.
781
- //
782
- // The traversal starts in the "shared" part of the tree. Once we reach the
783
- // "new" part of the tree, we switch to a different traversal,
784
- // pingNewPartOfCacheComponentsTree.
785
- // The shared part of the tree always performs the ordinary static (PPR)
786
- // prefetch, regardless of phase. Phase-specific strategies — the runtime
787
- // shell request and the Shell phase's StaticShell walk — apply only to the
788
- // new part of the tree, so the per-pass walk strategy is irrelevant here.
789
- // (The needs-runtime signal is ignored: shared segments are already
790
- // rendered on the current page, so a runtime prefetch has nothing to add.)
798
+ if (!(0, _cache.doesRouteStructureMatch)(currentTree, newTree)) {
799
+ // We're entering the part of the target route that doesn't exist on the
800
+ // current page.
801
+ return pingNewPartOfCacheComponentsTree(now, task, route, newTree, fetchStrategy === _types.FetchStrategy.StaticShell ? null : parentBundle, fetchStrategy);
802
+ }
803
+ if ((0, _varypath.compareParams)(currentTree.varyPath, newTree.varyPath) !== _varypath.ParamsChange.None) {
804
+ // A param changed. The navigation replaces only the data that read it and
805
+ // decides each descendant on its own (see updateRenderTreeOnNavigation in
806
+ // render-tree.ts); this walk doesn't know what each segment read, so it
807
+ // prefetches the whole subtree.
808
+ return pingNewPartOfCacheComponentsTree(now, task, route, newTree, fetchStrategy === _types.FetchStrategy.StaticShell ? null : parentBundle, fetchStrategy);
809
+ }
810
+ // The navigation keeps this segment's current data. A kept segment always
811
+ // performs the ordinary static (PPR) prefetch, regardless of phase.
812
+ // Phase-specific strategies — the runtime shell request and the Shell
813
+ // phase's StaticShell walk — apply only to the new part of the tree, so the
814
+ // per-pass walk strategy is irrelevant here. (The needs-runtime signal is
815
+ // ignored: kept segments are already rendered on the current page, so a
816
+ // runtime prefetch has nothing to add.)
791
817
  const bundleInProgress = accumulateSegmentBundle(now, task, route, newTree, parentBundle, _types.FetchStrategy.PPR, true).bundle;
792
- // Recursively ping the children.
793
- const oldTreeChildren = oldTree[1];
818
+ // Recursively ping the children, continuing in lockstep with the current
819
+ // page wherever it has a child in the same slot.
794
820
  const newTreeChildren = newTree.slots;
795
821
  if (newTreeChildren !== null) {
822
+ const currentSlots = currentTree.slots;
796
823
  for (const [parallelRouteKey, newTreeChild] of newTreeChildren){
797
824
  if (!hasNetworkBandwidth(task)) {
798
825
  // Stop prefetching segments until there's more bandwidth.
799
826
  return 0;
800
827
  }
801
- const newTreeChildSegment = newTreeChild.segment;
802
- const oldTreeChild = oldTreeChildren[parallelRouteKey];
803
- const oldTreeChildSegment = oldTreeChild?.[0];
804
828
  // Only pass the bundle to the child that accepts it. A parent is
805
829
  // only ever bundled into one child.
806
830
  const bundleForChild = process.env.__NEXT_PREFETCH_INLINING && bundleInProgress !== null && newTreeChild.prefetchHints & _approutertypes.PrefetchHint.ParentInlinedIntoSelf ? bundleInProgress : null;
831
+ let currentTreeChild = undefined;
832
+ if (currentSlots !== null) {
833
+ currentTreeChild = currentSlots.get(parallelRouteKey);
834
+ }
807
835
  let childExitStatus;
808
- if (oldTreeChildSegment !== undefined && doesCurrentSegmentMatchCachedSegment(route, newTreeChildSegment, oldTreeChildSegment)) {
809
- // We're still in the "shared" part of the tree.
810
- childExitStatus = pingSharedPartOfCacheComponentsTree(now, task, route, oldTreeChild, newTreeChild, bundleForChild, fetchStrategy);
836
+ if (currentTreeChild !== undefined) {
837
+ childExitStatus = pingSharedPartOfCacheComponentsTree(now, task, route, currentTreeChild, newTreeChild, bundleForChild, fetchStrategy);
811
838
  } else {
812
- // We've entered the "new" part of the tree. Switch
813
- // traversal functions.
814
- //
815
- // Bundle chains must not cross the strategy boundary: the shared
816
- // part walks at PPR while a Shell-phase new part walks at
817
- // StaticShell, and a chain spanning both would fulfill the shared
818
- // parent's concrete-path entry with shell-variant data. Nor may we
819
- // finish the chain by fetching the new-part child at PPR here —
820
- // that would prefetch new-part segments at the concrete tier
821
- // during the Shell phase, which only the Speculative phase is
822
- // allowed to do. So drop the bundle instead, exactly like the
823
- // Speculative walk's subtree bail does when a chain crosses into a
824
- // subtree it skips: nothing in a dropped chain was upgraded to
825
- // Pending, so no entry is stranded, and the inlined shared data is
826
- // fetched by the Speculative pass whenever its walk of the new
827
- // part permits the child fetch.
828
- const bundleForNewPart = fetchStrategy === _types.FetchStrategy.StaticShell ? null : bundleForChild;
829
- childExitStatus = pingNewPartOfCacheComponentsTree(now, task, route, newTreeChild, bundleForNewPart, fetchStrategy);
839
+ childExitStatus = pingNewPartOfCacheComponentsTree(now, task, route, newTreeChild, fetchStrategy === _types.FetchStrategy.StaticShell ? null : bundleForChild, fetchStrategy);
830
840
  }
831
841
  if (childExitStatus === 0) {
832
842
  // Child yielded without finishing.
@@ -834,62 +844,94 @@ fetchStrategy) {
834
844
  }
835
845
  }
836
846
  }
847
+ // The static attempt was sufficient for this segment (each child is its
848
+ // own decision point) — or parts of it are still in flight, in which case
849
+ // the task is blocked and the decision re-runs against the received
850
+ // responses.
837
851
  return 2;
838
852
  }
839
- function pingNewPartOfCacheComponentsTree(now, task, route, tree, parentBundle, // The per-pass static walk strategy; see pingRootRouteTree where
853
+ /**
854
+ * The static walk over the part of the target route that doesn't exist on
855
+ * the current page. Nothing here is compared against the current tree: every
856
+ * segment goes through the per-segment decision point.
857
+ */ function pingNewPartOfCacheComponentsTree(now, task, route, tree, parentBundle, // The per-pass static walk strategy; see pingRootRouteTree where
840
858
  // it's derived.
841
859
  fetchStrategy) {
842
- // We're now prefetching in the "new" part of the tree, the part that
843
- // doesn't exist on the current page. (In other words, we're deeper than
844
- // the shared layouts.) Segments in here default to being prefetched
845
- // statically, at the per-pass strategy derived in pingRootRouteTree.
846
- //
847
- // When the walk requires runtime completeness — an entry at least as
848
- // complete as a runtime response for every segment before the prefetch
849
- // can complete (see walkRequiresRuntimeCompleteness) — this function is
850
- // also the per-segment decision point. If the segment's node carries the
851
- // ShouldAttemptStaticPrefetch hint (the build-time prerender accessed no
852
- // runtime data), its subtree is prefetched statically first,
853
- // and the responses themselves decide whether that was enough: every
854
- // fulfilled entry carries a needsRuntimeRequest signal. Pending responses
855
- // block the task, so the attempt is serial, never raced: static attempt →
856
- // observe → runtime only if needed. Without the hint, the segment deopts
857
- // directly. Deopting registers the segment's request key in
858
- // spawnedRuntimePrefetches; the runtime gate at the end of
859
- // pingRootRouteTree issues a single batched runtime request for
860
- // everything that accumulated, and that request re-fetches the whole
861
- // subtree, so the walk stops descending at a deopt.
862
- //
863
- // Outside a runtime-completeness walk the same needsRuntimeRequest signal
864
- // is routine and ignored — any partial entry of a page that accesses
865
- // runtime data carries it, and the dynamic holes are filled by the
866
- // navigation-time request.
867
- if (// Only the Speculative pass skips subtrees with nothing to speculatively
868
- // prefetch. (It's also the only pass that walks at FetchStrategy.PPR;
869
- // the Shell phase walks at StaticShell and covers the whole new tree.)
870
- fetchStrategy === _types.FetchStrategy.PPR && !subtreeHasSpeculativePrefetch(task.fetchStrategy, tree.prefetchHints)) {
871
- // Nothing in the new part of the tree needs to be speculatively prefetched.
872
- // Bail out.
860
+ const accumulation = pingSegmentInCacheComponentsTree(now, task, route, tree, parentBundle, fetchStrategy);
861
+ if (accumulation === null) {
873
862
  return 2;
874
863
  }
864
+ const bundleInProgress = accumulation.bundle;
865
+ // Recursively ping the children.
866
+ const treeChildren = tree.slots;
867
+ if (treeChildren !== null) {
868
+ for (const treeChild of treeChildren.values()){
869
+ if (!hasNetworkBandwidth(task)) {
870
+ // Stop prefetching segments until there's more bandwidth.
871
+ return 0;
872
+ }
873
+ // Only pass the bundle to the child that accepts it. A parent is
874
+ // only ever bundled into one child.
875
+ const bundleForChild = process.env.__NEXT_PREFETCH_INLINING && bundleInProgress !== null && treeChild.prefetchHints & _approutertypes.PrefetchHint.ParentInlinedIntoSelf ? bundleInProgress : null;
876
+ const childExitStatus = pingNewPartOfCacheComponentsTree(now, task, route, treeChild, bundleForChild, fetchStrategy);
877
+ if (childExitStatus === 0) {
878
+ // Child yielded without finishing.
879
+ return 0;
880
+ }
881
+ }
882
+ }
883
+ // The static attempt was sufficient for this segment (each child is its
884
+ // own decision point) — or parts of it are still in flight, in which case
885
+ // the task is blocked and the decision re-runs against the received
886
+ // responses.
887
+ return 2;
888
+ }
889
+ /**
890
+ * The per-segment decision point of the static walk: the one place that
891
+ * decides how a segment in the new part of the route — one the navigation
892
+ * won't keep — is prefetched (pingNewPartOfCacheComponentsTree).
893
+ *
894
+ * When Cache Components is enabled (or PPR, or a fully static route when PPR
895
+ * is disabled; those cases are treated equivalently to Cache Components), we
896
+ * prefetch each segment individually, statically, at the per-pass strategy
897
+ * derived in pingRootRouteTree.
898
+ *
899
+ * This is where we decide whether we should use runtime requests, if the walk
900
+ * is allowed to do so (see `walkCanUseRuntimeRequests`).
901
+ *
902
+ * If runtime requests are allowed, but the segment's node has one of the
903
+ * `ShouldAttemptStatic{Shell,Prefetch}` hints set (either because the build-time
904
+ * prerender accessed no runtime data, or because of `ensureStatic`), then its
905
+ * subtree should be prefetched statically first.
906
+ * However, the hint may be stale after a revalidation, so we'll also check the
907
+ * `needsRuntimeRequest` promise on the static response, and will follow up with
908
+ * a runtime request if needed.
909
+ * Pending responses block the task, so the attempt is serial, never raced:
910
+ * static attempt → observe → runtime (if needed).
911
+ *
912
+ * The static hints and `needsRuntimeRequest` have no effect if runtime requests
913
+ * are not allowed (i.e. outside of Partial Prefetching).
914
+ *
915
+ * Returns the segment's bundle accumulation when the walk should continue
916
+ * into its children, and null when the walk stops at this segment: the link
917
+ * needs no speculative prefetch, or the segment deopted and the batched
918
+ * runtime request covers the whole subtree.
919
+ */ function pingSegmentInCacheComponentsTree(now, task, route, tree, parentBundle, // The per-pass static walk strategy; see pingRootRouteTree where
920
+ // it's derived.
921
+ fetchStrategy) {
922
+ // In PPF, links may skip speculative prefetching if they only need a shell.
923
+ if (fetchStrategy === _types.FetchStrategy.PPR && !needsSpeculativePrefetch(task.fetchStrategy, route.root.tree.prefetchHints)) {
924
+ return null;
925
+ }
875
926
  // Constant for the whole pass; recomputed here only because the walk is
876
927
  // recursive and the check is cheap.
877
- const segmentRequiresRuntimeCompleteness = walkRequiresRuntimeCompleteness(fetchStrategy, route);
878
- // TODO: The static-attempt hint reflects the build-time prerender's whole
879
- // runtime-data tracking, so a page that always accesses
880
- // runtime data after the shell stage never attempts a static prefetch —
881
- // even though its shell variant is rewindable at the shell boundary and
882
- // perfectly reusable. The server could emit a second bit derived from the
883
- // shell-stage value ("a static SHELL attempt is worthwhile even though
884
- // the page accesses runtime data post-shell") to let such pages attempt
885
- // static, too.
928
+ const canUseRuntimeRequests = walkCanUseRuntimeRequests(fetchStrategy, route);
886
929
  // A force-disabled segment deliberately does NOT deopt here: disabling
887
930
  // prefetch is passive. It never initiates a request — its accumulation
888
931
  // below contributes nothing — and must never be the reason a runtime
889
932
  // prefetch spawns, though it may ride along in a runtime response issued
890
933
  // on another segment's behalf.
891
- const attemptStaticPrefetchOfSegment = (tree.prefetchHints & _approutertypes.PrefetchHint.ShouldAttemptStaticPrefetch) !== 0;
892
- if (segmentRequiresRuntimeCompleteness && !attemptStaticPrefetchOfSegment) {
934
+ if (canUseRuntimeRequests && !shouldSegmentAttemptStaticRequest(fetchStrategy, tree)) {
893
935
  // Deopt directly to a runtime prefetch, without a static attempt.
894
936
  addSpawnedRuntimePrefetch(task, tree.requestKey);
895
937
  // If there's a pending static bundle from a parent, we need to finish
@@ -897,13 +939,12 @@ fetchStrategy) {
897
939
  if (parentBundle !== null) {
898
940
  finishStaticBundleOnRuntimeBailout(now, task, route, tree, parentBundle, fetchStrategy);
899
941
  }
900
- return 2;
942
+ return null;
901
943
  }
902
944
  // Prefetch this segment and its subtree statically, using the normal
903
945
  // static bundling walk.
904
946
  const accumulation = accumulateSegmentBundle(now, task, route, tree, parentBundle, fetchStrategy, true);
905
- const bundleInProgress = accumulation.bundle;
906
- if (segmentRequiresRuntimeCompleteness && accumulation.needsRuntimeRequest) {
947
+ if (canUseRuntimeRequests && accumulation.needsRuntimeRequest) {
907
948
  // The static attempt for this segment was insufficient. Stop the walk
908
949
  // and deopt — the runtime prefetch covers the whole subtree. (Unlike the
909
950
  // direct deopt above, any open bundle is dropped rather than finished: a
@@ -912,112 +953,28 @@ fetchStrategy) {
912
953
  // upgraded to Pending, so no entry is stranded blocking the task, and
913
954
  // Empty entries in the dropped chain are re-fetched by a later pass.)
914
955
  addSpawnedRuntimePrefetch(task, tree.requestKey);
915
- return 2;
916
- }
917
- if (tree.slots !== null) {
918
- if (!hasNetworkBandwidth(task)) {
919
- // Stop prefetching segments until there's more bandwidth.
920
- return 0;
921
- }
922
- // Recursively ping the children.
923
- for (const childTree of tree.slots.values()){
924
- // Only pass the bundle to the child that accepts it. A parent is
925
- // only ever bundled into one child.
926
- const bundleForChild = process.env.__NEXT_PREFETCH_INLINING && bundleInProgress !== null && childTree.prefetchHints & _approutertypes.PrefetchHint.ParentInlinedIntoSelf ? bundleInProgress : null;
927
- const childResult = pingNewPartOfCacheComponentsTree(now, task, route, childTree, bundleForChild, fetchStrategy);
928
- if (childResult === 0) {
929
- // Child yielded without finishing.
930
- return 0;
931
- }
932
- }
956
+ return null;
933
957
  }
934
- // The static attempt was sufficient for this segment (each child is its
935
- // own decision point) — or parts of it are still in flight, in which case
936
- // the task is blocked and the decision re-runs against the received
937
- // responses.
938
- return 2;
958
+ return accumulation;
939
959
  }
940
960
  function diffRouteTreeAgainstCurrent(now, task, route, oldTree, newTree, spawnedEntries, fetchStrategy) {
941
961
  // This is a single recursive traversal that does multiple things:
942
- // - Finds the parts of the target route (newTree) that are not part of
943
- // of the current page (oldTree) by diffing them, using the same algorithm
944
- // as a real navigation.
962
+ // - Finds the segments that differ from the current route, comparing each
963
+ // segment the same way the navigation will (see
964
+ // updateRenderTreeOnNavigation in render-tree.ts): its route position,
965
+ // then whether any of its param values changed.
945
966
  // - Constructs a request tree (FlightRouterState) that describes which
946
967
  // segments need to be prefetched and which ones are already cached.
947
968
  // - Creates a set of pending cache entries for the segments that need to
948
969
  // be prefetched, so that a subsequent prefetch task does not request the
949
970
  // same segments again.
950
- const oldTreeChildren = oldTree[1];
971
+ const oldSlots = oldTree.slots;
951
972
  const newTreeChildren = newTree.slots;
952
973
  let requestTreeChildren = {};
953
974
  if (newTreeChildren !== null) {
954
975
  for (const [parallelRouteKey, newTreeChild] of newTreeChildren){
955
- const newTreeChildSegment = newTreeChild.segment;
956
- const oldTreeChild = oldTreeChildren[parallelRouteKey];
957
- const oldTreeChildSegment = oldTreeChild?.[0];
958
- if (oldTreeChildSegment !== undefined && doesCurrentSegmentMatchCachedSegment(route, newTreeChildSegment, oldTreeChildSegment)) {
959
- // This segment is already part of the current route. Keep traversing.
960
- const requestTreeChild = diffRouteTreeAgainstCurrent(now, task, route, oldTreeChild, newTreeChild, spawnedEntries, fetchStrategy);
961
- requestTreeChildren[parallelRouteKey] = requestTreeChild;
962
- } else {
963
- // This segment is not part of the current route. We're entering a
964
- // part of the tree that we need to prefetch (unless everything is
965
- // already cached).
966
- switch(fetchStrategy){
967
- case _types.FetchStrategy.LoadingBoundary:
968
- {
969
- // When PPR is disabled, we can't prefetch per segment. We must
970
- // fallback to the old prefetch behavior and send a dynamic request.
971
- // Only routes that include a loading boundary can be prefetched in
972
- // this way.
973
- //
974
- // This is simlar to a "full" prefetch, but we're much more
975
- // conservative about which segments to include in the request.
976
- //
977
- // The server will only render up to the first loading boundary
978
- // inside new part of the tree. If there's no loading boundary
979
- // anywhere in the tree, the server will never return any data, so
980
- // we can skip the request.
981
- const subtreeHasLoadingBoundary = (newTreeChild.prefetchHints & (_approutertypes.PrefetchHint.SegmentHasLoadingBoundary | _approutertypes.PrefetchHint.SubtreeHasLoadingBoundary)) !== 0;
982
- const requestTreeChild = subtreeHasLoadingBoundary ? pingPPRDisabledRouteTreeUpToLoadingBoundary(now, task, route, newTreeChild, null, spawnedEntries) : (0, _cache.convertRouteTreeToFlightRouterState)(newTreeChild);
983
- requestTreeChildren[parallelRouteKey] = requestTreeChild;
984
- break;
985
- }
986
- case _types.FetchStrategy.PPRRuntime:
987
- {
988
- // This is a runtime prefetch. Fetch all cacheable data in the tree,
989
- // not just the static PPR shell.
990
- const requestTreeChild = pingRouteTreeAndIncludeDynamicData(now, task, route, newTreeChild, false, spawnedEntries, fetchStrategy);
991
- requestTreeChildren[parallelRouteKey] = requestTreeChild;
992
- break;
993
- }
994
- case _types.FetchStrategy.Full:
995
- {
996
- // This is a "full" prefetch. Fetch all the data in the tree, both
997
- // static and dynamic. We issue roughly the same request that we
998
- // would during a real navigation. The goal is that once the
999
- // navigation occurs, the router should not have to fetch any
1000
- // additional data.
1001
- //
1002
- // Although the response will include dynamic data, opting into a
1003
- // Full prefetch — via <Link prefetch={true}> — implicitly
1004
- // instructs the cache to treat the response as "static", or non-
1005
- // dynamic, since the whole point is to cache it for
1006
- // future navigations.
1007
- //
1008
- // Construct a tree (currently a FlightRouterState) that represents
1009
- // which segments need to be prefetched and which ones are already
1010
- // cached. If the tree is empty, then we can exit. Otherwise, we'll
1011
- // send the request tree to the server and use the response to
1012
- // populate the segment cache.
1013
- const requestTreeChild = pingRouteTreeAndIncludeDynamicData(now, task, route, newTreeChild, false, spawnedEntries, fetchStrategy);
1014
- requestTreeChildren[parallelRouteKey] = requestTreeChild;
1015
- break;
1016
- }
1017
- default:
1018
- fetchStrategy;
1019
- }
1020
- }
976
+ const oldTreeChild = oldSlots?.get(parallelRouteKey);
977
+ requestTreeChildren[parallelRouteKey] = diffSegmentAgainstCurrent(now, task, route, oldTreeChild, newTreeChild, spawnedEntries, fetchStrategy);
1021
978
  }
1022
979
  }
1023
980
  const requestTree = [
@@ -1031,6 +988,77 @@ function diffRouteTreeAgainstCurrent(now, task, route, oldTree, newTree, spawned
1031
988
  }
1032
989
  return requestTree;
1033
990
  }
991
+ /**
992
+ * The per-segment decision of a runtime request's tree walk
993
+ * (diffRouteTreeAgainstCurrent): the segment at this position of the target
994
+ * route, and the current page's segment at the same position, if it has one.
995
+ * A segment the navigation keeps — same route position, and none of its param
996
+ * values changed — is omitted from the request and the walk continues into
997
+ * its children. Otherwise this segment begins a part of the tree that needs
998
+ * to be prefetched (unless everything is already cached), requested according
999
+ * to the strategy.
1000
+ */ function diffSegmentAgainstCurrent(now, task, route, oldTree, newTree, spawnedEntries, fetchStrategy) {
1001
+ if (oldTree !== undefined && (0, _cache.doesRouteStructureMatch)(oldTree, newTree)) {
1002
+ // This segment is already part of the current route.
1003
+ if ((0, _varypath.compareParams)(oldTree.varyPath, newTree.varyPath) === _varypath.ParamsChange.None) {
1004
+ // The navigation keeps its data. Keep traversing.
1005
+ return diffRouteTreeAgainstCurrent(now, task, route, oldTree, newTree, spawnedEntries, fetchStrategy);
1006
+ }
1007
+ }
1008
+ // This segment is not part of the current route, or the navigation
1009
+ // replaces its data. We're entering a part of the tree that we need to
1010
+ // prefetch (unless everything is already cached).
1011
+ switch(fetchStrategy){
1012
+ case _types.FetchStrategy.LoadingBoundary:
1013
+ {
1014
+ // When PPR is disabled, we can't prefetch per segment. We must
1015
+ // fallback to the old prefetch behavior and send a runtime request.
1016
+ // Only routes that include a loading boundary can be prefetched in
1017
+ // this way.
1018
+ //
1019
+ // This is simlar to a "full" prefetch, but we're much more
1020
+ // conservative about which segments to include in the request.
1021
+ //
1022
+ // The server will only render up to the first loading boundary
1023
+ // inside new part of the tree. If there's no loading boundary
1024
+ // anywhere in the tree, the server will never return any data, so
1025
+ // we can skip the request.
1026
+ const subtreeHasLoadingBoundary = (newTree.prefetchHints & (_approutertypes.PrefetchHint.SegmentHasLoadingBoundary | _approutertypes.PrefetchHint.SubtreeHasLoadingBoundary)) !== 0;
1027
+ if (subtreeHasLoadingBoundary) {
1028
+ return pingPPRDisabledRouteTreeUpToLoadingBoundary(now, task, route, newTree, null, spawnedEntries);
1029
+ }
1030
+ // There's no loading boundary within this tree. Bail out.
1031
+ return (0, _cache.convertRouteTreeToFlightRouterState)(newTree);
1032
+ }
1033
+ case _types.FetchStrategy.PPRRuntime:
1034
+ {
1035
+ // This is a runtime prefetch. Fetch all cacheable data in the tree,
1036
+ // not just the static PPR shell.
1037
+ return pingRouteTreeAndIncludeDynamicData(now, task, route, newTree, false, spawnedEntries, fetchStrategy);
1038
+ }
1039
+ case _types.FetchStrategy.Full:
1040
+ {
1041
+ // This is a "full" prefetch. Fetch all the data in the tree, both
1042
+ // static and dynamic. We issue roughly the same request that we
1043
+ // would during a real navigation. The goal is that once the
1044
+ // navigation occurs, the router should not have to fetch any
1045
+ // additional data.
1046
+ //
1047
+ // Although the response will include dynamic data, opting into a
1048
+ // Full prefetch — via <Link prefetch={true}> — implicitly
1049
+ // instructs the cache to treat the response as "static", or non-
1050
+ // dynamic, since the whole point is to cache it for
1051
+ // future navigations.
1052
+ //
1053
+ // Construct a tree (currently a FlightRouterState) that represents
1054
+ // which segments need to be prefetched and which ones are already
1055
+ // cached. If the tree is empty, then we can exit. Otherwise, we'll
1056
+ // send the request tree to the server and use the response to
1057
+ // populate the segment cache.
1058
+ return pingRouteTreeAndIncludeDynamicData(now, task, route, newTree, false, spawnedEntries, fetchStrategy);
1059
+ }
1060
+ }
1061
+ }
1034
1062
  function pingPPRDisabledRouteTreeUpToLoadingBoundary(now, task, route, tree, refetchMarkerContext, spawnedEntries) {
1035
1063
  // This function is similar to pingRouteTreeAndIncludeDynamicData, except the
1036
1064
  // server is only going to return a minimal loading state — it will stop
@@ -1299,9 +1327,11 @@ function pingRuntimePrefetches(now, task, route, tree, spawnedRuntimePrefetches,
1299
1327
  * request would return more content than the entry contains
1300
1328
  * (needsRuntimeRequest, derived at write time from the response that
1301
1329
  * produced the entry). The callers surface this signal to the per-segment
1302
- * decision point in pingNewPartOfCacheComponentsTree (and its analog for
1303
- * the head in pingStaticHead), which uses it during a static attempt to
1304
- * decide whether to fall back to a runtime prefetch.
1330
+ * decision point in pingSegmentInCacheComponentsTree, which uses it during
1331
+ * a static attempt to decide whether to fall back to a runtime prefetch. One
1332
+ * exception withholds the signal: a shell-tier entry whose segment carries
1333
+ * the static-attempt hint spawns a concrete static attempt first — see the
1334
+ * Fulfilled case.
1305
1335
  */ function pingSegmentBundle(now, task, route, routeKey, tree, segments, // Per-pass static walk strategy; see pingRootRouteTree where it's derived.
1306
1336
  fetchStrategy, // False when finishing an open bundle chain on a runtime-prefetch bailout
1307
1337
  // (finishStaticBundleOnRuntimeBailout). The finish exists only to fetch
@@ -1310,15 +1340,17 @@ fetchStrategy, // False when finishing an open bundle chain on a runtime-prefetc
1310
1340
  // already settled or in flight: the chain's terminal segments are inside
1311
1341
  // the deopted subtree, and re-fetching their static bundle would at best
1312
1342
  // duplicate the runtime request and at worst replace a runtime-complete
1313
- // entry (e.g. a runtime App Shell) with a less complete static fallback
1314
- // response.
1343
+ // entry (e.g. a RuntimeShell-tier entry) with a less complete static
1344
+ // fallback response.
1315
1345
  spawnRevalidations) {
1316
- let segmentCount = 0;
1317
- let needsFetch = false;
1318
1346
  let needsRuntimeRequest = false;
1347
+ // The pending entries this task owns — Empty entries upgraded here, plus
1348
+ // any revalidations spawned here — keyed by segment request key. If any
1349
+ // accumulate, a single fetch is spawned for the whole bundle, and the
1350
+ // response fulfills them.
1351
+ let spawnedEntries = null;
1319
1352
  let node = segments;
1320
1353
  while(node !== null){
1321
- segmentCount++;
1322
1354
  const nodeEntry = node.entry;
1323
1355
  const nodeTree = node.tree;
1324
1356
  if (nodeEntry === null || nodeTree === null) {
@@ -1327,12 +1359,17 @@ spawnRevalidations) {
1327
1359
  }
1328
1360
  switch(nodeEntry.status){
1329
1361
  case _cache.EntryStatus.Empty:
1330
- (0, _cache.upgradeToPendingSegment)(nodeEntry, fetchStrategy);
1331
- needsFetch = true;
1332
- // The pass blocks on every request it spawns, not just requests it
1333
- // finds already in flight.
1334
- blockTaskOnPendingResponse(task, nodeEntry);
1335
- break;
1362
+ {
1363
+ const pendingEntry = (0, _cache.upgradeToPendingSegment)(nodeEntry, fetchStrategy);
1364
+ if (spawnedEntries === null) {
1365
+ spawnedEntries = new Map();
1366
+ }
1367
+ spawnedEntries.set(nodeTree.requestKey, pendingEntry);
1368
+ // The pass blocks on every request it spawns, not just requests it
1369
+ // finds already in flight.
1370
+ blockTaskOnPendingResponse(task, pendingEntry);
1371
+ break;
1372
+ }
1336
1373
  case _cache.EntryStatus.Pending:
1337
1374
  if (spawnRevalidations && // During a static shell attempt, never spawn revalidations — just
1338
1375
  // wait for the in-flight response (blocked below); its sufficiency
@@ -1340,17 +1377,15 @@ spawnRevalidations) {
1340
1377
  fetchStrategy === _types.FetchStrategy.PPR && (0, _cache.canNewFetchStrategyProvideMoreContent)(nodeEntry.fetchStrategy, fetchStrategy)) {
1341
1378
  const revalidatingEntry = (0, _cache.readOrCreateRevalidatingSegmentEntry)(now, task.segmentCacheMap, fetchStrategy, nodeTree);
1342
1379
  if (revalidatingEntry.status === _cache.EntryStatus.Empty) {
1343
- (0, _cache.upgradeToPendingSegment)(revalidatingEntry, fetchStrategy);
1344
- node.entry = revalidatingEntry;
1345
- needsFetch = true;
1380
+ const pendingEntry = (0, _cache.upgradeToPendingSegment)(revalidatingEntry, fetchStrategy);
1381
+ if (spawnedEntries === null) {
1382
+ spawnedEntries = new Map();
1383
+ }
1384
+ spawnedEntries.set(nodeTree.requestKey, pendingEntry);
1346
1385
  // Block on the revalidation request we just spawned, in
1347
1386
  // addition to the original in-flight entry (blocked below).
1348
- blockTaskOnPendingResponse(task, revalidatingEntry);
1349
- } else {
1350
- node.entry = null;
1387
+ blockTaskOnPendingResponse(task, pendingEntry);
1351
1388
  }
1352
- } else {
1353
- node.entry = null;
1354
1389
  }
1355
1390
  blockTaskOnPendingResponse(task, nodeEntry);
1356
1391
  break;
@@ -1367,53 +1402,65 @@ spawnRevalidations) {
1367
1402
  fetchStrategy === _types.FetchStrategy.PPR && (0, _cache.canNewFetchStrategyProvideMoreContent)(nodeEntry.fetchStrategy, fetchStrategy)) {
1368
1403
  const revalidatingEntry = (0, _cache.readOrCreateRevalidatingSegmentEntry)(now, task.segmentCacheMap, fetchStrategy, nodeTree);
1369
1404
  if (revalidatingEntry.status === _cache.EntryStatus.Empty) {
1370
- (0, _cache.upgradeToPendingSegment)(revalidatingEntry, fetchStrategy);
1371
- node.entry = revalidatingEntry;
1372
- needsFetch = true;
1405
+ const pendingEntry = (0, _cache.upgradeToPendingSegment)(revalidatingEntry, fetchStrategy);
1406
+ if (spawnedEntries === null) {
1407
+ spawnedEntries = new Map();
1408
+ }
1409
+ spawnedEntries.set(nodeTree.requestKey, pendingEntry);
1373
1410
  // Block on the retry revalidation we just spawned, like any
1374
1411
  // other pending response. If the retry succeeds, its upsert
1375
1412
  // evicts the rejected entry (see evictShadowingSegmentEntries
1376
1413
  // in cache.ts) and the re-run pass reads the healed data. If it
1377
1414
  // rejects too, the re-run observes a settled revalidation and
1378
1415
  // moves on.
1379
- blockTaskOnPendingResponse(task, revalidatingEntry);
1380
- } else {
1381
- node.entry = null;
1416
+ blockTaskOnPendingResponse(task, pendingEntry);
1382
1417
  }
1383
- } else {
1384
- node.entry = null;
1385
1418
  }
1386
1419
  break;
1387
1420
  case _cache.EntryStatus.Fulfilled:
1388
1421
  {
1389
- const runtimeWouldProvideMore = wouldRuntimeRequestProvideMore(nodeEntry, fetchStrategy);
1390
- if (runtimeWouldProvideMore) {
1391
- // A runtime request would return more content for this segment
1392
- // than the entry contains. Surface it via the return value, so the
1393
- // caller can deopt this subtree to a runtime prefetch.
1394
- needsRuntimeRequest = true;
1422
+ let willBeSupersededByRuntimeRequest = false;
1423
+ if (walkCanUseRuntimeRequests(fetchStrategy, route)) {
1424
+ const runtimeWouldProvideMore = wouldRuntimeRequestProvideMore(nodeEntry, fetchStrategy);
1425
+ // An eligible shell-tier entry takes the static attempt path below
1426
+ // (the revalidation) instead of deopting straight to a runtime
1427
+ // request; see isShellEntryEligibleForStaticAttempt. The attempt
1428
+ // can't recur: its response records at least the concrete static
1429
+ // tier, which fails the shell-tier check on the re-run pass — and an
1430
+ // attempt that already settled without healing the entry reads as
1431
+ // ineligible, so the deopt proceeds after all.
1432
+ const shellEntryEligibleForStaticAttempt = isShellEntryEligibleForStaticAttempt(now, task.segmentCacheMap, nodeEntry, nodeTree, fetchStrategy);
1433
+ if (runtimeWouldProvideMore && !shellEntryEligibleForStaticAttempt) {
1434
+ // A runtime request would return more content for this segment
1435
+ // than the entry contains. Surface it via the return value, so the
1436
+ // caller can deopt this subtree to a runtime prefetch. (An
1437
+ // eligible shell-tier entry withholds the signal for this pass:
1438
+ // the static attempt spawned below blocks the task, and the re-run
1439
+ // pass reads the attempt's result instead.)
1440
+ needsRuntimeRequest = true;
1441
+ // If a runtime request would return more content skip the static path
1442
+ // entirely — unless the entry is an eligible shell-tier entry (see above),
1443
+ // whose static attempt IS this upgrade.
1444
+ // Otherwise the runtime request covers this segment and supersedes
1445
+ // anything a static fetch could add, so a static upgrade would at best
1446
+ // duplicate it — delivering the same content twice — and at worst replace
1447
+ // runtime content with static content.
1448
+ willBeSupersededByRuntimeRequest = true;
1449
+ }
1395
1450
  }
1451
+ // If this is the speculative phase (not the shell phase), check if we
1452
+ // should attempt to upgrade a fallback ISR response to a concrete
1453
+ // version.
1454
+ //
1396
1455
  // For entries below this phase's tier, upgrade during the phase
1397
1456
  // itself — no background deferral, since the whole point of the
1398
1457
  // Speculative phase is to bring the cache up to the
1399
1458
  // per-link-concrete tier. `isPartial` ensures a complete entry isn't
1400
1459
  // re-fetched.
1401
1460
  //
1402
- // Exception: when a runtime request would return more AND this walk
1403
- // permits one, skip the static path entirely. The runtime request
1404
- // covers this segment and supersedes anything a static fetch could
1405
- // add, so a static upgrade would at best duplicate it — delivering
1406
- // the same content twice — and at worst replace runtime content with
1407
- // static content.
1408
- //
1409
- // When no runtime request is permitted, the signal is irrelevant:
1410
- // nothing can act on it, so it must not suppress the static upgrade.
1411
- // That's what keeps a link prefetching static content on top of a
1412
- // cached shell.
1413
- const willBeSupersededByRuntimeRequest = runtimeWouldProvideMore && walkRequiresRuntimeCompleteness(fetchStrategy, route);
1414
- // Check if we should attempt to upgrade a fallback ISR response to
1415
- // a concrete version.
1416
- const isUpgradeableISRFallbackRetry = nodeEntry.isUpgradeableISRFallback && // If the status is empty, then we haven't yet attempted to upgrade
1461
+ // If we can use runtime requests and a runtime request would provide more
1462
+ // data, we also skip the upgrade (see `willBeSupersededByRuntimeRequest`)
1463
+ const isUpgradeableISRFallbackRetry = fetchStrategy === _types.FetchStrategy.PPR && nodeEntry.isUpgradeableISRFallback && // If the status is empty, then we haven't yet attempted to upgrade
1417
1464
  // the fallback.
1418
1465
  //
1419
1466
  // If the status is fulfilled, then the fallback was
@@ -1424,29 +1471,32 @@ spawnRevalidations) {
1424
1471
  if (spawnRevalidations && !willBeSupersededByRuntimeRequest && (nodeEntry.isPartial && (0, _cache.canNewFetchStrategyProvideMoreContent)(nodeEntry.fetchStrategy, fetchStrategy) || isUpgradeableISRFallbackRetry)) {
1425
1472
  const revalidatingEntry = (0, _cache.readOrCreateRevalidatingSegmentEntry)(now, task.segmentCacheMap, fetchStrategy, nodeTree);
1426
1473
  if (revalidatingEntry.status === _cache.EntryStatus.Empty) {
1427
- (0, _cache.upgradeToPendingSegment)(revalidatingEntry, fetchStrategy);
1428
- node.entry = revalidatingEntry;
1429
- needsFetch = true;
1474
+ const pendingEntry = (0, _cache.upgradeToPendingSegment)(revalidatingEntry, fetchStrategy);
1475
+ if (spawnedEntries === null) {
1476
+ spawnedEntries = new Map();
1477
+ }
1478
+ spawnedEntries.set(nodeTree.requestKey, pendingEntry);
1430
1479
  // The pass blocks on every request it spawns, including
1431
1480
  // revalidations of an already-fulfilled entry.
1432
- blockTaskOnPendingResponse(task, revalidatingEntry);
1481
+ blockTaskOnPendingResponse(task, pendingEntry);
1433
1482
  } else {
1434
1483
  // A non-empty revalidating entry means a request is already in
1435
1484
  // flight (or recently settled), so we dedupe and don't issue a
1436
1485
  // competing one — including for ISR-fallback upgrades, which then
1437
1486
  // share the same revalidation across tasks.
1438
- node.entry = null;
1439
1487
  if (revalidatingEntry.status === _cache.EntryStatus.Pending) {
1440
1488
  // The deduped-against revalidation is still in flight, and this
1441
1489
  // pass depends on its response. Wait for it before the phase
1442
1490
  // can complete. (A settled revalidation we chose not to use
1443
1491
  // needs no waiting and is not a prefetch failure — the base
1444
- // entry here is already Fulfilled.)
1492
+ // entry here is already Fulfilled. A settled revalidation
1493
+ // can't strand an eligible shell-tier entry either:
1494
+ // isShellEntryEligibleForStaticAttempt reads the slot, so a
1495
+ // settled attempt makes the entry ineligible and the runtime
1496
+ // deopt proceeds above.)
1445
1497
  blockTaskOnPendingResponse(task, revalidatingEntry);
1446
1498
  }
1447
1499
  }
1448
- } else {
1449
- node.entry = null;
1450
1500
  }
1451
1501
  break;
1452
1502
  }
@@ -1455,8 +1505,8 @@ spawnRevalidations) {
1455
1505
  }
1456
1506
  node = node.parent;
1457
1507
  }
1458
- if (needsFetch) {
1459
- spawnPrefetchSubtask((0, _cache.fetchSegmentsOnCacheMiss)(task, route, routeKey, tree, segments, segmentCount, fetchStrategy));
1508
+ if (spawnedEntries !== null) {
1509
+ spawnPrefetchSubtask((0, _cache.fetchSegmentPrefetchesUsingStaticRequest)(task, route, routeKey, tree, spawnedEntries, fetchStrategy));
1460
1510
  }
1461
1511
  return needsRuntimeRequest;
1462
1512
  }
@@ -1469,14 +1519,15 @@ spawnRevalidations) {
1469
1519
  * bundle ping, if one happened (always false otherwise).
1470
1520
  */ function accumulateSegmentBundle(now, task, route, tree, parentBundle, // Per-pass static walk strategy; see pingRootRouteTree where it's derived.
1471
1521
  // PPR for the normal static bundling walk; StaticShell during the Shell
1472
- // phase's static App Shell attempt, whose entries are keyed at the shell
1522
+ // phase's static shell attempt, whose entries are keyed at the shell
1473
1523
  // vary paths.
1474
1524
  fetchStrategy, // False when finishing a chain on a runtime-prefetch bailout; see
1475
1525
  // pingSegmentBundle.
1476
1526
  spawnRevalidations) {
1477
1527
  // Prefetching is disabled for this segment (prefetch: 'force-disabled'):
1478
- // the server emits null for its slot, and it participates in the bundle
1479
- // chain with null tree/entry so the null-slot positions line up.
1528
+ // the server emits identity only for its response node, and it
1529
+ // participates in the bundle chain with null tree/entry — no cache entry
1530
+ // is created for it.
1480
1531
  // (Partial Prefetching segments are NOT in this mask — the server emits
1481
1532
  // static data for them unconditionally.) Intentionally not gated by the
1482
1533
  // prefetch inlining flag: we never statically prefetch unprefetchable
@@ -1495,7 +1546,7 @@ spawnRevalidations) {
1495
1546
  if (process.env.__NEXT_PREFETCH_INLINING && tree.prefetchHints & _approutertypes.PrefetchHint.InlinedIntoChild) {
1496
1547
  if (segment.status === _cache.EntryStatus.Pending) {
1497
1548
  // The chain this entry joins may be dropped before it's ever pinged
1498
- // (see the drop sites in pingNewPartOfCacheComponentsTree), and only
1549
+ // (see the drop sites in pingSegmentInCacheComponentsTree), and only
1499
1550
  // the ping blocks on Pending entries. Register on the in-flight
1500
1551
  // response at read time instead, so the pass observes it before the
1501
1552
  // phase can complete even if the chain is dropped. When the chain does
@@ -1513,8 +1564,12 @@ spawnRevalidations) {
1513
1564
  // ping only reaches the terminal descendant, and if that descendant is
1514
1565
  // itself a decision point it consumes the signal for its own subtree,
1515
1566
  // leaving this ancestor's insufficiency invisible to the decision
1516
- // point above it.
1517
- needsRuntimeRequest: segment.status === _cache.EntryStatus.Fulfilled && wouldRuntimeRequestProvideMore(segment, fetchStrategy)
1567
+ // point above it. An eligible shell-tier entry withholds the signal,
1568
+ // the same exception the bundle ping applies: deopting here would
1569
+ // pre-empt the static attempt the chain ping spawns for this node when
1570
+ // it reaches the terminal descendant (its Fulfilled case runs for
1571
+ // every node in the chain).
1572
+ needsRuntimeRequest: segment.status === _cache.EntryStatus.Fulfilled && wouldRuntimeRequestProvideMore(segment, fetchStrategy) && !isShellEntryEligibleForStaticAttempt(now, task.segmentCacheMap, segment, tree, fetchStrategy)
1518
1573
  };
1519
1574
  }
1520
1575
  // Not bundled. Build a single-node bundle and ping it. If this page
@@ -1523,8 +1578,8 @@ spawnRevalidations) {
1523
1578
  let effectiveParent = parentBundle;
1524
1579
  if (process.env.__NEXT_PREFETCH_INLINING && tree.prefetchHints & _approutertypes.PrefetchHint.HeadInlinedIntoSelf) {
1525
1580
  effectiveParent = {
1526
- tree: route.metadata,
1527
- entry: (0, _cache.readOrCreateSegmentCacheEntry)(now, task.segmentCacheMap, fetchStrategy, route.metadata),
1581
+ tree: route.root.head,
1582
+ entry: (0, _cache.readOrCreateSegmentCacheEntry)(now, task.segmentCacheMap, fetchStrategy, route.root.head),
1528
1583
  parent: parentBundle
1529
1584
  };
1530
1585
  }
@@ -1562,14 +1617,14 @@ fetchStrategy) {
1562
1617
  function pingFullSegmentRevalidation(now, task, tree, fetchStrategy) {
1563
1618
  const revalidatingSegment = (0, _cache.readOrCreateRevalidatingSegmentEntry)(now, task.segmentCacheMap, fetchStrategy, tree);
1564
1619
  if (revalidatingSegment.status === _cache.EntryStatus.Empty) {
1565
- // During a Full/PPRRuntime prefetch, a single dynamic request is made for all the
1566
- // segments that we need. So we don't initiate a request here directly. By
1567
- // returning a pending entry from this function, it signals to the caller
1568
- // that this segment should be included in the request that's sent to
1569
- // the server.
1620
+ // During a Full/PPRRuntime prefetch, a single runtime request is made for
1621
+ // all the segments that we need. So we don't initiate a request here
1622
+ // directly. By returning a pending entry from this function, it signals
1623
+ // to the caller that this segment should be included in the request
1624
+ // that's sent to the server.
1570
1625
  const pendingSegment = (0, _cache.upgradeToPendingSegment)(revalidatingSegment, fetchStrategy);
1571
- // The upsert is handled by fulfillEntrySpawnedByRuntimePrefetch
1572
- // when the dynamic prefetch response is written into the cache.
1626
+ // The upsert is handled by writeSegmentDataIntoCache
1627
+ // when the runtime request's response is written into the cache.
1573
1628
  return pendingSegment;
1574
1629
  } else {
1575
1630
  // There's already a revalidation in progress.
@@ -1579,8 +1634,8 @@ function pingFullSegmentRevalidation(now, task, tree, fetchStrategy) {
1579
1634
  // Reset it and start a new revalidation.
1580
1635
  const emptySegment = (0, _cache.overwriteRevalidatingSegmentCacheEntry)(now, task.segmentCacheMap, fetchStrategy, tree);
1581
1636
  const pendingSegment = (0, _cache.upgradeToPendingSegment)(emptySegment, fetchStrategy);
1582
- // The upsert is handled by fulfillEntrySpawnedByRuntimePrefetch
1583
- // when the dynamic prefetch response is written into the cache.
1637
+ // The upsert is handled by writeSegmentDataIntoCache
1638
+ // when the runtime request's response is written into the cache.
1584
1639
  return pendingSegment;
1585
1640
  }
1586
1641
  switch(nonEmptyRevalidatingSegment.status){
@@ -1602,30 +1657,14 @@ function pingFullSegmentRevalidation(now, task, tree, fetchStrategy) {
1602
1657
  }
1603
1658
  }
1604
1659
  }
1605
- function doesCurrentSegmentMatchCachedSegment(route, currentSegment, cachedSegment) {
1606
- if (cachedSegment === _segment.PAGE_SEGMENT_KEY) {
1607
- // In the FlightRouterState stored by the router, the page segment has the
1608
- // rendered search params appended to the name of the segment. In the
1609
- // prefetch cache, however, this is stored separately. So, when comparing
1610
- // the router's current FlightRouterState to the cached FlightRouterState,
1611
- // we need to make sure we compare both parts of the segment.
1612
- // TODO: This is not modeled clearly. We use the same type,
1613
- // FlightRouterState, for both the CacheNode tree _and_ the prefetch cache
1614
- // _and_ the server response format, when conceptually those are three
1615
- // different things and treated in different ways. We should encode more of
1616
- // this information into the type design so mistakes are less likely.
1617
- return currentSegment === (0, _segment.addSearchParamsIfPageSegment)(_segment.PAGE_SEGMENT_KEY, (0, _routeparams.urlSearchParamsToParsedUrlQuery)(new URLSearchParams(route.renderedSearch)));
1660
+ function needsSpeculativePrefetch(taskfetchStrategy, rootPrefetchHints) {
1661
+ if ((rootPrefetchHints & _approutertypes.PrefetchHint.SubtreeHasPartialPrefetching) !== 0) {
1662
+ // PPF - only needs a speculative prefetch if this is a `<Link prefetch={true}>`.
1663
+ return taskfetchStrategy === _types.FetchStrategy.Full;
1664
+ } else {
1665
+ // non-PPF -- all prefetches are speculative.
1666
+ return true;
1618
1667
  }
1619
- // Non-page segments are compared using the same function as the server
1620
- return (0, _matchsegments.matchSegment)(cachedSegment, currentSegment);
1621
- }
1622
- function subtreeHasSpeculativePrefetch(fetchStrategy, prefetchHints) {
1623
- return(// Check if this is a "full" prefetch (<Link prefetch={true}>).
1624
- fetchStrategy === _types.FetchStrategy.Full || // Check if something in this subtree is configured to be eagerly
1625
- // prefetched at the route level. Segments that don't opt into Partial
1626
- // Prefetching are marked eager, so a route without any Partial Prefetching
1627
- // still speculatively prefetches everything.
1628
- (prefetchHints & _approutertypes.PrefetchHint.SubtreeHasEagerPrefetch) !== 0);
1629
1668
  }
1630
1669
  // -----------------------------------------------------------------------------
1631
1670
  // The remainder of the module is a MinHeap implementation. Try not to put any