Skip to content

perf(test): shorten Google Meet reconnect proof - #124602

Merged
steipete merged 1 commit into
mainfrom
perf/google-meet-reconnect-test
Aug 16, 2026
Merged

steipete merged 1 commit into
mainfrom
perf/google-meet-reconnect-test

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

The Google Meet voice-call gateway regression waits 1.15 real seconds after a failed localhost connection to re-prove that GatewayClient.stopAndWait() cleared its reconnect timer. The same test already inspects the actual one-second retry timer, and the GatewayClient owner suite independently advances 30 seconds to prove stopped clients never reconnect.

Why This Change Was Made

Keep the real cross-component proof but remove the duplicate elapsed observation window:

  • The Google Meet test still uses a real localhost upgrade server and the actual GatewayClient implementation.
  • It still proves the failed client is stopped exactly once, the initial socket connects once, and no live referenced one-second retry timer remains.
  • src/gateway/client.test.ts remains the owner proof that advancing well past the retry window creates no second socket.

No mocks replace the real connection boundary, and production behavior is unchanged.

User Impact

Maintainer Google Meet test feedback is about 1.2 seconds faster while retaining the original failed-client teardown regression and its GatewayClient reconnect owner coverage.

Evidence

Controlled same-Testbox A/B on tbx_01m05bdf2m3229wy5rj8ncja7d, with one excluded warmup and two retained samples per state, the same command, one worker, distinct filesystem module caches, import diagnostics, and /usr/bin/time -v:

Metric Before After Gain
Wall 8.80s 7.63s -1.17s (-13.3%)
Vitest 5.94s 4.74s -20.2%
Test body 1.65s 0.51s -69.1%
Imports 3.67s 3.62s effectively flat

CPU and peak RSS were effectively flat, so this PR makes no resource-usage claim.

Validation:

  • 12/12 Google Meet voice-call gateway tests.
  • GatewayClient owner test clears pending reconnect timers on stop passed.
  • Mutation: removing Google Meet's production stopAndWait() fails the shortened real integration with stopCalls: 0 and referencedRetry: true; three sibling teardown cases fail too.
  • Full extension-test changed gate passed, including typecheck, targeted lint, plugin boundaries, dead exports, and assertion guards.
  • Fresh autoreview: no accepted/actionable findings.
  • Production LOC: +0/-0; test LOC: +0/-24.

Testbox benchmark, mutation, and owner proof: https://github.com/openclaw/openclaw/actions/runs/31949314982

Final post-rebase changed gate: https://github.com/openclaw/openclaw/actions/runs/31949786933

AI-assisted: yes. The change and evidence were reviewed by the maintainer agent and fresh autoreview.

@clawsweeper

clawsweeper Bot commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@steipete
steipete marked this pull request as ready for review August 16, 2026 13:33
@openclaw-barnacle openclaw-barnacle Bot added size: XS maintainer Maintainer-authored PR labels Aug 16, 2026
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 16, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Land-ready proof for d7afe7b0a41f03b2aeca0452d5a7447047e329d0:

@clawsweeper

clawsweeper Bot commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 16, 2026, 9:39 AM ET / 13:39 UTC.

ClawSweeper review

What this changes

This PR removes a 1.15-second reconnect observation from the Google Meet voice-call gateway test while retaining its real localhost failure and teardown assertions.

Merge readiness

⚠️ Ready for maintainer review - 1 item remains

Keep open for normal maintainer handling. The focused test-only deletion preserves the cross-boundary failed-connection assertion, while the shared client suite remains the delayed-reconnect owner proof; no correctness or security finding was identified.

Priority: P3
Reviewed head: d7afe7b0a41f03b2aeca0452d5a7447047e329d0

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, source-backed test simplification with retained boundary and owner coverage.
Proof confidence 🌊 off-meta tidepool Not applicable: This is a maintainer-authored test-only PR; its body also links focused after-change benchmark and validation evidence.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This is a maintainer-authored test-only PR; its body also links focused after-change benchmark and validation evidence.
Evidence reviewed 6 items Plugin teardown boundary: The plugin’s connection helper awaits stopAndWait when startup fails, so the test’s rejection only completes after client teardown has been requested.
Shared request owner: The generic meeting gateway awaits stopAndWait in a finally block after every request, making client teardown a shared owner invariant rather than Google Meet-only policy.
Reconnect cancellation contract: The protocol client marks itself stopped and resets the reconnect supervisor before close handling; reconnect scheduling is guarded by !stopped.
Findings None None.
Security None None.

How this fits together

The Google Meet plugin delegates voice-call requests through the shared meeting gateway, which opens a Gateway client and tears it down after each request. A failed local WebSocket connection must not leave the client’s reconnect timer alive.

flowchart LR
  A[Google Meet voice request] --> B[Meeting gateway]
  B --> C[Gateway client]
  C --> D[Local WebSocket]
  D --> E[Connection failure]
  E --> F[Client teardown]
  F --> G[Retry timer cleared]
Loading

Before merge

  • Complete next step (P2) - This is a protected maintainer PR requiring normal review and exact-head validation, not a repair-lane candidate.
Agent review details

Security

None.

PR surface

Tests -24. Total -24 across 1 file.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 0 24 -24
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 0 24 -24

Review metrics

Metric Value Why it matters
Production versus test LOC production +0/-0; tests +0/-24 The branch removes only duplicate test observation code and does not alter shipped runtime behavior.

Technical review

Best possible solution:

Retain the immediate live-timer assertion in the Google Meet integration test and the shared client’s delayed fake-timer regression, then merge once normal exact-head checks complete.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this PR optimizes existing regression coverage rather than reporting a user-facing failure.

Is this the best way to solve the issue?

Yes. The shared client test already proves that a stopped reconnect path cannot create a later socket, and the retained real-localhost test still validates the Google Meet teardown boundary and absence of a live retry timer.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against b5491a08bf1c.

Labels

Label changes:

  • add P3: This is a low-risk test-runtime optimization with no intended user-facing behavior change.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This is a maintainer-authored test-only PR; its body also links focused after-change benchmark and validation evidence.

Label justifications:

  • P3: This is a low-risk test-runtime optimization with no intended user-facing behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This is a maintainer-authored test-only PR; its body also links focused after-change benchmark and validation evidence.

Evidence

What I checked:

Likely related people:

  • steipete: Blame attributes the Google Meet test, meeting-gateway teardown path, and relevant client teardown path to the current-main commit that introduced this boundary; the same person authored this focused follow-up. (role: introduced current gateway-test boundary and recent area contributor; confidence: high; commits: 063ce57caf23, d7afe7b0a41f; files: extensions/google-meet/src/voice-call-gateway.test.ts, extensions/google-meet/src/voice-call-gateway.ts, src/meeting-bot/voice-call-gateway.ts)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@steipete
steipete merged commit 605dece into main Aug 16, 2026
178 checks passed
@steipete
steipete deleted the perf/google-meet-reconnect-test branch August 16, 2026 13:41
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. plugin: google-meet rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant