TaKO8Ki / frum

A little bit fast and modern Ruby version manager written in Rust
MIT License
636 stars 15 forks source link

Uninstall crashes if exact version is not used #131

Open jamesgecko opened 11 months ago

jamesgecko commented 11 months ago

I have Ruby 3.1.4 installed. frum uninstall 3.1.4 worked. frum uninstall 3.1 does the following:

><((o> env RUST_BACKTRACE=full frum uninstall 3.1
thread 'main' panicked at /home/james/.cargo/registry/src/index.crates.io-6f17d22bba15001f/frum-0.1.2/src/commands/uninstall.rs:47:18:
internal error: entered unreachable code
stack backtrace:
   0:     0xaaaae375966c - std::backtrace_rs::backtrace::libunwind::trace::heef1386c69141c0e
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5
   1:     0xaaaae375966c - std::backtrace_rs::backtrace::trace_unsynchronized::hf52898491dc115b3
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0xaaaae375966c - std::sys_common::backtrace::_print_fmt::h54a977219eb084db
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/sys_common/backtrace.rs:67:5
   3:     0xaaaae375966c - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h14034993f2dfde80
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/sys_common/backtrace.rs:44:22
   4:     0xaaaae3781878 - core::fmt::rt::Argument::fmt::hc7ab06fc179a0538
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/core/src/fmt/rt.rs:138:9
   5:     0xaaaae3781878 - core::fmt::write::h5c1b4d7dd1fe1297
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/core/src/fmt/mod.rs:1114:21
   6:     0xaaaae375594c - std::io::Write::write_fmt::h5288162c5e42a3a2
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/io/mod.rs:1763:15
   7:     0xaaaae37594a0 - std::sys_common::backtrace::_print::he08b7cac662e6bf2
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/sys_common/backtrace.rs:47:5
   8:     0xaaaae37594a0 - std::sys_common::backtrace::print::hfc02f4f778cfba10
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/sys_common/backtrace.rs:34:9
   9:     0xaaaae375aaa4 - std::panicking::default_hook::{{closure}}::ha5e3ccf8ff24afce
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:272:22
  10:     0xaaaae375a7b8 - std::panicking::default_hook::h8515e68938392e65
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:292:9
  11:     0xaaaae375b060 - std::panicking::rust_panic_with_hook::hc79d39f29b02a8f2
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:731:13
  12:     0xaaaae375aee4 - std::panicking::begin_panic_handler::{{closure}}::hc334b8544d985752
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:601:13
  13:     0xaaaae3759b50 - std::sys_common::backtrace::__rust_end_short_backtrace::h1479ad9e3d67013a
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/sys_common/backtrace.rs:170:18
  14:     0xaaaae375ac80 - rust_begin_unwind
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:597:5
  15:     0xaaaae3421c1c - core::panicking::panic_fmt::h35c6be226eceb7e0
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/core/src/panicking.rs:72:14
  16:     0xaaaae3421c90 - core::panicking::panic::h8a4c6e356ed191d2
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/core/src/panicking.rs:127:5
  17:     0xaaaae34370a4 - frum::command::Command::call::hf826e1aa882c20a6
  18:     0xaaaae34454c0 - frum::main::hda400292b5d03a92
  19:     0xaaaae3437b70 - std::sys_common::backtrace::__rust_begin_short_backtrace::h023afb581e16ab7c
  20:     0xaaaae3445bbc - std::rt::lang_start::{{closure}}::h1688cdf53901e3b3
  21:     0xaaaae374ea68 - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::hf61f7cbe35478064
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/core/src/ops/function.rs:284:13
  22:     0xaaaae374ea68 - std::panicking::try::do_call::he002a9d8b88eec92
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:504:40
  23:     0xaaaae374ea68 - std::panicking::try::h623ba8c426e94cd9
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:468:19
  24:     0xaaaae374ea68 - std::panic::catch_unwind::h145c7caddb5ceae3
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panic.rs:142:14
  25:     0xaaaae374ea68 - std::rt::lang_start_internal::{{closure}}::h98e3135c0b0dadc6
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/rt.rs:148:48
  26:     0xaaaae374ea68 - std::panicking::try::do_call::hf8fca3c9ffc6d981
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:504:40
  27:     0xaaaae374ea68 - std::panicking::try::h9de3ce8279c045a7
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panicking.rs:468:19
  28:     0xaaaae374ea68 - std::panic::catch_unwind::hc2636d38b3ad5f51
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/panic.rs:142:14
  29:     0xaaaae374ea68 - std::rt::lang_start_internal::he29c91d67ad39838
                               at /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/std/src/rt.rs:148:20
  30:     0xaaaae3445a48 - main
  31:     0xffffa27b7584 - <unknown>
  32:     0xffffa27b7658 - __libc_start_main
  33:     0xaaaae3422230 - _start
  34:                0x0 - <unknown>