Skip to content

Merge upstream zed/main (2026-05-19) - #37

Merged
jasonsmithio merged 1135 commits into
mainfrom
chore/merge-upstream-zed-2026-05-19
May 20, 2026
Merged

Merge upstream zed/main (2026-05-19)#37
jasonsmithio merged 1135 commits into
mainfrom
chore/merge-upstream-zed-2026-05-19

Conversation

@github-actions

Copy link
Copy Markdown

Weekly upstream merge

  • Upstream: zed-industries/zed@8ca194d833a4d2e9a3f3c43f84e806a36c3839c4
  • Merge base: 3a5dc8ef6aaed33f7c57f9eeab36bbc71a19bc59
  • Commits ahead upstream: 1121
  • Compare: zed-industries/zed@3a5dc8e...8ca194d

⚠️ Conflicts

The merge produced conflicts. Conflict markers are committed to the branch — resolve locally before marking ready.

Files with leftover conflict markers:

Cargo.lock
Cargo.toml
assets/settings/default.json
crates/agent/src/templates/edit_file_prompt_diff_fenced.hbs
crates/agent/src/templates/system_prompt.hbs
crates/agent/src/thread.rs
crates/agent/src/tools.rs
crates/agent_ui/src/agent_panel.rs
crates/agent_ui/src/agent_ui.rs
crates/agent_ui/src/conversation_view.rs
crates/agent_ui/src/conversation_view/thread_view.rs
crates/agent_ui/src/inline_assistant.rs
crates/agent_ui/src/thread_metadata_store.rs
crates/ai_onboarding/src/agent_panel_onboarding_card.rs
crates/ai_onboarding/src/agent_panel_onboarding_content.rs
crates/ai_onboarding/src/ai_onboarding.rs
crates/ai_onboarding/src/plan_definitions.rs
crates/cli/src/cli.rs
crates/collab/.env.toml
crates/context_server/src/context_server.rs
crates/context_server/src/oauth.rs
crates/crashes/src/crashes.rs
crates/db/src/db.rs
crates/edit_prediction/src/edit_prediction.rs
crates/edit_prediction/src/zeta.rs
crates/edit_prediction_ui/src/edit_prediction_button.rs
crates/editor/src/editor.rs
crates/feature_flags/src/feature_flags.rs
crates/feedback/Cargo.toml
crates/git_ui/src/commit_modal.rs
crates/git_ui/src/conflict_view.rs
crates/git_ui/src/git_picker.rs
crates/git_ui/src/git_ui.rs
crates/git_ui/src/worktree_picker.rs
crates/gpui_wgpu/src/wgpu_context.rs
crates/language_model/src/language_model.rs
crates/language_model/src/registry.rs
crates/language_models/src/provider/cloud.rs
crates/onboarding/src/basics_page.rs
crates/paddleboard/Cargo.toml
crates/paddleboard/build.rs
crates/paddleboard/src/main.rs
crates/paddleboard/src/zed.rs
crates/paddleboard/src/zed/open_listener.rs
crates/paddleboard/src/zed/remote_debug.rs
crates/paths/src/paths.rs
crates/remote_server/src/server.rs
crates/repl/src/notebook/notebook_ui.rs
crates/search/src/buffer_search.rs
crates/settings/src/vscode_import.rs
crates/settings_content/src/language.rs
crates/settings_content/src/settings_content.rs
crates/settings_ui/src/settings_ui.rs
crates/sidebar/src/sidebar.rs
crates/sidebar/src/sidebar_tests.rs
crates/task/src/task.rs
crates/title_bar/Cargo.toml
crates/title_bar/src/title_bar.rs
crates/workspace/Cargo.toml
crates/workspace/src/multi_workspace.rs
crates/workspace/src/welcome.rs
tooling/compliance/src/github.rs

Fork-modified files also touched by this merge

Files containing // PaddleBoard divergence markers that received upstream changes (manual review recommended):

crates/agent/src/agent.rs
crates/agent_ui/src/agent_panel.rs
crates/agent_ui/src/agent_ui.rs
crates/agent_ui/src/model_selector.rs
crates/ai_onboarding/src/agent_panel_onboarding_card.rs
crates/ai_onboarding/src/agent_panel_onboarding_content.rs
crates/ai_onboarding/src/ai_onboarding.rs
crates/ai_onboarding/src/plan_definitions.rs
crates/auto_update/src/auto_update.rs
crates/cli/src/main.rs
crates/client/src/telemetry.rs
crates/client/src/zed_urls.rs
crates/context_server/src/context_server.rs
crates/context_server/src/oauth.rs
crates/copilot_chat/src/copilot_chat.rs
crates/debugger_ui/src/session/running.rs
crates/edit_prediction/src/edit_prediction.rs
crates/edit_prediction/src/zed_edit_prediction_delegate.rs
crates/edit_prediction/src/zeta.rs
crates/edit_prediction_ui/src/edit_prediction_button.rs
crates/eval_cli/src/headless.rs
crates/extension_cli/src/main.rs
crates/extension_host/src/extension_store_test.rs
crates/extensions_ui/src/extensions_ui.rs
crates/git/src/repository.rs
crates/gpui/src/platform.rs
crates/gpui_macos/src/window.rs
crates/gpui_windows/src/platform.rs
crates/gpui_windows/src/window.rs
crates/language_models/src/provider/anthropic.rs
crates/language_models/src/provider/cloud.rs
crates/language_models/src/provider/google.rs
crates/language_models/src/provider/open_ai.rs
crates/languages/src/lib.rs
crates/node_runtime/src/node_runtime.rs
crates/onboarding/src/basics_page.rs
crates/onboarding/src/onboarding.rs
crates/open_router/src/open_router.rs
crates/paddleboard/build.rs
crates/paddleboard/src/main.rs
crates/paddleboard/src/zed.rs
crates/paddleboard/src/zed/app_menus.rs
crates/paths/src/paths.rs
crates/project/src/context_server_store.rs
crates/release_channel/src/lib.rs
crates/remote_server/src/server.rs
crates/repl/src/components/kernel_options.rs
crates/repl/src/kernels/mod.rs
crates/repl/src/kernels/remote_kernels.rs
crates/repl/src/notebook/notebook_ui.rs
crates/repl/src/repl_store.rs
crates/repl/src/session.rs
crates/settings/src/vscode_import.rs
crates/settings_content/src/language.rs
crates/settings_content/src/project.rs
crates/settings_content/src/settings_content.rs
crates/settings_ui/src/settings_ui.rs
crates/system_specs/src/system_specs.rs
crates/title_bar/src/title_bar.rs
crates/ui/src/components/label/label.rs
crates/workspace/src/welcome.rs
crates/workspace/src/workspace.rs

Generated by .github/workflows/merge_upstream_zed.yml.

Release Notes:

  • N/A

macraig and others added 30 commits May 7, 2026 14:41
This update modifies the initialization of the left-hand side
multibuffer in the SplittableEditor. It now checks if the right-hand
side multibuffer is a singleton and uses a
`MultiBuffer::without_headers` instead.


