Commit graph

23914 commits

Author SHA1 Message Date
Conrad Irwin
dc84c736be
Hide old Agent UI when ACP flag set (#36533)
- **Use key value store instead of JSON**
- **Default NewThread to the native agent when flagged**

Closes #ISSUE

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2025-08-23 10:39:24 -04:00
Julia Ryan
5df0807f77
Attach minidump errors to uploaded crash events (#36527)
We see a bunch of crash events with truncated minidumps where they have
a valid header but no events. We think this is due to an issue
generating them, so we're attaching the relevant result to the uploaded
tags.

Release Notes:

- N/A

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2025-08-23 10:39:24 -04:00
Conrad Irwin
6ec4b80b7b
Rebuild recently opened threads for ACP (#36531)
Closes #ISSUE

Release Notes:

- N/A
2025-08-23 10:39:24 -04:00
Julia Ryan
7c1fe1b731
Suspend macOS threads during crashes (#36520)
This should improve our detection of which thread crashed since they
wont be able to resume while the minidump is being generated.

Release Notes:

- N/A
2025-08-23 10:39:24 -04:00
Bennet Bo Fenner
5c9ccc390b
agent2: Token count (#36496)
Release Notes:

- N/A

---------

Co-authored-by: Agus Zubiaga <agus@zed.dev>
2025-08-23 10:39:23 -04:00
Piotr Osiewicz
0d2f70ee8c
Another batch of lint fixes (#36521)
- **Enable a bunch of extra lints**
- **First batch of fixes**
- **More fixes**

Release Notes:

- N/A
2025-08-23 10:39:23 -04:00
Piotr Osiewicz
f61482151a
Fix a bunch of other low-hanging style lints (#36498)
- **Fix a bunch of low hanging style lints like unnecessary-return**
- **Fix single worktree violation**
- **And the rest**

Release Notes:

- N/A
2025-08-23 10:39:23 -04:00
Cole Miller
2a4db70df6
thread_view: Fix issues with images (#36509)
- Clean up failed load tasks for mentions that require async processing
- When dragging and dropping files, hold onto added worktrees until any
async processing has completed; this fixes a bug when dragging items
from outside the project

Release Notes:

- N/A
2025-08-23 10:39:23 -04:00
Umesh Yadav
03d773da99
onboarding: Fix theme selection in system mode (#36484)
Previously, selecting the "System" theme during onboarding would
hardcode the theme based on the device's current mode (e.g., Light or
Dark). This change ensures the "System" setting is saved correctly,
allowing the app to dynamically follow the OS theme by inserting the
correct theme in the config for both light and dark mode.

Release Notes:

- N/A

Signed-off-by: Umesh Yadav <git@umesh.dev>
2025-08-23 10:39:23 -04:00
Conrad Irwin
a73802242a
Re-add history entries for native agent threads (#36500)
Closes #ISSUE

Release Notes:

- N/A

---------

Co-authored-by: Antonio Scandurra <me@as-cii.com>
2025-08-23 10:39:23 -04:00
Bennet Bo Fenner
4ab3d5d1d0
agent2: Fix tool schemas for Gemini (#36507)
Release Notes:

- N/A

---------

Co-authored-by: Agus Zubiaga <agus@zed.dev>
2025-08-23 10:39:23 -04:00
fantacell
6bd4372f32
helix: Uncomment one test (#36328)
There are two tests commented out in the helix file, but one of them
works again. I don't know if this is too little a change to be merged,
but I wanted to suggest it.
The other test might be more complicated though, so I didn't touch it.

Release Notes:

- N/A
2025-08-23 10:39:23 -04:00
Agus Zubiaga
dc9ed7ab94
Split external agent flags (#36499)
Release Notes:

- N/A
2025-08-23 10:39:23 -04:00
Lukas Wirth
fcd95cc0e7
editor: Fix inline diagnostics min column inaccuracy (#36501)
Closes https://github.com/zed-industries/zed/issues/33346

Release Notes:

- Fixed `diagnostic.inline.min_column` being inaccurate
2025-08-23 10:39:23 -04:00
Lukas Wirth
489906c64b
editor: Render dirty and conflict markers in multibuffer headers (#36489)
Release Notes:

- Added rendering of status indicators for multi buffer headers
2025-08-23 10:39:23 -04:00
Smit Barmase
a049c37d01
lsp: Enable dynamic registration for TextDocumentSyncClientCapabilities post revert (#36494)
Follow up: https://github.com/zed-industries/zed/pull/36485

Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Cole Miller
fa5ff2bd98
Fix Windows test failures not being detected in CI (#36446)
Bug introduced in #35926 

Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Antonio Scandurra
c65d113f5b
Lay the groundwork to support history in agent2 (#36483)
This pull request introduces title generation and history replaying. We
still need to wire up the rest of the history but this gets us very
close. I extracted a lot of this code from `agent2-history` because that
branch was starting to get long-lived and there were lots of changes
since we started.

Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Piotr Osiewicz
68d37d3818
Fix unnecessary-mut-passed lint (#36490)
Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Smit Barmase
99d86ac919
project: Take 2 on Handle textDocument/didSave and textDocument/didChange (un)registration and usage correctly (#36485)
Relands https://github.com/zed-industries/zed/pull/36441 with a
deserialization fix.

Previously, deserializing `"includeText"` into
`lsp::TextDocumentSyncSaveOptions` resulted in a `Supported(false)` type
instead of `SaveOptions(SaveOptions { include_text: Option<bool> })`.

```rs
impl From<bool> for TextDocumentSyncSaveOptions {
    fn from(from: bool) -> Self {
        Self::Supported(from)
    }
}
```

Looks like, while dynamic registartion we only get `SaveOptions` type
and never `Supported` type.
(https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocumentSaveRegistrationOptions)

Release Notes:

- N/A

---------

Co-authored-by: Lukas Wirth <lukas@zed.dev>
2025-08-23 10:39:22 -04:00
Piotr Osiewicz
780d5c7d35
Auto-fix clippy::collapsible_if violations (#36428)
Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Lukas Wirth
b399264622
Revert "project: Handle textDocument/didSave and textDocument/didChange (un)registration and usage correctly (#36441)" (#36480)
This reverts commit c5991e74bb.

This PR broke rust-analyzer's check on save function, so reverting for
now

Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Bennet Bo Fenner
cfcf88b5d5
agent: Remove thread-auto-capture feature (#36474)
We never ended up using this in practice (the feature flag is not
enabled for anyone, not even staff)

Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Bennet Bo Fenner
711fcb24e0
agent2: Support preferred_completion_mode setting (#36473)
Release Notes:

- N/A
2025-08-23 10:39:22 -04:00
Bennet Bo Fenner
6ebd617d40
agent2: Fix agent location still being present after thread stopped (#36471)
Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Lukas Wirth
c59d2dcc6d
search: Fix project search query flickering (#36470)
Release Notes:

- N/A

Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
2025-08-23 10:39:21 -04:00
Bennet Bo Fenner
0155488955
agent2: Port retry logic (#36421)
Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Smit Barmase
621fcb3c07
editor: Fix edit_predictions_disabled_in not disabling predictions (#36469)
Closes #25744

Only setting changes and editor init determined whether to show
predictions, so glob patterns and toggles correctly disabled them. On
cursor changes we call `update_visible_edit_prediction`, but we weren’t
discarding predictions when the scope changed. This PR fixes that.

Release Notes:

- Fixed an issue where the `edit_predictions_disabled_in` setting was
ignored in some cases.
2025-08-23 10:39:21 -04:00
Bennet Bo Fenner
3235b97e8c
agent2: Port rules UI (#36429)
Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Piotr Osiewicz
87352b04c9
gpui: Introduce stacker to address stack overflows with deep layout trees (#35813)
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Co-authored-by: Ben Kunkle <ben@zed.dev>

Release Notes:

- N/A

Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Co-authored-by: Ben Kunkle <ben@zed.dev>
2025-08-23 10:39:21 -04:00
tidely
3a40d598e1
Fix iterator related clippy style lint violations (#36437)
Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
0x5457
9501b48c15
Avoid symlink conflicts when re-extracting eslint-xx.tar.gz (#36068)
Closes #34325

**Background**
When upgrading/reinstalling the ESLint language server, extracting the
archive over an existing version directory that contains symlinks can
fail and interrupt the installation.
```
failed to unpack .../vscode-eslint-2.4.4/.../client/src/shared
File exists (os error 17) when symlinking ../../$shared/ to .../client/src/shared
```

**Root cause**
Extracting into a non-empty directory conflicts with leftover
files/symlinks (e.g., `client/src/shared -> ../../$shared`), causing
“File exists (os error 17)”.

When `fs::metadata(&server_path).await.is_err()` is true, the code falls
back to cached_server_binary, but that still targets the same
(potentially corrupted/half-installed) directory and does not run `npm
install` or `npm run compile`, so the system cannot recover and remains
broken.

**Change**
Before downloading and extracting, delete the target version directory
(vscode-eslint-<version>) to ensure an empty extraction destination and
avoid conflicts.

**Alternative approaches**
temp directory + rename: extract into a clean temp directory and rename
into place to avoid half-installed states

[async-tar](https://github.com/dignifiedquire/async-tar) enhancement:
tolerate already-existing symlinks (or add a “replace-existing” option).

Release Notes:

- Fixed eslint installation not clearing files after previous attempts'
2025-08-23 10:39:21 -04:00
Cole Miller
226eed8f53
Prevent sending slash commands in CC threads (#36453)
Highlight them as errors in the editor, and add a leading space when
sending them so users don't hit the odd behavior when sending these
commands to the SDK.

Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Cole Miller
4af757d578
agent2: Support directories in @file mentions (#36416)
Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Cole Miller
e9cf3ac721
agent2: Add hover preview for image creases (#36427)
Note that (at least for now) this only works for creases in the "new
message" editor, not when editing past messages. That's because we don't
have the original image available when putting together the creases for
past messages, only the base64-encoded language model content.

Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Michael Sloan
d1e69ed9dc
Fix InlineCompletion -> EditPrediction keymap migration (#36457)
Accidentally regressed this in #35512, causing this migration to not
work and an error log to appear when one of these actions is in the user
keymap

Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Marshall Bowers
7ada5cd48d
collab: Add orb_subscription_id to billing_subscriptions (#36455)
This PR adds an `orb_subscription_id` column to the
`billing_subscriptions` table.

Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Ben Kunkle
e099b0fae2
git: Suggest merge commit message in remote (#36430)
Closes #ISSUE

Adds `merge_message` field to the `UpdateRepository` proto message so
that suggested merge messages are displayed in remote projects.

Release Notes:

- git: Fixed an issue where suggested merge commit messages would not
appear for remote projects
2025-08-23 10:39:21 -04:00
Danilo Leal
5b67fd2cc2
ai onboarding: Adjust the Zed Pro banner (#36452)
Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Danilo Leal
3078f3c655
agent: Improve error and warnings display (#36425)
This PR refactors the callout component and improves how we display
errors and warnings in the agent panel, along with improvements for
specific cases (e.g., you have `zed.dev` as your LLM provider and is
signed out).

Still a work in progress, though, wrapping up some details.

Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Agus Zubiaga
f2059dda3f
claude: Respect always allow setting (#36450)
Claude will now respect the `agent.always_allow_tool_actions` setting
and will set it when "Always Allow" is clicked.

Release Notes:

- N/A
2025-08-23 10:39:21 -04:00
Marshall Bowers
623f6f536d
client: Make Client::sign_in_with_optional_connect a no-op when already connected to Collab (#36449)
This PR makes it so `Client::sign_in_with_optional_connect` does nothing
when the user is already connected to Collab.

This fixes the issue where clicking on a channel link would temporarily
disconnect you from Collab.

Release Notes:

- N/A
2025-08-23 10:39:20 -04:00
Kirill Bulatov
62d984b6f0
Remove an unused struct (#36448)
Release Notes:

- N/A
2025-08-23 10:39:20 -04:00
Marshall Bowers
24d98325be
terminal: Temporarily disable test_basic_terminal test (#36447)
This PR temporarily disables the `test_basic_terminal` test, as it
flakes on macOS.

Release Notes:

- N/A
2025-08-23 10:39:20 -04:00
tidely
e256f46659
terminal: Fix python venv path when spawning tasks on windows (#35909)
I haven't found any issues related to this, but it seems like currently
the wrong directory is added to the path when spawning tasks on windows
with a python virtual environment. I also deduplicated the logic at a
few places. The same constant exists in the languages crate, but we
don't want to pull an additional dependency just for this.

-1 papercut

Release Notes:

- Fix python venv path when spawning tasks on windows
2025-08-23 10:39:20 -04:00
Gregor
6bfdb554e0
Add multi selection support to UnwrapSyntaxNode (#35991)
Closes #35932
Closes #35933

I only intended to fix multi select in this, I accidentally drive-by
fixed the VIM issue as well. `replace_text_in_range` which I was using
before has two, to me unexpected, side-effects:
- it no-ops when input is disabled, which is the case in VIM's
Insert/Visual modes
- it takes the current selection into account, and does not just operate
on the given range (which I erroneously assumed before)

Now the code is using `buffer.edit` instead, which seems more lower
level, and does not have those side-effects. I was enthused to see that
it accepts a vec of edits, so I didn't have to calculate offsets for
following edits... until I also wanted to set selections, where I do
need to do it by hand. I'm still wondering if there is a simpler way to
do it, but for now it at least passes my muster

Release Notes:

- Added multiple selection support to UnwrapSyntaxNode action
- Fixed UnwrapSyntaxNode not working in VIM Insert/Visual modes
2025-08-23 10:39:20 -04:00
Piotr Osiewicz
455a95c81d
Fix clippy::needless_borrow lint violations (#36444)
Release Notes:

- N/A
2025-08-23 10:39:20 -04:00
localcc
8ae47a60d4
Fix early dispatch crash on windows (#36445)
Closes #36384

Release Notes:

- N/A
2025-08-23 10:39:20 -04:00
Smit Barmase
efd929e20a
project: Handle textDocument/didSave and textDocument/didChange (un)registration and usage correctly (#36441)
Follow-up of https://github.com/zed-industries/zed/pull/35306

This PR contains two changes:

Both changes are inspired from:
d90a87f955/client/src/common/textSynchronization.ts

1. Handling `textDocument/didSave` and `textDocument/didChange`
registration and unregistration correctly:

```rs
#[derive(Debug, Eq, PartialEq, Clone, Deserialize, Serialize)]
#[serde(untagged)]
pub enum TextDocumentSyncCapability {
    Kind(TextDocumentSyncKind),
    Options(TextDocumentSyncOptions),
}
```

- `textDocument/didSave` dynamic registration contains "includeText"
- `textDocument/didChange` dynamic registration contains "syncKind"

While storing this to Language Server, we use
`TextDocumentSyncCapability::Options` instead of
`TextDocumentSyncCapability::Kind` since it also include
[change](be7336e92a/src/lib.rs (L1714-L1717))
field as `TextDocumentSyncCapability::Kind` as well as
[save](be7336e92a/src/lib.rs (L1727-L1729))
field as `TextDocumentSyncSaveOptions`. This way while registering or
unregistering both of them, we don't accidentaly mess with other data.

So, if at intialization we end up getting
`TextDocumentSyncCapability::Kind` and we receive any above kind of
dynamic registration, we change `TextDocumentSyncCapability::Kind` to
`TextDocumentSyncCapability::Options` so we can store more data anyway.

2. Modify `include_text` method to only depend on
`TextDocumentSyncSaveOptions`, instead of depending on
`TextDocumentSyncKind`. Idea behind this is,
`TextDocumentSyncSaveOptions` should be responsible for
"textDocument/didSave" notification, and `TextDocumentSyncKind` should
be responsible for "textDocument/didChange", which it already is:
4b79eade1d/crates/project/src/lsp_store.rs (L7324-L7331)

Release Notes:

- N/A
2025-08-23 10:39:20 -04:00
Agus Zubiaga
1b270842a3
Handle auth for claude (#36442)
We'll now use the anthropic provider to get credentials for `claude` and
embed its configuration view in the panel when they are not present.

Release Notes:

- N/A
2025-08-23 10:39:20 -04:00