Skip to content

v1.1.49:修复会话卡死、新增 Haskell 格式化 ​

发布日期:2026年02月03日


一句话总结 ​

这次更新修复了多个关键问题,包括会话卡死、文件状态计算错误等,新增 Haskell 代码格式化支持,并大幅改进桌面端交互体验。


问题修复:会话卡死问题 ​

之前的问题 ​

当会话遇到错误后,状态卡在错误中,导致无法开始新会话。

现在的情况 ​

修复了会话状态管理,错误后可以正常开始新会话,OpenCode 不再卡死。


新功能:Haskell 代码格式化 ​

这次更新了什么? ​

新增 Ormolu 代码格式化器支持,可以格式化 Haskell 代码。

什么是 Ormolu? ​

Ormolu 是 Haskell 的代码格式化工具,类似于 JavaScript 的 Prettier,可以自动统一代码风格。

如何使用? ​

在项目中包含 Haskell 代码时,OpenCode 会自动使用 Ormolu 进行格式化。


新功能:自定义 mDNS 域名 ​

这次更新了什么? ​

添加了 --mdns-domain 标志,可以自定义 mDNS 主机名。

有什么用? ​

在局域网访问时,可以自定义更友好的域名。

如何使用? ​

bash
opencode --mdns-domain mydevice.local

改进:桌面端交互体验 ​

项目搜索 ​

现在可以在桌面端搜索项目,快速找到要打开的项目。

会话导航 ​

新增键盘快捷键在未读会话之间切换。

Tab 关闭快捷键 ​

添加了关闭标签页的快捷键。

响应式设计 ​

新增断点,优化大屏幕布局。


问题修复 ​

文件状态计算 ​

新增和删除的文件现在能正确计算状态。

OpenAI 会话标题生成 ​

修复了使用 OpenAI 模型时标题生成的问题。

任务状态显示 ​

修复了任务状态无法显示当前工具状态的问题。

Copilot Provider ​

修复了 Copilot provider 的系统消息内容转换问题。

Agent 变量作用域 ​

修复了 agent variant 未正确作用域到 model 的问题。

@ 提及隐藏文件 ​

修复了以 . 开头的文件夹和文件无法用 @ 提及的问题。

Windows PTY 编码 ​

为 Windows PTY 添加 UTF-8 编码默认值。


要不要升级? ​

情况建议
遇到会话卡死问题✅ 强烈推荐
使用 Haskell✅ 推荐升级
桌面端用户✅ 推荐升级
用得好好的可以等下次

升级命令:

bash
opencode upgrade

技术细节(可跳过) ​

点击展开完整更新列表

Core ​

  • Revert pull request that was mistakenly merged
  • Add --mdns-domain flag to customize mDNS hostname (@luiz290788)
  • Added and deleted file status now correctly calculated in app
  • Add User-Agent header for GitLab AI Gateway requests (@vglafirov)
  • Add Ormolu code formatter for Haskell (@mimi1vx)
  • Use OpenTUI OSC52 clipboard implementation
  • Convert system message content to string for Copilot provider (@jogi47)
  • Give OPENCODE_CONFIG_CONTENT proper priority for setting config based on docs (@OpeOginni)
  • Fixed session title generation with OpenAI models (@oomathias)
  • Simplify directory tree output for prompts
  • Fix task status to show current tool state from message store
  • Allow starting new sessions after errors by fixing stuck session status
  • Adjust resolve parts to properly order tool calls when messages contain multiple @ references
  • Hide badge for builtin slash commands
  • Add workspace tests to the app (@neriousy)
  • Send custom agent prompts as developer messages instead of user messages when using Codex subscriptions
  • Fixed variant logic for Anthropic models through OpenAI compatibility endpoint
  • Add prompt caching support for Claude Opus on AWS Bedrock (@rgodha24)
  • Scope agent variant to model (@neavo)
  • Prevent duplicate AGENTS.md injection when reading instruction files (@code-yeongyu)
  • OpenCode no longer hangs when using client.app.log() during initialization (@desmondsow)
  • Remove outer backtick wrapper in session transcript tool formatting (@zerone0x)
  • Allow user plugins to override built-in auth plugins (@JosXa)
  • Binary file handling in file view (@alexyaroshuk)
  • Ensure switching Anthropic models mid-conversation works without errors and fix reasoning opaque not being picked up for Gemini models
  • Fix issue where folders and files starting with "." could not be mentioned with @
  • Show actual retry error message instead of generic error message
  • Use process.env directly for runtime environment mutations in provider (@jerome-benoit)
  • Add reasoning variants support for SAP AI Core (@jerome-benoit)
  • Add UTF-8 encoding defaults for Windows PTY (@01luyicheng)

TUI ​

  • Respect terminal transparency in system theme (@pablopunk)
  • Truncate session title in exit banner to prevent display overflow
  • Show exit message banner in TUI
  • Add spinner animation for Task tool
  • Correct pluralization of match count in grep and glob tools (@adamjhf)
  • Remove extra padding between search and results in dialog-select
  • Add UI for skill tool in session view
  • Conditionally render bash tool output in TUI
  • Add skill dialog for selecting and inserting skills
  • Enable password authentication for remote session attachment
  • Fix documentation issues (@lailoo)
  • Revert skill slash commands feature
  • Add skill slash commands to the app

Desktop ​

  • Fix prompt input overflow issue in app (@neriousy)
  • Sidebar losing projects on collapse has been fixed
  • Add workspace toggle command to command palette and prompt input (@alexyaroshuk)
  • Search through sessions
  • Standardize icon sizes in the application
  • Navigate to last project on open
  • User messages not rendering consistently
  • Add project context menu on right-click
  • Open project search in app (@neriousy)
  • Add tab close keybind to app (@ProdigyRahul)
  • Enhance responsive design with additional breakpoints for larger screen layout adjustments (@OpeOginni)
  • Add keyboard shortcuts for navigating between unread sessions (@Brendonovich)
  • Fix Rust build and bindings formatting in desktop application (@Brendonovich)
  • Remove unnecessary setTimeout in desktop app (@Brendonovich)
  • Throttle window state persistence in desktop application (@Brendonovich)
  • Integrate tauri-specta for desktop application (@Brendonovich)
  • Keep macOS titlebar stable under zoom (@Brendonovich)
  • Kill zombie server process on startup timeout (@heyitsmohdd)
  • Show skill and MCP badges for slash commands
  • Use static language names in Thai localization (@alexyaroshuk)
  • Add tests for general settings, shortcuts, providers and status popover (@neriousy)
  • Fixed session header 'share' button to hug content (@alexyaroshuk)

← 返回更新日志