Before Screenshot:
<img width="1624" height="1030" alt="Screenshot 2026-05-07 at 7 30
16 PM"
src="https://github.com/user-attachments/assets/3d963703-309c-42e4-b2be-fe64bd9c0a06"
/>

After Screenshot:
<img width="1624" height="1030" alt="Screenshot 2026-05-07 at 7 32
48 PM"
src="https://github.com/user-attachments/assets/51668319-6a34-47df-b8b1-8bf58b86407e"
/>


Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)



Release Notes:
- Optimized multibuffer creation by conditionally using headers based on
RHS state.
Experiment with allowing users to manage terminal sessions along with
threads in the sidebar.

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

---------

Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
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
Adds a command to help debugging stuck git job queues

Release Notes:

- N/A or Added/Fixed/Improved ...

---------

Co-authored-by: Anthony Eid <hello@anthonyeid.me>
cc @SomeoneToIgnore

## Summary

Follow-up to #56030 

This mechanically extracts two editor topics into focused sibling
modules:

- `crates/editor/src/fold.rs`
- `crates/editor/src/selection.rs`

One odd boundary remains: several selection state types still live in
`editor.rs`. I didn't move them because those caused that "huge 11k
diff" in the previous PR, so I propose to move them later.

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
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:

- The `git::Commit` action (cmd-enter or ctrl-enter) will now commit a
pending amend.
…#54823)

Closes #48032 

When restoring a diff hunk, we first unstage it unconditionally. That
unstaging operation is a no-op in terms of the index text if the hunk
was already not staged, but previously we would still always do
`spawn_set_index_text_job` and bump the
`hunk_staging_operation_count_as_of_write`. Bumping that count in turn
causes us to skip a diff recalculation in response to the change in the
buffer's text. That works out fine in the local case, because when the
worktree picks up the write to `.git/index` we kick off another diff
recalculation which is not skipped. But in the remote case, we don't get
an `UpdateDiffBases` proto message if the index text didn't actually
change, so there is no subsequent diff calculation to do the cleanup,
and we end up with a stale no-op hunk.

This PR fixes the issue by skipping the write to the index and the
`hunk_staging_operation_count_as_of_write` bump if the new and old index
texts are the same.

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:

- Fixed a bug where restoring diff hunks in remote projects would leave
stale no-op hunks in the UI.
Following on from zed-industries/zed#54031,
implement the same but for `Cut`.

Release Notes:

- N/A
`render_settings_item_link` was calling `cx.read_from_clipboard()`
during render so it could show a check icon next to the copy-link button
when the matching link was on the clipboard. This had two problems:

- A clipboard read per visible setting per frame is too expensive.
- On Windows, reading the clipboard pumps the system message queue. If a
queued message handler updates `App` while we're still rendering, GPUI
panics with `RefCell already borrowed` (many occurrences observed).

Track the `json_path` of the most recently copied setting locally
instead. The check icon now reflects what was copied in this session via
this UI rather than whatever is on the system clipboard.

While this removes the most common offender, the underlying
`gpui_windows` reentrancy bug still exists: `on_close` /
`on_request_frame` callbacks can be invoked while `App` is already
borrowed on Windows, and can be triggered by any other
clipboard-touching code path. We should consider a follow-up PR that
handles this at the platform layer -- either by deferring callbacks that
re-borrow `App`, or by guarding individual handlers in
`gpui_windows::events` against reentrant `borrow_mut` calls.

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 crash on Windows that could occur when closing the settings
window
- Improved the overall performance of the settings window
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
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

NixOS users who are missing rsync get a generic "Please install rsync
using your package manager" message.

Release Notes:

- Improved auto update error message for NixOS users missing rsync
This PR fixes a few bugs, updates some UI, and improves testing of auto
watch. It'll likely be easier to review commit by commit:

- Swapped the Copy Channel Link and Auto Watch buttons so Auto Watch
appears in a better position. The UI is still not great, but I think
this tweak will improve it until someone on design can help.

   Before: 

<img width="324" height="61"
alt="589131021-c967dfe1-9026-4a1d-a399-b735303f2de0"
src="https://github.com/user-attachments/assets/7cd414cd-5a13-4e16-ab6e-5de6d2cd64ed"
/>

   After:

<img width="373" height="77"
alt="589131282-607e15a5-e50c-4a8e-b22c-327f2e7b8ab5"
src="https://github.com/user-attachments/assets/7c19e0c8-8c50-4f8c-b966-f2a824eea4a0"
/>


- Disable Auto Watch when following another collaborator, with test
coverage for that behavior. We currently disable following when engaging
auto watch, and now we disable auto watch when following. They are
mutually exclusive and I think the feels correct.
- Refactored Auto Watch integration tests to use channels API instead of
room API.
- Improved test robustness by using assertions to identify
`SharedScreen` items by type and `peer_id` instead of tab title text.
- Fixed Auto Watch for returning channel participants by emitting
`RemoteVideoTracksChanged` when removing a participant with active video
tracks, with regression coverage for leave/rejoin/share.

Self-Review Checklist:

- [X] I've reviewed my own diff for quality, security, and reliability
- [ ] 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

Release Notes:

