tui: --prompt no longer auto-submits in 2.0
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 74/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
- Domain
- cli
Research direction
Start at the home route's auto-submit effect and inspect its checks for local.model.ready, sync.ready, and the submit() call; compare the change with commit 0fa9e5039e. Reproduce with opencode --prompt "hello" in a new session, and confirm the prompt submits automatically once the required agent data is available.
Written by the indexing model from the issue text.
Description
Description
In 2.0, opencode --prompt "some text" puts the text in the composer on the home screen but no longer submits it. You have to press Enter. In 1.x it submitted automatically.
The home route's auto-submit effect only waits for local.model.ready, which just means the local model.json preferences were read. The server usually hasn't returned agents/models yet, so submit() bails at if (!agent) return false, and the effect never retries. It used to also wait for sync.ready; that check was dropped in 0fa9e5039e.
OpenCode version
2.0.16
Steps to reproduce
- Run
opencode --prompt "hello"in a new session (no--session) - The text appears in the prompt box but isn't sent until you press Enter
- Dominant language
- TypeScript
- Stars
- 210k
- Forks
- 27.8k
- Avg merge
- 8h 43m
- Merged PRs (30d)
- 380
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing 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 anomalyco/opencode
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
anomalyco/opencode#51159 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
All issues in anomalyco/opencode
Similar issues
-
resources
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
railmapgen/rmg-palette#2445 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
danielmiessler/LifeOS#2242 ·
Maintainers usually reply within 5 days
-
good first issue hacktoberfest help wanted translation
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
callstackincubator/appduct#129 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 1-3 hours Newbie friendliness 88/100