Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closing a window crashes other Zed windows #17005

Open
1 task done
roehnan opened this issue Aug 28, 2024 · 21 comments · Fixed by #17510 · May be fixed by #20853
Open
1 task done

Closing a window crashes other Zed windows #17005

roehnan opened this issue Aug 28, 2024 · 21 comments · Fixed by #17510 · May be fixed by #20853
Labels
bug [core label] linux linux-wayland Linux Wayland panic / crash [core label] workspace Feedback for workspace management, layout, interactions, etc

Comments

@roehnan
Copy link

roehnan commented Aug 28, 2024

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

  1. Open a zed window for a folder with zed ..
  2. Navigate to another folder and also open it with zed ..
  3. Close one of the windows.
  4. Boom!

Environment

Zed: v0.151.0 (Zed Nightly 22a791d)
OS: Linux Wayland fedora 40
Memory: 30.6 GiB
Architecture: x86_64
GPU: NVIDIA RTX A3000 Laptop GPU || NVIDIA || 555.58.02

If applicable, add mockups / screenshots to help explain present your vision of the feature

Screencast.from.2024-08-28.08-00-32.mp4

If applicable, attach your Zed.log file to this issue.

Zed.log
2024-08-28T07:59:31.307244453-06:00 [INFO] ========== starting zed ==========
2024-08-28T07:59:31.424491047-06:00 [INFO] perform;
2024-08-28T07:59:31.424534165-06:00 [INFO] authenticate;
2024-08-28T07:59:31.424588481-06:00 [INFO] read_command;
2024-08-28T07:59:31.424735036-06:00 [INFO] Opening main db
2024-08-28T07:59:31.424849215-06:00 [INFO] new;
2024-08-28T07:59:31.424882669-06:00 [INFO] socket reader;
2024-08-28T07:59:31.425251536-06:00 [INFO] keep_updated;
2024-08-28T07:59:31.428274016-06:00 [INFO] Using git binary path: None
2024-08-28T07:59:31.452096309-06:00 [ERROR] No such file or directory (os error 2) about ["/home/joshuabiagio/.config/github-copilot"]
2024-08-28T07:59:31.452291497-06:00 [INFO] initializing context server client
2024-08-28T07:59:31.452372428-06:00 [INFO] Registering built-in prompt template: content_prompt
2024-08-28T07:59:31.452616817-06:00 [INFO] Registering built-in prompt template: edit_workflow
2024-08-28T07:59:31.452819861-06:00 [INFO] Registering built-in prompt template: step_resolution
2024-08-28T07:59:31.453124063-06:00 [INFO] Registering built-in prompt template: terminal_assistant_prompt
2024-08-28T07:59:31.453374557-06:00 [INFO] Prompt template overrides directory found at /home/joshuabiagio/.local/share/zed/prompt_overrides.
2024-08-28T07:59:31.454060087-06:00 [INFO] extensions updated. loading 5, reloading 0, unloading 0
2024-08-28T07:59:31.456526691-06:00 [INFO] performance metrics display disabled
2024-08-28T07:59:31.456582439-06:00 [INFO] activate is not implemented on Linux, ignoring the call
2024-08-28T07:59:31.457804798-06:00 [INFO] perform;
2024-08-28T07:59:31.457838103-06:00 [INFO] authenticate;
2024-08-28T07:59:31.457874304-06:00 [INFO] read_command;
2024-08-28T07:59:31.458188749-06:00 [INFO] socket reader;
2024-08-28T07:59:31.459404758-06:00 [INFO] set environment variables from shell:/usr/bin/fish, path:/home/joshuabiagio/venv/bin:/home/joshuabiagio/.local/bin:/home/joshuabiagio/.cargo/bin:/home/joshuabiagio/.krew/bin:/home/joshuabiagio/go/bin:/usr/local/go/bin:/home/joshuabiagio/.local/bin:/home/joshuabiagio/.cargo/bin:/home/joshuabiagio/.krew/bin:/home/joshuabiagio/go/bin:/usr/local/go/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin
2024-08-28T07:59:31.461838493-06:00 [INFO] Opening main db
2024-08-28T07:59:31.461936503-06:00 [INFO] new;
2024-08-28T07:59:31.462358953-06:00 [INFO] keep_updated;
2024-08-28T07:59:31.463669062-06:00 [INFO] set status on client 0: Authenticating
2024-08-28T07:59:31.463934001-06:00 [INFO] perform;
2024-08-28T07:59:31.463987518-06:00 [INFO] authenticate;
2024-08-28T07:59:31.464041842-06:00 [INFO] read_command;
2024-08-28T07:59:31.464274917-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464327763-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464371537-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464400819-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464491485-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464529788-06:00 [INFO] socket reader;
2024-08-28T07:59:31.464566797-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464625113-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464660598-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464696537-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464724498-06:00 [INFO] building git repository, `.git` path in the worktree: ".git"
2024-08-28T07:59:31.464770375-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.464820989-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:31.468246426-06:00 [INFO] new;
2024-08-28T07:59:31.468677195-06:00 [INFO] keep_updated;
2024-08-28T07:59:31.568649656-06:00 [INFO] Enabling Vulkan Portability
2024-08-28T07:59:31.568696106-06:00 [INFO] Enabling color space support
2024-08-28T07:59:31.656838316-06:00 [INFO] Adapter: "NVIDIA RTX A3000 Laptop GPU"
2024-08-28T07:59:31.656907206-06:00 [INFO] Ray tracing is supported
2024-08-28T07:59:32.065999693-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T07:59:32.06604648-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T07:59:32.074185653-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T07:59:32.074221423-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T07:59:32.074248444-06:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: PreMultiplied }
2024-08-28T07:59:32.080697852-06:00 [INFO] Using GPU: GPUSpecs { is_software_emulated: false, device_name: "NVIDIA RTX A3000 Laptop GPU", driver_name: "NVIDIA", driver_info: "555.58.02" }
2024-08-28T07:59:32.081954954-06:00 [INFO] set status on client 199060: Connecting
2024-08-28T07:59:32.084188512-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.084246101-06:00 [INFO] Opening main db
2024-08-28T07:59:32.107876257-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.10837673-06:00 [INFO] time to first window draw: 802.004368ms
2024-08-28T07:59:32.108486857-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.108521521-06:00 [INFO] Node runtime install_if_needed
2024-08-28T07:59:32.108835181-06:00 [INFO] Opening main db
2024-08-28T07:59:32.164298502-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T07:59:32.164352434-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T07:59:32.179513514-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.179796107-06:00 [INFO] starting language server. binary path: "/home/joshuabiagio/.local/share/zed/node/node-v22.5.1-linux-x64/bin/node", working directory: "/", args: ["/home/joshuabiagio/.local/share/zed/copilot/copilot-v0.5.0/dist/agent.js", "--stdio"]
2024-08-28T07:59:32.198877988-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:32.198923343-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.199203934-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:32.199233533-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.199342047-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:32.199374291-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.199403785-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.201418587-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:32.201462596-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.201490587-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.201597072-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.223003232-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.416846571-06:00 [INFO] connected to rpc endpoint https://collab.zed.dev/rpc
2024-08-28T07:59:32.443650207-06:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-08-28T13:59:32.440Z] Agent service starting",
  "metadataStr": "[DEBUG] [agent] [2024-08-28T13:59:32.440Z]",
  "extra": [
    "Agent service starting"
  ]
}
2024-08-28T07:59:32.444963798-06:00 [INFO] Language server with id 0 sent unhandled notification client/registerCapability:
{
  "registrations": [
    {
      "id": "b7ca279b-b6c7-46e0-9eee-79c66854f3c9",
      "method": "workspace/didChangeWorkspaceFolders",
      "registerOptions": {}
    }
  ]
}
2024-08-28T07:59:32.472485258-06:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-08-28T13:59:32.449Z] Telemetry initialized",
  "metadataStr": "[DEBUG] [agent] [2024-08-28T13:59:32.449Z]",
  "extra": [
    "Telemetry initialized"
  ]
}
2024-08-28T07:59:32.482287171-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:32.482330535-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.482418816-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:32.483210239-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:32.936539821-06:00 [INFO] add connection to peer
2024-08-28T07:59:32.936640933-06:00 [INFO] add_connection;
2024-08-28T07:59:32.936720868-06:00 [INFO] waiting for server hello
2024-08-28T07:59:32.954001915-06:00 [INFO] got server hello
2024-08-28T07:59:32.954153782-06:00 [INFO] set status to connected (connection id: ConnectionId { owner_id: 0, id: 0 }, peer id: PeerId { owner_id: 502, id: 812497 })
2024-08-28T07:59:32.954352039-06:00 [INFO] set status on client 199060: Connected { peer_id: PeerId { owner_id: 502, id: 812497 }, connection_id: ConnectionId { owner_id: 0, id: 0 } }
2024-08-28T07:59:33.933925528-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T07:59:33.934078371-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T07:59:37.866166077-06:00 [INFO] building git repository, `.git` path in the worktree: ".git"
2024-08-28T07:59:37.887838455-06:00 [INFO] Enabling Vulkan Portability
2024-08-28T07:59:37.887872913-06:00 [INFO] Enabling color space support
2024-08-28T07:59:37.928977985-06:00 [INFO] Adapter: "NVIDIA RTX A3000 Laptop GPU"
2024-08-28T07:59:37.929040718-06:00 [INFO] Ray tracing is supported
2024-08-28T07:59:38.205144078-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T07:59:38.205192186-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T07:59:38.212507348-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T07:59:38.212542541-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T07:59:38.212567983-06:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: PreMultiplied }
2024-08-28T07:59:38.217173379-06:00 [INFO] Using GPU: GPUSpecs { is_software_emulated: false, device_name: "NVIDIA RTX A3000 Laptop GPU", driver_name: "NVIDIA", driver_info: "555.58.02" }
2024-08-28T07:59:38.217425917-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:38.217462188-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:38.217488067-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:38.223450623-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:38.257986666-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:38.258052639-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:38.258080417-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:38.273972841-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T07:59:38.274014412-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T07:59:38.285594047-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:38.317366358-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:38.317433289-06:00 [INFO] starting language servers for Dockerfile: dockerfile-language-server
2024-08-28T07:59:38.317462357-06:00 [INFO] starting language server "dockerfile-language-server", path: "/home/joshuabiagio/go/src/gitlab.com/vivint/horizontals/platform/platform-base", id: 1
2024-08-28T07:59:38.31760742-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:38.317646562-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:38.31768879-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T07:59:38.317867988-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T07:59:38.317902651-06:00 [INFO] starting language servers for Dockerfile: dockerfile-language-server
2024-08-28T07:59:38.318744305-06:00 [INFO] Node runtime install_if_needed
2024-08-28T07:59:38.318821361-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T07:59:38.960509924-06:00 [INFO] Node runtime install_if_needed
2024-08-28T07:59:39.032703641-06:00 [INFO] starting language server. binary path: "/home/joshuabiagio/.local/share/zed/node/node-v22.5.1-linux-x64/bin/node", working directory: "/home/joshuabiagio/go/src/gitlab.com/vivint/horizontals/platform/platform-base", args: ["/home/joshuabiagio/.local/share/zed/extensions/work/dockerfile/node_modules/dockerfile-language-server-nodejs/bin/docker-langserver", "--stdio"]
2024-08-28T07:59:39.113570731-06:00 [WARN] unhandled capability registration: Registration { id: "bb0388d3-2a70-4d12-8a92-1f9a59323690", method: "workspace/didChangeConfiguration", register_options: Some(Object {}) }
2024-08-28T07:59:42.77870001-06:00 [ERROR] window not found
2024-08-28T07:59:42.778834055-06:00 [ERROR] window not found
2024-08-28T08:00:36.825332643-06:00 [INFO] ========== starting zed ==========
2024-08-28T08:00:36.85163658-06:00 [INFO] perform;
2024-08-28T08:00:36.851684437-06:00 [INFO] authenticate;
2024-08-28T08:00:36.85172788-06:00 [INFO] read_command;
2024-08-28T08:00:36.851925231-06:00 [INFO] Opening main db
2024-08-28T08:00:36.85206911-06:00 [INFO] new;
2024-08-28T08:00:36.852105037-06:00 [INFO] socket reader;
2024-08-28T08:00:36.85249842-06:00 [INFO] keep_updated;
2024-08-28T08:00:36.854158869-06:00 [INFO] Using git binary path: None
2024-08-28T08:00:36.8775163-06:00 [ERROR] No such file or directory (os error 2) about ["/home/joshuabiagio/.config/github-copilot"]
2024-08-28T08:00:36.877733462-06:00 [INFO] initializing context server client
2024-08-28T08:00:36.877829381-06:00 [INFO] Registering built-in prompt template: content_prompt
2024-08-28T08:00:36.878071735-06:00 [INFO] Registering built-in prompt template: edit_workflow
2024-08-28T08:00:36.878254789-06:00 [INFO] Registering built-in prompt template: step_resolution
2024-08-28T08:00:36.878533554-06:00 [INFO] Registering built-in prompt template: terminal_assistant_prompt
2024-08-28T08:00:36.878721101-06:00 [INFO] Prompt template overrides directory found at /home/joshuabiagio/.local/share/zed/prompt_overrides.
2024-08-28T08:00:36.879302961-06:00 [INFO] extensions updated. loading 5, reloading 0, unloading 0
2024-08-28T08:00:36.880090376-06:00 [INFO] set environment variables from shell:/usr/bin/fish, path:/home/joshuabiagio/venv/bin:/home/joshuabiagio/.local/bin:/home/joshuabiagio/.cargo/bin:/home/joshuabiagio/.krew/bin:/home/joshuabiagio/go/bin:/usr/local/go/bin:/home/joshuabiagio/.local/bin:/home/joshuabiagio/.cargo/bin:/home/joshuabiagio/.krew/bin:/home/joshuabiagio/go/bin:/usr/local/go/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin
2024-08-28T08:00:36.881578993-06:00 [INFO] performance metrics display disabled
2024-08-28T08:00:36.88163066-06:00 [INFO] activate is not implemented on Linux, ignoring the call
2024-08-28T08:00:36.897102603-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897169724-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897201492-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897230679-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897260353-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897310357-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897347261-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897377016-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897406078-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.897752105-06:00 [INFO] perform;
2024-08-28T08:00:36.897814521-06:00 [INFO] authenticate;
2024-08-28T08:00:36.897912546-06:00 [INFO] read_command;
2024-08-28T08:00:36.898278519-06:00 [INFO] socket reader;
2024-08-28T08:00:36.901975814-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.902036687-06:00 [INFO] Opening main db
2024-08-28T08:00:36.902337513-06:00 [INFO] new;
2024-08-28T08:00:36.902787267-06:00 [INFO] keep_updated;
2024-08-28T08:00:36.903037935-06:00 [INFO] set status on client 0: Authenticating
2024-08-28T08:00:36.903107567-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:36.9032168-06:00 [INFO] perform;
2024-08-28T08:00:36.903252464-06:00 [INFO] authenticate;
2024-08-28T08:00:36.903285718-06:00 [INFO] read_command;
2024-08-28T08:00:36.9034541-06:00 [INFO] socket reader;
2024-08-28T08:00:36.903512691-06:00 [INFO] building git repository, `.git` path in the worktree: ".git"
2024-08-28T08:00:36.90692047-06:00 [INFO] new;
2024-08-28T08:00:36.907271874-06:00 [INFO] keep_updated;
2024-08-28T08:00:36.960462773-06:00 [INFO] Enabling Vulkan Portability
2024-08-28T08:00:36.960502816-06:00 [INFO] Enabling color space support
2024-08-28T08:00:37.043169316-06:00 [INFO] Adapter: "NVIDIA RTX A3000 Laptop GPU"
2024-08-28T08:00:37.04323803-06:00 [INFO] Ray tracing is supported
2024-08-28T08:00:37.377034327-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:00:37.377085963-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:00:37.384519077-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:00:37.384556892-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:00:37.384584165-06:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: PreMultiplied }
2024-08-28T08:00:37.390359438-06:00 [INFO] Using GPU: GPUSpecs { is_software_emulated: false, device_name: "NVIDIA RTX A3000 Laptop GPU", driver_name: "NVIDIA", driver_info: "555.58.02" }
2024-08-28T08:00:37.390824096-06:00 [INFO] set status on client 199060: Connecting
2024-08-28T08:00:37.392608492-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.392702186-06:00 [INFO] Opening main db
2024-08-28T08:00:37.39367128-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.394491897-06:00 [INFO] Opening main db
2024-08-28T08:00:37.452887384-06:00 [INFO] time to first window draw: 627.704008ms
2024-08-28T08:00:37.453006807-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.453050911-06:00 [INFO] Node runtime install_if_needed
2024-08-28T08:00:37.480560296-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:00:37.480609702-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:00:37.492368389-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.502873408-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:37.502939454-06:00 [INFO] starting language servers for Dockerfile: 
2024-08-28T08:00:37.503066624-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:37.50310987-06:00 [INFO] starting language servers for Dockerfile: 
2024-08-28T08:00:37.503948248-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.529449144-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:37.529540869-06:00 [INFO] starting language servers for Dockerfile: 
2024-08-28T08:00:37.530653964-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.530697969-06:00 [INFO] starting language server. binary path: "/home/joshuabiagio/.local/share/zed/node/node-v22.5.1-linux-x64/bin/node", working directory: "/", args: ["/home/joshuabiagio/.local/share/zed/copilot/copilot-v0.5.0/dist/agent.js", "--stdio"]
2024-08-28T08:00:37.6458738-06:00 [INFO] connected to rpc endpoint https://collab.zed.dev/rpc
2024-08-28T08:00:37.799222023-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:37.799309583-06:00 [INFO] starting language servers for Dockerfile: dockerfile-language-server
2024-08-28T08:00:37.799347381-06:00 [INFO] starting language server "dockerfile-language-server", path: "/home/joshuabiagio/go/src/gitlab.com/vivint/horizontals/platform/platform-base", id: 1
2024-08-28T08:00:37.800174546-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:37.80021847-06:00 [INFO] Node runtime install_if_needed
2024-08-28T08:00:37.827533949-06:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-08-28T14:00:37.818Z] Agent service starting",
  "metadataStr": "[DEBUG] [agent] [2024-08-28T14:00:37.818Z]",
  "extra": [
    "Agent service starting"
  ]
}
2024-08-28T08:00:37.827878711-06:00 [INFO] Language server with id 0 sent unhandled notification client/registerCapability:
{
  "registrations": [
    {
      "id": "690a6df5-46ba-4460-b352-647969333869",
      "method": "workspace/didChangeWorkspaceFolders",
      "registerOptions": {}
    }
  ]
}
2024-08-28T08:00:37.857216709-06:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-08-28T14:00:37.832Z] Telemetry initialized",
  "metadataStr": "[DEBUG] [agent] [2024-08-28T14:00:37.832Z]",
  "extra": [
    "Telemetry initialized"
  ]
}
2024-08-28T08:00:38.136667231-06:00 [INFO] add connection to peer
2024-08-28T08:00:38.136806153-06:00 [INFO] add_connection;
2024-08-28T08:00:38.13691515-06:00 [INFO] waiting for server hello
2024-08-28T08:00:38.161141826-06:00 [INFO] got server hello
2024-08-28T08:00:38.16131413-06:00 [INFO] set status to connected (connection id: ConnectionId { owner_id: 0, id: 0 }, peer id: PeerId { owner_id: 502, id: 813387 })
2024-08-28T08:00:38.161566819-06:00 [INFO] set status on client 199060: Connected { peer_id: PeerId { owner_id: 502, id: 813387 }, connection_id: ConnectionId { owner_id: 0, id: 0 } }
2024-08-28T08:00:38.324642089-06:00 [INFO] Node runtime install_if_needed
2024-08-28T08:00:38.397838345-06:00 [INFO] starting language server. binary path: "/home/joshuabiagio/.local/share/zed/node/node-v22.5.1-linux-x64/bin/node", working directory: "/home/joshuabiagio/go/src/gitlab.com/vivint/horizontals/platform/platform-base", args: ["/home/joshuabiagio/.local/share/zed/extensions/work/dockerfile/node_modules/dockerfile-language-server-nodejs/bin/docker-langserver", "--stdio"]
2024-08-28T08:00:38.471966871-06:00 [WARN] unhandled capability registration: Registration { id: "f686dec6-6104-4ead-a434-88c4d64e89d3", method: "workspace/didChangeConfiguration", register_options: Some(Object {}) }
2024-08-28T08:00:44.991822297-06:00 [INFO] building git repository, `.git` path in the worktree: ".git"
2024-08-28T08:00:45.019403598-06:00 [INFO] Enabling Vulkan Portability
2024-08-28T08:00:45.019447207-06:00 [INFO] Enabling color space support
2024-08-28T08:00:45.048836846-06:00 [INFO] Adapter: "NVIDIA RTX A3000 Laptop GPU"
2024-08-28T08:00:45.048914423-06:00 [INFO] Ray tracing is supported
2024-08-28T08:00:45.317565995-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:00:45.31761589-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:00:45.326376996-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:00:45.326415118-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:00:45.326442585-06:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: PreMultiplied }
2024-08-28T08:00:45.332404192-06:00 [INFO] Using GPU: GPUSpecs { is_software_emulated: false, device_name: "NVIDIA RTX A3000 Laptop GPU", driver_name: "NVIDIA", driver_info: "555.58.02" }
2024-08-28T08:00:45.332774012-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:45.332830185-06:00 [INFO] starting language servers for Dockerfile: dockerfile-language-server
2024-08-28T08:00:45.340858197-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:45.370196544-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:45.370271792-06:00 [INFO] starting language servers for Dockerfile: dockerfile-language-server
2024-08-28T08:00:45.387137335-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:00:45.387181255-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:00:45.397661998-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:45.400792279-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:45.400838826-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:00:45.401122253-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:45.401165963-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:00:45.40625008-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:45.40636204-06:00 [INFO] starting language servers for Dockerfile: dockerfile-language-server
2024-08-28T08:00:45.406775273-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:00:45.406826369-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:00:45.40685537-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:00:45.408722419-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:00:47.808828579-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:00:47.808924092-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:01:45.627521954-06:00 [INFO] ========== starting zed ==========
2024-08-28T08:01:45.650629828-06:00 [INFO] Opening main db
2024-08-28T08:01:45.65073327-06:00 [INFO] perform;
2024-08-28T08:01:45.65076987-06:00 [INFO] authenticate;
2024-08-28T08:01:45.650814156-06:00 [INFO] read_command;
2024-08-28T08:01:45.651136744-06:00 [INFO] new;
2024-08-28T08:01:45.651172589-06:00 [INFO] socket reader;
2024-08-28T08:01:45.651545947-06:00 [INFO] keep_updated;
2024-08-28T08:01:45.652986078-06:00 [INFO] Using git binary path: None
2024-08-28T08:01:45.676505588-06:00 [ERROR] No such file or directory (os error 2) about ["/home/joshuabiagio/.config/github-copilot"]
2024-08-28T08:01:45.676720128-06:00 [INFO] initializing context server client
2024-08-28T08:01:45.67679665-06:00 [INFO] Registering built-in prompt template: content_prompt
2024-08-28T08:01:45.677046335-06:00 [INFO] Registering built-in prompt template: edit_workflow
2024-08-28T08:01:45.677239059-06:00 [INFO] Registering built-in prompt template: step_resolution
2024-08-28T08:01:45.677527071-06:00 [INFO] Registering built-in prompt template: terminal_assistant_prompt
2024-08-28T08:01:45.677660817-06:00 [INFO] Prompt template overrides directory found at /home/joshuabiagio/.local/share/zed/prompt_overrides.
2024-08-28T08:01:45.678297351-06:00 [INFO] extensions updated. loading 5, reloading 0, unloading 0
2024-08-28T08:01:45.678996747-06:00 [INFO] set environment variables from shell:/usr/bin/fish, path:/home/joshuabiagio/venv/bin:/home/joshuabiagio/.local/bin:/home/joshuabiagio/.cargo/bin:/home/joshuabiagio/.krew/bin:/home/joshuabiagio/go/bin:/usr/local/go/bin:/home/joshuabiagio/.local/bin:/home/joshuabiagio/.cargo/bin:/home/joshuabiagio/.krew/bin:/home/joshuabiagio/go/bin:/usr/local/go/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin
2024-08-28T08:01:45.680572547-06:00 [INFO] performance metrics display disabled
2024-08-28T08:01:45.680624426-06:00 [INFO] activate is not implemented on Linux, ignoring the call
2024-08-28T08:01:45.680694411-06:00 [INFO] Opening main db
2024-08-28T08:01:45.691675031-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.691720128-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.691749305-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.691784431-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.691821324-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.692409346-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.692448544-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.692521646-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.692560089-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.692600216-06:00 [INFO] perform;
2024-08-28T08:01:45.69265774-06:00 [INFO] authenticate;
2024-08-28T08:01:45.692718175-06:00 [INFO] read_command;
2024-08-28T08:01:45.693025615-06:00 [INFO] socket reader;
2024-08-28T08:01:45.696564403-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.69669869-06:00 [INFO] new;
2024-08-28T08:01:45.696970591-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:45.697153499-06:00 [INFO] keep_updated;
2024-08-28T08:01:45.697407211-06:00 [INFO] building git repository, `.git` path in the worktree: ".git"
2024-08-28T08:01:45.781749766-06:00 [INFO] Enabling Vulkan Portability
2024-08-28T08:01:45.781794279-06:00 [INFO] Enabling color space support
2024-08-28T08:01:45.856732106-06:00 [INFO] Adapter: "NVIDIA RTX A3000 Laptop GPU"
2024-08-28T08:01:45.856797557-06:00 [INFO] Ray tracing is supported
2024-08-28T08:01:46.25805207-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:01:46.25810277-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:01:46.268309688-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:01:46.268353223-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:01:46.268381329-06:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: PreMultiplied }
2024-08-28T08:01:46.274249354-06:00 [INFO] Using GPU: GPUSpecs { is_software_emulated: false, device_name: "NVIDIA RTX A3000 Laptop GPU", driver_name: "NVIDIA", driver_info: "555.58.02" }
2024-08-28T08:01:46.275377151-06:00 [INFO] set status on client 0: Authenticating
2024-08-28T08:01:46.276283908-06:00 [INFO] perform;
2024-08-28T08:01:46.276329406-06:00 [INFO] authenticate;
2024-08-28T08:01:46.276372302-06:00 [INFO] read_command;
2024-08-28T08:01:46.276719563-06:00 [INFO] socket reader;
2024-08-28T08:01:46.277278876-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:46.277374399-06:00 [INFO] Opening main db
2024-08-28T08:01:46.278933775-06:00 [INFO] Node runtime install_if_needed
2024-08-28T08:01:46.281234984-06:00 [INFO] new;
2024-08-28T08:01:46.281851621-06:00 [INFO] keep_updated;
2024-08-28T08:01:46.296608875-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:46.296838149-06:00 [INFO] Opening main db
2024-08-28T08:01:46.351791181-06:00 [INFO] set status on client 199060: Connecting
2024-08-28T08:01:46.352409344-06:00 [INFO] time to first window draw: 725.003268ms
2024-08-28T08:01:46.35252506-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:46.381515163-06:00 [INFO] Using surface present mode MAILBOX
2024-08-28T08:01:46.381563264-06:00 [WARN] Unable to forbid exclusive full screen
2024-08-28T08:01:46.395022582-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:46.404153879-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:01:46.404204086-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:01:46.404439333-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:01:46.404471655-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:01:46.404562996-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:01:46.404597059-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:01:46.404625513-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:01:46.405363595-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:46.405418231-06:00 [INFO] starting language server. binary path: "/home/joshuabiagio/.local/share/zed/node/node-v22.5.1-linux-x64/bin/node", working directory: "/", args: ["/home/joshuabiagio/.local/share/zed/copilot/copilot-v0.5.0/dist/agent.js", "--stdio"]
2024-08-28T08:01:46.59280085-06:00 [INFO] connected to rpc endpoint https://collab.zed.dev/rpc
2024-08-28T08:01:46.663134933-06:00 [INFO] Initializing default prettier with plugins {}
2024-08-28T08:01:46.663195122-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:01:46.663226907-06:00 [INFO] starting language servers for Shell Script: 
2024-08-28T08:01:46.664008522-06:00 [WARN] request completed with error: failed to connect to the server
2024-08-28T08:01:46.664907494-06:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-08-28T14:01:46.661Z] Agent service starting",
  "metadataStr": "[DEBUG] [agent] [2024-08-28T14:01:46.661Z]",
  "extra": [
    "Agent service starting"
  ]
}
2024-08-28T08:01:46.666423289-06:00 [INFO] Language server with id 0 sent unhandled notification client/registerCapability:
{
  "registrations": [
    {
      "id": "d406c639-75cb-4d17-8d14-167b2e4756e3",
      "method": "workspace/didChangeWorkspaceFolders",
      "registerOptions": {}
    }
  ]
}
2024-08-28T08:01:46.692630338-06:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-08-28T14:01:46.670Z] Telemetry initialized",
  "metadataStr": "[DEBUG] [agent] [2024-08-28T14:01:46.670Z]",
  "extra": [
    "Telemetry initialized"
  ]
}
2024-08-28T08:01:47.044708528-06:00 [INFO] add connection to peer
2024-08-28T08:01:47.044864481-06:00 [INFO] add_connection;
2024-08-28T08:01:47.044994687-06:00 [INFO] waiting for server hello
2024-08-28T08:01:47.060945805-06:00 [INFO] got server hello
2024-08-28T08:01:47.061119893-06:00 [INFO] set status to connected (connection id: ConnectionId { owner_id: 0, id: 0 }, peer id: PeerId { owner_id: 502, id: 814170 })
2024-08-28T08:01:47.061381255-06:00 [INFO] set status on client 199060: Connected { peer_id: PeerId { owner_id: 502, id: 814170 }, connection_id: ConnectionId { owner_id: 0, id: 0 } }
2024-08-28T08:01:47.667425068-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:01:47.688053041-06:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-08-28T08:01:47.716683016-06:00 [INFO] Creating a descriptor pool for at most 256 sets
2024-08-28T08:01:47.750074608-06:00 [INFO] Creating a descriptor pool for at most 256 sets
2024-08-28T08:03:54.397549941-06:00 [ERROR] window not found
@roehnan roehnan added admin read Pending admin review bug [core label] triage Maintainer needs to classify the issue labels Aug 28, 2024
@apricotbucket28
Copy link
Contributor