- N/A
…Id` where possible (#56139)

Horror of a PR title but could not think of anything better here.

Release Notes:

- N/A

---------

Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Update Mistral provider docs following #55443

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 **and docs** cover the new/changed behavior
- [ ] Performance impact has been considered and is acceptable

Release Notes:

- N/A or Added/Fixed/Improved ...

Signed-off-by: Gabriel Linder <linder.gabriel@gmail.com>
The function is unsound due to the classic fact that one can leak tasks,
sidestepping the blocking drop behavior resulting in a use after free.

Release Notes:

- N/A or Added/Fixed/Improved ...
Based on
zed-industries/zed#54100 (comment)

* Adjusts the code lens display closer to what VSCode does: have blank
placeholders for the code lens need resolving.
Zed will remove them if resolve returns nothing, so some small amount of
jitter is still there.

* Also reworks LspStore layer to provide a simple resolve method,
without any ranges involved, grouping that logic in the editor itself.
This allows to process each resolve request separately, updating editor
blocks as soon as possible.

Before:


https://github.com/user-attachments/assets/d6759a90-0087-4658-abf8-8e2767bc63a2

After:


https://github.com/user-attachments/assets/cb8f976c-b3fc-4f66-bb9f-812108255c90


Release Notes:

- Fixed resolved lens causing flickers
Closes zed-industries/zed#53471

Adds a requirement on status bar items to provide a way to hide
themselves.

<img width="329" height="153" alt="image"
src="https://github.com/user-attachments/assets/b98ee5ba-a439-44d7-9ab5-f4511b66a574"
/>

<img width="464" height="40" alt="image"
src="https://github.com/user-attachments/assets/b41d9189-3475-4e61-b3a4-bc731dd52c53"
/>


Release Notes:

- Added a way to hide sidebar buttons
Before:

1. Agent tries to edit unsaved file
2. Tool call fails with error telling the agent to ask the user to save
or discard edits
3. User types save/restore
4. Agent uses save/restore tool


https://github.com/user-attachments/assets/c94dd361-e8e0-48ee-be31-da8afe594419

After:

1. Agent tries to edit unsaved file
2. User is prompted to save/restore file
3. User accepts/rejects or saves/discards file manually


https://github.com/user-attachments/assets/1d98a0c4-4420-4426-94f2-42355de230be

Release Notes:

- agent: Improved UX when agent tries to edit unsaved buffer

---------

Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
cc @SomeoneToIgnore

## Summary

Follow-up to zed-industries/zed#55352,
where the conclusion was to split `editor.rs` incrementally by topic
instead of all at once.

This mechanically extracts two editor topics into focused sibling
modules:

- `crates/editor/src/input.rs`
- `crates/editor/src/git.rs`

The git extraction is intentionally partial for now. I left a lot of
related parts because otherwise the diff was super huge (over 9K lines)
in the Github, so we can move those parts later in the follow-up PRs
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
This PR removes the `api_token` field from Collab's `Config`, as it is
no longer used.

Release Notes:

- N/A
Makes the sidebar search case insensitive, and also require contiguous
matches. Also removes the duplicate logic for the sidebar and thread
history view

Release Notes:

- N/A or Added/Fixed/Improved ...
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 zed-industries/zed#56064

This behavior regressed in
zed-industries/zed#54481

Release Notes:

- Fixed an issue where broken symlinks, permission errors, or other fs
errors in watched directories could cause excessive CPU usage
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

Closes zed-industries/zed#52585

Release Notes:

- Fixed local zeta2 edit predictions using the wrong prompt format.
This PR makes it so we route the `UserService::get_users_by_ids` call
through Cloud instead of hitting the database.

We've introduced a new `CloudUserService` that will fetch the users from
Cloud using the internal API. Note that we've only implemented the
`get_users_by_ids` method on this service, as the endpoints for the
other methods don't yet exist.

We have also introduced a `TransitionalUserService` for the purposes of
gradually transitioning these calls over to Cloud. Right now it uses the
`CloudUserService` for the `get_users_by_ids` implementation, but then
uses the `DatabaseUserService` for the other methods.

Closes CLO-740.

Release Notes:

- N/A
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 #55998

Release Notes:

- ollama: Fixed issue where specifying `auto_discover: false` would
still auto discover models
…iagnostic (#56172)

Otherwise we can sometimes end up with single line excerpts which looks
very off



Release Notes:

- Improved the minimum size of diagnostics pane excerpts
…ent (#56179)

Follow up: zed-industries/zed#53465

For Markdown tables, headers are now always centered (ignoring column
alignment), matching standard Markdown rendering behavior. For HTML
tables, headers default to center but respect explicit `align`
attributes.

This also propagates alignment to paragraphs and headings inside table
cells, not just the cell container itself.

Release Notes:

- N/A
Failed CI run:
https://github.com/zed-industries/zed/actions/runs/25559568951/job/75027378760?pr=56181

test_kill_active_task_on_completed_task_is_noop was flaking on Linux.
It's sibling was just waiting 200ms for PTY events to be handled by
alacritty. This PR polls the PTY instead of waiting an arbitrary amount
of time

Release Notes:

- N/A
@github-actions

github-actions Bot commented May 19, 2026

Copy link
Copy Markdown
Author

Upstream drift report

Comparing PaddleBoard HEAD (7533df3765) against zed-industries/zed:main (068d64edd6).
Last common ancestor: 8ca194d833.

Crate Files Insertions Deletions // PaddleBoard: tags
crates/agent 18 +25278 -494 0
crates/agent_ui 30 +4229 -1940 5
crates/buffer_diff 0 +0 -0 0
crates/client 5 +64 -232 2
crates/collab 6 +20 -60 0
crates/collab_ui 2 +2 -2 0
crates/editor 10 +95 -82 0
crates/gpui 5 +52 -35 0
crates/language 1 +2 -2 0
crates/language_core 0 +0 -0 0
crates/lsp 0 +0 -0 0
crates/multi_buffer 0 +0 -0 0
crates/project 11 +184 -334 1
crates/rope 0 +0 -0 0
crates/settings_content 5 +153 -26 6
crates/text 0 +0 -0 0
crates/workspace 10 +149 -33 0
Total 103 +30228 -3240 14

Generated by script/check-upstream-drift. See FORK_HYGIENE.md for context.

jasonsmithio and others added 11 commits May 18, 2026 19:27
All 62 conflict markers resolved (down from `git grep -l '^<<<<<<< HEAD'`
returning 62 files). Build is not yet green — the merge also brought in
upstream structural changes (new traits, deleted modules PB used) that
need post-resolution fix-up.

Resolved by category:

- tooling/xtask: re-deleted setup_webrtc.rs that the merge restored.
- crates/paddleboard/* (5 files): kept PB rename/branding (name,
  version, FileDescription/ProductName, env vars), kept PB's
  restore_or_create_workspace tuple-bucket design per user request,
  merged in upstream additions where harmless (UserAgentsMdState
  import, no-windows safety check, FocusApp URL scheme).
- ai_onboarding/* (4 files), edit_prediction_ui/edit_prediction_button.rs,
  edit_prediction/zeta.rs, settings_content/language.rs: took PB's
  gutted stubs throughout (PB intent: kill Zed Pro upsells and Zeta).
- edit_prediction/edit_prediction.rs (5 hunks): kept PB-renamed
  constants (PADDLEBOARD_VERSION_HEADER_NAME,
  PADDLEBOARD_PREDICT_DATA_COLLECTION_CHOICE), took upstream's
  refactored process_api_response / is_data_collection_enabled
  structures.
- assets/settings/default.json + settings_content/settings_content.rs:
  combined PB's paddleboard_sandbox / sandbox-policy defaults with
  upstream's new feature_flags + instrumentation settings.
- Cargo.toml + crates/feedback,title_bar,workspace,auto_update_ui:
  kept PB workspace members and paddleboard_actions deps, added
  upstream's windows_resources member and arrayvec/client deps.
- agent/thread.rs: combined PB's tools (NowTool, OpenTool, SandboxTool,
  etc.) with upstream's new tools (ApplyCodeActionTool, FindReferencesTool,
  WriteFileTool, etc.); kept both step_mode and inherits_parent_model_settings
  fields; dropped upstream's tool-result image handling block where it
  collided with PB's step_mode flow.
- agent_ui/*: restored PB-deleted thread_history.rs +
  thread_history_view.rs from main, combined PB-only modules
  (mcp_servers_ui, orchestration_panel, branch_names) with upstream's
  re-exports (ActiveAcpConnection, AgentPanelTerminalInfo, etc.).
- agent_ui/agent_panel.rs (6 hunks): kept PB upsell-disabled
  should_render_trial_end_upsell + should_render_new_user_onboarding,
  combined PB MCP Servers menu header with upstream's Settings entry,
  kept PB "Move to New Window" sidebar action.
- thread_metadata_store.rs + sidebar_tests.rs: took upstream's
  restructured ThreadMetadata (thread_id, optional session_id,
  title_override) since PB's old struct shape no longer matches the
  type definition; renamed all leftover ZED_AGENT_ID references to
  PADDLEBOARD_AGENT_ID.
- Most agent_ui / git_ui / workspace / search / notebook / title_bar /
  multi_workspace / task / cli / settings / sidebar / settings_ui /
  conflict_view / vscode_import / collab .env / oauth /
  context_server / db / gpui_wgpu / repl files: pattern was
  zed_actions→paddleboard_actions rename combined with adopting new
  upstream symbols (e.g., HideStatusItem, NotifyResultExt,
  UseSelectionForFind, OpenKeymap, ItemEvent, FocusAgent).
- paths/paths.rs (11 hunks): adopted upstream's APP_NAME constant
  system but changed APP_NAME to "PaddleBoard" so the generated
  APP_NAME_LOWERCASE is "paddleboard".
- editor/editor.rs + language_model/language_model.rs +
  language_models/cloud.rs: PB-side huge additions that upstream had
  empty on the other side — took PB.
- remote_server/server.rs: took upstream's refactored crash handler
  init (signature changed; PB's old call no longer compiles) and
  renamed ZED_GENERATE_MINIDUMPS / ZED_COMMIT_SHA to PADDLEBOARD_*.
- crashes/crashes.rs: kept PB minidump generation block AND upstream's
  new force_backtrace helper.
- language_model: restored PB-deleted provider/, rate_limiter.rs,
  role.rs, tool_schema.rs files + the upstream provider/ subfiles
  (anthropic.rs, google.rs, open_ai.rs, open_router.rs, x_ai.rs) so
  the module tree exists. Imports still need cleanup.
- tooling/compliance/github.rs: kept PB-only build_co_authors_query +
  PB's simpler graphql signature.
- Cargo.lock: regenerated from scratch via cargo generate-lockfile.

Remaining work for next session: 70+ build errors from missing
imports / ambiguous re-exports / removed-upstream-symbols PB still
references (StatusCode/Duration imports in language_model, missing
schemars/smol/cloud_llm_client deps, ZED_SYSTEM_ID_HEADER_NAME in
cloud_api_client, ORG/REPO constants in tooling/compliance/github.rs,
etc.). These are merge fix-ups, not conflict resolution.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Targeted fix-ups after PR #37's full conflict-marker resolution:

- crates/language_model/Cargo.toml: restored PB-main's full dep set
  (anthropic, cloud_api_client, cloud_api_types, cloud_llm_client,
  open_ai, open_router, schemars, smol, language_model_core) so the
  restored provider/*, rate_limiter, role, tool_schema files can
  actually compile.
- crates/cloud_api_client/src/cloud_api_client.rs: bulk-renamed leftover
  ZED_SYSTEM_ID_HEADER_NAME references to PADDLEBOARD_SYSTEM_ID_HEADER_NAME.
- crates/language_models_cloud/src/language_models_cloud.rs: same fix
  for ZED_VERSION_HEADER_NAME -> PADDLEBOARD_VERSION_HEADER_NAME.
- crates/crashes/Cargo.toml + crashes.rs: added back the deps PB main
  needed (cfg-if, futures, paths, release_channel, smol) and the
  release_channel + atomic-u32 imports the crashes module references.
- crates/context_server/Cargo.toml: added smol dep so
  sandboxed_stdio_transport.rs compiles.
- crates/feature_flags/src/store.rs: ZED_DISABLE_STAFF -> PADDLEBOARD_DISABLE_STAFF.
- crates/settings_content/src/language.rs: removed Deserialize from
  the derive macro (manual impl exists), brought serde::de::Error
  into scope inside the impl so D::Error::custom(...) resolves, and
  added Experimental(_) match arms to is_zed() and display_name()
  for upstream's new variant.
- crates/ai_onboarding/src/ai_onboarding.rs: added Vector, VectorName
  back to the ui imports — PB's gutted renders still reference these
  in the *_stamp() helpers that survived the gutting.
- tooling/compliance/src/github.rs: added the missing
  use itertools::Itertools as _, restored the ORG/REPO consts in
  octo_client, and threaded .map_err(anyhow::anyhow!) on the graphql
  call in get_commit_metadata to convert octocrab::Error to anyhow.
- crates/language_model/src/language_model.rs: disambiguated the
  `util` ambiguity (`pub use language_model_core::*` re-exports `util`
  as a module that shadowed the `util` crate) by switching the
  is_default import to `::util::serde::is_default`.

Remaining (15 errors, all in language_model / language_models_cloud
and PB language adapters):

- Duplicate LanguageModelCompletionEvent: pub use language_model_core::*
  re-exports the upstream-canonical type while PB's restored body in
  language_model.rs *also* defines an identical-shape enum + a
  from_completion_request_status method that doesn't exist on the
  upstream type. Solving needs either dropping PB's restored type
  (and porting from_completion_request_status to a free fn or trait
  ext) or removing the language_model_core glob re-export. Same
  duplication issue causes the language_models_cloud type-mismatch
  errors at lines 452/513/555/590.
- LSP adapter Arc<dyn> signature drift: upstream changed
  LspAdapterDelegate to be passed as &Arc<dyn ...> instead of
  &dyn ...; PB's Java / Kotlin / PHP / Swift adapters still use the
  old signature. Mechanical s/&dyn LspAdapterDelegate/&Arc<dyn LspAdapterDelegate>/
  per file with maybe one or two callsite tweaks.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
What this commit does:

- crates/language_model/src/language_model.rs: deleted the 326-line
  block of duplicate type definitions PB had restored from main
  (LanguageModelCompletionEvent / LanguageModelCompletionError /
  StopReason / TokenUsage / LanguageModelToolUseId / LanguageModelToolUse).
  The canonical versions now live in language_model_core and are
  re-exported via `pub use language_model_core::*` at line 13.
- crates/language_model/src/provider.rs + provider/*.rs: removed PB's
  restored anthropic/google/open_ai/open_router/x_ai provider files
  (kept zed.rs). They were duplicating the From<*Error> for
  LanguageModelCompletionError impls already in the upstream anthropic
  / open_ai / open_router crates, and triggering orphan rule
  violations. Provider IDs come through language_model_core now.
- crates/paddleboard_actions/src/lib.rs: added
  agents_sidebar::MoveWorkspaceToNewWindow action (multi_workspace.rs
  imported it but it didn't exist yet).
- crates/workspace/src/tour_status_item.rs: implemented the
  hide_setting trait method (upstream added it to StatusItemView).
- crates/languages/src/{java,kotlin,php,swift}.rs: added Arc imports,
  fixed signatures to &Arc<dyn LspAdapterDelegate>, and converted
  java's fetch_server_binary to a non-async fn returning an `async
  move {}` block so it matches the trait's `+ use<>` lifetime
  restriction. Same conversion is in progress for kotlin (closing
  delimiter still off by one); php and swift still need the same
  treatment.

Status:

- `cargo check -p paddleboard` shallow check: 0 errors (down from 70).
- `cargo check --workspace`: ~510 errors revealed. The shallow check
  was stopping at the first broken crate; the workspace check exposes
  the full graph.

Remaining categories (rough triage):

- crates/editor/src/editor.rs: when I took HEAD in the big conflict
  (lines 7426..11678), the resulting file duplicates ~30+ method
  definitions that *also* live in the upstream-extracted
  crates/editor/src/navigation.rs. Net: every `move_to_previous_word_start`,
  `select_to_previous_word_start`, `delete_to_previous_word_start`, etc.
  fires E0592 "duplicate definitions". Fix: drop the inline copies in
  editor.rs and rely on navigation.rs. Likely 1-2 hour audit.
- crates/language_models/src/provider/cloud.rs: imports
  `LlmApiToken` from `language_model` (moved to `cloud_api_client`),
  imports `count_anthropic_tokens_with_tiktoken` /
  `count_open_ai_tokens` / `count_xai_tokens` from the now-deleted
  language_model::provider::* tree. Either re-export these from
  language_model_core or rewrite the call sites against the
  upstream-canonical provider crates.
- crates/language_models_cloud (whole file): unresolved
  `cloud_llm_client` crate, missing thiserror imports, pattern
  bindings out of order. Looks like the crate is half-merged — needs
  a pass against PB main's version.
- crates/copilot_chat/src/copilot_chat.rs: SharedString is now `pub`
  through `gpui_shared_string::SharedString` not `gpui::SharedString`.
  Mechanical s/gpui::SharedString/gpui_shared_string::SharedString/.
- Ambiguous glob re-exports through language_model — `Role`,
  `RateLimiter`, `RateLimitGuard`, `parse_prompt_too_long`,
  `ANTHROPIC_PROVIDER_ID` etc. are re-exported from both
  language_model_core::* and crate::{role,rate_limiter,provider}::*.
  Either remove the duplicate `pub use crate::{role,rate_limiter}::*`
  or rename the local definitions.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
… → 17)

Clusters #1-#5 step 3 of the PR #37 upstream-merge cleanup, bundled together
since the changes do not compile independently. Net: 16-error cluster #5
punch list resolved, plus the prior 510 → 16 reductions from clusters #1-4.

Cluster #1: php/swift LSP-adapter trait conversions
Cluster #2: editor.rs vs extracted-module duplicate-method deletion (-4247 lines)
Cluster #3 + small wins: zed_actions → paddleboard_actions rename and isolated 1-offs
Cluster #5 step 1+2: cloud.rs import cleanup + dead Zed-Cloud token-counting deletion
Cluster #5 step 3: residual cloud.rs renames, EditPredictionPromptFormat,
async-tungstenite 0.31 → 0.34.1 (resolves jupyter-websocket-client type
mismatch), copilot_start_menu restoration.

Remaining: 17 errors all in `agent` crate (newly visible now that
language_models compiles). Cluster #6 punch list captured in RECAPS.md.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…rrors)

Cluster #6 of the PR #37 upstream-merge cleanup. With cluster #5 done and
language_models compiling, the agent crate became checkable and surfaced
17 errors driven by the agent_client_protocol 0.12.x split into a thin
top-level crate plus agent-client-protocol-schema-0.13.x. Only a narrow
set of types stayed re-exported at the root; the rest moved into
`agent_client_protocol::schema`.

Fixes:
- Re-route `agent_client_protocol as acp` to `agent_client_protocol::schema as acp`
  in sandbox_tool.rs, sandbox_service_tool.rs, and agent_ui/thread_history.rs.
- Restore crates/agent/src/tools/tool_edit_parser.rs from PB main (PB-only
  file that did not survive the upstream merge).
- Drop 5 dead tool imports from thread.rs (NowTool, OpenTool,
  RestoreFileFromDiskTool, SaveFileTool, StreamingEditFileTool — removed
  upstream, never referenced after the import).
- Add `kind: AuthorizationKind::PermissionGrant` to the step-mode
  ToolCallAuthorization initializer (new required field upstream).
- Wrap two `LanguageModelToolResultContent::Text(...)` literals in `vec![...]`
  to match the field's `Vec<...>` type.
- Replace `AgentToolOutput::from_error("...")` with
  `AgentToolOutput::from(anyhow::anyhow!("..."))` (method was removed in
  favor of the `From<anyhow::Error>` impl).
- Rewrite the `if let LanguageModelToolResultContent::Image(_) =
  &output.llm_output` checks to iterate the Vec, since llm_output is no
  longer a single enum.

Remaining: 41 errors in agent_ui (cluster #7). Punch list in RECAPS.md.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Cluster #7 of the PR #37 upstream-merge cleanup. All 14 errors cleared
in this pass are mechanical — restoring a PB-only module that didn't
survive the merge, adding a missing workspace dep, renaming three
symbols, and fixing field renames on ThreadView. The remaining 27 are
structural: PB's history-panel infrastructure (ActiveView, set_active_view,
background_threads, AgentConnectionEntry::history(), ConversationView
extension methods) was wiped by upstream's restructure of the agent panel.

Fixes:
- Restore crates/agent_ui/src/branch_names.rs from PB main (171 lines,
  PB-only word-list helpers).
- Add time_format.workspace = true to crates/agent_ui/Cargo.toml.
- Switch orchestration_panel.rs to agent_client_protocol::schema as acp.
- Rename agent::ZED_AGENT_ID → agent::PADDLEBOARD_AGENT_ID at 3 sites.
- Drop the unused AgentV2FeatureFlag import.
- Rename paddleboard_actions::agent::OpenAcpOnboardingModal →
  OpenOnboardingModal.
- Rename ThreadView field accesses: .id → .session_id, .parent_id →
  .parent_session_id (5 sites in orchestration_panel.rs).

Remaining 27 errors are PB-vs-upstream structural divergence. Punch list
and (A) restore vs (B) defer/delete options captured in RECAPS.md.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…addleboard)

Final two clusters of the PR #37 upstream-merge cleanup. Workspace went
from 27 errors (in cluster #7 start) to 0 errors across all crates.
`cargo check --workspace` now finishes successfully.

Cluster #7 (agent_ui): Instead of restoring PB-main's full ActiveView
state machine (~1000 LOC), bridged PB's history-panel feature to
upstream's new BaseView + OverlayView layered model. PB's history view
slots into OverlayView::History alongside the existing Configuration
overlay, getting "back to previous view" semantics for free via
clear_overlay().

Key changes:
- Add OverlayView::History { view: Entity<ThreadHistoryView> } and
  parallel VisibleSurface::History plumbing (focus, title, render).
- Rewrite open_history against the overlay model.
- background_threads → retained_threads for all_conversation_views().
- AgentConnectionEntry::history() stub returning None (followup: wire
  per-agent history when AcpConnection backends support it).
- ConversationView::{workspace, delete_history_entry, navigate_to_session}
  — workspace is a real getter; the other two are stubs while
  AgentConnectionEntry::history() is disabled.
- gpui::Corner → gpui::Anchor (with alias to preserve callsites).
- Restored RemoveHistory action; dropped dead WorktreeCreationStatus
  re-export and AgentV2FeatureFlag import; renamed OpenAcpOnboardingModal
  → OpenOnboardingModal.
- Match-arm exhaustiveness: AgentIdOrLegacyAgent::LegacyAgent(Gemini)
  falls back to NativeAgent.id(); EditPredictionProvider::Experimental(_)
  hides edit-prediction namespace (same as None).
- supports_delete() gained a &App arg (passed through at all 4 callsites).
- Expanded thread_import re-exports for sidebar crate.

Cluster #8 (paddleboard binary, 3 errors → 0):
- Added `Error` and `editor::Editor` to imports.
- EditPredictionProvider::Experimental(_) match arm.
- Mapped tasks-future results through `.map(|_| ())` to match the
  Vec<Result<(), Error>> type.

Followups captured in RECAPS:
- Per-agent thread history (AgentConnectionEntry::history) re-enable.
- load_agent_thread bridge for ThreadHistoryViewEvent::Open callsites.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Cluster #9 of the PR #37 upstream-merge cleanup. Resolves all
`./script/clippy` errors (clippy --workspace --release --all-targets
--all-features --deny warnings), confirms the debug binary links, and
smoke-tests `--system-specs` to exercise the startup path.

Cleanups:
- Delete language_model/{rate_limiter,role}.rs (PB shadows of the
  canonical language_model_core::* re-exports — confirmed unused).
- Delete agent/tools/tool_edit_parser.rs (ToolEditParser was unused
  anywhere; restored in cluster #6 only to silence the missing-mod
  error, but the `mod` declaration was orphaned).
- Rename ZED_PREDICT_DATA_COLLECTION_CHOICE → PADDLEBOARD_… in
  edit_prediction_tests.rs (7 sites; runtime code already renamed).
- Switch Command::spawn / Command::output to util::command helpers
  in paddleboard_sandbox_prereqs_ui and repl/podman_kernel (the
  podman_kernel one is in Drop, so wrapped in
  #[allow(clippy::disallowed_methods)] with explanatory comment).
- `#[allow(dead_code)]` for the PB history-panel infrastructure
  (ActiveView::History, AgentPanel history methods, branch_names.rs,
  thread_history.rs, thread_history_view.rs). The action handler isn't
  wired up yet — followup tracked in RECAPS.md.
