six-degrees 0.2.0 → 0.3.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.next/standalone/.next/BUILD_ID +1 -1
- package/.next/standalone/.next/app-path-routes-manifest.json +10 -0
- package/.next/standalone/.next/build-manifest.json +3 -3
- package/.next/standalone/.next/prerender-manifest.json +39 -11
- package/.next/standalone/.next/required-server-files.json +4 -1
- package/.next/standalone/.next/routes-manifest.json +60 -0
- package/.next/standalone/.next/server/app/_global-error/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_global-error.html +1 -1
- package/.next/standalone/.next/server/app/_global-error.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found.html +1 -1
- package/.next/standalone/.next/server/app/_not-found.rsc +11 -11
- package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +9 -9
- package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/api/admin-delete/route.js +3 -2
- package/.next/standalone/.next/server/app/api/admin-delete/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/admin-update/route.js +3 -2
- package/.next/standalone/.next/server/app/api/admin-update/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/bridges/route.js +3 -2
- package/.next/standalone/.next/server/app/api/bridges/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/bulk-import/route.js +3 -2
- package/.next/standalone/.next/server/app/api/bulk-import/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route.js +9 -0
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/company-scores/legacy/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/company-scores/route.js +3 -2
- package/.next/standalone/.next/server/app/api/company-scores/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/connections/route.js +3 -2
- package/.next/standalone/.next/server/app/api/connections/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/data/export/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/data/export/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/data/export/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/data/export/route.js +7 -0
- package/.next/standalone/.next/server/app/api/data/export/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/data/export/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/data/export/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/data/import/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/data/import/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/data/import/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/data/import/route.js +8 -0
- package/.next/standalone/.next/server/app/api/data/import/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/data/import/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/data/import/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/data/restart/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/data/restart/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/data/restart/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/data/restart/route.js +8 -0
- package/.next/standalone/.next/server/app/api/data/restart/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/data/restart/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/data/restart/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route.js +7 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/data/reveal/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/data/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/data/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/data/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/data/route.js +7 -0
- package/.next/standalone/.next/server/app/api/data/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/data/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/data/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/delete-cluster/route.js +3 -2
- package/.next/standalone/.next/server/app/api/delete-cluster/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/ingest/route.js +2 -2
- package/.next/standalone/.next/server/app/api/ingest/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/network/route.js +3 -2
- package/.next/standalone/.next/server/app/api/network/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/notifications/route.js +3 -2
- package/.next/standalone/.next/server/app/api/notifications/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/outreach/route.js +3 -2
- package/.next/standalone/.next/server/app/api/outreach/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/queue/route.js +3 -2
- package/.next/standalone/.next/server/app/api/queue/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/scraper/route.js +3 -2
- package/.next/standalone/.next/server/app/api/scraper/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/settings/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/settings/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/settings/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/settings/route.js +9 -0
- package/.next/standalone/.next/server/app/api/settings/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/settings/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/settings/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route.js +8 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/settings/sector-preview/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route/build-manifest.json +12 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route.js +8 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route.js.map +5 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/settings/sector-suggestions/route_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/api/setup-profile/route.js +3 -2
- package/.next/standalone/.next/server/app/api/setup-profile/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/unlock/route.js +3 -2
- package/.next/standalone/.next/server/app/api/unlock/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/update/route.js +1 -1
- package/.next/standalone/.next/server/app/api/update/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/update-images/route.js +3 -2
- package/.next/standalone/.next/server/app/api/update-images/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/users/route.js +3 -2
- package/.next/standalone/.next/server/app/api/users/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/avatars/[file]/route.js +2 -1
- package/.next/standalone/.next/server/app/avatars/[file]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/favicon.ico/route.js +2 -1
- package/.next/standalone/.next/server/app/favicon.ico/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/import/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/import/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/import.html +1 -1
- package/.next/standalone/.next/server/app/import.rsc +13 -13
- package/.next/standalone/.next/server/app/import.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/import.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/import.segments/import/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/index.html +1 -1
- package/.next/standalone/.next/server/app/index.rsc +13 -13
- package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/launch/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/launch/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/launch.html +2 -2
- package/.next/standalone/.next/server/app/launch.rsc +13 -13
- package/.next/standalone/.next/server/app/launch.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/launch.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/launch.segments/launch/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/paths/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/paths/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/paths.html +1 -1
- package/.next/standalone/.next/server/app/paths.rsc +13 -13
- package/.next/standalone/.next/server/app/paths.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/paths.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/paths.segments/paths/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/profile/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/profile/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/profile.html +1 -1
- package/.next/standalone/.next/server/app/profile.rsc +13 -13
- package/.next/standalone/.next/server/app/profile.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/profile.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/profile.segments/profile/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/queue/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/queue/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/queue.html +1 -1
- package/.next/standalone/.next/server/app/queue.rsc +13 -13
- package/.next/standalone/.next/server/app/queue.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/queue.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/queue.segments/queue/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app/settings/page/app-paths-manifest.json +3 -0
- package/.next/standalone/.next/server/app/settings/page/build-manifest.json +20 -0
- package/.next/standalone/.next/server/app/settings/page/next-font-manifest.json +11 -0
- package/.next/standalone/.next/server/app/settings/page/react-loadable-manifest.json +1 -0
- package/.next/standalone/.next/server/app/settings/page/server-reference-manifest.json +4 -0
- package/.next/standalone/.next/server/app/settings/page.js +13 -0
- package/.next/standalone/.next/server/app/settings/page.js.map +5 -0
- package/.next/standalone/.next/server/app/settings/page.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +3 -0
- package/.next/standalone/.next/server/app/settings.html +1 -0
- package/.next/standalone/.next/server/app/settings.meta +26 -0
- package/.next/standalone/.next/server/app/settings.rsc +24 -0
- package/.next/standalone/.next/server/app/settings.segments/_full.segment.rsc +24 -0
- package/.next/standalone/.next/server/app/settings.segments/_tree.segment.rsc +4 -0
- package/.next/standalone/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +28 -0
- package/.next/standalone/.next/server/app/setup/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/setup/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/setup.html +1 -1
- package/.next/standalone/.next/server/app/setup.rsc +13 -13
- package/.next/standalone/.next/server/app/setup.segments/_full.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/setup.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/setup.segments/setup/__PAGE__.segment.rsc +11 -11
- package/.next/standalone/.next/server/app-paths-manifest.json +10 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0-rnla2._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__00la_y0._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__07t47cm._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0cj5jqc._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0e0fei3._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0i5hdu4._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0ljcioj._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0ljnyho._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0o5-tcg._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0qrnous._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0t3v1a1._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0uag-k5._.js +8 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0um1uey._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0wmexuc._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0xu34sz._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__133knx1._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__14ou7j5._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__15-17hl._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__16iu0hv._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__19b7mig._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1bbcwub._.js +8 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1eris29._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1gjo_cq._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1kbl21f._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1qcm08_._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1rphsdk._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1t3rugi._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1w25q0m._.js +3 -0
- package/.next/standalone/.next/server/chunks/_072jl0y._.js +3 -0
- package/.next/standalone/.next/server/chunks/_0lw8_i0._.js +3 -0
- package/.next/standalone/.next/server/chunks/_1_fynia._.js +21 -3
- package/.next/standalone/.next/server/chunks/_1fn30_l._.js +3 -0
- package/.next/standalone/.next/server/chunks/_1itd1o_._.js +2 -1
- package/.next/standalone/.next/server/chunks/_1iwkh8t._.js +1 -1
- package/.next/standalone/.next/server/chunks/_1mxn_lb._.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_company-scores_legacy_route_actions_1ncspu_.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_data_export_route_actions_1lkimty.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_data_import_route_actions_1eji0kd.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_data_restart_route_actions_00_-u6o.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_data_reveal_route_actions_0-moqtn.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_data_route_actions_0j0w5ep.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_settings_route_actions_1bpm9ac.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_settings_sector-preview_route_actions_0w79454.js +3 -0
- package/.next/standalone/.next/server/chunks/_next-internal_server_app_api_settings_sector-suggestions_route_actions_1eoqugp.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_db-client_15le7cw.js +155 -0
- package/.next/standalone/.next/server/chunks/{lib_rpc_0mc73lk.js → lib_rpc_00tx2sm.js} +1 -1
- package/.next/standalone/.next/server/chunks/lib_rpc_02-qa4d.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_02ndsg2.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_08q5vp6.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_0_8i3ft.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_0c9d9ti.js +5 -2
- package/.next/standalone/.next/server/chunks/lib_rpc_0huvw-3.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_0ip2vdh.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_0jzisgh.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_0yi9xvd.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_1jyhd0o.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_1kn59-i.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_1q2jkza.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_1vpm1sk.js +3 -0
- package/.next/standalone/.next/server/chunks/lib_rpc_1x6p_31.js +3 -0
- package/.next/standalone/.next/server/chunks/node_modules_next_1zc5q0a._.js +158 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0mocm6d._.js → [root-of-the-server]__0an6blh._.js} +3 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0h1_f_2._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1m0255u._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0bipr5s._.js → [root-of-the-server]__1z1j3ek._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/_07u8byv._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/_08r_mlf._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{_0ggabjc._.js → _0942v8n._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{_1djpk8t._.js → _0hl_t7r._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/_0tb83dw._.js +132 -0
- package/.next/standalone/.next/server/chunks/ssr/_1-87bs1._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/_17gui6a._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_next-internal_server_app_settings_page_actions_11x4dq5.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/app_import_page_1fmu6_l.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_launch_page_19t0dyd.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/app_page_1fazqbf.js +4 -4
- package/.next/standalone/.next/server/chunks/ssr/app_profile_page_0u3-l5y.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_queue_page_0c6znd6.js +5 -5
- package/.next/standalone/.next/server/chunks/ssr/app_settings_page_1f8mjj_.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/app_setup_page_1-282zx.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/lib_0i8v-s3._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/node_modules_1f8t_rp._.js +23 -0
- package/.next/standalone/.next/server/chunks/ssr/node_modules_1nkgb45._.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_01xbj_9._.js → node_modules_1wax83z._.js} +3 -3
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_next_dist_00nap8h._.js → node_modules_next_dist_1bunoni._.js} +2 -2
- package/.next/standalone/.next/server/edge/chunks/[root-of-the-server]__0pco7a6._.js +2 -2
- package/.next/standalone/.next/server/middleware-build-manifest.js +3 -3
- package/.next/standalone/.next/server/middleware-manifest.json +15 -7
- package/.next/standalone/.next/server/next-font-manifest.js +1 -1
- package/.next/standalone/.next/server/next-font-manifest.json +4 -0
- package/.next/standalone/.next/server/pages/404.html +1 -1
- package/.next/standalone/.next/server/pages/500.html +1 -1
- package/.next/standalone/.next/server/prefetch-hints.json +14 -0
- package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/static/chunks/06x3jiiz96m5t.js +1 -0
- package/.next/{static/chunks/34at5d2ifl62i.js → standalone/.next/static/chunks/0ngx9s6-zgshe.js} +5 -5
- package/.next/standalone/.next/static/chunks/0q-_khndfxubv.js +2 -0
- package/.next/standalone/.next/static/chunks/1c79veqedvubt.js +1 -0
- package/.next/standalone/.next/static/chunks/1chp3nx45meg5.js +44 -0
- package/.next/standalone/.next/static/chunks/1irqj0lf-fu3d.js +1 -0
- package/.next/standalone/.next/static/chunks/1uadqylrod5_v.js +1 -0
- package/.next/standalone/.next/static/chunks/23u0zclgwpc4d.js +1 -0
- package/.next/standalone/.next/static/chunks/289ktj97di6zg.js +1 -0
- package/.next/standalone/.next/static/chunks/2b3lmf8e6uj8m.js +16 -0
- package/.next/standalone/.next/static/chunks/2jz311xl1pp_8.js +1 -0
- package/.next/standalone/.next/static/chunks/2ot61qsv6_0eq.js +1 -0
- package/.next/standalone/.next/static/chunks/3npq5yd7c4dmn.js +2 -0
- package/.next/standalone/.next/static/frfHFnRYTA0Wjrw8oZJtY/_clientMiddlewareManifest.js +14 -0
- package/.next/standalone/AGENTS.md +10 -0
- package/.next/standalone/CHANGELOG.md +325 -0
- package/.next/standalone/CONTRIBUTING.md +14 -2
- package/.next/standalone/README.md +181 -53
- package/.next/standalone/SECURITY.md +120 -10
- package/.next/standalone/app/api/company-scores/legacy/route.js +32 -0
- package/.next/standalone/app/api/company-scores/route.js +20 -11
- package/.next/standalone/app/api/data/export/route.js +49 -0
- package/.next/standalone/app/api/data/import/route.js +83 -0
- package/.next/standalone/app/api/data/restart/route.js +37 -0
- package/.next/standalone/app/api/data/reveal/route.js +14 -0
- package/.next/standalone/app/api/data/route.js +39 -0
- package/.next/standalone/app/api/ingest/route.js +15 -47
- package/.next/standalone/app/api/scraper/route.js +268 -128
- package/.next/standalone/app/api/settings/route.js +58 -0
- package/.next/standalone/app/api/settings/sector-preview/route.js +38 -0
- package/.next/standalone/app/api/settings/sector-suggestions/route.js +20 -0
- package/.next/standalone/app/api/update/route.js +197 -24
- package/.next/standalone/app/avatars/[file]/route.js +4 -2
- package/.next/standalone/app/components/CompanyScores.js +28 -7
- package/.next/standalone/app/components/EmptyState.js +8 -0
- package/.next/standalone/app/components/ForceGraph.js +40 -36
- package/.next/standalone/app/components/LegacyScoresCard.js +129 -0
- package/.next/standalone/app/components/Sidebar.js +19 -18
- package/.next/standalone/app/components/UpdatePanel.js +317 -99
- package/.next/standalone/app/components/UserProvider.js +4 -3
- package/.next/standalone/app/components/settings/DataSection.js +437 -0
- package/.next/standalone/app/components/settings/SectorSection.js +445 -0
- package/.next/standalone/app/components/ui.js +62 -0
- package/.next/standalone/app/import/page.js +3 -3
- package/.next/standalone/app/launch/page.js +30 -20
- package/.next/standalone/app/layout.js +2 -2
- package/.next/standalone/app/page.js +15 -2
- package/.next/standalone/app/paths/page.js +13 -5
- package/.next/standalone/app/profile/page.js +41 -186
- package/.next/standalone/app/queue/page.js +8 -2
- package/.next/standalone/app/settings/page.js +96 -0
- package/.next/standalone/app/setup/page.js +35 -19
- package/.next/standalone/bin/args.mjs +44 -0
- package/.next/standalone/bin/six-degrees.mjs +16 -17
- package/.next/standalone/install.sh +1 -1
- package/.next/standalone/lib/companies.js +44 -119
- package/.next/standalone/lib/csv.js +61 -27
- package/.next/standalone/lib/data-export.js +170 -0
- package/.next/standalone/lib/data-folder.js +238 -0
- package/.next/standalone/lib/data-import.js +878 -0
- package/.next/standalone/lib/db-client.js +48 -3
- package/.next/standalone/lib/durable.js +73 -0
- package/.next/standalone/lib/gate.js +90 -1
- package/.next/standalone/lib/ingest.js +40 -0
- package/.next/standalone/lib/legacy-offer.js +185 -0
- package/.next/standalone/lib/legacy-scores.js +77 -0
- package/.next/standalone/lib/linkedin-limits.js +124 -1
- package/.next/standalone/lib/release.js +5 -2
- package/.next/standalone/lib/rpc.js +121 -13
- package/.next/standalone/lib/sample-stats.js +16 -0
- package/.next/standalone/lib/scan-progress.js +13 -0
- package/.next/standalone/lib/scan-state.js +53 -0
- package/.next/standalone/lib/scanner-python.js +685 -0
- package/.next/standalone/lib/scanner-setup.js +104 -0
- package/.next/standalone/lib/scoring.js +747 -138
- package/.next/standalone/lib/scraper-client.js +10 -6
- package/.next/standalone/lib/sector-directory.js +1532 -0
- package/.next/standalone/lib/sector-focus.js +163 -0
- package/.next/standalone/lib/sector-labels.js +81 -0
- package/.next/standalone/lib/settings-effects.js +59 -0
- package/.next/standalone/lib/settings.js +83 -0
- package/.next/standalone/lib/updater-job.js +838 -0
- package/.next/standalone/lib/updater.js +494 -0
- package/.next/standalone/middleware.js +25 -28
- package/.next/standalone/next.config.mjs +19 -3
- package/.next/standalone/package-lock.json +103 -9
- package/.next/standalone/package.json +12 -11
- package/.next/standalone/public/demo-data.json +1 -1
- package/.next/standalone/scripts/apply-update.sh +482 -0
- package/.next/standalone/scripts/build-app.mjs +251 -9
- package/.next/standalone/scripts/gen-synthetic.mjs +16 -1
- package/.next/standalone/scripts/readme_buttons.py +89 -0
- package/.next/standalone/scripts/requirements.txt +106 -4
- package/.next/standalone/scripts/screenshots.py +2 -0
- package/.next/standalone/scripts/test-release-server.mjs +143 -0
- package/.next/standalone/server.js +1 -1
- package/.next/static/chunks/06x3jiiz96m5t.js +1 -0
- package/.next/{standalone/.next/static/chunks/34at5d2ifl62i.js → static/chunks/0ngx9s6-zgshe.js} +5 -5
- package/.next/static/chunks/0q-_khndfxubv.js +2 -0
- package/.next/static/chunks/1c79veqedvubt.js +1 -0
- package/.next/static/chunks/1chp3nx45meg5.js +44 -0
- package/.next/static/chunks/1irqj0lf-fu3d.js +1 -0
- package/.next/static/chunks/1uadqylrod5_v.js +1 -0
- package/.next/static/chunks/23u0zclgwpc4d.js +1 -0
- package/.next/static/chunks/289ktj97di6zg.js +1 -0
- package/.next/static/chunks/2b3lmf8e6uj8m.js +16 -0
- package/.next/static/chunks/2jz311xl1pp_8.js +1 -0
- package/.next/static/chunks/2ot61qsv6_0eq.js +1 -0
- package/.next/static/chunks/3npq5yd7c4dmn.js +2 -0
- package/.next/static/frfHFnRYTA0Wjrw8oZJtY/_clientMiddlewareManifest.js +14 -0
- package/CHANGELOG.md +325 -0
- package/README.md +181 -53
- package/SECURITY.md +120 -10
- package/bin/args.mjs +44 -0
- package/bin/six-degrees.mjs +16 -17
- package/lib/companies.js +44 -119
- package/lib/csv.js +61 -27
- package/lib/data-export.js +170 -0
- package/lib/data-folder.js +238 -0
- package/lib/data-import.js +878 -0
- package/lib/db-client.js +48 -3
- package/lib/durable.js +73 -0
- package/lib/gate.js +90 -1
- package/lib/ingest.js +40 -0
- package/lib/legacy-offer.js +185 -0
- package/lib/legacy-scores.js +77 -0
- package/lib/linkedin-limits.js +124 -1
- package/lib/release.js +5 -2
- package/lib/rpc.js +121 -13
- package/lib/sample-stats.js +16 -0
- package/lib/scan-progress.js +13 -0
- package/lib/scan-state.js +53 -0
- package/lib/scanner-python.js +685 -0
- package/lib/scanner-setup.js +104 -0
- package/lib/scoring.js +747 -138
- package/lib/scraper-client.js +10 -6
- package/lib/sector-directory.js +1532 -0
- package/lib/sector-focus.js +163 -0
- package/lib/sector-labels.js +81 -0
- package/lib/settings-effects.js +59 -0
- package/lib/settings.js +83 -0
- package/lib/updater-job.js +838 -0
- package/lib/updater.js +494 -0
- package/package.json +12 -11
- package/public/demo-data.json +1 -1
- package/scripts/requirements.txt +106 -4
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0jrmmj-._.js +0 -150
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0qx548g._.js +0 -151
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1an3leo._.js +0 -150
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1m8zedk._.js +0 -155
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1zor0ys._.js +0 -3
- package/.next/standalone/.next/server/chunks/_0_rp-01._.js +0 -3
- package/.next/standalone/.next/server/chunks/_0hzdk79._.js +0 -3
- package/.next/standalone/.next/server/chunks/_0ow7u5r._.js +0 -3
- package/.next/standalone/.next/server/chunks/_0t0zc2d._.js +0 -3
- package/.next/standalone/.next/server/chunks/_0wa631d._.js +0 -3
- package/.next/standalone/.next/server/chunks/_13ccnao._.js +0 -3
- package/.next/standalone/.next/server/chunks/_13es063._.js +0 -3
- package/.next/standalone/.next/server/chunks/_142872j._.js +0 -3
- package/.next/standalone/.next/server/chunks/_18wsb_a._.js +0 -8
- package/.next/standalone/.next/server/chunks/_1e-4h5h._.js +0 -3
- package/.next/standalone/.next/server/chunks/_1gvvd7n._.js +0 -158
- package/.next/standalone/.next/server/chunks/_1moda66._.js +0 -3
- package/.next/standalone/.next/server/chunks/_1p6ghzv._.js +0 -3
- package/.next/standalone/.next/server/chunks/_1xmmi_v._.js +0 -3
- package/.next/standalone/.next/server/chunks/_1z-yrlf._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/_0bf3x4q._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/app_paths_page_1ol90m7.js +0 -4
- package/.next/standalone/.next/static/N9wokeIiC9rUIGmzBhj6T/_clientMiddlewareManifest.js +0 -6
- package/.next/standalone/.next/static/chunks/1odow92u6wxz0.js +0 -1
- package/.next/standalone/.next/static/chunks/1wb_is4wsdm-u.js +0 -1
- package/.next/standalone/.next/static/chunks/1zmpcmngg5c7-.js +0 -2
- package/.next/standalone/.next/static/chunks/220-ne82aus0c.js +0 -44
- package/.next/standalone/.next/static/chunks/2rrf5kzx2fhin.js +0 -2
- package/.next/standalone/.next/static/chunks/2s_k9x4d0gi9h.js +0 -16
- package/.next/standalone/.next/static/chunks/3hsi90cejq2dg.js +0 -1
- package/.next/standalone/.next/static/chunks/3pfyuezyqd9ob.js +0 -1
- package/.next/standalone/.next/static/chunks/3ts-_4i6bfkh2.js +0 -1
- package/.next/standalone/scripts/score-connections.sql +0 -80
- package/.next/standalone/scripts/score_new_connections.sql +0 -77
- package/.next/static/N9wokeIiC9rUIGmzBhj6T/_clientMiddlewareManifest.js +0 -6
- package/.next/static/chunks/1odow92u6wxz0.js +0 -1
- package/.next/static/chunks/1wb_is4wsdm-u.js +0 -1
- package/.next/static/chunks/1zmpcmngg5c7-.js +0 -2
- package/.next/static/chunks/220-ne82aus0c.js +0 -44
- package/.next/static/chunks/2rrf5kzx2fhin.js +0 -2
- package/.next/static/chunks/2s_k9x4d0gi9h.js +0 -16
- package/.next/static/chunks/3hsi90cejq2dg.js +0 -1
- package/.next/static/chunks/3pfyuezyqd9ob.js +0 -1
- package/.next/static/chunks/3ts-_4i6bfkh2.js +0 -1
- package/scripts/score_new_connections.sql +0 -77
- /package/.next/standalone/.next/static/{N9wokeIiC9rUIGmzBhj6T → frfHFnRYTA0Wjrw8oZJtY}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{N9wokeIiC9rUIGmzBhj6T → frfHFnRYTA0Wjrw8oZJtY}/_ssgManifest.js +0 -0
- /package/.next/static/{N9wokeIiC9rUIGmzBhj6T → frfHFnRYTA0Wjrw8oZJtY}/_buildManifest.js +0 -0
- /package/.next/static/{N9wokeIiC9rUIGmzBhj6T → frfHFnRYTA0Wjrw8oZJtY}/_ssgManifest.js +0 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { mkdtempSync, openSync, rmSync, createReadStream } from 'node:fs';
|
|
2
|
+
import { Readable } from 'node:stream';
|
|
3
|
+
import path from 'node:path';
|
|
4
|
+
import { getDb, dataDir } from '../../../../lib/db-client';
|
|
5
|
+
import { buildExport, exportFileName } from '../../../../lib/data-export';
|
|
6
|
+
import { EXPORT_WORK_PREFIX, sweepLeftovers } from '../../../../lib/data-folder';
|
|
7
|
+
import { SCHEMA_SQL } from '../../../../db/schema';
|
|
8
|
+
import { APP_VERSION } from '../../../../lib/app-version';
|
|
9
|
+
|
|
10
|
+
// Save a copy of the network to carry to another computer: one .sixdegrees
|
|
11
|
+
// file (lib/data-export.js), sent back as a download. A POST, so it takes a
|
|
12
|
+
// click on the app's own page (the cross-site guard applies), and gated with
|
|
13
|
+
// the other routes that hand over or replace everything (lib/gate.js).
|
|
14
|
+
//
|
|
15
|
+
// It is built in a private folder inside the data folder, never anywhere else,
|
|
16
|
+
// and that folder is gone before the first byte is sent: the open file keeps
|
|
17
|
+
// the bytes readable, so an interrupted download leaves no copy behind.
|
|
18
|
+
|
|
19
|
+
export async function POST(request) {
|
|
20
|
+
let body = {};
|
|
21
|
+
try { body = await request.json(); } catch { /* no options: the defaults */ }
|
|
22
|
+
const includePhotos = body?.photos !== false;
|
|
23
|
+
|
|
24
|
+
const dir = dataDir();
|
|
25
|
+
sweepLeftovers(dir);
|
|
26
|
+
const work = mkdtempSync(path.join(dir, EXPORT_WORK_PREFIX));
|
|
27
|
+
try {
|
|
28
|
+
const file = path.join(work, 'export.sixdegrees');
|
|
29
|
+
const made = buildExport(getDb(), {
|
|
30
|
+
dir, outFile: file, includePhotos, appVersion: APP_VERSION, schemaSql: SCHEMA_SQL,
|
|
31
|
+
});
|
|
32
|
+
const fd = openSync(file, 'r');
|
|
33
|
+
rmSync(work, { recursive: true, force: true });
|
|
34
|
+
const stream = createReadStream(file, { fd });
|
|
35
|
+
return new Response(Readable.toWeb(stream), {
|
|
36
|
+
headers: {
|
|
37
|
+
'Content-Type': 'application/octet-stream',
|
|
38
|
+
'Content-Disposition': `attachment; filename="${exportFileName()}"`,
|
|
39
|
+
'Content-Length': String(made.bytes),
|
|
40
|
+
'Cache-Control': 'no-store',
|
|
41
|
+
'X-Six-Degrees-People': String(made.people),
|
|
42
|
+
'X-Six-Degrees-Photos': String(made.photos),
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
} catch (err) {
|
|
46
|
+
rmSync(work, { recursive: true, force: true });
|
|
47
|
+
return Response.json({ error: `The copy couldn't be made: ${err.message}` }, { status: 500 });
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { mkdtempSync, rmSync } from 'node:fs';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { getDb, dataDir, applySchema } from '../../../../lib/db-client';
|
|
4
|
+
import { SCHEMA_SQL } from '../../../../db/schema';
|
|
5
|
+
import { APP_VERSION } from '../../../../lib/app-version';
|
|
6
|
+
import { countPeople } from '../../../../lib/data-export';
|
|
7
|
+
import { UPLOAD_WORK_PREFIX, sweepLeftovers } from '../../../../lib/data-folder';
|
|
8
|
+
import { requestRefusal } from '../../../../lib/gate';
|
|
9
|
+
import {
|
|
10
|
+
ImportError, IMPORT_ROUTE, admitImport, receiveUpload, stageImport, pendingImport, cancelPendingImport,
|
|
11
|
+
} from '../../../../lib/data-import';
|
|
12
|
+
import { scannerJob, runningNow } from '../../../../lib/scan-state';
|
|
13
|
+
|
|
14
|
+
// Bring in a network from another computer. The body is the .sixdegrees file
|
|
15
|
+
// itself; X-Six-Degrees-Size says how big it is (a body cut short must never
|
|
16
|
+
// pass for a whole one), and X-Six-Degrees-Replace is the number of people the
|
|
17
|
+
// user agreed to replace.
|
|
18
|
+
//
|
|
19
|
+
// middleware.js leaves this route alone: Next would copy the whole upload into
|
|
20
|
+
// memory before middleware could refuse it. So every handler here makes the
|
|
21
|
+
// middleware's checks itself, first (lib/gate.js requestRefusal, the same
|
|
22
|
+
// function), and the upload is written to disk as it arrives (receiveUpload).
|
|
23
|
+
//
|
|
24
|
+
// This only checks the file and stages it (lib/data-import.js). The network is
|
|
25
|
+
// replaced the next time the app starts, after a copy of it is kept. Gated
|
|
26
|
+
// (lib/gate.js): it replaces everything.
|
|
27
|
+
|
|
28
|
+
function refuse(err) {
|
|
29
|
+
return Response.json({ error: err.message, ...err.extra }, { status: err.status });
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export async function POST(request) {
|
|
33
|
+
const admitted = admitImport(request, {
|
|
34
|
+
env: process.env,
|
|
35
|
+
scanRunning: scannerJob,
|
|
36
|
+
pending: () => pendingImport(dataDir()),
|
|
37
|
+
currentPeople: () => countPeople(getDb()),
|
|
38
|
+
});
|
|
39
|
+
if (admitted.refused) {
|
|
40
|
+
const { status, ...body } = admitted.refused;
|
|
41
|
+
return Response.json(body, { status });
|
|
42
|
+
}
|
|
43
|
+
const { declared, currentPeople } = admitted;
|
|
44
|
+
|
|
45
|
+
const dir = dataDir();
|
|
46
|
+
sweepLeftovers(dir);
|
|
47
|
+
const work = mkdtempSync(path.join(dir, UPLOAD_WORK_PREFIX));
|
|
48
|
+
try {
|
|
49
|
+
const upload = path.join(work, 'upload.sixdegrees');
|
|
50
|
+
await receiveUpload(request.body, upload, { declared });
|
|
51
|
+
// Asked again: a scan (or Install) or a second import could have started during the upload.
|
|
52
|
+
const job = scannerJob();
|
|
53
|
+
if (job) {
|
|
54
|
+
throw new ImportError(`${runningNow(job)}: it started while the file was arriving. Let it finish, then import again.`, { status: 409 });
|
|
55
|
+
}
|
|
56
|
+
if (pendingImport(dir)) {
|
|
57
|
+
throw new ImportError('Another import is already waiting to finish.', { status: 409 });
|
|
58
|
+
}
|
|
59
|
+
const pending = stageImport(upload, {
|
|
60
|
+
dir, applySchema, schemaSql: SCHEMA_SQL, appVersion: APP_VERSION, replacedPeople: currentPeople,
|
|
61
|
+
});
|
|
62
|
+
return Response.json({ ok: true, pending });
|
|
63
|
+
} catch (err) {
|
|
64
|
+
rmSync(work, { recursive: true, force: true });
|
|
65
|
+
if (err instanceof ImportError) return refuse(err);
|
|
66
|
+
return Response.json({ error: `The file couldn't be checked: ${err.message}` }, { status: 500 });
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
/** Throw away an import that is waiting, before it starts. */
|
|
71
|
+
export async function DELETE(request) {
|
|
72
|
+
const refused = requestRefusal({ method: request.method, pathname: IMPORT_ROUTE, headers: request.headers, env: process.env });
|
|
73
|
+
if (refused) return Response.json({ error: refused.error }, { status: refused.status });
|
|
74
|
+
|
|
75
|
+
const result = cancelPendingImport(dataDir());
|
|
76
|
+
if (result.reason === 'started') {
|
|
77
|
+
return Response.json(
|
|
78
|
+
{ error: 'This import has already started, so it can only go forward. Restart Six Degrees to finish it.' },
|
|
79
|
+
{ status: 409 },
|
|
80
|
+
);
|
|
81
|
+
}
|
|
82
|
+
return Response.json({ ok: true, cancelled: result.cancelled });
|
|
83
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { after } from 'next/server';
|
|
2
|
+
import { dataDir } from '../../../../lib/db-client';
|
|
3
|
+
import { pendingImport, restartCodeFrom } from '../../../../lib/data-import';
|
|
4
|
+
import { busyRefusal } from '../../../../lib/scan-state';
|
|
5
|
+
|
|
6
|
+
// Restart the server so a staged import finishes. Only the Mac app can do this:
|
|
7
|
+
// its shell (desktop/main.mjs) tells the server which exit code means "start
|
|
8
|
+
// me again", and does. Anywhere else the server is the Terminal's own process,
|
|
9
|
+
// and ending it would just stop the app, so the page says how instead.
|
|
10
|
+
//
|
|
11
|
+
// Gated (lib/gate.js): it stops the server.
|
|
12
|
+
|
|
13
|
+
export async function POST() {
|
|
14
|
+
const code = restartCodeFrom(process.env);
|
|
15
|
+
if (!code) {
|
|
16
|
+
return Response.json(
|
|
17
|
+
{ error: "This copy can't restart itself. Stop it and start it again to finish the import." },
|
|
18
|
+
{ status: 409 },
|
|
19
|
+
);
|
|
20
|
+
}
|
|
21
|
+
if (!pendingImport(dataDir())) {
|
|
22
|
+
return Response.json({ error: 'No import is waiting, so there is nothing to restart for.' }, { status: 409 });
|
|
23
|
+
}
|
|
24
|
+
// The scanner (and Install) runs in its own process group and would outlive
|
|
25
|
+
// the server. The refusal says which is running.
|
|
26
|
+
const busy = busyRefusal('Stop it on the Scan page first, then restart.');
|
|
27
|
+
if (busy) {
|
|
28
|
+
return Response.json({ error: busy }, { status: 409 });
|
|
29
|
+
}
|
|
30
|
+
// After the answer has gone, so the page learns it worked. process.exit and
|
|
31
|
+
// not a signal: Next turns SIGTERM into exit code 143, which the shell would
|
|
32
|
+
// report as a crash.
|
|
33
|
+
after(() => {
|
|
34
|
+
setTimeout(() => process.exit(code), 150);
|
|
35
|
+
});
|
|
36
|
+
return Response.json({ ok: true, restarting: true });
|
|
37
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import path from 'node:path';
|
|
2
|
+
import { dataDir } from '../../../../lib/db-client';
|
|
3
|
+
import { revealFolder } from '../../../../lib/data-folder';
|
|
4
|
+
|
|
5
|
+
// Show the data folder in Finder (or the Linux file browser). It opens the data
|
|
6
|
+
// folder itself and takes nothing from the request. Gated (lib/gate.js) like
|
|
7
|
+
// every route that starts a process.
|
|
8
|
+
|
|
9
|
+
export async function POST() {
|
|
10
|
+
const dir = path.resolve(dataDir());
|
|
11
|
+
const result = await revealFolder(dir);
|
|
12
|
+
if (result.ok) return Response.json({ ok: true });
|
|
13
|
+
return Response.json({ error: `${result.message} The folder is ${dir}` }, { status: 500 });
|
|
14
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import path from 'node:path';
|
|
2
|
+
import { homedir } from 'node:os';
|
|
3
|
+
import { getDb, dataDir, dbFile, AUTO_BACKUP_PREFIX } from '../../../lib/db-client';
|
|
4
|
+
import { folderReport } from '../../../lib/data-folder';
|
|
5
|
+
import { countPeople, referencedPhotos } from '../../../lib/data-export';
|
|
6
|
+
import {
|
|
7
|
+
pendingImport, lastImport, restartCodeFrom, restartAdvice, MAX_IMPORT_BYTES,
|
|
8
|
+
} from '../../../lib/data-import';
|
|
9
|
+
import { projectRoot, isGitCheckout } from '../../../lib/paths';
|
|
10
|
+
import { installKind } from '../../../lib/release';
|
|
11
|
+
|
|
12
|
+
// Settings → Your data: where the network is kept, what it takes up, and any
|
|
13
|
+
// import waiting to finish. Sizes come from the file system; nothing in the
|
|
14
|
+
// folder is read, and chrome-profile/ is only reported as there or not. A read
|
|
15
|
+
// that changes nothing, so it stays open like every other read. The actions
|
|
16
|
+
// live under /api/data/… and are gated (lib/gate.js).
|
|
17
|
+
|
|
18
|
+
export async function GET() {
|
|
19
|
+
try {
|
|
20
|
+
const db = getDb();
|
|
21
|
+
const dir = path.resolve(dataDir());
|
|
22
|
+
// A git checkout is its own kind here, as on the rest of the Settings page.
|
|
23
|
+
const kind = isGitCheckout() ? 'git' : installKind(process.env, projectRoot());
|
|
24
|
+
const custom = dir !== path.join(homedir(), '.six-degrees');
|
|
25
|
+
return Response.json({
|
|
26
|
+
...folderReport({ dir, dbFile: path.resolve(dbFile()), autoPrefix: AUTO_BACKUP_PREFIX, inNetwork: referencedPhotos(db) }),
|
|
27
|
+
people: countPeople(db),
|
|
28
|
+
platform: process.platform,
|
|
29
|
+
kind,
|
|
30
|
+
customDataDir: custom,
|
|
31
|
+
pending: pendingImport(dir),
|
|
32
|
+
lastImport: lastImport(db),
|
|
33
|
+
restart: restartAdvice({ kind, code: restartCodeFrom(process.env), dataDir: custom ? dir : null }),
|
|
34
|
+
maxImportBytes: MAX_IMPORT_BYTES,
|
|
35
|
+
});
|
|
36
|
+
} catch (err) {
|
|
37
|
+
return Response.json({ error: err.message }, { status: 500 });
|
|
38
|
+
}
|
|
39
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { db as supabase } from '../../../lib/db';
|
|
2
|
-
import { uniqueByProfile, splitAlreadyConnected, toIsoDate } from '../../../lib/ingest';
|
|
2
|
+
import { uniqueByProfile, splitAlreadyConnected, toIsoDate, refreshNotifications } from '../../../lib/ingest';
|
|
3
3
|
import { promoteToFirstDegree } from '../../../lib/promote';
|
|
4
4
|
|
|
5
5
|
function parseHeadline(h) {
|
|
@@ -258,55 +258,23 @@ export async function POST(request) {
|
|
|
258
258
|
} catch (e) { /* auto-detect is optional */ }
|
|
259
259
|
}
|
|
260
260
|
|
|
261
|
-
//
|
|
261
|
+
// Notifications for a refresh of your own connections: how many are new,
|
|
262
|
+
// and each new person the model scored S or A (lib/ingest.js
|
|
263
|
+
// refreshNotifications). New is what this request inserted (newRecords);
|
|
264
|
+
// their tiers are the ones the rescore above just stored.
|
|
262
265
|
if (degree === 1 && records.length > 0) {
|
|
263
266
|
try {
|
|
264
|
-
|
|
265
|
-
const
|
|
266
|
-
|
|
267
|
-
.from('linkedin_connections')
|
|
268
|
-
|
|
269
|
-
.
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
if (brandNew.length > 0) {
|
|
274
|
-
// Summary notification
|
|
275
|
-
await supabase.from('notifications').insert([{
|
|
276
|
-
user_id: userId || null,
|
|
277
|
-
type: 'refresh_summary',
|
|
278
|
-
title: `${brandNew.length} new connection${brandNew.length > 1 ? 's' : ''} found!`,
|
|
279
|
-
message: brandNew.slice(0, 3).map(r => r.name).join(', ') + (brandNew.length > 3 ? ` +${brandNew.length - 3} more` : ''),
|
|
280
|
-
icon: '🔄',
|
|
281
|
-
}]);
|
|
282
|
-
|
|
283
|
-
// Individual notifications for S/A tier new connections
|
|
284
|
-
const eliteNew = brandNew.filter(r => {
|
|
285
|
-
const hl = (r.headline || '').toLowerCase();
|
|
286
|
-
return hl.match(/ceo|chief|founder|president|vp|vice president|director|head of/i)
|
|
287
|
-
|| hl.match(/snap|google|meta|apple|amazon|microsoft|blackrock|stripe|palantir/i);
|
|
288
|
-
});
|
|
289
|
-
if (eliteNew.length > 0) {
|
|
290
|
-
await supabase.from('notifications').insert(
|
|
291
|
-
eliteNew.slice(0, 5).map(r => ({
|
|
292
|
-
user_id: userId || null,
|
|
293
|
-
type: 'new_elite_connection',
|
|
294
|
-
title: `High-value connection: ${r.name}`,
|
|
295
|
-
message: r.headline?.substring(0, 60),
|
|
296
|
-
icon: '👑',
|
|
297
|
-
}))
|
|
298
|
-
);
|
|
299
|
-
}
|
|
300
|
-
} else {
|
|
301
|
-
// No new connections found
|
|
302
|
-
await supabase.from('notifications').insert([{
|
|
303
|
-
user_id: userId || null,
|
|
304
|
-
type: 'refresh_summary',
|
|
305
|
-
title: 'Network up to date',
|
|
306
|
-
message: `Checked ${records.length} connections — no new additions`,
|
|
307
|
-
icon: '✓',
|
|
308
|
-
}]);
|
|
267
|
+
const tiers = new Map();
|
|
268
|
+
const added = newRecords.map(r => r.profile_url);
|
|
269
|
+
for (let i = 0; i < added.length; i += 100) {
|
|
270
|
+
let q = supabase.from('linkedin_connections').select('profile_url, tier')
|
|
271
|
+
.in('profile_url', added.slice(i, i + 100)).eq('degree', 1);
|
|
272
|
+
if (userId) q = q.eq('user_id', userId);
|
|
273
|
+
const { data } = await q;
|
|
274
|
+
(data || []).forEach(r => tiers.set(r.profile_url, r.tier));
|
|
309
275
|
}
|
|
276
|
+
const rows = refreshNotifications({ added: newRecords, checked: records.length, tierOf: (url) => tiers.get(url), userId });
|
|
277
|
+
await supabase.from('notifications').insert(rows);
|
|
310
278
|
} catch (e) { /* notifications are optional */ }
|
|
311
279
|
}
|
|
312
280
|
|