Same here. Bisected it to d1dceef.

These are the logs I get with KWin:

warning: queue 0x563a1bfcc750 destroyed while proxies still attached:
  wp_linux_drm_syncobj_timeline_v1#164 still attached
  wp_linux_drm_syncobj_timeline_v1#165 still attached
  wl_buffer#166 still attached
  wp_linux_drm_syncobj_timeline_v1#133 still attached
  wp_linux_drm_syncobj_timeline_v1#160 still attached
  wl_buffer#146 still attached
  wp_linux_drm_syncobj_timeline_v1#151 still attached
  wp_linux_drm_syncobj_timeline_v1#149 still attached
  wl_buffer#154 still attached
  wp_linux_drm_syncobj_timeline_v1#153 still attached
  wp_linux_drm_syncobj_timeline_v1#158 still attached
  wl_buffer#159 still attached
Tried to add event to destroyed queue

Interestingly, it only happens on Wayland and not on X11.

@apricotbucket28
Copy link
Contributor

Enabling Vulkan validation in the source code (which should be on by default in debug builds IMO) shows many errors like the following (both on Wayland and X11):

VUID-vkDestroySurfaceKHR-surface-01266(ERROR / SPEC): msgNum: -1093400348 - Validation Error: [ VUID-vkDestroySurfaceKHR-surface-01266 ] Object 0: handle = 0x55f9bc188460, type = VK_OBJECT_TYPE_INSTANCE; | MessageID = 0xbed408e4 | vkDestroySurfaceKHR():  called before its associated VkSwapchainKHR was destroyed. The Vulkan spec states: All VkSwapchainKHR objects created for surface must have been destroyed prior to destroying surface (https://www.khronos.org/registry/vulkan/specs/1.3-extensions/html/vkspec.html#VUID-vkDestroySurfaceKHR-surface-01266)
    Objects: 1
        [0] 0x55f9bc188460, type: 1, name: NULL

It seems like object destruction is being done incorrectly.

@Moshyfawn Moshyfawn added panic / crash [core label] workspace Feedback for workspace management, layout, interactions, etc linux and removed triage Maintainer needs to classify the issue labels Aug 28, 2024
@notpeter notpeter added linux-wayland Linux Wayland and removed admin read Pending admin review labels Aug 29, 2024
@apricotbucket28
Copy link
Contributor

Applying the following on blade@master fixes the crash on Wayland:

diff --git a/blade-graphics/src/vulkan/init.rs b/blade-graphics/src/vulkan/init.rs
index 3b4ac73..07625df 100644
--- a/blade-graphics/src/vulkan/init.rs
+++ b/blade-graphics/src/vulkan/init.rs
@@ -1034,8 +1034,6 @@ impl Drop for super::Context {
                     surface_instance.destroy_surface(surface.raw, None);
                 }
             }
-            self.device.core.destroy_device(None);
-            self.instance.core.destroy_instance(None);
             if let Ok(queue) = self.queue.lock() {
                 self.device
                     .core
@@ -1044,6 +1042,8 @@ impl Drop for super::Context {
                     .core
                     .destroy_semaphore(queue.present_semaphore, None);
             }
+            self.device.core.destroy_device(None);
+            self.instance.core.destroy_instance(None);
         }
     }
 }

There are still lots of Vulkan validation errors though.

@paring-chan
Copy link

Happening for me too(returns SIGABRT)
I'm using Hyprland on NixOS

❯ zed --foreground
[2024-08-30T18:52:11+09:00 ERROR theme] theme not found: Catppuccin Latte
[2024-08-30T18:52:11+09:00 ERROR assistant] no worktrees when constructing ProjectLspAdapterDelegate
[2024-08-30T18:57:03+09:00 ERROR gpui] window not found
[2024-08-30T18:57:03+09:00 ERROR gpui] window not found
warning: queue "mesa vk display queue" 0x56548d022920 destroyed while proxies still attached:
  wp_linux_drm_syncobj_timeline_v1#334 still attached
  wp_linux_drm_syncobj_timeline_v1#333 still attached
  wl_buffer#332 still attached
  wp_linux_drm_syncobj_timeline_v1#227 still attached
  wp_linux_drm_syncobj_timeline_v1#235 still attached
  wl_buffer#296 still attached
  wp_linux_drm_syncobj_timeline_v1#321 still attached
  wp_linux_drm_syncobj_timeline_v1#205 still attached
  wl_buffer#299 still attached
  wp_linux_drm_syncobj_timeline_v1#327 still attached
  wp_linux_drm_syncobj_timeline_v1#241 still attached
  wl_buffer#319 still attached
