Skip to content

test: the streaming QUERY e2e reads the speak frame, not the newest frame - #398

Merged
JarbasAl merged 1 commit into
devfrom
test/query-streaming-e2e-reads-the-speak-frame
Oct 21, 2026
Merged

JarbasAl merged 1 commit into
devfrom
test/query-streaming-e2e-reads-the-speak-frame

Conversation

@openvoiceos-bot

Copy link
Copy Markdown
Contributor

🤖 Auto-generated by Claude Sonnet 5.5 (claude-sonnet-5-5) via Claude Code, reviewed by Claude Opus 5.5 — NOT human-reviewed. Verify before acting.

Two relay-chain tests in tests/e2e/test_query_streaming_e2e.py fail intermittently with KeyError: 'utterance'. They read the answer from the return value of hivescope Recorder.wait_for, which returns the newest matching record. When the stream ends before the woken waiter reads the recorder, that record is the hive.query.complete frame, not a speak chunk. Load widens the window. A review measured 5 failures in 80 runs on dev.

The tests now wait until a received QUERY frame carries an utterance, read from recorder.received(...), and assert the spoken text. The async test now asserts its text as well, where it checked only that a frame arrived. No source file changes.

Under a load of four CPU-bound processes, 48 runs of the two relay tests gave 0 failures. The same load on dev gave 1 failure in 24 runs. That sample is small, so the review's 5 in 80 on dev is the better baseline. The full suite gives 674 passed and 3 skipped, equal to dev.

🤖 Generated with Claude Code

…rame

The relay-chain tests read the satellite's answer from the return value of
Recorder.wait_for, which is the newest matching record. When the stream
finishes before the woken waiter reads the recorder, that record is the
hive.query.complete frame, and the test fails with KeyError: 'utterance'.

The tests now wait until a received frame carries an utterance and assert
the spoken text, so the read no longer depends on frame timing. The async
test asserts its text too, where it checked only that a frame existed.

Under a 4-process CPU load, 48 runs of the two relay tests passed with 0
failures. On dev, 1 failure in 24 runs under the same load.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 19 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 276df83f-798b-49ef-92b2-ebe3a694f824
📥 Commits

Reviewing files that changed from the base of the PR and between d868724 and 7c68c6a.

📒 Files selected for processing: 1
  • tests/e2e/test_query_streaming_e2e.py
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

I've gathered some intelligence on your latest changes. 🕵️‍♀️

I've aggregated the results of the automated checks for this PR below.

🔍 Lint

The automated sentinel is back with news. 💂‍♂️

❌ ruff: issues found in 108 file(s) — see job log
✅ actionlint: 11 workflow file(s), no finding

🏷️ Release Preview

I've checked the 'Security Updates' section. 🛡️

Current: 5.3.7a1 → Next: 5.3.7a2

Signal Value
Label (none)
PR title test: the streaming QUERY e2e reads the speak frame, not the newest frame
Bump alpha

✅ PR title follows conventional commit format.


🚀 Release Channel Compatibility

Predicted next version: 5.3.7a2

Channel Status Note Current Constraint
Stable ⚪ Not in channel -
Testing ❌ Too new (must be <5.0.0) hivemind-core>=4.0.0,<5.0.0
Alpha ✅ Compatible hivemind-core>=5.3.7a1

⚖️ License Check

Making sure we're playing by the open-source rules. 🎲

✅ No license violations found.

Policy: Apache 2.0 (universal donor). StrongCopyleft / NetworkCopyleft / WeakCopyleft / Other / Error categories fail. MPL allowed.

🔒 Security (pip-audit)

Ensuring our data is safe and secure. 🔐

✅ No known vulnerabilities found (87 packages scanned).

📋 Repo Health

Evaluating the repository's overall condition. 📋

✅ All required files present.

Latest Version: 5.3.7a1

✅ hivemind_core/version.py — Version file
✅ README.md — README
✅ LICENSE — License file
✅ pyproject.toml — pyproject.toml
⚠️ setup.py — setup.py
✅ CHANGELOG.md — Changelog
✅ hivemind_core/version.py has valid version block markers

📊 Coverage

The coverage report is now available for inspection. 📋

❌ 36.0% total coverage

Per-file coverage (9 files)
File Coverage Missing lines
hivemind_core/__init__.py 0.0% 2
hivemind_core/__main__.py 0.0% 24
hivemind_core/database.py 0.0% 62
hivemind_core/scripts.py 0.0% 468
hivemind_core/service.py 0.0% 244
hivemind_core/version.py 0.0% 5
hivemind_core/config.py 47.4% 41
hivemind_core/policy.py 50.0% 68
hivemind_core/protocol.py 51.2% 843

Full report: download the coverage-report artifact.

🔨 Build Tests

Running the forge to see if the code tempers correctly. 🔥

✅ All versions pass

Python Build Install Tests pytest
3.10 ✅ ✅ ✅ 674 passed, 3 skipped, 1069 warnings, 61 subtests passed in 411.66s (0:06:51)
3.11 ✅ ✅ ✅ 674 passed, 3 skipped, 1072 warnings, 61 subtests passed in 386.03s (0:06:26)
3.12 ✅ ✅ ✅ 674 passed, 3 skipped, 1066 warnings, 61 subtests passed in 337.05s (0:05:37)
3.13 ✅ ✅ ✅ 674 passed, 3 skipped, 1066 warnings, 61 subtests passed in 395.44s (0:06:35)

Automating the path to a better future 🌈

@JarbasAl
JarbasAl marked this pull request as ready for review October 21, 2026 04:37
@JarbasAl
JarbasAl merged commit 4b2b94e into dev Oct 21, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants