From d3b58e72611ab5ab7aac85b6189b98bf9efea671 Mon Sep 17 00:00:00 2001 From: Azory YData Bot Date: Mon, 28 Oct 2024 19:40:33 +0000 Subject: [PATCH] fix(linting): code formatting --- src/ydata_profiling/utils/common.py | 10 ++++++---- src/ydata_profiling/utils/logger.py | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/ydata_profiling/utils/common.py b/src/ydata_profiling/utils/common.py index e964af067..08e8febb3 100644 --- a/src/ydata_profiling/utils/common.py +++ b/src/ydata_profiling/utils/common.py @@ -158,10 +158,12 @@ def calculate_nrows(df): n_partitions = df.rdd.getNumPartitions() nrows = ( - df.rdd.mapPartitionsWithIndex( - lambda idx, partition: [sum(1 for _ in partition)] if idx == 0 else [0] - ).collect()[0] - * n_partitions + df.rdd.mapPartitionsWithIndex( + lambda idx, partition: [sum(1 for _ in partition)] + if idx == 0 + else [0] + ).collect()[0] + * n_partitions ) except: nrows = 0 diff --git a/src/ydata_profiling/utils/logger.py b/src/ydata_profiling/utils/logger.py index db31fcdb4..b5873726b 100644 --- a/src/ydata_profiling/utils/logger.py +++ b/src/ydata_profiling/utils/logger.py @@ -21,7 +21,7 @@ def info_def_report(self, df, timeseries: bool) -> None: # noqa: ANN001 try: ncols = len(df.columns) except AttributeError: - ncols=0 + ncols = 0 nrows = calculate_nrows(df)