Tried to add event to destroyed queue

@apricotbucket28
Copy link
Contributor

cc: @ConradIrwin, since you're the last one to update Blade 🙂

The crash is now fixed in upstream Blade, but this bug affects 0.151.x (and it's a pretty bad regression imo) and master uses a different Blade branch (which hasn't been rebased with the fix yet).

Should I open a PR for the 0.151.x branch or to master (which would essentially revert #17022)?

@ConradIrwin
Copy link
Member

@apricotbucket28 We should probably merge the two. I'd like #17022 to hit preview tomorrow (we haven't heard complaints from anyone on main).

@apricotbucket28
Copy link
Contributor

I've opened #17319 for the 0.151.x branch. Unfortunately kvark/blade#144 hasn't been rebased with the fix yet.

ConradIrwin pushed a commit that referenced this issue Sep 5, 2024
See #17005

This PR updates Blade to fix a regression from
d1dceef,
and also properly destroys all Vulkan objects (verified by enabling
Vulkan validation in the source code, in both Wayland and X11).

Release Notes:

- Linux: Fixed crash when closing windows on Wayland.
@jvmncs jvmncs closed this as completed in f91bf7f Sep 6, 2024
notpeter pushed a commit that referenced this issue Sep 6, 2024
Closes #17005

Like #17319, but based on
kvark/blade#144.

