Consider timing diagnostics and adapters for slow repeated CLI startup
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
- Issue type
- Feature
- Clarity
- Needs clarification
- Activity status
- Quiet
- Tech stack
- node.js, typescript
- Domain
- cli, performance, testing-qa
Research direction
No file or test is named in the issue. First reproduce a repeated-command suite and compare startup time with output-matching overhead; then scope one direction—timing diagnostics, documentation, or an adapter. Done should include clear guidance or diagnostics, plus preserved argv, cwd, environment, streams, and exit-code behavior for any adapter.
Written by the indexing model from the issue text.
Description
Some CLI golden suites run the same command many times, and for TypeScript/Node CLIs a
single cold start can be around a second. When a tryscript file or suite has many console
blocks, that startup cost can dominate the run even when tryscript's own matching overhead
is small.
It would be useful to consider support or guidance here without changing tryscript's core
shell semantics.
Possible directions:
- Document how to diagnose startup-bound suites versus output-matching overhead.
- Add optional timing diagnostics, such as per-command duration and a slowest-commands
summary. - Provide guidance for CLI authors on reducing startup cost: lazy imports, prebuilt JS,
Node compile cache, avoiding heavy barrel imports, etc. - Consider an advanced adapter/lifecycle pattern for CLIs that can safely run multiple
invocations through one prestarted process while preserving argv, cwd, env, stdin,
stdout/stderr, and exit-code behavior.
The adapter idea is not universally safe because many CLIs rely on process isolation or
global state. Even if tryscript does not implement daemonization directly, docs and timing
visibility would help users see where slow golden tests are spending time and choose the
right mitigation.
- Dominant language
- TypeScript
- Stars
- 13
- Forks
- 1
- Avg merge
- 3h 38m
- Merged PRs (30d)
- 3
Contributor guide
No contributing guide indexed for this repository
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 jlevy/tryscript
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Difficulty 4/5 3-5 days Newbie friendliness 52/100
-
Difficulty 4/5 3-5 days Newbie friendliness 52/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
danielmiessler/LifeOS#2218 ·