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

Thread "<unnamed>" panicked with "called Result::unwrap() on an Err value: map entry zed:extension/github defined twice" #25364

Closed
Angelk90 opened this issue Feb 21, 2025 · 3 comments
Labels
crash [core label]

Comments

@Angelk90
Copy link
Contributor

Summary

Steps to trigger the problem:

  1. Cargo Run
  2. Zed Crash

Or

  1. cargo run
  2. Open file
  3. Try to edit a file
  4. Zed Crash

All this happens when I try to build the latest version of zed.

Error:

2025-02-21 22:29:13.242 zed[39739:857618] +[IMKClient subclass]: chose IMKClient_Modern
2025-02-21 22:29:13.242 zed[39739:857618] +[IMKInputSession subclass]: chose IMKInputSession_Modern
Thread "<unnamed>" panicked with "called `Result::unwrap()` on an `Err` value: map entry `zed:extension/github` defined twice" at crates/extension_host/src/wasm_host/wit.rs:38:31
https://github.com/zed-industries/zed/blob/10a6cd00e7d5bff07605598500123d987e0ea67e/src/crates/extension_host/src/wasm_host/wit.rs#L38 (may not be uploaded, line may be incorrect if files modified)
   0: backtrace::backtrace::libunwind::trace
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/backtrace-0.3.74/src/backtrace/libunwind.rs:116:5
      backtrace::backtrace::trace_unsynchronized
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/backtrace-0.3.74/src/backtrace/mod.rs:66:5
   1: backtrace::backtrace::trace
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/backtrace-0.3.74/src/backtrace/mod.rs:53:14
   2: backtrace::capture::Backtrace::create
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/backtrace-0.3.74/src/capture.rs:292:9
   3: backtrace::capture::Backtrace::new
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/backtrace-0.3.74/src/capture.rs:257:22
   4: zed::reliability::init_panic_hook::{{closure}}
             at /Users/NAMEUSER/Desktop/zed/crates/zed/src/reliability.rs:56:29
   5: <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/alloc/src/boxed.rs:2084:9
      std::panicking::rust_panic_with_hook
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/panicking.rs:808:13
   6: std::panicking::begin_panic_handler::{{closure}}
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/panicking.rs:674:13
   7: std::sys::backtrace::__rust_end_short_backtrace
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sys/backtrace.rs:168:18
   8: rust_begin_unwind
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/panicking.rs:665:5
   9: core::panicking::panic_fmt
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/core/src/panicking.rs:74:14
  10: core::result::unwrap_failed
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/core/src/result.rs:1679:5
  11: core::result::Result<T,E>::unwrap
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/core/src/result.rs:1102:23
      extension_host::wasm_host::wit::new_linker
             at /Users/NAMEUSER/Desktop/zed/crates/extension_host/src/wasm_host/wit.rs:38:5
  12: extension_host::wasm_host::wit::since_v0_2_0::linker::{{closure}}
             at /Users/NAMEUSER/Desktop/zed/crates/extension_host/src/wasm_host/wit/since_v0_2_0.rs:43:9
  13: std::sync::once_lock::OnceLock<T>::get_or_init::{{closure}}
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once_lock.rs:276:50
  14: std::sync::once_lock::OnceLock<T>::initialize::{{closure}}
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once_lock.rs:483:19
  15: std::sync::once::Once::call_once_force::{{closure}}
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once.rs:217:40
  16: std::sys::sync::once::queue::Once::call
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sys/sync/once/queue.rs:183:21
  17: std::sync::once::Once::call_once_force
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once.rs:217:9
  18: std::sync::once_lock::OnceLock<T>::initialize
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once_lock.rs:482:9
  19: std::sync::once_lock::OnceLock<T>::get_or_try_init
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once_lock.rs:364:9
  20: std::sync::once_lock::OnceLock<T>::get_or_init
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/std/src/sync/once_lock.rs:276:15
  21: extension_host::wasm_host::wit::since_v0_2_0::linker
             at /Users/NAMEUSER/Desktop/zed/crates/extension_host/src/wasm_host/wit/since_v0_2_0.rs:42:5
  22: extension_host::wasm_host::wit::Extension::instantiate_async::{{closure}}
             at /Users/NAMEUSER/Desktop/zed/crates/extension_host/src/wasm_host/wit.rs:122:17
  23: extension_host::wasm_host::WasmHost::load_extension::{{closure}}
             at /Users/NAMEUSER/Desktop/zed/crates/extension_host/src/wasm_host.rs:385:14
  24: <core::pin::Pin<P> as core::future::future::Future>::poll
             at /rustc/eeb90cda1969383f56a2637cbd3037bdf598841c/library/core/src/future/future.rs:123:9
  25: async_task::raw::RawTask<F,T,S,M>::run
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.1/src/raw.rs:557:17
  26: async_task::runnable::Runnable<M>::run
             at /Users/NAMEUSER/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-task-4.7.1/src/runnable.rs:781:18
  27: gpui::platform::mac::dispatcher::trampoline
             at /Users/NAMEUSER/Desktop/zed/crates/gpui/src/platform/mac/dispatcher.rs:106:5
  28: <unknown>
  29: <unknown>
  30: <unknown>
  31: __pthread_wqthread

Zed Version and System Specs

Zed: v0.175.3 (Zed Preview) 
OS: macOS 15.3.0
Memory: 16 GiB
Architecture: x86_64

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

Zed.log

@devzeth devzeth added the crash [core label] label Feb 21, 2025
@devzeth
Copy link
Member

devzeth commented Feb 21, 2025

Fixed with pr #25361

@devzeth devzeth closed this as not planned Won't fix, can't repro, duplicate, stale Feb 21, 2025
@Angelk90
Copy link
Contributor Author

Angelk90 commented Feb 21, 2025

@beniaminzagan : I am with the current latest commit, but zed still crashes.

What is currently printed in shell:

2025-02-21 23:16:16.607 zed[55739:945921] +[IMKClient subclass]: chose IMKClient_Modern
2025-02-21 23:16:16.607 zed[55739:945921] +[IMKInputSession subclass]: chose IMKInputSession_Modern
[2025-02-21T23:18:57+01:00 ERROR zed] didn't receive login redirect
[1]    55739 segmentation fault  cargo run

Safari browser opens to Sign in to GitHub to continue to Zed Industries page every time i do cargo run and then zed crashes.

@devzeth
Copy link
Member

devzeth commented Feb 21, 2025

@beniaminzagan : I am with the current latest commit, but zed still crashes.

What is currently printed in shell:

2025-02-21 23:13:43.548 zed[54381:940756] +[IMKClient subclass]: chose IMKClient_Modern
2025-02-21 23:13:43.548 zed[54381:940756] +[IMKInputSession subclass]: chose IMKInputSession_Modern
[1]    54381 segmentation fault  cargo run

Safari browser opens to Sign in to GitHub to continue to Zed Industries page every time i do cargo run and then zed crashes.

But thats not the crash you first mentioned in the isuse. Please make a new issue pointing this out. I know maxdeviant did some changes there recently, he will be the one probably to assist you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
crash [core label]
Projects
None yet
Development

No branches or pull requests

2 participants