This should be cherry-picked into preview if possible 🙂 

Release Notes:

- Linux: Fixed crash when closing windows on Wayland.
@roehnan
Copy link
Author

roehnan commented Sep 26, 2024

This is still happening. Unfortunately I don't see any new errors in the logs.

Please re-open issue.

@jvmncs jvmncs reopened this Oct 4, 2024
@jvmncs
Copy link
Contributor

jvmncs commented Oct 4, 2024

Same thing happens on my end (NixOS, Hyprland WM, latest nvidia driver), reopening.

Repro Steps:

  1. Open Zed
  2. Open any new Zed window (prompt library, new Zed workspace, etc.)
  3. Close either of the open Zed windows.

@toolateralus
Copy link

Same thing here. Arch linux, KDE plasma (wayland), latest nvidia driver. Makes it really tough to swap folders!

@taufik-nurhidayat
Copy link

Same here, but when i see others using nvidia. I think that a problem, because im use nvidia rtx 4060.

So this is step to make all window closed:

  1. Open zed
  2. Open new project
  3. Close first window
  4. Another window is closed to

@gretchenfrage
Copy link

Also experiencing this (on current main 3b76ba6d5ab6745cd12d2cb632ae4a55680dc89a), with Wayland.

I get a segfault. Using gdb to capture the segfault backtrace reveals this:

