Panicked at called Result::unwrap()
I am using the exa version v0.9.0 on a MacOS Catalina 10.15.7
Into a GIT project I am running into the following error, launching the command:
ls
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/libcore/result.rs:1084:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
- Removing .git folder, the issue disappears
- Launching
exa -la, the issue disappears
Thank you
Having the same issue here, but the folder itself is not a git repo, just the parent dir to a bunch of git repos with nothing else (no symlink, etc.)
System: macOS 10.15.6 (19G2021)
Here are the full backtrace:
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(6795364578.871345152s)', src/libcore/result.rs:1084:5
stack backtrace:
0: 0x10a8b6ced - std::panicking::default_hook::{{closure}}::hffc69ca72fa98b80
1: 0x10a8b67bc - std::panicking::rust_panic_with_hook::h058ef423beec40ce
2: 0x10a8b6f7d - std::panicking::continue_panic_fmt::h0bb2cdb45a553955
3: 0x10a8b7249 - rust_begin_unwind
4: 0x10a948dfa - core::panicking::panic_fmt::h2413d97d26203710
5: 0x10a949399 - core::result::unwrap_failed::hef33208e3f23e07a
6: 0x10a87c6bd - exa::output::table::Table::display::h7d61868c2e1aa281
7: 0x10a88f955 - <F as scoped_threadpool::FnBox>::call_box::hfeff2cdcb76e7a57
8: 0x10a8a7d6e - std::sys_common::backtrace::__rust_begin_short_backtrace::hf388fc36537a8fe9
9: 0x10a8a889e - core::ops::function::FnOnce::call_once{{vtable.shim}}::hd49318dcebc5ef76
10: 0x10a8c113d - <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once::hf778f932793a5a82
11: 0x10a8c1767 - std::sys::unix::thread::Thread::new::thread_start::ha4ccb7099fa6037f
12: 0x7fff6dfcd109 - _pthread_start
[1] 26927 abort exa --all --icons --header --long
@loikein try to verify if you have a symlink in your folder. I solve removing that file (because it was unused).
@davideprevosto No, because if you read my reply more closely, I have already checked that. There are only folders and a zip file under the mentioned directory. Maybe I should open another issue…
I have the same error. Its working earlier then suddenly like this.
Similar here (ubuntu 20.10 with exa from official repo), removing the .git folder doesn't help nor running exa -la.
It's the -l option to cause this (-a and -h or without options, it works)
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(2147483648s)', src/fs/file.rs:331:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[1] 7916 abort (core dumped) exa -lh
same here. exa v0.9.0. mac os 10.15.7
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/libcore/result.rs:1084:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
zsh: abort exa -ahl --git
I have a similar issue where exa -l / panics with the following message:
❯ exa -l /
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(1649944470s)', /home/{user}/.cargo/registry/src/github.com-1ecc6299db9ec823/exa-0.9.0/src/fs/file.rs:331:70
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Aborted (core dumped)
OS: Linux (Ubuntu 20.04)
This is the line of code in question:
/// This file’s last modified timestamp.
pub fn modified_time(&self) -> Duration {
self.metadata.modified().unwrap().duration_since(UNIX_EPOCH).unwrap()
}
Same here, in a subfolder of a git repository containing symlinks. exa -l works, exa -l --git crashes:
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/fs/feature/git.rs:271:22
stack backtrace:
0: 0x10375ebbf - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h0afb3dc3ec8cd05f
1: 0x1036e526e - core::fmt::write::h39441ef24fae20ea
2: 0x10375e90b - std::io::Write::write_fmt::h2ffecc964e3c3ddd
3: 0x10377526c - std::panicking::default_hook::{{closure}}::h1a491655bcf6394f
4: 0x103775a75 - std::panicking::rust_panic_with_hook::h489020cfd35413ea
5: 0x10375efcb - std::panicking::begin_panic_handler::{{closure}}::he498abc45ca35fbf
6: 0x10375ef97 - std::sys_common::backtrace::__rust_end_short_backtrace::h4a2a0fae6b0989d8
7: 0x1037733e0 - _rust_begin_unwind
8: 0x1037dd97f - core::panicking::panic_fmt::h0003130af3c08aa0
9: 0x1037dda45 - core::result::unwrap_failed::hbfeca77107a6ab03
10: 0x10370fd27 - exa::fs::feature::git::reorient::h9176b700a1752132
11: 0x10370f840 - exa::fs::feature::git::Git::status::h64d4895027d8c490
12: 0x1036f47d9 - exa::output::table::Table::display::h48880f40188c858c
13: 0x1036f88db - exa::output::table::Table::row_for_file::h48ab4796ac2fab91
14: 0x10370518b - <F as scoped_threadpool::FnBox>::call_box::hf5abb6a9b5199787
15: 0x1037506a3 - std::sys_common::backtrace::__rust_begin_short_backtrace::h7c4af1d8ccff7ba6
16: 0x103750ec1 - core::ops::function::FnOnce::call_once{{vtable.shim}}::h2fcbe3686f5acc79
17: 0x103778459 - std::sys::unix::thread::Thread::new::thread_start::hd5599cd92bd5bc81
18: 0x7fff6eae3109 - __pthread_start
[1] 51298 abort exa -l --git
macOS 10.15.7, exa 0.9.0
macOS 11.1, exa 0.9.0
$ RUST_BACKTRACE=full exa -l
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(6795364578.871345152s)', src/fs/file.rs:331:70
stack backtrace:
0: 0x109dd7bbf - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h0afb3dc3ec8cd05f
1: 0x109d5e26e - core::fmt::write::h39441ef24fae20ea
2: 0x109dd790b - std::io::Write::write_fmt::h2ffecc964e3c3ddd
3: 0x109dee26c - std::panicking::default_hook::{{closure}}::h1a491655bcf6394f
4: 0x109deea75 - std::panicking::rust_panic_with_hook::h489020cfd35413ea
5: 0x109dd7fcb - std::panicking::begin_panic_handler::{{closure}}::he498abc45ca35fbf
6: 0x109dd7f97 - std::sys_common::backtrace::__rust_end_short_backtrace::h4a2a0fae6b0989d8
7: 0x109dec3e0 - _rust_begin_unwind
8: 0x109e5697f - core::panicking::panic_fmt::h0003130af3c08aa0
9: 0x109e56a45 - core::result::unwrap_failed::hbfeca77107a6ab03
10: 0x109d6c8f9 - exa::output::table::Table::display::h48880f40188c858c
11: 0x109d718db - exa::output::table::Table::row_for_file::h48ab4796ac2fab91
12: 0x109d7e18b - <F as scoped_threadpool::FnBox>::call_box::hf5abb6a9b5199787
13: 0x109dc96a3 - std::sys_common::backtrace::__rust_begin_short_backtrace::h7c4af1d8ccff7ba6
14: 0x109dc9ec1 - core::ops::function::FnOnce::call_once{{vtable.shim}}::h2fcbe3686f5acc79
15: 0x109df1459 - std::sys::unix::thread::Thread::new::thread_start::hd5599cd92bd5bc81
16: 0x7fff20339950 - __pthread_start
[1] 3900 abort RUST_BACKTRACE=full exa -l
@davideprevosto
Into a GIT project I am running into the following error, launching the command:
ls
What’s ls? I suppose you’re using an alias.
@davideprevosto @Crux-One I’m not sure how to trace the issue.
- Please test if building exa from source fixes the problem
- Otherwise, please run
RUST_BACKTRACE=1 exa -alh --gitand tell me in which cases (directory, flags, etc.) it crashes or not
@loikein @tommyblue @ataias @gliderkite You experience a crash but the backtrace is different so that’s not the same issue. Here:
thread '<unnamed>' panicked at 'calledResult::unwrap()on anErrvalue: SystemTimeError(6795364578.871345152s)', src/libcore/result.rs:1084:5
makes me think it’s the same as #596 and #658, and that it’s been fixed in #670.
@seguri
thread '
' panicked at 'called Result::unwrap()on anErrvalue: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/fs/feature/git.rs:271:22
I believe this one is #526 and has been fixed in #584.
Nice summary @ariasuni. Although the relevant issues seem to be fixed, users (me included) are still encountering them because there hasn't been a release incorporating the fixes. Is there a good reason for that?
I can’t do releases, only ogham can. I’m actively working to clean issues and soon I’ll merge some PR and I hope it will make it easier for him to do the release, by reducing the hassle of going through the state of the repositories etc..
I see, good luck! @ogham any ETA on a new release?
I'm sorry, but is this the same issue?
❯ RUST_BACKTRACE=1 exa -alh --git
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(2147483648s)', src/fs/file.rs:331:70
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
[1] 2205647 abort (core dumped) RUST_BACKTRACE=1 exa -alh --git
I mean, a panic is as general as a segfault… However as said here the SystemTimeError is very probably the one that has been fixed a while ago.
I can verify that installed 'exa-git' from the Arch AUR instead of 'exa' fixes the problem. I'll wait patiently for a release ;-) Thanks. This is really cool software.
Having a similar error on macOS:
RUST_BACKTRACE=1 exa -lga
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: SystemTimeError(6795364578.871345152s)', src/fs/file.rs:331:70
stack backtrace:
0: _rust_begin_unwind
1: core::panicking::panic_fmt
2: core::result::unwrap_failed
3: exa::output::table::Table::display
4: exa::output::table::Table::row_for_file
5: <F as scoped_threadpool::FnBox>::call_box
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
[1] 13074 abort RUST_BACKTRACE=1 exa -lga
also happens with exa -l. The -l parameter seems to cause this in my case.
exa --version
exa v0.9.
macOS Big Sur Version 11.1 (20C69)
As I said above,
I mean, a panic is as general as a segfault… However as said here the SystemTimeError is very probably the one that has been fixed a while ago.
Similar issue with git here:
$ exa --version
exa v0.9.0
$ RUST_BACKTRACE=full exa --git -l
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/fs/feature/git.rs:268:5
stack backtrace:
0: 0x559e34ec09e8 - <unknown>
1: 0x559e34e45a3c - <unknown>
2: 0x559e34ec00c4 - <unknown>
3: 0x559e34ebfafa - <unknown>
4: 0x559e34ebf29a - <unknown>
5: 0x559e34ebee7a - <unknown>
6: 0x559e34e44110 - <unknown>
7: 0x559e34e46992 - <unknown>
8: 0x559e34e74b38 - <unknown>
9: 0x559e34e74622 - <unknown>
10: 0x559e34e5ad20 - <unknown>
11: 0x559e34e61ae7 - <unknown>
12: 0x559e34eba415 - <unknown>
13: 0x559e34eb932c - <unknown>
14: 0x559e34eca435 - <unknown>
15: 0x7f1d3d3da3e9 - start_thread
16: 0x7f1d3d2ee293 - __GI___clone
17: 0x0 - <unknown>
Aborted (core dumped)
@ariasuni I've built exa from 13b91cc but not found an error like https://github.com/ogham/exa/issues/760#issuecomment-730880526.