Skip to content

feat(gmail): gmail_mark_read — clear UNREAD by message ids or whole thread (v0.3.0)#6

Merged
mabry1985 merged 1 commit into
mainfrom
feat/mark-read
Jul 3, 2026
Merged

feat(gmail): gmail_mark_read — clear UNREAD by message ids or whole thread (v0.3.0)#6
mabry1985 merged 1 commit into
mainfrom
feat/mark-read

Conversation

@mabry1985

Copy link
Copy Markdown
Contributor

Adds the ability the agent was missing: mark mail as read for inbox triage.

What

  • gmail.mark_read(): messages/batchModify with removeLabelIds: [UNREAD] for up to 1000 ids (blank ids dropped), or threads/{id}/modify for a whole thread.
  • Tool gmail_mark_read(message_ids | thread_id) — validates a target is given, reports the count marked.
  • Posture: this is deliberately the ONLY mailbox mutation beyond drafts — it clears the UNREAD label and nothing else (no archive/delete/send). README + manifest + module docstrings updated to state that explicitly.
  • Scope: gmail.modify, which the existing refresh token and the default connect scopes already carry — works with no re-consent.
  • Version → 0.3.0 (single-feature release, bump included).

Test

46 passed (3 new: batch body + blank-id filtering, thread modify, tool wrapper validation/count), ruff clean, host-free.

🤖 Generated with Claude Code

…hread (v0.3.0)

The one mailbox mutation beyond drafts: batchModify removes the UNREAD label from
up to 1000 message ids, or threads/{id}/modify clears a whole thread. Never
archives, deletes, or sends — posture docs updated to say exactly that. Uses the
gmail.modify scope the default connect flow already requests.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@protoquinn

protoquinn Bot commented Jul 3, 2026

Copy link
Copy Markdown

👀 Quinn is reviewing — verdict (PASS / WARN / FAIL) + findings to follow.

@mabry1985 mabry1985 merged commit 7232752 into main Jul 3, 2026
1 check passed
@mabry1985 mabry1985 deleted the feat/mark-read branch July 3, 2026 10:22

@protoquinn protoquinn Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

QA Audit — PR #6 | feat(gmail): gmail_mark_read — clear UNREAD by message ids or whole thread (v0.3.0)

VERDICT: WARN (CI queued — re-review on terminal)


CI Status

  • test: queued

Diff Review

  • gmail.mark_read() in gmail.py: two clean paths — threads/{id}/modify with removeLabelIds: [UNREAD] for whole-thread, messages/batchModify for up to 1000 ids. Blank-id filter and cap are correct. Defensive or 1 fallback on thread path is reasonable.
  • Tool wrapper in __init__.py validates at least one target, delegates consistently with existing _run pattern, and formats output appropriately.
  • 3 new tests cover batch body + blank-id filtering, thread modify path, and tool validation/count reporting — all follow the existing mock-transport style.
  • Documentation updated across README, module docstring, plugin manifest, and pyproject.toml — posture is explicit and consistent: "never archives, deletes, or sends."

Observations

  • LOW: clawpatch structural review unavailable (502 — repo not in checkout cache). Diff-only review is sufficient for this scope; no cross-file risk detected manually.
  • No unresolved CodeRabbit threads. No blocking findings.

— Quinn, QA Engineer

@protoquinn

protoquinn Bot commented Jul 3, 2026

Copy link
Copy Markdown

Submitted COMMENT review on #6.

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