Thread 1 "zed" received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) backtrace
#0  0x0000000000000000 in ?? ()
#1  0x00007ffe1eb09e6c in ?? ()
   from /nix/store/sk11fm1g27s20fisyqj0qd3h4ll304qh-nvidia-x11-550.78-6.6.60/lib/libnvidia-glcore.so.550.78
#2  0x00007ffe1ed25255 in ?? ()
   from /nix/store/sk11fm1g27s20fisyqj0qd3h4ll304qh-nvidia-x11-550.78-6.6.60/lib/libnvidia-glcore.so.550.78
#3  0x00007ffe7ed5fa55 in ?? () from /nix/store/sk11fm1g27s20fisyqj0qd3h4ll304qh-nvidia-x11-550.78-6.6.60/lib/libGLX_nvidia.so.0
warning: Could not find DWO CU /home/phoenix/repos/zed/target/debug/deps/blade_graphics-8ddb4abc5a277634.blade_graphics.d0ca6537b5273178-cgu.12.rcgu.dwo(0x98cb31fe10f9cfb5) referenced by CU at offset 0x14964d [in module /home/phoenix/repos/zedstuff/zed/target/debug/zed]
warning: Could not find DWO CU /home/phoenix/repos/zed/target/debug/deps/blade_graphics-8ddb4abc5a277634.blade_graphics.d0ca6537b5273178-cgu.03.rcgu.dwo(0x28ce01bbecb90e26) referenced by CU at offset 0x149481 [in module /home/phoenix/repos/zedstuff/zed/target/debug/zed]
#4  0x00005555635742cb in ash::extensions::khr::swapchain::<impl ash::extensions_generated::khr::swapchain::Device>::acquire_next_image () at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ash-0.38.0+1.3.281/src/extensions/khr/swapchain.rs:62
#5  0x000055556353d6f8 in blade_graphics::hal::init::<impl blade_graphics::hal::Context>::acquire_frame ()
    at src/vulkan/init.rs:1081
