52ea501
Fix multicursors not being added when clicking on line numbers (#28263)
Click to expand commit body
Closes https://github.com/zed-industries/zed/issues/21372
Release Notes:
- Fixed multicursors not being added when clicking on line numbers
-----
I tracked this down to
https://github.com/zed-industries/zed/blob/b6ee367ee0e62a111164dd6e09c534e7e48bad5a/crates/editor/src/element.rs#L591
being forwarded to `editor.select()` a few lines below
https://github.com/zed-industries/zed/blob/b6ee367ee0e62a111164dd6e09c534e7e48bad5a/crates/editor/src/element.rs#L667-L675
resulting in `add == true` and `click_count == 3`, triggering this
https://github.com/zed-industries/zed/blob/b6ee367ee0e62a111164dd6e09c534e7e48bad5a/crates/editor/src/editor.rs#L2750-L2752
... and we end up removing the previous selection.
This was added [in
2021](https://github.com/zed-industries/zed/commit/bfecdb7bc0e51ed1e37c8d0f61ceb27c5c6b5de9)
under this reasoning:
> This prevents selections added in earlier clicks from being rendered
under the pending selection.
which no longer seems to be an issue, so removing should be safe?
---------
Co-authored-by: Peter Tripp <peter@zed.dev>
When starting a selection from only carets, the action
`editor::SelectPrevious` behaved in a manner inconsistent with
`editor::SelectNext` as well as equivalent keybinds in editors such as
VSCode, by selecting substrings of whole words matching the initially
selected string on subsequent triggers.
This fix brings the `select_previous` function in line with
`select_next_internal`by calling `select_match_ranges` (previously an
internal function of `select_next_internal`) in the same way it was
previously used in the function that exhibited expected behavior.
Furthermore, the relevant test was adapted to bring it in line with the
equivalent test for the `editor::SelectNext` action
Closes #24346
Release Notes:
- Fixed inconsistent SelectPrevious behavior
Closes https://github.com/zed-industries/zed/issues/29821
Release Notes:
- Fixed an issue in the agent panel where OpenAI requests would fail if
the assistant begins its response with a tool call.
Max Brunsfeld
created
55fd835
assistant_slash_commands: Be more precise in content type matching (#29124)
Click to expand commit body
While investigating https://github.com/zed-industries/zed/issues/28076,
I found out often times the content type header of a website comes with
more data, such as the `charset`. So instead of doing an equal
comparison, I changed to a `starts_with`.
You can see an example here:
```shell
$ curl -sS -D - https://github.com/zed-industries/zed/blob/main/Cargo.toml -o /dev/null | head -n 10
HTTP/2 200
date: Sun, 20 Apr 2025 10:19:52 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame,Accept-Encoding, Accept, X-Requested-With
etag: W/"92dabf048b34d04a1b1d94e29cae4aca"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
```
Release Notes:
- Improved Content Type matching of `/fetch` commands in Assistant
Co-authored-by: Peter Tripp <peter@zed.dev>
Eva Pace
and
Peter Tripp
created
0b10eb7
Remove Tree-sitter AST logging from `SelectLargerSyntaxNode` (#29949)
Click to expand commit body
Release Notes:
- N/A
Michael Sloan
created
3d737fd
gpui: Update argument name of the `from_corners` method (#29968)
This PR further organizes and documents the component crate. It:
- Simplifies the component registry
- Gives access to `ComponentMetadata` sooner
- Enables lookup by id in preview extension implementations
(`ComponentId` -> `ComponentMetadata`)
- Should slightly improve the performance of ComponentPreview
It also brings component statuses to the Component trait:



Release Notes:
- N/A
Cleaning up as I introduced a few regressions in this PR:
https://github.com/zed-industries/zed/pull/29866.
Release Notes:
- N/A
Danilo Leal
created
bdd911f
Update `assistant` to `agent` in settings and keymaps (#29943)
Click to expand commit body
Closes #ISSUE
Release Notes:
- Agent Beta: Renamed the top-level `assistant` settings key to `agent`.
A migration for existing settings files is included.
- Agent Beta: Moved the `assistant::ToggleFocus`,
`assistant::ToggleModelSelector`, and `assistant::OpenRulesLibrary`
actions to the `agent` namespace. Existing keymaps that mention these
actions by their old names will continue to work.
---------
Co-authored-by: Max <max@zed.dev>
Cole Miller
and
Max
created
34e10e4
Honor the prompt field of inline assist action (#29960)
Click to expand commit body
Closes https://github.com/zed-industries/zed/issues/29337
Release Notes:
- Fixed a bug where the `prompt` field was ignored on custom key
bindings for `InlineAssist`
Co-authored-by: Michael Sloan <mgsloan@gmail.com>
Max Brunsfeld
and
Michael Sloan
created
275c808
Allow dragging files and tabs into the agent panel (#29959)
Click to expand commit body
Release Notes:
- Added the ability to drag files and tabs onto the new agent panel.
---------
Co-authored-by: Michael Sloan <mgsloan@gmail.com>
Max Brunsfeld
and
Michael Sloan
created
b214c9e
Fix profile menu hover flickering due to documentation asides (#29958)
This PR adds an upsell to try Zed Pro
Release Notes:
- N/A
---------
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
Nate Butler
and
Marshall Bowers
created
b4653c1
language: Add fallback for enum member completion highlight (#27929)
Click to expand commit body
i tried to use `variant` but it wasnt giving any color despite my theme
definitely having a color for it, am i doing something wrong? i think
`property` is an alright fallback
before:

after:

Release Notes:
- N/A
xdBronch
created
4896e0b
Allow the agent panel font size to be customized (#29954)
Click to expand commit body
You can set `agent_font_size` as a top-level settings key. You can also
use `zed::IncreaseBufferFontSize` and `zed::DecreaseBufferFontSize` and
`zed::ResetBufferFontSize` the agent panel is focused via the standard
bindings to adjust the agent font size. In the future, it might make
sense to rename these actions to be more general since "buffer" is now a
bit of a misnomer. 🍐'd with @mikayla-maki
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Nathan Sobo
and
Mikayla Maki
created
0bf682a
docs: Fix a broken link to the PyRight Settings section (#29283)
Click to expand commit body
This PR fixes a broken link to the PyRight Settings section.
This is a follow-up to 5f390f1bf80bd534a5c93d25613494df9ca20b23.
Release Notes:
- N/A
Noritada Kobayashi
created
3d0c4d7
Use the same context store for all inline assists in a project (#29953)
Click to expand commit body
Release Notes:
- Made context attachments in inline assist prompts persist across
inline assist invocations.
Co-authored-by: Michael Sloan <mgsloan@gmail.com>
Max Brunsfeld
and
Michael Sloan
created
b6c7df8
inline_completion_button: Show the initial usage data from the server (#29952)
Click to expand commit body
This PR updates the usage indicator for edit predictions to show the
initial usage data returned from the server.
Release Notes:
- N/A
Marshall Bowers
created
1aa92d9
debugger: Enable setting debug panel dock position to the side (#29914)
Click to expand commit body
### Preview
<img width="301" alt="Screenshot 2025-05-05 at 11 08 43 PM"
src="https://github.com/user-attachments/assets/aa445117-1c1c-4d90-a3bb-049f8417eca4"
/>
Setups the ground work to write debug panel persistence tests and allows
users to change the dock position of the debug panel.
Release Notes:
- N/A
Anthony Eid
created
6e28400
gpui: Fix a bug with Japanese romaji typing in input example (#28507)
Click to expand commit body
Steps to reproduce:
* On macOS, run `input` example
* type `aaa|bbb` place caret on the place marked with |
* switch to `japanese romaji`
* press `ko`
* press left arrow
<img width="412" alt="image"
src="https://github.com/user-attachments/assets/d3c02e9b-98f9-420e-a3b7-681ba90829cd"
/>
You will get `aaa` duplicated with every arrow press.
According to [reference
implementation](https://developer.apple.com/library/archive/samplecode/TextInputView/Listings/FadingTextView_m.html#//apple_ref/doc/uid/DTS40008840-FadingTextView_m-DontLinkElementID_6)
we need to unmark text when we get empty line in `setMarkedText `
Currently contains the pre-work of making sessions creatable without a
definition, but still need to change the spawn in terminal
to use the running session
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
WIP
- On macOS/Linux, run the command in bash instead of the user's shell
- Try to prevent the agent from running commands that expect interaction
Release Notes:
- Agent Beta: Switched to using `bash` (if available) instead of the
user's shell when calling the terminal tool.
- Agent Beta: Prevented the agent from hanging when trying to run
interactive commands.
---------
Co-authored-by: WeetHet <stas.ale66@gmail.com>
Cole Miller
and
WeetHet
created
9cb5ffa
context_store: Refactor state management (#29910)
Click to expand commit body
Because we instantiated `ContextServerManager` both in `agent` and
`assistant-context-editor`, and these two entities track the running MCP
servers separately, we were effectively running every MCP server twice.
This PR moves the `ContextServerManager` into the project crate (now
called `ContextServerStore`). The store can be accessed via a project
instance. This ensures that we only instantiate one `ContextServerStore`
per project.
Also, this PR adds a bunch of tests to ensure that the
`ContextServerStore` behaves correctly (Previously there were none).
Closes #28714
Closes #29530
Release Notes:
- N/A
Bennet Bo Fenner
created
8199664
agent: Handle attempts to use hallucinated tools (#29946)
Click to expand commit body
This change:
1. Catches attempts to use missing tools. If this happens, we now send
Agent a message listing available tools, after which Agent can
gracefully recover. Prior behavior: thread would stop in a broken state.
Example of a hallucinated call and a message we send back:

2. Adds evals for hallucinated tool use and imagined edits
3. Adds ability to configure a profile name in evals.
Release Notes:
- N/A
To-dos:
- [x] Expose the command to defend against cases where that's just super
long
- [x] Tackle the vertical scroll conflict with panel scroll
- [x] Reduce default font-size
Release Notes:
- N/A
---------
Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Co-authored-by: Agus Zubiaga <hi@aguz.me>
Danilo Leal
,
Ben Brandt
,
Mikayla Maki
, and
Agus Zubiaga
created
The goal of this PR is to support tool calls using ollama. A lot of the
serialization work was done in
https://github.com/zed-industries/zed/pull/15803 however the abstraction
over language models always disables tools.
## Changelog:
- Use `serde_json::Value` inside `OllamaFunctionCall` just as it's used
in `OllamaFunctionCall`. This fixes deserialization of ollama tool
calls.
- Added deserialization tests using json from official ollama api docs.
- Fetch model capabilities during model enumeration from ollama provider
- Added `supports_tools` setting to manually configure if a model
supports tools
## TODO:
- [x] Fix tool call serialization/deserialization
- [x] Fetch model capabilities from ollama api
- [x] Add tests for parsing model capabilities
- [ ] Documentation for `supports_tools` field for ollama language model
config
- [ ] Convert between generic language model types
- [x] Pass tools to ollama
Release Notes:
- N/A
---------
Co-authored-by: Antonio Scandurra <me@as-cii.com>
Co-authored-by: Nathan Sobo <nathan@zed.dev>
tidely
,
Antonio Scandurra
, and
Nathan Sobo
created
Completely subjective, but I just like it better.
Release Notes:
- N/A
---------
Co-authored-by: Danilo Leal <67129314+danilo-leal@users.noreply.github.com>
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Nathan Sobo
,
Danilo Leal
, and
Danilo Leal
created
7164124
agent panel: Bring back search within text threads (#29934)
Click to expand commit body
Release Notes:
- N/A
Michael Sloan
created
76c0ede
Add more documentation about ways to configure language servers and rust-analyzer (#29932)
Release Notes:
- `r enter` now maintains indentation, matching vim
Useful info for this implementation can be found here:
https://github.com/vim/vim/blob/c3f48e3a76c61884d7801171ced327b76965bf29/src/normal.c#L4865
The tool has been deleted, but the description remained.
Release Notes:
- N/A
Richard Feldman
created
10bdf39
collab: Pass down billing information in `UpdatePlan` message (#29929)
Click to expand commit body
This PR updates the `UpdatePlan` message to include some additional
information about the user's billing subscription usage.
Release Notes:
- N/A
Marshall Bowers
created
07b4480
editor: Handle more completions sort cases in Rust and Python (#29926)
Click to expand commit body
Closes #29725
Adds 3 more tests for Rust `into` and `await` cases, and Python
`__init__` case. Tweaks sort logic to accommodate them.
Release Notes:
- Improved code completion sort order, handling more cases with Rust and
Python.
Smit Barmase
created
b0414df
Simplify setting font size for EditToolCard (#29925)
Click to expand commit body
Release Notes:
- N/A
Antonio Scandurra
created
0246ec2
agent: Tweak MCP server configuration dialog (#29878)
Click to expand commit body
Tweaks the MCP configuration dialog a bit:
- Increase width of popover
- Disable soft
- Clear errors when hitting confirm
Release Notes:
- N/A
Bennet Bo Fenner
created
a72ade8
Show prompt usage in agent overflow menu (#29922)
Click to expand commit body
This PR adds prompt usage information, and easy access to managing your
account, to the agent overflow menu:

Currently this UI will only show after making a request. We'll work on
eagerly getting the usage info later.
Release Notes:
- Added current prompt usage information to the agent menu (`...`) for
Zed AI users
5674b5c
Don't show deleted hunks when agent overwrites file (#29918)
Click to expand commit body
Release Notes:
- Improved display of diffs when the agent rewrites a file from scratch.
Antonio Scandurra
created
4a7b3aa
zed: Fix migration message sometimes showing up on other tabs (#29917)
Click to expand commit body
<img width="1178" alt="image"
src="https://github.com/user-attachments/assets/6b76fe7d-0621-4d61-936e-bfe4f72cc614"
/>
Release Notes:
- Fixed an issue where the keymap/settings migration message sometimes
showing up on tabs other than `settings.json` and `keymap.json`.
Smit Barmase
created
c765da1
lsp: Don't log oneshot channel errors from notify (#29857)
Click to expand commit body
This is kind of noisy and not very informative.
Release Notes:
- N/A
Cole Miller
created
b404024
Get terminal tool working in evals (#29831)
Click to expand commit body
Bypass our terminal subsystem and just run a shell in a pty.
- [x] make sure we use the same working directory
- [x] strip control chars from the pty output (?)
- [x] tests
Release Notes:
- N/A
Cole Miller
created
ce053c9
Stop generating in the Agent panel when the user edits a previous message (#29915)
Click to expand commit body
Otherwise the panel keeps scrolling as the new token comes in and it is
almost impossible to keep the scroll position in the right place.
Also, if the user is editing, it is likely that the current generated
tokens will need to be regenerated anyway, so we may as well stop the
current progress.
Release Notes:
- Agent Beta: Stop generating tokens if previous messages are edited.