Skip to content

Restore speaker context and participant lookups broken by a SQL syntax error - #8183

Open
georgi4444 wants to merge 2 commits into
fastrepl:mainfrom
georgi4444:fix/remote-participant-ids-sql
Open

georgi4444 wants to merge 2 commits into
fastrepl:mainfrom
georgi4444:fix/remote-participant-ids-sql

Conversation

@georgi4444

@georgi4444 georgi4444 commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Intent: Since 1.4.30, SESSION_REMOTE_PARTICIPANT_IDS_SQL has one closing parenthesis too many (added with the additional-email match in #8044), so SQLite rejects it with near ")": syntax error. Remove it so speaker context capture and the remote participant lookups work again.

Found on desktop 1.4.34: every recording since 1.4.30 stored speaker_context as {"intervals":[]}, and the app logged a console error on each 5 s capture poll, so the owner's mic voices stay "Speaker N" even with a headset. useSessionParticipantHumanIds and getSessionTranscriptRenderRequest use the same query and get no participants or an error instead.

Demo

N/A — no UI of its own to show; the regression test reproduces the SQLite error, and a 1.4.34 test recording kept an empty speaker_context while the app logged an error every 5 s.

Verification

  • New regression test runs the query on in-memory SQLite (owner, a calendar copy, an additional-email copy, one remote person): fails with near ")": syntax error without the fix and returns only the remote person with it.
  • Ran the 1.4.29, 1.4.34 and fixed queries against a local 1.4.34 database: the fixed query returns the same participants as 1.4.29.
  • pnpm -F @anlg/desktop test: 4222 passed. pnpm -F @anlg/desktop typecheck: passed.
  • oxlint on the changed files: no errors (one existing warning in unchanged code). dprint check on the changed files: passed.
  • Not run: a desktop build with a live recording, i18n validation, the license-boundary checks.

Summary by cubic

Fixes a SQL syntax error in SESSION_REMOTE_PARTICIPANT_IDS_SQL that since 1.4.30 made SQLite reject the query, so speaker context capture always failed and remote participant lookups returned no participants.

Written for commit 3de3d4f. Summary will update on new commits.

View guided diff

…x error

fastrepl#8044 added the owner's additional emails to SESSION_REMOTE_PARTICIPANT_IDS_SQL
with one closing parenthesis too many, so since 1.4.30 SQLite rejects the query
(near ")": syntax error). Speaker context capture fails on every poll and
stores no intervals, so the owner's mic is never named, and the remote
participant hooks get no participants.

Remove the extra parenthesis and run the query on SQLite in a regression test.
@coderabbitai

coderabbitai Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The SQL condition for the remote participant query no longer has a redundant closing parenthesis. A SQLite-backed test creates session, human, and participant records, then checks that the query returns only bob. The test closes the database in a finally block.

Suggested reviewers: computelesscomputer

Merge Risk: Minimal · up to 3de3d

The query fix and focused regression test are ready to merge; no actionable merge-blocking risk remains.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title states the main change: removing an extra closing parenthesis from SESSION_REMOTE_PARTICIPANT_IDS_SQL that caused a SQLite syntax error, which restores speaker context capture and participan…
Description check Passed The description explains the intent, the root cause (an extra closing parenthesis added in #8044 that causes a SQLite syntax error), the user-visible impact on speaker context and participant lookups,…
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title states the main change: removing an extra closing parenthesis from SESSION_REMOTE_PARTICIPANT_IDS_SQL that caused a SQLite syntax error, which restores speaker context capture and participant lookups. The raw summary confirms the change is a single removed parenthesis in queries.ts plus a regression test in queries.test.tsx, so the title matches the changeset.

Full details: Description check

Explanation

The description explains the intent, the root cause (an extra closing parenthesis added in #8044 that causes a SQLite syntax error), the user-visible impact on speaker context and participant lookups, and the verification steps including a new in-memory SQLite regression test. It relates directly to the changeset.

Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 1 files.

Tip

🎯 Customize your risk assessments

Guide how CodeRabbit assesses merge risk and security architecture risk. Highlight sensitive changes and explain your security boundaries using Merge Risk Instructions and Security Risk Instructions in your review settings. Security architecture risk assessments require the Advanced plan or above.

✅ Automatic approvals, with your rules

Let CodeRabbit approve pull requests once required threads are resolved, pre-merge checks pass, and your risk limits are met. Enable Automatic approvals in review settings, with overrides for teams or file paths.

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
Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: QUIET
  • Plan: Advanced
  • Run ID: ceba1b9f-6cf7-4e40-a04c-83aa990675d3
Commits

Reviewing files that changed from the base of the PR and between 1557eae and 3de3d4f.

Files selected for processing: 1
  • apps/desktop/src/stt/queries.test.tsx

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

Devin Review

Comment thread apps/desktop/src/stt/queries.test.tsx Resolved

This branch has not been deployed

No deployments
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.

1 participant