six-degrees 0.4.0 → 0.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (209) hide show
  1. package/.next/standalone/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/build-manifest.json +3 -3
  3. package/.next/standalone/.next/prerender-manifest.json +14 -14
  4. package/.next/standalone/.next/server/app/_global-error/page.js.nft.json +1 -1
  5. package/.next/standalone/.next/server/app/_global-error.html +1 -1
  6. package/.next/standalone/.next/server/app/_global-error.rsc +2 -2
  7. package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  8. package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +2 -2
  9. package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  10. package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
  11. package/.next/standalone/.next/server/app/_not-found.html +1 -1
  12. package/.next/standalone/.next/server/app/_not-found.rsc +2 -2
  13. package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
  14. package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  15. package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  16. package/.next/standalone/.next/server/app/api/admin-delete/route.js.nft.json +1 -1
  17. package/.next/standalone/.next/server/app/api/admin-update/route.js.nft.json +1 -1
  18. package/.next/standalone/.next/server/app/api/bridges/route.js.nft.json +1 -1
  19. package/.next/standalone/.next/server/app/api/bulk-import/route.js.nft.json +1 -1
  20. package/.next/standalone/.next/server/app/api/company-scores/legacy/route.js.nft.json +1 -1
  21. package/.next/standalone/.next/server/app/api/company-scores/route.js.nft.json +1 -1
  22. package/.next/standalone/.next/server/app/api/connections/route.js.nft.json +1 -1
  23. package/.next/standalone/.next/server/app/api/data/export/route.js.nft.json +1 -1
  24. package/.next/standalone/.next/server/app/api/data/import/route.js.nft.json +1 -1
  25. package/.next/standalone/.next/server/app/api/data/restart/route.js.nft.json +1 -1
  26. package/.next/standalone/.next/server/app/api/data/reveal/route.js.nft.json +1 -1
  27. package/.next/standalone/.next/server/app/api/data/route.js.nft.json +1 -1
  28. package/.next/standalone/.next/server/app/api/delete-cluster/route.js.nft.json +1 -1
  29. package/.next/standalone/.next/server/app/api/ingest/route.js +1 -1
  30. package/.next/standalone/.next/server/app/api/ingest/route.js.nft.json +1 -1
  31. package/.next/standalone/.next/server/app/api/network/route.js.nft.json +1 -1
  32. package/.next/standalone/.next/server/app/api/notifications/route.js.nft.json +1 -1
  33. package/.next/standalone/.next/server/app/api/outreach/route.js.nft.json +1 -1
  34. package/.next/standalone/.next/server/app/api/queue/route.js.nft.json +1 -1
  35. package/.next/standalone/.next/server/app/api/scraper/route.js.nft.json +1 -1
  36. package/.next/standalone/.next/server/app/api/settings/route.js.nft.json +1 -1
  37. package/.next/standalone/.next/server/app/api/settings/sector-preview/route.js.nft.json +1 -1
  38. package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route.js.nft.json +1 -1
  39. package/.next/standalone/.next/server/app/api/setup-profile/route.js.nft.json +1 -1
  40. package/.next/standalone/.next/server/app/api/unlock/route.js.nft.json +1 -1
  41. package/.next/standalone/.next/server/app/api/update/route.js.nft.json +1 -1
  42. package/.next/standalone/.next/server/app/api/update-images/route.js.nft.json +1 -1
  43. package/.next/standalone/.next/server/app/api/users/route.js.nft.json +1 -1
  44. package/.next/standalone/.next/server/app/avatars/[file]/route.js.nft.json +1 -1
  45. package/.next/standalone/.next/server/app/favicon.ico/route.js.nft.json +1 -1
  46. package/.next/standalone/.next/server/app/favicon.ico.body +0 -0
  47. package/.next/standalone/.next/server/app/import/page.js.nft.json +1 -1
  48. package/.next/standalone/.next/server/app/import.html +1 -1
  49. package/.next/standalone/.next/server/app/import.rsc +2 -2
  50. package/.next/standalone/.next/server/app/import.segments/_full.segment.rsc +2 -2
  51. package/.next/standalone/.next/server/app/import.segments/_tree.segment.rsc +1 -1
  52. package/.next/standalone/.next/server/app/import.segments/import/__PAGE__.segment.rsc +1 -1
  53. package/.next/standalone/.next/server/app/index.html +1 -1
  54. package/.next/standalone/.next/server/app/index.rsc +3 -3
  55. package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
  56. package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +3 -3
  57. package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
  58. package/.next/standalone/.next/server/app/launch/page.js.nft.json +1 -1
  59. package/.next/standalone/.next/server/app/launch.html +2 -2
  60. package/.next/standalone/.next/server/app/launch.rsc +2 -2
  61. package/.next/standalone/.next/server/app/launch.segments/_full.segment.rsc +2 -2
  62. package/.next/standalone/.next/server/app/launch.segments/_tree.segment.rsc +1 -1
  63. package/.next/standalone/.next/server/app/launch.segments/launch/__PAGE__.segment.rsc +1 -1
  64. package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
  65. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  66. package/.next/standalone/.next/server/app/paths/page.js.nft.json +1 -1
  67. package/.next/standalone/.next/server/app/paths/page_client-reference-manifest.js +1 -1
  68. package/.next/standalone/.next/server/app/paths.html +1 -1
  69. package/.next/standalone/.next/server/app/paths.rsc +3 -3
  70. package/.next/standalone/.next/server/app/paths.segments/_full.segment.rsc +3 -3
  71. package/.next/standalone/.next/server/app/paths.segments/_tree.segment.rsc +1 -1
  72. package/.next/standalone/.next/server/app/paths.segments/paths/__PAGE__.segment.rsc +2 -2
  73. package/.next/standalone/.next/server/app/profile/page.js.nft.json +1 -1
  74. package/.next/standalone/.next/server/app/profile/page_client-reference-manifest.js +1 -1
  75. package/.next/standalone/.next/server/app/profile.html +1 -1
  76. package/.next/standalone/.next/server/app/profile.rsc +3 -3
  77. package/.next/standalone/.next/server/app/profile.segments/_full.segment.rsc +3 -3
  78. package/.next/standalone/.next/server/app/profile.segments/_tree.segment.rsc +1 -1
  79. package/.next/standalone/.next/server/app/profile.segments/profile/__PAGE__.segment.rsc +2 -2
  80. package/.next/standalone/.next/server/app/queue/page.js.nft.json +1 -1
  81. package/.next/standalone/.next/server/app/queue/page_client-reference-manifest.js +1 -1
  82. package/.next/standalone/.next/server/app/queue.html +1 -1
  83. package/.next/standalone/.next/server/app/queue.rsc +3 -3
  84. package/.next/standalone/.next/server/app/queue.segments/_full.segment.rsc +3 -3
  85. package/.next/standalone/.next/server/app/queue.segments/_tree.segment.rsc +1 -1
  86. package/.next/standalone/.next/server/app/queue.segments/queue/__PAGE__.segment.rsc +2 -2
  87. package/.next/standalone/.next/server/app/scores/page.js.nft.json +1 -1
  88. package/.next/standalone/.next/server/app/scores.html +1 -1
  89. package/.next/standalone/.next/server/app/scores.rsc +2 -2
  90. package/.next/standalone/.next/server/app/scores.segments/_full.segment.rsc +2 -2
  91. package/.next/standalone/.next/server/app/scores.segments/_tree.segment.rsc +1 -1
  92. package/.next/standalone/.next/server/app/scores.segments/scores/__PAGE__.segment.rsc +1 -1
  93. package/.next/standalone/.next/server/app/settings/page.js.nft.json +1 -1
  94. package/.next/standalone/.next/server/app/settings.html +1 -1
  95. package/.next/standalone/.next/server/app/settings.rsc +2 -2
  96. package/.next/standalone/.next/server/app/settings.segments/_full.segment.rsc +2 -2
  97. package/.next/standalone/.next/server/app/settings.segments/_tree.segment.rsc +1 -1
  98. package/.next/standalone/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +1 -1
  99. package/.next/standalone/.next/server/app/setup/page.js.nft.json +1 -1
  100. package/.next/standalone/.next/server/app/setup/page_client-reference-manifest.js +1 -1
  101. package/.next/standalone/.next/server/app/setup.html +1 -1
  102. package/.next/standalone/.next/server/app/setup.rsc +3 -3
  103. package/.next/standalone/.next/server/app/setup.segments/_full.segment.rsc +3 -3
  104. package/.next/standalone/.next/server/app/setup.segments/_tree.segment.rsc +1 -1
  105. package/.next/standalone/.next/server/app/setup.segments/setup/__PAGE__.segment.rsc +2 -2
  106. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0e0fei3._.js +1 -1
  107. package/.next/standalone/.next/server/chunks/{[root-of-the-server]__03ydxxh._.js → [root-of-the-server]__20tmem7._.js} +1 -1
  108. package/.next/standalone/.next/server/chunks/_1_fynia._.js +6 -6
  109. package/.next/standalone/.next/server/chunks/_1itd1o_._.js +1 -1
  110. package/.next/standalone/.next/server/chunks/_1iwkh8t._.js +1 -1
  111. package/.next/standalone/.next/server/chunks/_1mxn_lb._.js +1 -1
  112. package/.next/standalone/.next/server/chunks/lib_db-client_15le7cw.js +21 -7
  113. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__00d8snt._.js +1 -1
  114. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__00g61b8._.js +1 -1
  115. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__08lf3gy._.js +1 -1
  116. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0hg5gib._.js +1 -1
  117. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ho-u0w._.js +1 -1
  118. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ze473p._.js +1 -1
  119. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1194jps._.js +1 -1
  120. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1cnxxc9._.js +1 -1
  121. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1ll97ry._.js +1 -1
  122. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1m0255u._.js +1 -1
  123. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1w9z0zv._.js +1 -1
  124. package/.next/standalone/.next/server/chunks/ssr/_15xuwkv._.js +1 -1
  125. package/.next/standalone/.next/server/chunks/ssr/_1hgd5dp._.js +1 -1
  126. package/.next/standalone/.next/server/chunks/ssr/_20w06i-._.js +1 -1
  127. package/.next/standalone/.next/server/chunks/ssr/app_page_1fazqbf.js +4 -4
  128. package/.next/standalone/.next/server/chunks/ssr/app_paths_page_1ol90m7.js +1 -1
  129. package/.next/standalone/.next/server/chunks/ssr/app_setup_page_1-282zx.js +6 -2
  130. package/.next/standalone/.next/server/middleware-build-manifest.js +3 -3
  131. package/.next/standalone/.next/server/middleware-manifest.json +5 -5
  132. package/.next/standalone/.next/server/pages/404.html +1 -1
  133. package/.next/standalone/.next/server/pages/500.html +1 -1
  134. package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
  135. package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
  136. package/.next/standalone/.next/static/chunks/{3e8zg6ctvvb8p.js → 049vavjsmqgmn.js} +3 -3
  137. package/.next/standalone/.next/static/chunks/0ljxa-wk_iu__.js +18 -0
  138. package/.next/standalone/.next/static/chunks/0mp9b72fm-jp6.js +6 -0
  139. package/.next/standalone/.next/static/chunks/1pre1cotntk6-.js +1 -0
  140. package/.next/standalone/.next/static/chunks/{18xu0fbgo_qz-.js → 22x2_r768-u5i.js} +1 -1
  141. package/.next/standalone/.next/static/chunks/2p5yt1o9tnxjn.js +2 -0
  142. package/.next/standalone/.next/static/chunks/3zs_6-nn0dapb.js +1 -0
  143. package/.next/standalone/.next/static/media/favicon.0zdzw5kurn8m-.ico +0 -0
  144. package/.next/standalone/CHANGELOG.md +86 -0
  145. package/.next/standalone/app/api/admin-delete/route.js +3 -0
  146. package/.next/standalone/app/api/ingest/route.js +13 -0
  147. package/.next/standalone/app/api/scraper/route.js +10 -2
  148. package/.next/standalone/app/components/ChainView.js +76 -15
  149. package/.next/standalone/app/components/FilterPanel.js +37 -1
  150. package/.next/standalone/app/components/ForceGraph.js +144 -12
  151. package/.next/standalone/app/components/LinkedInLimits.js +20 -3
  152. package/.next/standalone/app/components/OrbitGraph.js +92 -30
  153. package/.next/standalone/app/components/Sidebar.js +37 -0
  154. package/.next/standalone/app/components/views.js +7 -5
  155. package/.next/standalone/app/favicon.ico +0 -0
  156. package/.next/standalone/app/page.js +24 -7
  157. package/.next/standalone/app/paths/page.js +8 -1
  158. package/.next/standalone/db/schema.js +14 -0
  159. package/.next/standalone/lib/brokerage.js +94 -0
  160. package/.next/standalone/lib/chain-layout.js +89 -0
  161. package/.next/standalone/lib/circle.js +23 -4
  162. package/.next/standalone/lib/degrees.js +30 -0
  163. package/.next/standalone/lib/dot-rings.js +21 -0
  164. package/.next/standalone/lib/ingest.js +3 -3
  165. package/.next/standalone/lib/linkedin-limits.js +9 -4
  166. package/.next/standalone/lib/reach.js +22 -1
  167. package/.next/standalone/lib/search-risk.js +38 -0
  168. package/.next/standalone/lib/ties.js +23 -0
  169. package/.next/standalone/package-lock.json +2 -2
  170. package/.next/standalone/package.json +1 -1
  171. package/.next/standalone/scripts/scrape.py +50 -12
  172. package/.next/static/chunks/{3e8zg6ctvvb8p.js → 049vavjsmqgmn.js} +3 -3
  173. package/.next/static/chunks/0ljxa-wk_iu__.js +18 -0
  174. package/.next/static/chunks/0mp9b72fm-jp6.js +6 -0
  175. package/.next/static/chunks/1pre1cotntk6-.js +1 -0
  176. package/.next/static/chunks/{18xu0fbgo_qz-.js → 22x2_r768-u5i.js} +1 -1
  177. package/.next/static/chunks/2p5yt1o9tnxjn.js +2 -0
  178. package/.next/static/chunks/3zs_6-nn0dapb.js +1 -0
  179. package/.next/static/media/favicon.0zdzw5kurn8m-.ico +0 -0
  180. package/CHANGELOG.md +86 -0
  181. package/db/schema.js +14 -0
  182. package/lib/brokerage.js +94 -0
  183. package/lib/chain-layout.js +89 -0
  184. package/lib/circle.js +23 -4
  185. package/lib/degrees.js +30 -0
  186. package/lib/dot-rings.js +21 -0
  187. package/lib/ingest.js +3 -3
  188. package/lib/linkedin-limits.js +9 -4
  189. package/lib/reach.js +22 -1
  190. package/lib/search-risk.js +38 -0
  191. package/lib/ties.js +23 -0
  192. package/package.json +1 -1
  193. package/scripts/scrape.py +50 -12
  194. package/.next/standalone/.next/static/chunks/0w76iraw7ij3k.js +0 -18
  195. package/.next/standalone/.next/static/chunks/135n87ydxjrra.js +0 -2
  196. package/.next/standalone/.next/static/chunks/2pnbm1z6j7xab.js +0 -1
  197. package/.next/standalone/.next/static/chunks/3qh78g2aqhprd.js +0 -2
  198. package/.next/standalone/.next/static/media/favicon.2vob68tjqpejf.ico +0 -0
  199. package/.next/static/chunks/0w76iraw7ij3k.js +0 -18
  200. package/.next/static/chunks/135n87ydxjrra.js +0 -2
  201. package/.next/static/chunks/2pnbm1z6j7xab.js +0 -1
  202. package/.next/static/chunks/3qh78g2aqhprd.js +0 -2
  203. package/.next/static/media/favicon.2vob68tjqpejf.ico +0 -0
  204. /package/.next/standalone/.next/static/{WseE_5HuU-1q0ywC9CP3U → wGVrXBkFLmEB4snfhtOcO}/_buildManifest.js +0 -0
  205. /package/.next/standalone/.next/static/{WseE_5HuU-1q0ywC9CP3U → wGVrXBkFLmEB4snfhtOcO}/_clientMiddlewareManifest.js +0 -0
  206. /package/.next/standalone/.next/static/{WseE_5HuU-1q0ywC9CP3U → wGVrXBkFLmEB4snfhtOcO}/_ssgManifest.js +0 -0
  207. /package/.next/static/{WseE_5HuU-1q0ywC9CP3U → wGVrXBkFLmEB4snfhtOcO}/_buildManifest.js +0 -0
  208. /package/.next/static/{WseE_5HuU-1q0ywC9CP3U → wGVrXBkFLmEB4snfhtOcO}/_clientMiddlewareManifest.js +0 -0
  209. /package/.next/static/{WseE_5HuU-1q0ywC9CP3U → wGVrXBkFLmEB4snfhtOcO}/_ssgManifest.js +0 -0
@@ -4,7 +4,7 @@
4
4
  4:I[37457,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"default"]
5
5
  5:I[37711,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"default"]
6
6
  6:I[47257,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"ClientPageRoot"]
7
- 7:I[68863,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js","/_next/static/chunks/0muwt9bykzr-1.js","/_next/static/chunks/135n87ydxjrra.js"],"default"]
7
+ 7:I[68863,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js","/_next/static/chunks/0muwt9bykzr-1.js","/_next/static/chunks/0mp9b72fm-jp6.js"],"default"]
8
8
  a:I[97367,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"OutletBoundary"]
9
9
  b:"$Sreact.suspense"
10
10
  e:I[97367,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"ViewportBoundary"]
@@ -14,11 +14,11 @@ e:I[97367,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2j
14
14
  :HL["/_next/static/media/797e433ab948586e-s.p.0r6juujl39pe6.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
15
15
  :HL["/_next/static/media/caa3a2e1cccd8315-s.p.0wgildi0cnwt9.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
16
16
  d:X
17
- 0:{"P":null,"c":["","setup"],"q":"","i":false,"f":[[["",{"children":["setup",{"children":["__PAGE__",{},"$undefined","$undefined",4608]},"$undefined","$undefined",4608]},"$undefined","$undefined",4624],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2p6o90z0vgcwr.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","script","script-0",{"src":"/_next/static/chunks/2jz311xl1pp_8.js","async":true,"nonce":"$undefined"}],["$","script","script-1",{"src":"/_next/static/chunks/0cuuo2jwc9h94.js","async":true,"nonce":"$undefined"}]],["$","html",null,{"lang":"en","className":"geist_2ae47f08-module__h69qWW__variable geist_mono_eb58308d-module__w_p2Lq__variable","children":["$","body",null,{"style":{"margin":0,"padding":0,"background":"#0a0a1a"},"children":["$","$L2",null,{"children":[["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}],["$","$L5",null,{}]]}]}]}]]}],{"children":[["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":[["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@8","$@9"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/0muwt9bykzr-1.js","async":true,"nonce":"$undefined"}],["$","script","script-1",{"src":"/_next/static/chunks/135n87ydxjrra.js","async":true,"nonce":"$undefined"}]],["$","$La",null,{"children":["$","$b",null,{"name":"Next.MetadataOutlet","children":"$@c"}]}]]}],{},null,false,null]},null,false,"$d"]},null,false,null],["$","$1","h",{"children":[null,["$","$Le",null,{"children":"$Lf"}],["$","div",null,{"hidden":true,"children":["$","$L10",null,{"children":["$","$b",null,{"name":"Next.Metadata","children":"$L11"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$12",[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2p6o90z0vgcwr.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]]],"S":true,"h":null,"r":"$undefined","s":"$undefined","a":"$undefined","l":"$undefined","p":"$undefined","d":"$undefined","b":"WseE_5HuU-1q0ywC9CP3U"}
17
+ 0:{"P":null,"c":["","setup"],"q":"","i":false,"f":[[["",{"children":["setup",{"children":["__PAGE__",{},"$undefined","$undefined",4608]},"$undefined","$undefined",4608]},"$undefined","$undefined",4624],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2p6o90z0vgcwr.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","script","script-0",{"src":"/_next/static/chunks/2jz311xl1pp_8.js","async":true,"nonce":"$undefined"}],["$","script","script-1",{"src":"/_next/static/chunks/0cuuo2jwc9h94.js","async":true,"nonce":"$undefined"}]],["$","html",null,{"lang":"en","className":"geist_2ae47f08-module__h69qWW__variable geist_mono_eb58308d-module__w_p2Lq__variable","children":["$","body",null,{"style":{"margin":0,"padding":0,"background":"#0a0a1a"},"children":["$","$L2",null,{"children":[["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}],["$","$L5",null,{}]]}]}]}]]}],{"children":[["$","$1","c",{"children":[null,["$","$L3",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L4",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","forbidden":"$undefined","unauthorized":"$undefined"}]]}],{"children":[["$","$1","c",{"children":[["$","$L6",null,{"Component":"$7","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@8","$@9"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/0muwt9bykzr-1.js","async":true,"nonce":"$undefined"}],["$","script","script-1",{"src":"/_next/static/chunks/0mp9b72fm-jp6.js","async":true,"nonce":"$undefined"}]],["$","$La",null,{"children":["$","$b",null,{"name":"Next.MetadataOutlet","children":"$@c"}]}]]}],{},null,false,null]},null,false,"$d"]},null,false,null],["$","$1","h",{"children":[null,["$","$Le",null,{"children":"$Lf"}],["$","div",null,{"hidden":true,"children":["$","$L10",null,{"children":["$","$b",null,{"name":"Next.Metadata","children":"$L11"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$12",[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2p6o90z0vgcwr.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]]],"S":true,"h":null,"r":"$undefined","s":"$undefined","a":"$undefined","l":"$undefined","p":"$undefined","d":"$undefined","b":"wGVrXBkFLmEB4snfhtOcO"}
18
18
  d:C
19
19
  8:{}
20
20
  9:"$0:f:0:1:1:children:1:children:0:props:children:0:props:serverProvidedParams:params"
21
21
  f:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]
22
22
  13:I[27201,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"IconMark"]
23
23
  c:null
24
- 11:[["$","title","0",{"children":"Six Degrees"}],["$","meta","1",{"name":"description","content":"Maps your LinkedIn network: who you know, who they know, and the shortest path to someone you haven't met. Runs on your own computer; nothing is uploaded."}],["$","link","2",{"rel":"icon","href":"/favicon.ico?favicon.2vob68tjqpejf.ico","sizes":"256x256","type":"image/x-icon"}],["$","$L13","3",{}]]
24
+ 11:[["$","title","0",{"children":"Six Degrees"}],["$","meta","1",{"name":"description","content":"Maps your LinkedIn network: who you know, who they know, and the shortest path to someone you haven't met. Runs on your own computer; nothing is uploaded."}],["$","link","2",{"rel":"icon","href":"/favicon.ico?favicon.0zdzw5kurn8m-.ico","sizes":"48x48","type":"image/x-icon"}],["$","$L13","3",{}]]
@@ -1,4 +1,4 @@
1
1
  :HL["/_next/static/chunks/2p6o90z0vgcwr.css","style"]
2
2
  :HL["/_next/static/media/797e433ab948586e-s.p.0r6juujl39pe6.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
3
3
  :HL["/_next/static/media/caa3a2e1cccd8315-s.p.0wgildi0cnwt9.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
4
- 0:{"tree":{"name":"","param":null,"prefetchHints":4176,"slots":{"children":{"name":"setup","param":null,"prefetchHints":4192,"slots":{"children":{"name":"__PAGE__","param":null,"prefetchHints":4256,"slots":null}}}}},"staleTime":300,"buildId":"WseE_5HuU-1q0ywC9CP3U"}
4
+ 0:{"tree":{"name":"","param":null,"prefetchHints":4176,"slots":{"children":{"name":"setup","param":null,"prefetchHints":4192,"slots":{"children":{"name":"__PAGE__","param":null,"prefetchHints":4256,"slots":null}}}}},"staleTime":300,"buildId":"wGVrXBkFLmEB4snfhtOcO"}
@@ -1,6 +1,6 @@
1
1
  1:"$Sreact.fragment"
2
2
  2:I[47257,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"ClientPageRoot"]
3
- 3:I[68863,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js","/_next/static/chunks/0muwt9bykzr-1.js","/_next/static/chunks/135n87ydxjrra.js"],"default"]
3
+ 3:I[68863,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js","/_next/static/chunks/0muwt9bykzr-1.js","/_next/static/chunks/0mp9b72fm-jp6.js"],"default"]
4
4
  6:I[97367,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"OutletBoundary"]
5
5
  7:"$Sreact.suspense"
6
6
  b:I[97367,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2jwc9h94.js"],"ViewportBoundary"]
@@ -14,7 +14,7 @@ f:I[39756,["/_next/static/chunks/2jz311xl1pp_8.js","/_next/static/chunks/0cuuo2j
14
14
  a:X
15
15
  12:X
16
16
  12:C
17
- 0:{"buildId":"WseE_5HuU-1q0ywC9CP3U","data":[{"rsc":["$","$1","c",{"children":[["$","$L2",null,{"Component":"$3","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@4","$@5"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/0muwt9bykzr-1.js","async":true}],["$","script","script-1",{"src":"/_next/static/chunks/135n87ydxjrra.js","async":true}]],["$","$L6",null,{"children":["$","$7",null,{"name":"Next.MetadataOutlet","children":"$@8"}]}]]}],"isPartial":"$@9","staleTime":"$a","varyParams":null},{"rsc":["$","$1","h",{"children":[null,["$","$Lb",null,{"children":[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]}],["$","div",null,{"hidden":true,"children":["$","$Lc",null,{"children":["$","$7",null,{"name":"Next.Metadata","children":[["$","title","0",{"children":"Six Degrees"}],["$","meta","1",{"name":"description","content":"Maps your LinkedIn network: who you know, who they know, and the shortest path to someone you haven't met. Runs on your own computer; nothing is uploaded."}],["$","link","2",{"rel":"icon","href":"/favicon.ico?favicon.2vob68tjqpejf.ico","sizes":"256x256","type":"image/x-icon"}],["$","$Ld","3",{}]]}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],"isPartial":"$@e","staleTime":"$a","varyParams":null},{"rsc":["$","$1","c",{"children":[null,["$","$Lf",null,{"parallelRouterKey":"children","template":["$","$L10",null,{}]}]]}],"isPartial":"$@11","staleTime":"$a","varyParams":"$12"},{"rsc":["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2p6o90z0vgcwr.css","precedence":"next"}],["$","script","script-0",{"src":"/_next/static/chunks/2jz311xl1pp_8.js","async":true}],["$","script","script-1",{"src":"/_next/static/chunks/0cuuo2jwc9h94.js","async":true}]],["$","html",null,{"lang":"en","className":"geist_2ae47f08-module__h69qWW__variable geist_mono_eb58308d-module__w_p2Lq__variable","children":["$","body",null,{"style":{"margin":0,"padding":0,"background":"#0a0a1a"},"children":["$","$L13",null,{"children":[["$","$Lf",null,{"parallelRouterKey":"children","template":["$","$L10",null,{}],"notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]]}],["$","$L14",null,{}]]}]}]}]]}],"isPartial":"$@15","staleTime":"$a","varyParams":null}],"isUpgradeableISRFallback":false,"a":"$@16","rootVaryParams":null,"needsRuntimeRequest":"$@17"}
17
+ 0:{"buildId":"wGVrXBkFLmEB4snfhtOcO","data":[{"rsc":["$","$1","c",{"children":[["$","$L2",null,{"Component":"$3","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@4","$@5"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/0muwt9bykzr-1.js","async":true}],["$","script","script-1",{"src":"/_next/static/chunks/0mp9b72fm-jp6.js","async":true}]],["$","$L6",null,{"children":["$","$7",null,{"name":"Next.MetadataOutlet","children":"$@8"}]}]]}],"isPartial":"$@9","staleTime":"$a","varyParams":null},{"rsc":["$","$1","h",{"children":[null,["$","$Lb",null,{"children":[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]}],["$","div",null,{"hidden":true,"children":["$","$Lc",null,{"children":["$","$7",null,{"name":"Next.Metadata","children":[["$","title","0",{"children":"Six Degrees"}],["$","meta","1",{"name":"description","content":"Maps your LinkedIn network: who you know, who they know, and the shortest path to someone you haven't met. Runs on your own computer; nothing is uploaded."}],["$","link","2",{"rel":"icon","href":"/favicon.ico?favicon.0zdzw5kurn8m-.ico","sizes":"48x48","type":"image/x-icon"}],["$","$Ld","3",{}]]}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],"isPartial":"$@e","staleTime":"$a","varyParams":null},{"rsc":["$","$1","c",{"children":[null,["$","$Lf",null,{"parallelRouterKey":"children","template":["$","$L10",null,{}]}]]}],"isPartial":"$@11","staleTime":"$a","varyParams":"$12"},{"rsc":["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2p6o90z0vgcwr.css","precedence":"next"}],["$","script","script-0",{"src":"/_next/static/chunks/2jz311xl1pp_8.js","async":true}],["$","script","script-1",{"src":"/_next/static/chunks/0cuuo2jwc9h94.js","async":true}]],["$","html",null,{"lang":"en","className":"geist_2ae47f08-module__h69qWW__variable geist_mono_eb58308d-module__w_p2Lq__variable","children":["$","body",null,{"style":{"margin":0,"padding":0,"background":"#0a0a1a"},"children":["$","$L13",null,{"children":[["$","$Lf",null,{"parallelRouterKey":"children","template":["$","$L10",null,{}],"notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]]}],["$","$L14",null,{}]]}]}]}]]}],"isPartial":"$@15","staleTime":"$a","varyParams":null}],"isUpgradeableISRFallback":false,"a":"$@16","rootVaryParams":null,"needsRuntimeRequest":"$@17"}
18
18
  4:{}
19
19
  5:"$0:data:0:rsc:props:children:0:props:serverProvidedParams:params"
20
20
  8:null
@@ -1,3 +1,3 @@
1
- module.exports=[70406,(e,t,r)=>{t.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,t,r)=>{t.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,t,r)=>{t.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(e,t,r)=>{t.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},74533,(e,t,r)=>{t.exports=e.x("node:child_process",()=>require("node:child_process"))},66680,(e,t,r)=>{t.exports=e.x("node:crypto",()=>require("node:crypto"))},2157,(e,t,r)=>{t.exports=e.x("node:fs",()=>require("node:fs"))},12714,(e,t,r)=>{t.exports=e.x("node:fs/promises",()=>require("node:fs/promises"))},60526,(e,t,r)=>{t.exports=e.x("node:os",()=>require("node:os"))},50227,(e,t,r)=>{t.exports=e.x("node:path",()=>require("node:path"))},81111,(e,t,r)=>{t.exports=e.x("node:stream",()=>require("node:stream"))},49222,e=>{"use strict";var t=e.i(80998);async function r(e){try{let{profileUrl:r}=await e.json();if(!r)return Response.json({error:"Missing profileUrl"},{status:400});let{error:s}=await t.db.from("linkedin_connections").delete().eq("profile_url",r);if(s)return Response.json({error:s.message},{status:500});return Response.json({success:!0})}catch(e){return Response.json({error:e.message},{status:500})}}e.s(["POST",0,r])},98114,e=>{"use strict";var t=e.i(47909),r=e.i(74017),s=e.i(96250),n=e.i(59756),a=e.i(61916),i=e.i(74677),l=e.i(69741),o=e.i(16795),u=e.i(87718),p=e.i(95169),d=e.i(47587),c=e.i(66012),h=e.i(70101),m=e.i(26937),g=e.i(10372),f=e.i(93695);e.i(52474);var _=e.i(220);let R=new t.AppRouteRouteModule({definition:{kind:r.RouteKind.APP_ROUTE,page:"/api/admin-delete/route",pathname:"/api/admin-delete",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/app/api/admin-delete/route.js",nextConfigOutput:"standalone",userland:()=>e.r(49222),...{}}),{workAsyncStorage:x,workUnitAsyncStorage:E,serverHooks:b}=R;async function v(e,t,s){s.requestMeta&&(0,n.setRequestMeta)(e,s.requestMeta),R.isDev&&(0,n.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let x="/api/admin-delete/route";x=x.replace(/\/index$/,"")||"/";let E=await R.prepare(e,t,{srcPage:x,multiZoneDraftMode:!1});if(!E)return t.statusCode=400,t.end("Bad Request"),null==s.waitUntil||s.waitUntil.call(s,Promise.resolve()),null;let{buildId:b,deploymentId:v,params:w,nextConfig:y,parsedUrl:T,isDraftMode:S,prerenderManifest:C,routerServerContext:$,isOnDemandRevalidate:q,revalidateOnlyGenerated:N,resolvedPathname:A,clientReferenceManifest:O,serverActionsManifest:I}=E,L=(0,l.normalizeAppPath)(x),j=!!(C.dynamicRoutes[L]||C.routes[A]),P=async()=>((null==$?void 0:$.render404)?await $.render404(e,t,T,!1):t.end("This page could not be found"),null);if(j&&!S){let e=!!C.routes[A],t=C.dynamicRoutes[L];if(t&&!1===t.fallback&&!e){if(y.adapterPath)return await P();throw new f.NoFallbackError}}let D=null;!j||R.isDev||S||(D="/index"===(D=A)?"/":D);let k=!0===R.isDev||!j,U=j&&!k;I&&O&&(0,i.setManifestsSingleton)({page:x,clientReferenceManifest:O,serverActionsManifest:I});let M=e.method||"GET",H=(0,a.getTracer)(),F=H.getActiveScopeSpan(),V=!!(null==$?void 0:$.isWrappedByNextServer),K=!!(0,n.getRequestMeta)(e,"minimalMode"),G=(0,n.getRequestMeta)(e,"incrementalCache")||await R.getIncrementalCache(e,y,C,K);null==G||G.resetRequestCache(),globalThis.__incrementalCache=G;let B={params:w,previewProps:C.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:k,incrementalCache:G,hmrRefreshHash:(0,n.getRequestMeta)(e,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:s.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,r,s,n)=>R.onRequestError(e,t,s,n,$)},sharedContext:{buildId:b,deploymentId:v}},W=new o.NodeNextRequest(e),X=new o.NodeNextResponse(t),z=u.NextRequestAdapter.fromNodeNextRequest(W,(0,u.signalFromNodeResponse)(t)),J=async({previousCacheEntry:r})=>{try{if(!K&&q&&N&&!r)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let n=await R.handle(z,B);e.fetchMetrics=B.renderOpts.fetchMetrics;let a=B.renderOpts.pendingWaitUntil;a&&s.waitUntil&&(s.waitUntil(a),a=void 0);let i=B.renderOpts.collectedTags;if(!j)return await (0,c.sendResponse)(W,X,n,a),null;{let e=await n.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(n.headers);i&&(t[g.NEXT_CACHE_TAGS_HEADER]=i),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let r=void 0!==B.renderOpts.collectedRevalidate&&!(B.renderOpts.collectedRevalidate>=g.INFINITE_CACHE)&&B.renderOpts.collectedRevalidate,s=void 0===B.renderOpts.collectedExpire||B.renderOpts.collectedExpire>=g.INFINITE_CACHE?!1!==r&&r>0?y.expireTime:void 0:B.renderOpts.collectedExpire;return{value:{kind:_.CachedRouteKind.APP_ROUTE,status:n.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:r,expire:s}}}}catch(t){throw(null==r?void 0:r.isStale)&&await R.onRequestError(e,t,{routerKind:"App Router",routePath:x,routeType:"route",revalidateReason:(0,d.getRevalidateReason)({isStaticGeneration:U,isOnDemandRevalidate:q})},!1,$),t}},Q=async(n,i)=>{try{var l,o;let n=await R.handleResponse({req:e,nextConfig:y,cacheKey:D,routeKind:r.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:C,isRoutePPREnabled:!1,isOnDemandRevalidate:q,revalidateOnlyGenerated:N,responseGenerator:J,waitUntil:s.waitUntil,isMinimalMode:K});if(!j)return;if((null==n||null==(l=n.value)?void 0:l.kind)!==_.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==n||null==(o=n.value)?void 0:o.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});K||t.setHeader("x-nextjs-cache",q?"REVALIDATED":n.isMiss?"MISS":n.isStale?"STALE":"HIT"),S&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let a=(0,h.fromNodeOutgoingHttpHeaders)(n.value.headers);K&&j||a.delete(g.NEXT_CACHE_TAGS_HEADER),!n.cacheControl||t.getHeader("Cache-Control")||a.get("Cache-Control")||a.set("Cache-Control",(0,m.getCacheControlHeader)(n.cacheControl)),await (0,c.sendResponse)(W,X,new Response(n.value.body,{headers:a,status:n.value.status||200}));return}catch(t){if(t instanceof f.NoFallbackError||await R.onRequestError(e,t,{routerKind:"App Router",routePath:L,routeType:"route",revalidateReason:(0,d.getRevalidateReason)({isStaticGeneration:U,isOnDemandRevalidate:q})},!1,$),j)throw t;await (0,c.sendResponse)(W,X,new Response(null,{status:500}));return}finally{(()=>{if(!n)return;let e=t.statusCode;n.setAttributes({"http.status_code":e,"next.rsc":!1}),e&&e>=500&&(n.setStatus({code:a.SpanStatusCode.ERROR}),n.setAttribute("error.type",e.toString()));let r=H.getRootSpanAttributes();if(!r)return;if(r.get("next.span_type")!==p.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${r.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let s=r.get("next.route")||L,l=`${M} ${s}`;n.setAttributes({"next.route":s,"http.route":s,"next.span_name":l}),n.updateName(l),i&&i!==n&&(i.setAttribute("http.route",s),i.updateName(l))})()}};if(V&&F)await Q(F,void 0);else{let t=H.getActiveScopeSpan();await H.withPropagatedContext(e.headers,()=>H.trace(p.BaseServerSpan.handleRequest,{spanName:`${M} ${x}`,kind:a.SpanKind.SERVER,attributes:{"http.method":M,"http.target":e.url}},e=>Q(e,t)),void 0,!V)}}e.s(["handler",0,v,"patchFetch",0,function(){return(0,s.patchFetch)({workAsyncStorage:x,workUnitAsyncStorage:E})},"routeModule",0,R,"serverHooks",0,b,"workAsyncStorage",0,x,"workUnitAsyncStorage",0,E])},80998,e=>{"use strict";var t=e.i(88431);let r=/^[a-z_][a-z0-9_]*$/i;function s(e,t){if(!r.test(e))throw Error(`Unsafe ${t}: ${e}`);return e}class n{constructor(e){this.table=s(e,"table"),this._columns="*",this._filters=[],this._order=null,this._limit=null,this._single=!1,this._op="select",this._payload=null,this._onConflict=null,this._ignoreDuplicates=!1}select(e="*"){return"select"===this._op&&(this._columns="*"===e?"*":e),this._returning=!0,this}eq(e,r){return s(e,"column"),null===r?this._filters.push({sql:`"${e}" IS NULL`,params:[]}):this._filters.push({sql:`"${e}" = ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}neq(e,r){return s(e,"column"),this._filters.push({sql:`"${e}" IS NOT ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}in(e,r){s(e,"column");let n=Array.isArray(r)?r:[];return n.length?this._filters.push({sql:`"${e}" IN (${n.map(()=>"?").join(", ")})`,params:n.map(r=>(0,t.encodeValue)(this.table,e,r))}):this._filters.push({sql:"0 = 1",params:[]}),this}ilike(e,t){return s(e,"column"),this._filters.push({sql:`"${e}" LIKE ?`,params:[t]}),this}not(e,r,n){return s(e,"column"),"is"===r&&null===n?this._filters.push({sql:`"${e}" IS NOT NULL`,params:[]}):this._filters.push({sql:`NOT ("${e}" = ?)`,params:[(0,t.encodeValue)(this.table,e,n)]}),this}is(e,r){return s(e,"column"),null===r?this._filters.push({sql:`"${e}" IS NULL`,params:[]}):this._filters.push({sql:`"${e}" = ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}order(e,{ascending:t=!0}={}){return s(e,"column"),this._order=`"${e}" ${t?"ASC":"DESC NULLS LAST"}`,this}limit(e){return this._limit=Number(e)||0,this}single(){return this._single=!0,this._limit=this._limit??1,this}maybeSingle(){return this.single()}insert(e){return this._op="insert",this._payload=Array.isArray(e)?e:[e],this}upsert(e,t={}){return this._op="upsert",this._payload=Array.isArray(e)?e:[e],this._onConflict=t.onConflict||null,this._ignoreDuplicates=!!t.ignoreDuplicates,this}update(e){return this._op="update",this._payload=e,this}delete(){return this._op="delete",this}_where(){return this._filters.length?{sql:" WHERE "+this._filters.map(e=>e.sql).join(" AND "),params:this._filters.flatMap(e=>e.params)}:{sql:"",params:[]}}_run(){let e=(0,t.getDb)(),s=this._where();if("select"===this._op){let r=`SELECT ${"*"===this._columns?"*":this._columns} FROM "${this.table}"${s.sql}`;this._order&&(r+=` ORDER BY ${this._order}`),null!=this._limit&&(r+=` LIMIT ${Number(this._limit)}`);let n=e.prepare(r).all(...s.params).map(e=>(0,t.decodeRow)(this.table,e));return this._single?n.length?{data:n[0],error:null}:{data:null,error:{message:"No rows found",code:"PGRST116"}}:{data:n,error:null}}if("insert"===this._op||"upsert"===this._op){let s=[];for(let n of this._payload){let a={id:n.id||(0,t.newId)(),...n};a.id||(a.id=(0,t.newId)());let i=Object.keys(a).filter(e=>r.test(e)),l=i.map(e=>(0,t.encodeValue)(this.table,e,a[e])),o=i.map(()=>"?").join(", "),u=i.map(e=>`"${e}"`).join(", "),p=`INSERT INTO "${this.table}" (${u}) VALUES (${o})`;if("upsert"===this._op)if(this._ignoreDuplicates)p+=" ON CONFLICT DO NOTHING";else{let e=this._onConflict?this._onConflict.split(",").map(e=>`"${e.trim()}"`).join(", "):'"id"',t=i.filter(e=>"id"!==e).map(e=>`"${e}" = excluded."${e}"`).join(", ");p+=` ON CONFLICT (${e}) DO UPDATE SET ${t||'"id" = "id"'}`}try{e.prepare(p).run(...l);let r=e.prepare(`SELECT * FROM "${this.table}" WHERE id = ?`).get(a.id);r&&s.push((0,t.decodeRow)(this.table,r))}catch(e){if("upsert"===this._op&&/UNIQUE constraint/i.test(e.message))continue;return{data:null,error:{message:e.message}}}}return this._single?{data:s[0]??null,error:s.length?null:{message:"Insert returned no row"}}:{data:s,error:null}}if("update"===this._op){let n={...this._payload};"updated_at"in n==!1&&"linkedin_connections"===this.table&&(n.updated_at=(0,t.nowIso)());let a=Object.keys(n).filter(e=>r.test(e));if(!a.length)return{data:[],error:null};let i=a.map(e=>`"${e}" = ?`).join(", "),l=a.map(e=>(0,t.encodeValue)(this.table,e,n[e])),o=`UPDATE "${this.table}" SET ${i}${s.sql}`;try{let r=e.prepare(`SELECT id FROM "${this.table}"${s.sql}`).all(...s.params);e.prepare(o).run(...l,...s.params);let n=r.map(t=>e.prepare(`SELECT * FROM "${this.table}" WHERE id = ?`).get(t.id)).filter(Boolean).map(e=>(0,t.decodeRow)(this.table,e));if(this._single)return{data:n[0]??null,error:n.length?null:{message:"No rows updated"}};return{data:n,error:null}}catch(e){return{data:null,error:{message:e.message}}}}if("delete"===this._op)try{let r=e.prepare(`SELECT * FROM "${this.table}"${s.sql}`).all(...s.params).map(e=>(0,t.decodeRow)(this.table,e));return e.prepare(`DELETE FROM "${this.table}"${s.sql}`).run(...s.params),{data:r,error:null}}catch(e){return{data:null,error:{message:e.message}}}return{data:null,error:{message:`Unsupported operation: ${this._op}`}}}then(e,t){let r;try{r=this._run()}catch(e){r={data:null,error:{message:e.message}}}return Promise.resolve(r).then(e,t)}catch(e){return this.then(void 0,e)}finally(e){return this.then(t=>(e?.(),t),t=>{throw e?.(),t})}}e.s(["db",0,{from:e=>new n(e),async rpc(t,r={}){let{runRpc:s}=await e.A(35862);return s(t,r)}}])},12506,1348,e=>{"use strict";e.s(["compareVersions",0,function(e,t){let r=e=>String(e||"").replace(/^v/i,"").split(/[-+]/)[0].split(".").map(e=>Number.parseInt(e,10)||0),s=r(e),n=r(t);for(let e=0;e<Math.max(s.length,n.length);e++){let t=(s[e]||0)-(n[e]||0);if(0!==t)return t>0?1:-1}return 0},"installKind",0,function(e=process.env,t=""){return["mac-app","source","npm"].includes(e.SIX_DEGREES_INSTALL)?e.SIX_DEGREES_INSTALL:/\.app\/Contents\/Resources/.test(t||"")?"mac-app":"npm"},"repoSlug",0,function(e){let t=("string"==typeof e?e:e?.url||"").match(/github\.com[/:]([^/]+)\/([^/.#?]+)/);return t?`${t[1]}/${t[2]}`:null},"updateCommand",0,function(e,t,{dataDir:r}={}){if("mac-app"===e)return`curl -fsSL https://raw.githubusercontent.com/${t}/main/install.sh | bash`;if("source"===e)return"git pull && npm ci && npm run build && npm run start:packaged";let s=r&&`'${String(r).replace(/'/g,"'\\''")}'`;return s?`npx six-degrees@latest --data-dir ${s}`:"npx six-degrees@latest"}],12506);let t=Symbol.for("six-degrees.scan-state");function r(){let e=globalThis[t];return e?.running!==!0?null:"string"==typeof e.action&&e.action?e.action:"scan"}function s(e){switch(e){case"install":return"The scanner's packages are being installed";case"setup":return"The scanner is being set up";case"login":return"The LinkedIn sign-in window is open";case"photos":return"Profile photos are being saved";default:return"A scan is running"}}e.s(["busyRefusal",0,function(e,t=r()){return t?`${s(t)}. ${e}`:null},"registerScanState",0,function(e){return globalThis[t]||(globalThis[t]=e),globalThis[t]},"runningNow",0,s,"scannerJob",0,r],1348)}];
1
+ module.exports=[70406,(e,t,r)=>{t.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,t,r)=>{t.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,t,r)=>{t.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(e,t,r)=>{t.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},74533,(e,t,r)=>{t.exports=e.x("node:child_process",()=>require("node:child_process"))},66680,(e,t,r)=>{t.exports=e.x("node:crypto",()=>require("node:crypto"))},2157,(e,t,r)=>{t.exports=e.x("node:fs",()=>require("node:fs"))},12714,(e,t,r)=>{t.exports=e.x("node:fs/promises",()=>require("node:fs/promises"))},60526,(e,t,r)=>{t.exports=e.x("node:os",()=>require("node:os"))},50227,(e,t,r)=>{t.exports=e.x("node:path",()=>require("node:path"))},81111,(e,t,r)=>{t.exports=e.x("node:stream",()=>require("node:stream"))},49222,e=>{"use strict";var t=e.i(80998);async function r(e){try{let{profileUrl:r}=await e.json();if(!r)return Response.json({error:"Missing profileUrl"},{status:400});let{error:s}=await t.db.from("linkedin_connections").delete().eq("profile_url",r);if(s)return Response.json({error:s.message},{status:500});return await t.db.from("connection_ties").delete().eq("a_url",r),await t.db.from("connection_ties").delete().eq("b_url",r),Response.json({success:!0})}catch(e){return Response.json({error:e.message},{status:500})}}e.s(["POST",0,r])},98114,e=>{"use strict";var t=e.i(47909),r=e.i(74017),s=e.i(96250),n=e.i(59756),a=e.i(61916),i=e.i(74677),l=e.i(69741),o=e.i(16795),u=e.i(87718),p=e.i(95169),d=e.i(47587),c=e.i(66012),h=e.i(70101),m=e.i(26937),g=e.i(10372),f=e.i(93695);e.i(52474);var _=e.i(220);let R=new t.AppRouteRouteModule({definition:{kind:r.RouteKind.APP_ROUTE,page:"/api/admin-delete/route",pathname:"/api/admin-delete",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/app/api/admin-delete/route.js",nextConfigOutput:"standalone",userland:()=>e.r(49222),...{}}),{workAsyncStorage:x,workUnitAsyncStorage:b,serverHooks:E}=R;async function v(e,t,s){s.requestMeta&&(0,n.setRequestMeta)(e,s.requestMeta),R.isDev&&(0,n.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let x="/api/admin-delete/route";x=x.replace(/\/index$/,"")||"/";let b=await R.prepare(e,t,{srcPage:x,multiZoneDraftMode:!1});if(!b)return t.statusCode=400,t.end("Bad Request"),null==s.waitUntil||s.waitUntil.call(s,Promise.resolve()),null;let{buildId:E,deploymentId:v,params:w,nextConfig:y,parsedUrl:T,isDraftMode:S,prerenderManifest:C,routerServerContext:$,isOnDemandRevalidate:q,revalidateOnlyGenerated:N,resolvedPathname:A,clientReferenceManifest:O,serverActionsManifest:I}=b,L=(0,l.normalizeAppPath)(x),j=!!(C.dynamicRoutes[L]||C.routes[A]),P=async()=>((null==$?void 0:$.render404)?await $.render404(e,t,T,!1):t.end("This page could not be found"),null);if(j&&!S){let e=!!C.routes[A],t=C.dynamicRoutes[L];if(t&&!1===t.fallback&&!e){if(y.adapterPath)return await P();throw new f.NoFallbackError}}let D=null;!j||R.isDev||S||(D="/index"===(D=A)?"/":D);let k=!0===R.isDev||!j,U=j&&!k;I&&O&&(0,i.setManifestsSingleton)({page:x,clientReferenceManifest:O,serverActionsManifest:I});let M=e.method||"GET",H=(0,a.getTracer)(),F=H.getActiveScopeSpan(),V=!!(null==$?void 0:$.isWrappedByNextServer),K=!!(0,n.getRequestMeta)(e,"minimalMode"),G=(0,n.getRequestMeta)(e,"incrementalCache")||await R.getIncrementalCache(e,y,C,K);null==G||G.resetRequestCache(),globalThis.__incrementalCache=G;let B={params:w,previewProps:C.preview,renderOpts:{experimental:{authInterrupts:!!y.experimental.authInterrupts,useCacheTimeout:y.experimental.useCacheTimeout},cacheComponents:!!y.cacheComponents,validationLevel:y.experimental.instantInsights.validationLevel,supportsDynamicResponse:k,incrementalCache:G,hmrRefreshHash:(0,n.getRequestMeta)(e,"hmrRefreshHash"),cacheLifeProfiles:y.cacheLife,staticPageGenerationTimeout:y.staticPageGenerationTimeout,waitUntil:s.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,r,s,n)=>R.onRequestError(e,t,s,n,$)},sharedContext:{buildId:E,deploymentId:v}},W=new o.NodeNextRequest(e),X=new o.NodeNextResponse(t),z=u.NextRequestAdapter.fromNodeNextRequest(W,(0,u.signalFromNodeResponse)(t)),J=async({previousCacheEntry:r})=>{try{if(!K&&q&&N&&!r)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let n=await R.handle(z,B);e.fetchMetrics=B.renderOpts.fetchMetrics;let a=B.renderOpts.pendingWaitUntil;a&&s.waitUntil&&(s.waitUntil(a),a=void 0);let i=B.renderOpts.collectedTags;if(!j)return await (0,c.sendResponse)(W,X,n,a),null;{let e=await n.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(n.headers);i&&(t[g.NEXT_CACHE_TAGS_HEADER]=i),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let r=void 0!==B.renderOpts.collectedRevalidate&&!(B.renderOpts.collectedRevalidate>=g.INFINITE_CACHE)&&B.renderOpts.collectedRevalidate,s=void 0===B.renderOpts.collectedExpire||B.renderOpts.collectedExpire>=g.INFINITE_CACHE?!1!==r&&r>0?y.expireTime:void 0:B.renderOpts.collectedExpire;return{value:{kind:_.CachedRouteKind.APP_ROUTE,status:n.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:r,expire:s}}}}catch(t){throw(null==r?void 0:r.isStale)&&await R.onRequestError(e,t,{routerKind:"App Router",routePath:x,routeType:"route",revalidateReason:(0,d.getRevalidateReason)({isStaticGeneration:U,isOnDemandRevalidate:q})},!1,$),t}},Q=async(n,i)=>{try{var l,o;let n=await R.handleResponse({req:e,nextConfig:y,cacheKey:D,routeKind:r.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:C,isRoutePPREnabled:!1,isOnDemandRevalidate:q,revalidateOnlyGenerated:N,responseGenerator:J,waitUntil:s.waitUntil,isMinimalMode:K});if(!j)return;if((null==n||null==(l=n.value)?void 0:l.kind)!==_.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==n||null==(o=n.value)?void 0:o.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});K||t.setHeader("x-nextjs-cache",q?"REVALIDATED":n.isMiss?"MISS":n.isStale?"STALE":"HIT"),S&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let a=(0,h.fromNodeOutgoingHttpHeaders)(n.value.headers);K&&j||a.delete(g.NEXT_CACHE_TAGS_HEADER),!n.cacheControl||t.getHeader("Cache-Control")||a.get("Cache-Control")||a.set("Cache-Control",(0,m.getCacheControlHeader)(n.cacheControl)),await (0,c.sendResponse)(W,X,new Response(n.value.body,{headers:a,status:n.value.status||200}));return}catch(t){if(t instanceof f.NoFallbackError||await R.onRequestError(e,t,{routerKind:"App Router",routePath:L,routeType:"route",revalidateReason:(0,d.getRevalidateReason)({isStaticGeneration:U,isOnDemandRevalidate:q})},!1,$),j)throw t;await (0,c.sendResponse)(W,X,new Response(null,{status:500}));return}finally{(()=>{if(!n)return;let e=t.statusCode;n.setAttributes({"http.status_code":e,"next.rsc":!1}),e&&e>=500&&(n.setStatus({code:a.SpanStatusCode.ERROR}),n.setAttribute("error.type",e.toString()));let r=H.getRootSpanAttributes();if(!r)return;if(r.get("next.span_type")!==p.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${r.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let s=r.get("next.route")||L,l=`${M} ${s}`;n.setAttributes({"next.route":s,"http.route":s,"next.span_name":l}),n.updateName(l),i&&i!==n&&(i.setAttribute("http.route",s),i.updateName(l))})()}};if(V&&F)await Q(F,void 0);else{let t=H.getActiveScopeSpan();await H.withPropagatedContext(e.headers,()=>H.trace(p.BaseServerSpan.handleRequest,{spanName:`${M} ${x}`,kind:a.SpanKind.SERVER,attributes:{"http.method":M,"http.target":e.url}},e=>Q(e,t)),void 0,!V)}}e.s(["handler",0,v,"patchFetch",0,function(){return(0,s.patchFetch)({workAsyncStorage:x,workUnitAsyncStorage:b})},"routeModule",0,R,"serverHooks",0,E,"workAsyncStorage",0,x,"workUnitAsyncStorage",0,b])},80998,e=>{"use strict";var t=e.i(88431);let r=/^[a-z_][a-z0-9_]*$/i;function s(e,t){if(!r.test(e))throw Error(`Unsafe ${t}: ${e}`);return e}class n{constructor(e){this.table=s(e,"table"),this._columns="*",this._filters=[],this._order=null,this._limit=null,this._single=!1,this._op="select",this._payload=null,this._onConflict=null,this._ignoreDuplicates=!1}select(e="*"){return"select"===this._op&&(this._columns="*"===e?"*":e),this._returning=!0,this}eq(e,r){return s(e,"column"),null===r?this._filters.push({sql:`"${e}" IS NULL`,params:[]}):this._filters.push({sql:`"${e}" = ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}neq(e,r){return s(e,"column"),this._filters.push({sql:`"${e}" IS NOT ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}in(e,r){s(e,"column");let n=Array.isArray(r)?r:[];return n.length?this._filters.push({sql:`"${e}" IN (${n.map(()=>"?").join(", ")})`,params:n.map(r=>(0,t.encodeValue)(this.table,e,r))}):this._filters.push({sql:"0 = 1",params:[]}),this}ilike(e,t){return s(e,"column"),this._filters.push({sql:`"${e}" LIKE ?`,params:[t]}),this}not(e,r,n){return s(e,"column"),"is"===r&&null===n?this._filters.push({sql:`"${e}" IS NOT NULL`,params:[]}):this._filters.push({sql:`NOT ("${e}" = ?)`,params:[(0,t.encodeValue)(this.table,e,n)]}),this}is(e,r){return s(e,"column"),null===r?this._filters.push({sql:`"${e}" IS NULL`,params:[]}):this._filters.push({sql:`"${e}" = ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}order(e,{ascending:t=!0}={}){return s(e,"column"),this._order=`"${e}" ${t?"ASC":"DESC NULLS LAST"}`,this}limit(e){return this._limit=Number(e)||0,this}single(){return this._single=!0,this._limit=this._limit??1,this}maybeSingle(){return this.single()}insert(e){return this._op="insert",this._payload=Array.isArray(e)?e:[e],this}upsert(e,t={}){return this._op="upsert",this._payload=Array.isArray(e)?e:[e],this._onConflict=t.onConflict||null,this._ignoreDuplicates=!!t.ignoreDuplicates,this}update(e){return this._op="update",this._payload=e,this}delete(){return this._op="delete",this}_where(){return this._filters.length?{sql:" WHERE "+this._filters.map(e=>e.sql).join(" AND "),params:this._filters.flatMap(e=>e.params)}:{sql:"",params:[]}}_run(){let e=(0,t.getDb)(),s=this._where();if("select"===this._op){let r=`SELECT ${"*"===this._columns?"*":this._columns} FROM "${this.table}"${s.sql}`;this._order&&(r+=` ORDER BY ${this._order}`),null!=this._limit&&(r+=` LIMIT ${Number(this._limit)}`);let n=e.prepare(r).all(...s.params).map(e=>(0,t.decodeRow)(this.table,e));return this._single?n.length?{data:n[0],error:null}:{data:null,error:{message:"No rows found",code:"PGRST116"}}:{data:n,error:null}}if("insert"===this._op||"upsert"===this._op){let s=[];for(let n of this._payload){let a={id:n.id||(0,t.newId)(),...n};a.id||(a.id=(0,t.newId)());let i=Object.keys(a).filter(e=>r.test(e)),l=i.map(e=>(0,t.encodeValue)(this.table,e,a[e])),o=i.map(()=>"?").join(", "),u=i.map(e=>`"${e}"`).join(", "),p=`INSERT INTO "${this.table}" (${u}) VALUES (${o})`;if("upsert"===this._op)if(this._ignoreDuplicates)p+=" ON CONFLICT DO NOTHING";else{let e=this._onConflict?this._onConflict.split(",").map(e=>`"${e.trim()}"`).join(", "):'"id"',t=i.filter(e=>"id"!==e).map(e=>`"${e}" = excluded."${e}"`).join(", ");p+=` ON CONFLICT (${e}) DO UPDATE SET ${t||'"id" = "id"'}`}try{e.prepare(p).run(...l);let r=e.prepare(`SELECT * FROM "${this.table}" WHERE id = ?`).get(a.id);r&&s.push((0,t.decodeRow)(this.table,r))}catch(e){if("upsert"===this._op&&/UNIQUE constraint/i.test(e.message))continue;return{data:null,error:{message:e.message}}}}return this._single?{data:s[0]??null,error:s.length?null:{message:"Insert returned no row"}}:{data:s,error:null}}if("update"===this._op){let n={...this._payload};"updated_at"in n==!1&&"linkedin_connections"===this.table&&(n.updated_at=(0,t.nowIso)());let a=Object.keys(n).filter(e=>r.test(e));if(!a.length)return{data:[],error:null};let i=a.map(e=>`"${e}" = ?`).join(", "),l=a.map(e=>(0,t.encodeValue)(this.table,e,n[e])),o=`UPDATE "${this.table}" SET ${i}${s.sql}`;try{let r=e.prepare(`SELECT id FROM "${this.table}"${s.sql}`).all(...s.params);e.prepare(o).run(...l,...s.params);let n=r.map(t=>e.prepare(`SELECT * FROM "${this.table}" WHERE id = ?`).get(t.id)).filter(Boolean).map(e=>(0,t.decodeRow)(this.table,e));if(this._single)return{data:n[0]??null,error:n.length?null:{message:"No rows updated"}};return{data:n,error:null}}catch(e){return{data:null,error:{message:e.message}}}}if("delete"===this._op)try{let r=e.prepare(`SELECT * FROM "${this.table}"${s.sql}`).all(...s.params).map(e=>(0,t.decodeRow)(this.table,e));return e.prepare(`DELETE FROM "${this.table}"${s.sql}`).run(...s.params),{data:r,error:null}}catch(e){return{data:null,error:{message:e.message}}}return{data:null,error:{message:`Unsupported operation: ${this._op}`}}}then(e,t){let r;try{r=this._run()}catch(e){r={data:null,error:{message:e.message}}}return Promise.resolve(r).then(e,t)}catch(e){return this.then(void 0,e)}finally(e){return this.then(t=>(e?.(),t),t=>{throw e?.(),t})}}e.s(["db",0,{from:e=>new n(e),async rpc(t,r={}){let{runRpc:s}=await e.A(35862);return s(t,r)}}])},12506,1348,e=>{"use strict";e.s(["compareVersions",0,function(e,t){let r=e=>String(e||"").replace(/^v/i,"").split(/[-+]/)[0].split(".").map(e=>Number.parseInt(e,10)||0),s=r(e),n=r(t);for(let e=0;e<Math.max(s.length,n.length);e++){let t=(s[e]||0)-(n[e]||0);if(0!==t)return t>0?1:-1}return 0},"installKind",0,function(e=process.env,t=""){return["mac-app","source","npm"].includes(e.SIX_DEGREES_INSTALL)?e.SIX_DEGREES_INSTALL:/\.app\/Contents\/Resources/.test(t||"")?"mac-app":"npm"},"repoSlug",0,function(e){let t=("string"==typeof e?e:e?.url||"").match(/github\.com[/:]([^/]+)\/([^/.#?]+)/);return t?`${t[1]}/${t[2]}`:null},"updateCommand",0,function(e,t,{dataDir:r}={}){if("mac-app"===e)return`curl -fsSL https://raw.githubusercontent.com/${t}/main/install.sh | bash`;if("source"===e)return"git pull && npm ci && npm run build && npm run start:packaged";let s=r&&`'${String(r).replace(/'/g,"'\\''")}'`;return s?`npx six-degrees@latest --data-dir ${s}`:"npx six-degrees@latest"}],12506);let t=Symbol.for("six-degrees.scan-state");function r(){let e=globalThis[t];return e?.running!==!0?null:"string"==typeof e.action&&e.action?e.action:"scan"}function s(e){switch(e){case"install":return"The scanner's packages are being installed";case"setup":return"The scanner is being set up";case"login":return"The LinkedIn sign-in window is open";case"photos":return"Profile photos are being saved";default:return"A scan is running"}}e.s(["busyRefusal",0,function(e,t=r()){return t?`${s(t)}. ${e}`:null},"registerScanState",0,function(e){return globalThis[t]||(globalThis[t]=e),globalThis[t]},"runningNow",0,s,"scannerJob",0,r],1348)}];
2
2
 
3
3
  //# sourceMappingURL=%5Broot-of-the-server%5D__0e0fei3._.js.map
@@ -1,3 +1,3 @@
1
1
  module.exports=[70406,(e,t,r)=>{t.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,t,r)=>{t.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,t,r)=>{t.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(e,t,r)=>{t.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},74533,(e,t,r)=>{t.exports=e.x("node:child_process",()=>require("node:child_process"))},66680,(e,t,r)=>{t.exports=e.x("node:crypto",()=>require("node:crypto"))},2157,(e,t,r)=>{t.exports=e.x("node:fs",()=>require("node:fs"))},12714,(e,t,r)=>{t.exports=e.x("node:fs/promises",()=>require("node:fs/promises"))},60526,(e,t,r)=>{t.exports=e.x("node:os",()=>require("node:os"))},50227,(e,t,r)=>{t.exports=e.x("node:path",()=>require("node:path"))},81111,(e,t,r)=>{t.exports=e.x("node:stream",()=>require("node:stream"))},80998,e=>{"use strict";var t=e.i(88431);let r=/^[a-z_][a-z0-9_]*$/i;function s(e,t){if(!r.test(e))throw Error(`Unsafe ${t}: ${e}`);return e}class i{constructor(e){this.table=s(e,"table"),this._columns="*",this._filters=[],this._order=null,this._limit=null,this._single=!1,this._op="select",this._payload=null,this._onConflict=null,this._ignoreDuplicates=!1}select(e="*"){return"select"===this._op&&(this._columns="*"===e?"*":e),this._returning=!0,this}eq(e,r){return s(e,"column"),null===r?this._filters.push({sql:`"${e}" IS NULL`,params:[]}):this._filters.push({sql:`"${e}" = ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}neq(e,r){return s(e,"column"),this._filters.push({sql:`"${e}" IS NOT ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}in(e,r){s(e,"column");let i=Array.isArray(r)?r:[];return i.length?this._filters.push({sql:`"${e}" IN (${i.map(()=>"?").join(", ")})`,params:i.map(r=>(0,t.encodeValue)(this.table,e,r))}):this._filters.push({sql:"0 = 1",params:[]}),this}ilike(e,t){return s(e,"column"),this._filters.push({sql:`"${e}" LIKE ?`,params:[t]}),this}not(e,r,i){return s(e,"column"),"is"===r&&null===i?this._filters.push({sql:`"${e}" IS NOT NULL`,params:[]}):this._filters.push({sql:`NOT ("${e}" = ?)`,params:[(0,t.encodeValue)(this.table,e,i)]}),this}is(e,r){return s(e,"column"),null===r?this._filters.push({sql:`"${e}" IS NULL`,params:[]}):this._filters.push({sql:`"${e}" = ?`,params:[(0,t.encodeValue)(this.table,e,r)]}),this}order(e,{ascending:t=!0}={}){return s(e,"column"),this._order=`"${e}" ${t?"ASC":"DESC NULLS LAST"}`,this}limit(e){return this._limit=Number(e)||0,this}single(){return this._single=!0,this._limit=this._limit??1,this}maybeSingle(){return this.single()}insert(e){return this._op="insert",this._payload=Array.isArray(e)?e:[e],this}upsert(e,t={}){return this._op="upsert",this._payload=Array.isArray(e)?e:[e],this._onConflict=t.onConflict||null,this._ignoreDuplicates=!!t.ignoreDuplicates,this}update(e){return this._op="update",this._payload=e,this}delete(){return this._op="delete",this}_where(){return this._filters.length?{sql:" WHERE "+this._filters.map(e=>e.sql).join(" AND "),params:this._filters.flatMap(e=>e.params)}:{sql:"",params:[]}}_run(){let e=(0,t.getDb)(),s=this._where();if("select"===this._op){let r=`SELECT ${"*"===this._columns?"*":this._columns} FROM "${this.table}"${s.sql}`;this._order&&(r+=` ORDER BY ${this._order}`),null!=this._limit&&(r+=` LIMIT ${Number(this._limit)}`);let i=e.prepare(r).all(...s.params).map(e=>(0,t.decodeRow)(this.table,e));return this._single?i.length?{data:i[0],error:null}:{data:null,error:{message:"No rows found",code:"PGRST116"}}:{data:i,error:null}}if("insert"===this._op||"upsert"===this._op){let s=[];for(let i of this._payload){let n={id:i.id||(0,t.newId)(),...i};n.id||(n.id=(0,t.newId)());let l=Object.keys(n).filter(e=>r.test(e)),a=l.map(e=>(0,t.encodeValue)(this.table,e,n[e])),o=l.map(()=>"?").join(", "),u=l.map(e=>`"${e}"`).join(", "),p=`INSERT INTO "${this.table}" (${u}) VALUES (${o})`;if("upsert"===this._op)if(this._ignoreDuplicates)p+=" ON CONFLICT DO NOTHING";else{let e=this._onConflict?this._onConflict.split(",").map(e=>`"${e.trim()}"`).join(", "):'"id"',t=l.filter(e=>"id"!==e).map(e=>`"${e}" = excluded."${e}"`).join(", ");p+=` ON CONFLICT (${e}) DO UPDATE SET ${t||'"id" = "id"'}`}try{e.prepare(p).run(...a);let r=e.prepare(`SELECT * FROM "${this.table}" WHERE id = ?`).get(n.id);r&&s.push((0,t.decodeRow)(this.table,r))}catch(e){if("upsert"===this._op&&/UNIQUE constraint/i.test(e.message))continue;return{data:null,error:{message:e.message}}}}return this._single?{data:s[0]??null,error:s.length?null:{message:"Insert returned no row"}}:{data:s,error:null}}if("update"===this._op){let i={...this._payload};"updated_at"in i==!1&&"linkedin_connections"===this.table&&(i.updated_at=(0,t.nowIso)());let n=Object.keys(i).filter(e=>r.test(e));if(!n.length)return{data:[],error:null};let l=n.map(e=>`"${e}" = ?`).join(", "),a=n.map(e=>(0,t.encodeValue)(this.table,e,i[e])),o=`UPDATE "${this.table}" SET ${l}${s.sql}`;try{let r=e.prepare(`SELECT id FROM "${this.table}"${s.sql}`).all(...s.params);e.prepare(o).run(...a,...s.params);let i=r.map(t=>e.prepare(`SELECT * FROM "${this.table}" WHERE id = ?`).get(t.id)).filter(Boolean).map(e=>(0,t.decodeRow)(this.table,e));if(this._single)return{data:i[0]??null,error:i.length?null:{message:"No rows updated"}};return{data:i,error:null}}catch(e){return{data:null,error:{message:e.message}}}}if("delete"===this._op)try{let r=e.prepare(`SELECT * FROM "${this.table}"${s.sql}`).all(...s.params).map(e=>(0,t.decodeRow)(this.table,e));return e.prepare(`DELETE FROM "${this.table}"${s.sql}`).run(...s.params),{data:r,error:null}}catch(e){return{data:null,error:{message:e.message}}}return{data:null,error:{message:`Unsupported operation: ${this._op}`}}}then(e,t){let r;try{r=this._run()}catch(e){r={data:null,error:{message:e.message}}}return Promise.resolve(r).then(e,t)}catch(e){return this.then(void 0,e)}finally(e){return this.then(t=>(e?.(),t),t=>{throw e?.(),t})}}e.s(["db",0,{from:e=>new i(e),async rpc(t,r={}){let{runRpc:s}=await e.A(35862);return s(t,r)}}])},12506,1348,e=>{"use strict";e.s(["compareVersions",0,function(e,t){let r=e=>String(e||"").replace(/^v/i,"").split(/[-+]/)[0].split(".").map(e=>Number.parseInt(e,10)||0),s=r(e),i=r(t);for(let e=0;e<Math.max(s.length,i.length);e++){let t=(s[e]||0)-(i[e]||0);if(0!==t)return t>0?1:-1}return 0},"installKind",0,function(e=process.env,t=""){return["mac-app","source","npm"].includes(e.SIX_DEGREES_INSTALL)?e.SIX_DEGREES_INSTALL:/\.app\/Contents\/Resources/.test(t||"")?"mac-app":"npm"},"repoSlug",0,function(e){let t=("string"==typeof e?e:e?.url||"").match(/github\.com[/:]([^/]+)\/([^/.#?]+)/);return t?`${t[1]}/${t[2]}`:null},"updateCommand",0,function(e,t,{dataDir:r}={}){if("mac-app"===e)return`curl -fsSL https://raw.githubusercontent.com/${t}/main/install.sh | bash`;if("source"===e)return"git pull && npm ci && npm run build && npm run start:packaged";let s=r&&`'${String(r).replace(/'/g,"'\\''")}'`;return s?`npx six-degrees@latest --data-dir ${s}`:"npx six-degrees@latest"}],12506);let t=Symbol.for("six-degrees.scan-state");function r(){let e=globalThis[t];return e?.running!==!0?null:"string"==typeof e.action&&e.action?e.action:"scan"}function s(e){switch(e){case"install":return"The scanner's packages are being installed";case"setup":return"The scanner is being set up";case"login":return"The LinkedIn sign-in window is open";case"photos":return"Profile photos are being saved";default:return"A scan is running"}}e.s(["busyRefusal",0,function(e,t=r()){return t?`${s(t)}. ${e}`:null},"registerScanState",0,function(e){return globalThis[t]||(globalThis[t]=e),globalThis[t]},"runningNow",0,s,"scannerJob",0,r],1348)},35862,e=>{e.v(t=>Promise.all(["server/chunks/lib_rpc_0c9d9ti.js"].map(t=>e.l(t))).then(()=>t(33471)))}];
2
2
 
3
- //# sourceMappingURL=%5Broot-of-the-server%5D__03ydxxh._.js.map
3
+ //# sourceMappingURL=%5Broot-of-the-server%5D__20tmem7._.js.map
@@ -1,4 +1,4 @@
1
- module.exports=[81638,e=>{"use strict";let t;var n=e.i(74533),r=e.i(2157),i=e.i(50227),o=e.i(10960),a=e.i(88602);let s=/LinkedIn reports (\d+) connections/,l=/^Downloading Python [\d.]+: ([\d.]+) of ([\d.]+) MB$/,u=/(\d+)\s*\/\s*(\d+)\s+collected/,d=/Collected all (\d+) connections/,c=/\[(\d+)\/(\d+)\]/,p=/^(Collected \d+ connections|Pushing \d+ connections|\s*Sent \d+ →|\s*Updating \d+ profile images|\s*\[image_store\]|\s*Images \d+-\d+)/;function h(e,t){return t?{done:Math.min(e,t),total:t,kind:"walk"}:null}var f=e.i(41238);function g(e,t){try{let n=JSON.parse((0,r.readFileSync)(i.default.join(e,"bridge-progress.json"),"utf8")),o=n?.[String(t||"default")];return o&&"object"==typeof o?o:{}}catch{return{}}}function m(e){try{return JSON.parse((0,r.readFileSync)(i.default.join(e,"bridge-unclear.json"),"utf8"))||{}}catch{return{}}}function y(e,t,n={},r={}){let i=[];for(let o of e){let e=o.profile_url,a=e?n[e]:void 0;if(!t.has(o.id)&&!a)continue;let s=function(e){if(!e)return 11;if(e.hidden||!e.more)return null;let t=(Number(e.pages)||0)+1;return t<=100?t:null}(a);null!=s&&i.push({id:o.id,name:o.name,tier:o.tier,profileUrl:e,pagesRead:s-1,nextPage:s,legacy:!a,at:a?.at||null,unclear:Number(r?.[e]?.n)||0,connected:o.connected_date||null,created:o.created_at||null})}let o=e=>`${+!!e.connected}|${e.connected||e.created||""}`;return i.sort((e,t)=>(e.unclear>=2)-(t.unclear>=2)||o(t).localeCompare(o(e))),i}var b=e.i(88431),w=e.i(1348),v=e.i(19041),_=e.i(98612);function S(e){return String(e?.profile_url||"").split(/[?#]/)[0].replace(/\/+$/,"")||`id:${e?.id}`}var R=e.i(66680),E=e.i(12714),T=e.i(98199),x=e.i(26525);let k=Object.freeze({release:"20260814",version:"3.12.14",builds:Object.freeze({"darwin-arm64":Object.freeze({file:"cpython-3.12.14+20260814-aarch64-apple-darwin-install_only.tar.gz",sha256:"4572133a5542f306b9bdb155da5800f9e38950cd0a98d469b832ce256fe299ea",size:0x17fc7f8}),"darwin-x64":Object.freeze({file:"cpython-3.12.14+20260814-x86_64-apple-darwin-install_only.tar.gz",sha256:"1a94c83264731e9603fbea78e57e7ca8f20e7d91eb866627ac2304621b0f6f1f",size:0x17b03bb}),"linux-x64":Object.freeze({file:"cpython-3.12.14+20260814-x86_64-unknown-linux-gnu-install_only_stripped.tar.gz",sha256:"5acfa3e9ba26b51ae161c83aff278da915b590d22373a424b2ba55b8afe91fcc",size:0x208fdfb}),"linux-arm64":Object.freeze({file:"cpython-3.12.14+20260814-aarch64-unknown-linux-gnu-install_only_stripped.tar.gz",sha256:"2d8e17dfd732102cfeb18e0e1fa6769b24caa034e159981129590fe409c7157a",size:0x1bdd3eb})})}),P=Object.freeze({min:[3,10],max:[3,14]}),C=Object.freeze(["/usr/bin/python3","python3","python","python3.14","python3.13","python3.12","python3.11","python3.10"]);function N(e,t=P){let n=String(e||"").match(/^(\d+)\.(\d+)/);if(!n)return!1;let r=[Number(n[1]),Number(n[2])],i=(e,t)=>e[0]-t[0]||e[1]-t[1];return i(r,t.min)>=0&&0>=i(r,t.max)}let D="import requests; from PIL import Image; from playwright.sync_api import sync_playwright",A=`import sys
1
+ module.exports=[81638,e=>{"use strict";let t;var n=e.i(74533),r=e.i(2157),i=e.i(50227),o=e.i(10960),a=e.i(88602);let s=/LinkedIn reports (\d+) connections/,l=/^Downloading Python [\d.]+: ([\d.]+) of ([\d.]+) MB$/,u=/(\d+)\s*\/\s*(\d+)\s+collected/,d=/Collected all (\d+) connections/,c=/\[(\d+)\/(\d+)\]/,p=/^(Collected \d+ connections|Pushing \d+ connections|\s*Sent \d+ →|\s*Updating \d+ profile images|\s*\[image_store\]|\s*Images \d+-\d+)/;function h(e,t){return t?{done:Math.min(e,t),total:t,kind:"walk"}:null}var f=e.i(41238);function g(e,t){try{let n=JSON.parse((0,r.readFileSync)(i.default.join(e,"bridge-progress.json"),"utf8")),o=n?.[String(t||"default")];return o&&"object"==typeof o?o:{}}catch{return{}}}function m(e){try{return JSON.parse((0,r.readFileSync)(i.default.join(e,"bridge-unclear.json"),"utf8"))||{}}catch{return{}}}function b(e,t,n={},r={}){let i=[];for(let o of e){let e=o.profile_url,a=e?n[e]:void 0;if(!t.has(o.id)&&!a)continue;let s=function(e){if(!e)return 11;if(e.hidden||!e.more)return null;let t=(Number(e.pages)||0)+1;return t<=100?t:null}(a);null!=s&&i.push({id:o.id,name:o.name,tier:o.tier,profileUrl:e,pagesRead:s-1,nextPage:s,legacy:!a,at:a?.at||null,unclear:Number(r?.[e]?.n)||0,connected:o.connected_date||null,created:o.created_at||null})}let o=e=>`${+!!e.connected}|${e.connected||e.created||""}`;return i.sort((e,t)=>(e.unclear>=2)-(t.unclear>=2)||o(t).localeCompare(o(e))),i}var y=e.i(88431),w=e.i(1348),v=e.i(19041),_=e.i(98612);function S(e){return String(e?.profile_url||"").split(/[?#]/)[0].replace(/\/+$/,"")||`id:${e?.id}`}var R=e.i(66680),E=e.i(12714),T=e.i(98199),x=e.i(26525);let k=Object.freeze({release:"20260814",version:"3.12.14",builds:Object.freeze({"darwin-arm64":Object.freeze({file:"cpython-3.12.14+20260814-aarch64-apple-darwin-install_only.tar.gz",sha256:"4572133a5542f306b9bdb155da5800f9e38950cd0a98d469b832ce256fe299ea",size:0x17fc7f8}),"darwin-x64":Object.freeze({file:"cpython-3.12.14+20260814-x86_64-apple-darwin-install_only.tar.gz",sha256:"1a94c83264731e9603fbea78e57e7ca8f20e7d91eb866627ac2304621b0f6f1f",size:0x17b03bb}),"linux-x64":Object.freeze({file:"cpython-3.12.14+20260814-x86_64-unknown-linux-gnu-install_only_stripped.tar.gz",sha256:"5acfa3e9ba26b51ae161c83aff278da915b590d22373a424b2ba55b8afe91fcc",size:0x208fdfb}),"linux-arm64":Object.freeze({file:"cpython-3.12.14+20260814-aarch64-unknown-linux-gnu-install_only_stripped.tar.gz",sha256:"2d8e17dfd732102cfeb18e0e1fa6769b24caa034e159981129590fe409c7157a",size:0x1bdd3eb})})}),N=Object.freeze({min:[3,10],max:[3,14]}),P=Object.freeze(["/usr/bin/python3","python3","python","python3.14","python3.13","python3.12","python3.11","python3.10"]);function C(e,t=N){let n=String(e||"").match(/^(\d+)\.(\d+)/);if(!n)return!1;let r=[Number(n[1]),Number(n[2])],i=(e,t)=>e[0]-t[0]||e[1]-t[1];return i(r,t.min)>=0&&0>=i(r,t.max)}let D="import requests; from PIL import Image; from playwright.sync_api import sync_playwright",A=`import sys
2
2
  print("version %d.%d.%d" % sys.version_info[:3])
3
3
  try:
4
4
  import venv, ensurepip
@@ -9,17 +9,17 @@ try:
9
9
  ${D}
10
10
  print("imports")
11
11
  except Exception as e:
12
- print("missing %s: %s" % (type(e).__name__, (str(e).splitlines() or [""])[0][:200]))`;function O(e){let t={version:null,venv:!1,imports:!1,missing:null};for(let n of String(e||"").split("\n").map(e=>e.trim()))n.startsWith("version ")?t.version=n.slice(8).trim()||null:"venv"===n?t.venv=!0:"imports"===n?t.imports=!0:n.startsWith("missing ")&&(t.missing=n.slice(8).trim()||null);return t}let j=Object.freeze(["-E","-s","-B","-u"]);function I(e=process.env){let t={};for(let[n,r]of Object.entries(e))n.startsWith("PYTHON")||(t[n]=r);return t.PYTHONNOUSERSITE="1",t.PYTHONDONTWRITEBYTECODE="1",t}function $(e=process.env){return{...e,PYTHONDONTWRITEBYTECODE:"1"}}let M=new Set(["target","prefix","root","user"]);function H(e=process.env){let t={};for(let[n,r]of Object.entries(e))n.startsWith("PIP_")&&M.has(n.slice(4).toLowerCase().replace(/_/g,"-"))||(t[n]=r);return t}function L(e){return i.default.join(e,"venv")}function U(e,t=process.platform){return"win32"===t?i.default.join(L(e),"Scripts","python.exe"):i.default.join(L(e),"bin","python")}let F="python";function W(e){return i.default.join(e,F,"bin","python3")}function z(e,t,{timeoutMs:r=8e3,env:i}={}){return new Promise(o=>{let a,s="",l="",u=!1,d=e=>{u||(u=!0,o(e))};try{a=(0,n.spawn)(e,t,{stdio:["ignore","pipe","pipe"],...i?{env:i}:{}})}catch(e){d({ok:!1,stdout:s,stderr:l,problem:e.message});return}let c=(e,t)=>e.length<16384?e+t.toString():e;a.stdout.on("data",e=>{s=c(s,e)}),a.stderr.on("data",e=>{l=c(l,e)});let p=setTimeout(()=>{try{a.kill("SIGKILL")}catch{}d({ok:!1,stdout:s,stderr:l,problem:`it didn't answer within ${Math.round(r/1e3)} seconds`})},r);a.on("error",e=>{clearTimeout(p),d({ok:!1,stdout:s,stderr:l,problem:"ENOENT"===e.code?"it isn't there":e.message})}),a.on("close",(e,t)=>{clearTimeout(p);let n=l.trim().split("\n").pop()||"";d({ok:0===e,stdout:s,stderr:l,problem:0===e?null:t?`it was stopped (${t})`:n||`it exited with ${e}`})})})}async function q({bundled:e="",app:t="",dataDir:n,probe:o=z,exists:a=r.default.existsSync,host:s=null,systemCandidates:l=C,timeouts:u={own:2e4,other:8e3},env:d=process.env}={}){let c={run:null,own:null,base:null,systemFound:null,download:null};if(e){let n=t&&i.default.resolve(e).startsWith(`${i.default.resolve(t)}${i.default.sep}`)?"bundled":"custom",r=await o(e,[...j,"-c",A],{timeoutMs:u.own,env:I(d)}),a=O(r.stdout);if(r.ok&&a.imports)return c.run={path:e,source:n,version:a.version},c;c.own={source:n,problem:a.missing||r.problem||"it didn't start"}}let p=U(n);if(a(p)){let e=await o(p,["-c",A],{timeoutMs:u.other,env:d}),t=O(e.stdout);if(e.ok&&t.imports)return c.run={path:p,source:"venv",version:t.version},c}let h=[];for(let e of l){let t=await o(e,["-c",A],{timeoutMs:u.other,env:d}),n=O(t.stdout);if(n.version){if(t.ok&&n.imports)return c.run={path:e,source:"system",version:n.version},c;h.push({path:e,version:n.version,venv:n.venv})}}let f=h.find(e=>e.venv&&N(e.version));if(f)return c.base={path:f.path,source:"system",version:f.version},c;let g=h.find(e=>N(e.version))||h[0];c.systemFound=g?{version:g.version,venv:g.venv}:null;let m=W(n);if(a(m)){let e=await o(m,[...j,"-c",A],{timeoutMs:u.other,env:I(d)}),t=O(e.stdout);if(e.ok&&t.venv)return c.base={path:m,source:"downloaded",version:t.version},c}return c.download=function(e,t=k){let n=e&&Object.hasOwn(t.builds,e)?t.builds[e]:null;return n?{key:e,version:t.version,release:t.release,...n,url:function(e,t=k){return`https://github.com/astral-sh/python-build-standalone/releases/download/${t.release}/${encodeURIComponent(e.file)}`}(n,t)}:null}(s),c}class G extends Error{}let B=(...e)=>(globalThis.fetch?._nextOriginalFetch||globalThis.fetch)(...e),K=e=>(e/1048576).toFixed(1);async function X(e,t,{sha256:n,size:r,signal:i,onProgress:o,idleMs:a=3e4,fetchImpl:s=B,from:l="GitHub"}={}){if(!/^[0-9a-f]{64}$/.test(String(n))||!(Number.isInteger(r)&&r>0))throw new G("There is no pinned checksum for this download, so it wasn't started.");let u=`${t}.part`,d=new AbortController,c=i?AbortSignal.any([i,d.signal]):d.signal,p=null,h=()=>{clearTimeout(p),p=setTimeout(()=>d.abort(new G(`The download stopped for ${Math.round(a/1e3)} seconds. Check your connection and try again.`)),a)};h();let f=await E.default.open(u,"w"),g=(0,R.createHash)("sha256"),m=0,y=!1;try{let t=await s(e,{signal:c,redirect:"follow",cache:"no-store",headers:{Accept:"application/octet-stream","User-Agent":"six-degrees-scanner-setup"}});if(!t.ok||!t.body)throw new G(`${l} answered ${t.status} to the download. Try again later.`);let i=Number(t.headers.get("content-length"))||null;if(i&&i!==r)throw new G(`The download isn't the size it should be (${i} bytes, not ${r}), so it was stopped.`);for await(let e of t.body){if(h(),(m+=e.byteLength)>r)throw new G("The download is bigger than it should be, so it was stopped.");g.update(e);let t=0;for(;t<e.byteLength;){let{bytesWritten:n}=await f.write(e,t,e.byteLength-t);t+=n}o?.(m,r)}if(m!==r)throw new G("The download ended early. Try again.");let a=g.digest("hex");if(a!==n)throw new G("The download doesn't match the checksum Six Degrees has for it, so it was deleted and nothing was unpacked.");return y=!0,a}catch(e){if(c.aborted&&c.reason instanceof Error)throw c.reason;throw e}finally{clearTimeout(p),await f.close(),y?await E.default.rename(u,t):await E.default.rm(u,{force:!0})}}async function Y(e,t,n){let o=i.default.join(e,"python");if(!await E.default.lstat(i.default.join(o,"bin","python3")).catch(()=>null))throw new G("The download didn't contain the Python it should have.");let a=i.default.join(t,F);return r.default.existsSync(a)&&await E.default.rename(a,i.default.join(n,"python-before")),await E.default.rename(o,a),W(t)}let V=(0,w.registerScanState)({running:!1,action:null,target:null,recent:[],log:[],startedAt:null,exitCode:null,child:null,abort:null,stopping:!1,stderrTail:[],failure:null});function J(e){for(let t of String(e).split("\n")){let e=t.replace(/\s+$/,"");e&&V.log.push(e)}V.log.length>500&&V.log.splice(0,V.log.length-500)}function Z(){try{let e=(0,r.readFileSync)(i.default.join((0,o.dataDir)(),"bridge-skips.json"),"utf8"),t=JSON.parse(e);return Object.entries(t).map(([e,t])=>({profileUrl:e,name:t?.name??"",reason:t?.reason??"",at:t?.at??null}))}catch{return[]}}function Q(){let e=[];try{let t=(0,a.resolveProfile)({create:!1});t&&(e=Object.keys(g((0,o.dataDir)(),t.id)))}catch{}return{skips:Z(),read:e}}let ee={at:0,value:null},et=null,en=0;function er(){en++,ee={at:0,value:null},et=null}let ei=Symbol.for("six-degrees.python-looker"),eo=globalThis[ei]??=function({choose:e=q,now:t=Date.now,retryMs:n=6e4}={}){let r=null,i=null;return async function(o,a={}){if(o&&r?.path===o)return{run:r,own:null,base:null,systemFound:null,download:null};let s=!!o&&i?.path===o&&(!1===i.own.retry||t()-i.at<n),l=await e({...a,bundled:s?"":o});if(s)return{...l,own:i.own};if(o&&l.run?.path===o)r=l.run;else if(o&&l.own){let e="bundled"===l.own.source?{...l.own,retry:!1}:l.own;return i={path:o,at:t(),own:e},{...l,own:e}}return l}}();async function ea(){let e=(0,o.projectRoot)(),n=await eo(process.env.SIX_DEGREES_PYTHON||"",{app:process.env.SIX_DEGREES_APP||"",dataDir:(0,o.dataDir)(),host:(void 0===t&&(t=function({platform:e=process.platform,arch:t=process.arch,sysctlArm64:n=""}={}){return"darwin"===e?`darwin-${(0,T.chipOf)({sysctlArm64:n,processArch:t})}`:"linux"===e&&("x64"===t||"arm64"===t)?`linux-${t}`:null}({sysctlArm64:""})),t)});return{root:e,python:n,chrome:(0,r.existsSync)("/opt/google/chrome/chrome"),signedIn:(0,r.existsSync)(i.default.join((0,o.dataDir)(),"chrome-profile","Default","Cookies"))}}function es(){if(Date.now()-ee.at<4e3&&ee.value)return Promise.resolve(ee.value);if(et)return et;let e=en,t=ea().then(t=>(e===en&&(ee={at:Date.now(),value:t}),t)).finally(()=>{et===t&&(et=null)});return et=t,t}async function el(){let e=await es(),t={first:0,second:0,third:0},n=null;try{(n=(0,a.resolveProfile)({create:!1}))&&(t=(0,a.networkCounts)(n.id))}catch{}let r=0;try{r=(0,_.waitingPhotoCount)((0,b.getDb)())}catch{}let i=e.python;return{ready:!!(e.root&&i.run&&e.chrome),checks:{scriptsFound:!!e.root,python:!!(i.run||i.base),pythonPath:i.run?.path||i.base?.path||null,pythonVersion:i.run?.version||i.base?.version||null,pythonSource:i.run?.source||null,dependencies:!!i.run,ownPython:i.own,installFrom:i.base?{source:i.base.source,version:i.base.version}:null,systemPython:i.systemFound,download:i.download?{version:i.download.version,size:i.download.size,from:"github.com"}:null,chrome:e.chrome,signedIn:e.signedIn},network:t,photosWaiting:r,...eu(),skips:Z(),linkedin:(0,f.linkedinState)((0,o.dataDir)()),paused:function(e){if(!e)return[];try{let t=(0,b.getDb)(),n=t.prepare(`SELECT id, name, tier, profile_url, connected_date, created_at
12
+ print("missing %s: %s" % (type(e).__name__, (str(e).splitlines() or [""])[0][:200]))`;function O(e){let t={version:null,venv:!1,imports:!1,missing:null};for(let n of String(e||"").split("\n").map(e=>e.trim()))n.startsWith("version ")?t.version=n.slice(8).trim()||null:"venv"===n?t.venv=!0:"imports"===n?t.imports=!0:n.startsWith("missing ")&&(t.missing=n.slice(8).trim()||null);return t}let j=Object.freeze(["-E","-s","-B","-u"]);function I(e=process.env){let t={};for(let[n,r]of Object.entries(e))n.startsWith("PYTHON")||(t[n]=r);return t.PYTHONNOUSERSITE="1",t.PYTHONDONTWRITEBYTECODE="1",t}function $(e=process.env){return{...e,PYTHONDONTWRITEBYTECODE:"1"}}let M=new Set(["target","prefix","root","user"]);function H(e=process.env){let t={};for(let[n,r]of Object.entries(e))n.startsWith("PIP_")&&M.has(n.slice(4).toLowerCase().replace(/_/g,"-"))||(t[n]=r);return t}function L(e){return i.default.join(e,"venv")}function U(e,t=process.platform){return"win32"===t?i.default.join(L(e),"Scripts","python.exe"):i.default.join(L(e),"bin","python")}let F="python";function W(e){return i.default.join(e,F,"bin","python3")}function z(e,t,{timeoutMs:r=8e3,env:i}={}){return new Promise(o=>{let a,s="",l="",u=!1,d=e=>{u||(u=!0,o(e))};try{a=(0,n.spawn)(e,t,{stdio:["ignore","pipe","pipe"],...i?{env:i}:{}})}catch(e){d({ok:!1,stdout:s,stderr:l,problem:e.message});return}let c=(e,t)=>e.length<16384?e+t.toString():e;a.stdout.on("data",e=>{s=c(s,e)}),a.stderr.on("data",e=>{l=c(l,e)});let p=setTimeout(()=>{try{a.kill("SIGKILL")}catch{}d({ok:!1,stdout:s,stderr:l,problem:`it didn't answer within ${Math.round(r/1e3)} seconds`})},r);a.on("error",e=>{clearTimeout(p),d({ok:!1,stdout:s,stderr:l,problem:"ENOENT"===e.code?"it isn't there":e.message})}),a.on("close",(e,t)=>{clearTimeout(p);let n=l.trim().split("\n").pop()||"";d({ok:0===e,stdout:s,stderr:l,problem:0===e?null:t?`it was stopped (${t})`:n||`it exited with ${e}`})})})}async function q({bundled:e="",app:t="",dataDir:n,probe:o=z,exists:a=r.default.existsSync,host:s=null,systemCandidates:l=P,timeouts:u={own:2e4,other:8e3},env:d=process.env}={}){let c={run:null,own:null,base:null,systemFound:null,download:null};if(e){let n=t&&i.default.resolve(e).startsWith(`${i.default.resolve(t)}${i.default.sep}`)?"bundled":"custom",r=await o(e,[...j,"-c",A],{timeoutMs:u.own,env:I(d)}),a=O(r.stdout);if(r.ok&&a.imports)return c.run={path:e,source:n,version:a.version},c;c.own={source:n,problem:a.missing||r.problem||"it didn't start"}}let p=U(n);if(a(p)){let e=await o(p,["-c",A],{timeoutMs:u.other,env:d}),t=O(e.stdout);if(e.ok&&t.imports)return c.run={path:p,source:"venv",version:t.version},c}let h=[];for(let e of l){let t=await o(e,["-c",A],{timeoutMs:u.other,env:d}),n=O(t.stdout);if(n.version){if(t.ok&&n.imports)return c.run={path:e,source:"system",version:n.version},c;h.push({path:e,version:n.version,venv:n.venv})}}let f=h.find(e=>e.venv&&C(e.version));if(f)return c.base={path:f.path,source:"system",version:f.version},c;let g=h.find(e=>C(e.version))||h[0];c.systemFound=g?{version:g.version,venv:g.venv}:null;let m=W(n);if(a(m)){let e=await o(m,[...j,"-c",A],{timeoutMs:u.other,env:I(d)}),t=O(e.stdout);if(e.ok&&t.venv)return c.base={path:m,source:"downloaded",version:t.version},c}return c.download=function(e,t=k){let n=e&&Object.hasOwn(t.builds,e)?t.builds[e]:null;return n?{key:e,version:t.version,release:t.release,...n,url:function(e,t=k){return`https://github.com/astral-sh/python-build-standalone/releases/download/${t.release}/${encodeURIComponent(e.file)}`}(n,t)}:null}(s),c}class G extends Error{}let B=(...e)=>(globalThis.fetch?._nextOriginalFetch||globalThis.fetch)(...e),K=e=>(e/1048576).toFixed(1);async function X(e,t,{sha256:n,size:r,signal:i,onProgress:o,idleMs:a=3e4,fetchImpl:s=B,from:l="GitHub"}={}){if(!/^[0-9a-f]{64}$/.test(String(n))||!(Number.isInteger(r)&&r>0))throw new G("There is no pinned checksum for this download, so it wasn't started.");let u=`${t}.part`,d=new AbortController,c=i?AbortSignal.any([i,d.signal]):d.signal,p=null,h=()=>{clearTimeout(p),p=setTimeout(()=>d.abort(new G(`The download stopped for ${Math.round(a/1e3)} seconds. Check your connection and try again.`)),a)};h();let f=await E.default.open(u,"w"),g=(0,R.createHash)("sha256"),m=0,b=!1;try{let t=await s(e,{signal:c,redirect:"follow",cache:"no-store",headers:{Accept:"application/octet-stream","User-Agent":"six-degrees-scanner-setup"}});if(!t.ok||!t.body)throw new G(`${l} answered ${t.status} to the download. Try again later.`);let i=Number(t.headers.get("content-length"))||null;if(i&&i!==r)throw new G(`The download isn't the size it should be (${i} bytes, not ${r}), so it was stopped.`);for await(let e of t.body){if(h(),(m+=e.byteLength)>r)throw new G("The download is bigger than it should be, so it was stopped.");g.update(e);let t=0;for(;t<e.byteLength;){let{bytesWritten:n}=await f.write(e,t,e.byteLength-t);t+=n}o?.(m,r)}if(m!==r)throw new G("The download ended early. Try again.");let a=g.digest("hex");if(a!==n)throw new G("The download doesn't match the checksum Six Degrees has for it, so it was deleted and nothing was unpacked.");return b=!0,a}catch(e){if(c.aborted&&c.reason instanceof Error)throw c.reason;throw e}finally{clearTimeout(p),await f.close(),b?await E.default.rename(u,t):await E.default.rm(u,{force:!0})}}async function Y(e,t,n){let o=i.default.join(e,"python");if(!await E.default.lstat(i.default.join(o,"bin","python3")).catch(()=>null))throw new G("The download didn't contain the Python it should have.");let a=i.default.join(t,F);return r.default.existsSync(a)&&await E.default.rename(a,i.default.join(n,"python-before")),await E.default.rename(o,a),W(t)}let V=(0,w.registerScanState)({running:!1,action:null,target:null,recent:[],log:[],startedAt:null,exitCode:null,child:null,abort:null,stopping:!1,stderrTail:[],failure:null});function J(e){for(let t of String(e).split("\n")){let e=t.replace(/\s+$/,"");e&&V.log.push(e)}V.log.length>500&&V.log.splice(0,V.log.length-500)}function Z(){try{let e=(0,r.readFileSync)(i.default.join((0,o.dataDir)(),"bridge-skips.json"),"utf8"),t=JSON.parse(e);return Object.entries(t).map(([e,t])=>({profileUrl:e,name:t?.name??"",reason:t?.reason??"",at:t?.at??null}))}catch{return[]}}function Q(){let e=[],t={};try{let n=(0,a.resolveProfile)({create:!1});if(n){let r=g((0,o.dataDir)(),n.id);for(let[n,i]of(e=Object.keys(r),Object.entries(r)))t[n]={pages:Number(i?.pages)||0,more:!!i?.more,total:Number(i?.total)||null}}}catch{}return{skips:Z(),read:e,lists:t}}let ee={at:0,value:null},et=null,en=0;function er(){en++,ee={at:0,value:null},et=null}let ei=Symbol.for("six-degrees.python-looker"),eo=globalThis[ei]??=function({choose:e=q,now:t=Date.now,retryMs:n=6e4}={}){let r=null,i=null;return async function(o,a={}){if(o&&r?.path===o)return{run:r,own:null,base:null,systemFound:null,download:null};let s=!!o&&i?.path===o&&(!1===i.own.retry||t()-i.at<n),l=await e({...a,bundled:s?"":o});if(s)return{...l,own:i.own};if(o&&l.run?.path===o)r=l.run;else if(o&&l.own){let e="bundled"===l.own.source?{...l.own,retry:!1}:l.own;return i={path:o,at:t(),own:e},{...l,own:e}}return l}}();async function ea(){let e=(0,o.projectRoot)(),n=await eo(process.env.SIX_DEGREES_PYTHON||"",{app:process.env.SIX_DEGREES_APP||"",dataDir:(0,o.dataDir)(),host:(void 0===t&&(t=function({platform:e=process.platform,arch:t=process.arch,sysctlArm64:n=""}={}){return"darwin"===e?`darwin-${(0,T.chipOf)({sysctlArm64:n,processArch:t})}`:"linux"===e&&("x64"===t||"arm64"===t)?`linux-${t}`:null}({sysctlArm64:""})),t)});return{root:e,python:n,chrome:(0,r.existsSync)("/opt/google/chrome/chrome"),signedIn:(0,r.existsSync)(i.default.join((0,o.dataDir)(),"chrome-profile","Default","Cookies"))}}function es(){if(Date.now()-ee.at<4e3&&ee.value)return Promise.resolve(ee.value);if(et)return et;let e=en,t=ea().then(t=>(e===en&&(ee={at:Date.now(),value:t}),t)).finally(()=>{et===t&&(et=null)});return et=t,t}async function el(){let e=await es(),t={first:0,second:0,third:0},n=null;try{(n=(0,a.resolveProfile)({create:!1}))&&(t=(0,a.networkCounts)(n.id))}catch{}let r=0;try{r=(0,_.waitingPhotoCount)((0,y.getDb)())}catch{}let i=e.python;return{ready:!!(e.root&&i.run&&e.chrome),checks:{scriptsFound:!!e.root,python:!!(i.run||i.base),pythonPath:i.run?.path||i.base?.path||null,pythonVersion:i.run?.version||i.base?.version||null,pythonSource:i.run?.source||null,dependencies:!!i.run,ownPython:i.own,installFrom:i.base?{source:i.base.source,version:i.base.version}:null,systemPython:i.systemFound,download:i.download?{version:i.download.version,size:i.download.size,from:"github.com"}:null,chrome:e.chrome,signedIn:e.signedIn},network:t,photosWaiting:r,...eu(),skips:Z(),linkedin:(0,f.linkedinState)((0,o.dataDir)()),paused:function(e){if(!e)return[];try{let t=(0,y.getDb)(),n=t.prepare(`SELECT id, name, tier, profile_url, connected_date, created_at
13
13
  FROM linkedin_connections WHERE user_id = ? AND degree = 1`).all(e),r=new Set(t.prepare(`SELECT DISTINCT source_connection_id AS id FROM linkedin_connections
14
- WHERE user_id = ? AND degree = 2 AND source_connection_id IS NOT NULL`).all(e).map(e=>e.id));return y(n,r,g((0,o.dataDir)(),e),m((0,o.dataDir)()))}catch{return[]}}(n?.id)}}function eu(){return{running:V.running,action:V.action,target:V.target,startedAt:V.startedAt,exitCode:V.exitCode,failure:V.running?null:V.failure,progress:V.running?function(e,t){if(!Array.isArray(e)||0===e.length)return null;if("setup"===t){let t=String(e[e.length-1]).match(l);return t&&Number(t[2])?{done:Math.min(Number(t[1]),Number(t[2])),total:Number(t[2]),kind:"download"}:null}if("full"===t||"refresh"===t){for(let t=e.length-1;t>=0;t--){let n=String(e[t]);if(p.test(n))return{kind:"saving"};let r=n.match(d);if(r)return h(Number(r[1]),Number(r[1]));let i=n.match(u);if(i)return h(Number(i[1]),Number(i[2]));let o=n.match(s);if(o)return h(0,Number(o[1]))}return null}if(t&&(t.startsWith("auto-bridge")||"resume-all"===t))for(let t=e.length-1;t>=0;t--){let n=String(e[t]).match(c);if(n){let e=Number(n[1]),t=Number(n[2]);if(!t)return null;return{done:Math.min(e-1,t),total:t,current:e,kind:"batch"}}}return null}(V.log,V.action):null,log:V.log.slice(-120),recent:V.recent}}async function ed(e){let t=new URL(e?.url||"http://127.0.0.1/api/scraper").searchParams;return t.has("job")?Response.json(eu()):t.has("resume")?Response.json({resume:function(e){try{let t=(0,a.resolveProfile)({create:!1});if(!t)return null;let n=(0,b.getDb)(),r=n.prepare(`SELECT id, name, tier, profile_url, connected_date, created_at
15
- FROM linkedin_connections WHERE id = ? AND user_id = ? AND degree = 1`).get(String(e??""),t.id);if(!r)return null;let i=n.prepare("SELECT 1 FROM linkedin_connections WHERE user_id = ? AND degree = 2 AND source_connection_id = ? LIMIT 1").get(t.id,r.id),[s]=y([r],new Set(i?[r.id]:[]),g((0,o.dataDir)(),t.id),m((0,o.dataDir)()));return s?{nextPage:s.nextPage,pagesRead:s.pagesRead,legacy:s.legacy}:null}catch{return null}}(t.get("resume"))}):t.has("reach")?Response.json(Q()):t.has("person")?Response.json(function(e){try{let t=(0,a.resolveProfile)({create:!1});if(!t)return{person:null};let n=(0,b.getDb)(),r=n.prepare(`SELECT id, name, tier, power_score, degree, profile_url, unlocked_from_bridge_id, unlocked_from_name
16
- FROM linkedin_connections WHERE id = ? AND user_id = ? AND degree = 1`).get(String(e??""),t.id);if(!r)return{person:null};let i=n.prepare("SELECT 1 FROM linkedin_connections WHERE user_id = ? AND degree = 2 AND source_connection_id = ? LIMIT 1").get(t.id,r.id),o=function(e=[],t=[],n={}){let r=new Set;for(let e of t||[])e?.source_connection_id!=null&&r.add(e.source_connection_id);let i=new Set;for(let e of n?.skips||[])e?.profileUrl&&i.add(S({profile_url:e.profileUrl}));let o=new Set;for(let e of n?.read||[])e&&o.add(S({profile_url:e}));let a=new Map;for(let t of e||[]){let e=t?.unlocked_from_bridge_id;if(null==e||1!==t.degree)continue;let n=a.get(e);n||a.set(e,n=[]),n.push(t)}return{scanned:r,read:o,hidden:i,reachedFrom:a}}([],i?[{source_connection_id:r.id}]:[],Q());return{person:{id:r.id,name:r.name,tier:r.tier,power_score:r.power_score,unlocked_from_bridge_id:r.unlocked_from_bridge_id,unlocked_from_name:r.unlocked_from_name},circle:r?o.scanned.has(r.id)||r.profile_url&&o.read?.has(S(r))?"scanned":r.profile_url&&o.hidden.has(S(r))?"hidden":"todo":"todo"}}catch{return{person:null}}}(t.get("person"))):Response.json(await el())}let ec={install:{label:"Installing the scanner’s Python packages"},setup:{label:"Setting up the scanner"},login:{flag:"--login",label:"Opening LinkedIn so you can sign in"},full:{flag:"--full",label:"Scanning your whole network"},refresh:{flag:"--refresh",label:"Checking for new connections"},"auto-bridge":{flag:"--auto-bridge",label:"Mapping every bridge in turn"},"auto-bridge-retry":{flag:"--auto-bridge --retry-private",label:"Mapping every bridge, hidden ones included"},bridge:{flag:"--bridge",needsName:!0,byId:!0,label:"Mapping the circle behind"},resume:{flag:"--bridge-url",needsId:!0,label:"Carrying on with",searches:!0},"resume-all":{flag:"--auto-bridge --only-unfinished",label:"Carrying on with every paused list",searches:!0},rescrape:{flag:"--rescrape",needsName:!0,label:"Re-mapping the circle behind"},company:{flag:"--company",needsName:!0,label:"Scanning"},photos:{flag:"--save-photos",label:"Saving profile photos to this computer"}};async function ep(e){let t,s={};try{s=await e.json()}catch{}let l=String(s.action||"");if("cancel"===l)return!function(){if(V.abort){V.stopping=!0,J("Stopping…"),V.abort.abort(new G("Stopped."));return}let e=V.child;if(!e)return;V.stopping=!0,J("Stopping…");let t=e.pid;try{process.kill(-t,"SIGTERM")}catch{try{e.kill("SIGTERM")}catch{}}setTimeout(()=>{if(V.child&&V.child.pid===t){J("Still running — forcing it.");try{process.kill(-t,"SIGKILL")}catch{try{e.kill("SIGKILL")}catch{}}}},2e4)}(),Response.json({ok:!0,cancelled:!0});if("set-limits"===l){let e=(0,f.writeLimits)((0,o.dataDir)(),{daily:s.daily,monthly:s.monthly,profiles:s.profiles});return Response.json({ok:!0,limits:e})}if("lift-cooldown"===l)return(0,f.liftCooldown)((0,o.dataDir)()),Response.json({ok:!0});if(!Object.hasOwn(ec,l))return Response.json({error:`Unknown action '${l}'`},{status:400});let u=ec[l],d=Number.isInteger(s.maxBridges)&&s.maxBridges>0?Math.min(s.maxBridges,500):0,c=Array.isArray(s.tiers)?s.tiers.map(e=>String(e).toUpperCase()).filter(e=>"SABCD".includes(e)&&1===e.length):[],p="score"===s.order?"score":"newest",h=[10,25,50,100].includes(s.maxPages)?s.maxPages:100,g=l.startsWith("auto-bridge")||["bridge","rescrape","resume","resume-all"].includes(l),m=!0===s.deeper&&(l.startsWith("auto-bridge")||"bridge"===l),y=u.needsId||u.byId&&!!s.id,w=null;if(u.needsName&&!y){let e;if(!(w=!(e=String(s.name??"").trim())||e.length>120||/[\u0000-\u001f]/.test(e)?null:e))return Response.json({error:"A name is required for this action."},{status:400})}let _=null,S=null;if(y){try{var R;let e,t=(0,a.resolveProfile)({create:!1});S=t&&(0,b.getDb)().prepare("SELECT name, profile_url FROM linkedin_connections WHERE id = ? AND user_id = ? AND degree = 1").get(String(s.id??""),t.id),_=S?.profile_url&&(R=S.profile_url,(e=String(R??"").trim()).length>400||/[\u0000-\u001f\s]/.test(e)?null:/^https?:\/\/([a-z]{2,3}\.|www\.)?linkedin\.com\/in\/[^/?#]+\/?$/i.test(e)?e:null)}catch{_=null}if(!_)return Response.json({error:"That connection could not be found."},{status:400})}let E="string"==typeof s.id&&/^[\w-]{1,64}$/.test(s.id)?s.id:null,T=w||_?{id:E,name:w||S?.name||null}:null,k=u.searches||l.startsWith("auto-bridge")||["bridge","rescrape","company","full","refresh"].includes(l);if(!["install","setup","login"].includes(l)&&(0,v.pendingImport)((0,o.dataDir)()))return Response.json({error:"An import is waiting to finish. Restart Six Degrees first (Settings → Your data), then scan."},{status:409});let P=(0,f.linkedinState)((0,o.dataDir)()).cooldown;if(k&&P)return Response.json({error:`Scanning is paused until ${new Date(P.until).toLocaleString()} — ${P.reason}.`,cooldown:P},{status:409});if(V.running)return Response.json({error:"Something is already running.",action:V.action},{status:409});let C=(0,o.projectRoot)();if(!C)return Response.json({error:"Could not find scripts/scrape.py next to the app."},{status:500});er();let N=(await es()).python;if(V.running)return Response.json({error:"Something is already running.",action:V.action},{status:409});let A=null;if("install"===l||"setup"===l){let e=function(e,t,{root:n,data:o,say:a}){if(t.run)return{status:409,error:"bundled"===t.run.source?"The scanner is already set up: its Python comes with the app.":"The scanner is already set up."};let s=t.base;if("install"===e&&!s)return t.download?{status:409,error:"This computer has no Python the scanner can use. Use Set up the scanner instead."}:{status:500,error:"No Python 3.10 to 3.14 is installed, or none is on this app’s PATH."};if("setup"===e&&s?.source==="system")return{status:409,error:`This computer already has Python ${s.version}, so nothing needs downloading. Use Install instead.`};if("setup"===e&&!s&&!t.download)return{status:409,error:"There is no Python download for this computer. Install Python 3.10 to 3.14, then reload."};let l=i.default.join(n,"scripts","requirements.txt"),u=e=>(function({base:e,dataDir:t,requirements:n}){let r="downloaded"===e.source,i=U(t);return[{cmd:e.path,args:[...r?j:[],"-m","venv","--clear",L(t)],...r?{env:I}:{},note:"Creating the scanner’s own Python environment"},{cmd:i,args:["-m","pip","install","--disable-pip-version-check","--no-input","-r",n],env:H,note:"Installing Playwright, requests and Pillow"},{cmd:i,args:["-c",function(e=D){return`import sys
14
+ WHERE user_id = ? AND degree = 2 AND source_connection_id IS NOT NULL`).all(e).map(e=>e.id));return b(n,r,g((0,o.dataDir)(),e),m((0,o.dataDir)()))}catch{return[]}}(n?.id)}}function eu(){return{running:V.running,action:V.action,target:V.target,startedAt:V.startedAt,exitCode:V.exitCode,failure:V.running?null:V.failure,progress:V.running?function(e,t){if(!Array.isArray(e)||0===e.length)return null;if("setup"===t){let t=String(e[e.length-1]).match(l);return t&&Number(t[2])?{done:Math.min(Number(t[1]),Number(t[2])),total:Number(t[2]),kind:"download"}:null}if("full"===t||"refresh"===t){for(let t=e.length-1;t>=0;t--){let n=String(e[t]);if(p.test(n))return{kind:"saving"};let r=n.match(d);if(r)return h(Number(r[1]),Number(r[1]));let i=n.match(u);if(i)return h(Number(i[1]),Number(i[2]));let o=n.match(s);if(o)return h(0,Number(o[1]))}return null}if(t&&(t.startsWith("auto-bridge")||"resume-all"===t))for(let t=e.length-1;t>=0;t--){let n=String(e[t]).match(c);if(n){let e=Number(n[1]),t=Number(n[2]);if(!t)return null;return{done:Math.min(e-1,t),total:t,current:e,kind:"batch"}}}return null}(V.log,V.action):null,log:V.log.slice(-120),recent:V.recent}}async function ed(e){let t=new URL(e?.url||"http://127.0.0.1/api/scraper").searchParams;return t.has("job")?Response.json(eu()):t.has("resume")?Response.json({resume:function(e){try{let t=(0,a.resolveProfile)({create:!1});if(!t)return null;let n=(0,y.getDb)(),r=n.prepare(`SELECT id, name, tier, profile_url, connected_date, created_at
15
+ FROM linkedin_connections WHERE id = ? AND user_id = ? AND degree = 1`).get(String(e??""),t.id);if(!r)return null;let i=n.prepare("SELECT 1 FROM linkedin_connections WHERE user_id = ? AND degree = 2 AND source_connection_id = ? LIMIT 1").get(t.id,r.id),[s]=b([r],new Set(i?[r.id]:[]),g((0,o.dataDir)(),t.id),m((0,o.dataDir)()));return s?{nextPage:s.nextPage,pagesRead:s.pagesRead,legacy:s.legacy}:null}catch{return null}}(t.get("resume"))}):t.has("reach")?Response.json(Q()):t.has("person")?Response.json(function(e){try{let t=(0,a.resolveProfile)({create:!1});if(!t)return{person:null};let n=(0,y.getDb)(),r=n.prepare(`SELECT id, name, tier, power_score, degree, profile_url, unlocked_from_bridge_id, unlocked_from_name
16
+ FROM linkedin_connections WHERE id = ? AND user_id = ? AND degree = 1`).get(String(e??""),t.id);if(!r)return{person:null};let i=n.prepare("SELECT 1 FROM linkedin_connections WHERE user_id = ? AND degree = 2 AND source_connection_id = ? LIMIT 1").get(t.id,r.id),o=function(e=[],t=[],n={}){let r=new Set;for(let e of t||[])e?.source_connection_id!=null&&r.add(e.source_connection_id);let i=new Set;for(let e of n?.skips||[])e?.profileUrl&&i.add(S({profile_url:e.profileUrl}));let o=new Set;for(let e of n?.read||[])e&&o.add(S({profile_url:e}));let a=new Map;for(let[e,t]of Object.entries(n?.lists||{}))e&&t&&a.set(S({profile_url:e}),t);let s=new Map;for(let t of e||[]){let e=t?.unlocked_from_bridge_id;if(null==e||1!==t.degree)continue;let n=s.get(e);n||s.set(e,n=[]),n.push(t)}return{scanned:r,read:o,hidden:i,reachedFrom:s,lists:a}}([],i?[{source_connection_id:r.id}]:[],Q());return{person:{id:r.id,name:r.name,tier:r.tier,power_score:r.power_score,unlocked_from_bridge_id:r.unlocked_from_bridge_id,unlocked_from_name:r.unlocked_from_name},circle:r?o.scanned.has(r.id)||r.profile_url&&o.read?.has(S(r))?"scanned":r.profile_url&&o.hidden.has(S(r))?"hidden":"todo":"todo"}}catch{return{person:null}}}(t.get("person"))):Response.json(await el())}let ec={install:{label:"Installing the scanner’s Python packages"},setup:{label:"Setting up the scanner"},login:{flag:"--login",label:"Opening LinkedIn so you can sign in"},full:{flag:"--full",label:"Scanning your whole network"},refresh:{flag:"--refresh",label:"Checking for new connections"},"auto-bridge":{flag:"--auto-bridge",label:"Mapping every bridge in turn"},"auto-bridge-retry":{flag:"--auto-bridge --retry-private",label:"Mapping every bridge, hidden ones included"},bridge:{flag:"--bridge",needsName:!0,byId:!0,label:"Mapping the circle behind"},resume:{flag:"--bridge-url",needsId:!0,label:"Carrying on with",searches:!0},"resume-all":{flag:"--auto-bridge --only-unfinished",label:"Carrying on with every paused list",searches:!0},rescrape:{flag:"--rescrape",needsName:!0,label:"Re-mapping the circle behind"},company:{flag:"--company",needsName:!0,label:"Scanning"},photos:{flag:"--save-photos",label:"Saving profile photos to this computer"}};async function ep(e){let t,s={};try{s=await e.json()}catch{}let l=String(s.action||"");if("cancel"===l)return!function(){if(V.abort){V.stopping=!0,J("Stopping…"),V.abort.abort(new G("Stopped."));return}let e=V.child;if(!e)return;V.stopping=!0,J("Stopping…");let t=e.pid;try{process.kill(-t,"SIGTERM")}catch{try{e.kill("SIGTERM")}catch{}}setTimeout(()=>{if(V.child&&V.child.pid===t){J("Still running — forcing it.");try{process.kill(-t,"SIGKILL")}catch{try{e.kill("SIGKILL")}catch{}}}},2e4)}(),Response.json({ok:!0,cancelled:!0});if("set-limits"===l){let e=(0,f.writeLimits)((0,o.dataDir)(),{daily:s.daily,monthly:s.monthly,profiles:s.profiles});return Response.json({ok:!0,limits:e})}if("lift-cooldown"===l)return(0,f.liftCooldown)((0,o.dataDir)()),Response.json({ok:!0});if(!Object.hasOwn(ec,l))return Response.json({error:`Unknown action '${l}'`},{status:400});let u=ec[l],d=Number.isInteger(s.maxBridges)&&s.maxBridges>0?Math.min(s.maxBridges,500):0,c=Array.isArray(s.tiers)?s.tiers.map(e=>String(e).toUpperCase()).filter(e=>"SABCD".includes(e)&&1===e.length):[],p="score"===s.order?"score":"newest",h=[10,25,50,100].includes(s.maxPages)?s.maxPages:100,g=l.startsWith("auto-bridge")||["bridge","rescrape","resume","resume-all"].includes(l),m=!0===s.deeper&&(l.startsWith("auto-bridge")||"bridge"===l),b=u.needsId||u.byId&&!!s.id,w=null;if(u.needsName&&!b){let e;if(!(w=!(e=String(s.name??"").trim())||e.length>120||/[\u0000-\u001f]/.test(e)?null:e))return Response.json({error:"A name is required for this action."},{status:400})}let _=null,S=null;if(b){try{var R;let e,t=(0,a.resolveProfile)({create:!1});S=t&&(0,y.getDb)().prepare("SELECT name, profile_url FROM linkedin_connections WHERE id = ? AND user_id = ? AND degree = 1").get(String(s.id??""),t.id),_=S?.profile_url&&(R=S.profile_url,(e=String(R??"").trim()).length>400||/[\u0000-\u001f\s]/.test(e)?null:/^https?:\/\/([a-z]{2,3}\.|www\.)?linkedin\.com\/in\/[^/?#]+\/?$/i.test(e)?e:null)}catch{_=null}if(!_)return Response.json({error:"That connection could not be found."},{status:400})}let E="string"==typeof s.id&&/^[\w-]{1,64}$/.test(s.id)?s.id:null,T=w||_?{id:E,name:w||S?.name||null}:null,k=u.searches||l.startsWith("auto-bridge")||["bridge","rescrape","company","full","refresh"].includes(l);if(!["install","setup","login"].includes(l)&&(0,v.pendingImport)((0,o.dataDir)()))return Response.json({error:"An import is waiting to finish. Restart Six Degrees first (Settings → Your data), then scan."},{status:409});let N=(0,f.linkedinState)((0,o.dataDir)()).cooldown;if(k&&N)return Response.json({error:`Scanning is paused until ${new Date(N.until).toLocaleString()} — ${N.reason}.`,cooldown:N},{status:409});if(V.running)return Response.json({error:"Something is already running.",action:V.action},{status:409});let P=(0,o.projectRoot)();if(!P)return Response.json({error:"Could not find scripts/scrape.py next to the app."},{status:500});er();let C=(await es()).python;if(V.running)return Response.json({error:"Something is already running.",action:V.action},{status:409});let A=null;if("install"===l||"setup"===l){let e=function(e,t,{root:n,data:o,say:a}){if(t.run)return{status:409,error:"bundled"===t.run.source?"The scanner is already set up: its Python comes with the app.":"The scanner is already set up."};let s=t.base;if("install"===e&&!s)return t.download?{status:409,error:"This computer has no Python the scanner can use. Use Set up the scanner instead."}:{status:500,error:"No Python 3.10 to 3.14 is installed, or none is on this app’s PATH."};if("setup"===e&&s?.source==="system")return{status:409,error:`This computer already has Python ${s.version}, so nothing needs downloading. Use Install instead.`};if("setup"===e&&!s&&!t.download)return{status:409,error:"There is no Python download for this computer. Install Python 3.10 to 3.14, then reload."};let l=i.default.join(n,"scripts","requirements.txt"),u=e=>(function({base:e,dataDir:t,requirements:n}){let r="downloaded"===e.source,i=U(t);return[{cmd:e.path,args:[...r?j:[],"-m","venv","--clear",L(t)],...r?{env:I}:{},note:"Creating the scanner’s own Python environment"},{cmd:i,args:["-m","pip","install","--disable-pip-version-check","--no-input","-r",n],env:H,note:"Installing Playwright, requests and Pillow"},{cmd:i,args:["-c",function(e=D){return`import sys
17
17
  try:
18
18
  ${e}
19
19
  except Exception as e:
20
20
  first = (str(e).splitlines() or [""])[0][:200]
21
21
  sys.stderr.write("pip said it installed them, but the scanner's environment can't load them (%s: %s). A pip setting may send packages somewhere else: pip config list shows yours.\\n" % (type(e).__name__, first))
22
22
  sys.exit(1)
23
- print("The scanner's packages load in its environment.")`}()],note:"Checking that they load"}]})({base:e,dataDir:o,requirements:l});if(s)return{plan:u(s),cleanup:null};let d=t.download;(0,r.mkdirSync)(o,{recursive:!0}),function(e,{now:t=Date.now(),maxAgeMs:n=36e5}={}){let o=[];try{o=r.default.readdirSync(e)}catch{return}for(let a of o){if(!a.startsWith(x.SETUP_WORK_PREFIX))continue;let o=i.default.join(e,a);try{let e=r.default.lstatSync(o);e.isDirectory()&&t-e.mtimeMs>n&&r.default.rmSync(o,{recursive:!0,force:!0})}catch{}}}(o);let c=(0,r.mkdtempSync)(i.default.join(o,x.SETUP_WORK_PREFIX)),p=i.default.join(c,d.file),h=-1;return{plan:[{note:`Downloading Python ${d.version} from GitHub (${K(d.size)} MB)`,run:async({signal:e})=>{await X(d.url,p,{sha256:d.sha256,size:d.size,signal:e,onProgress:(e,t)=>{let n=Math.floor(e/t*10);n>h&&(h=n,a(`Downloading Python ${d.version}: ${K(e)} of ${K(t)} MB`))}}),a("Its checksum matches the one Six Degrees has for it.")}},{cmd:"tar",args:["-xzf",p,"-C",c],note:"Unpacking it"},{run:()=>Y(c,o,c)},...u({path:W(o),source:"downloaded"})],cleanup:()=>(0,r.rmSync)(c,{recursive:!0,force:!0})}}(l,N,{root:C,data:(0,o.dataDir)(),say:J});if(e.error)return Response.json({error:e.error},{status:e.status});({plan:t,cleanup:A}=e)}else{if(!N.run)return Response.json({error:"The scanner’s packages are not installed yet. Do step 1 first."},{status:409});t=[function(e,t,n=[]){let r=e?.source==="bundled"||e?.source==="custom";return{cmd:e.path,args:[...r?j:[],t,...n],env:r?I:$}}(N.run,i.default.join(C,"scripts","scrape.py"),[...w?[`${u.flag}=${w}`]:_?[`--bridge-url=${_}`]:u.flag.split(" "),..._&&"bridge"===l&&!m?["--from-start"]:[],...d&&(l.startsWith("auto-bridge")||"resume-all"===l)?[`--max-bridges=${d}`]:[],...c.length&&l.startsWith("auto-bridge")?[`--tiers=${c.join(",")}`]:[],...l.startsWith("auto-bridge")?[`--order=${p}`]:[],...g?[`--max-pages=${l.startsWith("resume")?100:h}`]:[],...m?["--deeper"]:[]])]}let O=e.headers.get("host")||"127.0.0.1:3000",M=O.includes(":")?O.split(":").pop():"80";V.running=!0,V.stopping=!1,V.action=l,V.target=T,V.exitCode=null,V.startedAt=Date.now(),V.log=[u.label+(T?.name?` ${T.name}…`:"…")],V.stderrTail=[],V.failure=null,er();let F="";try{F=(0,a.resolveProfile)().id}catch{}let z={...process.env,SIX_DEGREES_USER_ID:F,APP_URL:`http://127.0.0.1:${M}`,PYTHONUNBUFFERED:"1",SIX_DEGREES_ROOT:C,SIX_DEGREES_FROM_APP:"1"};function q(e){if(0!==e&&!V.stopping&&V.stderrTail.length){let e=new Set(V.log),t=V.stderrTail.filter(t=>!e.has(t));t.length&&J(t.join("\n"));let n=V.stderrTail.filter(e=>!/Warning|warnings\.warn\(/.test(e)).slice(-6);V.failure=n.length?n:null}if(J(V.stopping?"Stopped.":0===e?"Finished.":`Stopped (exit ${e}).`),V.stopping=!1,V.running=!1,V.child=null,V.abort=null,V.exitCode=e,V.recent=[{action:V.action,target:V.target,startedAt:V.startedAt,exitCode:e,failure:V.failure},...V.recent].slice(0,5),A)try{A()}catch{}er()}return!function e(r){let i;if(r>=t.length)return q(0);let o=t[r];if(o.note&&J(o.note+"…"),o.run){let t=new AbortController;V.abort=t,Promise.resolve().then(()=>o.run({signal:t.signal})).then(()=>{if(V.abort=null,V.stopping)return q(0);e(r+1)},e=>{if(V.abort=null,V.stopping)return q(0);V.stderrTail.push(e instanceof G?e.message:`Could not finish: ${e.message}`),q(1)});return}try{i=(0,n.spawn)(o.cmd,o.args,{cwd:C,env:o.env?o.env(z):z,detached:!0})}catch(e){return J(`Could not start: ${e.message}`),q(-1)}V.child=i,i.stdout.on("data",e=>J(e.toString())),i.stderr.on("data",e=>{let t=e.toString();for(let e of t.split("\n")){let t=e.replace(/\s+$/,"");t&&V.stderrTail.push(t)}V.stderrTail.length>20&&V.stderrTail.splice(0,V.stderrTail.length-20),/error|Error|Traceback|No module|failed|externally-managed/.test(t)&&J(t)}),i.on("error",e=>{J(`Could not start: ${e.message}`),q(-1)}),i.on("close",t=>V.stopping?q(t??0):0===t||o.tolerant?void e(r+1):q(t))}(0),Response.json({ok:!0,action:l,startedAt:V.startedAt})}e.s(["GET",0,ed,"POST",0,ep],81638)},14974,e=>{"use strict";var t=e.i(47909),n=e.i(74017),r=e.i(96250),i=e.i(59756),o=e.i(61916),a=e.i(74677),s=e.i(69741),l=e.i(16795),u=e.i(87718),d=e.i(95169),c=e.i(47587),p=e.i(66012),h=e.i(70101),f=e.i(26937),g=e.i(10372),m=e.i(93695);e.i(52474);var y=e.i(220);let b=new t.AppRouteRouteModule({definition:{kind:n.RouteKind.APP_ROUTE,page:"/api/scraper/route",pathname:"/api/scraper",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/app/api/scraper/route.js",nextConfigOutput:"standalone",userland:()=>e.r(81638),...{}}),{workAsyncStorage:w,workUnitAsyncStorage:v,serverHooks:_}=b;async function S(e,t,r){r.requestMeta&&(0,i.setRequestMeta)(e,r.requestMeta),b.isDev&&(0,i.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let w="/api/scraper/route";w=w.replace(/\/index$/,"")||"/";let v=await b.prepare(e,t,{srcPage:w,multiZoneDraftMode:!1});if(!v)return t.statusCode=400,t.end("Bad Request"),null==r.waitUntil||r.waitUntil.call(r,Promise.resolve()),null;let{buildId:_,deploymentId:S,params:R,nextConfig:E,parsedUrl:T,isDraftMode:x,prerenderManifest:k,routerServerContext:P,isOnDemandRevalidate:C,revalidateOnlyGenerated:N,resolvedPathname:D,clientReferenceManifest:A,serverActionsManifest:O}=v,j=(0,s.normalizeAppPath)(w),I=!!(k.dynamicRoutes[j]||k.routes[D]),$=async()=>((null==P?void 0:P.render404)?await P.render404(e,t,T,!1):t.end("This page could not be found"),null);if(I&&!x){let e=!!k.routes[D],t=k.dynamicRoutes[j];if(t&&!1===t.fallback&&!e){if(E.adapterPath)return await $();throw new m.NoFallbackError}}let M=null;!I||b.isDev||x||(M="/index"===(M=D)?"/":M);let H=!0===b.isDev||!I,L=I&&!H;O&&A&&(0,a.setManifestsSingleton)({page:w,clientReferenceManifest:A,serverActionsManifest:O});let U=e.method||"GET",F=(0,o.getTracer)(),W=F.getActiveScopeSpan(),z=!!(null==P?void 0:P.isWrappedByNextServer),q=!!(0,i.getRequestMeta)(e,"minimalMode"),G=(0,i.getRequestMeta)(e,"incrementalCache")||await b.getIncrementalCache(e,E,k,q);null==G||G.resetRequestCache(),globalThis.__incrementalCache=G;let B={params:R,previewProps:k.preview,renderOpts:{experimental:{authInterrupts:!!E.experimental.authInterrupts,useCacheTimeout:E.experimental.useCacheTimeout},cacheComponents:!!E.cacheComponents,validationLevel:E.experimental.instantInsights.validationLevel,supportsDynamicResponse:H,incrementalCache:G,hmrRefreshHash:(0,i.getRequestMeta)(e,"hmrRefreshHash"),cacheLifeProfiles:E.cacheLife,staticPageGenerationTimeout:E.staticPageGenerationTimeout,waitUntil:r.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,n,r,i)=>b.onRequestError(e,t,r,i,P)},sharedContext:{buildId:_,deploymentId:S}},K=new l.NodeNextRequest(e),X=new l.NodeNextResponse(t),Y=u.NextRequestAdapter.fromNodeNextRequest(K,(0,u.signalFromNodeResponse)(t)),V=async({previousCacheEntry:n})=>{try{if(!q&&C&&N&&!n)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let i=await b.handle(Y,B);e.fetchMetrics=B.renderOpts.fetchMetrics;let o=B.renderOpts.pendingWaitUntil;o&&r.waitUntil&&(r.waitUntil(o),o=void 0);let a=B.renderOpts.collectedTags;if(!I)return await (0,p.sendResponse)(K,X,i,o),null;{let e=await i.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(i.headers);a&&(t[g.NEXT_CACHE_TAGS_HEADER]=a),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let n=void 0!==B.renderOpts.collectedRevalidate&&!(B.renderOpts.collectedRevalidate>=g.INFINITE_CACHE)&&B.renderOpts.collectedRevalidate,r=void 0===B.renderOpts.collectedExpire||B.renderOpts.collectedExpire>=g.INFINITE_CACHE?!1!==n&&n>0?E.expireTime:void 0:B.renderOpts.collectedExpire;return{value:{kind:y.CachedRouteKind.APP_ROUTE,status:i.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:n,expire:r}}}}catch(t){throw(null==n?void 0:n.isStale)&&await b.onRequestError(e,t,{routerKind:"App Router",routePath:w,routeType:"route",revalidateReason:(0,c.getRevalidateReason)({isStaticGeneration:L,isOnDemandRevalidate:C})},!1,P),t}},J=async(i,a)=>{try{var s,l;let i=await b.handleResponse({req:e,nextConfig:E,cacheKey:M,routeKind:n.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:k,isRoutePPREnabled:!1,isOnDemandRevalidate:C,revalidateOnlyGenerated:N,responseGenerator:V,waitUntil:r.waitUntil,isMinimalMode:q});if(!I)return;if((null==i||null==(s=i.value)?void 0:s.kind)!==y.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==i||null==(l=i.value)?void 0:l.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});q||t.setHeader("x-nextjs-cache",C?"REVALIDATED":i.isMiss?"MISS":i.isStale?"STALE":"HIT"),x&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let o=(0,h.fromNodeOutgoingHttpHeaders)(i.value.headers);q&&I||o.delete(g.NEXT_CACHE_TAGS_HEADER),!i.cacheControl||t.getHeader("Cache-Control")||o.get("Cache-Control")||o.set("Cache-Control",(0,f.getCacheControlHeader)(i.cacheControl)),await (0,p.sendResponse)(K,X,new Response(i.value.body,{headers:o,status:i.value.status||200}));return}catch(t){if(t instanceof m.NoFallbackError||await b.onRequestError(e,t,{routerKind:"App Router",routePath:j,routeType:"route",revalidateReason:(0,c.getRevalidateReason)({isStaticGeneration:L,isOnDemandRevalidate:C})},!1,P),I)throw t;await (0,p.sendResponse)(K,X,new Response(null,{status:500}));return}finally{(()=>{if(!i)return;let e=t.statusCode;i.setAttributes({"http.status_code":e,"next.rsc":!1}),e&&e>=500&&(i.setStatus({code:o.SpanStatusCode.ERROR}),i.setAttribute("error.type",e.toString()));let n=F.getRootSpanAttributes();if(!n)return;if(n.get("next.span_type")!==d.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${n.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let r=n.get("next.route")||j,s=`${U} ${r}`;i.setAttributes({"next.route":r,"http.route":r,"next.span_name":s}),i.updateName(s),a&&a!==i&&(a.setAttribute("http.route",r),a.updateName(s))})()}};if(z&&W)await J(W,void 0);else{let t=F.getActiveScopeSpan();await F.withPropagatedContext(e.headers,()=>F.trace(d.BaseServerSpan.handleRequest,{spanName:`${U} ${w}`,kind:o.SpanKind.SERVER,attributes:{"http.method":U,"http.target":e.url}},e=>J(e,t)),void 0,!z)}}e.s(["handler",0,S,"patchFetch",0,function(){return(0,r.patchFetch)({workAsyncStorage:w,workUnitAsyncStorage:v})},"routeModule",0,b,"serverHooks",0,_,"workAsyncStorage",0,w,"workUnitAsyncStorage",0,v])}];
23
+ print("The scanner's packages load in its environment.")`}()],note:"Checking that they load"}]})({base:e,dataDir:o,requirements:l});if(s)return{plan:u(s),cleanup:null};let d=t.download;(0,r.mkdirSync)(o,{recursive:!0}),function(e,{now:t=Date.now(),maxAgeMs:n=36e5}={}){let o=[];try{o=r.default.readdirSync(e)}catch{return}for(let a of o){if(!a.startsWith(x.SETUP_WORK_PREFIX))continue;let o=i.default.join(e,a);try{let e=r.default.lstatSync(o);e.isDirectory()&&t-e.mtimeMs>n&&r.default.rmSync(o,{recursive:!0,force:!0})}catch{}}}(o);let c=(0,r.mkdtempSync)(i.default.join(o,x.SETUP_WORK_PREFIX)),p=i.default.join(c,d.file),h=-1;return{plan:[{note:`Downloading Python ${d.version} from GitHub (${K(d.size)} MB)`,run:async({signal:e})=>{await X(d.url,p,{sha256:d.sha256,size:d.size,signal:e,onProgress:(e,t)=>{let n=Math.floor(e/t*10);n>h&&(h=n,a(`Downloading Python ${d.version}: ${K(e)} of ${K(t)} MB`))}}),a("Its checksum matches the one Six Degrees has for it.")}},{cmd:"tar",args:["-xzf",p,"-C",c],note:"Unpacking it"},{run:()=>Y(c,o,c)},...u({path:W(o),source:"downloaded"})],cleanup:()=>(0,r.rmSync)(c,{recursive:!0,force:!0})}}(l,C,{root:P,data:(0,o.dataDir)(),say:J});if(e.error)return Response.json({error:e.error},{status:e.status});({plan:t,cleanup:A}=e)}else{if(!C.run)return Response.json({error:"The scanner’s packages are not installed yet. Do step 1 first."},{status:409});t=[function(e,t,n=[]){let r=e?.source==="bundled"||e?.source==="custom";return{cmd:e.path,args:[...r?j:[],t,...n],env:r?I:$}}(C.run,i.default.join(P,"scripts","scrape.py"),[...w?[`${u.flag}=${w}`]:_?[`--bridge-url=${_}`]:u.flag.split(" "),..._&&"bridge"===l&&!m?["--from-start"]:[],...d&&(l.startsWith("auto-bridge")||"resume-all"===l)?[`--max-bridges=${d}`]:[],...c.length&&l.startsWith("auto-bridge")?[`--tiers=${c.join(",")}`]:[],...l.startsWith("auto-bridge")?[`--order=${p}`]:[],...g?[`--max-pages=${l.startsWith("resume")?100:h}`]:[],...m?["--deeper"]:[]])]}let O=e.headers.get("host")||"127.0.0.1:3000",M=O.includes(":")?O.split(":").pop():"80";V.running=!0,V.stopping=!1,V.action=l,V.target=T,V.exitCode=null,V.startedAt=Date.now(),V.log=[u.label+(T?.name?` ${T.name}…`:"…")],V.stderrTail=[],V.failure=null,er();let F="";try{F=(0,a.resolveProfile)().id}catch{}let z={...process.env,SIX_DEGREES_USER_ID:F,APP_URL:`http://127.0.0.1:${M}`,PYTHONUNBUFFERED:"1",SIX_DEGREES_ROOT:P,SIX_DEGREES_FROM_APP:"1"};function q(e){if(0!==e&&!V.stopping&&V.stderrTail.length){let e=new Set(V.log),t=V.stderrTail.filter(t=>!e.has(t));t.length&&J(t.join("\n"));let n=V.stderrTail.filter(e=>!/Warning|warnings\.warn\(/.test(e)).slice(-6);V.failure=n.length?n:null}if(J(V.stopping?"Stopped.":0===e?"Finished.":`Stopped (exit ${e}).`),V.stopping=!1,V.running=!1,V.child=null,V.abort=null,V.exitCode=e,V.recent=[{action:V.action,target:V.target,startedAt:V.startedAt,exitCode:e,failure:V.failure},...V.recent].slice(0,5),A)try{A()}catch{}er()}return!function e(r){let i;if(r>=t.length)return q(0);let o=t[r];if(o.note&&J(o.note+"…"),o.run){let t=new AbortController;V.abort=t,Promise.resolve().then(()=>o.run({signal:t.signal})).then(()=>{if(V.abort=null,V.stopping)return q(0);e(r+1)},e=>{if(V.abort=null,V.stopping)return q(0);V.stderrTail.push(e instanceof G?e.message:`Could not finish: ${e.message}`),q(1)});return}try{i=(0,n.spawn)(o.cmd,o.args,{cwd:P,env:o.env?o.env(z):z,detached:!0})}catch(e){return J(`Could not start: ${e.message}`),q(-1)}V.child=i,i.stdout.on("data",e=>J(e.toString())),i.stderr.on("data",e=>{let t=e.toString();for(let e of t.split("\n")){let t=e.replace(/\s+$/,"");t&&V.stderrTail.push(t)}V.stderrTail.length>20&&V.stderrTail.splice(0,V.stderrTail.length-20),/error|Error|Traceback|No module|failed|externally-managed/.test(t)&&J(t)}),i.on("error",e=>{J(`Could not start: ${e.message}`),q(-1)}),i.on("close",t=>V.stopping?q(t??0):0===t||o.tolerant?void e(r+1):q(t))}(0),Response.json({ok:!0,action:l,startedAt:V.startedAt})}e.s(["GET",0,ed,"POST",0,ep],81638)},14974,e=>{"use strict";var t=e.i(47909),n=e.i(74017),r=e.i(96250),i=e.i(59756),o=e.i(61916),a=e.i(74677),s=e.i(69741),l=e.i(16795),u=e.i(87718),d=e.i(95169),c=e.i(47587),p=e.i(66012),h=e.i(70101),f=e.i(26937),g=e.i(10372),m=e.i(93695);e.i(52474);var b=e.i(220);let y=new t.AppRouteRouteModule({definition:{kind:n.RouteKind.APP_ROUTE,page:"/api/scraper/route",pathname:"/api/scraper",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/app/api/scraper/route.js",nextConfigOutput:"standalone",userland:()=>e.r(81638),...{}}),{workAsyncStorage:w,workUnitAsyncStorage:v,serverHooks:_}=y;async function S(e,t,r){r.requestMeta&&(0,i.setRequestMeta)(e,r.requestMeta),y.isDev&&(0,i.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let w="/api/scraper/route";w=w.replace(/\/index$/,"")||"/";let v=await y.prepare(e,t,{srcPage:w,multiZoneDraftMode:!1});if(!v)return t.statusCode=400,t.end("Bad Request"),null==r.waitUntil||r.waitUntil.call(r,Promise.resolve()),null;let{buildId:_,deploymentId:S,params:R,nextConfig:E,parsedUrl:T,isDraftMode:x,prerenderManifest:k,routerServerContext:N,isOnDemandRevalidate:P,revalidateOnlyGenerated:C,resolvedPathname:D,clientReferenceManifest:A,serverActionsManifest:O}=v,j=(0,s.normalizeAppPath)(w),I=!!(k.dynamicRoutes[j]||k.routes[D]),$=async()=>((null==N?void 0:N.render404)?await N.render404(e,t,T,!1):t.end("This page could not be found"),null);if(I&&!x){let e=!!k.routes[D],t=k.dynamicRoutes[j];if(t&&!1===t.fallback&&!e){if(E.adapterPath)return await $();throw new m.NoFallbackError}}let M=null;!I||y.isDev||x||(M="/index"===(M=D)?"/":M);let H=!0===y.isDev||!I,L=I&&!H;O&&A&&(0,a.setManifestsSingleton)({page:w,clientReferenceManifest:A,serverActionsManifest:O});let U=e.method||"GET",F=(0,o.getTracer)(),W=F.getActiveScopeSpan(),z=!!(null==N?void 0:N.isWrappedByNextServer),q=!!(0,i.getRequestMeta)(e,"minimalMode"),G=(0,i.getRequestMeta)(e,"incrementalCache")||await y.getIncrementalCache(e,E,k,q);null==G||G.resetRequestCache(),globalThis.__incrementalCache=G;let B={params:R,previewProps:k.preview,renderOpts:{experimental:{authInterrupts:!!E.experimental.authInterrupts,useCacheTimeout:E.experimental.useCacheTimeout},cacheComponents:!!E.cacheComponents,validationLevel:E.experimental.instantInsights.validationLevel,supportsDynamicResponse:H,incrementalCache:G,hmrRefreshHash:(0,i.getRequestMeta)(e,"hmrRefreshHash"),cacheLifeProfiles:E.cacheLife,staticPageGenerationTimeout:E.staticPageGenerationTimeout,waitUntil:r.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,n,r,i)=>y.onRequestError(e,t,r,i,N)},sharedContext:{buildId:_,deploymentId:S}},K=new l.NodeNextRequest(e),X=new l.NodeNextResponse(t),Y=u.NextRequestAdapter.fromNodeNextRequest(K,(0,u.signalFromNodeResponse)(t)),V=async({previousCacheEntry:n})=>{try{if(!q&&P&&C&&!n)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let i=await y.handle(Y,B);e.fetchMetrics=B.renderOpts.fetchMetrics;let o=B.renderOpts.pendingWaitUntil;o&&r.waitUntil&&(r.waitUntil(o),o=void 0);let a=B.renderOpts.collectedTags;if(!I)return await (0,p.sendResponse)(K,X,i,o),null;{let e=await i.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(i.headers);a&&(t[g.NEXT_CACHE_TAGS_HEADER]=a),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let n=void 0!==B.renderOpts.collectedRevalidate&&!(B.renderOpts.collectedRevalidate>=g.INFINITE_CACHE)&&B.renderOpts.collectedRevalidate,r=void 0===B.renderOpts.collectedExpire||B.renderOpts.collectedExpire>=g.INFINITE_CACHE?!1!==n&&n>0?E.expireTime:void 0:B.renderOpts.collectedExpire;return{value:{kind:b.CachedRouteKind.APP_ROUTE,status:i.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:n,expire:r}}}}catch(t){throw(null==n?void 0:n.isStale)&&await y.onRequestError(e,t,{routerKind:"App Router",routePath:w,routeType:"route",revalidateReason:(0,c.getRevalidateReason)({isStaticGeneration:L,isOnDemandRevalidate:P})},!1,N),t}},J=async(i,a)=>{try{var s,l;let i=await y.handleResponse({req:e,nextConfig:E,cacheKey:M,routeKind:n.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:k,isRoutePPREnabled:!1,isOnDemandRevalidate:P,revalidateOnlyGenerated:C,responseGenerator:V,waitUntil:r.waitUntil,isMinimalMode:q});if(!I)return;if((null==i||null==(s=i.value)?void 0:s.kind)!==b.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==i||null==(l=i.value)?void 0:l.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});q||t.setHeader("x-nextjs-cache",P?"REVALIDATED":i.isMiss?"MISS":i.isStale?"STALE":"HIT"),x&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let o=(0,h.fromNodeOutgoingHttpHeaders)(i.value.headers);q&&I||o.delete(g.NEXT_CACHE_TAGS_HEADER),!i.cacheControl||t.getHeader("Cache-Control")||o.get("Cache-Control")||o.set("Cache-Control",(0,f.getCacheControlHeader)(i.cacheControl)),await (0,p.sendResponse)(K,X,new Response(i.value.body,{headers:o,status:i.value.status||200}));return}catch(t){if(t instanceof m.NoFallbackError||await y.onRequestError(e,t,{routerKind:"App Router",routePath:j,routeType:"route",revalidateReason:(0,c.getRevalidateReason)({isStaticGeneration:L,isOnDemandRevalidate:P})},!1,N),I)throw t;await (0,p.sendResponse)(K,X,new Response(null,{status:500}));return}finally{(()=>{if(!i)return;let e=t.statusCode;i.setAttributes({"http.status_code":e,"next.rsc":!1}),e&&e>=500&&(i.setStatus({code:o.SpanStatusCode.ERROR}),i.setAttribute("error.type",e.toString()));let n=F.getRootSpanAttributes();if(!n)return;if(n.get("next.span_type")!==d.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${n.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let r=n.get("next.route")||j,s=`${U} ${r}`;i.setAttributes({"next.route":r,"http.route":r,"next.span_name":s}),i.updateName(s),a&&a!==i&&(a.setAttribute("http.route",r),a.updateName(s))})()}};if(z&&W)await J(W,void 0);else{let t=F.getActiveScopeSpan();await F.withPropagatedContext(e.headers,()=>F.trace(d.BaseServerSpan.handleRequest,{spanName:`${U} ${w}`,kind:o.SpanKind.SERVER,attributes:{"http.method":U,"http.target":e.url}},e=>J(e,t)),void 0,!z)}}e.s(["handler",0,S,"patchFetch",0,function(){return(0,r.patchFetch)({workAsyncStorage:w,workUnitAsyncStorage:v})},"routeModule",0,y,"serverHooks",0,_,"workAsyncStorage",0,w,"workUnitAsyncStorage",0,v])}];
24
24
 
25
25
  //# sourceMappingURL=_1_fynia._.js.map
@@ -1,4 +1,4 @@
1
- module.exports=[24214,(e,t,n)=>{t.exports={name:"six-degrees",version:"0.4.0",description:"Map your professional network as a galaxy — leverage tiers, bridges into new circles, and the shortest path to anyone. Runs locally on your own data.",license:"MIT",author:"Blake Burford",repository:{type:"git",url:"git+https://github.com/blakeb056/six-degrees.git"},bugs:{url:"https://github.com/blakeb056/six-degrees/issues"},homepage:"https://sixdegreesapp.com/",keywords:["linkedin","network","graph","visualization","d3","local-first","networking","career"],engines:{node:">=22.13"},os:["darwin","linux"],private:!1,bin:{"six-degrees":"bin/six-degrees.mjs"},files:["bin/",".next/standalone/",".next/static/","public/","db/","lib/","scripts/scrape.py","scripts/image_store.py","scripts/requirements.txt","README.md","LICENSE","CHANGELOG.md","SECURITY.md","scripts/check-node.mjs","scripts/audit-avatars.mjs","scripts/check-stale-server.mjs","scripts/update.mjs"],scripts:{dev:"NEXT_TELEMETRY_DISABLED=1 SIX_DEGREES_BIND=127.0.0.1 next dev -H 127.0.0.1",predev:"node scripts/check-node.mjs && node scripts/check-stale-server.mjs",fresh:"node scripts/check-node.mjs && node scripts/sandbox.mjs",build:"NEXT_TELEMETRY_DISABLED=1 next build && node scripts/prepare-standalone.mjs",prebuild:"node scripts/check-node.mjs",start:"NEXT_TELEMETRY_DISABLED=1 SIX_DEGREES_BIND=127.0.0.1 next start -H 127.0.0.1",lint:"eslint",test:"node --test tests/*.test.mjs","gen:demo":"node scripts/gen-synthetic.mjs",prepack:"npm run build","start:packaged":"node bin/six-degrees.mjs",scrape:"python3 scripts/scrape.py","scrape:login":"python3 scripts/scrape.py --login","scrape:server":"python3 scripts/scrape.py --server","setup:python":"python3 -m pip install -r scripts/requirements.txt","scrape:full":"python3 scripts/scrape.py --full","scrape:refresh":"python3 scripts/scrape.py --refresh","audit:avatars":"node scripts/audit-avatars.mjs","build:app":"node scripts/build-app.mjs","build:desktop":"node scripts/build-app.mjs --shell=electron",desktop:"electron desktop",update:"node scripts/update.mjs"},devDependencies:{"@electron/packager":"20.3.0",d3:"^7.9.0",electron:"44.4.5",eslint:"^9","eslint-config-next":"16.3.6",next:"16.3.6",react:"19.2.4","react-dom":"19.2.4"}}},34091,e=>{"use strict";var t=e.i(74533),n=e.i(2157),r=e.i(10960),a=e.i(60526),s=e.i(50227),i=e.i(12506),o=e.i(98199),l=e.i(66680),c=e.i(12714),u=e.i(1348);let d="/usr/bin/hdiutil",p="six-degrees-update",h=new Set(["checking","downloading","verifying","preparing","restarting"]),f=new Set(["checking","downloading","verifying","preparing"]);class m extends Error{constructor(e,t=null){super(e),this.code=t}}let g="cancelled";function w({home:e=a.default.homedir(),tmp:t=a.default.tmpdir()}={}){let n=s.default.join(e,"Library","Caches","Six Degrees");return{cacheDir:n,statusFile:s.default.join(n,"last-update.json"),confirmFile:s.default.join(n,"update-confirmed.json"),logFile:s.default.join(t,"six-degrees-update.log")}}function y(e){try{let t=JSON.parse(n.default.readFileSync(e,"utf8"));return t&&"object"==typeof t&&!Array.isArray(t)?t:null}catch{return null}}function b(e,t){n.default.mkdirSync(s.default.dirname(e),{recursive:!0});let r=`${e}.${process.pid}.tmp`;n.default.writeFileSync(r,`${JSON.stringify(t)}
1
+ module.exports=[24214,(e,t,n)=>{t.exports={name:"six-degrees",version:"0.4.2",description:"Map your professional network as a galaxy — leverage tiers, bridges into new circles, and the shortest path to anyone. Runs locally on your own data.",license:"MIT",author:"Blake Burford",repository:{type:"git",url:"git+https://github.com/blakeb056/six-degrees.git"},bugs:{url:"https://github.com/blakeb056/six-degrees/issues"},homepage:"https://sixdegreesapp.com/",keywords:["linkedin","network","graph","visualization","d3","local-first","networking","career"],engines:{node:">=22.13"},os:["darwin","linux"],private:!1,bin:{"six-degrees":"bin/six-degrees.mjs"},files:["bin/",".next/standalone/",".next/static/","public/","db/","lib/","scripts/scrape.py","scripts/image_store.py","scripts/requirements.txt","README.md","LICENSE","CHANGELOG.md","SECURITY.md","scripts/check-node.mjs","scripts/audit-avatars.mjs","scripts/check-stale-server.mjs","scripts/update.mjs"],scripts:{dev:"NEXT_TELEMETRY_DISABLED=1 SIX_DEGREES_BIND=127.0.0.1 next dev -H 127.0.0.1",predev:"node scripts/check-node.mjs && node scripts/check-stale-server.mjs",fresh:"node scripts/check-node.mjs && node scripts/sandbox.mjs",build:"NEXT_TELEMETRY_DISABLED=1 next build && node scripts/prepare-standalone.mjs",prebuild:"node scripts/check-node.mjs",start:"NEXT_TELEMETRY_DISABLED=1 SIX_DEGREES_BIND=127.0.0.1 next start -H 127.0.0.1",lint:"eslint",test:"node --test tests/*.test.mjs","gen:demo":"node scripts/gen-synthetic.mjs",prepack:"npm run build","start:packaged":"node bin/six-degrees.mjs",scrape:"python3 scripts/scrape.py","scrape:login":"python3 scripts/scrape.py --login","scrape:server":"python3 scripts/scrape.py --server","setup:python":"python3 -m pip install -r scripts/requirements.txt","scrape:full":"python3 scripts/scrape.py --full","scrape:refresh":"python3 scripts/scrape.py --refresh","audit:avatars":"node scripts/audit-avatars.mjs","build:app":"node scripts/build-app.mjs","build:desktop":"node scripts/build-app.mjs --shell=electron",desktop:"electron desktop",update:"node scripts/update.mjs"},devDependencies:{"@electron/packager":"20.3.0",d3:"^7.9.0",electron:"44.4.5",eslint:"^9","eslint-config-next":"16.3.6",next:"16.3.6",react:"19.2.4","react-dom":"19.2.4"}}},34091,e=>{"use strict";var t=e.i(74533),n=e.i(2157),r=e.i(10960),a=e.i(60526),s=e.i(50227),i=e.i(12506),o=e.i(98199),l=e.i(66680),c=e.i(12714),u=e.i(1348);let d="/usr/bin/hdiutil",p="six-degrees-update",h=new Set(["checking","downloading","verifying","preparing","restarting"]),f=new Set(["checking","downloading","verifying","preparing"]);class m extends Error{constructor(e,t=null){super(e),this.code=t}}let g="cancelled";function w({home:e=a.default.homedir(),tmp:t=a.default.tmpdir()}={}){let n=s.default.join(e,"Library","Caches","Six Degrees");return{cacheDir:n,statusFile:s.default.join(n,"last-update.json"),confirmFile:s.default.join(n,"update-confirmed.json"),logFile:s.default.join(t,"six-degrees-update.log")}}function y(e){try{let t=JSON.parse(n.default.readFileSync(e,"utf8"));return t&&"object"==typeof t&&!Array.isArray(t)?t:null}catch{return null}}function b(e,t){n.default.mkdirSync(s.default.dirname(e),{recursive:!0});let r=`${e}.${process.pid}.tmp`;n.default.writeFileSync(r,`${JSON.stringify(t)}
2
2
  `),n.default.renameSync(r,e)}function v(){let e=(e,n)=>{try{return(0,t.execFileSync)(e,n,{timeout:5e3,stdio:["ignore","pipe","ignore"]}).toString().trim()}catch{return""}};return{chip:(0,o.chipOf)({sysctlArm64:e("/usr/sbin/sysctl",["-n","hw.optional.arm64"]),processArch:process.arch}),macosVersion:e("/usr/bin/sw_vers",["-productVersion"])}}let S=Symbol.for("six-degrees.update-job");function R(){return globalThis[S]||(globalThis[S]={job:null}),globalThis[S]}function j(e){if(!e)return null;let{id:t,phase:n,version:r,notes:a,received:s,total:i,error:o,code:l,startedAt:c,endedAt:u}=e;return{id:t,phase:n,version:r,notes:a,received:s,total:i,error:o,code:l,startedAt:c,endedAt:u}}function x(){return j(R().job)}function T(e,n,{signal:r,timeoutMs:a=12e4}={}){return new Promise((s,i)=>{(0,t.execFile)(e,n,{signal:r,timeout:a,maxBuffer:8388608},(e,t,n)=>{if(e){e.detail=String(n||"").trim().split("\n").filter(Boolean).slice(-2).join(" ")||e.message,i(e);return}s(String(t))})})}let E=e=>Math.max(1,Math.round(e/1048576));function k(e,t,r){let a;try{let t=n.default.statfsSync(e);a=t.bavail*t.bsize}catch{return}if(a<t)throw new m(`There isn't enough free space ${r}: the update needs about ${E(t)} MB, and ${E(a)} MB is free.`)}async function A(e,t,n,r,a){return t.fetchImpl(e,{headers:{Accept:a,"User-Agent":p},signal:AbortSignal.any([n,AbortSignal.timeout(r)]),cache:"no-store",redirect:"follow"})}async function C(e,t,{job:n,c:r,signal:a,expectedSize:s}){let i=new AbortController,o=AbortSignal.any([a,i.signal]),u=null,d=()=>{clearTimeout(u),u=setTimeout(()=>i.abort(new m(`The download stopped for ${Math.round(r.idleMs/1e3)} seconds. Check your connection and try again.`)),r.idleMs)};d();let h=await c.default.open(t,"w"),f=(0,l.createHash)("sha256"),g=0;try{let t=await r.fetchImpl(e,{headers:{Accept:"application/octet-stream","User-Agent":p},signal:o,cache:"no-store",redirect:"follow"});if(!t.ok||!t.body)throw new m(`GitHub answered ${t.status} to the download. Try again later.`);let a=Number(t.headers.get("content-length"))||null;if(s&&a&&a!==s)throw new m("The download is not the size GitHub listed for it, so it was stopped.");let i=a||s||null;n.total=i;let l=i||r.maxBytes;for await(let e of t.body){if(d(),(g+=e.byteLength)>l)throw new m("The download is bigger than GitHub said it would be, so it was stopped.");f.update(e);let t=0;for(;t<e.byteLength;){let{bytesWritten:n}=await h.write(e,t,e.byteLength-t);t+=n}n.received=g}if(i&&g!==i)throw new m("The download ended early. Try again.");return f.digest("hex")}catch(e){if(o.aborted&&o.reason instanceof Error)throw o.reason;throw e}finally{clearTimeout(u),await h.close()}}async function $(e,t,n){let r;await c.default.mkdir(t.point,{recursive:!0});try{r=await T(d,["attach",e,"-nobrowse","-readonly","-noautoopen","-mountpoint",t.point,"-plist"],{signal:n,timeoutMs:18e4})}catch(e){if(n.aborted)throw e;throw new m(`The disk image wouldn't open (${e.detail}).`)}t.device=[...r.matchAll(/<key>dev-entry<\/key>\s*<string>([^<]+)<\/string>/g)].map(e=>e[1]).find(e=>/^\/dev\/disk\d+$/.test(e))||null}function D(e){try{return n.default.statSync(e).dev!==n.default.statSync(s.default.dirname(e)).dev}catch{return!1}}async function M({point:e,device:t},r){let a=[[],[],["-force"],["-force"],["-force"]],s=null;for(let i=0;i<a.length;i++){let o=D(e);if(!o&&(!t||!n.default.existsSync(t)))return;try{await T(d,["detach",o?e:t,...a[i]],{timeoutMs:6e4});return}catch(e){s=e,await r(1e3*(i+1))}}if(D(e)||t&&n.default.existsSync(t))throw s}async function N(e){for(let t of(await c.default.readdir(e,{recursive:!0,withFileTypes:!0}))){if(!t.isSymbolicLink())continue;let n=s.default.join(t.parentPath??t.path,t.name),r=await c.default.readlink(n),a=s.default.resolve(s.default.dirname(n),r);if(s.default.isAbsolute(r)||a!==e&&!a.startsWith(e+s.default.sep))return`${s.default.relative(e,n)} → ${r}`}return null}async function _(e,t=4096){let n=await c.default.open(e,"r");try{let e=Buffer.alloc(t),{bytesRead:r}=await n.read(e,0,t,0);return e.subarray(0,r)}finally{await n.close()}}async function B(e,{plan:t,c:n,signal:r,where:a}){let i=await c.default.lstat(e).catch(()=>null);if(!i||!i.isDirectory())throw new m(`The disk image doesn't contain ${o.APP_BUNDLE_NAME}.`);try{await T("/usr/bin/codesign",["--verify","--deep","--strict",e],{signal:r,timeoutMs:3e5})}catch(e){if(r.aborted)throw e;throw new m(`The new version's signature doesn't check out ${a} (${e.detail}), so it wasn't used.`)}let l=s.default.join(e,"Contents","Info.plist"),u=e=>T("/usr/bin/plutil",["-extract",e,"raw","-o","-",l],{signal:r,timeoutMs:15e3}).then(e=>e.trim()).catch(()=>""),[d,p,h,f]=await Promise.all([u("CFBundleIdentifier"),u("CFBundleShortVersionString"),u("LSMinimumSystemVersion"),u("CFBundleExecutable")]);if(d!==n.bundleId)throw new m(`The download isn't Six Degrees (it calls itself ${d||"nothing"}), so it wasn't used.`);if(p!==t.version)throw new m(`The download says it is version ${p||"(none)"}, not ${t.version}, so it wasn't used.`);if(h&&n.macosVersion&&!(0,o.versionAtLeast)(n.macosVersion,h))throw new m(`Version ${t.version} needs macOS ${h} or later, and this Mac has ${n.macosVersion}.`);for(let t of[f&&!f.includes("/")?s.default.join(e,"Contents","MacOS",f):null,s.default.join(e,"Contents","Resources","node")].filter(Boolean)){let e=(0,o.machoArchs)(await _(t).catch(()=>null));if(e.size){if(!e.has(n.chip))throw new m(`The download is built for ${[...e].map(e=>o.CHIP_LABEL[e]||e).join(" and ")} Macs, not this one, so it wasn't used.`);break}}let g=await N(e);if(g)throw new m(`The new version has a link that points outside it (${g}), so it wasn't used.`)}function F(){return{PATH:"/usr/bin:/bin:/usr/sbin:/sbin",HOME:a.default.homedir(),TMPDIR:a.default.tmpdir(),LANG:"en_US.UTF-8",LC_ALL:"en_US.UTF-8",...process.env.USER?{USER:process.env.USER,LOGNAME:process.env.USER}:{}}}let I=(...e)=>(globalThis.fetch?._nextOriginalFetch||globalThis.fetch)(...e),O={bundleId:o.BUNDLE_ID,apiBase:o.GITHUB.apiBase,downloadBase:o.GITHUB.downloadBase,idleMs:3e4,maxBytes:0x40000000,waitSeconds:30,confirmWaitSeconds:600,settleMs:400,scanRunning:()=>null,othersRunning:()=>[],launch:function({helper:e,args:r,cwd:a,logFile:s}){let i=F(),o=n.default.openSync(s,"w");try{let n=(0,t.spawn)("/bin/bash",[e,...r],{cwd:a,env:i,detached:!0,stdio:["ignore",o,o]});return new Promise((e,t)=>{n.once("error",t),n.once("spawn",()=>{n.unref(),e(n)})})}finally{n.default.closeSync(o)}},exit:function(){setTimeout(()=>process.exit(o.UPDATE_HANDOFF_EXIT_CODE),1200)},sleep:e=>new Promise(t=>setTimeout(t,e))};function P(e){if(e.othersRunning().length)throw new m("Another user of this Mac has Six Degrees open, so it can't be replaced now. Try again once they have quit it.")}async function H(e,r){let a={fetchImpl:I,...O,...r},{signal:i}=e.ctrl,l=null,p=null,h=null,f=!1,w=()=>{if(!f){if(p&&D(p.point))try{(0,t.execFileSync)(d,["detach",p.point,"-force"],{stdio:"ignore",timeout:15e3})}catch{}for(let e of[h,l])if(e)try{n.default.rmSync(e,{recursive:!0,force:!0})}catch{}}};process.once("exit",w);try{let t,r,d,g=await A(`${a.apiBase}/repos/${a.slug}/releases/latest`,a,i,15e3,"application/vnd.github+json");if(404===g.status)throw new m("No release has been published yet.");if(!g.ok)throw new m(`GitHub answered ${g.status}. Try again in a moment.`);let{plan:w,refusal:y}=(0,o.planFromRelease)(await g.json(),{currentVersion:a.currentVersion,chip:a.chip,slug:a.slug,downloadBase:a.downloadBase});if(y)throw new m(y.message);if(a.expectVersion&&w.version!==a.expectVersion)throw new m(`Version ${w.version} has come out since you checked, and you were offered ${a.expectVersion}. Check again, then install.`,"stale-check");r={version:w.version,notes:w.notes,total:w.dmg.size},Object.assign(e,r),P(a),l=await c.default.mkdtemp(s.default.join(a.tmpRoot,"six-degrees-update-")),k(a.tmpRoot,(w.dmg.size||0x20000000)+0x4000000,"for the download"),Object.assign(e,{phase:"downloading"});let v=await A(w.sums.url,a,i,3e4,"text/plain, application/octet-stream");if(!v.ok)throw new m(`GitHub answered ${v.status} for the checksum file. Try again later.`);let S=()=>new m("The checksum file is not what was expected, so nothing was downloaded.");if(Number(v.headers.get("content-length"))>65536)throw S();let R=await v.text();if(R.length>65536)throw S();let j=(0,o.parseSha256Sums)(R).get(w.dmg.name);if(!j)throw new m(`The checksum file doesn't list ${w.dmg.name}, so its download can't be checked.`);let x=s.default.join(l,w.dmg.name),E=await C(w.dmg.url,`${x}.part`,{job:e,c:a,signal:i,expectedSize:w.dmg.size});if(d={phase:"verifying"},Object.assign(e,d),!(0,o.digestsMatch)(j,E))throw new m("The download doesn't match the checksum published with it, so it wasn't used. Try again later.");await c.default.rename(`${x}.part`,x),Object.assign(e,{phase:"preparing"}),p={point:s.default.join(l,"mnt"),device:null},await $(x,p,i);let D=s.default.join(p.point,o.APP_BUNDLE_NAME);await B(D,{plan:w,c:a,signal:i,where:"in the disk image"});let N=Number.parseInt(await T("/usr/bin/du",["-sk",D],{signal:i,timeoutMs:12e4}),10)||0;k(s.default.dirname(a.bundle),1024*N+0x4000000,`in ${s.default.dirname(a.bundle)}`),h=(0,o.stagingPath)(a.bundle),await c.default.rm(h,{recursive:!0,force:!0});try{await T("/usr/bin/ditto",[D,h],{signal:i,timeoutMs:9e5})}catch(e){if(i.aborted)throw e;throw new m(`Could not copy the new version into ${s.default.dirname(a.bundle)} (${e.detail}).`)}if(await B(h,{plan:w,c:a,signal:i,where:"after copying"}),await T("/usr/bin/xattr",["-dr","com.apple.quarantine",h],{signal:i}).catch(()=>{}),await M(p,a.sleep),p=null,await c.default.rm(x,{force:!0}),i.aborted)throw i.reason;let _=await a.scanRunning();if(_)throw new m(`${(0,u.runningNow)(_)}, so the update was not applied. Try again when it has finished.`);if(P(a),i.aborted)throw i.reason;Object.assign(e,{phase:"restarting"});let F=s.default.join(l,"apply-update.sh");await c.default.copyFile(a.helper,F);let I=(0,o.helperArgs)({target:a.bundle,staged:h,keepDir:a.cacheDir,statusFile:a.statusFile,from:a.currentVersion,to:w.version,pids:a.pids||[process.ppid,process.pid],waitSeconds:a.waitSeconds,logFile:a.logFile,work:l,confirmFile:a.confirmFile,confirmWaitSeconds:a.confirmWaitSeconds,relaunch:(0,o.relaunchArgs)({dataDir:a.dataDir})}),O={outcome:"started",from:a.currentVersion,to:w.version,at:new Date().toISOString(),log:a.logFile};try{b(a.statusFile,O)}catch{}try{t=await a.launch({helper:F,args:I,cwd:a.tmpRoot,logFile:a.logFile}),await a.sleep(a.settleMs)}catch(e){throw n.default.rmSync(a.statusFile,{force:!0}),new m(`The update helper wouldn't start (${e.message}).`)}if(t&&(null!==t.exitCode||null!==t.signalCode)){n.default.rmSync(a.statusFile,{force:!0});let e=function(e){try{return n.default.readFileSync(e,"utf8").trim().split("\n").slice(-2).join(" ").replace(/^\S+ \S+ {2}/,"")}catch{return""}}(a.logFile);throw new m(`The update helper stopped before the app closed${e?` (${e})`:""}.`)}f=!0,a.exit()}catch(n){let t=i.aborted&&i.reason instanceof m&&i.reason.message===g;Object.assign(e,{phase:t?"cancelled":"failed",error:t?null:n instanceof m?n.message:n?.name==="TimeoutError"?"GitHub didn't answer in time. Try again in a moment.":n instanceof TypeError&&/fetch failed/i.test(n.message)?`Could not reach GitHub (${n.cause?.code||n.cause?.message||"no connection"}). Check your connection and try again.`:`The update stopped: ${n?.detail||n?.message||n}.`,code:!t&&n instanceof m?n.code:null})}finally{p&&await M(p,a.sleep).catch(()=>{}),!f&&(h&&await c.default.rm(h,{recursive:!0,force:!0}).catch(()=>{}),l&&await c.default.rm(l,{recursive:!0,force:!0}).catch(()=>{})),process.removeListener("exit",w),Object.assign(e,{endedAt:new Date().toISOString()})}}var U=e.i(24214);let L=null;function G(e,n){return new Promise(r=>{let a,s="",i="";try{a=(0,t.spawn)("git",e,{cwd:n})}catch(e){return r({code:-1,out:"",err:e.message})}let o=setTimeout(()=>{try{a.kill()}catch{}},6e4);a.stdout.on("data",e=>{s+=e.toString()}),a.stderr.on("data",e=>{i+=e.toString()}),a.on("error",e=>{clearTimeout(o),r({code:-1,out:s,err:e.message})}),a.on("close",e=>{clearTimeout(o),r({code:e,out:s.trim(),raw:s,err:i.trim()})})})}async function V(e){let[t,n,r,a]=await Promise.all([G(["rev-parse","--short","HEAD"],e),G(["log","-1","--pretty=%s"],e),G(["status","--porcelain"],e),G(["rev-parse","--abbrev-ref","HEAD"],e)]),s=(r.raw||"").split("\n").filter(e=>e.length>3).map(e=>e.slice(3).trim()).filter(Boolean),i=s.length>0&&s.every(e=>"package-lock.json"===e);return{sha:t.out,subject:n.out,branch:a.out,dirty:s,onlyLockfile:i}}function q(){let e=(0,r.dataDir)();return s.default.resolve(e)===s.default.join((0,a.homedir)(),".six-degrees")?null:e}function z(e){let t=(0,i.repoSlug)(U.default.repository),n=(0,i.installKind)(process.env,e||""),r={supported:!1,installed:!0,kind:n,version:U.default.version,slug:t,command:t?(0,i.updateCommand)(n,t,{dataDir:q()}):null};if("mac-app"===n){let e=w();!function({statusFile:e,confirmFile:t},n){let r=y(e);if(r&&"started"===r.outcome&&r.to===n&&y(t)?.version!==n)try{b(t,{version:n,pid:process.pid,at:new Date().toISOString()})}catch{return!1}}(e,U.default.version),r.lastUpdate=(0,o.lastUpdateReport)(y(e.statusFile),{runningVersion:U.default.version}),r.job=x()}let a=(0,o.releaseSource)(process.env);return a.test&&(r.testReleases=a.apiBase),r}async function K(e,t){let n=await fetch(`${t}/repos/${e}/releases/latest`,{headers:{Accept:"application/vnd.github+json","User-Agent":"six-degrees-update-check"},signal:AbortSignal.timeout(1e4),cache:"no-store"});if(404===n.status)return null;if(!n.ok)throw Error(`GitHub answered ${n.status}`);let r=await n.json();return{version:String(r.tag_name||"").replace(/^v/i,""),url:r.html_url||null,release:r}}function X(e){return{refusal:{code:"not-mac",message:"Installing an update from here works only in the Mac app."}}}function W(e,t){let r=!0;try{(0,n.accessSync)("/Applications",n.constants.W_OK)}catch{r=!1}return(0,o.terminalFallback)({bundle:e,refusalCode:t?.code||null,installsTo:(0,o.installerTarget)({applicationsWritable:r,home:(0,a.homedir)()}),dataDir:q()})}function Y(e){let r;if(!(!e||(r=R().job)&&h.has(r.phase)))try{!function({bundle:e,cacheDir:r,tmpRoot:a,statusFile:i,now:l=Date.now(),isAlive:c=function(e){try{return process.kill(e,0),!0}catch(e){return"EPERM"===e.code}},asideAgeMs:u=6e5}={}){let p=[],h=e=>l-Math.max(e.mtimeMs,e.ctimeMs),f=e=>{try{return n.default.lstatSync(e)}catch{return null}},m=e=>{try{return n.default.readdirSync(e)}catch{return[]}},g=e=>{try{n.default.rmSync(e,{recursive:!0,force:!0}),p.push(e)}catch{}},w=i?y(i):null,b=w?.outcome==="failed"&&"string"==typeof w.previous?s.default.resolve(w.previous):null;if(e){let t=s.default.dirname(e);for(let{name:n,kind:r,pid:a}of(0,o.leftoversBeside)(m(t),s.default.basename(e))){let e=s.default.join(t,n),i=f(e);i&&e!==b&&("incoming"===r?h(i)>36e5&&g(e):!c(a)&&h(i)>u&&g(e))}}if(r)for(let e of m(r)){if(!/^\.previous-[A-Za-z0-9]{6}$/.test(e)&&!/\.zip\.part$/.test(e)&&!/^(last-update|update-confirmed)\.json\.\d+\.tmp$/.test(e))continue;let t=s.default.join(r,e),n=f(t);n&&h(n)>36e5&&g(t)}if(a)for(let e of m(a)){if(!/^six-degrees-update-[A-Za-z0-9]{6}$/.test(e))continue;let n=s.default.join(a,e),r=f(n);if(!r||!r.isDirectory()||36e5>=h(r))continue;let i=s.default.join(n,"mnt");if(D(i)){try{(0,t.execFileSync)(d,["detach",i,"-force"],{stdio:"ignore",timeout:3e4})}catch{}if(D(i))continue}g(n)}}({bundle:e,tmpRoot:(0,a.tmpdir)(),...w()})}catch{}}async function J(e,c){var d;let p=z(c),y=(0,o.releaseSource)(process.env);if("update-status"===e)return Response.json({job:x()});if("cancel-install"===e){let e;return Response.json({job:((e=R().job)&&f.has(e.phase)&&e.ctrl.abort(new m(g)),j(e))})}if("check-release"===e){if(!p.slug)return Response.json({error:"This copy does not say where it was published."},{status:400});let e="mac-app"===p.kind?X(c):null;e&&Y(e.bundle);try{let t=await K(p.slug,y.apiBase),n=!!(t&&(0,i.compareVersions)(t.version,p.version)>0),r=null,a=null;if(n&&e){let n=e.refusal?null:(0,o.planFromRelease)(t.release,{currentVersion:p.version,chip:v().chip,slug:p.slug,downloadBase:y.downloadBase}),s=e.refusal||n?.refusal||null;r=s?{possible:!1,reason:s.message,code:s.code}:{possible:!0,size:n.plan.dmg.size},a=W(e.bundle,e.refusal)}return e&&(d=n?t.version:null,R().checked=d?String(d):null),Response.json({...p,latest:t&&{version:t.version,url:t.url},newer:n,install:r,fallback:a})}catch(e){return Response.json({error:`Could not reach GitHub (${e.message}). Try again in a moment.`},{status:502})}}if("install-release"===e){let e;if("mac-app"!==p.kind)return Response.json({error:"Only the Mac app can install an update itself. Use the line below instead.",command:p.command},{status:400});if(!p.slug)return Response.json({error:"This copy does not say where it was published."},{status:400});let{bundle:i,refusal:d}=X(c),f=W(i,d);if(d)return Response.json({error:d.message,refusal:d.code,fallback:f,command:p.command},{status:409});let m=(0,u.busyRefusal)("Let it finish or stop it, then install the update.");if(m)return Response.json({error:m,fallback:f,command:p.command},{status:409});let g=R().checked||null;if(!g)return Response.json({error:"Check for updates first, then install.",refusal:"not-checked",fallback:f,command:p.command},{status:409});Y(i);let b=v(),S=function(e){let t=R();if(t.job&&h.has(t.job.phase))return{error:"An update is already in progress.",job:j(t.job)};let n={id:(0,l.randomUUID)(),phase:"checking",version:null,notes:null,received:0,total:null,error:null,code:null,startedAt:new Date().toISOString(),endedAt:null,ctrl:new AbortController};t.job=n;let r=H(n,e);return{job:j(n),done:r}}({slug:p.slug,currentVersion:p.version,expectVersion:g,chip:b.chip,macosVersion:b.macosVersion,bundle:i,dataDir:(0,r.dataDir)(),helper:(e=c?s.default.join(c,"scripts","apply-update.sh"):null)&&(0,n.existsSync)(e)?e:null,tmpRoot:(0,a.tmpdir)(),...w(),apiBase:y.apiBase,downloadBase:y.downloadBase,scanRunning:u.scannerJob,othersRunning:()=>(function(e){if(!e||"function"!=typeof process.getuid)return[];let r="";try{r=(0,t.execFileSync)("/bin/ps",["-axo","uid=,pid=,comm="],{timeout:1e4,maxBuffer:0x1000000,stdio:["ignore","pipe","ignore"],env:F()}).toString()}catch{return[]}let a=e;try{a=n.default.realpathSync(e)}catch{}return(0,o.foreignAppProcesses)(r,{bundles:[e,a],uid:process.getuid()})})(i)});return S.error?Response.json({error:S.error,job:S.job},{status:409}):Response.json({job:S.job},{status:202})}return Response.json({error:"Not a git checkout."},{status:400})}async function Z(){let e=(0,r.projectRoot)();if(!(0,r.isGitCheckout)())return Response.json(z(e));let n=await V(e),a=function(e){if(null===L)try{L=(0,t.execFileSync)("git",["rev-parse","--short","HEAD"],{cwd:e}).toString().trim()}catch{L=""}return L}(e);return Response.json({supported:!0,...n,bootSha:a,restartNeeded:!!(a&&n.sha&&a!==n.sha)})}async function Q(e){let t=(0,r.projectRoot)(),n={};try{n=await e.json()}catch{}let a=String(n.action||"");if(!(0,r.isGitCheckout)())return J(a,t);if("check"===a){let e=await G(["fetch","--quiet","origin"],t);if(0!==e.code)return Response.json({error:`Could not reach GitHub: ${e.err.slice(0,200)}`},{status:502});let n=await V(t),r=`origin/${n.branch||"main"}`,[a,s]=await Promise.all([G(["rev-list","--count",`HEAD..${r}`],t),G(["log","--pretty=%h %s",`HEAD..${r}`],t)]),i=Number(a.out||0);return Response.json({...n,behind:Number.isFinite(i)?i:0,commits:(s.out||"").split("\n").filter(Boolean).slice(0,25)})}if("pull"===a){let e=await V(t);if(e.dirty.length&&!e.onlyLockfile)return Response.json({error:"There are local changes here, so nothing was updated.",dirty:e.dirty},{status:409});e.onlyLockfile&&await G(["checkout","--","package-lock.json"],t);let n=await G(["pull","--ff-only"],t);if(0!==n.code)return Response.json({error:n.err.slice(0,400)||"The update could not be applied automatically."},{status:409});let r=await V(t),a=/package(-lock)?\.json/.test(n.out);return Response.json({ok:!0,output:n.out.split("\n").slice(-40).join("\n"),sha:r.sha,subject:r.subject,needsRestart:a})}return Response.json({error:`Unknown action '${a}'`},{status:400})}e.s(["GET",0,Z,"POST",0,Q],34091)},81067,e=>{"use strict";var t=e.i(47909),n=e.i(74017),r=e.i(96250),a=e.i(59756),s=e.i(61916),i=e.i(74677),o=e.i(69741),l=e.i(16795),c=e.i(87718),u=e.i(95169),d=e.i(47587),p=e.i(66012),h=e.i(70101),f=e.i(26937),m=e.i(10372),g=e.i(93695);e.i(52474);var w=e.i(220);let y=new t.AppRouteRouteModule({definition:{kind:n.RouteKind.APP_ROUTE,page:"/api/update/route",pathname:"/api/update",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/app/api/update/route.js",nextConfigOutput:"standalone",userland:()=>e.r(34091),...{}}),{workAsyncStorage:b,workUnitAsyncStorage:v,serverHooks:S}=y;async function R(e,t,r){r.requestMeta&&(0,a.setRequestMeta)(e,r.requestMeta),y.isDev&&(0,a.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let b="/api/update/route";b=b.replace(/\/index$/,"")||"/";let v=await y.prepare(e,t,{srcPage:b,multiZoneDraftMode:!1});if(!v)return t.statusCode=400,t.end("Bad Request"),null==r.waitUntil||r.waitUntil.call(r,Promise.resolve()),null;let{buildId:S,deploymentId:R,params:j,nextConfig:x,parsedUrl:T,isDraftMode:E,prerenderManifest:k,routerServerContext:A,isOnDemandRevalidate:C,revalidateOnlyGenerated:$,resolvedPathname:D,clientReferenceManifest:M,serverActionsManifest:N}=v,_=(0,o.normalizeAppPath)(b),B=!!(k.dynamicRoutes[_]||k.routes[D]),F=async()=>((null==A?void 0:A.render404)?await A.render404(e,t,T,!1):t.end("This page could not be found"),null);if(B&&!E){let e=!!k.routes[D],t=k.dynamicRoutes[_];if(t&&!1===t.fallback&&!e){if(x.adapterPath)return await F();throw new g.NoFallbackError}}let I=null;!B||y.isDev||E||(I="/index"===(I=D)?"/":I);let O=!0===y.isDev||!B,P=B&&!O;N&&M&&(0,i.setManifestsSingleton)({page:b,clientReferenceManifest:M,serverActionsManifest:N});let H=e.method||"GET",U=(0,s.getTracer)(),L=U.getActiveScopeSpan(),G=!!(null==A?void 0:A.isWrappedByNextServer),V=!!(0,a.getRequestMeta)(e,"minimalMode"),q=(0,a.getRequestMeta)(e,"incrementalCache")||await y.getIncrementalCache(e,x,k,V);null==q||q.resetRequestCache(),globalThis.__incrementalCache=q;let z={params:j,previewProps:k.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts,useCacheTimeout:x.experimental.useCacheTimeout},cacheComponents:!!x.cacheComponents,validationLevel:x.experimental.instantInsights.validationLevel,supportsDynamicResponse:O,incrementalCache:q,hmrRefreshHash:(0,a.getRequestMeta)(e,"hmrRefreshHash"),cacheLifeProfiles:x.cacheLife,staticPageGenerationTimeout:x.staticPageGenerationTimeout,waitUntil:r.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,n,r,a)=>y.onRequestError(e,t,r,a,A)},sharedContext:{buildId:S,deploymentId:R}},K=new l.NodeNextRequest(e),X=new l.NodeNextResponse(t),W=c.NextRequestAdapter.fromNodeNextRequest(K,(0,c.signalFromNodeResponse)(t)),Y=async({previousCacheEntry:n})=>{try{if(!V&&C&&$&&!n)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let a=await y.handle(W,z);e.fetchMetrics=z.renderOpts.fetchMetrics;let s=z.renderOpts.pendingWaitUntil;s&&r.waitUntil&&(r.waitUntil(s),s=void 0);let i=z.renderOpts.collectedTags;if(!B)return await (0,p.sendResponse)(K,X,a,s),null;{let e=await a.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(a.headers);i&&(t[m.NEXT_CACHE_TAGS_HEADER]=i),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let n=void 0!==z.renderOpts.collectedRevalidate&&!(z.renderOpts.collectedRevalidate>=m.INFINITE_CACHE)&&z.renderOpts.collectedRevalidate,r=void 0===z.renderOpts.collectedExpire||z.renderOpts.collectedExpire>=m.INFINITE_CACHE?!1!==n&&n>0?x.expireTime:void 0:z.renderOpts.collectedExpire;return{value:{kind:w.CachedRouteKind.APP_ROUTE,status:a.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:n,expire:r}}}}catch(t){throw(null==n?void 0:n.isStale)&&await y.onRequestError(e,t,{routerKind:"App Router",routePath:b,routeType:"route",revalidateReason:(0,d.getRevalidateReason)({isStaticGeneration:P,isOnDemandRevalidate:C})},!1,A),t}},J=async(a,i)=>{try{var o,l;let a=await y.handleResponse({req:e,nextConfig:x,cacheKey:I,routeKind:n.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:k,isRoutePPREnabled:!1,isOnDemandRevalidate:C,revalidateOnlyGenerated:$,responseGenerator:Y,waitUntil:r.waitUntil,isMinimalMode:V});if(!B)return;if((null==a||null==(o=a.value)?void 0:o.kind)!==w.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==a||null==(l=a.value)?void 0:l.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});V||t.setHeader("x-nextjs-cache",C?"REVALIDATED":a.isMiss?"MISS":a.isStale?"STALE":"HIT"),E&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let s=(0,h.fromNodeOutgoingHttpHeaders)(a.value.headers);V&&B||s.delete(m.NEXT_CACHE_TAGS_HEADER),!a.cacheControl||t.getHeader("Cache-Control")||s.get("Cache-Control")||s.set("Cache-Control",(0,f.getCacheControlHeader)(a.cacheControl)),await (0,p.sendResponse)(K,X,new Response(a.value.body,{headers:s,status:a.value.status||200}));return}catch(t){if(t instanceof g.NoFallbackError||await y.onRequestError(e,t,{routerKind:"App Router",routePath:_,routeType:"route",revalidateReason:(0,d.getRevalidateReason)({isStaticGeneration:P,isOnDemandRevalidate:C})},!1,A),B)throw t;await (0,p.sendResponse)(K,X,new Response(null,{status:500}));return}finally{(()=>{if(!a)return;let e=t.statusCode;a.setAttributes({"http.status_code":e,"next.rsc":!1}),e&&e>=500&&(a.setStatus({code:s.SpanStatusCode.ERROR}),a.setAttribute("error.type",e.toString()));let n=U.getRootSpanAttributes();if(!n)return;if(n.get("next.span_type")!==u.BaseServerSpan.handleRequest)return console.warn(`Unexpected root span type '${n.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let r=n.get("next.route")||_,o=`${H} ${r}`;a.setAttributes({"next.route":r,"http.route":r,"next.span_name":o}),a.updateName(o),i&&i!==a&&(i.setAttribute("http.route",r),i.updateName(o))})()}};if(G&&L)await J(L,void 0);else{let t=U.getActiveScopeSpan();await U.withPropagatedContext(e.headers,()=>U.trace(u.BaseServerSpan.handleRequest,{spanName:`${H} ${b}`,kind:s.SpanKind.SERVER,attributes:{"http.method":H,"http.target":e.url}},e=>J(e,t)),void 0,!G)}}e.s(["handler",0,R,"patchFetch",0,function(){return(0,r.patchFetch)({workAsyncStorage:b,workUnitAsyncStorage:v})},"routeModule",0,y,"serverHooks",0,S,"workAsyncStorage",0,b,"workUnitAsyncStorage",0,v])}];
3
3
 
4
4
  //# sourceMappingURL=_1itd1o_._.js.map