# 🚀 CodeBuddy Code v2.52.0 Release

## ✨ New Features

### Team View Switching

Quickly switch between different team member views using arrow keys. Press `↓` to enter switching mode, `←/→` to select a member, and `Enter` to confirm and switch to that member's view, allowing you to check conversation history and work progress in real time. The highlight preview and input box border color automatically sync when switching, keeping you informed of each member's work status at all times.

### Headless Mode

Added a lightweight headless build (45% smaller in size), supporting `--print`, `--serve`, and `--acp` for quick startup, ideal for CI/CD pipelines and automation integration scenarios.

## 🔧 Improvements

- **Major Startup Performance Boost**: Optimized the startup flow, reducing Application.start() time by 96% and memory usage by 31%, delivering a much smoother startup experience
- **Bun Native Optimization**: Replaced third-party dependencies (PTY, glob, semver, etc.) with Bun native APIs, improving runtime performance
- **Dependency Reduction**: Removed unused dependencies to reduce installation size
- **Authentication Timing Fix**: Ensured authentication completes before API calls, eliminating occasional 401 errors during cold starts
- **Model Sorting Optimization**: Adjusted default model priority order for the China edition, making commonly used models easier to select
- **Command Execution Stability**: Optimized command execution and environment initialization flow, reducing execution interruptions under abnormal conditions
- **Authentication Experience Enhancement**: Improved the robustness of the API Key Helper token acquisition process, enhancing authentication flow stability
- **Error Handling Upgrade**: Upgraded error handling from string matching to custom error classes, improving error identification reliability
- **Stream Timeout Auto-Retry**: Automatically retries when model streaming responses time out, requiring no manual intervention. Supports customizing timeout duration via the `CODEBUDDY_STREAM_TIMEOUT` environment variable
- **Command Suggestion Filtering**: Skills that cannot be invoked directly no longer appear in the slash command suggestion list, keeping the menu clean

## 🐛 Bug Fixes

- **Team Member Tool Permission Confirmation**: Fixed an issue where team members would skip permission confirmation when executing tools. Team members now correctly inherit the main Agent's permission mode; the permission confirmation dialog displays the member's name and dedicated color for easy identification
- **Plugin MCP Configuration Compatibility**: Fixed an issue where plugin `.mcp.json` did not support flat format. Both wrapped format and flat format are now supported
- **Team Member Status Display**: Fixed an issue where team members were incorrectly marked as failed due to the cleanup process after successfully completing tasks. Completed members now correctly display their completion status
