warn instead of error on unknown latency
This commit is contained in:
parent
f6845b5126
commit
e00eefb990
@ -17,7 +17,7 @@ use std::{
|
||||
time::{Duration, Instant},
|
||||
};
|
||||
|
||||
use log::{error, info};
|
||||
use log::{error, info, warn};
|
||||
use ordered_float::OrderedFloat;
|
||||
use rand::thread_rng;
|
||||
use serde_json::{json, Value};
|
||||
@ -141,7 +141,7 @@ pub fn get_move(
|
||||
|mut guard| {
|
||||
let target_latency = game.timeout / 2;
|
||||
let latency = you.latency.parse().unwrap_or_else(|e| {
|
||||
error!("Unable to parse latency: {e}");
|
||||
warn!("Unable to parse latency: {e}");
|
||||
target_latency
|
||||
});
|
||||
let last_computation_time = u32::try_from(guard.as_millis()).unwrap_or(0);
|
||||
|
Loading…
Reference in New Issue
Block a user