Persistent Dock badge from orphaned scheduled-task unread IDs
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
Research direction
Start by tracing the persisted unread-thread-ids-by-host-v1.local state, local thread metadata, and the current automations/automation-runs store. Reproduce the orphaned thread_source=automation unread IDs and verify that startup, deletion, or Scheduled → Mark all as read removes unreachable automation unread entries while preserving thread history and other unread IDs.
Written by the indexing model from the issue text.
Description
Environment
- ChatGPT/Codex desktop app for macOS: 26.730.61639 (build 6234)
- macOS: 26.5.2 (25F84)
- UI locale: Korean
- Model/subscription: not relevant; this is desktop persisted notification state
What issue are you seeing?
The macOS Dock notification badge remained stuck at 30 even though:
- there were no blue unread dots anywhere in the UI;
- Scheduled contained no tasks or completed runs;
- Scheduled → Mark all as read had no effect;
- quitting and relaunching the app preserved the badge.
A new notification changed the badge from 30 to 31, and opening that notification reduced it back to 30. This showed that 30 stale unread entries were still being counted, but were not reachable from the UI.
Diagnostic evidence
The persisted atom state key unread-thread-ids-by-host-v1.local contained exactly 30 thread IDs. Every ID mapped to local thread metadata with:
thread_source=automationsource=vscode
At the same time, the current automations / automation-runs store contained zero active items.
Editing the persisted state while the app was running did not work: the in-memory state rewrote the stale values during shutdown.
Likely root cause
Unread IDs for deleted or obsolete scheduled-task runs remain in the persisted unread atom after their automation records disappear. The Dock badge still counts those IDs, while Mark all as read only processes currently visible inbox/automation items, leaving no UI path to clear the orphaned unread state.
Steps to reproduce
- Create a scheduled task that produces multiple unread runs.
- Delete or otherwise remove the scheduled task and its visible runs.
- Observe that the Dock badge can continue counting the old automation-run unread IDs.
- Open Scheduled → Mark all as read.
- Observe that the orphaned count remains after relaunch.
Expected behavior
Any of these should prevent the stuck badge:
- reconcile stale unread IDs against current automation/thread state at startup;
- when an automation is deleted, clear unread state for its historical runs without deleting thread history;
- make Scheduled → Mark all as read clear orphaned automation unread entries;
- only count unread items that are still reachable from the UI.
Workaround and verification
The issue was resolved by:
- fully quitting the app;
- backing up both persisted state files;
- removing only unread IDs whose thread metadata had
thread_source=automationfrom the active state and its backup; - preserving all thread history and all non-automation unread IDs;
- relaunching the app.
Verification:
- active unread count: 30 → 0
- backup unread count: 30 → 0
- macOS Dock
StatusLabel: 30 → empty - user confirmed the badge was gone
Diagnostics
A diagnostic feedback bundle including logs and the relevant conversation was uploaded through the official /feedback flow.
Uploaded feedback thread: 019fd355-5fc7-7e73-8657-1d1208975e28
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.5k
- Avg merge
- 1m
- Merged PRs (30d)
- 1k
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from openai/codex
-
enhancement remote
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
bug CLI windows-os
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
macOS sandbox blocks hw.optional.arm64 sysctl, causing Flutter to misdetect Apple Silicon as x64 Openbug CLI sandbox
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug CLI TUI
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
CLI config enhancement skills
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
kwakseongjae/auto-hwp#319 ·
-
area:cli bug filter-quality good first issue priority:medium
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
bevyengine/bevy#25861 ·
-
comp-datalake
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
ClickHouse/ClickHouse#121222 ·
-
A-linter
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
oxc-project/oxc#26863 ·