Skip to content

rustc panicked: Could not deserialize save-analysis config: MissingFieldError("reachable_only") #46244

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

Closed
sebastiencs opened this issue Nov 24, 2017 · 8 comments
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@sebastiencs
Copy link

This occurs with RLS

error: internal compiler error: unexpected panic

note: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.23.0-nightly (246a6d19c 2017-11-23) running on x86_64-unknown-linux-gnu

note: run with `RUST_BACKTRACE=1` for a backtrace

thread 'rustc' panicked at 'Could not deserialize save-analysis config: MissingFieldError("reachable_only")', /checkout/src/libcore/result.rs:906:4
stack backtrace:
   0:     0x7f789cb2fd83 - std::sys::imp::backtrace::tracing::imp::unwind_backtrace::h96dee9bcdbb02649
                               at /checkout/src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1:     0x7f789cb2b2ec - std::sys_common::backtrace::_print::h2ebe3072a1360391
                               at /checkout/src/libstd/sys_common/backtrace.rs:68
   2:     0x7f789cb3e600 - std::panicking::default_hook::{{closure}}::hc769485d77b08421
                               at /checkout/src/libstd/sys_common/backtrace.rs:57
                               at /checkout/src/libstd/panicking.rs:381
   3:     0x7f789cb3e29b - std::panicking::default_hook::ha3a808245b182eab
                               at /checkout/src/libstd/panicking.rs:391
   4:     0x7f789cb3ea4b - std::panicking::rust_panic_with_hook::h0ab3e76fb9f3f920
                               at /checkout/src/libstd/panicking.rs:577
   5:     0x7f789cb3e90e - std::panicking::begin_panic::hfd4b218612038963
                               at /checkout/src/libstd/panicking.rs:538
   6:     0x7f789cb3e809 - std::panicking::begin_panic_fmt::h4b5b345d659c1144
                               at /checkout/src/libstd/panicking.rs:522
   7:     0x7f789cb3e792 - rust_begin_unwind
                               at /checkout/src/libstd/panicking.rs:498
   8:     0x7f789cb95d20 - core::panicking::panic_fmt::hcc609fe6044e4f6f
                               at /checkout/src/libcore/panicking.rs:71
   9:     0x7f789e7b3bb8 - core::result::unwrap_failed::h1c95e1cefe4f5473
  10:     0x7f789e771179 - rustc_save_analysis::find_config::hfb934eebb7996803
  11:     0x7f789eaf9a1d - rustc_save_analysis::process_crate::hfd92bbb204794371
  12:     0x7f789eaf8668 - _ZN12rustc_driver20enable_save_analysis28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17hf570f44722918d24E.llvm.62612383
  13:     0x7f789ebbf074 - _ZN12rustc_driver20enable_save_analysis28_$u7b$$u7b$closure$u7d$$u7d$17hb4345dc25d6e4a1eE.llvm.83E87C1D
  14:     0x7f789eb6761b - _ZN12rustc_driver6driver13compile_input28_$u7b$$u7b$closure$u7d$$u7d$17hb39861299bc70debE.llvm.DF215A50
  15:     0x7f789eb5e594 - <std::thread::local::LocalKey<T>>::with::h72fa8637b1aa9606
  16:     0x7f789eb62406 - <std::thread::local::LocalKey<T>>::with::he9af6cc8b8d020bf
  17:     0x7f789ebad597 - rustc::ty::context::TyCtxt::create_and_enter::hf445d48b43784e8c
  18:     0x7f789eb1d40f - rustc_driver::driver::compile_input::h00bc277747ac69f4
  19:     0x7f789ebbb086 - rustc_driver::run_compiler::h9622b988ba74f568
  20:     0x55861bd817c6 - std::sys_common::backtrace::__rust_begin_short_backtrace::h7e4a11959b1239ed
  21:     0x7f789cb49f1e - __rust_maybe_catch_panic
                               at /checkout/src/libpanic_unwind/lib.rs:101
  22:     0x55861bd85452 - _ZN50_$LT$F$u20$as$u20$alloc..boxed..FnBox$LT$A$GT$$GT$8call_box17h9fc1bf66cdabdcb9E.llvm.8C6D50E
  23:     0x7f789cb3d47b - std::sys::imp::thread::Thread::new::thread_start::h45c4df38a5521a02
                               at /checkout/src/liballoc/boxed.rs:835
                               at /checkout/src/libstd/sys_common/thread.rs:24
                               at /checkout/src/libstd/sys/unix/thread.rs:90
  24:     0x7f789c4a036c - start_thread
  25:     0x7f789bca7e1e - __GI___clone
  26:                0x0 - <unknown>

@euclio
Copy link
Contributor

euclio commented Nov 24, 2017

Caused by #46011.

@euclio
Copy link
Contributor

euclio commented Nov 24, 2017

I unfortunately am without reliable internet for the weekend, so I am unable to work on a fix.

@euclio
Copy link
Contributor

euclio commented Nov 24, 2017

@nrc

@kjeremy
Copy link

kjeremy commented Nov 26, 2017

Seeing this on x86_64-pc-windows-msvc as well.

@AaronStGeorge
Copy link

Seeing this on 1.24.0-nightly (560a5da 2017-11-27) running on x86_64-unknown-linux-gnu

@TimNN TimNN added A-rls C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ labels Nov 28, 2017
@MageSlayer
Copy link

Following hack for RLS might bring some relief...

diff --git a/src/config.rs b/src/config.rs
index 7a988a5..cfbbd93 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -129,6 +129,8 @@ pub struct Config {
     pub features: Vec<String>,
     pub all_features: bool,
     pub no_default_features: bool,
+    pub pub_only: bool,
+    pub reachable_only: bool,
 }
 
 impl Default for Config {
@@ -153,6 +155,8 @@ impl Default for Config {
             features: vec![],
             all_features: false,
             no_default_features: false,
+            pub_only: false,
+            reachable_only: false
         };
         result.normalise();
         result

@euclio
Copy link
Contributor

euclio commented Dec 13, 2017

@MageSlayer I was under the impression this was already fixed in rust-lang/rls@194f828 and subsequently nightly-2017-12-01. Are you still able to reproduce?

@MageSlayer
Copy link

MageSlayer commented Dec 13, 2017

@euclio
Hm. I am trying to check on latest nightly, but it does not install rls for some reason.
I am doing:

$ rustup component add rls-preview --toolchain nightly
$ rustup component add rust-analysis --toolchain nightly
$ rustup component add rust-src --toolchain nightly
$ rustup update nightly

but

denis@denis-devuan:~$ ls ~/.cargo/bin/rls
ls: cannot access '/home/denis/.cargo/bin/rls': No such file or directory

RLS moved into another location or not built in latest nightly?

EDIT:
Yes, looks like installing via cargo does the trick.
I guess the issue can be closed.

@nrc nrc closed this as completed Dec 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
Projects
None yet
Development

No branches or pull requests

7 participants