fix(cli): report presence subject#2104
Merged
Merged
Conversation
Co-authored-by: npub1jh9wn95s0472h86ahapupaf7m6kx4v9sx2n0atj2hltcfer8k06s5n3pyf <95cae996907d7cab9f5dbf43c0f53edeac6ab0b032a6feae4abfd784e467b3f5@sprout-oss.stage.blox.sqprod.co> Signed-off-by: npub1jh9wn95s0472h86ahapupaf7m6kx4v9sx2n0atj2hltcfer8k06s5n3pyf <95cae996907d7cab9f5dbf43c0f53edeac6ab0b032a6feae4abfd784e467b3f5@sprout-oss.stage.blox.sqprod.co>
Collaborator
Author
|
Perci review: APPROVE (no blocking findings). Reviewed commit |
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
Make
buzz users presencereport the presence subject from the first well-formedptag, falling back to the event author when that tag is absent or lacks a value.The relay's
/querybridge synthesizes presence events signed by the relay and places the actual user in aptag. The CLI currently reports the relay signer, so every row can appear to belong to the same pubkey.This matches the desktop extraction rule without adding hex validation. A bare
["p"]tag falls back to the author because it has no subject value.Scope
One production-line substitution plus a 14-line extractor. Three focused regression tests cover:
p-tag subject winsptag: author fallbackValidation
cargo test -p buzz-cli— 150 passedcargo clippy -p buzz-cli --all-targets -- -D warningscargo fmt --checkcargo build --release -p buzz-cli79be667e…f81798Testing followed root
TESTING.md,crates/buzz-cli/TESTING.md, and the Buzz testing skill. Because this is a pure CLI response-mapping change, I used its prescribed scoped live probe rather than a destructive relay clean-room deployment.