psi_exporter icon indicating copy to clipboard operation
psi_exporter copied to clipboard

skip over cgroup.pressure file

Open timo opened this issue 5 months ago • 0 comments

it only contains a single number, 0 or 1, to indicate whether pressure stall informaiton is turned on or off for the cgroup. The unexpected format causes a panic:

thread 'main' panicked at src/main.rs:211:33:
called `Result::unwrap()` on an `Err` value: PsiParseError(UnexpectedTerm("1"))
stack backtrace:
   0: rust_begin_unwind
   1: core::panicking::panic_fmt
   2: core::result::unwrap_failed
   3: core::result::Result<T,E>::unwrap
             at /builddir/build/BUILD/rustc-1.76.0-src/library/core/src/result.rs:1073:23
   4: psi_exporter::get_service_measurements
             at ./src/main.rs:211:26
   5: psi_exporter::main
             at ./src/main.rs:60:33
   6: core::ops::function::FnOnce::call_once
             at /builddir/build/BUILD/rustc-1.76.0-src/library/core/src/ops/function.rs:250:5

timo avatar Mar 09 '24 18:03 timo