# 🚀 CodeBuddy Code v2.102.0 Release

## 📦 Version Information

| Component | Version |
|-----------|---------|
| CodeBuddy Code CLI | v2.102.0 |
| Agent SDK JS | v0.3.164 |
| Agent SDK Python | v0.3.163 |

## ✨ New Features

### Proactive Notification for Background Task Completion

Bash / powershell tasks started via `run_in_background` will automatically inject a `<task-notification>` into the conversation stream upon completion, failure, or termination. The model can perceive the task status change in the next turn, eliminating the need for `TaskOutput` / `BashOutput` polling loops and significantly reducing wasted turns.

## 🔧 Improvements

- **WebFetch Concurrent Competition Strategy**: The WebFetch tool changes from serial fallback to concurrent competition mode. Local fetch (30s timeout) and remote API (20s timeout) start concurrently; if the remote wins, the local request is cancelled immediately. If the remote fails, it falls back directly to the already-running local result. Worst-case total latency drops from `20s + 30s` to `max(20s, actual local latency)`, significantly improving web fetch responsiveness.
- **WebFetch Size Limit and Caching**: Remote API limits the maximum returned length to 100K characters; content exceeding 15K characters automatically triggers AI summarization to reduce context usage. Fetch results are cached for 15 minutes, reusing the cache directly to skip network requests on hits.
- **WebFetch Observability**: Added structured `webfetch.complete` / `webfetch.failed` telemetry events, including source (cache / api / local), per-branch latency, URL host/path, whether summarization was triggered, etc., facilitating diagnostics and alerting.
- **Background Task Tool Description Refresh**: Bash / powershell tool descriptions now explicitly state "completion will trigger an automatic notification, do not sleep / poll loop", guiding the model to avoid pointless polling.
- **Subagent Call Chain Tracing**: chat_message_send / response / tool_action and other events now include `parentConversationId`, aligned with chat_request_send; chat_message_status now includes correlation fields such as `rootRequestId`, `agentName`, and `agentType`, supporting end-to-end tracing of subagent / team call chains.
- **End-to-End traceId**: ACP agent generates a traceId that flows through Galileo session / tool reporting, enabling end-to-end tracing for a single conversation request; user ID is injected into trace resource attributes, improving log correlation in multi-user environments.
- **Auxiliary Feature Telemetry Filtering**: Auxiliary features such as prompt_suggestion, conversation_topic, and context_compact no longer report chat_message_send / response, reducing telemetry noise.

## 🐛 Bug Fixes

- **Message Loss After macOS Lock Screen / App Nap Wake-up**: After long lock screen wake-up, WeChat long polling and WeCom group bot long connections suffer hangs or dead connections because the system freezes the network stack, causing users to feel "messages were lost". Added a long-connection liveness watchdog that automatically aborts hung requests / rebuilds the WebSocket upon thaw to restore normal send/receive. The daemon heartbeat and wake-detection timer also remove unref to avoid being unrecoverable after system freeze.
- **Permission Dialog Not Closing After Click**: In IDE integration scenarios, when the TUI pops up a tool permission dialog, pressing a number key / Enter to approve left the dialog open and required ESC to close, while the task had actually started executing. Now adjusted to close the dialog synchronously first and then fire-and-forget the IDE-side cleanup, restoring the expected click-to-close behavior. Also fixed a race condition under bypassPermissions mode where the `AskPanel` never mounted on the first `AskUserQuestion` enqueue, leaving LoadingBox stuck on "waiting for permission".
- **Enterprise Policy Causing Task Creation Timeout**: Temporarily disabled the CLI-side enterprise custom model policy and enterprise skill upload policy to fix the task creation timeout they caused.
- **Model Thinking Intensity Switch Abnormality**: Fixed an issue where switching to a non-thinking model could still carry over the previous turn's thinking intensity, and filtered out invalid thinking intensity configurations to prevent incorrect values from entering the final request.
- **Team Agent Respawn Missing Correlation Fields**: Restore `rootRequestId` and `parentConversationId` on respawn, fixing the missing correlation fields caused by `.meta.json` absence.
- **EditTool Infinite Loop When Creating New File**: When `old_string=''` and the target file does not exist, skip the `hasBeenRead` check so the Edit tool can create new files like Write, fixing the previous infinite loop where "Edit reports Read first, Read reports file not found".
- **EditTool Error Message Includes File Path**: When parallel multi-file Edits fail, the error message now includes the specific absolute file path, no longer requiring you to dig through tool_call parameters to locate which file failed.

## 📝 Documentation Updates

- **Troubleshooting Doc Adds "Permission Dialog Unresponsive" Section**: The troubleshooting doc now lists key log TAGs such as `[Approve]` / `[Reject]` / `[dequeue]` / `[tool-permission]` and a "symptom → inference" mapping table, making it easier to reproduce / locate similar dialog hang issues.
