Disable error log for position clamping, its too noisy due to ease of triggering

This commit is contained in:
Lukas Wirth 2025-08-07 15:14:22 +02:00
parent 8d75311400
commit 5022fb6343

View File

@ -40,12 +40,13 @@ pub(crate) fn offset(
})?; })?;
let col = TextSize::from(line_col.col); let col = TextSize::from(line_col.col);
let clamped_len = col.min(line_range.len()); let clamped_len = col.min(line_range.len());
if clamped_len < col { // FIXME: The cause for this is likely our request retrying. Commented out as this log is just too chatty and very easy to trigger.
tracing::error!( // if clamped_len < col {
"Position {line_col:?} column exceeds line length {}, clamping it", // tracing::error!(
u32::from(line_range.len()), // "Position {line_col:?} column exceeds line length {}, clamping it",
); // u32::from(line_range.len()),
} // );
// }
Ok(line_range.start() + clamped_len) Ok(line_range.start() + clamped_len)
} }