The sound distributed version control system

#811 Various errors while attempting to use Pijul

Opened by w4 on June 25, 2023
w4 on June 25, 2023

When attempting to use the pijul CLI for contributing to thrussh, I receive panics and other strange behaviour:

pijul change/pijul diff/pijul remote:

name = "pijul"
operating_system = "Mac OS 13.4.0 [64-bit]"
crate_version = "1.0.0-beta.5"
explanation = """
Panic occurred in file '/Users/jordan/.cargo/registry/src/index.crates.io-6f17d22bba15001f/libpijul-1.0.0-beta.5/src/pristine/hash.rs' at line 232
"""
cause = "Unknown hash algorithm 152"
method = "Panic"
backtrace = """

   0: 0x10111fdac - core::panicking::panic_fmt::h324f50b29db90195
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/core/src/panicking.rs:67
   1: 0x100e74ff8 - <libpijul::pristine::hash::Hash as core::convert::From<&libpijul::pristine::hash::SerializedHash>>::from::h13e9a49b3b0f0e2f
   2: 0x10099f6e4 - <libpijul::changestore::filesystem::FileSystem as libpijul::changestore::ChangeStore>::get_contents::h5e027c4e4b5cb36e
   3: 0x10080be1c - libpijul::record::Builder::delete_obsolete_children::h54991ef68018353d
   4: 0x10080d624 - libpijul::record::Builder::record::h48dae5bec8c583c2
   5: 0x100a9f4bc - pijul::commands::record::Record::record::h69ae63d7b7a5e0ea
   6: 0x100968ff8 - pijul::commands::record::Record::run::{{closure}}::h7c146960a02e4531
   7: 0x1009971e8 - pijul::run::{{closure}}::hadeca9dfbb8163af
   8: 0x1009430c4 - tokio::runtime::park::CachedParkThread::block_on::hdc860d525c73d753
   9: 0x1007dbbac - tokio::runtime::scheduler::multi_thread::MultiThread::block_on::h3e657db02aee0097
  10: 0x100b23b78 - tokio::runtime::runtime::Runtime::block_on::heba237fb47b7ea2d
  11: 0x100a5dff4 - pijul::main::h179577ca263470ae
  12: 0x10091cb6c - std::sys_common::backtrace::__rust_begin_short_backtrace::h5bf07071c23e326d
  13: 0x10091d540 - std::rt::lang_start::{{closure}}::ha3ac71e83e404190
  14: 0x1010a7afc - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::h6f7eb9f266759f90
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/core/src/ops/function.rs:287
                 - std::panicking::try::do_call::h54b2febb9ea02379
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/panicking.rs:485
                 - std::panicking::try::h95a2f9f45aeb75ea
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/panicking.rs:449
                 - std::panic::catch_unwind::h9686256fa0fc97a1
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/panic.rs:140
                 - std::rt::lang_start_internal::{{closure}}::h227e8b10bc4e486b
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/rt.rs:148
                 - std::panicking::try::do_call::h414d500a3ee5fa44
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/panicking.rs:485
                 - std::panicking::try::h4f025820961f1c3f
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/panicking.rs:449
                 - std::panic::catch_unwind::h0b71dfe3538d125d
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/panic.rs:140
                 - std::rt::lang_start_internal::h8ee16b8f6c950a26
                at /rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/rt.rs:148
  15: 0x100a5e0f4 - _main"""

pijul pull/pijul remote:

Error: Corruption error: offset 3403159395259148324 is past the end of the file
tankf33der on June 26, 2023

-1, Can not repeat.

Try to create simple scenario how to get the panic.

pmeunier on June 26, 2023

It could be an OSX thing. I do run @tankf33der’s tests on my Mac mini sometimes, but this isn’t my main machine.

Note that Pijul changed its algorithms multiple times, but they have been completely stable for the last ~2.5 years. There are version identifiers, actually, so I’d be pretty surprised if that were causing the issue.

@w4: if you can repeat consistently from fresh clones, could you give us a full reproduction scenario? If that is impossible, could you send a tarball of the repo to pe@pijul.org? Thanks!