Skip to content

Conversation

@def-
Copy link
Contributor

@def- def- commented Nov 28, 2024

This reverts commit e39999c.

Checked locally if this helps with file/line numbers in panics, and it does indeed. Before this PR:

./materialized
thread 'main' panicked at src/materialized/src/bin/materialized.rs:18:18:
Unknown executable: Some("materialized2")
stack backtrace:
[hangs indefinitely!]

Sometimes the backtrace is printed correctly but without file/line:

stack backtrace:
   0: rust_begin_unwind
   1: core::panicking::panic_fmt
   2: materialized::main
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

With this PR works reliably:

thread 'main' panicked at src/materialized/src/bin/materialized.rs:18:18:
Unknown executable: Some("materialized")
stack backtrace:
   0: rust_begin_unwind
             at /rustc/3f5fd8dd41153bc5fdca9427e9e05be2c767ba23/library/std/src/panicking.rs:652:5
   1: core::panicking::panic_fmt
             at /rustc/3f5fd8dd41153bc5fdca9427e9e05be2c767ba23/library/core/src/panicking.rs:72:14
   2: main
             at src/materialized/src/bin/materialized.rs:18:18
   3: call_once<fn(), ()>
             at /rustc/3f5fd8dd41153bc5fdca9427e9e05be2c767ba23/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

I had no idea Rust was broken with zstd compression in debug sections. I'll open a bug in Rust for this.

Checklist

  • This PR has adequate test coverage / QA involvement has been duly considered. (trigger-ci for additional test/nightly runs)
  • This PR has an associated up-to-date design doc, is a design doc (template), or is sufficiently small to not require a design.
  • If this PR evolves an existing $T ⇔ Proto$T mapping (possibly in a backwards-incompatible way), then it is tagged with a T-proto label.
  • If this PR will require changes to cloud orchestration or tests, there is a companion cloud PR to account for those changes that is tagged with the release-blocker label (example).
  • If this PR includes major user-facing behavior changes, I have pinged the relevant PM to schedule a changelog post.

This reverts commit e39999c.

Check if this helps with file/line numbers in panics
@def- def- requested review from ggevay and teskje November 28, 2024 18:18
@def- def- marked this pull request as ready for review November 28, 2024 18:18
@def- def- added the release-blocker Critical issue that should block *any* release if not fixed label Nov 28, 2024
@def- def- enabled auto-merge November 28, 2024 18:19
@teskje
Copy link
Contributor

teskje commented Nov 28, 2024

Hm, so maybe the PS weirdness was caused by zstd compression and not the line-tables-only change?

@def-
Copy link
Contributor Author

def- commented Nov 28, 2024

Maybe, maybe both? I feel like I don't want to touch this anymore after seeing how brittle tooling is around this, the small disk space savings are probably not worth the potential pain of having no functioning debug info at a crucial time.

The hanging backtrace actually seems to be a problem with us using jemalloc and our custom panic handler and it sometimes also happens with zlib. Has to be a Materialize issue after all, but not a regression from what I can tell.

@def- def- merged commit 33af11a into MaterializeInc:main Nov 28, 2024
73 of 74 checks passed
@def- def- deleted the pr-revert-zstd branch November 28, 2024 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release-blocker Critical issue that should block *any* release if not fixed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants