@surething/cockpit 1.1.8 → 1.1.9

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 (598) hide show
  1. package/.next-prod/BUILD_ID +1 -1
  2. package/.next-prod/app-path-routes-manifest.json +9 -5
  3. package/.next-prod/build-manifest.json +2 -2
  4. package/.next-prod/cockpit-build.json +1 -1
  5. package/.next-prod/prerender-manifest.json +3 -3
  6. package/.next-prod/routes-manifest.json +24 -0
  7. package/.next-prod/server/app/_global-error/page.js +2 -2
  8. package/.next-prod/server/app/_global-error/page_client-reference-manifest.js +1 -1
  9. package/.next-prod/server/app/_global-error.html +1 -1
  10. package/.next-prod/server/app/_global-error.rsc +1 -1
  11. package/.next-prod/server/app/_global-error.segments/_full.segment.rsc +1 -1
  12. package/.next-prod/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  13. package/.next-prod/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  14. package/.next-prod/server/app/_not-found/page.js +1 -1
  15. package/.next-prod/server/app/_not-found/page_client-reference-manifest.js +1 -1
  16. package/.next-prod/server/app/api/agent/test/route.js +1 -1
  17. package/.next-prod/server/app/api/bash/route.js +1 -1
  18. package/.next-prod/server/app/api/bots/[id]/route.js +1 -1
  19. package/.next-prod/server/app/api/bots/files/route.js +1 -1
  20. package/.next-prod/server/app/api/bots/route.js +1 -1
  21. package/.next-prod/server/app/api/chat/codex/route.js +1 -1
  22. package/.next-prod/server/app/api/chat/deepseek/route.js +1 -1
  23. package/.next-prod/server/app/api/chat/glm/route.js +1 -1
  24. package/.next-prod/server/app/api/chat/grok/route.js +1 -1
  25. package/.next-prod/server/app/api/chat/kimi/route.js +1 -1
  26. package/.next-prod/server/app/api/chat/ollama/route.js +1 -1
  27. package/.next-prod/server/app/api/chat/route.js +1 -1
  28. package/.next-prod/server/app/api/chat/stop/route.js +1 -1
  29. package/.next-prod/server/app/api/claude-stats/route.js +1 -1
  30. package/.next-prod/server/app/api/commands/route.js +1 -1
  31. package/.next-prod/server/app/api/comments/route.js +1 -1
  32. package/.next-prod/server/app/api/db/columns/route.js +1 -1
  33. package/.next-prod/server/app/api/db/connect/route.js +1 -1
  34. package/.next-prod/server/app/api/db/disconnect/route.js +1 -1
  35. package/.next-prod/server/app/api/db/export/route.js +1 -1
  36. package/.next-prod/server/app/api/db/query/route.js +1 -1
  37. package/.next-prod/server/app/api/db/schemas/route.js +2 -2
  38. package/.next-prod/server/app/api/deepseek/balance/route.js +1 -1
  39. package/.next-prod/server/app/api/deepseek/credentials/route.js +1 -1
  40. package/.next-prod/server/app/api/deepseek/models/route.js +1 -1
  41. package/.next-prod/server/app/api/dev/spans/route.js +1 -1
  42. package/.next-prod/server/app/api/extension/version/route.js +1 -1
  43. package/.next-prod/server/app/api/file/route.js +1 -1
  44. package/.next-prod/server/app/api/files/blame/route.js +1 -1
  45. package/.next-prod/server/app/api/files/clipboard/route.js +1 -1
  46. package/.next-prod/server/app/api/files/copy/route.js +1 -1
  47. package/.next-prod/server/app/api/files/delete/route.js +1 -1
  48. package/.next-prod/server/app/api/files/expanded/route.js +1 -1
  49. package/.next-prod/server/app/api/files/index/route.js +1 -1
  50. package/.next-prod/server/app/api/files/init/route.js +1 -1
  51. package/.next-prod/server/app/api/files/paste/route.js +1 -1
  52. package/.next-prod/server/app/api/files/read/route.js +1 -1
  53. package/.next-prod/server/app/api/files/readdir/route.js +1 -1
  54. package/.next-prod/server/app/api/files/recent/route.js +1 -1
  55. package/.next-prod/server/app/api/files/save/route.js +1 -1
  56. package/.next-prod/server/app/api/files/search/route.js +1 -1
  57. package/.next-prod/server/app/api/files/stat/route.js +1 -1
  58. package/.next-prod/server/app/api/files/text/route.js +1 -1
  59. package/.next-prod/server/app/api/fs/dirs/route.js +1 -1
  60. package/.next-prod/server/app/api/git/blob/route.js +1 -1
  61. package/.next-prod/server/app/api/git/branch-diff/route.js +1 -1
  62. package/.next-prod/server/app/api/git/branches/route.js +1 -1
  63. package/.next-prod/server/app/api/git/commit-diff/route.js +1 -1
  64. package/.next-prod/server/app/api/git/commits/route.js +1 -1
  65. package/.next-prod/server/app/api/git/current-branch/route.js +1 -1
  66. package/.next-prod/server/app/api/git/diff/route.js +1 -1
  67. package/.next-prod/server/app/api/git/discard/route.js +1 -1
  68. package/.next-prod/server/app/api/git/stage/route.js +1 -1
  69. package/.next-prod/server/app/api/git/status/route.js +1 -1
  70. package/.next-prod/server/app/api/git/unstage/route.js +1 -1
  71. package/.next-prod/server/app/api/git/worktree/route.js +1 -1
  72. package/.next-prod/server/app/api/glm/credentials/route.js +1 -1
  73. package/.next-prod/server/app/api/glm/models/route.js +1 -1
  74. package/.next-prod/server/app/api/glm/usage/route.js +1 -1
  75. package/.next-prod/server/app/api/global-state/route.js +2 -2
  76. package/.next-prod/server/app/api/grok/models/route.js +1 -1
  77. package/.next-prod/server/app/api/health/route.js +1 -1
  78. package/.next-prod/server/app/api/html-apps/[id]/route.js +1 -1
  79. package/.next-prod/server/app/api/html-apps/files/route.js +1 -1
  80. package/.next-prod/server/app/api/html-apps/route.js +1 -1
  81. package/.next-prod/server/app/api/instructions/config/route.js +1 -1
  82. package/.next-prod/server/app/api/kimi/credentials/route.js +1 -1
  83. package/.next-prod/server/app/api/kimi/models/route.js +1 -1
  84. package/.next-prod/server/app/api/kimi/usage/route.js +1 -1
  85. package/.next-prod/server/app/api/lsp/definition/route.js +1 -1
  86. package/.next-prod/server/app/api/lsp/hover/route.js +1 -1
  87. package/.next-prod/server/app/api/lsp/references/route.js +1 -1
  88. package/.next-prod/server/app/api/lsp/status/route.js +1 -1
  89. package/.next-prod/server/app/api/lsp/warmup/route.js +1 -1
  90. package/.next-prod/server/app/api/mobile-link/route.js +1 -1
  91. package/.next-prod/server/app/api/mysql/columns/route.js +2 -2
  92. package/.next-prod/server/app/api/mysql/connect/route.js +1 -1
  93. package/.next-prod/server/app/api/mysql/disconnect/route.js +1 -1
  94. package/.next-prod/server/app/api/mysql/export/route.js +1 -1
  95. package/.next-prod/server/app/api/mysql/query/route.js +1 -1
  96. package/.next-prod/server/app/api/mysql/schemas/route.js +2 -2
  97. package/.next-prod/server/app/api/neo4j/connect/route.js +1 -1
  98. package/.next-prod/server/app/api/neo4j/disconnect/route.js +1 -1
  99. package/.next-prod/server/app/api/neo4j/query/route.js +1 -1
  100. package/.next-prod/server/app/api/neo4j/schema/route.js +1 -1
  101. package/.next-prod/server/app/api/note/list/route.js +1 -1
  102. package/.next-prod/server/app/api/note/route.js +1 -1
  103. package/.next-prod/server/app/api/ollama/config/route.js +1 -1
  104. package/.next-prod/server/app/api/ollama/default-model/route.js +1 -1
  105. package/.next-prod/server/app/api/ollama/models/route.js +1 -1
  106. package/.next-prod/server/app/api/ollama/start/route.js +1 -1
  107. package/.next-prod/server/app/api/open-cursor/route.js +1 -1
  108. package/.next-prod/server/app/api/open-vscode/route.js +1 -1
  109. package/.next-prod/server/app/api/pi/thinking/route.js +1 -1
  110. package/.next-prod/server/app/api/pinned-sessions/route.js +1 -1
  111. package/.next-prod/server/app/api/project-settings/route.js +1 -1
  112. package/.next-prod/server/app/api/project-state/route.js +2 -2
  113. package/.next-prod/server/app/api/projectGraph/affected/route.js +1 -1
  114. package/.next-prod/server/app/api/projectGraph/callees/route.js +1 -1
  115. package/.next-prod/server/app/api/projectGraph/callers/route.js +1 -1
  116. package/.next-prod/server/app/api/projectGraph/coedit/route.js +1 -1
  117. package/.next-prod/server/app/api/projectGraph/edges/route.js +1 -0
  118. package/.next-prod/server/app/api/projectGraph/edges/route.js.nft.json +1 -0
  119. package/.next-prod/server/app/api/projectGraph/edges/route_client-reference-manifest.js +1 -0
  120. package/.next-prod/server/app/api/projectGraph/file/route.js +1 -1
  121. package/.next-prod/server/app/api/projectGraph/file-functions/route.js +1 -1
  122. package/.next-prod/server/app/api/projectGraph/impact/route.js +1 -1
  123. package/.next-prod/server/app/api/projectGraph/maps/route.js +1 -0
  124. package/.next-prod/server/app/api/projectGraph/maps/route.js.nft.json +1 -0
  125. package/.next-prod/server/app/api/projectGraph/maps/route_client-reference-manifest.js +1 -0
  126. package/.next-prod/server/app/api/projectGraph/related/route.js +1 -1
  127. package/.next-prod/server/app/api/projectGraph/search/route.js +1 -1
  128. package/.next-prod/server/app/api/projectGraph/symbols/route.js +1 -1
  129. package/.next-prod/server/app/api/projects/route.js +1 -1
  130. package/.next-prod/server/app/api/push/public-key/route.js +1 -1
  131. package/.next-prod/server/app/api/push/subscribe/route.js +1 -1
  132. package/.next-prod/server/app/api/push/unsubscribe/route.js +1 -1
  133. package/.next-prod/server/app/api/redis/command/route.js +1 -1
  134. package/.next-prod/server/app/api/redis/connect/route.js +1 -1
  135. package/.next-prod/server/app/api/redis/delete/route.js +1 -1
  136. package/.next-prod/server/app/api/redis/disconnect/route.js +1 -1
  137. package/.next-prod/server/app/api/redis/get/route.js +1 -1
  138. package/.next-prod/server/app/api/redis/keys/route.js +1 -1
  139. package/.next-prod/server/app/api/redis/set/route.js +1 -1
  140. package/.next-prod/server/app/api/restart/route.js +1 -1
  141. package/.next-prod/server/app/api/scheduled-tasks/route.js +2 -2
  142. package/.next-prod/server/app/api/services/config/route.js +1 -1
  143. package/.next-prod/server/app/api/services/scripts/route.js +1 -1
  144. package/.next-prod/server/app/api/session/[sessionId]/fork/route.js +1 -1
  145. package/.next-prod/server/app/api/session/[sessionId]/history/route.js +1 -1
  146. package/.next-prod/server/app/api/session/[sessionId]/turn/route.js +2 -2
  147. package/.next-prod/server/app/api/session/image/route.js +1 -1
  148. package/.next-prod/server/app/api/session/user-messages/route.js +1 -1
  149. package/.next-prod/server/app/api/session-bots/route.js +1 -1
  150. package/.next-prod/server/app/api/session-by-path/route.js +1 -1
  151. package/.next-prod/server/app/api/session-context/route.js +2 -2
  152. package/.next-prod/server/app/api/session-title/route.js +1 -1
  153. package/.next-prod/server/app/api/session-title/suggest/route.js +1 -1
  154. package/.next-prod/server/app/api/sessions/delegate/route.js +1 -1
  155. package/.next-prod/server/app/api/sessions/projects/[encodedPath]/route.js +1 -1
  156. package/.next-prod/server/app/api/sessions/projects/route.js +1 -1
  157. package/.next-prod/server/app/api/sessions/search/route.js +1 -1
  158. package/.next-prod/server/app/api/sessions/status/route.js +1 -1
  159. package/.next-prod/server/app/api/settings/route.js +1 -1
  160. package/.next-prod/server/app/api/shutdown/route.js +1 -1
  161. package/.next-prod/server/app/api/skills/[id]/route.js +1 -1
  162. package/.next-prod/server/app/api/skills/builtin/route.js +1 -1
  163. package/.next-prod/server/app/api/skills/content/route.js +1 -1
  164. package/.next-prod/server/app/api/skills/files/route.js +1 -1
  165. package/.next-prod/server/app/api/skills/route.js +1 -1
  166. package/.next-prod/server/app/api/snapshots/blob/route.js +1 -1
  167. package/.next-prod/server/app/api/snapshots/diff/route.js +1 -1
  168. package/.next-prod/server/app/api/snapshots/mark/route.js +1 -0
  169. package/.next-prod/server/app/api/snapshots/mark/route.js.nft.json +1 -0
  170. package/.next-prod/server/app/api/snapshots/mark/route_client-reference-manifest.js +1 -0
  171. package/.next-prod/server/app/api/snapshots/range-diff/route.js +1 -1
  172. package/.next-prod/server/app/api/snapshots/restore/route.js +1 -0
  173. package/.next-prod/server/app/api/snapshots/restore/route.js.nft.json +1 -0
  174. package/.next-prod/server/app/api/snapshots/restore/route_client-reference-manifest.js +1 -0
  175. package/.next-prod/server/app/api/snapshots/route.js +1 -1
  176. package/.next-prod/server/app/api/terminal/aliases/route.js +1 -1
  177. package/.next-prod/server/app/api/terminal/autocomplete/route.js +1 -1
  178. package/.next-prod/server/app/api/terminal/bubble-order/route.js +1 -1
  179. package/.next-prod/server/app/api/terminal/env/route.js +1 -1
  180. package/.next-prod/server/app/api/terminal/history/route.js +1 -1
  181. package/.next-prod/server/app/api/terminal/running/route.js +1 -1
  182. package/.next-prod/server/app/api/update/route.js +1 -1
  183. package/.next-prod/server/app/api/update-state/route.js +1 -1
  184. package/.next-prod/server/app/api/version/route.js +1 -1
  185. package/.next-prod/server/app/apps/[...path]/route.js +1 -1
  186. package/.next-prod/server/app/favicon.ico/route.js +1 -1
  187. package/.next-prod/server/app/m/page.js +2 -1
  188. package/.next-prod/server/app/m/page_client-reference-manifest.js +1 -1
  189. package/.next-prod/server/app/manifest.webmanifest/route.js +1 -1
  190. package/.next-prod/server/app/page.js +1 -1
  191. package/.next-prod/server/app/page_client-reference-manifest.js +1 -1
  192. package/.next-prod/server/app/project/page.js +1 -1
  193. package/.next-prod/server/app/project/page_client-reference-manifest.js +1 -1
  194. package/.next-prod/server/app-paths-manifest.json +9 -5
  195. package/.next-prod/server/chunks/2493.js +13 -13
  196. package/.next-prod/server/chunks/4949.js +1 -1
  197. package/.next-prod/server/chunks/6610.js +34 -34
  198. package/.next-prod/server/chunks/7270.js +1 -1
  199. package/.next-prod/server/chunks/9830.js +2 -2
  200. package/.next-prod/server/chunks/9998.js +1 -1
  201. package/.next-prod/server/middleware-build-manifest.js +1 -1
  202. package/.next-prod/server/next-font-manifest.js +1 -1
  203. package/.next-prod/server/next-font-manifest.json +1 -1
  204. package/.next-prod/server/pages/500.html +1 -1
  205. package/.next-prod/server/server-reference-manifest.json +1 -1
  206. package/.next-prod/static/LwAYWBEgXwTIkuj7U9BpE/_buildManifest.js +1 -0
  207. package/.next-prod/static/chunks/{50189-b59a96372658a46a.js → 55541-994b26deaa23f4e6.js} +2 -2
  208. package/.next-prod/static/chunks/{731-fd4b8bcd1d40dfe9.js → 6837-78c0d1a8165d46f7.js} +21 -21
  209. package/.next-prod/static/chunks/92000-46024df89fb50e16.js +41 -0
  210. package/.next-prod/static/chunks/98596-4ca2d2544138aefd.js +733 -0
  211. package/.next-prod/static/chunks/app/_global-error/page-6af5bc188af96106.js +1 -0
  212. package/.next-prod/static/chunks/app/api/agent/test/route-6af5bc188af96106.js +1 -0
  213. package/.next-prod/static/chunks/app/api/bash/route-6af5bc188af96106.js +1 -0
  214. package/.next-prod/static/chunks/app/api/bots/[id]/route-6af5bc188af96106.js +1 -0
  215. package/.next-prod/static/chunks/app/api/bots/files/route-6af5bc188af96106.js +1 -0
  216. package/.next-prod/static/chunks/app/api/bots/route-6af5bc188af96106.js +1 -0
  217. package/.next-prod/static/chunks/app/api/chat/codex/route-6af5bc188af96106.js +1 -0
  218. package/.next-prod/static/chunks/app/api/chat/deepseek/route-6af5bc188af96106.js +1 -0
  219. package/.next-prod/static/chunks/app/api/chat/glm/route-6af5bc188af96106.js +1 -0
  220. package/.next-prod/static/chunks/app/api/chat/grok/route-6af5bc188af96106.js +1 -0
  221. package/.next-prod/static/chunks/app/api/chat/kimi/route-6af5bc188af96106.js +1 -0
  222. package/.next-prod/static/chunks/app/api/chat/ollama/route-6af5bc188af96106.js +1 -0
  223. package/.next-prod/static/chunks/app/api/chat/route-6af5bc188af96106.js +1 -0
  224. package/.next-prod/static/chunks/app/api/chat/stop/route-6af5bc188af96106.js +1 -0
  225. package/.next-prod/static/chunks/app/api/claude-stats/route-6af5bc188af96106.js +1 -0
  226. package/.next-prod/static/chunks/app/api/commands/route-6af5bc188af96106.js +1 -0
  227. package/.next-prod/static/chunks/app/api/comments/route-6af5bc188af96106.js +1 -0
  228. package/.next-prod/static/chunks/app/api/db/columns/route-6af5bc188af96106.js +1 -0
  229. package/.next-prod/static/chunks/app/api/db/connect/route-6af5bc188af96106.js +1 -0
  230. package/.next-prod/static/chunks/app/api/db/disconnect/route-6af5bc188af96106.js +1 -0
  231. package/.next-prod/static/chunks/app/api/db/export/route-6af5bc188af96106.js +1 -0
  232. package/.next-prod/static/chunks/app/api/db/query/route-6af5bc188af96106.js +1 -0
  233. package/.next-prod/static/chunks/app/api/db/schemas/route-6af5bc188af96106.js +1 -0
  234. package/.next-prod/static/chunks/app/api/deepseek/balance/route-6af5bc188af96106.js +1 -0
  235. package/.next-prod/static/chunks/app/api/deepseek/credentials/route-6af5bc188af96106.js +1 -0
  236. package/.next-prod/static/chunks/app/api/deepseek/models/route-6af5bc188af96106.js +1 -0
  237. package/.next-prod/static/chunks/app/api/dev/spans/route-6af5bc188af96106.js +1 -0
  238. package/.next-prod/static/chunks/app/api/extension/version/route-6af5bc188af96106.js +1 -0
  239. package/.next-prod/static/chunks/app/api/file/route-6af5bc188af96106.js +1 -0
  240. package/.next-prod/static/chunks/app/api/files/blame/route-6af5bc188af96106.js +1 -0
  241. package/.next-prod/static/chunks/app/api/files/clipboard/route-6af5bc188af96106.js +1 -0
  242. package/.next-prod/static/chunks/app/api/files/copy/route-6af5bc188af96106.js +1 -0
  243. package/.next-prod/static/chunks/app/api/files/delete/route-6af5bc188af96106.js +1 -0
  244. package/.next-prod/static/chunks/app/api/files/expanded/route-6af5bc188af96106.js +1 -0
  245. package/.next-prod/static/chunks/app/api/files/index/route-6af5bc188af96106.js +1 -0
  246. package/.next-prod/static/chunks/app/api/files/init/route-6af5bc188af96106.js +1 -0
  247. package/.next-prod/static/chunks/app/api/files/paste/route-6af5bc188af96106.js +1 -0
  248. package/.next-prod/static/chunks/app/api/files/read/route-6af5bc188af96106.js +1 -0
  249. package/.next-prod/static/chunks/app/api/files/readdir/route-6af5bc188af96106.js +1 -0
  250. package/.next-prod/static/chunks/app/api/files/recent/route-6af5bc188af96106.js +1 -0
  251. package/.next-prod/static/chunks/app/api/files/save/route-6af5bc188af96106.js +1 -0
  252. package/.next-prod/static/chunks/app/api/files/search/route-6af5bc188af96106.js +1 -0
  253. package/.next-prod/static/chunks/app/api/files/stat/route-6af5bc188af96106.js +1 -0
  254. package/.next-prod/static/chunks/app/api/files/text/route-6af5bc188af96106.js +1 -0
  255. package/.next-prod/static/chunks/app/api/fs/dirs/route-6af5bc188af96106.js +1 -0
  256. package/.next-prod/static/chunks/app/api/git/blob/route-6af5bc188af96106.js +1 -0
  257. package/.next-prod/static/chunks/app/api/git/branch-diff/route-6af5bc188af96106.js +1 -0
  258. package/.next-prod/static/chunks/app/api/git/branches/route-6af5bc188af96106.js +1 -0
  259. package/.next-prod/static/chunks/app/api/git/commit-diff/route-6af5bc188af96106.js +1 -0
  260. package/.next-prod/static/chunks/app/api/git/commits/route-6af5bc188af96106.js +1 -0
  261. package/.next-prod/static/chunks/app/api/git/current-branch/route-6af5bc188af96106.js +1 -0
  262. package/.next-prod/static/chunks/app/api/git/diff/route-6af5bc188af96106.js +1 -0
  263. package/.next-prod/static/chunks/app/api/git/discard/route-6af5bc188af96106.js +1 -0
  264. package/.next-prod/static/chunks/app/api/git/stage/route-6af5bc188af96106.js +1 -0
  265. package/.next-prod/static/chunks/app/api/git/status/route-6af5bc188af96106.js +1 -0
  266. package/.next-prod/static/chunks/app/api/git/unstage/route-6af5bc188af96106.js +1 -0
  267. package/.next-prod/static/chunks/app/api/git/worktree/route-6af5bc188af96106.js +1 -0
  268. package/.next-prod/static/chunks/app/api/glm/credentials/route-6af5bc188af96106.js +1 -0
  269. package/.next-prod/static/chunks/app/api/glm/models/route-6af5bc188af96106.js +1 -0
  270. package/.next-prod/static/chunks/app/api/glm/usage/route-6af5bc188af96106.js +1 -0
  271. package/.next-prod/static/chunks/app/api/global-state/route-6af5bc188af96106.js +1 -0
  272. package/.next-prod/static/chunks/app/api/grok/models/route-6af5bc188af96106.js +1 -0
  273. package/.next-prod/static/chunks/app/api/health/route-6af5bc188af96106.js +1 -0
  274. package/.next-prod/static/chunks/app/api/html-apps/[id]/route-6af5bc188af96106.js +1 -0
  275. package/.next-prod/static/chunks/app/api/html-apps/files/route-6af5bc188af96106.js +1 -0
  276. package/.next-prod/static/chunks/app/api/html-apps/route-6af5bc188af96106.js +1 -0
  277. package/.next-prod/static/chunks/app/api/instructions/config/route-6af5bc188af96106.js +1 -0
  278. package/.next-prod/static/chunks/app/api/kimi/credentials/route-6af5bc188af96106.js +1 -0
  279. package/.next-prod/static/chunks/app/api/kimi/models/route-6af5bc188af96106.js +1 -0
  280. package/.next-prod/static/chunks/app/api/kimi/usage/route-6af5bc188af96106.js +1 -0
  281. package/.next-prod/static/chunks/app/api/lsp/definition/route-6af5bc188af96106.js +1 -0
  282. package/.next-prod/static/chunks/app/api/lsp/hover/route-6af5bc188af96106.js +1 -0
  283. package/.next-prod/static/chunks/app/api/lsp/references/route-6af5bc188af96106.js +1 -0
  284. package/.next-prod/static/chunks/app/api/lsp/status/route-6af5bc188af96106.js +1 -0
  285. package/.next-prod/static/chunks/app/api/lsp/warmup/route-6af5bc188af96106.js +1 -0
  286. package/.next-prod/static/chunks/app/api/mobile-link/route-6af5bc188af96106.js +1 -0
  287. package/.next-prod/static/chunks/app/api/mysql/columns/route-6af5bc188af96106.js +1 -0
  288. package/.next-prod/static/chunks/app/api/mysql/connect/route-6af5bc188af96106.js +1 -0
  289. package/.next-prod/static/chunks/app/api/mysql/disconnect/route-6af5bc188af96106.js +1 -0
  290. package/.next-prod/static/chunks/app/api/mysql/export/route-6af5bc188af96106.js +1 -0
  291. package/.next-prod/static/chunks/app/api/mysql/query/route-6af5bc188af96106.js +1 -0
  292. package/.next-prod/static/chunks/app/api/mysql/schemas/route-6af5bc188af96106.js +1 -0
  293. package/.next-prod/static/chunks/app/api/neo4j/connect/route-6af5bc188af96106.js +1 -0
  294. package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-6af5bc188af96106.js +1 -0
  295. package/.next-prod/static/chunks/app/api/neo4j/query/route-6af5bc188af96106.js +1 -0
  296. package/.next-prod/static/chunks/app/api/neo4j/schema/route-6af5bc188af96106.js +1 -0
  297. package/.next-prod/static/chunks/app/api/note/list/route-6af5bc188af96106.js +1 -0
  298. package/.next-prod/static/chunks/app/api/note/route-6af5bc188af96106.js +1 -0
  299. package/.next-prod/static/chunks/app/api/ollama/config/route-6af5bc188af96106.js +1 -0
  300. package/.next-prod/static/chunks/app/api/ollama/default-model/route-6af5bc188af96106.js +1 -0
  301. package/.next-prod/static/chunks/app/api/ollama/models/route-6af5bc188af96106.js +1 -0
  302. package/.next-prod/static/chunks/app/api/ollama/start/route-6af5bc188af96106.js +1 -0
  303. package/.next-prod/static/chunks/app/api/open-cursor/route-6af5bc188af96106.js +1 -0
  304. package/.next-prod/static/chunks/app/api/open-vscode/route-6af5bc188af96106.js +1 -0
  305. package/.next-prod/static/chunks/app/api/pi/thinking/route-6af5bc188af96106.js +1 -0
  306. package/.next-prod/static/chunks/app/api/pinned-sessions/route-6af5bc188af96106.js +1 -0
  307. package/.next-prod/static/chunks/app/api/project-settings/route-6af5bc188af96106.js +1 -0
  308. package/.next-prod/static/chunks/app/api/project-state/route-6af5bc188af96106.js +1 -0
  309. package/.next-prod/static/chunks/app/api/projectGraph/affected/route-6af5bc188af96106.js +1 -0
  310. package/.next-prod/static/chunks/app/api/projectGraph/callees/route-6af5bc188af96106.js +1 -0
  311. package/.next-prod/static/chunks/app/api/projectGraph/callers/route-6af5bc188af96106.js +1 -0
  312. package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-6af5bc188af96106.js +1 -0
  313. package/.next-prod/static/chunks/app/api/projectGraph/edges/route-6af5bc188af96106.js +1 -0
  314. package/.next-prod/static/chunks/app/api/projectGraph/file/route-6af5bc188af96106.js +1 -0
  315. package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-6af5bc188af96106.js +1 -0
  316. package/.next-prod/static/chunks/app/api/projectGraph/impact/route-6af5bc188af96106.js +1 -0
  317. package/.next-prod/static/chunks/app/api/projectGraph/maps/route-6af5bc188af96106.js +1 -0
  318. package/.next-prod/static/chunks/app/api/projectGraph/related/route-6af5bc188af96106.js +1 -0
  319. package/.next-prod/static/chunks/app/api/projectGraph/search/route-6af5bc188af96106.js +1 -0
  320. package/.next-prod/static/chunks/app/api/projectGraph/symbols/route-6af5bc188af96106.js +1 -0
  321. package/.next-prod/static/chunks/app/api/projects/route-6af5bc188af96106.js +1 -0
  322. package/.next-prod/static/chunks/app/api/push/public-key/route-6af5bc188af96106.js +1 -0
  323. package/.next-prod/static/chunks/app/api/push/subscribe/route-6af5bc188af96106.js +1 -0
  324. package/.next-prod/static/chunks/app/api/push/unsubscribe/route-6af5bc188af96106.js +1 -0
  325. package/.next-prod/static/chunks/app/api/redis/command/route-6af5bc188af96106.js +1 -0
  326. package/.next-prod/static/chunks/app/api/redis/connect/route-6af5bc188af96106.js +1 -0
  327. package/.next-prod/static/chunks/app/api/redis/delete/route-6af5bc188af96106.js +1 -0
  328. package/.next-prod/static/chunks/app/api/redis/disconnect/route-6af5bc188af96106.js +1 -0
  329. package/.next-prod/static/chunks/app/api/redis/get/route-6af5bc188af96106.js +1 -0
  330. package/.next-prod/static/chunks/app/api/redis/keys/route-6af5bc188af96106.js +1 -0
  331. package/.next-prod/static/chunks/app/api/redis/set/route-6af5bc188af96106.js +1 -0
  332. package/.next-prod/static/chunks/app/api/restart/route-6af5bc188af96106.js +1 -0
  333. package/.next-prod/static/chunks/app/api/scheduled-tasks/route-6af5bc188af96106.js +1 -0
  334. package/.next-prod/static/chunks/app/api/services/config/route-6af5bc188af96106.js +1 -0
  335. package/.next-prod/static/chunks/app/api/services/scripts/route-6af5bc188af96106.js +1 -0
  336. package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-6af5bc188af96106.js +1 -0
  337. package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-6af5bc188af96106.js +1 -0
  338. package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-6af5bc188af96106.js +1 -0
  339. package/.next-prod/static/chunks/app/api/session/image/route-6af5bc188af96106.js +1 -0
  340. package/.next-prod/static/chunks/app/api/session/user-messages/route-6af5bc188af96106.js +1 -0
  341. package/.next-prod/static/chunks/app/api/session-bots/route-6af5bc188af96106.js +1 -0
  342. package/.next-prod/static/chunks/app/api/session-by-path/route-6af5bc188af96106.js +1 -0
  343. package/.next-prod/static/chunks/app/api/session-context/route-6af5bc188af96106.js +1 -0
  344. package/.next-prod/static/chunks/app/api/session-title/route-6af5bc188af96106.js +1 -0
  345. package/.next-prod/static/chunks/app/api/session-title/suggest/route-6af5bc188af96106.js +1 -0
  346. package/.next-prod/static/chunks/app/api/sessions/delegate/route-6af5bc188af96106.js +1 -0
  347. package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-6af5bc188af96106.js +1 -0
  348. package/.next-prod/static/chunks/app/api/sessions/projects/route-6af5bc188af96106.js +1 -0
  349. package/.next-prod/static/chunks/app/api/sessions/search/route-6af5bc188af96106.js +1 -0
  350. package/.next-prod/static/chunks/app/api/sessions/status/route-6af5bc188af96106.js +1 -0
  351. package/.next-prod/static/chunks/app/api/settings/route-6af5bc188af96106.js +1 -0
  352. package/.next-prod/static/chunks/app/api/shutdown/route-6af5bc188af96106.js +1 -0
  353. package/.next-prod/static/chunks/app/api/skills/[id]/route-6af5bc188af96106.js +1 -0
  354. package/.next-prod/static/chunks/app/api/skills/builtin/route-6af5bc188af96106.js +1 -0
  355. package/.next-prod/static/chunks/app/api/skills/content/route-6af5bc188af96106.js +1 -0
  356. package/.next-prod/static/chunks/app/api/skills/files/route-6af5bc188af96106.js +1 -0
  357. package/.next-prod/static/chunks/app/api/skills/route-6af5bc188af96106.js +1 -0
  358. package/.next-prod/static/chunks/app/api/snapshots/blob/route-6af5bc188af96106.js +1 -0
  359. package/.next-prod/static/chunks/app/api/snapshots/diff/route-6af5bc188af96106.js +1 -0
  360. package/.next-prod/static/chunks/app/api/snapshots/mark/route-6af5bc188af96106.js +1 -0
  361. package/.next-prod/static/chunks/app/api/snapshots/range-diff/route-6af5bc188af96106.js +1 -0
  362. package/.next-prod/static/chunks/app/api/snapshots/restore/route-6af5bc188af96106.js +1 -0
  363. package/.next-prod/static/chunks/app/api/snapshots/route-6af5bc188af96106.js +1 -0
  364. package/.next-prod/static/chunks/app/api/terminal/aliases/route-6af5bc188af96106.js +1 -0
  365. package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-6af5bc188af96106.js +1 -0
  366. package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-6af5bc188af96106.js +1 -0
  367. package/.next-prod/static/chunks/app/api/terminal/env/route-6af5bc188af96106.js +1 -0
  368. package/.next-prod/static/chunks/app/api/terminal/history/route-6af5bc188af96106.js +1 -0
  369. package/.next-prod/static/chunks/app/api/terminal/running/route-6af5bc188af96106.js +1 -0
  370. package/.next-prod/static/chunks/app/api/update/route-6af5bc188af96106.js +1 -0
  371. package/.next-prod/static/chunks/app/api/update-state/route-6af5bc188af96106.js +1 -0
  372. package/.next-prod/static/chunks/app/api/version/route-6af5bc188af96106.js +1 -0
  373. package/.next-prod/static/chunks/app/apps/[...path]/route-6af5bc188af96106.js +1 -0
  374. package/.next-prod/static/chunks/app/{layout-f0ff0ab277c84dc6.js → layout-7107ed4eeac1f693.js} +1 -1
  375. package/.next-prod/static/chunks/app/m/page-0c8e79e2f753aecb.js +2 -0
  376. package/.next-prod/static/chunks/app/manifest.webmanifest/route-6af5bc188af96106.js +1 -0
  377. package/.next-prod/static/chunks/app/{page-d2ccfc2cb47ac4af.js → page-338a2c84319778b1.js} +1 -1
  378. package/.next-prod/static/chunks/app/project/{page-d2ccfc2cb47ac4af.js → page-338a2c84319778b1.js} +1 -1
  379. package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-6af5bc188af96106.js +1 -0
  380. package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-6af5bc188af96106.js +1 -0
  381. package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-6af5bc188af96106.js +1 -0
  382. package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-6af5bc188af96106.js +1 -0
  383. package/.next-prod/static/css/fa34d3b1412ca27a.css +1 -0
  384. package/.next-prod/trace +86 -15
  385. package/.next-prod/trace-build +1 -1
  386. package/.next-prod/types/app/api/projectGraph/edges/route.ts +353 -0
  387. package/.next-prod/types/app/api/projectGraph/maps/route.ts +353 -0
  388. package/.next-prod/types/app/api/snapshots/mark/route.ts +353 -0
  389. package/.next-prod/types/app/api/snapshots/restore/route.ts +353 -0
  390. package/.next-prod/types/routes.d.ts +5 -1
  391. package/.next-prod/types/validator.ts +36 -0
  392. package/README.md +6 -0
  393. package/bin/rotateLog.mjs +6 -5
  394. package/desktop-checksums.json +4 -4
  395. package/dist/{anthropicCompat-PQWSZ3O7.mjs → anthropicCompat-4HZVLIFE.mjs} +3 -2
  396. package/dist/auth.mjs +19 -3
  397. package/dist/authAudit.mjs +79 -0
  398. package/dist/{chunk-6QDJ3QAX.mjs → chunk-6QHHEA3D.mjs} +11 -9
  399. package/dist/{chunk-2PDNZOMA.mjs → chunk-HJT5ZRYY.mjs} +2 -2
  400. package/dist/{chunk-S7FDWHAF.mjs → chunk-LSFNZJMR.mjs} +26825 -29730
  401. package/dist/{chunk-3S5JGONK.mjs → chunk-N3DTLFZE.mjs} +14 -12
  402. package/dist/{chunk-AKBWZB3V.mjs → chunk-QPFJKR3B.mjs} +2 -2
  403. package/dist/{chunk-LQISLDJ5.mjs → chunk-SI632CNY.mjs} +1 -1
  404. package/dist/{chunk-G747UZSS.mjs → chunk-T4M6CNFO.mjs} +132 -34
  405. package/dist/chunk-WSSVELJX.mjs +2920 -0
  406. package/dist/{chunk-2O6IH2TF.mjs → chunk-X4R5HO25.mjs} +2 -2
  407. package/dist/deepseek-YEPNQ2GX.mjs +13 -0
  408. package/dist/glm-SGT2LTOS.mjs +15 -0
  409. package/dist/httpApi.mjs +9 -8
  410. package/dist/kimi-FDXILCYU.mjs +15 -0
  411. package/dist/scheduledTasks.mjs +41 -15
  412. package/dist/{sessionStore-FF2VHKXM.mjs → sessionStore-WJGMZM4A.mjs} +2 -1
  413. package/dist/wsServer.mjs +63 -26
  414. package/package.json +3 -3
  415. package/public/html-lib/markdown.js +1 -1
  416. package/server.mjs +6 -1
  417. package/skills/cr/SKILL.md +184 -11
  418. package/skills/dl/SKILL.md +5 -0
  419. package/skills/rf/SKILL.md +124 -0
  420. package/skills/rf/axes.md +87 -0
  421. package/skills/rf/converge.md +50 -0
  422. package/skills/rf/fix.md +138 -0
  423. package/skills/rf/lenses.md +76 -0
  424. package/skills/rf/report.md +133 -0
  425. package/skills/rf/sources.md +129 -0
  426. package/.next-prod/static/AO-RPvB4uxOb6-XZ_0YXg/_buildManifest.js +0 -1
  427. package/.next-prod/static/chunks/17220-89a26ee102272095.js +0 -732
  428. package/.next-prod/static/chunks/45590-d1a8b4e539cc8dda.js +0 -42
  429. package/.next-prod/static/chunks/app/_global-error/page-42efcb4fd08c5099.js +0 -1
  430. package/.next-prod/static/chunks/app/api/agent/test/route-42efcb4fd08c5099.js +0 -1
  431. package/.next-prod/static/chunks/app/api/bash/route-42efcb4fd08c5099.js +0 -1
  432. package/.next-prod/static/chunks/app/api/bots/[id]/route-42efcb4fd08c5099.js +0 -1
  433. package/.next-prod/static/chunks/app/api/bots/files/route-42efcb4fd08c5099.js +0 -1
  434. package/.next-prod/static/chunks/app/api/bots/route-42efcb4fd08c5099.js +0 -1
  435. package/.next-prod/static/chunks/app/api/chat/codex/route-42efcb4fd08c5099.js +0 -1
  436. package/.next-prod/static/chunks/app/api/chat/deepseek/route-42efcb4fd08c5099.js +0 -1
  437. package/.next-prod/static/chunks/app/api/chat/glm/route-42efcb4fd08c5099.js +0 -1
  438. package/.next-prod/static/chunks/app/api/chat/grok/route-42efcb4fd08c5099.js +0 -1
  439. package/.next-prod/static/chunks/app/api/chat/kimi/route-42efcb4fd08c5099.js +0 -1
  440. package/.next-prod/static/chunks/app/api/chat/ollama/route-42efcb4fd08c5099.js +0 -1
  441. package/.next-prod/static/chunks/app/api/chat/route-42efcb4fd08c5099.js +0 -1
  442. package/.next-prod/static/chunks/app/api/chat/stop/route-42efcb4fd08c5099.js +0 -1
  443. package/.next-prod/static/chunks/app/api/claude-stats/route-42efcb4fd08c5099.js +0 -1
  444. package/.next-prod/static/chunks/app/api/commands/route-42efcb4fd08c5099.js +0 -1
  445. package/.next-prod/static/chunks/app/api/comments/route-42efcb4fd08c5099.js +0 -1
  446. package/.next-prod/static/chunks/app/api/db/columns/route-42efcb4fd08c5099.js +0 -1
  447. package/.next-prod/static/chunks/app/api/db/connect/route-42efcb4fd08c5099.js +0 -1
  448. package/.next-prod/static/chunks/app/api/db/disconnect/route-42efcb4fd08c5099.js +0 -1
  449. package/.next-prod/static/chunks/app/api/db/export/route-42efcb4fd08c5099.js +0 -1
  450. package/.next-prod/static/chunks/app/api/db/query/route-42efcb4fd08c5099.js +0 -1
  451. package/.next-prod/static/chunks/app/api/db/schemas/route-42efcb4fd08c5099.js +0 -1
  452. package/.next-prod/static/chunks/app/api/deepseek/balance/route-42efcb4fd08c5099.js +0 -1
  453. package/.next-prod/static/chunks/app/api/deepseek/credentials/route-42efcb4fd08c5099.js +0 -1
  454. package/.next-prod/static/chunks/app/api/deepseek/models/route-42efcb4fd08c5099.js +0 -1
  455. package/.next-prod/static/chunks/app/api/dev/spans/route-42efcb4fd08c5099.js +0 -1
  456. package/.next-prod/static/chunks/app/api/extension/version/route-42efcb4fd08c5099.js +0 -1
  457. package/.next-prod/static/chunks/app/api/file/route-42efcb4fd08c5099.js +0 -1
  458. package/.next-prod/static/chunks/app/api/files/blame/route-42efcb4fd08c5099.js +0 -1
  459. package/.next-prod/static/chunks/app/api/files/clipboard/route-42efcb4fd08c5099.js +0 -1
  460. package/.next-prod/static/chunks/app/api/files/copy/route-42efcb4fd08c5099.js +0 -1
  461. package/.next-prod/static/chunks/app/api/files/delete/route-42efcb4fd08c5099.js +0 -1
  462. package/.next-prod/static/chunks/app/api/files/expanded/route-42efcb4fd08c5099.js +0 -1
  463. package/.next-prod/static/chunks/app/api/files/index/route-42efcb4fd08c5099.js +0 -1
  464. package/.next-prod/static/chunks/app/api/files/init/route-42efcb4fd08c5099.js +0 -1
  465. package/.next-prod/static/chunks/app/api/files/paste/route-42efcb4fd08c5099.js +0 -1
  466. package/.next-prod/static/chunks/app/api/files/read/route-42efcb4fd08c5099.js +0 -1
  467. package/.next-prod/static/chunks/app/api/files/readdir/route-42efcb4fd08c5099.js +0 -1
  468. package/.next-prod/static/chunks/app/api/files/recent/route-42efcb4fd08c5099.js +0 -1
  469. package/.next-prod/static/chunks/app/api/files/save/route-42efcb4fd08c5099.js +0 -1
  470. package/.next-prod/static/chunks/app/api/files/search/route-42efcb4fd08c5099.js +0 -1
  471. package/.next-prod/static/chunks/app/api/files/stat/route-42efcb4fd08c5099.js +0 -1
  472. package/.next-prod/static/chunks/app/api/files/text/route-42efcb4fd08c5099.js +0 -1
  473. package/.next-prod/static/chunks/app/api/fs/dirs/route-42efcb4fd08c5099.js +0 -1
  474. package/.next-prod/static/chunks/app/api/git/blob/route-42efcb4fd08c5099.js +0 -1
  475. package/.next-prod/static/chunks/app/api/git/branch-diff/route-42efcb4fd08c5099.js +0 -1
  476. package/.next-prod/static/chunks/app/api/git/branches/route-42efcb4fd08c5099.js +0 -1
  477. package/.next-prod/static/chunks/app/api/git/commit-diff/route-42efcb4fd08c5099.js +0 -1
  478. package/.next-prod/static/chunks/app/api/git/commits/route-42efcb4fd08c5099.js +0 -1
  479. package/.next-prod/static/chunks/app/api/git/current-branch/route-42efcb4fd08c5099.js +0 -1
  480. package/.next-prod/static/chunks/app/api/git/diff/route-42efcb4fd08c5099.js +0 -1
  481. package/.next-prod/static/chunks/app/api/git/discard/route-42efcb4fd08c5099.js +0 -1
  482. package/.next-prod/static/chunks/app/api/git/stage/route-42efcb4fd08c5099.js +0 -1
  483. package/.next-prod/static/chunks/app/api/git/status/route-42efcb4fd08c5099.js +0 -1
  484. package/.next-prod/static/chunks/app/api/git/unstage/route-42efcb4fd08c5099.js +0 -1
  485. package/.next-prod/static/chunks/app/api/git/worktree/route-42efcb4fd08c5099.js +0 -1
  486. package/.next-prod/static/chunks/app/api/glm/credentials/route-42efcb4fd08c5099.js +0 -1
  487. package/.next-prod/static/chunks/app/api/glm/models/route-42efcb4fd08c5099.js +0 -1
  488. package/.next-prod/static/chunks/app/api/glm/usage/route-42efcb4fd08c5099.js +0 -1
  489. package/.next-prod/static/chunks/app/api/global-state/route-42efcb4fd08c5099.js +0 -1
  490. package/.next-prod/static/chunks/app/api/grok/models/route-42efcb4fd08c5099.js +0 -1
  491. package/.next-prod/static/chunks/app/api/health/route-42efcb4fd08c5099.js +0 -1
  492. package/.next-prod/static/chunks/app/api/html-apps/[id]/route-42efcb4fd08c5099.js +0 -1
  493. package/.next-prod/static/chunks/app/api/html-apps/files/route-42efcb4fd08c5099.js +0 -1
  494. package/.next-prod/static/chunks/app/api/html-apps/route-42efcb4fd08c5099.js +0 -1
  495. package/.next-prod/static/chunks/app/api/instructions/config/route-42efcb4fd08c5099.js +0 -1
  496. package/.next-prod/static/chunks/app/api/kimi/credentials/route-42efcb4fd08c5099.js +0 -1
  497. package/.next-prod/static/chunks/app/api/kimi/models/route-42efcb4fd08c5099.js +0 -1
  498. package/.next-prod/static/chunks/app/api/kimi/usage/route-42efcb4fd08c5099.js +0 -1
  499. package/.next-prod/static/chunks/app/api/lsp/definition/route-42efcb4fd08c5099.js +0 -1
  500. package/.next-prod/static/chunks/app/api/lsp/hover/route-42efcb4fd08c5099.js +0 -1
  501. package/.next-prod/static/chunks/app/api/lsp/references/route-42efcb4fd08c5099.js +0 -1
  502. package/.next-prod/static/chunks/app/api/lsp/status/route-42efcb4fd08c5099.js +0 -1
  503. package/.next-prod/static/chunks/app/api/lsp/warmup/route-42efcb4fd08c5099.js +0 -1
  504. package/.next-prod/static/chunks/app/api/mobile-link/route-42efcb4fd08c5099.js +0 -1
  505. package/.next-prod/static/chunks/app/api/mysql/columns/route-42efcb4fd08c5099.js +0 -1
  506. package/.next-prod/static/chunks/app/api/mysql/connect/route-42efcb4fd08c5099.js +0 -1
  507. package/.next-prod/static/chunks/app/api/mysql/disconnect/route-42efcb4fd08c5099.js +0 -1
  508. package/.next-prod/static/chunks/app/api/mysql/export/route-42efcb4fd08c5099.js +0 -1
  509. package/.next-prod/static/chunks/app/api/mysql/query/route-42efcb4fd08c5099.js +0 -1
  510. package/.next-prod/static/chunks/app/api/mysql/schemas/route-42efcb4fd08c5099.js +0 -1
  511. package/.next-prod/static/chunks/app/api/neo4j/connect/route-42efcb4fd08c5099.js +0 -1
  512. package/.next-prod/static/chunks/app/api/neo4j/disconnect/route-42efcb4fd08c5099.js +0 -1
  513. package/.next-prod/static/chunks/app/api/neo4j/query/route-42efcb4fd08c5099.js +0 -1
  514. package/.next-prod/static/chunks/app/api/neo4j/schema/route-42efcb4fd08c5099.js +0 -1
  515. package/.next-prod/static/chunks/app/api/note/list/route-42efcb4fd08c5099.js +0 -1
  516. package/.next-prod/static/chunks/app/api/note/route-42efcb4fd08c5099.js +0 -1
  517. package/.next-prod/static/chunks/app/api/ollama/config/route-42efcb4fd08c5099.js +0 -1
  518. package/.next-prod/static/chunks/app/api/ollama/default-model/route-42efcb4fd08c5099.js +0 -1
  519. package/.next-prod/static/chunks/app/api/ollama/models/route-42efcb4fd08c5099.js +0 -1
  520. package/.next-prod/static/chunks/app/api/ollama/start/route-42efcb4fd08c5099.js +0 -1
  521. package/.next-prod/static/chunks/app/api/open-cursor/route-42efcb4fd08c5099.js +0 -1
  522. package/.next-prod/static/chunks/app/api/open-vscode/route-42efcb4fd08c5099.js +0 -1
  523. package/.next-prod/static/chunks/app/api/pi/thinking/route-42efcb4fd08c5099.js +0 -1
  524. package/.next-prod/static/chunks/app/api/pinned-sessions/route-42efcb4fd08c5099.js +0 -1
  525. package/.next-prod/static/chunks/app/api/project-settings/route-42efcb4fd08c5099.js +0 -1
  526. package/.next-prod/static/chunks/app/api/project-state/route-42efcb4fd08c5099.js +0 -1
  527. package/.next-prod/static/chunks/app/api/projectGraph/affected/route-42efcb4fd08c5099.js +0 -1
  528. package/.next-prod/static/chunks/app/api/projectGraph/callees/route-42efcb4fd08c5099.js +0 -1
  529. package/.next-prod/static/chunks/app/api/projectGraph/callers/route-42efcb4fd08c5099.js +0 -1
  530. package/.next-prod/static/chunks/app/api/projectGraph/coedit/route-42efcb4fd08c5099.js +0 -1
  531. package/.next-prod/static/chunks/app/api/projectGraph/file/route-42efcb4fd08c5099.js +0 -1
  532. package/.next-prod/static/chunks/app/api/projectGraph/file-functions/route-42efcb4fd08c5099.js +0 -1
  533. package/.next-prod/static/chunks/app/api/projectGraph/impact/route-42efcb4fd08c5099.js +0 -1
  534. package/.next-prod/static/chunks/app/api/projectGraph/related/route-42efcb4fd08c5099.js +0 -1
  535. package/.next-prod/static/chunks/app/api/projectGraph/search/route-42efcb4fd08c5099.js +0 -1
  536. package/.next-prod/static/chunks/app/api/projectGraph/symbols/route-42efcb4fd08c5099.js +0 -1
  537. package/.next-prod/static/chunks/app/api/projects/route-42efcb4fd08c5099.js +0 -1
  538. package/.next-prod/static/chunks/app/api/push/public-key/route-42efcb4fd08c5099.js +0 -1
  539. package/.next-prod/static/chunks/app/api/push/subscribe/route-42efcb4fd08c5099.js +0 -1
  540. package/.next-prod/static/chunks/app/api/push/unsubscribe/route-42efcb4fd08c5099.js +0 -1
  541. package/.next-prod/static/chunks/app/api/redis/command/route-42efcb4fd08c5099.js +0 -1
  542. package/.next-prod/static/chunks/app/api/redis/connect/route-42efcb4fd08c5099.js +0 -1
  543. package/.next-prod/static/chunks/app/api/redis/delete/route-42efcb4fd08c5099.js +0 -1
  544. package/.next-prod/static/chunks/app/api/redis/disconnect/route-42efcb4fd08c5099.js +0 -1
  545. package/.next-prod/static/chunks/app/api/redis/get/route-42efcb4fd08c5099.js +0 -1
  546. package/.next-prod/static/chunks/app/api/redis/keys/route-42efcb4fd08c5099.js +0 -1
  547. package/.next-prod/static/chunks/app/api/redis/set/route-42efcb4fd08c5099.js +0 -1
  548. package/.next-prod/static/chunks/app/api/restart/route-42efcb4fd08c5099.js +0 -1
  549. package/.next-prod/static/chunks/app/api/scheduled-tasks/route-42efcb4fd08c5099.js +0 -1
  550. package/.next-prod/static/chunks/app/api/services/config/route-42efcb4fd08c5099.js +0 -1
  551. package/.next-prod/static/chunks/app/api/services/scripts/route-42efcb4fd08c5099.js +0 -1
  552. package/.next-prod/static/chunks/app/api/session/[sessionId]/fork/route-42efcb4fd08c5099.js +0 -1
  553. package/.next-prod/static/chunks/app/api/session/[sessionId]/history/route-42efcb4fd08c5099.js +0 -1
  554. package/.next-prod/static/chunks/app/api/session/[sessionId]/turn/route-42efcb4fd08c5099.js +0 -1
  555. package/.next-prod/static/chunks/app/api/session/image/route-42efcb4fd08c5099.js +0 -1
  556. package/.next-prod/static/chunks/app/api/session/user-messages/route-42efcb4fd08c5099.js +0 -1
  557. package/.next-prod/static/chunks/app/api/session-bots/route-42efcb4fd08c5099.js +0 -1
  558. package/.next-prod/static/chunks/app/api/session-by-path/route-42efcb4fd08c5099.js +0 -1
  559. package/.next-prod/static/chunks/app/api/session-context/route-42efcb4fd08c5099.js +0 -1
  560. package/.next-prod/static/chunks/app/api/session-title/route-42efcb4fd08c5099.js +0 -1
  561. package/.next-prod/static/chunks/app/api/session-title/suggest/route-42efcb4fd08c5099.js +0 -1
  562. package/.next-prod/static/chunks/app/api/sessions/delegate/route-42efcb4fd08c5099.js +0 -1
  563. package/.next-prod/static/chunks/app/api/sessions/projects/[encodedPath]/route-42efcb4fd08c5099.js +0 -1
  564. package/.next-prod/static/chunks/app/api/sessions/projects/route-42efcb4fd08c5099.js +0 -1
  565. package/.next-prod/static/chunks/app/api/sessions/search/route-42efcb4fd08c5099.js +0 -1
  566. package/.next-prod/static/chunks/app/api/sessions/status/route-42efcb4fd08c5099.js +0 -1
  567. package/.next-prod/static/chunks/app/api/settings/route-42efcb4fd08c5099.js +0 -1
  568. package/.next-prod/static/chunks/app/api/shutdown/route-42efcb4fd08c5099.js +0 -1
  569. package/.next-prod/static/chunks/app/api/skills/[id]/route-42efcb4fd08c5099.js +0 -1
  570. package/.next-prod/static/chunks/app/api/skills/builtin/route-42efcb4fd08c5099.js +0 -1
  571. package/.next-prod/static/chunks/app/api/skills/content/route-42efcb4fd08c5099.js +0 -1
  572. package/.next-prod/static/chunks/app/api/skills/files/route-42efcb4fd08c5099.js +0 -1
  573. package/.next-prod/static/chunks/app/api/skills/route-42efcb4fd08c5099.js +0 -1
  574. package/.next-prod/static/chunks/app/api/snapshots/blob/route-42efcb4fd08c5099.js +0 -1
  575. package/.next-prod/static/chunks/app/api/snapshots/diff/route-42efcb4fd08c5099.js +0 -1
  576. package/.next-prod/static/chunks/app/api/snapshots/range-diff/route-42efcb4fd08c5099.js +0 -1
  577. package/.next-prod/static/chunks/app/api/snapshots/route-42efcb4fd08c5099.js +0 -1
  578. package/.next-prod/static/chunks/app/api/terminal/aliases/route-42efcb4fd08c5099.js +0 -1
  579. package/.next-prod/static/chunks/app/api/terminal/autocomplete/route-42efcb4fd08c5099.js +0 -1
  580. package/.next-prod/static/chunks/app/api/terminal/bubble-order/route-42efcb4fd08c5099.js +0 -1
  581. package/.next-prod/static/chunks/app/api/terminal/env/route-42efcb4fd08c5099.js +0 -1
  582. package/.next-prod/static/chunks/app/api/terminal/history/route-42efcb4fd08c5099.js +0 -1
  583. package/.next-prod/static/chunks/app/api/terminal/running/route-42efcb4fd08c5099.js +0 -1
  584. package/.next-prod/static/chunks/app/api/update/route-42efcb4fd08c5099.js +0 -1
  585. package/.next-prod/static/chunks/app/api/update-state/route-42efcb4fd08c5099.js +0 -1
  586. package/.next-prod/static/chunks/app/api/version/route-42efcb4fd08c5099.js +0 -1
  587. package/.next-prod/static/chunks/app/apps/[...path]/route-42efcb4fd08c5099.js +0 -1
  588. package/.next-prod/static/chunks/app/m/page-50e48b4ba0942454.js +0 -1
  589. package/.next-prod/static/chunks/app/manifest.webmanifest/route-42efcb4fd08c5099.js +0 -1
  590. package/.next-prod/static/chunks/next/dist/client/components/builtin/app-error-42efcb4fd08c5099.js +0 -1
  591. package/.next-prod/static/chunks/next/dist/client/components/builtin/forbidden-42efcb4fd08c5099.js +0 -1
  592. package/.next-prod/static/chunks/next/dist/client/components/builtin/not-found-42efcb4fd08c5099.js +0 -1
  593. package/.next-prod/static/chunks/next/dist/client/components/builtin/unauthorized-42efcb4fd08c5099.js +0 -1
  594. package/.next-prod/static/css/74144fec62c7ff43.css +0 -1
  595. package/dist/deepseek-5QJ2IWS3.mjs +0 -12
  596. package/dist/glm-SIOUQCWL.mjs +0 -14
  597. package/dist/kimi-NKL4WBNS.mjs +0 -14
  598. /package/.next-prod/static/{AO-RPvB4uxOb6-XZ_0YXg → LwAYWBEgXwTIkuj7U9BpE}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=5510,a.ids=[5510],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},2331:(a,b,c)=>{c.d(b,{Z:()=>e});let d=a=>"/"===a||"\\"===a;function e(a,b,c=!1){let f=function(a,b){let c;if(!a)return null;let e=""===(c=a.replace(/[/\\]+$/,""))||/^[A-Za-z]:$/.test(c)?a:c;return b===e?"":b.startsWith(e)?d(e[e.length-1])?b.slice(e.length):d(b[e.length])?b.slice(e.length+1):null:null}(a,b);return null!==f&&(c||""!==f)}},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},8396:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(56904),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},24309:(a,b,c)=>{c.d(b,{oF:()=>j,pT:()=>i});var d=c(79748),e=c(33873),f=c.n(e),g=c(2331);let h=new Set(["node_modules","__pycache__"]);async function i(a){let b=[],c=!1,e=async(a,g,i)=>{let j;if(b.length>=2e3){c=!0;return}try{j=await (0,d.readdir)(a,{withFileTypes:!0})}catch{return}for(let k of j.sort((a,b)=>a.name.localeCompare(b.name))){if(k.name.startsWith("."))continue;let j=f().join(a,k.name),l=g?`${g}/${k.name}`:k.name;if(k.isDirectory())!h.has(k.name)&&i<8&&await e(j,l,i+1);else if(k.isFile()){if(b.length>=2e3){c=!0;return}let a=await (0,d.stat)(j).then(a=>a.size,()=>0);b.push({path:l,size:a})}}};return await e(a,"",0),{files:b,truncated:c}}async function j(a,b){let c=await (0,d.realpath)(a).catch(()=>null),e=await (0,d.realpath)(f().resolve(a,b)).catch(()=>null);if(!c||!e)return{kind:"missing"};if(!(0,g.Z)(c,e))return{kind:"outside"};let h=await (0,d.stat)(e).catch(()=>null);if(!h?.isFile())return{kind:"missing"};if(h.size>1048576)return{kind:"tooLarge",size:h.size};let i=await (0,d.readFile)(e);return i.subarray(0,8192).includes(0)?{kind:"binary",size:h.size}:{kind:"text",content:i.toString("utf-8"),size:h.size}}},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},45676:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/html-apps/files/route",pathname:"/api/html-apps/files",filename:"route",bundlePath:"app/api/html-apps/files/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/html-apps/files/route.ts",nextConfigOutput:"",userland:()=>c(8396),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/html-apps/files/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},56904:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>p,fA:()=>o,fG:()=>q});var e=c(79748),f=c(33873),g=c.n(f),h=c(89705),i=c(7939),j=c(24309),k=c(72891),l=c(770),m=c(71147),n=a([k]);k=(n.then?(await n)():n)[0];let o="nodejs",p="force-dynamic",q=(0,k.RL)(a=>h.JkU(function*(){let b=new URL(a.url).searchParams,c=b.get("id");if(!c)return yield*h.fJG(new l.yI({field:"id",reason:"missing"}));let d=yield*h.JkU(function*(){let a=(yield*(0,m.cJ)()).find(a=>a.id===c);if(a)return a.path;let b=yield*h.$mh(()=>(0,i.JE)(i.sH,{apps:[]})).pipe(h.DM4(()=>({apps:[]})));return b.apps.find(a=>a.id===c)?.path});if(!d)return yield*h.fJG(new l.m_({resource:"html-app",id:c}));let f=g().dirname(d),n=g().basename(d),o=yield*h.$mh(()=>(0,e.readdir)(f)).pipe(h.TjK(a=>a.some(a=>a!==n&&/\.html?$/i.test(a))),h.DM4(()=>!0)),p=b.get("path");if(null===p){if(o){let a=yield*h.$mh(()=>(0,e.stat)(d)).pipe(h.TjK(a=>a.size),h.DM4(()=>0));return(0,k.ok)({dir:f,files:[{path:n,size:a}],truncated:!1})}let a=yield*h.$mh(()=>(0,j.pT)(f)).pipe(h.DM4(()=>({files:[],truncated:!1})));return(0,k.ok)({dir:f,...a})}if(o&&p!==n)return yield*h.fJG(new l.yI({field:"path",reason:"outside app"}));let q=yield*h.$mh(()=>(0,j.oF)(f,p)).pipe(h.DM4(()=>({kind:"missing"})));return"outside"===q.kind?yield*h.fJG(new l.yI({field:"path",reason:"outside app directory"})):"missing"===q.kind?yield*h.fJG(new l.m_({resource:"file",id:p})):(0,k.ok)({path:p,...q})}));d()}catch(a){d(a)}})},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},71147:(a,b,c)=>{c.d(b,{PT:()=>j,cJ:()=>k});var d=c(33873),e=c(89705),f=c(7939),g=c(92769);let h=["devkit"],i="builtin:",j=a=>a.startsWith(i);function k(){return e.jJl(h,a=>e.ivC(async()=>{let b=(0,d.join)(f.Hj,a,"index.html"),c=await (0,g.s)(b);return c.valid?{id:`${i}${a}`,path:b,addedAt:"",name:c.name,title:c.title,description:c.description,icon:c.icon,valid:!0,builtin:!0}:null}),{concurrency:"unbounded"}).pipe(e.TjK(a=>a.filter(a=>null!==a)))}},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},92769:(a,b,c)=>{c.d(b,{s:()=>g});var d=c(79748),e=c(29021),f=c(33873);async function g(a){let b,c;if(!a||!(0,e.existsSync)(a))return h(a);try{b=await (0,d.readFile)(a,"utf-8")}catch{return h(a)}let g=b.slice(0,65536),j=(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a),m=i(g,"cockpit-name"),n=(c=g.match(/<title[^>]*>([\s\S]*?)<\/title>/i))?k(c[1].trim().replace(/\s+/g," ")):"";return{name:l(m)||j,title:n||l(m)||j,description:i(g,"description")||"",icon:i(g,"cockpit-icon")||void 0,valid:!0}}function h(a){let b=a?(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a):"unknown";return{name:b,title:b,description:"",icon:void 0,valid:!1}}function i(a,b){let c=RegExp(`<meta\\b[^>]*\\bname\\s*=\\s*["']${j(b)}["'][^>]*\\bcontent\\s*=\\s*["']([^"']*)["']`,"i"),d=a.match(c);if(d)return k(d[1].trim());let e=RegExp(`<meta\\b[^>]*\\bcontent\\s*=\\s*["']([^"']*)["'][^>]*\\bname\\s*=\\s*["']${j(b)}["']`,"i"),f=a.match(e);return f?k(f[1].trim()):""}function j(a){return a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function k(a){return a.replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&quot;/g,'"').replace(/&#39;/g,"'")}function l(a){return a?a.trim().replace(/\s+/g,"-").replace(/[^A-Za-z0-9\-_:.]/g,""):""}},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=45676));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=5510,a.ids=[5510],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},2331:(a,b,c)=>{c.d(b,{Z:()=>e});let d=a=>"/"===a||"\\"===a;function e(a,b,c=!1){let f=function(a,b){let c;if(!a)return null;let e=""===(c=a.replace(/[/\\]+$/,""))||/^[A-Za-z]:$/.test(c)?a:c;return b===e?"":b.startsWith(e)?d(e[e.length-1])?b.slice(e.length):d(b[e.length])?b.slice(e.length+1):null:null}(a,b);return null!==f&&(c||""!==f)}},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},8396:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(56904),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},24309:(a,b,c)=>{c.d(b,{oF:()=>j,pT:()=>i});var d=c(79748),e=c(33873),f=c.n(e),g=c(2331);let h=new Set(["node_modules","__pycache__"]);async function i(a){let b=[],c=!1,e=async(a,g,i)=>{let j;if(b.length>=2e3){c=!0;return}try{j=await (0,d.readdir)(a,{withFileTypes:!0})}catch{return}for(let k of j.sort((a,b)=>a.name.localeCompare(b.name))){if(k.name.startsWith("."))continue;let j=f().join(a,k.name),l=g?`${g}/${k.name}`:k.name;if(k.isDirectory())!h.has(k.name)&&i<8&&await e(j,l,i+1);else if(k.isFile()){if(b.length>=2e3){c=!0;return}let a=await (0,d.stat)(j).then(a=>a.size,()=>0);b.push({path:l,size:a})}}};return await e(a,"",0),{files:b,truncated:c}}async function j(a,b){let c=await (0,d.realpath)(a).catch(()=>null),e=await (0,d.realpath)(f().resolve(a,b)).catch(()=>null);if(!c||!e)return{kind:"missing"};if(!(0,g.Z)(c,e))return{kind:"outside"};let h=await (0,d.stat)(e).catch(()=>null);if(!h?.isFile())return{kind:"missing"};if(h.size>1048576)return{kind:"tooLarge",size:h.size};let i=await (0,d.readFile)(e);return i.subarray(0,8192).includes(0)?{kind:"binary",size:h.size}:{kind:"text",content:i.toString("utf-8"),size:h.size}}},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},56904:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>p,fA:()=>o,fG:()=>q});var e=c(79748),f=c(33873),g=c.n(f),h=c(89705),i=c(7939),j=c(24309),k=c(72891),l=c(770),m=c(71147),n=a([k]);k=(n.then?(await n)():n)[0];let o="nodejs",p="force-dynamic",q=(0,k.RL)(a=>h.JkU(function*(){let b=new URL(a.url).searchParams,c=b.get("id");if(!c)return yield*h.fJG(new l.yI({field:"id",reason:"missing"}));let d=yield*h.JkU(function*(){let a=(yield*(0,m.cJ)()).find(a=>a.id===c);if(a)return a.path;let b=yield*h.$mh(()=>(0,i.JE)(i.sH,{apps:[]})).pipe(h.DM4(()=>({apps:[]})));return b.apps.find(a=>a.id===c)?.path});if(!d)return yield*h.fJG(new l.m_({resource:"html-app",id:c}));let f=g().dirname(d),n=g().basename(d),o=yield*h.$mh(()=>(0,e.readdir)(f)).pipe(h.TjK(a=>a.some(a=>a!==n&&/\.html?$/i.test(a))),h.DM4(()=>!0)),p=b.get("path");if(null===p){if(o){let a=yield*h.$mh(()=>(0,e.stat)(d)).pipe(h.TjK(a=>a.size),h.DM4(()=>0));return(0,k.ok)({dir:f,files:[{path:n,size:a}],truncated:!1})}let a=yield*h.$mh(()=>(0,j.pT)(f)).pipe(h.DM4(()=>({files:[],truncated:!1})));return(0,k.ok)({dir:f,...a})}if(o&&p!==n)return yield*h.fJG(new l.yI({field:"path",reason:"outside app"}));let q=yield*h.$mh(()=>(0,j.oF)(f,p)).pipe(h.DM4(()=>({kind:"missing"})));return"outside"===q.kind?yield*h.fJG(new l.yI({field:"path",reason:"outside app directory"})):"missing"===q.kind?yield*h.fJG(new l.m_({resource:"file",id:p})):(0,k.ok)({path:p,...q})}));d()}catch(a){d(a)}})},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},71147:(a,b,c)=>{c.d(b,{PT:()=>j,cJ:()=>k});var d=c(33873),e=c(89705),f=c(7939),g=c(92769);let h=["devkit"],i="builtin:",j=a=>a.startsWith(i);function k(){return e.jJl(h,a=>e.ivC(async()=>{let b=(0,d.join)(f.Hj,a,"index.html"),c=await (0,g.s)(b);return c.valid?{id:`${i}${a}`,path:b,addedAt:"",name:c.name,title:c.title,description:c.description,icon:c.icon,valid:!0,builtin:!0}:null}),{concurrency:"unbounded"}).pipe(e.TjK(a=>a.filter(a=>null!==a)))}},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},74982:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/html-apps/files/route",pathname:"/api/html-apps/files",filename:"route",bundlePath:"app/api/html-apps/files/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/html-apps/files/route.ts",nextConfigOutput:"",userland:()=>c(8396),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/html-apps/files/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},92769:(a,b,c)=>{c.d(b,{s:()=>g});var d=c(79748),e=c(29021),f=c(33873);async function g(a){let b,c;if(!a||!(0,e.existsSync)(a))return h(a);try{b=await (0,d.readFile)(a,"utf-8")}catch{return h(a)}let g=b.slice(0,65536),j=(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a),m=i(g,"cockpit-name"),n=(c=g.match(/<title[^>]*>([\s\S]*?)<\/title>/i))?k(c[1].trim().replace(/\s+/g," ")):"";return{name:l(m)||j,title:n||l(m)||j,description:i(g,"description")||"",icon:i(g,"cockpit-icon")||void 0,valid:!0}}function h(a){let b=a?(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a):"unknown";return{name:b,title:b,description:"",icon:void 0,valid:!1}}function i(a,b){let c=RegExp(`<meta\\b[^>]*\\bname\\s*=\\s*["']${j(b)}["'][^>]*\\bcontent\\s*=\\s*["']([^"']*)["']`,"i"),d=a.match(c);if(d)return k(d[1].trim());let e=RegExp(`<meta\\b[^>]*\\bcontent\\s*=\\s*["']([^"']*)["'][^>]*\\bname\\s*=\\s*["']${j(b)}["']`,"i"),f=a.match(e);return f?k(f[1].trim()):""}function j(a){return a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function k(a){return a.replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&quot;/g,'"').replace(/&#39;/g,"'")}function l(a){return a?a.trim().replace(/\s+/g,"-").replace(/[^A-Za-z0-9\-_:.]/g,""):""}},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=74982));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=1326,a.ids=[1326],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},13244:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,POST:()=>e.LO,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(44743),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44743:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{LO:()=>q,OR:()=>n,fA:()=>m,fG:()=>p});var e=c(89705),f=c(7939),g=c(66106),h=c(72891),i=c(770),j=c(92769),k=c(71147),l=a([h]);h=(l.then?(await l)():l)[0];let m="nodejs",n="force-dynamic",o={apps:[]},p=(0,h.RL)(()=>e.JkU(function*(){let a=yield*e.$mh({try:()=>(0,f.Ux)(f.sH,()=>(0,f.PR)(f.sH,o)),catch:()=>null}).pipe(e.DM4(()=>o)),b=yield*(0,k.cJ)(),c=new Set(b.map(a=>a.path)),d=yield*e.jJl((a.apps||[]).filter(a=>!c.has(a.path)),a=>e.ivC(async()=>{let b=await (0,j.s)(a.path);return{id:a.id,path:a.path,addedAt:a.addedAt,name:b.name,title:b.title,description:b.description,icon:b.icon,valid:b.valid}}),{concurrency:"unbounded"});return(0,h.ok)([...b,...d])})),q=(0,h.RL)(a=>e.JkU(function*(){let b=yield*(0,h.k9)(a);if("string"!=typeof b.path||!b.path.trim())return yield*e.fJG(new i.yI({field:"path",reason:"missing"}));let c=b.path.trim();if(!(0,g.Z1)(c))return yield*e.fJG(new i.yI({field:"path",reason:"must be absolute"}));if(!/\.html?$/i.test(c))return yield*e.fJG(new i.yI({field:"path",reason:"must be an .html file"}));let d=yield*e.$mh({try:()=>(0,j.s)(c),catch:a=>new i.uU({path:c,op:"read",cause:a})});if(!d.valid)return yield*e.fJG(new i.yI({field:"path",reason:"File does not exist or cannot be read"}));let l=(yield*(0,k.cJ)()).find(a=>a.path===c);if(l)return(0,h.ok)({...l,alreadyExists:!0});let{record:m,alreadyExists:n}=yield*e.$mh({try:()=>(0,f.Ux)(f.sH,async()=>{let a=await (0,f.PR)(f.sH,o),b=a.apps.find(a=>a.path===c);if(b)return{record:b,alreadyExists:!0};let d={id:`html-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,path:c,addedAt:new Date().toISOString()};return await (0,f.An)(f.sH,{apps:[...a.apps,d]}),{record:d,alreadyExists:!1}}),catch:a=>new i.uU({path:f.sH,op:"write",cause:a})});return(0,h.ok)({id:m.id,path:m.path,addedAt:m.addedAt,name:d.name,title:d.title,description:d.description,icon:d.icon,valid:!0,alreadyExists:n})}));d()}catch(a){d(a)}})},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},71147:(a,b,c)=>{c.d(b,{PT:()=>j,cJ:()=>k});var d=c(33873),e=c(89705),f=c(7939),g=c(92769);let h=["devkit"],i="builtin:",j=a=>a.startsWith(i);function k(){return e.jJl(h,a=>e.ivC(async()=>{let b=(0,d.join)(f.Hj,a,"index.html"),c=await (0,g.s)(b);return c.valid?{id:`${i}${a}`,path:b,addedAt:"",name:c.name,title:c.title,description:c.description,icon:c.icon,valid:!0,builtin:!0}:null}),{concurrency:"unbounded"}).pipe(e.TjK(a=>a.filter(a=>null!==a)))}},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},92769:(a,b,c)=>{c.d(b,{s:()=>g});var d=c(79748),e=c(29021),f=c(33873);async function g(a){let b,c;if(!a||!(0,e.existsSync)(a))return h(a);try{b=await (0,d.readFile)(a,"utf-8")}catch{return h(a)}let g=b.slice(0,65536),j=(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a),m=i(g,"cockpit-name"),n=(c=g.match(/<title[^>]*>([\s\S]*?)<\/title>/i))?k(c[1].trim().replace(/\s+/g," ")):"";return{name:l(m)||j,title:n||l(m)||j,description:i(g,"description")||"",icon:i(g,"cockpit-icon")||void 0,valid:!0}}function h(a){let b=a?(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a):"unknown";return{name:b,title:b,description:"",icon:void 0,valid:!1}}function i(a,b){let c=RegExp(`<meta\\b[^>]*\\bname\\s*=\\s*["']${j(b)}["'][^>]*\\bcontent\\s*=\\s*["']([^"']*)["']`,"i"),d=a.match(c);if(d)return k(d[1].trim());let e=RegExp(`<meta\\b[^>]*\\bcontent\\s*=\\s*["']([^"']*)["'][^>]*\\bname\\s*=\\s*["']${j(b)}["']`,"i"),f=a.match(e);return f?k(f[1].trim()):""}function j(a){return a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function k(a){return a.replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&quot;/g,'"').replace(/&#39;/g,"'")}function l(a){return a?a.trim().replace(/\s+/g,"-").replace(/[^A-Za-z0-9\-_:.]/g,""):""}},94735:a=>{a.exports=require("events")},95336:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/html-apps/route",pathname:"/api/html-apps",filename:"route",bundlePath:"app/api/html-apps/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/html-apps/route.ts",nextConfigOutput:"",userland:()=>c(13244),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/html-apps/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}}};var b=require("../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,6106],()=>b(b.s=95336));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=1326,a.ids=[1326],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},13244:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,POST:()=>e.LO,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(44743),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},14985:a=>{a.exports=require("dns")},15458:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/html-apps/route",pathname:"/api/html-apps",filename:"route",bundlePath:"app/api/html-apps/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/html-apps/route.ts",nextConfigOutput:"",userland:()=>c(13244),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/html-apps/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44743:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{LO:()=>q,OR:()=>n,fA:()=>m,fG:()=>p});var e=c(89705),f=c(7939),g=c(66106),h=c(72891),i=c(770),j=c(92769),k=c(71147),l=a([h]);h=(l.then?(await l)():l)[0];let m="nodejs",n="force-dynamic",o={apps:[]},p=(0,h.RL)(()=>e.JkU(function*(){let a=yield*e.$mh({try:()=>(0,f.Ux)(f.sH,()=>(0,f.PR)(f.sH,o)),catch:()=>null}).pipe(e.DM4(()=>o)),b=yield*(0,k.cJ)(),c=new Set(b.map(a=>a.path)),d=yield*e.jJl((a.apps||[]).filter(a=>!c.has(a.path)),a=>e.ivC(async()=>{let b=await (0,j.s)(a.path);return{id:a.id,path:a.path,addedAt:a.addedAt,name:b.name,title:b.title,description:b.description,icon:b.icon,valid:b.valid}}),{concurrency:"unbounded"});return(0,h.ok)([...b,...d])})),q=(0,h.RL)(a=>e.JkU(function*(){let b=yield*(0,h.k9)(a);if("string"!=typeof b.path||!b.path.trim())return yield*e.fJG(new i.yI({field:"path",reason:"missing"}));let c=b.path.trim();if(!(0,g.Z1)(c))return yield*e.fJG(new i.yI({field:"path",reason:"must be absolute"}));if(!/\.html?$/i.test(c))return yield*e.fJG(new i.yI({field:"path",reason:"must be an .html file"}));let d=yield*e.$mh({try:()=>(0,j.s)(c),catch:a=>new i.uU({path:c,op:"read",cause:a})});if(!d.valid)return yield*e.fJG(new i.yI({field:"path",reason:"File does not exist or cannot be read"}));let l=(yield*(0,k.cJ)()).find(a=>a.path===c);if(l)return(0,h.ok)({...l,alreadyExists:!0});let{record:m,alreadyExists:n}=yield*e.$mh({try:()=>(0,f.Ux)(f.sH,async()=>{let a=await (0,f.PR)(f.sH,o),b=a.apps.find(a=>a.path===c);if(b)return{record:b,alreadyExists:!0};let d={id:`html-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,path:c,addedAt:new Date().toISOString()};return await (0,f.An)(f.sH,{apps:[...a.apps,d]}),{record:d,alreadyExists:!1}}),catch:a=>new i.uU({path:f.sH,op:"write",cause:a})});return(0,h.ok)({id:m.id,path:m.path,addedAt:m.addedAt,name:d.name,title:d.title,description:d.description,icon:d.icon,valid:!0,alreadyExists:n})}));d()}catch(a){d(a)}})},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},71147:(a,b,c)=>{c.d(b,{PT:()=>j,cJ:()=>k});var d=c(33873),e=c(89705),f=c(7939),g=c(92769);let h=["devkit"],i="builtin:",j=a=>a.startsWith(i);function k(){return e.jJl(h,a=>e.ivC(async()=>{let b=(0,d.join)(f.Hj,a,"index.html"),c=await (0,g.s)(b);return c.valid?{id:`${i}${a}`,path:b,addedAt:"",name:c.name,title:c.title,description:c.description,icon:c.icon,valid:!0,builtin:!0}:null}),{concurrency:"unbounded"}).pipe(e.TjK(a=>a.filter(a=>null!==a)))}},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},92769:(a,b,c)=>{c.d(b,{s:()=>g});var d=c(79748),e=c(29021),f=c(33873);async function g(a){let b,c;if(!a||!(0,e.existsSync)(a))return h(a);try{b=await (0,d.readFile)(a,"utf-8")}catch{return h(a)}let g=b.slice(0,65536),j=(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a),m=i(g,"cockpit-name"),n=(c=g.match(/<title[^>]*>([\s\S]*?)<\/title>/i))?k(c[1].trim().replace(/\s+/g," ")):"";return{name:l(m)||j,title:n||l(m)||j,description:i(g,"description")||"",icon:i(g,"cockpit-icon")||void 0,valid:!0}}function h(a){let b=a?(0,f.basename)(a,(0,f.extname)(a))||(0,f.basename)(a):"unknown";return{name:b,title:b,description:"",icon:void 0,valid:!1}}function i(a,b){let c=RegExp(`<meta\\b[^>]*\\bname\\s*=\\s*["']${j(b)}["'][^>]*\\bcontent\\s*=\\s*["']([^"']*)["']`,"i"),d=a.match(c);if(d)return k(d[1].trim());let e=RegExp(`<meta\\b[^>]*\\bcontent\\s*=\\s*["']([^"']*)["'][^>]*\\bname\\s*=\\s*["']${j(b)}["']`,"i"),f=a.match(e);return f?k(f[1].trim()):""}function j(a){return a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function k(a){return a.replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&quot;/g,'"').replace(/&#39;/g,"'")}function l(a){return a?a.trim().replace(/\s+/g,"-").replace(/[^A-Za-z0-9\-_:.]/g,""):""}},94735:a=>{a.exports=require("events")}};var b=require("../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,6106],()=>b(b.s=15458));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=6786,a.ids=[6786],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},51940:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,POST:()=>e.LO,dynamic:()=>h,runtime:()=>g});var e=c(80309),f=a([e]);e=(f.then?(await f)():f)[0];let g="nodejs",h="force-dynamic";d()}catch(a){d(a)}})},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},73852:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/instructions/config/route",pathname:"/api/instructions/config",filename:"route",bundlePath:"app/api/instructions/config/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/instructions/config/route.ts",nextConfigOutput:"",userland:()=>c(51940),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/instructions/config/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80309:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{LO:()=>p,fG:()=>o});var e=c(89705),f=c(7939),g=c(72891),h=c(770),i=a([g]);g=(i.then?(await i)():i)[0];let j=()=>Math.random().toString(36).slice(2,10),k=a=>{let b="string"==typeof a?a:"string"==typeof a?.text?a.text:null;if(null===b)return null;let c=b.trim().slice(0,2e3);return c?{id:"string"==typeof a?.id?a.id:"",text:c}:null},l=a=>{if(!Array.isArray(a))return[];let b=new Set,c=a=>{let c=a;for(;!c||b.has(c);)c=j();return b.add(c),c},d=new Set,e=[],f=(a,b,d)=>{d.has(a.text)||(d.add(a.text),b.push({id:c(a.id),text:a.text}))},g=a=>{d.has(a.text)||(d.add(a.text),e.push({id:c(a.id),text:a.text}))};for(let b of a){if(b&&"object"==typeof b&&Array.isArray(b.items)){let a="string"==typeof b.name?b.name.trim().slice(0,60):"",g=new Set,h=[],i=(a,b)=>{for(let c of a){if(b<4&&c&&"object"==typeof c&&Array.isArray(c.items)){i(c.items,b+1);continue}let a=k(c);a&&f(a,h,g)}};if(i(b.items,0),!a){for(let a of h)d.has(a.text)||(d.add(a.text),e.push(a));continue}e.push({id:c("string"==typeof b.id?b.id:""),name:a,items:h});continue}let a=k(b);a&&g(a)}return e},m=(a,b)=>"global"===b?(0,f.If)():a?(0,f.X)(a):null,n=(a,b)=>{let c=a?.instructions;if(Array.isArray(c)&&c.length>0)return c;let d=b?.prompts??b?.instructions;return Array.isArray(d)&&d.length>0?d:c},o=(0,g.RL)(a=>e.JkU(function*(){let b,c,d,i=new URL(a.url).searchParams,j=m(i.get("cwd"),i.get("scope"));if(!j)return yield*e.fJG(new h.yI({field:"cwd|scope",reason:"Missing cwd or scope"}));let k=yield*(b=i.get("cwd"),c=i.get("scope"),d="global"===c?(0,f.Xe)():b?(0,f.I8)(b):null,e.JkU(function*(){let a=a=>e.$mh({try:()=>(0,f.JE)(a,{}),catch:b=>new h.uU({path:a,op:"read",cause:b})}),b=yield*a(j);return d&&d!==j?n(b,(yield*a(d))):n(b,null)}));return(0,g.ok)({instructions:l(k)})})),p=(0,g.RL)(a=>e.JkU(function*(){let b=yield*(0,g.k9)(a),c=m(b.cwd??null,b.scope??null);if(!c)return yield*e.fJG(new h.yI({field:"cwd|scope",reason:"Missing cwd or scope"}));let d={instructions:l(b.instructions)};return yield*e.$mh({try:()=>(0,f.Ux)(c,()=>(0,f.An)(c,d)),catch:a=>new h.uU({path:c,op:"write",cause:a})}),(0,g.ok)({success:!0,instructions:d.instructions})}));d()}catch(a){d(a)}})},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=73852));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=6786,a.ids=[6786],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},18646:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/instructions/config/route",pathname:"/api/instructions/config",filename:"route",bundlePath:"app/api/instructions/config/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/instructions/config/route.ts",nextConfigOutput:"",userland:()=>c(51940),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/instructions/config/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},51940:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,POST:()=>e.LO,dynamic:()=>h,runtime:()=>g});var e=c(80309),f=a([e]);e=(f.then?(await f)():f)[0];let g="nodejs",h="force-dynamic";d()}catch(a){d(a)}})},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80309:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{LO:()=>p,fG:()=>o});var e=c(89705),f=c(7939),g=c(72891),h=c(770),i=a([g]);g=(i.then?(await i)():i)[0];let j=()=>Math.random().toString(36).slice(2,10),k=a=>{let b="string"==typeof a?a:"string"==typeof a?.text?a.text:null;if(null===b)return null;let c=b.trim().slice(0,2e3);return c?{id:"string"==typeof a?.id?a.id:"",text:c}:null},l=a=>{if(!Array.isArray(a))return[];let b=new Set,c=a=>{let c=a;for(;!c||b.has(c);)c=j();return b.add(c),c},d=new Set,e=[],f=(a,b,d)=>{d.has(a.text)||(d.add(a.text),b.push({id:c(a.id),text:a.text}))},g=a=>{d.has(a.text)||(d.add(a.text),e.push({id:c(a.id),text:a.text}))};for(let b of a){if(b&&"object"==typeof b&&Array.isArray(b.items)){let a="string"==typeof b.name?b.name.trim().slice(0,60):"",g=new Set,h=[],i=(a,b)=>{for(let c of a){if(b<4&&c&&"object"==typeof c&&Array.isArray(c.items)){i(c.items,b+1);continue}let a=k(c);a&&f(a,h,g)}};if(i(b.items,0),!a){for(let a of h)d.has(a.text)||(d.add(a.text),e.push(a));continue}e.push({id:c("string"==typeof b.id?b.id:""),name:a,items:h});continue}let a=k(b);a&&g(a)}return e},m=(a,b)=>"global"===b?(0,f.If)():a?(0,f.X)(a):null,n=(a,b)=>{let c=a?.instructions;if(Array.isArray(c)&&c.length>0)return c;let d=b?.prompts??b?.instructions;return Array.isArray(d)&&d.length>0?d:c},o=(0,g.RL)(a=>e.JkU(function*(){let b,c,d,i=new URL(a.url).searchParams,j=m(i.get("cwd"),i.get("scope"));if(!j)return yield*e.fJG(new h.yI({field:"cwd|scope",reason:"Missing cwd or scope"}));let k=yield*(b=i.get("cwd"),c=i.get("scope"),d="global"===c?(0,f.Xe)():b?(0,f.I8)(b):null,e.JkU(function*(){let a=a=>e.$mh({try:()=>(0,f.JE)(a,{}),catch:b=>new h.uU({path:a,op:"read",cause:b})}),b=yield*a(j);return d&&d!==j?n(b,(yield*a(d))):n(b,null)}));return(0,g.ok)({instructions:l(k)})})),p=(0,g.RL)(a=>e.JkU(function*(){let b=yield*(0,g.k9)(a),c=m(b.cwd??null,b.scope??null);if(!c)return yield*e.fJG(new h.yI({field:"cwd|scope",reason:"Missing cwd or scope"}));let d={instructions:l(b.instructions)};return yield*e.$mh({try:()=>(0,f.Ux)(c,()=>(0,f.An)(c,d)),catch:a=>new h.uU({path:c,op:"write",cause:a})}),(0,g.ok)({success:!0,instructions:d.instructions})}));d()}catch(a){d(a)}})},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=18646));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=5971,a.ids=[5971],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},35141:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,PUT:()=>e.Uc,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(44700),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},41204:a=>{a.exports=require("string_decoder")},44700:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>i,Uc:()=>k,fA:()=>h,fG:()=>j});var e=c(41726),f=c(58703),g=a([f]);f=(g.then?(await g)():g)[0];let h="nodejs",i="force-dynamic",{GET:j,PUT:k}=(0,f.P)(e.o5);d()}catch(a){d(a)}})},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},56068:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/kimi/credentials/route",pathname:"/api/kimi/credentials",filename:"route",bundlePath:"app/api/kimi/credentials/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/kimi/credentials/route.ts",nextConfigOutput:"",userland:()=>c(35141),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/kimi/credentials/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},58703:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{P:()=>j});var e=c(89705),f=c(72891),g=c(770),h=c(41726),i=a([f]);function j(a){let b=a=>({hasKey:!!a,maskedKey:(0,h.oO)(a)}),c=(0,f.RL)(c=>e.JkU(function*(){let d=yield*e.$mh({try:()=>a.read(),catch:b=>new g.uU({path:a.file,op:"read",cause:b})}),h="1"===new URL(c.url).searchParams.get("reveal");return(0,f.ok)(h?{...b(d),apiKey:d}:b(d))})),d=(0,f.RL)(c=>e.JkU(function*(){let d=yield*(0,f.k9)(c),h="string"==typeof d.apiKey?d.apiKey.trim():"";return yield*e.$mh({try:()=>a.write(h),catch:b=>new g.uU({path:a.file,op:"write",cause:b})}),(0,f.ok)(b(h))}));return{GET:c,PUT:d}}f=(i.then?(await i)():i)[0],d()}catch(a){d(a)}})},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=56068));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=5971,a.ids=[5971],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},35141:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,PUT:()=>e.Uc,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(44700),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},41204:a=>{a.exports=require("string_decoder")},44700:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>i,Uc:()=>k,fA:()=>h,fG:()=>j});var e=c(41726),f=c(58703),g=a([f]);f=(g.then?(await g)():g)[0];let h="nodejs",i="force-dynamic",{GET:j,PUT:k}=(0,f.P)(e.o5);d()}catch(a){d(a)}})},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},58703:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{P:()=>j});var e=c(89705),f=c(72891),g=c(770),h=c(41726),i=a([f]);function j(a){let b=a=>({hasKey:!!a,maskedKey:(0,h.oO)(a)}),c=(0,f.RL)(c=>e.JkU(function*(){let d=yield*e.$mh({try:()=>a.read(),catch:b=>new g.uU({path:a.file,op:"read",cause:b})}),h="1"===new URL(c.url).searchParams.get("reveal");return(0,f.ok)(h?{...b(d),apiKey:d}:b(d))})),d=(0,f.RL)(c=>e.JkU(function*(){let d=yield*(0,f.k9)(c),h="string"==typeof d.apiKey?d.apiKey.trim():"";return yield*e.$mh({try:()=>a.write(h),catch:b=>new g.uU({path:a.file,op:"write",cause:b})}),(0,f.ok)(b(h))}));return{GET:c,PUT:d}}f=(i.then?(await i)():i)[0],d()}catch(a){d(a)}})},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},87966:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/kimi/credentials/route",pathname:"/api/kimi/credentials",filename:"route",bundlePath:"app/api/kimi/credentials/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/kimi/credentials/route.ts",nextConfigOutput:"",userland:()=>c(35141),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/kimi/credentials/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=87966));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=2825,a.ids=[2825],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},3145:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(8186),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},6525:(a,b,c)=>{function d(a){let b=a instanceof Error?a.message:String(a);return b.includes("401")||b.includes("403")||b.includes("API key")?"auth":b.includes("abort")||b.includes("fetch failed")?"timeout":"protocol"}async function e(a){let b=await a.store.read();if(!b)throw Error(`${a.label} API key is not configured`);let c=await fetch(a.url,{headers:{Accept:"application/json",Authorization:`Bearer ${b}`},signal:AbortSignal.timeout(8e3)});if(!c.ok)throw Error(`Server returned ${c.status}`);return await c.json()}c.d(b,{Sw:()=>e,sU:()=>d})},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},8186:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>j,fA:()=>i,fG:()=>k});var e=c(41726),f=c(67928),g=c(79995),h=a([g]);g=(h.then?(await h)():h)[0];let i="nodejs",j="force-dynamic",k=(0,g.i)({provider:"kimi",label:"Kimi",url:`${f.KIMI_OPENAI_BASE_URL}/models`,store:e.o5,hiddenModelIds:["kimi-for-coding","kimi-for-coding-highspeed"]});d()}catch(a){d(a)}})},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},79995:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{i:()=>k});var e=c(89705),f=c(72891),g=c(770),h=c(6525),i=a([f]);function j(a){if(!a.id)return null;let b=a.think_efforts?.support?a.think_efforts.default_effort:void 0;return{id:a.id,...a.display_name&&{label:a.display_name},..."number"==typeof a.context_length&&{contextTokens:a.context_length},...b&&{effort:b}}}function k(a){return(0,f.RL)(()=>e.JkU(function*(){let b=yield*e.$mh({try:async()=>{let b=await (0,h.Sw)({url:"string"==typeof a.url?a.url:await a.url(),store:a.store,label:a.label}),c=new Set(a.hiddenModelIds);return(b.data||[]).map(j).filter(a=>!!a&&!c.has(a.id))},catch:b=>new g.Yv({provider:a.provider,kind:(0,h.sU)(b),cause:b})});return(0,f.ok)({models:b})}))}f=(i.then?(await i)():i)[0],d()}catch(a){d(a)}})},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},93246:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/kimi/models/route",pathname:"/api/kimi/models",filename:"route",bundlePath:"app/api/kimi/models/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/kimi/models/route.ts",nextConfigOutput:"",userland:()=>c(3145),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/kimi/models/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=93246));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=2825,a.ids=[2825],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},3145:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(8186),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5676:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/kimi/models/route",pathname:"/api/kimi/models",filename:"route",bundlePath:"app/api/kimi/models/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/kimi/models/route.ts",nextConfigOutput:"",userland:()=>c(3145),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/kimi/models/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},6525:(a,b,c)=>{function d(a){let b=a instanceof Error?a.message:String(a);return b.includes("401")||b.includes("403")||b.includes("API key")?"auth":b.includes("abort")||b.includes("fetch failed")?"timeout":"protocol"}async function e(a){let b=await a.store.read();if(!b)throw Error(`${a.label} API key is not configured`);let c=await fetch(a.url,{headers:{Accept:"application/json",Authorization:`Bearer ${b}`},signal:AbortSignal.timeout(8e3)});if(!c.ok)throw Error(`Server returned ${c.status}`);return await c.json()}c.d(b,{Sw:()=>e,sU:()=>d})},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},8186:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>j,fA:()=>i,fG:()=>k});var e=c(41726),f=c(67928),g=c(79995),h=a([g]);g=(h.then?(await h)():h)[0];let i="nodejs",j="force-dynamic",k=(0,g.i)({provider:"kimi",label:"Kimi",url:`${f.KIMI_OPENAI_BASE_URL}/models`,store:e.o5,hiddenModelIds:["kimi-for-coding","kimi-for-coding-highspeed"]});d()}catch(a){d(a)}})},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},79995:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{i:()=>k});var e=c(89705),f=c(72891),g=c(770),h=c(6525),i=a([f]);function j(a){if(!a.id)return null;let b=a.think_efforts?.support?a.think_efforts.default_effort:void 0;return{id:a.id,...a.display_name&&{label:a.display_name},..."number"==typeof a.context_length&&{contextTokens:a.context_length},...b&&{effort:b}}}function k(a){return(0,f.RL)(()=>e.JkU(function*(){let b=yield*e.$mh({try:async()=>{let b=await (0,h.Sw)({url:"string"==typeof a.url?a.url:await a.url(),store:a.store,label:a.label}),c=new Set(a.hiddenModelIds);return(b.data||[]).map(j).filter(a=>!!a&&!c.has(a.id))},catch:b=>new g.Yv({provider:a.provider,kind:(0,h.sU)(b),cause:b})});return(0,f.ok)({models:b})}))}f=(i.then?(await i)():i)[0],d()}catch(a){d(a)}})},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=5676));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=1508,a.ids=[1508],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},6525:(a,b,c)=>{function d(a){let b=a instanceof Error?a.message:String(a);return b.includes("401")||b.includes("403")||b.includes("API key")?"auth":b.includes("abort")||b.includes("fetch failed")?"timeout":"protocol"}async function e(a){let b=await a.store.read();if(!b)throw Error(`${a.label} API key is not configured`);let c=await fetch(a.url,{headers:{Accept:"application/json",Authorization:`Bearer ${b}`},signal:AbortSignal.timeout(8e3)});if(!c.ok)throw Error(`Server returned ${c.status}`);return await c.json()}c.d(b,{Sw:()=>e,sU:()=>d})},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},22970:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/kimi/usage/route",pathname:"/api/kimi/usage",filename:"route",bundlePath:"app/api/kimi/usage/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/kimi/usage/route.ts",nextConfigOutput:"",userland:()=>c(50864),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/kimi/usage/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},50864:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(75853),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},75853:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>n,fA:()=>m,fG:()=>r});var e=c(89705),f=c(72891),g=c(770),h=c(41726),i=c(67928),j=c(6525),k=a([f]);f=(k.then?(await k)():k)[0];let m="nodejs",n="force-dynamic",o=`${i.KIMI_OPENAI_BASE_URL}/usages`,p=a=>{if("string"!=typeof a||!a.trim())return null;let b=Number(a);return Number.isFinite(b)?b:null},q=(a,b)=>({label:a,limit:p(b?.limit),remaining:p(b?.remaining),resetTime:b?.resetTime??null});async function l(){let a=await (0,j.Sw)({url:o,store:h.o5,label:"Kimi"});return{tier:(a.user?.membership?.level??"").replace(/^LEVEL_/,""),windows:[q("plan",a.usage),...(a.limits||[]).map(a=>q(function(a){let b=a?.duration;if("number"!=typeof b||b<=0)return"window";let c=b*(({TIME_UNIT_SECOND:1/60,TIME_UNIT_MINUTE:1,TIME_UNIT_HOUR:60,TIME_UNIT_DAY:1440})[a?.timeUnit??""]??1);return c>=1440&&c%1440==0?`${c/1440}d`:c>=60&&c%60==0?`${c/60}h`:`${Math.round(c)}m`}(a.window),a.detail))]}}let r=(0,f.RL)(()=>e.JkU(function*(){let a=yield*e.$mh({try:()=>l(),catch:a=>new g.Yv({provider:"kimi",kind:(0,j.sU)(a),cause:a})});return(0,f.ok)(a)}));d()}catch(a){d(a)}})},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=22970));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=1508,a.ids=[1508],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},6525:(a,b,c)=>{function d(a){let b=a instanceof Error?a.message:String(a);return b.includes("401")||b.includes("403")||b.includes("API key")?"auth":b.includes("abort")||b.includes("fetch failed")?"timeout":"protocol"}async function e(a){let b=await a.store.read();if(!b)throw Error(`${a.label} API key is not configured`);let c=await fetch(a.url,{headers:{Accept:"application/json",Authorization:`Bearer ${b}`},signal:AbortSignal.timeout(8e3)});if(!c.ok)throw Error(`Server returned ${c.status}`);return await c.json()}c.d(b,{Sw:()=>e,sU:()=>d})},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},50864:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{GET:()=>e.fG,dynamic:()=>e.OR,runtime:()=>e.fA});var e=c(75853),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},75853:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{OR:()=>n,fA:()=>m,fG:()=>r});var e=c(89705),f=c(72891),g=c(770),h=c(41726),i=c(67928),j=c(6525),k=a([f]);f=(k.then?(await k)():k)[0];let m="nodejs",n="force-dynamic",o=`${i.KIMI_OPENAI_BASE_URL}/usages`,p=a=>{if("string"!=typeof a||!a.trim())return null;let b=Number(a);return Number.isFinite(b)?b:null},q=(a,b)=>({label:a,limit:p(b?.limit),remaining:p(b?.remaining),resetTime:b?.resetTime??null});async function l(){let a=await (0,j.Sw)({url:o,store:h.o5,label:"Kimi"});return{tier:(a.user?.membership?.level??"").replace(/^LEVEL_/,""),windows:[q("plan",a.usage),...(a.limits||[]).map(a=>q(function(a){let b=a?.duration;if("number"!=typeof b||b<=0)return"window";let c=b*(({TIME_UNIT_SECOND:1/60,TIME_UNIT_MINUTE:1,TIME_UNIT_HOUR:60,TIME_UNIT_DAY:1440})[a?.timeUnit??""]??1);return c>=1440&&c%1440==0?`${c/1440}d`:c>=60&&c%60==0?`${c/60}h`:`${Math.round(c)}m`}(a.window),a.detail))]}}let r=(0,f.RL)(()=>e.JkU(function*(){let a=yield*e.$mh({try:()=>l(),catch:a=>new g.Yv({provider:"kimi",kind:(0,j.sU)(a),cause:a})});return(0,f.ok)(a)}));d()}catch(a){d(a)}})},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")},97864:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/kimi/usage/route",pathname:"/api/kimi/usage",filename:"route",bundlePath:"app/api/kimi/usage/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/kimi/usage/route.ts",nextConfigOutput:"",userland:()=>c(50864),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/kimi/usage/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493],()=>b(b.s=97864));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=6493,a.ids=[6493],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5327:(a,b,c)=>{c.d(b,{c:()=>d});function d(a){let b=a.split(".").pop()?.toLowerCase();return b?["ts","tsx","js","jsx","mjs","cjs"].includes(b)?"typescript":["py","pyi"].includes(b)?"python":null:null}},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28483:a=>{a.exports=require("typescript/lib/tsserver.js")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83024:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{L:()=>m});var e=c(79748),f=c(33873),g=c(89705),h=c(72891),i=c(770),j=c(5327),k=c(15090),l=a([h]);h=(l.then?(await l)():l)[0];let m=(0,h.RL)(a=>g.JkU(function*(){let b=yield*(0,h.k9)(a);if(!b.filePath||!b.line||!b.column)return yield*g.fJG(new i.yI({field:b.filePath?b.line?"column":"line":"filePath",reason:"missing"}));let{cwd:c,filePath:d,line:l,column:m}=b,n=(0,j.c)(d);if(!n)return(0,h.ok)({definitions:[]});let o=c||process.cwd(),p=yield*g.$mh({try:()=>(0,k.bX)(n,o),catch:a=>new i.uV({message:"LSP server startup failed",cause:a})});if(!p)return(0,h.ok)({definitions:[]});let q=(0,f.resolve)(o,d);yield*g.$mh({try:async()=>{let a=await (0,e.readFile)(q,"utf-8");await (0,k.rL)(p,q,a)},catch:a=>new i.yI({field:"filePath",reason:`cannot read file: ${String(a)}`})});let r=yield*g.$mh({try:()=>p.adapter.definition(q,l,m),catch:a=>new i.uV({message:"LSP definition failed",cause:a})});return(0,h.ok)({definitions:r})}));d()}catch(a){d(a)}})},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},86692:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/lsp/definition/route",pathname:"/api/lsp/definition",filename:"route",bundlePath:"app/api/lsp/definition/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/lsp/definition/route.ts",nextConfigOutput:"",userland:()=>c(95823),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/lsp/definition/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")},95823:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{POST:()=>e.L});var e=c(83024),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,5090],()=>b(b.s=86692));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=6493,a.ids=[6493],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5327:(a,b,c)=>{c.d(b,{c:()=>d});function d(a){let b=a.split(".").pop()?.toLowerCase();return b?["ts","tsx","js","jsx","mjs","cjs"].includes(b)?"typescript":["py","pyi"].includes(b)?"python":null:null}},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28483:a=>{a.exports=require("typescript/lib/tsserver.js")},28574:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/lsp/definition/route",pathname:"/api/lsp/definition",filename:"route",bundlePath:"app/api/lsp/definition/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/lsp/definition/route.ts",nextConfigOutput:"",userland:()=>c(95823),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/lsp/definition/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83024:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{L:()=>m});var e=c(79748),f=c(33873),g=c(89705),h=c(72891),i=c(770),j=c(5327),k=c(15090),l=a([h]);h=(l.then?(await l)():l)[0];let m=(0,h.RL)(a=>g.JkU(function*(){let b=yield*(0,h.k9)(a);if(!b.filePath||!b.line||!b.column)return yield*g.fJG(new i.yI({field:b.filePath?b.line?"column":"line":"filePath",reason:"missing"}));let{cwd:c,filePath:d,line:l,column:m}=b,n=(0,j.c)(d);if(!n)return(0,h.ok)({definitions:[]});let o=c||process.cwd(),p=yield*g.$mh({try:()=>(0,k.bX)(n,o),catch:a=>new i.uV({message:"LSP server startup failed",cause:a})});if(!p)return(0,h.ok)({definitions:[]});let q=(0,f.resolve)(o,d);yield*g.$mh({try:async()=>{let a=await (0,e.readFile)(q,"utf-8");await (0,k.rL)(p,q,a)},catch:a=>new i.yI({field:"filePath",reason:`cannot read file: ${String(a)}`})});let r=yield*g.$mh({try:()=>p.adapter.definition(q,l,m),catch:a=>new i.uV({message:"LSP definition failed",cause:a})});return(0,h.ok)({definitions:r})}));d()}catch(a){d(a)}})},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")},95823:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{POST:()=>e.L});var e=c(83024),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,5090],()=>b(b.s=28574));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=8872,a.ids=[8872],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},262:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{POST:()=>e.L});var e=c(16351),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5327:(a,b,c)=>{c.d(b,{c:()=>d});function d(a){let b=a.split(".").pop()?.toLowerCase();return b?["ts","tsx","js","jsx","mjs","cjs"].includes(b)?"typescript":["py","pyi"].includes(b)?"python":null:null}},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},16351:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{L:()=>m});var e=c(79748),f=c(33873),g=c(89705),h=c(72891),i=c(770),j=c(5327),k=c(15090),l=a([h]);h=(l.then?(await l)():l)[0];let m=(0,h.RL)(a=>g.JkU(function*(){let b=yield*(0,h.k9)(a);if(!b.filePath||!b.line||!b.column)return yield*g.fJG(new i.yI({field:b.filePath?b.line?"column":"line":"filePath",reason:"missing"}));let{cwd:c,filePath:d,line:l,column:m}=b,n=(0,j.c)(d);if(!n)return(0,h.ok)({hover:null});let o=c||process.cwd(),p=yield*g.$mh({try:()=>(0,k.bX)(n,o),catch:a=>new i.uV({message:"LSP server startup failed",cause:a})});if(!p)return(0,h.ok)({hover:null});let q=(0,f.resolve)(o,d);yield*g.$mh({try:async()=>{let a=await (0,e.readFile)(q,"utf-8");await (0,k.rL)(p,q,a)},catch:a=>new i.yI({field:"filePath",reason:`cannot read file: ${String(a)}`})});let r=yield*g.$mh({try:()=>p.adapter.hover(q,l,m),catch:a=>new i.uV({message:"LSP hover failed",cause:a})});return(0,h.ok)({hover:r})}));d()}catch(a){d(a)}})},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28483:a=>{a.exports=require("typescript/lib/tsserver.js")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},65168:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/lsp/hover/route",pathname:"/api/lsp/hover",filename:"route",bundlePath:"app/api/lsp/hover/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/lsp/hover/route.ts",nextConfigOutput:"",userland:()=>c(262),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/lsp/hover/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,5090],()=>b(b.s=65168));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=8872,a.ids=[8872],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},262:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{POST:()=>e.L});var e=c(16351),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},1932:a=>{a.exports=require("url")},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5327:(a,b,c)=>{c.d(b,{c:()=>d});function d(a){let b=a.split(".").pop()?.toLowerCase();return b?["ts","tsx","js","jsx","mjs","cjs"].includes(b)?"typescript":["py","pyi"].includes(b)?"python":null:null}},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},16351:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{L:()=>m});var e=c(79748),f=c(33873),g=c(89705),h=c(72891),i=c(770),j=c(5327),k=c(15090),l=a([h]);h=(l.then?(await l)():l)[0];let m=(0,h.RL)(a=>g.JkU(function*(){let b=yield*(0,h.k9)(a);if(!b.filePath||!b.line||!b.column)return yield*g.fJG(new i.yI({field:b.filePath?b.line?"column":"line":"filePath",reason:"missing"}));let{cwd:c,filePath:d,line:l,column:m}=b,n=(0,j.c)(d);if(!n)return(0,h.ok)({hover:null});let o=c||process.cwd(),p=yield*g.$mh({try:()=>(0,k.bX)(n,o),catch:a=>new i.uV({message:"LSP server startup failed",cause:a})});if(!p)return(0,h.ok)({hover:null});let q=(0,f.resolve)(o,d);yield*g.$mh({try:async()=>{let a=await (0,e.readFile)(q,"utf-8");await (0,k.rL)(p,q,a)},catch:a=>new i.yI({field:"filePath",reason:`cannot read file: ${String(a)}`})});let r=yield*g.$mh({try:()=>p.adapter.hover(q,l,m),catch:a=>new i.uV({message:"LSP hover failed",cause:a})});return(0,h.ok)({hover:r})}));d()}catch(a){d(a)}})},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28483:a=>{a.exports=require("typescript/lib/tsserver.js")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},70442:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/lsp/hover/route",pathname:"/api/lsp/hover",filename:"route",bundlePath:"app/api/lsp/hover/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/lsp/hover/route.ts",nextConfigOutput:"",userland:()=>c(262),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/lsp/hover/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,5090],()=>b(b.s=70442));module.exports=c})();
@@ -1 +1 @@
1
- "use strict";(()=>{var a={};a.id=5376,a.ids=[5376],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},3468:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{POST:()=>e.L});var e=c(75447),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5327:(a,b,c)=>{c.d(b,{c:()=>d});function d(a){let b=a.split(".").pop()?.toLowerCase();return b?["ts","tsx","js","jsx","mjs","cjs"].includes(b)?"typescript":["py","pyi"].includes(b)?"python":null:null}},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28483:a=>{a.exports=require("typescript/lib/tsserver.js")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},50758:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/lsp/references/route",pathname:"/api/lsp/references",filename:"route",bundlePath:"app/api/lsp/references/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/lsp/references/route.ts",nextConfigOutput:"",userland:()=>c(3468),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/lsp/references/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},75447:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{L:()=>m});var e=c(79748),f=c(33873),g=c(89705),h=c(72891),i=c(770),j=c(5327),k=c(15090),l=a([h]);h=(l.then?(await l)():l)[0];let m=(0,h.RL)(a=>g.JkU(function*(){let b=yield*(0,h.k9)(a);if(!b.filePath||!b.line||!b.column)return yield*g.fJG(new i.yI({field:b.filePath?b.line?"column":"line":"filePath",reason:"missing"}));let{cwd:c,filePath:d,line:l,column:m}=b,n=(0,j.c)(d);if(!n)return(0,h.ok)({references:[]});let o=c||process.cwd(),p=yield*g.$mh({try:()=>(0,k.bX)(n,o),catch:a=>new i.uV({message:"LSP server startup failed",cause:a})});if(!p)return(0,h.ok)({references:[]});let q=(0,f.resolve)(o,d);yield*g.$mh({try:async()=>{let a=await (0,e.readFile)(q,"utf-8");await (0,k.rL)(p,q,a)},catch:a=>new i.yI({field:"filePath",reason:`cannot read file: ${String(a)}`})});let r=yield*g.$mh({try:()=>p.adapter.references(q,l,m),catch:a=>new i.uV({message:"LSP references failed",cause:a})});return(0,h.ok)({references:r})}));d()}catch(a){d(a)}})},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,5090],()=>b(b.s=50758));module.exports=c})();
1
+ "use strict";(()=>{var a={};a.id=5376,a.ids=[5376],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},1932:a=>{a.exports=require("url")},3468:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.r(b),c.d(b,{POST:()=>e.L});var e=c(75447),f=a([e]);e=(f.then?(await f)():f)[0],d()}catch(a){d(a)}})},4573:a=>{a.exports=require("node:buffer")},4984:a=>{a.exports=require("readline")},5327:(a,b,c)=>{c.d(b,{c:()=>d});function d(a){let b=a.split(".").pop()?.toLowerCase();return b?["ts","tsx","js","jsx","mjs","cjs"].includes(b)?"typescript":["py","pyi"].includes(b)?"python":null:null}},7156:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>z,patchFetch:()=>y,routeModule:()=>u,serverHooks:()=>x,workAsyncStorage:()=>v,workUnitAsyncStorage:()=>w});var d=c(19225),e=c(84006),f=c(8317),g=c(99373),h=c(34775),i=c(24235),j=c(261),k=c(54365),l=c(90771),m=c(73461),n=c(67798),o=c(92280),p=c(62018),q=c(45696),r=c(47929),s=c(86439),t=c(37527);let u=new d.AppRouteRouteModule({definition:{kind:e.RouteKind.APP_ROUTE,page:"/api/lsp/references/route",pathname:"/api/lsp/references",filename:"route",bundlePath:"app/api/lsp/references/route"},distDir:".next-prod",relativeProjectDir:"",resolvedPagePath:"/home/runner/work/cockpit/cockpit/src/app/api/lsp/references/route.ts",nextConfigOutput:"",userland:()=>c(3468),...{}}),{workAsyncStorage:v,workUnitAsyncStorage:w,serverHooks:x}=u;function y(){return(0,f.patchFetch)({workAsyncStorage:v,workUnitAsyncStorage:w})}async function z(a,b,c){c.requestMeta&&(0,g.setRequestMeta)(a,c.requestMeta),u.isDev&&(0,g.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/lsp/references/route";"/index"===d&&(d="/");let f=await u.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!f)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:v,deploymentId:w,params:x,nextConfig:y,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=f,I=(0,j.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(y.adapterPath)return await K();throw new s.NoFallbackError}}let L=null;!J||u.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===u.isDev||!J,N=J&&!M;H&&G&&(0,i.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,h.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,g.getRequestMeta)(a,"minimalMode"),T=(0,g.getRequestMeta)(a,"incrementalCache")||await u.getIncrementalCache(a,y,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:x,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:M,incrementalCache:T,hmrRefreshHash:(0,g.getRequestMeta)(a,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>u.onRequestError(a,b,d,e,C)},sharedContext:{buildId:v,deploymentId:w}},V=new k.NodeNextRequest(a),W=new k.NodeNextResponse(b),X=l.NextRequestAdapter.fromNodeNextRequest(V,(0,l.signalFromNodeResponse)(b)),Y=async({previousCacheEntry:e})=>{try{if(!S&&D&&E&&!e)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await u.handle(X,U);a.fetchMetrics=U.renderOpts.fetchMetrics;let f=U.renderOpts.pendingWaitUntil;f&&c.waitUntil&&(c.waitUntil(f),f=void 0);let g=U.renderOpts.collectedTags;if(!J)return await (0,o.I)(V,W,d,f),null;{let a=await d.blob(),b=(0,p.toNodeOutgoingHttpHeaders)(d.headers);g&&(b[r.NEXT_CACHE_TAGS_HEADER]=g),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=r.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=r.INFINITE_CACHE?!1!==c&&c>0?y.expireTime:void 0:U.renderOpts.collectedExpire;return{value:{kind:t.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==e?void 0:e.isStale)&&await u.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},Z=async(d,f)=>{try{var g,i;let d=await u.handleResponse({req:a,nextConfig:y,cacheKey:L,routeKind:e.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:Y,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return;if((null==d||null==(g=d.value)?void 0:g.kind)!==t.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==d||null==(i=d.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":d.isMiss?"MISS":d.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let f=(0,p.fromNodeOutgoingHttpHeaders)(d.value.headers);S&&J||f.delete(r.NEXT_CACHE_TAGS_HEADER),!d.cacheControl||b.getHeader("Cache-Control")||f.get("Cache-Control")||f.set("Cache-Control",(0,q.getCacheControlHeader)(d.cacheControl)),await (0,o.I)(V,W,new Response(d.value.body,{headers:f,status:d.value.status||200}));return}catch(b){if(b instanceof s.NoFallbackError||await u.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,n.getRevalidateReason)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;await (0,o.I)(V,W,new Response(null,{status:500}));return}finally{(()=>{if(!d)return;let a=b.statusCode;d.setAttributes({"http.status_code":a,"next.rsc":!1}),a&&a>=500&&(d.setStatus({code:h.SpanStatusCode.ERROR}),d.setAttribute("error.type",a.toString()));let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==m.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=c.get("next.route")||I,g=`${O} ${e}`;d.setAttributes({"next.route":e,"http.route":e,"next.span_name":g}),d.updateName(g),f&&f!==d&&(f.setAttribute("http.route",e),f.updateName(g))})()}};if(R&&Q)await Z(Q,void 0);else{let b=P.getActiveScopeSpan();await P.withPropagatedContext(a.headers,()=>P.trace(m.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:h.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},a=>Z(a,b)),void 0,!R)}}},8128:a=>{a.exports=require("next/dist/server/runtime-reacts.external.js")},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},12412:a=>{a.exports=require("assert")},14985:a=>{a.exports=require("dns")},19771:a=>{a.exports=require("process")},19879:a=>{a.exports=import("@anthropic-ai/claude-agent-sdk")},21820:a=>{a.exports=require("os")},27910:a=>{a.exports=require("stream")},28354:a=>{a.exports=require("util")},28483:a=>{a.exports=require("typescript/lib/tsserver.js")},28802:a=>{a.exports=import("@earendil-works/pi-ai")},29021:a=>{a.exports=require("fs")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},31421:a=>{a.exports=require("node:child_process")},33873:a=>{a.exports=require("path")},34631:a=>{a.exports=require("tls")},41204:a=>{a.exports=require("string_decoder")},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},48161:a=>{a.exports=require("node:os")},51181:a=>{a.exports=require("web-push")},51455:a=>{a.exports=require("node:fs/promises")},53053:a=>{a.exports=require("node:diagnostics_channel")},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},64939:a=>{a.exports=import("pg")},66136:a=>{a.exports=require("timers")},73024:a=>{a.exports=require("node:fs")},73136:a=>{a.exports=require("node:url")},74075:a=>{a.exports=require("zlib")},75342:a=>{a.exports=require("@vscode/ripgrep")},75430:a=>{a.exports=import("@earendil-works/pi-coding-agent")},75447:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{L:()=>m});var e=c(79748),f=c(33873),g=c(89705),h=c(72891),i=c(770),j=c(5327),k=c(15090),l=a([h]);h=(l.then?(await l)():l)[0];let m=(0,h.RL)(a=>g.JkU(function*(){let b=yield*(0,h.k9)(a);if(!b.filePath||!b.line||!b.column)return yield*g.fJG(new i.yI({field:b.filePath?b.line?"column":"line":"filePath",reason:"missing"}));let{cwd:c,filePath:d,line:l,column:m}=b,n=(0,j.c)(d);if(!n)return(0,h.ok)({references:[]});let o=c||process.cwd(),p=yield*g.$mh({try:()=>(0,k.bX)(n,o),catch:a=>new i.uV({message:"LSP server startup failed",cause:a})});if(!p)return(0,h.ok)({references:[]});let q=(0,f.resolve)(o,d);yield*g.$mh({try:async()=>{let a=await (0,e.readFile)(q,"utf-8");await (0,k.rL)(p,q,a)},catch:a=>new i.yI({field:"filePath",reason:`cannot read file: ${String(a)}`})});let r=yield*g.$mh({try:()=>p.adapter.references(q,l,m),catch:a=>new i.uV({message:"LSP references failed",cause:a})});return(0,h.ok)({references:r})}));d()}catch(a){d(a)}})},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},79428:a=>{a.exports=require("buffer")},79646:a=>{a.exports=require("child_process")},79748:a=>{a.exports=require("fs/promises")},80481:a=>{a.exports=require("node:readline")},83997:a=>{a.exports=require("tty")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},91645:a=>{a.exports=require("net")},94735:a=>{a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,9705,2679,7347,6495,9830,2493,5090],()=>b(b.s=7156));module.exports=c})();