- Add Agent::Stub match arm to has_history_for_selected_agent for the
  `test-support` feature shape.
- 24 misc lint cleanups: 5× redundant clones, 6× unused imports,
  3× pre-existing dead-code allows, 1× sort_by_key simplification,
  3× unused-variable underscoring in conversation_view/thread_view.rs.
- Add smol to agent_ui's dev-dependencies (used in TestSessionList).
- Add util to paddleboard_sandbox_prereqs_ui's deps.

Verified:
- `./script/clippy` finishes successfully (release profile, all-targets,
  all-features, deny warnings).
- `cargo build -p paddleboard` finishes successfully in 1m 41s on macOS.
- `./target/debug/paddleboard --system-specs` boots cleanly and prints
  PaddleBoard v0.232.0+dev.3a592ef18 system-specs output.

PR #37 is ready to flip from draft to ready-for-review.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@jasonsmithio
jasonsmithio marked this pull request as ready for review May 20, 2026 05:03
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@jasonsmithio
jasonsmithio merged commit 65aa3f5 into main May 20, 2026
1 check passed
jasonsmithio added a commit that referenced this pull request May 20, 2026
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@jasonsmithio
jasonsmithio deleted the chore/merge-upstream-zed-2026-05-19 branch May 20, 2026 05:08
jasonsmithio added a commit that referenced this pull request May 31, 2026
jasonsmithio added a commit that referenced this pull request May 31, 2026
All 62 conflict markers resolved (down from `git grep -l '^<<<<<<< HEAD'`
returning 62 files). Build is not yet green — the merge also brought in
upstream structural changes (new traits, deleted modules PB used) that
need post-resolution fix-up.

