feat(opencode): lightweight TUI (oclite) and subagent directory fix#51
Merged
feat(opencode): lightweight TUI (oclite) and subagent directory fix#51
Conversation
- Fix critical bug: task completion events now route to parent session (changed session_id: session.id to session_id: ctx.sessionID in task.ts) - Remove 'any' type annotations from catch blocks - Replace e?.name checks with proper type guards for AbortError - Convert Global paths to getters for test isolation - Fix log directory initialization order - Clean up Tauri dependencies from lock file
Bun.file().stat() throws "Directories cannot be read like files" when called on a directory. The .git path is a directory in normal repos (only a file in worktrees). Using Node.js fs.stat() works correctly with both. Also fixed stat.isFile to stat.isFile() (method call vs property).
|
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
This was referenced Jan 26, 2026
randomm
added a commit
that referenced
this pull request
Feb 3, 2026
) * fix(opencode): fix task auto-notification and remove any types - Fix critical bug: task completion events now route to parent session (changed session_id: session.id to session_id: ctx.sessionID in task.ts) - Remove 'any' type annotations from catch blocks - Replace e?.name checks with proper type guards for AbortError - Convert Global paths to getters for test isolation - Fix log directory initialization order - Clean up Tauri dependencies from lock file * fix(project): use fs.stat instead of Bun.file for directory detection Bun.file().stat() throws "Directories cannot be read like files" when called on a directory. The .git path is a directory in normal repos (only a file in worktrees). Using Node.js fs.stat() works correctly with both. Also fixed stat.isFile to stat.isFile() (method call vs property). * feat(opencode): add lightweight TUI (oclite) with raw ANSI terminal (#27) * fix(tool): inherit parent session directory in subagents (#50) * fix(provider): add comprehensive null checks in auth.ts (#52) * feat(cli): add task icons with color coding (#21) * feat(cli): add metrics formatting utilities (#20) * fix(project): handle empty commits and worktree path resolution
randomm
added a commit
that referenced
this pull request
Feb 3, 2026
) * fix(opencode): fix task auto-notification and remove any types - Fix critical bug: task completion events now route to parent session (changed session_id: session.id to session_id: ctx.sessionID in task.ts) - Remove 'any' type annotations from catch blocks - Replace e?.name checks with proper type guards for AbortError - Convert Global paths to getters for test isolation - Fix log directory initialization order - Clean up Tauri dependencies from lock file * fix(project): use fs.stat instead of Bun.file for directory detection Bun.file().stat() throws "Directories cannot be read like files" when called on a directory. The .git path is a directory in normal repos (only a file in worktrees). Using Node.js fs.stat() works correctly with both. Also fixed stat.isFile to stat.isFile() (method call vs property). * feat(opencode): add lightweight TUI (oclite) with raw ANSI terminal (#27) * fix(tool): inherit parent session directory in subagents (#50) * fix(provider): add comprehensive null checks in auth.ts (#52) * feat(cli): add task icons with color coding (#21) * feat(cli): add metrics formatting utilities (#20) * fix(project): handle empty commits and worktree path resolution
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the lightweight TUI (oclite) for Claude and fixes subagent session directory handling.
Changes
oclite Implementation (#27)
Subagent Directory Fix (#50)
Files Changed
Core Implementation:
packages/opencode/src/cli/lite/- New lightweight TUI modulepackages/opencode/script/build-lite.ts- Build configurationpackages/opencode/src/tool/task.ts- Session directory inheritance fixSupport Files:
packages/opencode/src/agent/agent.ts- Agent updatespackages/opencode/src/session/processor.ts- Processor updatespackages/opencode/src/session/tools.ts- Tool configurationpackages/opencode/src/project/project.ts- Project configurationpackages/opencode/src/global/index.ts- Global setuppackages/opencode/src/util/- Utility functionspackages/opencode/package.json- DependenciesCloses