exa icon indicating copy to clipboard operation
exa copied to clipboard

Panic when using 'exa --git' on a git directory with modified and staged submodule.

Open jpsalm opened this issue 6 years ago • 5 comments

Here's the backtrace:

thread '' panicked at 'called Result::unwrap() on an Err value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', /home/jordan/.cargo/registry/src/github.com-1ecc6299db9ec823/exa-0.9.0/src/fs/feature/git.rs:271:22 stack backtrace: 0: backtrace::backtrace::libunwind::trace at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.46/src/backtrace/libunwind.rs:86 1: backtrace::backtrace::trace_unsynchronized at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.46/src/backtrace/mod.rs:66 2: std::sys_common::backtrace::_print_fmt at src/libstd/sys_common/backtrace.rs:78 3: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt at src/libstd/sys_common/backtrace.rs:59 4: core::fmt::write at src/libcore/fmt/mod.rs:1076 5: std::io::Write::write_fmt at src/libstd/io/mod.rs:1537 6: std::sys_common::backtrace::_print at src/libstd/sys_common/backtrace.rs:62 7: std::sys_common::backtrace::print at src/libstd/sys_common/backtrace.rs:49 8: std::panicking::default_hook::{{closure}} at src/libstd/panicking.rs:198 9: std::panicking::default_hook at src/libstd/panicking.rs:217 10: std::panicking::rust_panic_with_hook at src/libstd/panicking.rs:526 11: rust_begin_unwind at src/libstd/panicking.rs:437 12: core::panicking::panic_fmt at src/libcore/panicking.rs:85 13: core::option::expect_none_failed at src/libcore/option.rs:1269 14: exa::fs::feature::git::reorient 15: exa::fs::feature::git::Git::status 16: exa::output::table::Table::display 17: exa::output::table::Table::row_for_file 18: ::call_box note: Some details are omitted, run with RUST_BACKTRACE=full for a verbose backtrace. [1] 17210 abort (core dumped) exa --long --git --classify --group-directories-first

jpsalm avatar Oct 05 '20 17:10 jpsalm

The issue doesn't seem related to the submodule -- a reset and clean resolved for me but I have seen this before as well. There seems to exist some state of a git repo which exa does not like.

jpsalm avatar Oct 05 '20 18:10 jpsalm

Line numbers for me differ, but there's a known (and fixed but not released as far as I can see) issue with broken symlinks in git when using -l --git, maybe it's that?

ghost avatar Oct 06 '20 19:10 ghost

I get this panic when i have a dangling symlink in the directory.

smsegal avatar Oct 07 '20 17:10 smsegal

I'm running into the same problem with a git project using submodules:

Screen Shot 2020-11-30 at 10 24 22 AM
RUST_BACKTRACE=full exa --long --git --all --header
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(6795364578.871345152s)', src/libcore/result.rs:1084:5
stack backtrace:
   0:        0x103ce5ced - std::panicking::default_hook::{{closure}}::hffc69ca72fa98b80
   1:        0x103ce57bc - std::panicking::rust_panic_with_hook::h058ef423beec40ce
   2:        0x103ce5f7d - std::panicking::continue_panic_fmt::h0bb2cdb45a553955
   3:        0x103ce6249 - rust_begin_unwind
   4:        0x103d77dfa - core::panicking::panic_fmt::h2413d97d26203710
   5:        0x103d78399 - core::result::unwrap_failed::hef33208e3f23e07a
   6:        0x103cab6bd - exa::output::table::Table::display::h7d61868c2e1aa281
   7:        0x103cbe955 - <F as scoped_threadpool::FnBox>::call_box::hfeff2cdcb76e7a57
   8:        0x103cd6d6e - std::sys_common::backtrace::__rust_begin_short_backtrace::hf388fc36537a8fe9
   9:        0x103cd789e - core::ops::function::FnOnce::call_once{{vtable.shim}}::hd49318dcebc5ef76
  10:        0x103cf013d - <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once::hf778f932793a5a82
  11:        0x103cf0767 - std::sys::unix::thread::Thread::new::thread_start::ha4ccb7099fa6037f
  12:     0x7fff2033e950 - _pthread_start
[1]    2991 abort      RUST_BACKTRACE=full exa --long --git --all --header

jahio avatar Nov 30 '20 17:11 jahio

@jpsalm This issue is the same as #526, and that it has been fixed in #584.

@jahio This has been fixed in #670.

ariasuni avatar Dec 31 '20 16:12 ariasuni