From f78c8b427bf9f7540ddbae2db7b916788f487bf8 Mon Sep 17 00:00:00 2001 From: Ritchie Vink Date: Fri, 17 Nov 2023 09:18:26 +0100 Subject: [PATCH] fix: saturating sub in debug msg (#12525) --- crates/polars-io/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/polars-io/src/lib.rs b/crates/polars-io/src/lib.rs index 35cb299d8950..6aad952d36e6 100644 --- a/crates/polars-io/src/lib.rs +++ b/crates/polars-io/src/lib.rs @@ -125,7 +125,7 @@ pub(crate) fn finish_reader( .map(|df: &DataFrame| df.height()) .sum::(); if polars_core::config::verbose() { - eprintln!("sliced off {} rows of the 'DataFrame'. These lines were read because they were in a single chunk.", df.height() - n) + eprintln!("sliced off {} rows of the 'DataFrame'. These lines were read because they were in a single chunk.", df.height().saturating_sub(n)) } parsed_dfs.push(df.slice(0, len)); break;