#6  0x0000555562745299 in gpui::platform::blade::blade_renderer::BladeRenderer::draw ()
    at crates/gpui/src/platform/blade/blade_renderer.rs:566
#7  0x0000555562891aac in gpui::platform::linux::wayland::window::{impl#8}::draw ()
    at crates/gpui/src/platform/linux/wayland/window.rs:943
#8  0x00005555625c5a44 in gpui::window::WindowContext::present () at crates/gpui/src/window.rs:1495
#9  0x000055556289886e in gpui::window::{impl#19}::new::{closure#4}::{closure#1}::{closure#0} () at crates/gpui/src/window.rs:707
#10 0x0000555562672470 in gpui::app::{impl#5}::update_window::{closure#0}<(), gpui::window::{impl#19}::new::{closure#4}::{closure#1}::{closure_env#0}> () at crates/gpui/src/app.rs:1452
#11 0x0000555562667a01 in gpui::app::AppContext::update<core::result::Result<(), anyhow::Error>, gpui::app::{impl#5}::update_window::{closure_env#0}<(), gpui::window::{impl#19}::new::{closure#4}::{closure#1}::{closure_env#0}>> () at crates/gpui/src/app.rs:372
#12 0x000055556266ad47 in gpui::app::{impl#5}::update_window<(), gpui::window::{impl#19}::new::{closure#4}::{closure#1}::{closure_env#0}> () at crates/gpui/src/app.rs:1443
#13 0x0000555562660b8b in gpui::app::async_context::{impl#0}::update_window<(), gpui::window::{impl#19}::new::{closure#4}::{closure#1}::{closure_env#0}> () at crates/gpui/src/app/async_context.rs:91
#14 0x00005555628c2126 in gpui::window::AnyWindowHandle::update<gpui::app::async_context::AsyncAppContext, (), gpui::window::{impl#19}::new::{closure#4}::{closure#1}::{closure_env#0}> () at crates/gpui/src/window.rs:4822
#15 0x000055556289880b in gpui::window::{impl#19}::new::{closure#4}::{closure#1} () at crates/gpui/src/window.rs:704
#16 0x000055556253ea4c in util::measure<(), gpui::window::{impl#19}::new::{closure#4}::{closure_env#1}> ()
    at crates/util/src/util.rs:327
#17 0x0000555562898568 in gpui::window::{impl#19}::new::{closure#4} () at crates/gpui/src/window.rs:703
#18 0x0000555562c3957e in alloc::boxed::{impl#49}::call_mut<(), dyn core::ops::function::FnMut<(), Output=()>, alloc::alloc::Global> () at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/alloc/src/boxed.rs:2077
#19 0x000055556288a87e in gpui::platform::linux::wayland::window::WaylandWindowStatePtr::frame ()
    at crates/gpui/src/platform/linux/wayland/window.rs:326
#20 0x0000555562734b29 in gpui::platform::linux::wayland::client::{impl#7}::event ()
    at crates/gpui/src/platform/linux/wayland/client.rs:874
