Upgrade: Anthropic.ts report exists only on stdout while state is saved, and --help runs a full scan
Maintainers usually reply within 6 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 84/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
Research direction
Start at Tools/Anthropic.ts:94-97, where argv parsing reads only the day count and --force, and at line 1011 where saveState runs after printing to stdout. Add a usage/exit path for --help (and rejection of unknown flags) before any scan begins, plus writing the report to a file under Logs/ and echoing its path, using Logs/run-history.jsonl as the convention reference. Done means: --help prints usage without fetching or saving state, every run leaves a report file on disk, and the existing behavior for day count and --force still passes any Upgrade skill tests.
Written by the indexing model from the issue text.
Description
Version
LifeOS 7.40.4. Same code on main today (Tools/Anthropic.ts, 1021 lines).
What is broken
Anthropic.ts prints its report only to stdout and saves State/last-check.json at the end of every successful run. So the report exists exactly once. If the output gets cut (an agent piping it through tail, a terminal scrollback limit, a tool-output size cap), the delta is gone, and a second run reports nothing because the state has already moved on.
The argument parser makes this easy to hit. It reads the first non--- argument as the day count and checks only for --force. Any other flag, --help included, is ignored and a full scan runs, which saves the state.
We lost the delta this way on two runs in a row and had to rebuild it from the previous state file in git.
Where (file:line)
LifeOS/install/skills/Upgrade/Tools/Anthropic.ts:94-97(argv: day count and--forceonly)LifeOS/install/skills/Upgrade/Tools/Anthropic.ts:1011(saveStateafter the report is printed to stdout)
Suggested fix
- Write every report to a file as well, for example
Logs/report-<timestamp>.md, and print its path at the end. The run history inLogs/run-history.jsonlalready records counts, so the report next to it fits. - Make
--helpprint usage and exit without fetching or saving state. Reject unknown flags the same way.
Optional: a --no-save flag for a dry run that leaves the state untouched.
This overlaps with the rewrite announced in #2227 (pagination and the import.meta.main guard), so it may be easiest to fold in there.
- Dominant language
- TypeScript
- Stars
- 19.3k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
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 danielmiessler/LifeOS
-
MergeSettings: an append annotation inside an overlay-only object is emitted raw into settings.jsonOpen
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
danielmiessler/LifeOS#2307 ·
Maintainers usually reply within 6 days
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
danielmiessler/LifeOS#2305 ·
Maintainers usually reply within 6 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
danielmiessler/LifeOS#2299 ·
Maintainers usually reply within 6 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
danielmiessler/LifeOS#2289 ·
Maintainers usually reply within 6 days
-
Difficulty 1/5 Under an hour Newbie friendliness 84/100
danielmiessler/LifeOS#2288 ·
Maintainers usually reply within 6 days
All issues in danielmiessler/LifeOS
Similar issues
-
bug help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
agent-task risk:low
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
guyellis/http-status-check#512 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
microsoft/playwright#43327 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
microsoft/TypeScript#64758 ·
Maintainers usually reply within 1 day
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
opensearch-project/OpenSearch-Dashboards#12937 ·
Maintainers usually reply within 2 days