Resolved by category:

- tooling/xtask: re-deleted setup_webrtc.rs that the merge restored.
- crates/paddleboard/* (5 files): kept PB rename/branding (name,
  version, FileDescription/ProductName, env vars), kept PB's
  restore_or_create_workspace tuple-bucket design per user request,
  merged in upstream additions where harmless (UserAgentsMdState
  import, no-windows safety check, FocusApp URL scheme).
- ai_onboarding/* (4 files), edit_prediction_ui/edit_prediction_button.rs,
  edit_prediction/zeta.rs, settings_content/language.rs: took PB's
  gutted stubs throughout (PB intent: kill Zed Pro upsells and Zeta).
- edit_prediction/edit_prediction.rs (5 hunks): kept PB-renamed
  constants (PADDLEBOARD_VERSION_HEADER_NAME,
  PADDLEBOARD_PREDICT_DATA_COLLECTION_CHOICE), took upstream's
  refactored process_api_response / is_data_collection_enabled
  structures.
- assets/settings/default.json + settings_content/settings_content.rs:
  combined PB's paddleboard_sandbox / sandbox-policy defaults with
  upstream's new feature_flags + instrumentation settings.
- Cargo.toml + crates/feedback,title_bar,workspace,auto_update_ui:
  kept PB workspace members and paddleboard_actions deps, added
  upstream's windows_resources member and arrayvec/client deps.
- agent/thread.rs: combined PB's tools (NowTool, OpenTool, SandboxTool,
  etc.) with upstream's new tools (ApplyCodeActionTool, FindReferencesTool,
  WriteFileTool, etc.); kept both step_mode and inherits_parent_model_settings
  fields; dropped upstream's tool-result image handling block where it
  collided with PB's step_mode flow.
- agent_ui/*: restored PB-deleted thread_history.rs +
  thread_history_view.rs from main, combined PB-only modules
  (mcp_servers_ui, orchestration_panel, branch_names) with upstream's
  re-exports (ActiveAcpConnection, AgentPanelTerminalInfo, etc.).
- agent_ui/agent_panel.rs (6 hunks): kept PB upsell-disabled
  should_render_trial_end_upsell + should_render_new_user_onboarding,
  combined PB MCP Servers menu header with upstream's Settings entry,
  kept PB "Move to New Window" sidebar action.
- thread_metadata_store.rs + sidebar_tests.rs: took upstream's
  restructured ThreadMetadata (thread_id, optional session_id,
  title_override) since PB's old struct shape no longer matches the
  type definition; renamed all leftover ZED_AGENT_ID references to
  PADDLEBOARD_AGENT_ID.
- Most agent_ui / git_ui / workspace / search / notebook / title_bar /
  multi_workspace / task / cli / settings / sidebar / settings_ui /
  conflict_view / vscode_import / collab .env / oauth /
  context_server / db / gpui_wgpu / repl files: pattern was
  zed_actions→paddleboard_actions rename combined with adopting new
  upstream symbols (e.g., HideStatusItem, NotifyResultExt,
  UseSelectionForFind, OpenKeymap, ItemEvent, FocusAgent).
- paths/paths.rs (11 hunks): adopted upstream's APP_NAME constant
  system but changed APP_NAME to "PaddleBoard" so the generated
  APP_NAME_LOWERCASE is "paddleboard".
- editor/editor.rs + language_model/language_model.rs +
  language_models/cloud.rs: PB-side huge additions that upstream had
  empty on the other side — took PB.
- remote_server/server.rs: took upstream's refactored crash handler
  init (signature changed; PB's old call no longer compiles) and
  renamed ZED_GENERATE_MINIDUMPS / ZED_COMMIT_SHA to PADDLEBOARD_*.
- crashes/crashes.rs: kept PB minidump generation block AND upstream's
  new force_backtrace helper.
- language_model: restored PB-deleted provider/, rate_limiter.rs,
  role.rs, tool_schema.rs files + the upstream provider/ subfiles
  (anthropic.rs, google.rs, open_ai.rs, open_router.rs, x_ai.rs) so
  the module tree exists. Imports still need cleanup.
- tooling/compliance/github.rs: kept PB-only build_co_authors_query +
  PB's simpler graphql signature.
- Cargo.lock: regenerated from scratch via cargo generate-lockfile.

Remaining work for next session: 70+ build errors from missing
imports / ambiguous re-exports / removed-upstream-symbols PB still
references (StatusCode/Duration imports in language_model, missing
schemars/smol/cloud_llm_client deps, ZED_SYSTEM_ID_HEADER_NAME in
cloud_api_client, ORG/REPO constants in tooling/compliance/github.rs,
etc.). These are merge fix-ups, not conflict resolution.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
Targeted fix-ups after PR #37's full conflict-marker resolution:

- crates/language_model/Cargo.toml: restored PB-main's full dep set
  (anthropic, cloud_api_client, cloud_api_types, cloud_llm_client,
  open_ai, open_router, schemars, smol, language_model_core) so the
  restored provider/*, rate_limiter, role, tool_schema files can
  actually compile.
- crates/cloud_api_client/src/cloud_api_client.rs: bulk-renamed leftover
  ZED_SYSTEM_ID_HEADER_NAME references to PADDLEBOARD_SYSTEM_ID_HEADER_NAME.
- crates/language_models_cloud/src/language_models_cloud.rs: same fix
  for ZED_VERSION_HEADER_NAME -> PADDLEBOARD_VERSION_HEADER_NAME.
- crates/crashes/Cargo.toml + crashes.rs: added back the deps PB main
  needed (cfg-if, futures, paths, release_channel, smol) and the
  release_channel + atomic-u32 imports the crashes module references.
- crates/context_server/Cargo.toml: added smol dep so
  sandboxed_stdio_transport.rs compiles.
- crates/feature_flags/src/store.rs: ZED_DISABLE_STAFF -> PADDLEBOARD_DISABLE_STAFF.
- crates/settings_content/src/language.rs: removed Deserialize from
  the derive macro (manual impl exists), brought serde::de::Error
  into scope inside the impl so D::Error::custom(...) resolves, and
  added Experimental(_) match arms to is_zed() and display_name()
  for upstream's new variant.
- crates/ai_onboarding/src/ai_onboarding.rs: added Vector, VectorName
  back to the ui imports — PB's gutted renders still reference these
  in the *_stamp() helpers that survived the gutting.
- tooling/compliance/src/github.rs: added the missing
  use itertools::Itertools as _, restored the ORG/REPO consts in
  octo_client, and threaded .map_err(anyhow::anyhow!) on the graphql
  call in get_commit_metadata to convert octocrab::Error to anyhow.
- crates/language_model/src/language_model.rs: disambiguated the
  `util` ambiguity (`pub use language_model_core::*` re-exports `util`
  as a module that shadowed the `util` crate) by switching the
  is_default import to `::util::serde::is_default`.

Remaining (15 errors, all in language_model / language_models_cloud
and PB language adapters):

- Duplicate LanguageModelCompletionEvent: pub use language_model_core::*
  re-exports the upstream-canonical type while PB's restored body in
  language_model.rs *also* defines an identical-shape enum + a
  from_completion_request_status method that doesn't exist on the
  upstream type. Solving needs either dropping PB's restored type
  (and porting from_completion_request_status to a free fn or trait
  ext) or removing the language_model_core glob re-export. Same
  duplication issue causes the language_models_cloud type-mismatch
  errors at lines 452/513/555/590.
- LSP adapter Arc<dyn> signature drift: upstream changed
  LspAdapterDelegate to be passed as &Arc<dyn ...> instead of
  &dyn ...; PB's Java / Kotlin / PHP / Swift adapters still use the
  old signature. Mechanical s/&dyn LspAdapterDelegate/&Arc<dyn LspAdapterDelegate>/
  per file with maybe one or two callsite tweaks.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
jasonsmithio added a commit that referenced this pull request May 31, 2026
… → 17)

Clusters #1-#5 step 3 of the PR #37 upstream-merge cleanup, bundled together
since the changes do not compile independently. Net: 16-error cluster #5
punch list resolved, plus the prior 510 → 16 reductions from clusters #1-4.

Cluster #1: php/swift LSP-adapter trait conversions
Cluster #2: editor.rs vs extracted-module duplicate-method deletion (-4247 lines)
Cluster #3 + small wins: zed_actions → paddleboard_actions rename and isolated 1-offs
Cluster #5 step 1+2: cloud.rs import cleanup + dead Zed-Cloud token-counting deletion
Cluster #5 step 3: residual cloud.rs renames, EditPredictionPromptFormat,
async-tungstenite 0.31 → 0.34.1 (resolves jupyter-websocket-client type
mismatch), copilot_start_menu restoration.

Remaining: 17 errors all in `agent` crate (newly visible now that
language_models compiles). Cluster #6 punch list captured in RECAPS.md.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
…rrors)

Cluster #6 of the PR #37 upstream-merge cleanup. With cluster #5 done and
language_models compiling, the agent crate became checkable and surfaced
17 errors driven by the agent_client_protocol 0.12.x split into a thin
top-level crate plus agent-client-protocol-schema-0.13.x. Only a narrow
set of types stayed re-exported at the root; the rest moved into
`agent_client_protocol::schema`.

Fixes:
- Re-route `agent_client_protocol as acp` to `agent_client_protocol::schema as acp`
  in sandbox_tool.rs, sandbox_service_tool.rs, and agent_ui/thread_history.rs.
- Restore crates/agent/src/tools/tool_edit_parser.rs from PB main (PB-only
  file that did not survive the upstream merge).
- Drop 5 dead tool imports from thread.rs (NowTool, OpenTool,
  RestoreFileFromDiskTool, SaveFileTool, StreamingEditFileTool — removed
  upstream, never referenced after the import).
- Add `kind: AuthorizationKind::PermissionGrant` to the step-mode
  ToolCallAuthorization initializer (new required field upstream).
- Wrap two `LanguageModelToolResultContent::Text(...)` literals in `vec![...]`
  to match the field's `Vec<...>` type.
- Replace `AgentToolOutput::from_error("...")` with
  `AgentToolOutput::from(anyhow::anyhow!("..."))` (method was removed in
  favor of the `From<anyhow::Error>` impl).
- Rewrite the `if let LanguageModelToolResultContent::Image(_) =
  &output.llm_output` checks to iterate the Vec, since llm_output is no
  longer a single enum.

Remaining: 41 errors in agent_ui (cluster #7). Punch list in RECAPS.md.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
Cluster #7 of the PR #37 upstream-merge cleanup. All 14 errors cleared
in this pass are mechanical — restoring a PB-only module that didn't
survive the merge, adding a missing workspace dep, renaming three
symbols, and fixing field renames on ThreadView. The remaining 27 are
structural: PB's history-panel infrastructure (ActiveView, set_active_view,
background_threads, AgentConnectionEntry::history(), ConversationView
extension methods) was wiped by upstream's restructure of the agent panel.

Fixes:
- Restore crates/agent_ui/src/branch_names.rs from PB main (171 lines,
  PB-only word-list helpers).
- Add time_format.workspace = true to crates/agent_ui/Cargo.toml.
- Switch orchestration_panel.rs to agent_client_protocol::schema as acp.
- Rename agent::ZED_AGENT_ID → agent::PADDLEBOARD_AGENT_ID at 3 sites.
- Drop the unused AgentV2FeatureFlag import.
- Rename paddleboard_actions::agent::OpenAcpOnboardingModal →
  OpenOnboardingModal.
- Rename ThreadView field accesses: .id → .session_id, .parent_id →
  .parent_session_id (5 sites in orchestration_panel.rs).

Remaining 27 errors are PB-vs-upstream structural divergence. Punch list
and (A) restore vs (B) defer/delete options captured in RECAPS.md.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
…addleboard)

Final two clusters of the PR #37 upstream-merge cleanup. Workspace went
from 27 errors (in cluster #7 start) to 0 errors across all crates.
`cargo check --workspace` now finishes successfully.

Cluster #7 (agent_ui): Instead of restoring PB-main's full ActiveView
state machine (~1000 LOC), bridged PB's history-panel feature to
upstream's new BaseView + OverlayView layered model. PB's history view
slots into OverlayView::History alongside the existing Configuration
overlay, getting "back to previous view" semantics for free via
clear_overlay().

Key changes:
- Add OverlayView::History { view: Entity<ThreadHistoryView> } and
  parallel VisibleSurface::History plumbing (focus, title, render).
- Rewrite open_history against the overlay model.
- background_threads → retained_threads for all_conversation_views().
- AgentConnectionEntry::history() stub returning None (followup: wire
  per-agent history when AcpConnection backends support it).
- ConversationView::{workspace, delete_history_entry, navigate_to_session}
  — workspace is a real getter; the other two are stubs while
  AgentConnectionEntry::history() is disabled.
- gpui::Corner → gpui::Anchor (with alias to preserve callsites).
- Restored RemoveHistory action; dropped dead WorktreeCreationStatus
  re-export and AgentV2FeatureFlag import; renamed OpenAcpOnboardingModal
  → OpenOnboardingModal.
- Match-arm exhaustiveness: AgentIdOrLegacyAgent::LegacyAgent(Gemini)
  falls back to NativeAgent.id(); EditPredictionProvider::Experimental(_)
  hides edit-prediction namespace (same as None).
- supports_delete() gained a &App arg (passed through at all 4 callsites).
- Expanded thread_import re-exports for sidebar crate.

Cluster #8 (paddleboard binary, 3 errors → 0):
- Added `Error` and `editor::Editor` to imports.
- EditPredictionProvider::Experimental(_) match arm.
- Mapped tasks-future results through `.map(|_| ())` to match the
  Vec<Result<(), Error>> type.

Followups captured in RECAPS:
- Per-agent thread history (AgentConnectionEntry::history) re-enable.
- load_agent_thread bridge for ThreadHistoryViewEvent::Open callsites.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
Cluster #9 of the PR #37 upstream-merge cleanup. Resolves all
`./script/clippy` errors (clippy --workspace --release --all-targets
--all-features --deny warnings), confirms the debug binary links, and
smoke-tests `--system-specs` to exercise the startup path.

Cleanups:
- Delete language_model/{rate_limiter,role}.rs (PB shadows of the
  canonical language_model_core::* re-exports — confirmed unused).
- Delete agent/tools/tool_edit_parser.rs (ToolEditParser was unused
  anywhere; restored in cluster #6 only to silence the missing-mod
  error, but the `mod` declaration was orphaned).
- Rename ZED_PREDICT_DATA_COLLECTION_CHOICE → PADDLEBOARD_… in
  edit_prediction_tests.rs (7 sites; runtime code already renamed).
- Switch Command::spawn / Command::output to util::command helpers
  in paddleboard_sandbox_prereqs_ui and repl/podman_kernel (the
  podman_kernel one is in Drop, so wrapped in
  #[allow(clippy::disallowed_methods)] with explanatory comment).
- `#[allow(dead_code)]` for the PB history-panel infrastructure
  (ActiveView::History, AgentPanel history methods, branch_names.rs,
  thread_history.rs, thread_history_view.rs). The action handler isn't
  wired up yet — followup tracked in RECAPS.md.
- Add Agent::Stub match arm to has_history_for_selected_agent for the
  `test-support` feature shape.
- 24 misc lint cleanups: 5× redundant clones, 6× unused imports,
  3× pre-existing dead-code allows, 1× sort_by_key simplification,
  3× unused-variable underscoring in conversation_view/thread_view.rs.
- Add smol to agent_ui's dev-dependencies (used in TestSessionList).
- Add util to paddleboard_sandbox_prereqs_ui's deps.

Verified:
- `./script/clippy` finishes successfully (release profile, all-targets,
  all-features, deny warnings).
- `cargo build -p paddleboard` finishes successfully in 1m 41s on macOS.
- `./target/debug/paddleboard --system-specs` boots cleanly and prints
  PaddleBoard v0.232.0+dev.bd467db14 system-specs output.

PR #37 is ready to flip from draft to ready-for-review.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
jasonsmithio added a commit that referenced this pull request May 31, 2026
…6-05-19

Merge upstream zed/main (2026-05-19)
jasonsmithio added a commit that referenced this pull request May 31, 2026
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.