Repository navigation
refactor(meetings): deslop browser meetings - #165349
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed October 5, 2026, 3:16 AM ET / 07:16 UTC (Revision 4). ClawSweeper reviewWhat this changesSimplifies shared browser-meeting session, caption, audio, and cleanup handling and Google Meet command dispatch while preserving existing behavior. Merge readiness✅ Ready for maintainer review The refactor remains useful and is not already present on current main. The prior finding is resolved, and this review found no actionable correctness or security defect. Priority: P3 Review scores
Verification
How this fits togetherMeeting plugins translate CLI, tool, and Gateway requests into browser participation and audio operations. The shared runtime manages session ownership, caption delivery, and cleanup across Google Meet, Teams, Zoom, and Slack huddles. flowchart TD
A[CLI and agent requests] --> B[Meeting plugins]
B --> C[Shared session runtime]
C --> D[Browser ownership and tab lock]
D --> E[Meeting browser and audio]
E --> F[Caption delivery queue]
F --> G[Transcripts and meeting notes]
C --> H[Leave and resource cleanup]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource -492, Tests -3, Other -1. Total -496 across 31 files. View PR surface stats
Review metrics
Technical reviewBest possible solution: Keep one shared session owner and caption-delivery path while retaining platform-specific transport hooks and public SDK contracts. Do we have a high-confidence way to reproduce the issue? Not applicable: this is behavior-preserving cleanup, and source review identified no introduced failing scenario. Is this the best way to solve the issue? Yes: specializing the existing runtime and consolidating delivery and dispatch remove duplicate ownership without changing documented defaults or retained SDK contracts. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against fdd3a97f23ef. LabelsLabel changes: No label changes. Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (3 earlier review cycles)
|
|
Exact-head inherited-failure evidence for the coordinator-authorized squash merge of The only failing source job is
The same file, line, diagnostic, and missing properties fail on main at All other selected CI jobs pass, including meeting test lanes, production types, other test-type shards, every lint shard, baseline ratchets, and security checks. The Repair proof: 31 focused tests passed; focused lint and mock ratchet passed; both import-cycle checks report zero; independent P0/P1 review is clean. Final production delta is 921 added / 1,413 removed, −492 net LOC. The coordinator accepted the below-1000 batch. Per the explicit inherited-failure instruction, the Gateway main failure is reported for the coordinator rather than fixed in this lane. |
56bdfc7 (#165349) removed the production users of GoogleMeetJoinResult and the external MeetingRuntimeOwner alias, leaving Knip failures. Keep the locally used owner type private, remove the redundant join alias, and derive test result types from the existing runtime fixture. No runtime behavior or public SDK contract changes.
* refactor(meetings): deslop browser meetings * chore(meetings): shrink assertion safety baseline * fix(meetings): preserve callback binding and mock isolation
5d5e44b (openclaw#165349) removed the production users of GoogleMeetJoinResult and the external MeetingRuntimeOwner alias, leaving Knip failures. Keep the locally used owner type private, remove the redundant join alias, and derive test result types from the existing runtime fixture. No runtime behavior or public SDK contract changes.
What Problem This Solves
Maintainer-requested simplification: browser meeting implementations retained redundant forwarding and duplicate control-flow paths after consolidation onto a shared runtime.
User Impact
No user-visible change. Google Meet, Teams meetings, Zoom meetings, and Slack huddles retain their features, CLI/RPC/tool surfaces and descriptions, configuration, persisted schema, protocol shapes, and authority checks. Gateway ownership and PID-namespace checks are unchanged.
Why This Change Was Made
Production: 26,327 → 25,835 LOC (−492, 1.87%), excluding tests/support, fixtures, docs, generated metadata, and assets. BELOW-1000: the exhaustive coverage log below documents the permitted final below-threshold batch. The requested 20% reduction was not achieved; remaining platform lifecycle differences and retained public SDK contracts do not support the inspected deletions without changing behavior. No production code moved outside the feature.
Evidence
Exact-head inherited-failure evidence for the coordinator-authorized squash merge of
2fb229804a28facc91b1a1f744f73f0ac754efe6.The only failing source job is
check-test-types-core-5in PR CI run 37276104760. Its Gateway typecheck reports:src/gateway/server-lifecycle.catalog-write.test.ts(162,34): TS2739— therunGatewayStartupObserversfixture omitsresolveGatewayContextandloadSubagentRegistryActivation.The same file, line, diagnostic, and missing properties fail on main at
fdd3a97f23ef55fe8e76ff8f002bcdb8cb2ffc8fin main CI run 37276090760, and on unrelated PR #165410 at1e5b72ca3d19aae712469b38637c74fc078bfaeein run 37276361811. Fresh origin/main source also retains the same fixture/signature mismatch. This PR changes neither the failing test norsrc/gateway/server-startup-observers.ts; the missing-property diagnostic concerns their direct call contract, with no meeting implementation in the failing call/type path.All other selected CI jobs pass, including meeting test lanes, production types, other test-type shards, every lint shard, baseline ratchets, and security checks. The
openclaw/ci-gatefailures are aggregate consequences of this one inherited type error. All checks have settled. The earlier PR-caused assertion-baseline, mock-isolation, and unbound-method failures are fixed and green on this exact head.Repair proof: 31 focused tests passed; focused lint and mock ratchet passed; both import-cycle checks report zero; independent P0/P1 review is clean. Final production delta is 921 added / 1,413 removed, −492 net LOC. The coordinator accepted the below-1000 batch. Per the explicit inherited-failure instruction, the Gateway main failure is reported for the coordinator rather than fixed in this lane.
The coordinator accepted the below-1000 batch and retired the previous auto-merge request. The assertion-baseline shrink (3 → 2) passed on
7d18caeec7b. Run 37271228250 then passed every selected test and typecheck but found two PR-caused issues: the extracted audio prerequisite callback had method syntax that triggered unbound-method lint in both callers, and the lazy-import runtime mock needed its intentional isolation documented.2fb229804a28facc91b1a1f744f73f0ac754efe6restores a function property, documents the cold runtime mock, and removes its obsolete baseline entry. Exact-head hosted CI has settled with all PR-owned checks green and one inherited Gateway test-type failure; the coordinator-authorized pinned admin squash route applies as documented below.CI repair proof: focused type-aware lint passed; mock-factory ratchet passed (10,739 grandfathered factories); both cycle checks report zero; 31 tests in 3 files passed (
chrome-transport.test.ts,browser-plugin.config-setup.test.ts, and Google Meetlazy-import.test.ts), 590.40 seconds wrapper wall time on the loaded Mac. Independent P0/P1 review found no actionable issues. No test case or assertion changed in this repair.Full meeting selection:
node scripts/run-vitest.mjs src/meeting-bot extensions/google-meet extensions/teams-meetings extensions/zoom-meetings extensions/slack-huddles— 1,032 tests in 90 files passed, one worker; 5,231.81 seconds including runtime/worker preparation on the loaded Mac.Plugin contracts:
node scripts/run-vitest.mjs src/plugins/contracts— 1,139 passed, one inherited failure: the original base omitted the X runtime API from its guard inventory. Rebased to include upstream fix fix: classify X runtime API in plugin guardrails #165251 (43856f78ec6). The focused runtime-API guard then passed all 7 tests on the final base (node scripts/run-vitest.mjs src/plugins/contracts/plugin-sdk-runtime-api-guardrails.test.ts; 92.39 seconds wall time including worker preparation).Final-base cycle checks:
node --import ./scripts/tsx.mjs scripts/check-madge-import-cycles.tsandnode --import ./scripts/tsx.mjs scripts/check-import-cycles.ts— 0 cycles in both. An unrelated trajectory/SQLite cycle found during base integration was fixed upstream in48c08e6ccba; that fix is included.Independent Codex autoreview: scoped-clean at P0/P1 after correcting a browser result-key regression caught by review and four existing startup-cleanup tests. All four passed in the corrected meeting run.
The full meeting/contract results precede the final rebase. The original meeting patch stayed identical across that rebase (
3e41283c62aff2d12f41af8c03a3adbcee05aace), and no meeting-feature paths changed on the incorporated main commits. The later callback-syntax correction is covered by the focused repair proof above. The affected inventory guard and both cycle checks were rerun. Hosted CI owns lint/types and final-head verification;check-changedwas not run locally.Three Testbox preparation attempts could not dispatch checks because source freezing stalled. All three leases are stopped. Checks used the authorized serial local fallback at
nice -n 15; no live vendor meeting was exercised.No tests or assertions were removed. The four existing lazy-import cases took 3.381 seconds of test execution within the one-worker selection; the mock-only adjustment adds no cases or expected CI test seconds.
The attempted shared async Chrome-route resolver was removed because the existing pinned-node leave test requires dispatch before yielding. Its original control flow and regression assertions remain. The test edits update the lazy runtime mock to expose inherited transcript-source methods directly and document its required isolation; no assertion was weakened or removed.
PETER DECISION: retiring deprecated July-or-newer public
MeetingPlatformAdapterfactories/pluginTypescould enable further reduction, but would change a retained SDK contract. This PR preserves them.Complete production coverage log
Browser meetings coverage
Read-only coverage and implementation report for lane fd4-meetings. Baseline: dc518bf. Production measurement includes tracked TS/JS implementation files in src/meeting-bot and the four meeting plugins, excluding tests, test support, fixtures, docs, generated metadata, and assets. Every production file was read; the table lists every file originally above 200 lines, descending by size.
Measured production total: 26,327 → 25,835 lines, a reduction of 492 lines (1.87%) across 144 production files. This is BELOW-1000 and below the 20% target. Recent landed consolidation and retained behavior/SDK contracts limit the remaining sound reductions.
All entries below are READ. Existing behavior, platform surfaces, schema, protocol, security/authority checks, and Gateway/PID-namespace ownership remain required. Tests retain their assertions; the only test edit updates a runtime mock after removing an internal forwarding accessor.
src/meeting-bot/session-runtime.tsextensions/google-meet/src/runtime.tssrc/meeting-bot/status-call-source.tssrc/meeting-bot/node-host.tssrc/meeting-bot/chrome-transport.tssrc/meeting-bot/realtime-engine.tssrc/meeting-bot/browser-controller.tsextensions/google-meet/src/cli-export.tssrc/meeting-bot/runtime-facade.tssrc/meeting-bot/participation.tssrc/meeting-bot/transcripts-bridge.runtime.tsextensions/google-meet/src/meet-api.tsextensions/google-meet/src/cli-shared.tsextensions/google-meet/src/transports/google-meet-page-scripts.tssrc/meeting-bot/session-transcript-store.tsextensions/google-meet/index.tssrc/meeting-bot/platform-adapter.tssrc/meeting-bot/plugin-entry.tsextensions/google-meet/src/cli-space-commands.tsextensions/google-meet/src/meet.tssrc/meeting-bot/realtime-agent-engine.tssrc/meeting-bot/realtime-local-audio-transport.tssrc/meeting-bot/page-script-source.tsextensions/google-meet/src/config.tssrc/meeting-bot/status-prejoin-source.tssrc/meeting-bot/output-loopback-verifier.tsextensions/google-meet/src/plugin-registration.tsextensions/google-meet/src/transports/chrome-create.tssrc/meeting-bot/realtime-engine-support.tssrc/meeting-bot/realtime-output-owner.tssrc/meeting-bot/browser-session-control.tssrc/meeting-bot/runtime-facade-types.tssrc/meeting-bot/node-invoke-policy.tsextensions/google-meet/src/oauth.tssrc/meeting-bot/plugin-config.tssrc/meeting-bot/browser-audio-capture-source.tssrc/meeting-bot/browser-plugin.tssrc/meeting-bot/runtime-probes.tsextensions/slack-huddles/src/transports/slack-huddles-status-prejoin-source.tsextensions/google-meet/src/setup.tsextensions/google-meet/src/cli-runtime-commands.tssrc/meeting-bot/plugin-shell.tsextensions/google-meet/src/calendar.tssrc/meeting-bot/session-durable-transcripts.tsextensions/google-meet/src/transports/google-meet-caption-observer-source.tssrc/meeting-bot/session-cleanup-tracker.tsextensions/zoom-meetings/src/transports/zoom-meetings-status-prejoin-source.tssrc/meeting-bot/platform-adapter-contract.tsextensions/google-meet/src/transports/google-meet-platform-adapter.tsextensions/google-meet/src/cli-doctor.tsAll smaller production files were also read. The three newer adapters are already 74–82 lines each; selectors are platform data, URL parsing protects distinct workspace/passcode/identity contracts, and remaining forwarding includes public SDK members.
PETER DECISION: retiring deprecated July-or-newer MeetingPlatformAdapter factory members/pluginTypes would permit additional deletion, but changes a retained public SDK contract and is not part of this PR. No feature, configuration, schema, or protocol change is proposed or implemented.
Rejected simplification: a common async Chrome-route resolver added a yield before pinned-node leave dispatch. The original conditional-await path was restored; the existing before-yield regression assertions remain unchanged.