Commit log

995a265 zed 0.182.9

Joseph T. Lyons created

cc2168e Fix rejecting multiple hunks in `AgentDiff` (#28806)

Click to expand commit body
Release Notes:

- Fixed a bug that caused `Reject All` to not always reject _all_ the
hunks.

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>

Antonio Scandurra and Max Brunsfeld created

4032e03 markdown: Add ability to customize individual heading level (#28733)

Click to expand commit body
This PR adds a new field in the `MarkdownStyle` struct,
`heading_level_styles`, allowing, via the newly added function
`apply_heading_style` and struct `HeadingLevelStyles` to customize each
individual heading level in Markdown rendering/styling function.

Things like this should now be possible:

```rust
    MarkdownStyle {
        heading_level_styles: Some(HeadingLevelStyles {
            h1: Some(TextStyleRefinement {
                font_size: Some(rems(1.15).into()),
                ..Default::default()
            }),
        }),
        ..Default::default()
    }
```

Release Notes:

- N/A

Danilo Leal created

54dea92 agent: Show a warning when some tools are incompatible with the selected model (#28755)

Click to expand commit body
WIP

<img width="644" alt="image"
src="https://github.com/user-attachments/assets/b24e1a57-f82e-457c-b788-1b314ade7c84"
/>


<img width="644" alt="image"
src="https://github.com/user-attachments/assets/b158953c-2015-4cc8-b8ed-35c6fcbe162d"
/>


Release Notes:

- agent: Improve compatibility with Gemini Tool Calling APIs. When a
tool is incompatible with the Gemini APIs a warning indicator will be
displayed. Incompatible tools will be automatically excluded from the
conversation

---------

Co-authored-by: Danilo Leal <daniloleal09@gmail.com>

Bennet Bo Fenner and Danilo Leal created

5f2617d agent: Add ability to interrupt current generation with a new message (#28762)

Click to expand commit body
If you wanted to interrupt the current LLM response that's generating to
send a follow up message, you'd need to stop it first, type your new
message, and then send it. Now, you can just type your new message while
there's a response generating and send it. This will interrupt the
previous response generation and kick off a new one.

Release Notes:

- agent: Allow to send a new message while a response is generating,
interrupting the LLM to focus instead on the most recent prompt.

Danilo Leal created

4c572ee agent: Return `ToolResult` from `run` inside `Tool` (#28763)

Click to expand commit body
This is just a refactor which adds no functionality.
We now return a `ToolResult` from `Tool > run(...)`. For now this just
wraps the output task in a struct. We'll use this to implement custom
rendering of tools, see #28621.

Release Notes:

- N/A

Bennet Bo Fenner created

756fb87 hover_popover: Fix markdown selection for info and diagnostic popovers (#28642)

Click to expand commit body
Closes #28638

This PR fixes markdown selection for the info and diagnostic popovers.

In the editor popover, after the changes in
https://github.com/zed-industries/zed/pull/28255, the markdown selection
state updates correctly, but it no longer triggers the editor element to
repaint like it used to. This is fixed by adding a subscription to
listen for markdown entity changes and triggering a repaint for the
editor.

I assume markdown selection works elsewhere because:

1. Either the `Markdown` entity is directly part of a struct that
implements the `Render` trait, causing it to repaint whenever the
markdown state changes. See
[here](https://github.com/zed-industries/zed/blob/d1ffda9bfeccfdf9bea3f76251350bf9cf7f6e1b/crates/ui_prompt/src/ui_prompt.rs#L65).
2. OR it's wrapped around component like Popover which implements
`RenderOnce` trait. See
[here](https://github.com/zed-industries/zed/blob/d1ffda9bfeccfdf9bea3f76251350bf9cf7f6e1b/crates/editor/src/code_context_menus.rs#L645).

Whereas info and diagnostic popovers does not do both. I do think we can
change it to use `Popover` component, but for now this works as quick
fix.

Extras:
- Remove unnecessary struct cloning.
- Refactor rendering logic to use `when_some`.

Release Notes:

- Fixed issue where selection wasn't working for info and diagnostic
popovers.

Smit Barmase created

255e5b6 agent: Adjust markdown heading sizes (#28759)

Click to expand commit body
Adjust the heading sizes for the Agent Panel so they're not aggressively
huge.

Release Notes:

- N/A

Danilo Leal created

6beb3ad agent: Make `ToolWorkingSet` an `Entity` (#28757)

Click to expand commit body
Motivation is to emit events when enabled tools change, want to use this
in #28755

Release Notes:

- N/A

Bennet Bo Fenner created

5e0c076 agent: Improve compatibility when using MCP servers with Gemini models (#28700)

Click to expand commit body
WIP

Release Notes:

- agent: Improve compatibility when using MCPs with Gemini models

Bennet Bo Fenner created

ba008fc Add contents_tool (#28738)

Click to expand commit body
This is a combination of the "read file" and "list directory contents"
tools as part of a push to reduce our quantity of builtin tools by
combining some of them.

The functionality is all there for this tool, although there's room for
improvement on the visuals side: it currently always shows the same icon
and always says "Read" - so you can't tell at a glance when it's reading
a directory vs an individual file. Changing this will require a change
to the `Tool` trait, which can be in a separate PR. (FYI @danilo-leal!)

<img width="606" alt="Screenshot 2025-04-14 at 11 56 27 PM"
src="https://github.com/user-attachments/assets/bded72af-6476-4469-97c6-2f344629b0e4"
/>

Release Notes:

- Added `contents` tool

Richard Feldman created

4dcf10f Bump to 0.182.8 for @bennetbo

Zed Bot created

42015f1 gemini: Fix "invalid argument" error when request contains no tools (cherry-pick #28747) (#28750)

Click to expand commit body
Cherry-picked gemini: Fix "invalid argument" error when request contains
no tools (#28747)

When we do not have any tools, we want to set the `tools` field to
`None`

Release Notes:

- Fixed an issue where Gemini requests would sometimes return a Bad
Request ("Invalid argument...")

Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>

gcp-cherry-pick-bot[bot] and Bennet Bo Fenner created

c4265f4 agent: Add some design tweaks (#28726)

Click to expand commit body
Fine-tuning some areas of the Agent Panel design.

Release Notes:

- N/A

Danilo Leal created

abe5588 agent: Apply soft-wrap when message editor is expanded (#28716)

Click to expand commit body
Release Notes:

- N/A

Bennet Bo Fenner created

8adbe5a zed 0.182.7

Peter Tripp created

68bc185 assistant_tools: Fix code_action and rename schemas for Gemini (#28634)

Click to expand commit body
Closes #28475

Updates `rename` and `code_action` `input_schema` methods to use
`json_schema_for<T>()` which transforms standard JSONSchema into the
subset required by Gemini.
Also makes `input_schema` implementations consistent.
Tested tools against Gemini 2.5 Pro Preview, Zed Claude 3.7 Sonnet
Thinking, o3-mini

Release Notes:

- Agent Beta: Fixed error 400 `INVALID_ARGUMENT` when using Gemini with
`code_actions` or `rename` tools enabled.

duvetfall created

252f48c Add support for OpenAI GPT-4.1 models (#28708)

Click to expand commit body
Release Notes:

- Add support for OpenAI GPT-4.1 via Copilot Chat and OpenAI API

---------

Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>

Umesh Yadav , Danilo Leal , and Bennet Bo Fenner created

9514fba copilot_chat: Add Gemini 2.5 Pro support to Copilot Chat (#28660)

Richard Hao created

70ff2dd agent: Check built-in tools schema compatibility in tests (#28691)

Click to expand commit body
This ensures that we respect the `LanguageModelToolSchemaFormat` value
when we call `tool.input_schema`. This prevents us from breaking Gemini
compatibility when adding/changing built-in tools. See #28634.

The test suite will now fail with an error message like this, when
providing an incompatible input_schema:

```
thread 'tests::test_tool_schema_compatibility' panicked at crates/assistant_tools/src/assistant_tools.rs:108:17:
Tool schema for `code_actions` is not compatible with `language_model::LanguageModelToolSchemaFormat::JsonSchemaSubset` (Gemini Models).
Are you using `schema::json_schema_for<T>(format)` to generate the schema?
```


Release Notes:

- N/A

Bennet Bo Fenner created

2093e21 agent: Add scrollbar to the history view (#28690)

Click to expand commit body
Ended up not making this one visible only upon hover or something
because the layout alignment would be weird given the list item spans
the full width. So, experimenting with this design here:

<img
src="https://github.com/user-attachments/assets/62bf661e-1aae-4644-8a89-49cefb3e8130"
width="700" />

Release Notes:

- agent: Add scrollbar to the history view.

Danilo Leal created

b183df1 agent: Handle context window exceeded errors from Anthropic (#28688)

Click to expand commit body
![CleanShot 2025-04-14 at 11 15
38@2x](https://github.com/user-attachments/assets/9e803ffb-74fd-486b-bebc-2155a407a9fa)

Release Notes:

- agent: Handle context window exceeded errors from Anthropic

Agus Zubiaga created

a9a0ff2 agent: Clean up thread auto-capturing (#28550)

Click to expand commit body
This PR cleans up the thread auto-capturing added in #28271.

- Removed usage of `unsafe`
- Fixed feature flag check
- We were incorrectly not respecting the feature flag in release builds
- Made sure the telemetry event was being run on the background executor

Release Notes:

- N/A

Marshall Bowers created

e234399 agent: Auto-capture telemetry feature flag (#28271)

Click to expand commit body
Release Notes:

- N/A

Thomas Mickley-Doyle created

73d6e2d agent: Move focus to the message editor after going back (#28686)

Click to expand commit body
When you hit the back button in the agent panel toolbar, we were
returning the focus to the buffer instead to the panel's message editor,
which is likely where you want to be after quickly checking history or
settings.

Release Notes:

- N/A

Danilo Leal created

e8930c5 agent: Fix expand message editor while not focused (#28650)

Click to expand commit body
Allow expanding the message editor while the agent panel is not focused,
right now there is no effect when you use the button from another focus

Release Notes:

- N/A

5brian created

c4e9bf8 zed 0.182.6

Joseph T. Lyons created

d71ef64 agent: Display keybindings for "Reject All" and "Keep All" (#28620)

Click to expand commit body
<img
src="https://github.com/user-attachments/assets/2cdc5121-dd7b-4f46-8d43-88d5152c77ea"
width="550" />


Release Notes:

- N/A

Danilo Leal created

b71c31a agent: Increase message editor height (#28618)

Click to expand commit body
It was too tiny, felt like we could use more breathing room.

Release Notes:

- N/A

Danilo Leal created

ddf0f4b agent: Adjust MCP section in the settings view (#28615)

Click to expand commit body
Mentioning "MCP" more prominently, adding tool descriptions in the icon
button tooltip, and other UI adjustments.

<img
src="https://github.com/user-attachments/assets/e021b3be-99b8-454c-b5fd-0221a7947a35"
width="600" />

Release Notes:

- N/A

Danilo Leal created

93b05d3 agent: Add "Install MCPs" to panel menu (#28616)

Click to expand commit body
Also took the opportunity to rename the "Continue in New Thread" item to
a potentially clearer name.

<img
src="https://github.com/user-attachments/assets/024de07d-f215-4c41-8fbe-652a216b61d9"
width="300"/>

Release Notes:

- N/A

Danilo Leal created

a9e3ce1 agent: Cleanup `message_editor` (#28614)

Click to expand commit body
This PR splits up the rendering of the message editor into multiple
functions. Previously we had a single `h_flex()...` expression which
spanned across 550 lines, `cargo fmt` stopped working.

Release Notes:

- N/A

Bennet Bo Fenner created

895b81d agent: Only show recommended models that are actually configured (#28613)

Click to expand commit body
Release Notes:

- N/A

Bennet Bo Fenner created

115a462 agent: Remove unused code (#28552)

Click to expand commit body
This code was used before we had a proper completion menu for
at-mentions

Release Notes:

- N/A

Bennet Bo Fenner created

5c2f88e agent: Refine language model selector (#28597)

Click to expand commit body
Release Notes:

- agent: Show recommended models in the agent model selector and display
the provider in the model selector's trigger.

---------

Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Co-authored-by: Danilo Leal <67129314+danilo-leal@users.noreply.github.com>

Bennet Bo Fenner , Danilo Leal , and Danilo Leal created

d981015 agent: Register tracked buffers with language servers (#28610)

Click to expand commit body
Release Notes:

- agent: Start language servers when accessing files via tools

Co-authored-by: Michael <michael@zed.dev>

Agus Zubiaga and Michael created

ad92f31 zed 0.182.5

Joseph T. Lyons created

0aa2e36 Backport git store bugfix to v0.182.x (#28593)

Click to expand commit body
Closes #ISSUE

Release Notes:

- Fixed a bug that could cause the staged status of entries in the git
panel to be stale.

Cole Miller created

47b6eb1 Try to weak-link ScreenCaptureKit always (cherry-pick #28585) (#28591)

Click to expand commit body
Cherry-picked Try to weak-link ScreenCaptureKit always (#28585)

Release Notes:

- Fixed a crash on macOS (Catalina, Big Sur). Users may need to manually
redownload Zed if they updated to a broken release.
([#28585](https://github.com/zed-industries/zed/pull/28585))

Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>

gcp-cherry-pick-bot[bot] and Conrad Irwin created

bb151eb Fix a panic in the git store (cherry-pick #28590) (#28595)

Click to expand commit body
Cherry-picked Fix a panic in the git store (#28590)

Closes #ISSUE

Release Notes:

- Fixed a panic that could occur when git statuses were updated.

Co-authored-by: Cole Miller <cole@zed.dev>

gcp-cherry-pick-bot[bot] and Cole Miller created

1e2b986 zed 0.182.4

Joseph T. Lyons created

42c6cce agent: Fix bug where wrong crease for @mention would be displayed (#28558)

Click to expand commit body
Release Notes:

- agent: Fix a bug where an inserted @mention did not show up as the one
that was selected

Bennet Bo Fenner created

70182ba agent: Fix "new text thread" action name (#28555)

Click to expand commit body
Moving from "NewPromptEditor" to "NewTextThread". We recently re-named
that and this was missing.

Release Notes:

- N/A

Danilo Leal created

aba9875 agent: Make the message editor expandable (#28420)

Click to expand commit body
This PR allows expanding the message editor textarea to fit almost the
total height of the Agent Panel. Stylistically, I'm also changing the
font family we use in the textarea to use the buffer font; want to
experiment with this for a bit.

Release Notes:

- agent: The Agent Panel textarea can now be expanded to fill almost the
total height of the panel.

---------

Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>

Danilo Leal , Bennet Bo Fenner , and Bennet Bo Fenner created

243b046 editor: Refactor `EditorMode::Full` (#28546)

Click to expand commit body
This PR lightly refactors the `EditorMode::Full` exposing two new
methods: `is_full` and `set_mode`.

Motivation is to expose fields that modify the behavior when the editor
is in `Full` mode. By using is `mode.is_full()` instead of
`EditorMode::Full` we can introduce new fields without breaking other
places in the code.

Release Notes:

- N/A

Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>

Danilo Leal and Bennet Bo Fenner created

47edd4a Bump to 0.182.3 for @maxdeviant

Zed Bot created

d487d46 Actually run the eval and fix a hang when retrieving outline (#28547)

Click to expand commit body
Release Notes:

- Fixed a regression that caused the agent to hang sometimes.

---------

Co-authored-by: Thomas Mickley-Doyle <tmickleydoyle@gmail.com>
Co-authored-by: Nathan Sobo <nathan@zed.dev>
Co-authored-by: Michael Sloan <mgsloan@gmail.com>

Antonio Scandurra , Thomas Mickley-Doyle , Nathan Sobo , and Michael Sloan created

d1dcbba markdown: Track code block metadata in parser (#28543)

Click to expand commit body
This allows us to not scan the codeblock content for newlines on every
frame in `active_thread`

Release Notes:

- N/A

Bennet Bo Fenner created

3430d43 Change zed.dev's default model to Claude 3.7 Sonnet (#28541)

Click to expand commit body
From Claude 3.5 Sonnet to **Claude 3.7 Sonnet**.

Release Notes:

- Change the default model of Zed's hosted LLM service to Claude 3.7
Sonnet.

Danilo Leal created

16395bd language_models: Fix non-streaming Copilot Chat models (#28537)

Click to expand commit body
This PR fixes usage of non-streaming Copilot Chat models.

Closes https://github.com/zed-industries/zed/issues/28528.

Release Notes:

- Fixed an issue with using non-streaming Copilot Chat models (e.g., o1,
o3-mini).

Marshall Bowers created