Repository navigation
fix(agents): refuse watches on unreachable channels #2311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
johnmatthewtennant
wants to merge
35
commits into
main
Choose a base branch
from
jtennant/thomas/watch-channel-eligibility
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+606
−86
Open
Changes from all commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
7ab14ae
fix(agents): let watches hear public channels the agent is not in
loganj f041667
fix(agents): hold a public channel's catch-up until its metadata is read
loganj 17bb299
fix(agents): hold a channel's catch-up before it is attended, too
loganj b2dabb7
fix(agents): resolve the channels a watch of every channel finds
loganj 7fd1bb4
fix(agents): read again an attended channel found unreadable
loganj 63e1fd4
docs(agents): say an event watch hears public channels it has not joined
loganj d58f1d5
fix(agents): read again an attended channel that turns private, and b…
loganj e0d988e
test(agents): pin that a hidden or DM public channel is not heard; fi…
loganj ceab1be
fix(agents): hear a public channel the agent is not in only once its …
loganj dfb8dd6
fix(agents): let the live owner decide which attended channels fit
loganj d0ec42f
fix(agents): keep watched channels live across changes, and only for …
loganj 12871e9
fix(agents): hold a non-member's event while its channel's metadata i…
loganj 762290a
fix(agents): read attended channels' metadata in the background lane
loganj d3fc416
fix(agents): keep mention turns as without watches' attendance
loganj 5c984e0
fix(agents): keep a mention's provenance from arrival, and the owner'…
loganj 12e7a8f
fix(relay): retire agents-only provenance on any viewer lookup
loganj 3825446
fix(relay): keep agents-only provenance through rechecks
loganj b9712ee
fix(relay): count a link to an agent-known channel as the viewer's
loganj 63ce7c3
fix(agents): keep scoped searches and re-enabled watch replays as on …
loganj 80cecbb
fix(relay): look up attended channels one batch at a time
loganj 9fa6cf2
fix(relay): read an attended channel once while its read is in flight
loganj c58cfd4
fix(agents): apply a replay's start floor when it is admitted
loganj 339eda6
test(relay): cover viewer precedence and link-lookup provenance
loganj e54cc69
Recheck joined metadata after a drop; keep attendance provenance and …
loganj 667e381
fix(agents): refuse watches on unreachable channels
johnmatthewtennant 9e6ac9c
test(agents): describe watch admission policy invariant
johnmatthewtennant dce81d7
fix(agents): preserve GitHub watches on refused moves
johnmatthewtennant 88a6108
fix(github): respect Attention cancellation during watch moves
johnmatthewtennant 0057ed8
Resolve listening metadata before watch admission
johnmatthewtennant 6778018
fix(agents): preserve watch metadata provenance during admission
johnmatthewtennant 974e2aa
fix(relay): retain viewer provenance through suspended admission
johnmatthewtennant 5232afd
Merge main into watch admission
johnmatthewtennant 704b079
docs: distinguish watch admission from viewer channel lookups
johnmatthewtennant 29363a0
Merge main into watch admission
johnmatthewtennant 3dcff41
Merge main into watch admission
johnmatthewtennant File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤖 [P3] Resolve channel metadata before entering the record change queue
Adding, updating or enabling an event watch for an unknown explicit channel awaits network resolution inside host.change. AgentsService.change serializes other changes behind this operation (service.ts:5170–5195), and dueTimer returns while changing is set (runner.ts:2371). A slow metadata read therefore stalls owner saves, other Attention writes and timer progress for this agent until it settles. The read deadline is approximately 10 seconds; the delay is source-derived, not measured. Resolve metadata before host.change, keeping the synchronous reads()/member() admission checks inside the queued mutation so authorization still uses current state.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤖 Deferred as a separate scheduling follow-up. Source inspection confirms the network await holds the per-agent queue; the practical delay has not been measured. The follow-up will move resolution before the mutation, retain latest-state access and token checks inside it, and cover delayed metadata reads racing owner saves and timer ticks. This is the same non-blocking latency concern already recorded in the review disposition; the current batch preserves the validated admission and atomic-transfer behavior.