Include show_in_channel thread replies in the channel query response#43
Merged
andremion merged 1 commit intoJul 13, 2026
Merged
Conversation
The channel query response only returned messages with parent_id == nil, dropping thread replies sent also to the channel. The backend's channel message predicate is (parent_id IS NULL) OR (show_in_channel = true). This surfaced as a flaky Android e2e test: after a mid-test WebSocket reconnect, the client re-queries the channel and the response silently removed the also-in-channel reply from its state, wiping the deleted-message placeholder the test was waiting for (AND-1303). Verified against a local instance: an also-in-channel reply is now returned by the query, thread-only replies stay excluded.
Contributor
Author
Contributor
Author
|
e2e results against this branch:
No failures in the channel-query domain on either platform. |
testableapple
approved these changes
Jul 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The channel query response (
paginate_message_list) only returned messages withparent_id == nil, which drops thread replies sent also to the channel. The backend's channel message predicate is(parent_id IS NULL) OR (show_in_channel = true), so those replies belong in the response.Why it matters
This surfaced as the flaky
test_threadReplyIsRemovedEverywhere_whenParticipantRemovesItFromChannelon Android (AND-1303). The chain, reconstructed from the per-attempt artifacts of the 2026-07-13 nightly:The client behaved correctly; the response was the lie. Without a mid-test reconnect there is no re-query, which is why the test only flakes under CI load.
Testing
Against a local instance: seeded a regular message, a thread reply with
thread_and_channel=true, and a thread-only reply, thenPOST /channels/messaging/{id}/query:messages(the fix)