Skip to content

Unexpected compiler error when comiling kube-rs docs on nightly #108501

Closed
@jmintb

Description

@jmintb

I do not have a minimal example :(

When compiling the docs for kube-rs, I get the error outlined below. The command used is:

RUSTDOCFLAGS="--cfg docsrs" cargo +nightly doc --lib --workspace --features=derive,ws,oauth,jsonpatch,client,derive,runtime,admission,k8s-openapi/v1_26 --open

I believe I am hitting the same issue as mentioned here: kube-rs/kube#1150

Edit: included the stack tract with RUST_BACKTRACE=full

Code

no code :(

Meta

rustc --version --verbose:

rustc 1.69.0-nightly (34e6673a0 2023-02-25)
binary: rustc
commit-hash: 34e6673a0473e90ef01a18eb575392c9e3859747
commit-date: 2023-02-25
host: x86_64-unknown-linux-gnu
release: 1.69.0-nightly
LLVM version: 15.0.7

Error output

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

note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md

note: rustc 1.69.0-nightly (34e6673a0 2023-02-25) running on x86_64-unknown-linux-gnu

note: compiler flags: --crate-type lib

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
end of query stack
error: could not document `kube`

Caused by:
  process didn't exit successfully: `rustdoc --edition=2021 --crate-type lib --crate-name kube kube/src/lib.rs -o /home/jmintb/Sync/lab/kube-rs/target/doc --cfg 'feature="admission"' --cfg 'feature="client"' --cfg 'feature="config"' --cfg 'feature="default"' --cfg 'feature="derive"' --cfg 'feature="gzip"' --cfg 'feature="jsonpatch"' --cfg 'feature="kube-client"' --cfg 'feature="kube-derive"' --cfg 'feature="kube-runtime"' --cfg 'feature="oauth"' --cfg 'feature="openssl-tls"' --cfg 'feature="runtime"' --cfg 'feature="ws"' --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=213 -C metadata=11109ba456e761de -L dependency=/home/jmintb/Sync/lab/kube-rs/target/debug/deps --extern k8s_openapi=/home/jmintb/Sync/lab/kube-rs/target/debug/deps/libk8s_openapi-210f27282fabe8a6.rmeta --extern kube_client=/home/jmintb/Sync/lab/kube-rs/target/debug/deps/libkube_client-660b0ca36bfd5041.rmeta --extern kube_core=/home/jmintb/Sync/lab/kube-rs/target/debug/deps/libkube_core-e8fc2ef218cbbbb5.rmeta --extern kube_derive=/home/jmintb/Sync/lab/kube-rs/target/debug/deps/libkube_derive-b6f0793aecc89674.so --extern kube_runtime=/home/jmintb/Sync/lab/kube-rs/target/debug/deps/libkube_runtime-5247cd07dcbef488.rmeta --cfg docsrs --crate-version 0.79.0` (exit status: 101)
Backtrace

RUSTDOCFLAGS="--cfg docsrs" cargo +nightly doc --lib --workspace --features=derive,ws,oauth,jsonpatch,client,derive,runtime,admission,k8s-openapi/v1_26 --open
 Documenting kube v0.79.0 (/home/jmintb/Sync/lab/kube-rs/kube)
thread 'rustc' panicked at 'no resolution for "kube_runtime" MacroNS DefId(21:0 ~ kube_runtime[d02f])', src/librustdoc/passes/collect_intra_doc_links.rs:391:32
stack backtrace:
   0:     0x7fd19622da8a - std::backtrace_rs::backtrace::libunwind::trace::hf2766cee31f78014
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5
   1:     0x7fd19622da8a - std::backtrace_rs::backtrace::trace_unsynchronized::hf36691cebf29277a
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0x7fd19622da8a - std::sys_common::backtrace::_print_fmt::hffbf40bd0669bae4
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/sys_common/backtrace.rs:65:5
   3:     0x7fd19622da8a - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h7ad105c28858c097
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/sys_common/backtrace.rs:44:22                                                                                                                                                             
   4:     0x7fd19628da0e - core::fmt::write::h919381681baa7a0b                                                                                                                                                                                                                                                             at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/core/src/fmt/mod.rs:1232:17                                                                                                                                                                          5:     0x7fd19621de35 - std::io::Write::write_fmt::h712066bff563416b                                                                                                                                                                                                                                                    at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/io/mod.rs:1684:15                                                                                                                                                                         
   6:     0x7fd19622d855 - std::sys_common::backtrace::_print::h89608a795bfdc42d
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/sys_common/backtrace.rs:47:5
   7:     0x7fd19622d855 - std::sys_common::backtrace::print::ha3cef17b650a8d12
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/sys_common/backtrace.rs:34:9
   8:     0x7fd1962305cf - std::panicking::default_hook::{{closure}}::ha4d98de271a804e6                                                                                                                                                                                                     
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/panicking.rs:271:22
   9:     0x7fd19623030b - std::panicking::default_hook::h7f0e090a32d9c25f
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/panicking.rs:290:9
  10:     0x7fd199570af5 - <rustc_driver_impl[921a34b63f8d495]::DEFAULT_HOOK::{closure#0}::{closure#0} as core[df15197076ea29e4]::ops::function::FnOnce<(&core[df15197076ea29e4]::panic::panic_info::PanicInfo,)>>::call_once::{shim:vtable#0}
  11:     0x7fd196230e0d - <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call::h97d3c1efb26c5d4c
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/alloc/src/boxed.rs:2002:9
  12:     0x7fd196230e0d - std::panicking::rust_panic_with_hook::h5d8516e1de49fefa
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/panicking.rs:696:13
  13:     0x7fd196230b89 - std::panicking::begin_panic_handler::{{closure}}::hdee363c132339f2f
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/panicking.rs:583:13
  14:     0x7fd19622def6 - std::sys_common::backtrace::__rust_end_short_backtrace::h01c64d2e075fc45c
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/sys_common/backtrace.rs:137:18
  15:     0x7fd196230892 - rust_begin_unwind
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/panicking.rs:579:5
  16:     0x7fd19628a3b3 - core::panicking::panic_fmt::hb65d4ce4e2307d2d
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/core/src/panicking.rs:64:14
  17:     0x562aefd9ae04 - <rustdoc[d3129993ceb2fb41]::passes::collect_intra_doc_links::LinkCollector>::resolve_path
  18:     0x562aefd9af2e - <rustdoc[d3129993ceb2fb41]::passes::collect_intra_doc_links::LinkCollector>::resolve
  19:     0x562aefd9eb32 - <rustdoc[d3129993ceb2fb41]::passes::collect_intra_doc_links::LinkCollector as rustdoc[d3129993ceb2fb41]::visit::DocVisitor>::visit_item
  20:     0x562aefda802a - <rustdoc[d3129993ceb2fb41]::passes::collect_intra_doc_links::LinkCollector as rustdoc[d3129993ceb2fb41]::visit::DocVisitor>::visit_inner_recur
  21:     0x562aefda23ba - <rustdoc[d3129993ceb2fb41]::passes::collect_intra_doc_links::LinkCollector as rustdoc[d3129993ceb2fb41]::visit::DocVisitor>::visit_item
  22:     0x562aefd99882 - rustdoc[d3129993ceb2fb41]::passes::collect_intra_doc_links::collect_intra_doc_links
  23:     0x562aefce170e - <rustc_session[feb265819893f90]::session::Session>::time::<rustdoc[d3129993ceb2fb41]::clean::types::Crate, rustdoc[d3129993ceb2fb41]::core::run_global_ctxt::{closure#7}>
  24:     0x562aefe0db50 - rustdoc[d3129993ceb2fb41]::core::run_global_ctxt
  25:     0x562aefce1999 - <rustc_session[feb265819893f90]::session::Session>::time::<(rustdoc[d3129993ceb2fb41]::clean::types::Crate, rustdoc[d3129993ceb2fb41]::config::RenderOptions, rustdoc[d3129993ceb2fb41]::formats::cache::Cache), rustdoc[d3129993ceb2fb41]::main_args::{closure#1
}::{closure#0}::{closure#0}::{closure#0}>
  26:     0x562aefbe0947 - <rustc_middle[a3c172b61b1a9dcc]::ty::context::GlobalCtxt>::enter::<rustdoc[d3129993ceb2fb41]::main_args::{closure#1}::{closure#0}::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>>
  27:     0x562aefc4c720 - <rustc_interface[13c4583830495995]::interface::Compiler>::enter::<rustdoc[d3129993ceb2fb41]::main_args::{closure#1}::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>>
  28:     0x562aefce0cab - rustc_span[d2a99e845eee75b5]::with_source_map::<core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>, rustc_interface[13c4583830495995]::interface::run_compiler<core[df15197076ea29e4]::result::Result<(), rustc_errors[2
3d500b1f4d61315]::ErrorGuaranteed>, rustdoc[d3129993ceb2fb41]::main_args::{closure#1}>::{closure#0}::{closure#0}>
  29:     0x562aefbbdd34 - <scoped_tls[7ec87721c8cb8d70]::ScopedKey<rustc_span[d2a99e845eee75b5]::SessionGlobals>>::set::<rustc_interface[13c4583830495995]::interface::run_compiler<core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>, rustdoc[d3
129993ceb2fb41]::main_args::{closure#1}>::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>>
  30:     0x562aefcf9660 - std[e4fd71d079036e01]::sys_common::backtrace::__rust_begin_short_backtrace::<rustc_interface[13c4583830495995]::util::run_in_thread_pool_with_globals<rustc_interface[13c4583830495995]::interface::run_compiler<core[df15197076ea29e4]::result::Result<(), rustc
_errors[23d500b1f4d61315]::ErrorGuaranteed>, rustdoc[d3129993ceb2fb41]::main_args::{closure#1}>::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_error
s[23d500b1f4d61315]::ErrorGuaranteed>>
  31:     0x562aefdc3d4d - <<std[e4fd71d079036e01]::thread::Builder>::spawn_unchecked_<rustc_interface[13c4583830495995]::util::run_in_thread_pool_with_globals<rustc_interface[13c4583830495995]::interface::run_compiler<core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f
4d61315]::ErrorGuaranteed>, rustdoc[d3129993ceb2fb41]::main_args::{closure#1}>::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d61315]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[df15197076ea29e4]::result::Result<(), rustc_errors[23d500b1f4d6131
5]::ErrorGuaranteed>>::{closure#1} as core[df15197076ea29e4]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
  32:     0x7fd19623ac93 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h4d3cc1fadafd8bb6
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/alloc/src/boxed.rs:1988:9
  33:     0x7fd19623ac93 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h217aba05dd254767
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/alloc/src/boxed.rs:1988:9
  34:     0x7fd19623ac93 - std::sys::unix::thread::Thread::new::thread_start::h70cdd9aaa3576906
                               at /rustc/34e6673a0473e90ef01a18eb575392c9e3859747/library/std/src/sys/unix/thread.rs:108:17
  35:     0x7fd195f88ff2 - start_thread
  36:     0x7fd19600bbfc - clone3
  37:                0x0 - <unknown>

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

note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md

note: rustc 1.69.0-nightly (34e6673a0 2023-02-25) running on x86_64-unknown-linux-gnu

note: compiler flags: --crate-type lib

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
end of query stack

Metadata

Metadata

Assignees

Labels

C-bugCategory: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions