agent 3.0.2: pollDeferred notifies onInteraction only when (url, code) changes - #21
Merged
Merged
Conversation
…) changes A PS can carry the interaction on every 202 while it applies — Wallet's reach fallback re-advertises the url each ~5s poll until the record resolves — and onInteraction typically opens a browser, so per-poll notification re-opened the page every cycle (#17). Dedupe by (url, code): notify on first sight and again only if the advertised pair changes. The initial url/code passed into pollDeferred seeds the dedupe, so the same pair arriving via AAuth-Requirement is not a second notification. 18 tests passing (3 new). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01B9VG2CXgAaQcNAPWrCy6Yd
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.
Fixes #17.
A PS can carry the interaction requirement on every 202 while it applies — Wallet's reach fallback re-advertises the url on each ~5s poll until the record resolves — and
onInteractiontypically opens a browser, so per-poll notification re-opened the page every cycle.pollDeferrednow notifies on first sight of a (url, code) pair and again only when the pair changes; the initial url/code passed in seeds the dedupe so the same pair arriving viaAAuth-Requirementisn't a second notification.interaction_requiredevents dedupe the same way (they narrate a protocol moment, not a poll cycle).Observed live against person.hello-beta.net during web-reach testing 2026-08-13. 18 tests passing (3 new). Version bumped to 3.0.2 for the next release.
🤖 Generated with Claude Code
https://claude.ai/code/session_01B9VG2CXgAaQcNAPWrCy6Yd