Rustdoc ICE in CI build


For some reason we got an ICE when merging a trivial README change into master on mdbook.

Looking at the logs, it seems like travis closed stdout causing a println!() in rustdoc to panic. Before I make a bug report, has anyone seen this before?

error: internal compiler error: unexpected panic

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

note: we would appreciate a bug report:

note: rustc 1.23.0 (766bd11c8 2018-01-01) running on x86_64-unknown-linux-gnu

thread 'rustc' panicked at 'failed printing to stdout: Resource temporarily unavailable (os error 11)', /checkout/src/libstd/io/
note: Run with `RUST_BACKTRACE=1` for a backtrace.

WARNING: rendering difference in `Provides multiple conditional default values in th ... exact same manner as`
error: Could not document `clap`.

Caused by:
  process didn't exit successfully: `rustdoc --crate-name clap /home/travis/.cargo/registry/src/ -o /home/travis/build/rust-lang-nursery/mdBook/target/doc --cfg feature="ansi_term" --cfg feature="atty" --cfg feature="color" --cfg feature="default" --cfg feature="strsim" --cfg feature="suggestions" --cfg feature="vec_map" -L dependency=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps --extern atty=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libatty-c451b2ece5b799d4.rlib --extern vec_map=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libvec_map-a6e38ae82d25e4cd.rlib --extern strsim=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libstrsim-5b26b7d204f15494.rlib --extern ansi_term=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libansi_term-012690530882c051.rlib --extern textwrap=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libtextwrap-94d7c2b82652f6c9.rlib --extern bitflags=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libbitflags-d9077c45affafc32.rlib --extern unicode_width=/home/travis/build/rust-lang-nursery/mdBook/target/debug/deps/libunicode_width-915ad14b945324b2.rlib` (exit code: 101)
warning: build failed, waiting for other jobs to finish...
error: build failed


Doing a bit more digging, OS error 11 is EAGAIN. An error you typically get when some syscall operation was interrupted and you should try it again.

The usual way to deal with in C is to have a do-while loop which will repeat the write as long as you keep getting EAGAIN… Is there any reason why we don’t do this automatically within println!()?



This may be related to



Write::write_all does loop on ErrorKind::Interrupted and and print!/println! look like they should use that. Not verified dynamically.


closed #5

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.