Skip to content

fix(cli): reject empty messages without attachments - #7050

Open
rmarquesAvatel wants to merge 1 commit into
block:mainfrom
rmarquesAvatel:rmarquesAvatel/buzz-rechazo-vacios
Open

fix(cli): reject empty messages without attachments#7050
rmarquesAvatel wants to merge 1 commit into
block:mainfrom
rmarquesAvatel:rmarquesAvatel/buzz-rechazo-vacios

Conversation

@rmarquesAvatel

Copy link
Copy Markdown

Summary

  • Reject buzz messages send when trimmed content is empty and no --file is present.
  • Return the existing usage-error shape and exit code 1 before relay lookup, upload, or publication.
  • Preserve text-only and attachment-only sends with relay-free process coverage.

Work package: BUZZ_PAQUETE_RECHAZO_CUERPO_VACIO_2026_08_30.md (internal factory package; audit ratification event 4d70c1beed11218e46c4fe2ed5326461ea1db2ae947fd2b2de01b4a85e0ba59c).

Evidence

  • Red on base eed74bde2f4797714335ac10c56c0b0244c1def4: focused test had 3 expected rejection failures and 2 pass-through passes.
  • Green on candidate 27b763353e7ae688733282ff8dbe62c9e521a692: focused test 5/5; just ci passed.
  • Real relay: empty send exited 1 with zero author events since the fixed cursor; attachment-only and normal text sends were published and read back (full IDs and filters retained in the delivery notes).

Test plan

  • cargo test -p buzz-cli --test messages_send_empty
  • just ci

Signed-off-by: Rubén Márques <rmarques@avatel.es>
@rmarquesAvatel
rmarquesAvatel requested a review from a team as a code owner August 30, 2026 08:17
@github-actions

Copy link
Copy Markdown

🔐 Codex Security Review

Status: review required for the current range.

The current range is eed74bde2f4797714335ac10c56c0b0244c1def4...27b763353e7ae688733282ff8dbe62c9e521a692.
A new review must complete for this exact range. When manual authorization
is required, a Block organization member must comment exactly
@buzz-security-review 27b763353e7ae688733282ff8dbe62c9e521a692 to authorize a new review.
Any previous review applies only to its recorded range.

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