#21 0x00005555624a48b4 in wayland_client::event_queue::queue_callback<wayland_client::protocol::wl_callback::WlCallback, wayland_backend::sys::client::ObjectId, gpui::platform::linux::wayland::client::WaylandClientStatePtr> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wayland-client-0.31.5/src/event_queue.rs:660
#22 0x00005555624a85ec in wayland_client::event_queue::EventQueue::dispatching_impl<gpui::platform::linux::wayland::client::WaylandClientStatePtr> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wayland-client-0.31.5/src/event_queue.rs:482
#23 0x00005555624a84fb in wayland_client::event_queue::EventQueue::dispatch_pending<gpui::platform::linux::wayland::client::WaylandClientStatePtr> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wayland-client-0.31.5/src/event_queue.rs:388
#24 0x00005555626fa7cf in calloop_wayland_source::{impl#0}::insert::{closure#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr> () at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-wayland-source-0.3.0/src/lib.rs:115
#25 0x00005555626f8b5e in calloop::sources::{impl#4}::process_events::{closure#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr, calloop_wayland_source::WaylandSource<gpui::platform::linux::wayland::client::WaylandClientStatePtr>, calloop_wayland_source::{impl#0}::insert::{closure_env#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr>> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-0.13.0/src/sources/mod.rs:327
#26 0x00005555626fa226 in calloop_wayland_source::WaylandSource::loop_callback_pending<gpui::platform::linux::wayland::client::WaylandClientStatePtr, calloop::sources::{impl#4}::process_events::{closure_env#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr, calloop_wayland_source::WaylandSource<gpui::platform::linux::wayland::client::WaylandClientStatePtr>, calloop_wayland_source::{impl#0}::insert::{closure_env#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr>>> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-wayland-source-0.3.0/src/lib.rs:245
#27 0x000055556270868d in calloop_wayland_source::{impl#1}::process_events<gpui::platform::linux::wayland::client::WaylandClientStatePtr, calloop::sources::{impl#4}::process_events::{closure_env#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr, calloop_wayland_source::WaylandSource<gpui::platform::linux::wayland::client::WaylandClientStatePtr>, calloop_wayland_source::{impl#0}::insert::{closure_env#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr>>> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-wayland-source-0.3.0/src/lib.rs:154
#28 0x000055556249d24c in calloop::sources::{impl#4}::process_events<gpui::platform::linux::wayland::client::WaylandClientStatePtr, calloop_wayland_source::WaylandSource<gpui::platform::linux::wayland::client::WaylandClientStatePtr>, calloop_wayland_source::{impl#0}::insert::{closure_env#0}<gpui::platform::linux::wayland::client::WaylandClientStatePtr>> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-0.13.0/src/sources/mod.rs:326
#29 0x0000555562552824 in calloop::loop_logic::EventLoop::dispatch_events<gpui::platform::linux::wayland::client::WaylandClientStatePtr> () at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-0.13.0/src/loop_logic.rs:445
#30 0x0000555562556a11 in calloop::loop_logic::EventLoop::dispatch<gpui::platform::linux::wayland::client::WaylandClientStatePtr, core::option::Option<core::time::Duration>> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-0.13.0/src/loop_logic.rs:559
#31 0x0000555562554767 in calloop::loop_logic::EventLoop::run<gpui::platform::linux::wayland::client::WaylandClientStatePtr, gpui::platform::linux::wayland::client::{impl#5}::run::{closure_env#0}, core::option::Option<core::time::Duration>> ()
    at /home/phoenix/.cargo/registry/src/index.crates.io-6f17d22bba15001f/calloop-0.13.0/src/loop_logic.rs:596
#32 0x0000555562733393 in gpui::platform::linux::wayland::client::{impl#5}::run ()
    at crates/gpui/src/platform/linux/wayland/client.rs:713
#33 0x000055556259a699 in gpui::platform::linux::platform::{impl#1}::run<gpui::platform::linux::wayland::client::WaylandClient> ()
    at crates/gpui/src/platform/linux/platform.rs:144
#34 0x000055555a3cd612 in gpui::app::App::run<zed::main::{closure_env#5}> () at crates/gpui/src/app.rs:161
#35 0x000055555a44784a in zed::main () at crates/zed/src/main.rs:249

I'll note that, before I run run in the gdb shell, I have to enter handle SIGPIPE nostop noprint pass, to prevent it from breaking at a sigpipe signal which I assume has to do with some unrelated interaction with nixos and dlls.

@kvark
Copy link
Contributor

kvark commented Nov 14, 2024

Anything in the logs?
Anything that Vulkan validation shows when this is happening?
Crash inside acquire_next_image is totally unexpected.
Could someone confirm if Zed is re-using the same process for this case, or each instance is a separate process?

@ConradIrwin
Copy link
Member

Not sure if this is what you're asking, but Zed runs one process that has multiple windows: one per project that you open.

@kvark
Copy link
Contributor

kvark commented Nov 15, 2024

That makes sense, thanks! I'll see if I can repro this by creating different contexts within the same process.
At the end of the day, kvark/blade#82 would be best here. I'll see if I can prototype it.

@benterova
Copy link

Also having this issue -- has a cause been identified and a solution proposed? Happy to provide info if helpful.

@roehnan
Copy link
Author

roehnan commented Nov 23, 2024

Is this strictly an NVIDIA thing? The system I reported the issue on has an NVIDIA GPU. My other laptop that has an older AMD APU doesn't seem to exhibit the same crashing behavior.

@benterova
Copy link

Is this strictly an NVIDIA thing? The system I reported the issue on has an NVIDIA GPU. My other laptop that has an older AMD APU doesn't seem to exhibit the same crashing behavior.

Yes, I have an NVIDIA GPU, so that might be the cause.

@kvark
Copy link
Contributor

kvark commented Nov 23, 2024

If anyone can check out #20853 and confirm if it fixes it, that would be great!

@gretchenfrage
Copy link

If anyone can check out #20853 and confirm if it fixes it, that would be great!

Yes! Your branch on my system lets me open and close new windows as much as I want without Zed crashing. Thanks for your work on this!

@alexjg
Copy link

alexjg commented Nov 24, 2024

#20853 Fixes the issue for me. I'm on Arch Linux with an Nvidia GPU.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug [core label] linux linux-wayland Linux Wayland panic / crash [core label] workspace Feedback for workspace management, layout, interactions, etc
Projects
None yet