oysterun 1.5.7-beta.9 → 1.5.7
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/bin/oysterun.mjs +25 -1
- package/dev/client/connectivity/managed-host-browser.mjs +190 -21
- package/dev/client/web/index.html +1352 -390
- package/dev/client/web-chat/dist/assets/{ReactPrism-BJaS9Dji.js → ReactPrism-C_qvQuWU.js} +1 -1
- package/dev/client/web-chat/dist/assets/{ReactPrism-BJaS9Dji.js.map → ReactPrism-C_qvQuWU.js.map} +1 -1
- package/dev/client/web-chat/dist/assets/{index-DyTV0z1z.css → index-1o8_vyRd.css} +1 -1
- package/dev/client/web-chat/dist/assets/{index-lnzeCpZ2.js → index-B44MyL7f.js} +2 -2
- package/dev/client/web-chat/dist/assets/{index-lnzeCpZ2.js.map → index-B44MyL7f.js.map} +1 -1
- package/dev/client/web-chat/dist/assets/{index-DpdVj04F.js → index-BgxQAT-U.js} +90 -90
- package/dev/client/web-chat/dist/assets/index-BgxQAT-U.js.map +1 -0
- package/dev/client/web-chat/dist/assets/{index-D0XhQM5y.js → index-DdoJ_noi.js} +1 -1
- package/dev/client/web-chat/dist/assets/{index-D0XhQM5y.js.map → index-DdoJ_noi.js.map} +1 -1
- package/dev/client/web-chat/dist/assets/{pdf-HVmRwBUB.js → pdf-DgSk769O.js} +3 -3
- package/dev/client/web-chat/dist/assets/pdf-DgSk769O.js.map +1 -0
- package/dev/client/web-chat/dist/assets/{web-DbxDUTtW.js → web-CIst0rFB.js} +1 -1
- package/dev/client/web-chat/dist/assets/{web-DbxDUTtW.js.map → web-CIst0rFB.js.map} +1 -1
- package/dev/client/web-chat/dist/assets/{web-DMKxO8Wl.js → web-D3DR1arO.js} +1 -1
- package/dev/client/web-chat/dist/assets/{web-DMKxO8Wl.js.map → web-D3DR1arO.js.map} +1 -1
- package/dev/client/web-chat/dist/index.html +2 -2
- package/docs/routec/config_hierachy.md +132 -950
- package/docs/routec/dev/chat_local_link_annotation_pipeline.md +4 -0
- package/docs/routec/dev/cloud_deplyments.md +8 -0
- package/docs/routec/dev/host_update_runtime_identity.md +31 -0
- package/docs/routec/dev/node_runtime_startup.md +14 -3
- package/docs/routec/dev/npmjs_publish.md +36 -24
- package/docs/routec/dev/provider_command_resolution.md +11 -0
- package/docs/routec/form_UI_fields.md +287 -427
- package/docs/routec/host2_turn_started_idempotency_diagnostics.md +91 -105
- package/docs/routec/host_cloud_app_auth.md +102 -203
- package/docs/routec/host_owner_message_navigation.md +126 -93
- package/docs/routec/host_runtime_error_boundary.md +75 -60
- package/docs/routec/host_setup.md +155 -304
- package/docs/routec/hyperlink.md +91 -77
- package/docs/routec/hyperlink_rendering_mechanism.md +57 -315
- package/docs/routec/hyperlink_rendering_rule.md +89 -245
- package/docs/routec/large_tool_event_spillover.md +87 -38
- package/docs/routec/media_upload_image_compression.md +74 -65
- package/docs/routec/oysterun_operation_interface_spec.md +173 -650
- package/docs/routec/prev_page_map.md +101 -85
- package/docs/routec/provider_contract.md +153 -355
- package/docs/routec/skill_installation.md +128 -158
- package/docs/routec/tool_message_transfer_compression.md +43 -69
- package/host-service/adapters/claude-code-adapter.mjs +145 -5
- package/host-service/adapters/codex-app-server-adapter.mjs +34 -0
- package/host-service/agent-config.mjs +90 -22
- package/host-service/assets/product-skills/Oysterun/modules/oysterun-find-context/SKILL.md +15 -2
- package/host-service/assets/product-skills/Oysterun/modules/oysterun-scheduler/SKILL.md +5 -0
- package/host-service/assets/product-skills/Oysterun/modules/oysterun-session-chat/SKILL.md +134 -1
- package/host-service/assets/product-skills/Oysterun/modules/oysterun-sessions/SKILL.md +98 -2
- package/host-service/assets/product-skills/Oysterun/modules/oysterun-telegram/SKILL.md +18 -4
- package/host-service/assets/product-skills/Oysterun/modules/oysterun-website/SKILL.md +184 -21
- package/host-service/assets/product-skills/oysterun-find-context/SKILL.md +15 -2
- package/host-service/assets/product-skills/oysterun-scheduler/SKILL.md +5 -0
- package/host-service/assets/product-skills/oysterun-session-chat/SKILL.md +134 -1
- package/host-service/assets/product-skills/oysterun-sessions/SKILL.md +98 -2
- package/host-service/assets/product-skills/oysterun-telegram/SKILL.md +18 -4
- package/host-service/assets/product-skills/oysterun-website/SKILL.md +184 -21
- package/host-service/claude-acp-model-discovery.mjs +247 -6
- package/host-service/cli/assert-lifecycle-operation-available.mjs +117 -0
- package/host-service/cli/product-cli.mjs +140 -264
- package/host-service/cli/run-host-lifecycle.mjs +133 -0
- package/host-service/config.mjs +116 -26
- package/host-service/connectivity/cloud-retry-decision.mjs +57 -0
- package/host-service/connectivity/managed-tunnel-runtime-status.mjs +11 -0
- package/host-service/connectivity/retry-policy.json +9 -0
- package/host-service/connectivity/transport-usage-circuit-store.mjs +161 -0
- package/host-service/connectivity/webrtc-signaling-service.mjs +172 -33
- package/host-service/frp-agent.mjs +58 -0
- package/host-service/host-lifecycle-recovery.mjs +196 -0
- package/host-service/host-runtime-diagnostics.mjs +32 -0
- package/host-service/managed-identity-lifecycle.mjs +165 -0
- package/host-service/matrix-transcript-read-adapter.mjs +176 -0
- package/host-service/node-npm-runtime-identity.mjs +349 -7
- package/host-service/package.json +11 -2
- package/host-service/provider-registry.mjs +47 -0
- package/host-service/registered-update-authority.mjs +368 -0
- package/host-service/routec-matrix-storage-adapter.mjs +68 -4
- package/host-service/scheduler-setup-snapshot-contract.mjs +16 -2
- package/host-service/server.mjs +2761 -329
- package/host-service/session-history.mjs +3 -0
- package/host-service/session-manager.mjs +41 -4
- package/host-service/session-profile-runtime.mjs +54 -0
- package/host-service/setup.mjs +155 -82
- package/host-service/telegram-adapter.mjs +33 -0
- package/host-service/telegram-bridge.mjs +673 -190
- package/host-service/templates/agent-site/index.html +17 -1
- package/host-service/update-reminder-state.mjs +353 -0
- package/host-service/website-canonical-url.mjs +220 -0
- package/package.json +6 -1
- package/static/site/404/en/index.html +75 -0
- package/static/site/404/zh/index.html +75 -0
- package/static/site/assets/site.css +489 -0
- package/static/site/blog/en/index.html +92 -0
- package/static/site/blog/en/index.md +9 -0
- package/static/site/blog/generated_manifest.json +22 -10
- package/static/site/blog/index.html +18 -55
- package/static/site/blog/voice-input-model-experiment/en/index.html +55 -18
- package/static/site/blog/voice-input-model-experiment/en/index.md +1211 -0
- package/static/site/blog/voice-input-model-experiment/zh/index.html +59 -92
- package/static/site/blog/voice-input-model-experiment/zh/index.md +1220 -0
- package/static/site/blog/zh/index.html +92 -0
- package/static/site/blog/zh/index.md +9 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/article.css +104 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/codex-login-required.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/codex-recovered.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/publication/provider-command-unavailable.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/publication/provider-login-required.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/publication/provider-ready-after-restart.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/publication/provider-refresh-ready.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/publication/provider-restart-menu.png +0 -0
- package/static/site/docs/choose-and-recover-a-provider/assets/publication-screenshots.json +150 -0
- package/static/site/docs/choose-and-recover-a-provider/en/index.html +474 -0
- package/static/site/docs/choose-and-recover-a-provider/en/index.md +174 -0
- package/static/site/docs/choose-and-recover-a-provider/zh/index.html +474 -0
- package/static/site/docs/choose-and-recover-a-provider/zh/index.md +174 -0
- package/static/site/docs/configure-session-files-and-settings/assets/article.css +92 -0
- package/static/site/docs/configure-session-files-and-settings/assets/publication/folder-picker-focused.png +0 -0
- package/static/site/docs/configure-session-files-and-settings/assets/publication/session-profile-root.png +0 -0
- package/static/site/docs/configure-session-files-and-settings/assets/publication/session-setup-confirmed.png +0 -0
- package/static/site/docs/configure-session-files-and-settings/assets/publication-screenshots.json +100 -0
- package/static/site/docs/configure-session-files-and-settings/en/index.html +456 -0
- package/static/site/docs/configure-session-files-and-settings/en/index.md +130 -0
- package/static/site/docs/configure-session-files-and-settings/zh/index.html +456 -0
- package/static/site/docs/configure-session-files-and-settings/zh/index.md +132 -0
- package/static/site/docs/en/index.html +174 -0
- package/static/site/docs/en/index.md +31 -0
- package/static/site/docs/generated_manifest.json +720 -0
- package/static/site/docs/host-authentication-and-connection/assets/article.css +80 -0
- package/static/site/docs/host-authentication-and-connection/assets/publication/invalid-credentials-empty-password.png +0 -0
- package/static/site/docs/host-authentication-and-connection/assets/publication/password-sign-in.png +0 -0
- package/static/site/docs/host-authentication-and-connection/assets/publication/sessions-connected-direct-host.png +0 -0
- package/static/site/docs/host-authentication-and-connection/assets/publication-screenshots.json +100 -0
- package/static/site/docs/host-authentication-and-connection/en/index.html +429 -0
- package/static/site/docs/host-authentication-and-connection/en/index.md +108 -0
- package/static/site/docs/host-authentication-and-connection/zh/index.html +429 -0
- package/static/site/docs/host-authentication-and-connection/zh/index.md +110 -0
- package/static/site/docs/index.html +28 -0
- package/static/site/docs/install-and-use-a-skill/assets/article.css +141 -0
- package/static/site/docs/install-and-use-a-skill/assets/publication/skill-helper-draft.jpg +0 -0
- package/static/site/docs/install-and-use-a-skill/assets/publication/skill-read-only-result.jpg +0 -0
- package/static/site/docs/install-and-use-a-skill/assets/publication/skill-state-menu.jpg +0 -0
- package/static/site/docs/install-and-use-a-skill/assets/publication/skill-update-result.jpg +0 -0
- package/static/site/docs/install-and-use-a-skill/assets/publication/update-result.png +0 -0
- package/static/site/docs/install-and-use-a-skill/assets/publication-screenshots.json +122 -0
- package/static/site/docs/install-and-use-a-skill/en/index.html +484 -0
- package/static/site/docs/install-and-use-a-skill/en/index.md +233 -0
- package/static/site/docs/install-and-use-a-skill/zh/index.html +484 -0
- package/static/site/docs/install-and-use-a-skill/zh/index.md +233 -0
- package/static/site/docs/llms.txt +40 -0
- package/static/site/docs/read-large-tool-results/assets/article.css +132 -0
- package/static/site/docs/read-large-tool-results/assets/publication/oversized-result.jpg +0 -0
- package/static/site/docs/read-large-tool-results/assets/publication/tool-detail-page-two.jpg +0 -0
- package/static/site/docs/read-large-tool-results/assets/publication/tool-row-after-close.jpg +0 -0
- package/static/site/docs/read-large-tool-results/assets/publication/tool-row-view-details.jpg +0 -0
- package/static/site/docs/read-large-tool-results/assets/publication-screenshots.json +130 -0
- package/static/site/docs/read-large-tool-results/en/index.html +443 -0
- package/static/site/docs/read-large-tool-results/en/index.md +176 -0
- package/static/site/docs/read-large-tool-results/zh/index.html +443 -0
- package/static/site/docs/read-large-tool-results/zh/index.md +176 -0
- package/static/site/docs/recover-from-a-host-runtime-error/assets/article.css +104 -0
- package/static/site/docs/recover-from-a-host-runtime-error/assets/publication/recovered-chat.png +0 -0
- package/static/site/docs/recover-from-a-host-runtime-error/assets/publication/runtime-error.png +0 -0
- package/static/site/docs/recover-from-a-host-runtime-error/assets/publication-screenshots.json +70 -0
- package/static/site/docs/recover-from-a-host-runtime-error/en/index.html +453 -0
- package/static/site/docs/recover-from-a-host-runtime-error/en/index.md +142 -0
- package/static/site/docs/recover-from-a-host-runtime-error/zh/index.html +453 -0
- package/static/site/docs/recover-from-a-host-runtime-error/zh/index.md +142 -0
- package/static/site/docs/restore-work-after-a-host-restart/assets/article.css +63 -0
- package/static/site/docs/restore-work-after-a-host-restart/assets/publication/loop-disabled-after-restart.png +0 -0
- package/static/site/docs/restore-work-after-a-host-restart/assets/publication/restart-control.png +0 -0
- package/static/site/docs/restore-work-after-a-host-restart/assets/publication/restart-ready-sign-in.png +0 -0
- package/static/site/docs/restore-work-after-a-host-restart/assets/publication/restored-checkpoint.png +0 -0
- package/static/site/docs/restore-work-after-a-host-restart/assets/publication-screenshots.json +130 -0
- package/static/site/docs/restore-work-after-a-host-restart/en/index.html +444 -0
- package/static/site/docs/restore-work-after-a-host-restart/en/index.md +110 -0
- package/static/site/docs/restore-work-after-a-host-restart/zh/index.html +444 -0
- package/static/site/docs/restore-work-after-a-host-restart/zh/index.md +110 -0
- package/static/site/docs/search-index.json +273 -0
- package/static/site/docs/send-images-and-media/assets/article.css +132 -0
- package/static/site/docs/send-images-and-media/assets/publication/safe-image-viewer.jpg +0 -0
- package/static/site/docs/send-images-and-media/assets/publication/sent-ordered-group.jpg +0 -0
- package/static/site/docs/send-images-and-media/assets/publication/staged-ordered-group.jpg +0 -0
- package/static/site/docs/send-images-and-media/assets/publication-screenshots.json +100 -0
- package/static/site/docs/send-images-and-media/en/index.html +468 -0
- package/static/site/docs/send-images-and-media/en/index.md +152 -0
- package/static/site/docs/send-images-and-media/zh/index.html +468 -0
- package/static/site/docs/send-images-and-media/zh/index.md +152 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/article.css +104 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication/host-identity-browse-root.png +0 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication/host-setup-managed-ready.png +0 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication/host-setup-seven-steps.png +0 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication/session-profile-identity.png +0 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication/session-setup-identity.png +0 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication/website-link.png +0 -0
- package/static/site/docs/set-up-and-understand-a-host/assets/publication-screenshots.json +178 -0
- package/static/site/docs/set-up-and-understand-a-host/en/index.html +519 -0
- package/static/site/docs/set-up-and-understand-a-host/en/index.md +211 -0
- package/static/site/docs/set-up-and-understand-a-host/zh/index.html +519 -0
- package/static/site/docs/set-up-and-understand-a-host/zh/index.md +211 -0
- package/static/site/docs/understand-agent-activity/assets/article.css +154 -0
- package/static/site/docs/understand-agent-activity/assets/publication/session-available.png +0 -0
- package/static/site/docs/understand-agent-activity/assets/publication/turn-occupied.png +0 -0
- package/static/site/docs/understand-agent-activity/assets/publication/turn-terminal.png +0 -0
- package/static/site/docs/understand-agent-activity/assets/publication-screenshots.json +100 -0
- package/static/site/docs/understand-agent-activity/en/index.html +441 -0
- package/static/site/docs/understand-agent-activity/en/index.md +146 -0
- package/static/site/docs/understand-agent-activity/zh/index.html +441 -0
- package/static/site/docs/understand-agent-activity/zh/index.md +146 -0
- package/static/site/docs/use-the-oysterun-cli-safely/assets/article.css +138 -0
- package/static/site/docs/use-the-oysterun-cli-safely/assets/publication/cli-post-status.jpg +0 -0
- package/static/site/docs/use-the-oysterun-cli-safely/assets/publication/cli-protected-dry-run.jpg +0 -0
- package/static/site/docs/use-the-oysterun-cli-safely/assets/publication/cli-supported-modules.jpg +0 -0
- package/static/site/docs/use-the-oysterun-cli-safely/assets/publication/cli-target-read.jpg +0 -0
- package/static/site/docs/use-the-oysterun-cli-safely/assets/publication-screenshots.json +122 -0
- package/static/site/docs/use-the-oysterun-cli-safely/en/index.html +499 -0
- package/static/site/docs/use-the-oysterun-cli-safely/en/index.md +548 -0
- package/static/site/docs/use-the-oysterun-cli-safely/zh/index.html +499 -0
- package/static/site/docs/use-the-oysterun-cli-safely/zh/index.md +548 -0
- package/static/site/docs/zh/index.html +174 -0
- package/static/site/docs/zh/index.md +31 -0
- package/static/site/en/index.html +227 -0
- package/static/site/en/index.md +33 -0
- package/static/site/faq/en/index.html +116 -0
- package/static/site/faq/en/index.md +33 -0
- package/static/site/faq/index.html +28 -0
- package/static/site/faq/zh/index.html +116 -0
- package/static/site/faq/zh/index.md +33 -0
- package/static/site/getting-started/en/index.html +131 -0
- package/static/site/getting-started/en/index.md +18 -0
- package/static/site/getting-started/index.html +28 -0
- package/static/site/getting-started/zh/index.html +131 -0
- package/static/site/getting-started/zh/index.md +18 -0
- package/static/site/index.html +14 -1187
- package/static/site/llms.txt +25 -0
- package/static/site/overview/en/index.html +87 -0
- package/static/site/overview/en/index.md +36 -0
- package/static/site/overview/index.html +28 -0
- package/static/site/overview/zh/index.html +87 -0
- package/static/site/overview/zh/index.md +36 -0
- package/static/site/privacy/en/index.html +124 -0
- package/static/site/privacy/en/index.md +45 -0
- package/static/site/privacy/index.html +18 -171
- package/static/site/privacy/zh/index.html +124 -0
- package/static/site/privacy/zh/index.md +45 -0
- package/static/site/robots.txt +3 -0
- package/static/site/sitemap.xml +193 -0
- package/static/site/zh/index.html +227 -0
- package/static/site/zh/index.md +33 -0
- package/static/site_source/content/AGENTS.md +9 -2
- package/static/site_source/content/blog/published/voice-input-model-experiment/zh/article.html +0 -70
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/article.css +92 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/build-complete.png +0 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/cover.svg +39 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/empty-project.png +0 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/natural-language-prompt.png +0 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/web-catalog-owner-only.png +0 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/assets/website-result.png +0 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/content.json +33 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/en/article.html +116 -0
- package/static/site_source/content/tutorials/drafts/build-a-website-with-natural-language/zh/article.html +116 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/assets/article.css +87 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/assets/cover.svg +41 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/assets/publication/previous-result.png +0 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/assets/publication/returned-source.png +0 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/assets/publication/source-message.png +0 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/content.json +34 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/en/article.html +91 -0
- package/static/site_source/content/tutorials/drafts/find-and-return-to-a-message/zh/article.html +91 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/assets/article.css +87 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/assets/cover.svg +55 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/assets/publication/jump-to-latest.png +0 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/assets/publication/live-output-arriving.png +0 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/assets/publication/older-position-stable.png +0 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/content.json +34 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/en/article.html +91 -0
- package/static/site_source/content/tutorials/drafts/follow-live-chat-output/zh/article.html +91 -0
- package/static/site_source/content/tutorials/drafts/getting-started/assets/article.css +50 -0
- package/static/site_source/content/tutorials/drafts/getting-started/content.json +10 -4
- package/static/site_source/content/tutorials/drafts/getting-started/en/article.html +109 -132
- package/static/site_source/content/tutorials/drafts/getting-started/zh/article.html +120 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/article.css +91 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/cover.svg +48 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/publication/file-preview-safe.png +0 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/publication/local-link-confirmed.png +0 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/publication/returned-source-session.png +0 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/publication/source-links.png +0 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/assets/publication-screenshots.json +130 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/content.json +34 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/en/article.html +111 -0
- package/static/site_source/content/tutorials/drafts/open-links-safely/zh/article.html +111 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/article.css +87 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/cover.svg +53 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/publication/pin-menu.png +0 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/publication/pinned-focus.png +0 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/publication/pinned-list.png +0 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/publication/previous-page.png +0 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/assets/publication-screenshots.json +130 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/content.json +34 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/en/article.html +123 -0
- package/static/site_source/content/tutorials/drafts/pin-and-return-to-messages/zh/article.html +123 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/assets/article.css +87 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/assets/cover.svg +50 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/assets/publication/connection-lost.png +0 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/assets/publication/reconnecting.png +0 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/assets/publication/recovered.png +0 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/assets/publication-screenshots.json +94 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/content.json +34 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/en/article.html +102 -0
- package/static/site_source/content/tutorials/drafts/recover-delayed-chat-sync/zh/article.html +102 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/article.css +92 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/cover.svg +39 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/empty-project.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/latest-report.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/natural-language-prompt.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/no-runs.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/run-history-pass.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/run-log.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/assets/test-run-prompt.png +0 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/content.json +33 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/en/article.html +124 -0
- package/static/site_source/content/tutorials/drafts/schedule-agent-work-with-natural-language/zh/article.html +124 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/assets/article.css +105 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/assets/cover.svg +44 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/assets/publication/markdown-correction.png +0 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/assets/publication/markdown-rendered.png +0 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/assets/publication/markdown-source.png +0 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/content.json +34 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/en/article.html +104 -0
- package/static/site_source/content/tutorials/drafts/write-markdown-in-chat/zh/article.html +104 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/article.css +104 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/codex-login-required.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/codex-recovered.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/publication/provider-command-unavailable.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/publication/provider-login-required.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/publication/provider-ready-after-restart.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/publication/provider-refresh-ready.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/publication/provider-restart-menu.png +0 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/assets/publication-screenshots.json +150 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/content.json +23 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/en/article.html +141 -0
- package/static/site_source/content/tutorials/published/choose-and-recover-a-provider/zh/article.html +141 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/assets/article.css +92 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/assets/publication/folder-picker-focused.png +0 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/assets/publication/session-profile-root.png +0 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/assets/publication/session-setup-confirmed.png +0 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/content.json +23 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/en/article.html +126 -0
- package/static/site_source/content/tutorials/published/configure-session-files-and-settings/zh/article.html +126 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/assets/article.css +80 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/assets/publication/invalid-credentials-empty-password.png +0 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/assets/publication/password-sign-in.png +0 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/assets/publication/sessions-connected-direct-host.png +0 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/content.json +23 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/en/article.html +101 -0
- package/static/site_source/content/tutorials/published/host-authentication-and-connection/zh/article.html +101 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/article.css +141 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/cover.svg +59 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/publication/skill-helper-draft.jpg +0 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/publication/skill-read-only-result.jpg +0 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/publication/skill-state-menu.jpg +0 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/publication/skill-update-result.jpg +0 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/publication/update-result.png +0 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/assets/publication-screenshots.json +122 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/content.json +34 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/en/article.html +155 -0
- package/static/site_source/content/tutorials/published/install-and-use-a-skill/zh/article.html +155 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/assets/article.css +132 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/assets/publication/oversized-result.jpg +0 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/assets/publication/tool-detail-page-two.jpg +0 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/assets/publication/tool-row-after-close.jpg +0 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/assets/publication/tool-row-view-details.jpg +0 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/assets/publication-screenshots.json +130 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/content.json +23 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/en/article.html +116 -0
- package/static/site_source/content/tutorials/published/read-large-tool-results/zh/article.html +116 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/assets/article.css +104 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/assets/publication/recovered-chat.png +0 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/assets/publication/runtime-error.png +0 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/assets/publication-screenshots.json +70 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/content.json +23 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/en/article.html +122 -0
- package/static/site_source/content/tutorials/published/recover-from-a-host-runtime-error/zh/article.html +122 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/assets/article.css +63 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/assets/publication/loop-disabled-after-restart.png +0 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/assets/publication/restart-control.png +0 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/assets/publication/restart-ready-sign-in.png +0 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/assets/publication/restored-checkpoint.png +0 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/assets/publication-screenshots.json +130 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/content.json +23 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/en/article.html +117 -0
- package/static/site_source/content/tutorials/published/restore-work-after-a-host-restart/zh/article.html +117 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/assets/article.css +132 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/assets/publication/safe-image-viewer.jpg +0 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/assets/publication/sent-ordered-group.jpg +0 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/assets/publication/staged-ordered-group.jpg +0 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/content.json +23 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/en/article.html +141 -0
- package/static/site_source/content/tutorials/published/send-images-and-media/zh/article.html +141 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/article.css +104 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication/host-identity-browse-root.png +0 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication/host-setup-managed-ready.png +0 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication/host-setup-seven-steps.png +0 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication/session-profile-identity.png +0 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication/session-setup-identity.png +0 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication/website-link.png +0 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/assets/publication-screenshots.json +178 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/content.json +23 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/en/article.html +177 -0
- package/static/site_source/content/tutorials/published/set-up-and-understand-a-host/zh/article.html +177 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/assets/article.css +154 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/assets/publication/session-available.png +0 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/assets/publication/turn-occupied.png +0 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/assets/publication/turn-terminal.png +0 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/assets/publication-screenshots.json +100 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/content.json +23 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/en/article.html +114 -0
- package/static/site_source/content/tutorials/published/understand-agent-activity/zh/article.html +114 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/assets/article.css +138 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/assets/publication/cli-post-status.jpg +0 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/assets/publication/cli-protected-dry-run.jpg +0 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/assets/publication/cli-supported-modules.jpg +0 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/assets/publication/cli-target-read.jpg +0 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/assets/publication-screenshots.json +122 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/content.json +23 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/en/article.html +170 -0
- package/static/site_source/content/tutorials/published/use-the-oysterun-cli-safely/zh/article.html +170 -0
- package/static/site_source/manifests/docs_taxonomy.json +126 -0
- package/static/site_source/manifests/public_site.json +230 -0
- package/static/site_source/pages/blog/en.html +1 -0
- package/static/site_source/pages/blog/zh.html +1 -0
- package/static/site_source/pages/docs/en.html +1 -0
- package/static/site_source/pages/docs/zh.html +1 -0
- package/static/site_source/pages/faq/en.html +35 -0
- package/static/site_source/pages/faq/zh.html +35 -0
- package/static/site_source/pages/getting-started/en.html +50 -0
- package/static/site_source/pages/getting-started/zh.html +50 -0
- package/static/site_source/pages/home/en.html +19 -0
- package/static/site_source/pages/home/zh.html +19 -0
- package/static/site_source/pages/overview/en.html +6 -0
- package/static/site_source/pages/overview/zh.html +6 -0
- package/static/site_source/pages/privacy/en.html +43 -0
- package/static/site_source/pages/privacy/zh.html +43 -0
- package/static/site_source/shared/home_analytics.html +127 -0
- package/tool_scripts/install_oysterun_launch_agents.sh +57 -0
- package/tool_scripts/install_oysterun_update.mjs +76 -13
- package/tool_scripts/oysterun_npm_package_manifest.mjs +5 -0
- package/tool_scripts/oysterun_release_service.sh +119 -24
- package/tool_scripts/oysterun_service_common.sh +556 -23
- package/tool_scripts/oysterun_update_restart_runner.mjs +440 -17
- package/tool_scripts/preflight_oysterun_restart.sh +45 -0
- package/tool_scripts/restart_oysterun.sh +43 -2
- package/tool_scripts/run_oysterun_host.sh +15 -5
- package/tool_scripts/start_oysterun.sh +15 -5
- package/dev/client/web-chat/dist/assets/index-DpdVj04F.js.map +0 -1
- package/dev/client/web-chat/dist/assets/pdf-HVmRwBUB.js.map +0 -1
- package/static/site/content/blog/drafts/20260718-24hr-agent-team/assets/article.css +0 -31
- package/static/site/content/blog/drafts/20260718-24hr-agent-team/assets/cover.svg +0 -24
- package/static/site/content/blog/drafts/20260718-24hr-agent-team/zh/index.html +0 -224
- package/static/site/content/blog/drafts/generated_manifest.json +0 -37
- package/static/site/content/tutorials/drafts/generated_manifest.json +0 -49
- package/static/site/content/tutorials/drafts/getting-started/assets/AppStore.png +0 -0
- package/static/site/content/tutorials/drafts/getting-started/assets/article.css +0 -31
- package/static/site/content/tutorials/drafts/getting-started/assets/chat.png +0 -0
- package/static/site/content/tutorials/drafts/getting-started/assets/cover.svg +0 -24
- package/static/site/content/tutorials/drafts/getting-started/en/index.html +0 -360
- package/static/site/tutorial/generated_manifest.json +0 -13
- package/static/site/tutorial/index.html +0 -54
package/bin/oysterun.mjs
CHANGED
|
@@ -29,6 +29,11 @@ const serviceCommands = new Map([
|
|
|
29
29
|
["service:start", "start"],
|
|
30
30
|
["service:stop", "stop"],
|
|
31
31
|
["service:restart", "restart"],
|
|
32
|
+
["service:update", "update"],
|
|
33
|
+
["service:complete-update", "complete-update"],
|
|
34
|
+
["service:repair", "repair"],
|
|
35
|
+
["service:restore", "restore"],
|
|
36
|
+
["service:lifecycle-status", "lifecycle-status"],
|
|
32
37
|
["service:status", "status"],
|
|
33
38
|
["service:logs", "logs"],
|
|
34
39
|
["service:uninstall", "uninstall"],
|
|
@@ -55,7 +60,21 @@ function runSetup(args = []) {
|
|
|
55
60
|
}
|
|
56
61
|
|
|
57
62
|
function runService(command, args = []) {
|
|
58
|
-
|
|
63
|
+
const result = spawnSync(releaseServiceScript, [command, ...args], {
|
|
64
|
+
cwd: repoRoot,
|
|
65
|
+
env: {
|
|
66
|
+
...process.env,
|
|
67
|
+
OYSTERUN_BOOTSTRAP_NODE_BIN: process.execPath,
|
|
68
|
+
},
|
|
69
|
+
stdio: "inherit",
|
|
70
|
+
});
|
|
71
|
+
if (result.error) {
|
|
72
|
+
console.error(
|
|
73
|
+
`oysterun: failed to run ${releaseServiceScript}: ${result.error.message}`
|
|
74
|
+
);
|
|
75
|
+
process.exit(1);
|
|
76
|
+
}
|
|
77
|
+
process.exit(result.status ?? 0);
|
|
59
78
|
}
|
|
60
79
|
|
|
61
80
|
function parseUninstallArgs(args = []) {
|
|
@@ -181,6 +200,11 @@ Usage:
|
|
|
181
200
|
oysterun service:start
|
|
182
201
|
oysterun service:stop
|
|
183
202
|
oysterun service:restart [--restore-sessions]
|
|
203
|
+
oysterun service:update --channel latest|beta
|
|
204
|
+
oysterun service:complete-update
|
|
205
|
+
oysterun service:repair
|
|
206
|
+
oysterun service:restore
|
|
207
|
+
oysterun service:lifecycle-status
|
|
184
208
|
oysterun service:status
|
|
185
209
|
oysterun service:logs [--follow]
|
|
186
210
|
oysterun service:uninstall [--stack production|staging|all]
|
|
@@ -11,6 +11,7 @@ const REQUIRED_CHANNELS = Object.freeze(["control", "events", "bulk"]);
|
|
|
11
11
|
const SUPPORTED_TRANSPORT_PROTOCOL_VERSIONS = Object.freeze([1]);
|
|
12
12
|
const MANAGED_TRANSPORT_CONTRACT = "oysterun.managed_webrtc.v1";
|
|
13
13
|
const SIGNALING_TIMEOUT_MS = 20_000;
|
|
14
|
+
const MANAGED_ICE_CANDIDATE_SETTLE_MS = 100;
|
|
14
15
|
const BOOTSTRAP_SAFE_REQUEST_TIMEOUT_MS = 12_000;
|
|
15
16
|
const BOOTSTRAP_MATRIX_SYNC_TIMEOUT_MS = 45_000;
|
|
16
17
|
const PRESENCE_WAIT_SECONDS = 55;
|
|
@@ -553,20 +554,161 @@ function fingerprintFromSdp(sdp) {
|
|
|
553
554
|
return compact;
|
|
554
555
|
}
|
|
555
556
|
|
|
556
|
-
function
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
557
|
+
function managedWebRtcAttemptError(code, message) {
|
|
558
|
+
const error = new Error(message);
|
|
559
|
+
error.code = code;
|
|
560
|
+
return error;
|
|
561
|
+
}
|
|
562
|
+
|
|
563
|
+
function signalingCandidateToJson(candidate) {
|
|
564
|
+
if (
|
|
565
|
+
!candidate ||
|
|
566
|
+
typeof candidate.candidate !== "string" ||
|
|
567
|
+
!candidate.candidate.trim()
|
|
568
|
+
) {
|
|
569
|
+
return null;
|
|
570
|
+
}
|
|
571
|
+
return candidateToJson(candidate);
|
|
572
|
+
}
|
|
573
|
+
|
|
574
|
+
function createManagedIceCandidateReadiness(
|
|
575
|
+
peer,
|
|
576
|
+
{
|
|
577
|
+
assertCurrentAttempt,
|
|
578
|
+
settleMs = MANAGED_ICE_CANDIDATE_SETTLE_MS,
|
|
579
|
+
timeoutMs = SIGNALING_TIMEOUT_MS,
|
|
580
|
+
} = {}
|
|
581
|
+
) {
|
|
582
|
+
if (typeof assertCurrentAttempt !== "function") {
|
|
583
|
+
throw new Error("Managed ICE readiness requires an attempt owner");
|
|
584
|
+
}
|
|
585
|
+
const candidates = [];
|
|
586
|
+
const readiness = deferred();
|
|
587
|
+
let waitStarted = false;
|
|
588
|
+
let settled = false;
|
|
589
|
+
let settleTimer = null;
|
|
590
|
+
let timeoutTimer = null;
|
|
591
|
+
|
|
592
|
+
// A candidate or peer-close callback can reject between setLocalDescription
|
|
593
|
+
// and wait(). Keep that attempt-owned rejection observed until the caller
|
|
594
|
+
// reaches the browser_ice_gathering stage.
|
|
595
|
+
void readiness.promise.catch(() => {});
|
|
596
|
+
|
|
597
|
+
const cleanup = () => {
|
|
598
|
+
if (settleTimer !== null) {
|
|
599
|
+
clearTimeout(settleTimer);
|
|
600
|
+
settleTimer = null;
|
|
601
|
+
}
|
|
602
|
+
if (timeoutTimer !== null) {
|
|
603
|
+
clearTimeout(timeoutTimer);
|
|
604
|
+
timeoutTimer = null;
|
|
605
|
+
}
|
|
606
|
+
peer.removeEventListener("icecandidate", handleCandidate);
|
|
607
|
+
peer.removeEventListener("icegatheringstatechange", handleGatheringChange);
|
|
608
|
+
peer.removeEventListener("connectionstatechange", handleConnectionChange);
|
|
609
|
+
};
|
|
610
|
+
const reject = (error) => {
|
|
611
|
+
if (settled) return false;
|
|
612
|
+
settled = true;
|
|
613
|
+
cleanup();
|
|
614
|
+
readiness.reject(error);
|
|
615
|
+
return true;
|
|
616
|
+
};
|
|
617
|
+
const resolve = () => {
|
|
618
|
+
if (settled) return false;
|
|
619
|
+
try {
|
|
620
|
+
assertCurrentAttempt(peer);
|
|
621
|
+
} catch (error) {
|
|
622
|
+
return reject(error);
|
|
623
|
+
}
|
|
624
|
+
if (candidates.length === 0) return false;
|
|
625
|
+
settled = true;
|
|
626
|
+
cleanup();
|
|
627
|
+
readiness.resolve(candidates);
|
|
628
|
+
return true;
|
|
629
|
+
};
|
|
630
|
+
const startSettle = () => {
|
|
631
|
+
if (settled || settleTimer !== null) return;
|
|
632
|
+
settleTimer = setTimeout(resolve, settleMs);
|
|
633
|
+
};
|
|
634
|
+
function handleCandidate(event) {
|
|
635
|
+
if (settled) return;
|
|
636
|
+
try {
|
|
637
|
+
assertCurrentAttempt(peer);
|
|
638
|
+
} catch (error) {
|
|
639
|
+
reject(error);
|
|
640
|
+
return;
|
|
641
|
+
}
|
|
642
|
+
const candidate = signalingCandidateToJson(event.candidate);
|
|
643
|
+
if (!candidate) return;
|
|
644
|
+
candidates.push(candidate);
|
|
645
|
+
if (peer.iceGatheringState === "complete") {
|
|
646
|
+
resolve();
|
|
647
|
+
return;
|
|
648
|
+
}
|
|
649
|
+
startSettle();
|
|
650
|
+
}
|
|
651
|
+
function handleGatheringChange() {
|
|
652
|
+
if (settled || peer.iceGatheringState !== "complete") return;
|
|
653
|
+
resolve();
|
|
654
|
+
}
|
|
655
|
+
function handleConnectionChange() {
|
|
656
|
+
if (settled || peer.connectionState !== "closed") return;
|
|
657
|
+
reject(
|
|
658
|
+
managedWebRtcAttemptError(
|
|
659
|
+
"managed_webrtc_attempt_cancelled",
|
|
660
|
+
"Managed WebRTC connect attempt was cancelled"
|
|
661
|
+
)
|
|
662
|
+
);
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
peer.addEventListener("icecandidate", handleCandidate);
|
|
666
|
+
peer.addEventListener("icegatheringstatechange", handleGatheringChange);
|
|
667
|
+
peer.addEventListener("connectionstatechange", handleConnectionChange);
|
|
668
|
+
|
|
669
|
+
return {
|
|
670
|
+
peer,
|
|
671
|
+
candidates,
|
|
672
|
+
wait() {
|
|
673
|
+
if (!waitStarted) {
|
|
674
|
+
waitStarted = true;
|
|
675
|
+
try {
|
|
676
|
+
assertCurrentAttempt(peer);
|
|
677
|
+
} catch (error) {
|
|
678
|
+
reject(error);
|
|
679
|
+
return readiness.promise;
|
|
680
|
+
}
|
|
681
|
+
if (peer.iceGatheringState === "complete" && candidates.length > 0) {
|
|
682
|
+
resolve();
|
|
683
|
+
} else if (!settled) {
|
|
684
|
+
timeoutTimer = setTimeout(
|
|
685
|
+
() =>
|
|
686
|
+
reject(
|
|
687
|
+
new Error("Browser ICE candidate gathering timed out")
|
|
688
|
+
),
|
|
689
|
+
timeoutMs
|
|
690
|
+
);
|
|
691
|
+
}
|
|
692
|
+
}
|
|
693
|
+
return readiness.promise;
|
|
694
|
+
},
|
|
695
|
+
cancel(error) {
|
|
696
|
+
reject(
|
|
697
|
+
error ||
|
|
698
|
+
managedWebRtcAttemptError(
|
|
699
|
+
"managed_webrtc_attempt_cancelled",
|
|
700
|
+
"Managed WebRTC connect attempt was cancelled"
|
|
701
|
+
)
|
|
702
|
+
);
|
|
703
|
+
},
|
|
704
|
+
dispose() {
|
|
705
|
+
if (!settled) {
|
|
706
|
+
this.cancel();
|
|
707
|
+
} else {
|
|
708
|
+
cleanup();
|
|
709
|
+
}
|
|
710
|
+
},
|
|
711
|
+
};
|
|
570
712
|
}
|
|
571
713
|
|
|
572
714
|
function waitForPeerReady(peer, channels) {
|
|
@@ -971,6 +1113,7 @@ export class ManagedHostBrowserConnection {
|
|
|
971
1113
|
});
|
|
972
1114
|
this.peer = null;
|
|
973
1115
|
this.connectingPeer = null;
|
|
1116
|
+
this.pendingIceCandidateReadiness = null;
|
|
974
1117
|
this.webRtcTransport = null;
|
|
975
1118
|
this.activeConnection = null;
|
|
976
1119
|
this.iceTransportPolicy = "all";
|
|
@@ -1310,6 +1453,15 @@ export class ManagedHostBrowserConnection {
|
|
|
1310
1453
|
reconciliationEpoch = this.reconciliationOwner.status().epoch,
|
|
1311
1454
|
lifecycleReason = "initial_start",
|
|
1312
1455
|
} = {}) {
|
|
1456
|
+
if (this.pendingIceCandidateReadiness) {
|
|
1457
|
+
this.pendingIceCandidateReadiness.cancel(
|
|
1458
|
+
managedWebRtcAttemptError(
|
|
1459
|
+
"managed_webrtc_stale_connect_attempt",
|
|
1460
|
+
"Managed WebRTC connect attempt was replaced"
|
|
1461
|
+
)
|
|
1462
|
+
);
|
|
1463
|
+
this.pendingIceCandidateReadiness = null;
|
|
1464
|
+
}
|
|
1313
1465
|
const connectionGeneration = ++this.connectionGeneration;
|
|
1314
1466
|
const connectionAttemptId = createConnectivityRandomId();
|
|
1315
1467
|
const attempt = {
|
|
@@ -1364,6 +1516,7 @@ export class ManagedHostBrowserConnection {
|
|
|
1364
1516
|
iceTransportPolicy,
|
|
1365
1517
|
});
|
|
1366
1518
|
this.connectingPeer = peer;
|
|
1519
|
+
let iceCandidateReadiness = null;
|
|
1367
1520
|
try {
|
|
1368
1521
|
const channels = Object.fromEntries(
|
|
1369
1522
|
REQUIRED_CHANNELS.map((name) => [
|
|
@@ -1374,19 +1527,20 @@ export class ManagedHostBrowserConnection {
|
|
|
1374
1527
|
for (const channel of Object.values(channels)) {
|
|
1375
1528
|
channel.binaryType = "arraybuffer";
|
|
1376
1529
|
}
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
if (event.candidate) {
|
|
1380
|
-
localCandidates.push(candidateToJson(event.candidate));
|
|
1381
|
-
}
|
|
1530
|
+
iceCandidateReadiness = createManagedIceCandidateReadiness(peer, {
|
|
1531
|
+
assertCurrentAttempt,
|
|
1382
1532
|
});
|
|
1533
|
+
this.pendingIceCandidateReadiness = iceCandidateReadiness;
|
|
1383
1534
|
await this.runConnectionStage("browser_offer", attempt, async () => {
|
|
1384
1535
|
const offer = await peer.createOffer();
|
|
1385
1536
|
await peer.setLocalDescription(offer);
|
|
1386
1537
|
});
|
|
1387
1538
|
await this.runConnectionStage("browser_ice_gathering", attempt, () =>
|
|
1388
|
-
|
|
1539
|
+
iceCandidateReadiness.wait()
|
|
1389
1540
|
);
|
|
1541
|
+
if (this.pendingIceCandidateReadiness === iceCandidateReadiness) {
|
|
1542
|
+
this.pendingIceCandidateReadiness = null;
|
|
1543
|
+
}
|
|
1390
1544
|
assertCurrentAttempt(peer);
|
|
1391
1545
|
const localDescription = peer.localDescription;
|
|
1392
1546
|
if (!localDescription) {
|
|
@@ -1415,6 +1569,7 @@ export class ManagedHostBrowserConnection {
|
|
|
1415
1569
|
client_authority_kind: "host_owner_browser",
|
|
1416
1570
|
}
|
|
1417
1571
|
);
|
|
1572
|
+
assertCurrentAttempt(peer);
|
|
1418
1573
|
if (
|
|
1419
1574
|
!ticket ||
|
|
1420
1575
|
typeof ticket.credential !== "string" ||
|
|
@@ -1439,7 +1594,7 @@ export class ManagedHostBrowserConnection {
|
|
|
1439
1594
|
type: localDescription.type,
|
|
1440
1595
|
sdp: localDescription.sdp,
|
|
1441
1596
|
},
|
|
1442
|
-
candidates:
|
|
1597
|
+
candidates: iceCandidateReadiness.candidates,
|
|
1443
1598
|
})
|
|
1444
1599
|
);
|
|
1445
1600
|
assertCurrentAttempt(peer);
|
|
@@ -1517,6 +1672,11 @@ export class ManagedHostBrowserConnection {
|
|
|
1517
1672
|
if (this.connectingPeer === peer) this.connectingPeer = null;
|
|
1518
1673
|
peer.close();
|
|
1519
1674
|
throw error;
|
|
1675
|
+
} finally {
|
|
1676
|
+
if (this.pendingIceCandidateReadiness === iceCandidateReadiness) {
|
|
1677
|
+
this.pendingIceCandidateReadiness = null;
|
|
1678
|
+
}
|
|
1679
|
+
iceCandidateReadiness?.dispose();
|
|
1520
1680
|
}
|
|
1521
1681
|
}
|
|
1522
1682
|
|
|
@@ -1650,6 +1810,15 @@ export class ManagedHostBrowserConnection {
|
|
|
1650
1810
|
this.connectionGeneration += 1;
|
|
1651
1811
|
const connectingPeer = this.connectingPeer;
|
|
1652
1812
|
this.connectingPeer = null;
|
|
1813
|
+
if (this.pendingIceCandidateReadiness?.peer === connectingPeer) {
|
|
1814
|
+
this.pendingIceCandidateReadiness.cancel(
|
|
1815
|
+
managedWebRtcAttemptError(
|
|
1816
|
+
"managed_webrtc_stale_connect_attempt",
|
|
1817
|
+
"Managed WebRTC connect attempt was replaced"
|
|
1818
|
+
)
|
|
1819
|
+
);
|
|
1820
|
+
this.pendingIceCandidateReadiness = null;
|
|
1821
|
+
}
|
|
1653
1822
|
connectingPeer?.close();
|
|
1654
1823
|
const peer = this.peer;
|
|
1655
1824
|
const connection = this.activeConnection;
|