Filter out asn1_codecs warnings in rayhunter-daemon

...and make a small UI change so that folks won't get concerned about parsing errors.

Right now all the "undecoded extensions" noise goes into
rayhunter-daemon.log, and users get concerned about it when browsing
that through the UI.
This commit is contained in:
Markus Unterwaditzer
2026-02-03 11:42:28 +01:00
committed by Will Greenberg
parent 5b2cf3cec4
commit 1f171521e4
8 changed files with 17 additions and 47 deletions
+1
View File
@@ -16,6 +16,7 @@ crc = "3.0.1"
deku = { version = "0.20.0", features = ["logging"] }
libc = "0.2.150"
log = "0.4.20"
env_logger = { version = "0.11", default-features = false }
nix = { version = "0.29.0", features = ["feature"] }
pcap-file-tokio = "0.1.0"
pycrate-rs = { git = "https://github.com/EFForg/pycrate-rs" }
+11
View File
@@ -1,5 +1,16 @@
use serde::{Deserialize, Serialize};
/// Initialize logging with the given default level, suppressing noisy warnings
/// from hampi about undecoded ASN1 extensions. Respects `RUST_LOG` overrides.
pub fn init_logging(default_level: log::LevelFilter) {
env_logger::Builder::new()
.filter_level(default_level)
//Filter out a stupid massive amount of uneccessary warnings from hampi about undecoded extensions
.filter_module("asn1_codecs", log::LevelFilter::Error)
.parse_default_env()
.init();
}
pub mod analysis;
pub mod diag;
pub mod gsmtap;