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

Random crash SIGABRT #7509

Closed
1 task done
shekohex opened this issue Feb 7, 2024 · 3 comments
Closed
1 task done

Random crash SIGABRT #7509

shekohex opened this issue Feb 7, 2024 · 3 comments
Labels
defect [core label] panic / crash [core label]

Comments

@shekohex
Copy link

shekohex commented Feb 7, 2024

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

After running zig on a big rust project on my mac M1 PRO, it crashed with SIGABRT SIGNAL

Environment

Zed: v0.120.6 (Zed)
OS: macOS 14.3.0
Memory: 16 GiB
Architecture: aarch64

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

Here is macOS crash report: https://gist.github.com/shekohex/24f5ed17c4deae49b6b9fa037fff1669

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

If you only need the most recent lines, you can run the zed: open log command palette action to see the last 1000.

Zed.log

@shekohex shekohex added admin read Pending admin review defect [core label] triage Maintainer needs to classify the issue labels Feb 7, 2024
@ConradIrwin ConradIrwin added panic / crash [core label] and removed triage Maintainer needs to classify the issue labels Feb 8, 2024
@ConradIrwin
Copy link
Collaborator

Thanks for reporting this! SIGABRT happens on panic, and it looks like this corresponds to the following panic we recorded internally.

thread 'main' panicked at 'assertion `left == right` failed: invalid insertion
  left: Lamport {0: 1}
 right: Lamport {0: 100}'
crates/text/src/text.rs:1883
<backtrace::capture::Backtrace>::create
<backtrace::capture::Backtrace>::new
Zed::init_panic_hook::{closure#0}
std::panicking::rust_panic_with_hook
std::panicking::begin_panic_handler::{{closure}}
std::sys_common::backtrace::__rust_end_short_backtrace
_rust_begin_unwind
core::panicking::panic_fmt
core::panicking::assert_failed_inner
core::panicking::assert_failed::<clock::Lamport, clock::Lamport>
<text::BufferSnapshot>::summary_for_anchor::<usize>
<editor::Editor>::rename::{closure#1}::{closure#0}
<async_task::raw::RawTask<<async_task::runnable::Builder<_>>::spawn_local::Checked<core::pin::Pin<alloc::boxed::Box<dyn core::future::future::Future<Output = core::result::Result<(), anyhow::Error>>>>>, core::result::Result<(), anyhow::Error>, <gpui::executor::ForegroundExecutor>::spawn::inner<core::result::Result<(), anyhow::Error>>::{closure#0}, ()>>::run
<gpui::platform::mac::platform::MacPlatform as gpui::platform::Platform>::run
Zed::main
std::sys_common::backtrace::__rust_begin_short_backtrace::<fn(), ()>
std::rt::lang_start::<()>::{closure#0}
std::rt::lang_start_internal
std::rt::lang_start::<()>
_main

We've been trying to track this one down for a while, but no luck yet. Do you happen to remember what you were doing at the time of the crash?

@shekohex
Copy link
Author

shekohex commented Feb 8, 2024

So I remember trying to rename a function (F2) and it freezed for a bit then crashed.

@JosephTLyons JosephTLyons removed the admin read Pending admin review label Feb 8, 2024
@ConradIrwin ConradIrwin mentioned this issue Feb 14, 2024
ConradIrwin added a commit that referenced this issue Feb 14, 2024
Release Notes:

- Fix a panic in rename
([#7509](#7509)).

---------

Co-authored-by: Max <max@zed.dev>
ConradIrwin added a commit that referenced this issue Feb 16, 2024
Release Notes:

- Fix a panic in rename
([#7509](#7509)).

---------

Co-authored-by: Max <max@zed.dev>
@JosephTLyons
Copy link
Contributor

This has landed in v0.123.2.

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

No branches or pull requests

3 participants