31e0d22
context_server: Mirror authorization server grant_types_supported
Click to expand commit body
In MCP OAuth, mirror the authorization server's grant_types_supported in the
DCR registration body instead of hardcoding just authorization_code.
Logfire's auth server requires both authorization_code and refresh_token
in grant_types, and we already uses refresh tokens, so the only issue
was not advertising the capability during registration. The DCR body now
intersects our supported grant types with what the server advertises, or
sends all of ours when the server metadata omits grant_types_supported.
Without this change, the Pydantic Logfire MCP auth server refuses our client registration.
Tom Houlé
created
0858f1c
title_bar: Fix worktree label showing `main` when opening a worktree directly (#54406)
Click to expand commit body
This PR fixes an issue where we'd show incorrect worktree labels when
opening a linked worktree directly. The linked worktree name would be
displayed in the project button but the dedicated worktree button would
be displaying "main", which is incorrect.
Now that we have a dedicated worktree button in the title bar, we can
make the project button always show the root repository name,
effectively matching the threads sidebar.
Release Notes:
- Fixed the title bar worktree button showing "main" when opening a
linked git worktree directly.
Danilo Leal
created
7c1078e
compliance: Temporarily fix the wrong compliance reports (#54401)
Click to expand commit body
This will be fully replaced by
https://github.com/zed-industries/zed/pull/54342 - however, this will
not help for the next week on the stable branch, since we have plenty of
non-signed commits on that branch currently.
Thus, adding this temporary check here to fix this and which is a
cherry-pickable change. This **will** be fully replaced by the linked
PR, however, I cannot cherry pick that since we would otherwise need to
force-push the branches to remove the bad commits.
Release Notes:
- N/A
Finn Evers
created
51fc26d
Fix agent default model not picking up after authentication resolve (#54397)
Click to expand commit body
Regression in https://github.com/zed-industries/zed/pull/54125
Release Notes:
- agent: Fixed an issue where the default Zed model would not get
selected after sign-in completed
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
Smit Barmase
,
Bennet Bo Fenner
, and
Ben Brandt
created
d4849cc
compliance: Add support for checking singular commit (#54369)
Click to expand commit body
This helps with two things: Testing changes locally against real commits
as well as laying the groundwork for making things less convoluted for
the GitHub worker.
Also removes some useless wrapping left from an earlier direction.
Release Notes:
- N/A
When images are resized to meet provider size constraints (Anthropic's
1568px limit or the 5MB encoded-PNG cap), the stored ImageSize was still
recording the original width/height rather than the final post-downscale
dimensions. This caused incorrect token estimation via estimate_tokens()
since it uses width * height / 750.
Use processed_image.dimensions() after all downscale passes so that
ImageSize reflects the actual image sent to the provider.
Release Notes:
- Fixed an issue where token estimation would be incorrect in case where
the thread contained downscaled images.
https://github.com/user-attachments/assets/e7a7903b-e133-4fbf-9267-3ebb17f867ff
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #43132
Release Notes:
- Fixed inlay hints navigating to the wrong position
Ramon
created
90c8629
agent_panel: Retain draft prompt when creating new draft thread (#54387)
Click to expand commit body
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #ISSUE
Release Notes:
- N/A
Bennet Bo Fenner
created
84dcf38
gpui: Improve Anchored to support center position (#47154)
Click to expand commit body
Release Notes:
- N/A
Ref https://github.com/longbridge/gpui-component/pull/1956 extract my
fork version of `anchored.rs` to let GPUI to support position Anchored
at center.
https://github.com/user-attachments/assets/8d0230ed-4b75-440b-b8c3-9bde3decd141
---------
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Jason Lee
and
Claude Sonnet 4.6
created
81b16f4
fuzzy_nucleo: Fix out of range panic (#54371)
Click to expand commit body
Closes ZED-6PK
The issue here was that we could hit cases where the amount of segments
< amount of CPUs, e.g. for 5 candidates and 4 CPUs, we would have 2
candidates per matcher, so for the fourth matcher, we would start
slicing at 3 * 2 = 6 > 5, which is out of bounds.
Instead, make it so that we distribute the candidates across all
matchers so that all matchers have either n or n + 1 candidates.
No release notes since this is only on Nightly.
Release Notes:
- N/A
Finn Evers
created
4a630f0
Fix rules files not loading and config file rescan clearing tokens (#53659)
Click to expand commit body
Fixes #52453
Fixes #53246
Both issues were introduced by #51208 ("Handle Linux FS Rescan Events"),
which added `PathEventKind::Rescan` handling.
## Rules files not loading (#52453)
`load_worktree_info_for_system_prompt` called `load_worktree_rules_file`
synchronously, which uses `entry_for_path()` on the current worktree
snapshot. If the background scanner hasn't finished its initial scan,
the entry doesn't exist yet and the lookup returns `None` — the code
concludes no rules file exists. This was always a latent race condition,
but became more visible after Rescan events were introduced, since they
can trigger additional `WorktreeUpdatedEntries` churn that interacts
with the refresh mechanism.
The fix awaits `scan_complete()` on local worktrees before performing
the rules file lookup, ensuring the full directory tree is indexed
first.
## Config file rescan clearing OAuth tokens (#53246)
The `Rescan` handlers in `watch_config_dir` used
`fs.load(file_path).await.unwrap_or_default()`, which turns any
file-read error into an empty string. This empty string flows to
consumers like `CopilotChat`, where `extract_oauth_token("")` returns
`None`, causing the OAuth token to be unconditionally overwritten with
`None` — triggering re-authentication.
The fix changes both Rescan handlers to skip files that fail to load
(using `if let Ok(contents) = ...`), matching the pattern already used
by the `Created`/`Changed` handler.
Release Notes:
- Fixed rules files (AGENTS.md, CLAUDE.md, .rules, etc.) sometimes not
being applied in agent threads.
- Fixed GitHub Copilot re-prompting for authentication after filesystem
rescan events.
Anders Jenbo
created
95b0c5a
Prefer exact case matches when breaking completion ties (#54072)
Click to expand commit body
## Summary
Fix completion ordering when two items are otherwise tied and only
differ by letter case.
In cases like `abc` vs `ABC`, if the user types `a`, Zed should prefer
`abc`. If the user types `A`, Zed should prefer `ABC`. This matches the
expectation described in #37081 and #27993, where `subscription` should
rank above `Subscription` for query `s`.
## What changed
In `CompletionsMenu::sort_string_matches`, I added a tie-breaker that
prefers completions with more exact case-sensitive matches at the
fuzzy-match positions.
This only applies after the existing higher-priority sort keys, so it
does not replace fuzzy score, match positions, snippet ordering, or LSP
`sortText`. It only resolves ambiguous ties more intuitively.
## Tests
Added regression coverage in `code_completion_tests` for abstract
case-only examples:
- `a` prefers `abc` over `ABC`
- `A` prefers `ABC` over `abc`
- `ab` prefers `abc` over `ABC`
- `AB` prefers `ABC` over `abc`
- mixed-case multi-letter queries like `Ab` and `aB`
## Verification
Ran:
```bash
cargo test -p editor code_completion_tests
```
PS: all code and description is generated by Codex
Release Notes:
- Fixed completions not tie braking by case
Sergey Borovikov
created
7620b78
Fix zed irresponsive on symlinked directory events outside the editor (#50746)
Click to expand commit body
Closes #48729, closes #27263, closes #45954
This PR aims to make zed responsive on symlinked directory events
outside the editor.
Before you mark this PR as ready for review, make sure that you have:
- [ ] Added a solid test coverage and/or screenshots from doing manual
testing
- [x] Done a self-review taking into account security and performance
aspects
- [ ] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
new-linked-folder is inside /zed-test/zed-project
output of ls -ld new-linked-folder
`lrwxr-xr-x 1 prayanshchhablani staff 42 28 Mar 23:20 new-linked-folder
-> /Users/prayanshchhablani/new-target-folder`
this shows new-linked-folder is a symlink folder whose target is
new-target-folder which is outside the root dir of the project opened in
zed.
https://github.com/user-attachments/assets/ffebafc3-2fc4-4293-bdbf-3a894a45e276
Release Notes:
- Fixed file watching of symlinks that point outside of the
project/watched directory. Zed should now properly respond to changes in
files in symlinked directories
prayansh_chhablani
created
68341e7
Clarify error message when attempting to delete channel with active participants (#54146)
Click to expand commit body
Previous error message when trying to delete channel with active
participants in call:
<img width="2880" height="1800" alt="image"
src="https://github.com/user-attachments/assets/b11a0d75-438d-468f-8fe4-e0c249dd096c"
/>
After change (tested locally)
<img width="474" height="304" alt="image"
src="https://github.com/user-attachments/assets/1e887411-a851-4dc8-83dc-881f690c0ad9"
/>
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #ISSUE
https://github.com/zed-industries/zed/issues/53572
Release Notes:
- N/A or Added/Fixed/Improved ...
Added a clear error message upon trying to delete channel with active
participants
## Summary
Paths inside parentheses without a preceding space (e.g.
`Update(.claude/skills/sandbox/SKILL.md)` or `Write(/test/cool.rs)` from
Claude Code output) were not clickable in the terminal. The `(`
character was allowed as a middle character in the default path
hyperlink regex, causing the entire `Update(.path/here` to be matched as
a single invalid path.
**Changes:**
- Remove `(` from the middle-chars alternation (`[:(]` → `:`) in the
default path hyperlink regex, so `(` always acts as a path boundary —
consistent with it already being excluded from first and last character
sets. Preserves upstream's space exclusion after `:`.
- Iterate all regex matches in the line instead of only the first, so
the correct path (which may be the second match after a prefix like
`Update`) is found. This also simplifies the code by removing the
separate hovered-word search logic.
**Known tradeoff:**
Filenames with parentheses in the middle (e.g.
`docker-compose.prod(copy).yml`) are no longer matched as a single path.
This is uncommon in terminal output contexts (compiler errors, stack
traces, tool output) and is documented with a `should_panic` test.
**What doesn't break:**
- `(/path/file.js:321:13)` — `(` at word start is excluded by the
first-char rule (unchanged)
- Node.js stack traces like `at fn (/path/file.js:10:5)` — space before
`(` makes it a separate word
- All 38 terminal hyperlink tests pass
Related: #18556, #23774
Release Notes:
- Fixed terminal path detection for paths inside parentheses without
preceding space (e.g. `Update(path)` or `Write(path)` patterns from CLI
tool output)
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Mikhail Butvin
and
Claude Opus 4.6 (1M context)
created
7db7ea9
terminal: Use system shell for non-terminal uses (like spinning up external agents) (#51741)
Click to expand commit body
Closes #46551
Zed was using the `terminal.shell` setting for some actions unrelated to
the terminal GUI, like environment capture, ACP agent startup, context
server startup, and vim `:!`, and so if a user set it to `tmux` or
`nushell`, those paths would fail.
This PR ensures paths unrelated to Zed's terminal use the system path
instead.
Manual testing:
Set `terminal.shell` to `tmux` or any another non-bash executable.
Starting an external agent thread shouldn't break.
Release Notes:
- Fixed ACP agent and other breakage when `terminal.shell` was set to a
non-shell program like `tmux`
Oliver Azevedo Barnes
created
62f0203
terminal: Send SIGTERM synchronously on terminal drop (#53107)
Click to expand commit body
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Partially addresses #51455
Release Notes:
- Fixed terminal child processes surviving after closing Zed by sending
SIGTERM synchronously on terminal drop
João Soares
created
5102ac1
Try to recover even harder from linux GPU errors (#54349)
Closes #45271
Zed hardcodes `ControlMaster=yes` with a `ControlPath` in a random temp
directory, so it can never find a ControlMaster session the user already
has open. This means you get prompted for credentials again even if
you're already authenticated.
This patch checks for an existing master before spawning a new one. It
runs `ssh -G` to resolve the user's configured `controlpath` (with `%h`,
`%p`, etc. already expanded), then `ssh -O check` to verify it's alive.
If it is, Zed skips askpass and uses the existing socket. If not, the
current behavior is unchanged. Both commands are local and don't hit the
network.
Also adds a `killed: AtomicBool` to `SshRemoteConnection` because
`has_been_killed()` was using `master_process.is_none()` as a proxy for
"connection is dead." When reusing an external master, `master_process`
starts as `None`, so the connection pool would discard it immediately.
Tested against a university SSH setup with `ControlMaster auto`
configured. The reuse path connects without prompting, and the fallback
path works normally when no master exists. Windows is unaffected.
Release Notes:
- Zed now reuses existing SSH ControlMaster sessions instead of
prompting for credentials again (#45271).
Nico
created
aa14c42
terminal_view: Don't try home_dir when working locally (#53071)
Click to expand commit body
When opening a remote session, sometimes you get a message:
/bin/bash: line 1: cd: /Users/pep: No such file or directory
which suggests that that the local home dir (/Users/pep) is used for the
remote terminal session, where it should be something like /home/ubuntu.
Release Notes:
- Fixed remote terminals incorrectly trying to change to a local home
directory.
040b03b
repl: Unify kernel searching in remote and wsl (#53049)
Click to expand commit body
### Context:
- Having a unified way of searching would allow for better debugging as
we move forward here. Right now we have remote/headless specific
searching and it's getting messy. This should allow for a more intuitive
function graph in the head for debugging environment related issues in
remote repl. The implementation mirrors python.rs approach.
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #50892
Release Notes:
- N/A
MostlyK
created
eb6e7d7
Fix Node.js language servers failing with `--user-data-dir` on Windows (#50767)
Click to expand commit body
Closes #50677.
Release Notes:
- Fixed Node.js language servers failing with `--user-data-dir` on
Windows
Kunall Banerjee
created
7d7ec65
terminal_view: Show hollow cursor when bar/underline is unfocused (#53713)
Click to expand commit body
Self-Review Checklist:**
- [x] I've reviewed my own diff for quality, security, and reliability
- [ ] Unsafe blocks (if any) have justifying comments
- [ ] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [X] Performance impact has been considered and is acceptable
## What
When terminal cursor shape is set via escape sequences (e.g. `\e[6 q`
for bar, `\e[4 q` for underline), the cursor looks identical whether the
terminal is focused or unfocused. Block cursors already convert to a
hollow outline when unfocused, but bar and underline were missing this
treatment.
## How
Added unfocused guards for `Beam` and `Underline` in the cursor shape
match in `terminal_element.rs`, converting them to `Hollow` when the
terminal loses focus. This follows the same pattern already used for
`Block`.
## Why this approach
A hollow block outline is the clearest unfocused signal and stays
consistent with the existing Block behavior. Alternative approaches like
dimming opacity or drawing outlined versions of bar/underline were
considered, but a 2px-wide outlined bar would be nearly invisible at
normal font sizes.
## Demo:
Before:
https://github.com/user-attachments/assets/81d49899-0837-42fe-a68f-4eb745892af6
After:
https://github.com/user-attachments/assets/a4444e28-5835-4c9f-872f-e9ce8c4805a0
Closes #52716
Release Notes:
- Fixed terminal bar and underline cursors set via escape sequences not
visually distinguishing between focused and unfocused states
João Soares
created
e4d0c89
cli: Make `zed --wait --diff` not wait until window close (#54367)
Click to expand commit body
`zed --wait --diff <left> <right>` currently waits for the entire window
to close instead of just the diff itself, due to the combination of
- `zed --diff` adds the cwd to the paths to open (see #45131), and
- passing a directory to `zed --wait` blocks until the Zed window is
closed (see #44936), which doesn't distinguish between explicit paths
and the one `zed --diff` adds
Fixed by only running the `zed --wait <dir>` logic to block until the
window is closed in case the user actually passed any non-diff paths.
I've confirmed locally that it works, though I wasn't really sure how to
write a good test for this.
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Release Notes:
- `zed --wait --diff <left> <right>` now blocks until the diff is
closed, and not until the entire window is closed.
Tim Vermeulen
created
d84a00c
sidebar: Improve hover in history view thread items (#54370)
Click to expand commit body
This PR improves the hover state in thread items within the history view
by making them more stable. There were other thread events calling a
refresh, which would clear the hover state even though I'd still be
hovering the item, making the buttons that only appear on hover feel
unstable and disappear.
Release Notes:
- Agent: Improve hover state stability on thread items within the
sidebar's history view.
Danilo Leal
created
d7eeb5c
sidebar: Adjust display of workspaces in header's ellipsis menu (#54360)
Click to expand commit body
This PR only displays the X icon button to close an workspace when the
number of available ones is bigger than one, and does some light UI
tweaks to how we display the project labels inside the menu item.
Release Notes:
- N/A
Danilo Leal
created
aa5293d
Avoid constantly scrolling thread history to top as agent generates (#54365)
Click to expand commit body
Fixes two problems:
* We were not preserving scroll position in the thread history view when
the thread metadata store updated
* We were updating thread metadata on every single chunk streamed by the
agent, even though the content of the thread does not affect its
metadata.
Release Notes:
- N/A
Shorthand methods (`methodName() {}`) inside nested object literals were
not shown in the Outline panel. The outline query only captured
method_definition when it was a direct child of a variable_declarator's
object, so nested objects (e.g. `deep: { subFn() {} }`) were missed.
Extended the outline query to match method_definition in any object
node, not just top-level variable_declarator objects. Applied the fix to
TypeScript, JavaScript, and TSX outline definitions. Added tests for the
issue reproduction and edge cases.
Supporting evidence:
<img width="1352" height="812" alt="image"
src="https://github.com/user-attachments/assets/64868a70-abd3-4935-9c03-4c809b55262b"
/>
Fixes #48711
Release Notes:
- Fixed nested object methods not appearing in the Outline panel for
JavaScript and TypeScript files
Emamul Andalib
created
b8bec90
git: Fix a panic when updating the split diff (#54352)
Click to expand commit body
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Release Notes:
- Fixed a panic when using the split diff view.
Closes #50977
Before you mark this PR as ready for review, make sure that you have:
- [x] Added a solid test coverage and/or screenshots from doing manual
testing
- [x] Done a self-review taking into account security and performance
aspects
- [x] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
Before:
<img width="1700" height="1063" alt="image"
src="https://github.com/user-attachments/assets/fd8e8438-a8a8-4d00-ac72-7e5ab75c8723"
/>
After:
<img width="1700" height="1066" alt="image"
src="https://github.com/user-attachments/assets/e31e449d-93ce-433e-94fd-cfdc08d61f49"
/>
Release Notes:
- Fixed kernels discovery in python notebook editor.
---------
Co-authored-by: Finn Evers <finn@zed.dev>
Nadir
and
Finn Evers
created
4b48819
agent: When opening a remote thread check that the linked worktree path exists (#54353)
Click to expand commit body
If the path doesn't exist we fallback to the main worktree path. This
handles the edge case where a git linked worktree is deleted on a remote
machine, and a user tries to open a thread based on that.
We fallback to the main git worktree in this case, if that doesn't exist
the project will open in an error state (empty workspace) like we
already do
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #ISSUE
Release Notes:
- N/A
Anthony Eid
created
66a77d2
Fix devcontainer localEnv/containerEnv substitution when variable is undefined (#53728)
Click to expand commit body
Existing code replaces only the variables that are present in the
environment. It ignores references to undefined variables and leaves
them as is.
Consider following devcontainer.json:
```json
{
...
"remoteEnv": {
"RUSTFLAGS": "${localEnv:RUSTFLAGS}"
},
...
}
```
Existing code will set RUSTFLAGS inside the dev container to a correct
value only if RUSTFLAGS is defined outside the dev container. If
RUSTFLAGS is not defined outside, Zed will erroneously set RUSTFLAGS to
`${localEnv:RUSTFLAGS}`.
This patch fixes this by replacing such references with either empty
strings or provided default values (`${localEnv:VARNAME:default}`).
This patch also removes replacement of `\` with `/` for environment
variables. Existing code makes no sense as simple replacement will not
magically make Windows paths valid on *nix. It is also guaranteed to
break things: think about passing passwords via env vars, for example.
I also noticed that, for some reason, existing code serializes k-v maps
to JSON, then tries to replace the references, and after that
deserializes modified JSON back. I believe that this is horribly wrong
and may have some security implications. This is out of the scope of
this patch. And I hope that somebody from the Zed team will provide the
reasoning behind this code.
Self-Review Checklist:
- [X] I've reviewed my own diff for quality, security, and reliability
- [X] Unsafe blocks (if any) have justifying comments
- [X] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [X] Tests cover the new/changed behavior
- [X] Performance impact has been considered and is acceptable
~~Closes #ISSUE~~ This pull request is also a bug report.
Release Notes:
- Fixed substitution of `${localEnv:VARNAME}` and
`${containerEnv:VARNAME}` in devcontainer.json when variable is not
defined
Ivan Mironov
created
e18da9e
vim: Prevent flickering during movement actions (#52270)
Click to expand commit body
## Context
Closes #52202
Some actions we're unnecessarily delayed during execution by a
yield_now().await call, causing flickering while moving around.
Video Before:
https://github.com/user-attachments/assets/f9922915-8bc7-4e9e-8ce9-18a1e898b69e
Video After:
https://github.com/user-attachments/assets/a46a6338-3fef-4784-8fd7-ecec07a28cf6
## How to Review
when we call the yield in workspace.rs
## Self-Review Checklist
<!-- Check before requesting review: -->
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Release Notes:
- vim: fixed screen flickering during motions.
Co-authored-by: Cameron Mcloughlin <cameron.studdstreet@gmail.com>
Finn Eitreim
and
Cameron Mcloughlin
created
4919ca4
Always use ArchiveSelectedThread action for archiving threads (#54348)
Click to expand commit body
This changes the action for archiving threads in the main sidebar view
from `RemoveSelectedThread` to `ArchiveSelectedThread`. It has the same
key binding as before: `shift-backspace`. I also added `ctrl-backspace`
as a binding for deleting archived threads in the history view.
Release Notes:
- N/A
Max Brunsfeld
created
f37df7b
recent_projects: Fix unaligned keybinding labels in quick-switch menu (#54325)
Click to expand commit body
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #54324
Release Notes:
- Fixed shortcut label alignment in the Recent Projects quick-switch
footer by rendering action rows with a consistent two-column layout
(label left, keybinding right) for “Add Local Folders” and “Add Remote
Folder”.
---------
Co-authored-by: Danilo Leal <67129314+danilo-leal@users.noreply.github.com>
galuis116
and
Danilo Leal
created
261c073
ci: Fix target branch for Zippy version bumps (#54346)
Click to expand commit body
I assumed the action would pick up the branch from the context - turns
out it did not.
Release Notes:
- N/A
Finn Evers
created
57e01b3
language_models: Fix misleading copy when hosted models are disabled (#53971)
Click to expand commit body
The agent settings UI unconditionally showed "You have access to Zed's
hosted models through your Organization" for all Business plan users,
even when the org admin had turned off the Zed AI model provider. Now
the copy reads "Zed's hosted models are disabled by your organization's
configuration" when is_zed_model_provider_enabled is false.
Also added component preview entries for both Business plan states.
Closes CLO-667
Release Notes:
- N/A
---------
Co-authored-by: Neel <neel@zed.dev>
Tom Houlé
and
Neel
created
c289ec7
worktree: Fix crash on rescan of an unregistered linked worktree commondir (#54215)
Click to expand commit body
## Summary
Fixes a crash I hit running Zed Preview against a checkout with many
linked git worktrees. The panic was:
```
thread '<unnamed>' panicked at crates/worktree/src/worktree.rs:5334:25:
update_git_repositories: .git path outside worktree root is not a gitfile: "/Users/eric/repo/zed/.git"
```
The `debug_assert!` in `update_git_repositories` was added in #53443 to
catch the case where a `.git` path outside the worktree root is not a
gitfile. The comment there explained that a `.git` outside the root
should always be a gitfile (as in a linked worktree or submodule), so
the assertion was meant to flag "should never happen" paths.
But there's a second legitimate case: after a linked worktree's
repository has been unregistered from `git_repositories` (for example
because its gitfile was removed, or because the filesystem watcher for
the common git dir lost sync and rescan-driven cleanup dropped the
entry), a subsequent rescan event on the main repo's `.git` directory
arrives at the linked worktree's scanner with the common git dir as the
`dot_git_dir`. That path:
- is outside the linked worktree's root (so it doesn't strip-prefix
cleanly), and
- is a real directory (not a gitfile), because it's the main repo's
`.git`.
So the assertion fires, but `continue` is already the right thing to do
— there's simply nothing left for this scanner to do with a path that
isn't its repository anymore.
On macOS, the trigger in practice is the FSEvents API setting
`MustScanSubDirs` / `UserDropped` / `KernelDropped` on an event (which
`notify` surfaces as `need_rescan()`), which our `FsWatcher` converts
into a `PathEvent { path: <watched path>, kind: Rescan }`. Because every
linked worktree registers a watcher on the same shared common git dir,
one kernel drop fans out into many rescan callbacks, and any one of them
hitting a worktree whose repo was just unregistered triggers the panic.
## Changes
- `crates/worktree/src/worktree.rs` — drop the `debug_assert!`, broaden
the comment to cover both cases.
- `crates/worktree/tests/integration/main.rs` — add a failing regression
test that drives the exact sequence (repo unregistered, then a Rescan
event on the common git dir) and asserts it doesn't panic.
The two commits are split so the test commit reproduces the panic on its
own, and the fix commit on top makes it pass.
Release Notes:
- N/A
Simplification of V0318 with:
- Simpler editable region selection strategy
- Large current file snippet
- No related files
Release Notes:
- N/A
Oleksiy Syvokon
created
68da244
agent: Respect favorite model settings and sync UI changes back to settings (#54318)
Click to expand commit body
Closes #54313
**Before:**
- Favoriting a model only stored `provider`, `model`, and hardcoded
`enable_thinking` to `false`.
- Selecting a favorited model would not restore your preferred
`enable_thinking`, `effort`, or `speed` settings.
This means that if you'd like to use, say, GPT 5.4 your favorite model
on `xhigh` effort every single time, switching to it would set effort to
`medium` (the default for the model) instead.
**After:**
- Favoriting a model captures your current `enable_thinking`, `effort`,
and `speed` when it matches the currently-selected model. Otherwise, it
falls back to the model's own defaults, i.e. thinking-capable models are
no longer favorited with `enable_thinking` forced to `false`.
- Selecting a favorited model applies its stored thinking / effort /
speed.
- Toggling thinking, changing effort, or toggling fast mode on a
favorited model updates the favorite entry in settings (along with the
existing `default_model` setting), so the preference doesn't drift.
Release Notes:
- Agent favorite models now remember and restore per-model thinking,
effort level, and fast mode preferences.
Smit Barmase
created
cd12d5f
dev_container: Make all `PortAttributes` fields optional (#53799)
Click to expand commit body
The Dev Container [metadata
reference](https://containers.dev/implementors/json_reference/#port-attributes)
defines all five `PortAttributes` fields (`elevateIfNeeded`, `label`,
`onAutoForward`, `protocol`, `requireLocalPort`) as optional with
defined defaults. The struct required all of them, causing
deserialization failures for any `portsAttributes` entry that omitted a
field.
Add `#[serde(default)]` to each field, wrap `label` and `protocol` in
`Option<T>` (spec default: not set), and derive `Default` on
`OnAutoForward` with `Notify` as the default variant (spec default:
`notify`). The bool fields already default to false via
`serde(default)`, matching the spec.
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [ ] Unsafe blocks (if any) have justifying comments
- [ ] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [ ] Performance impact has been considered and is acceptable
Closes #53686.
Release Notes:
- Made all `PortAttributes` fields optional according to the Dev
Container spec
Kunall Banerjee
created
98f94e2
ci: Verify commits and releases created with Zed Zippy (#54264)
Click to expand commit body
This changes our approach for creating Zed version bumps with the Zed
Zippy identity:
With these changes, the Zippy version bumps as well as the tag creations
will be verified as per
https://docs.github.com/en/authentication/managing-commit-signature-verification/about-commit-signature-verification#signature-verification-for-bots.
This adds an extra layer of security for version bumps and release
triggers done by the Zippy identity.
Eventually, we can move code more around for this so it happens in the
bot itself, but for now, I think its a good and solid interim solution
to have this here.
Release Notes:
- N/A
Finn Evers
created
9ba6a32
sidebar: Consistently set `interacted_at` (#54320)
Click to expand commit body
There were a few places where you could trigger generation without
causing the `interacted_at` field to be set.
Also renames `message_sent_or_queued` to `interacted`, to be consistent
with the field on `ThreadMetadata`
Release Notes:
- N/A or Added/Fixed/Improved ...
Cameron Mcloughlin
created
c28d82c
feature_flags: Fix issue where staff is not automatically signed into collab (#54332)
Click to expand commit body
Follow up to #54206
`on_flags_ready` relied on the fact that the `FeatureFlagStore` was only
set once the flags had been received from the server.
However, after #54206 the global gets instantiated earlier, without the
flags being resolved.
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Release Notes:
- N/A
Bennet Bo Fenner
created
5a589c4
markdown_preview: Fix outline panel becoming empty when preview pane is focused (#54301)
Click to expand commit body
Closes #52663
Release Notes:
- Fixed outline panel becoming empty when switching focus to a Markdown
Preview pane.
Smit Barmase
created
e5086f3
editor: Fix auto indent adding trailing whitespace on repeated enter (#52628)
Click to expand commit body
Update how auto indentation is handled by `Editor::newline`, in the case
where auto-indentation is not `AutoIndentationMode::None`, so as to
extend the range of the edits being applied to the beginning of the
line, in case the line only contains the indentation whitespace or
there's only whitespace indentation before the cursor position
This ensures that newlines are not left with whitespace.
Closes #34316
Release Notes:
- Fixed auto indent leaving trailing whitespace on blank indented lines
when creating new lines.
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
Gonçalo Aleixo
and
dino
created
0ba60d8
worktree: Fix `.git` modified events not being correctly filtered out (#54329)
Click to expand commit body
Release Notes:
- N/A or Added/Fixed/Improved ...
Co-authored by: Cole Miller <cole@zed.dev>
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Closes #54193
Additionally, respects `cacheFrom` and `options` args defined in
devcontainer.json's `build` object. Also, addresses a bug which was
hiding these problems by overriding the primary build target with
aliasing.
Release Notes:
- Fixed an image aliasing but, respect build context and build args in
dev containers