Migrate to structured logging
This commit is contained in:
1 parent
0367d5001b
commit
0baf6cadf7
13 files changed
+202
-30
No files matched your search
+3
-2
@@ -22,6 +22,7 @@ use std::num::ParseIntError;
|
||||
use std::str::FromStr;
|
||||
use std::sync::Arc;
|
||||
use std::time::Instant;
|
||||
use log::info;
|
||||
|
||||
const MAX_HISTORY_LEN: usize = 20;
|
||||
const MAX_HISTORY_LEN_PART: f32 = 0.33;
|
||||
@@ -661,7 +662,7 @@ impl DeckSettings {
|
||||
let time = Instant::now();
|
||||
let engine = Engine::new();
|
||||
let ast = engine.compile(&self.filter);
|
||||
println!("Compile time is {:?}", time.elapsed());
|
||||
info!("Compile time is {:?}", time.elapsed());
|
||||
ast.is_ok()
|
||||
}
|
||||
pub fn get_word_list(&self, state: &AppState) -> Vec<usize> {
|
||||
@@ -705,7 +706,7 @@ impl DeckSettings {
|
||||
.map(|(index, _)| index)
|
||||
.collect();
|
||||
|
||||
println!("Collecting available words is {:?}", time.elapsed());
|
||||
info!("Collecting available words is {:?}", time.elapsed());
|
||||
|
||||
list
|
||||
} else {
|
||||
|
||||
Reference in new issue
Block a user