Skip to content

thread panic on WSL #45

@bartlibert

Description

@bartlibert

On my windows system, I use pack in WSL to manage my vim there. However, I get thread panics from time to time (see below).

It seems to be related to the thread sleep in the Spinner class. here

This function calls nanosleep here. On WSL, this function returns EINVAL sometimes on WSL, causing an unhandled assert, which in turn results in the panic (at least I think so, I'm a C/C++ programmer, not a Rust programmer, so I'm making some assumptions).

I don't know if there's a sensible way to handle this assert on your side? Or maybe provide a "no spinner" option or something?

' panicked at 'assertion failed: `(left == right)`
  left: `22`, ⠋
 right: `4`', thread 'src/libstd/sys/unix/thread.rs<unnamed>:' panicked at '172assertion failed: `(left == right)`
  left: `22`,
 right: `4`:', 21src/libstd/sys/unix/thread.rs
:172:21
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
   ⠋ [jsfaint/coc-neoinclude] syncing
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
  left: `22`,
 right: `4`', src/libstd/sys/unix/thread.rs:172:21
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
   ⠋ [juneedahamed/vc.vim] syncing
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
  left: `22`,
 right: `4`', src/libstd/sys/unix/thread.rs:172:21
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
   ⠋ [junegunn/fzf.vim] syncing
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
  left: `22`,
 right: `4`', src/libstd/sys/unix/thread.rs:172:21
^Cthread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:1188:5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions