Skip to content

Reopen handled notifications on same-reason new activity #8

Description

@blink-claw-bot

Problem

The recent re-open fix only reopens a dismissed notification when the GitHub notification reason changes. That catches cases like subscribed -> mention, but it can miss same-reason new activity, such as a new comment on a subscribed thread that remains reason=subscribed.

If GitHub returns an already-handled notification in the active notifications API again, that is itself useful signal: there is unread/new activity for the thread.

Suggested behavior

Reopen a locally handled notification when GitHub serves it again with new activity, even if reason did not change.

Implementation hints

Options:

  • Store GitHub updated_at on the notification row and reopen when incoming updated_at > last_handled_github_updated_at.
  • Store last_read_at/latest_comment_url where available and compare those.
  • Simpler first pass: if an existing row is dismissed=1 or acted_at IS NOT NULL and appears in gh api notifications, clear dismissed, clear acted_at, and set action_taken = 'RE-OPENED: new GitHub activity detected'.

Be careful not to reset rows that are currently processing=1; those should probably stay locked.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions