Skip to content

Thread panic w/ reason "entry must not contain newlines" #294

Description

@Weldoret

I recently tried to run nix-index to build my package cache and ran into an issue. No matter how many times I clear the cache directory or restart my computer, every time I run it I eventually get the same error:

thread 'main' (10081) panicked at src/frcode.rs:478:9:
entry must not contain newlines
stack backtrace:
   0:     0x55cfdabbe77c - <std::sys::backtrace::BacktraceLock::print::DisplayBacktrace as core::fmt::Display>::fmt::h97fb6610f56dfc08
   1:     0x55cfdabf501f - core::fmt::write::h9136135b32f30016
   2:     0x55cfdabd681d - std::io::Write::write_fmt::h88f642fc161ea70b
   3:     0x55cfdabbc783 - std::sys::backtrace::BacktraceLock::print::hdc1d1cbac2d2f5bf
   4:     0x55cfdabd2d39 - std::panicking::default_hook::{{closure}}::h324e042fbf76f6d6
   5:     0x55cfdabd2c19 - std::panicking::default_hook::h5897f072e00526e4
   6:     0x55cfdabd2fa1 - std::panicking::panic_with_hook::hf5deea2fc5d79056
   7:     0x55cfdabbd2f6 - std::panicking::panic_handler::{{closure}}::h3678cfe4e749a213
   8:     0x55cfdabbc899 - std::sys::backtrace::__rust_end_short_backtrace::hf98377857d9e9cf7
   9:     0x55cfdabcf29d - __rustc[bd3b3f48d2381c32]::rust_begin_unwind
  10:     0x55cfda7fce50 - core::panicking::panic_fmt::hf6e3d461535f5ca9
  11:     0x55cfda83c3e1 - nix_index::frcode::Encoder<W>::write_meta::h957d6136ef4eb2f5
  12:     0x55cfda84a049 - nix_index::files::FileTreeEntry::encode::h7c0f057755f31303
  13:     0x55cfda82cf80 - nix_index::database::Writer::add::hf26b54ae6652f182
  14:     0x55cfda816c76 - tokio::runtime::park::CachedParkThread::block_on::h4a513481f7b52f25
  15:     0x55cfda81ed84 - tokio::runtime::context::runtime::enter_runtime::h8c6fe0093f4be8a0
  16:     0x55cfda7ff4c4 - tokio::runtime::runtime::Runtime::block_on::he3dcc02d41cc103d
  17:     0x55cfda82bb83 - nix_index::main::hb148f56c0ef1950d
  18:     0x55cfda826036 - std::sys::backtrace::__rust_begin_short_backtrace::h24ec6066dec2c196
  19:     0x55cfda81970c - std::rt::lang_start::{{closure}}::h2e0cdcd1d7733fc0
  20:     0x55cfdabd0795 - std::rt::lang_start_internal::h1536f6da427acac8
  21:     0x55cfda82bc74 - main
  22:     0x7fe1e882a4c5 - __libc_start_call_main
  23:     0x7fe1e882a578 - __libc_start_main_alias_1
  24:     0x55cfda7fcf95 - _start
  25:                0x0 - <unknown>

This is always during the "generating index" stage, and seems to happen around the 6500 paths in queue mark. I am unsure if this actually affects usability but figured it was worth reporting.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions