power-grid-model-io 1.3.11__py3-none-any.whl → 1.3.13__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of power-grid-model-io might be problematic. Click here for more details.

@@ -18,10 +18,12 @@ def exclude_empty(row: pd.Series, col: str) -> bool:
18
18
  """
19
19
  if col not in row:
20
20
  raise ValueError(f"The column: '{col}' cannot be found for the filter")
21
- result = has_value(row[col])
22
- if isinstance(result, pd.Series):
23
- return result.item()
24
- return result
21
+
22
+ col_value = row[col]
23
+ if isinstance(col_value, pd.Series):
24
+ col_value = col_value.item()
25
+
26
+ return has_value(col_value)
25
27
 
26
28
 
27
29
  def exclude_value(row: pd.Series, col: str, value: float | str) -> bool:
@@ -30,11 +32,12 @@ def exclude_value(row: pd.Series, col: str, value: float | str) -> bool:
30
32
  """
31
33
  if col not in row:
32
34
  raise ValueError(f"The column: '{col}' cannot be found for the filter")
33
- result = row[col] != value
34
- # Sonar cloud false positive (S2583): result can be a pd.Series of bool
35
- if isinstance(result, pd.Series): # NOSONAR
36
- return result.item()
37
- return result
35
+
36
+ col_value = row[col]
37
+ if isinstance(col_value, pd.Series):
38
+ col_value = col_value.item()
39
+
40
+ return col_value != value
38
41
 
39
42
 
40
43
  def exclude_all_columns_empty_or_zero(row: pd.Series, cols: List[str]) -> bool:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: power-grid-model-io
3
- Version: 1.3.11
3
+ Version: 1.3.13
4
4
  Summary: Power Grid Model Input/Output
5
5
  Author-email: Contributors to the Power Grid Model project <powergridmodel@lfenergy.org>
6
6
  License: MPL-2.0
@@ -25,7 +25,7 @@ power_grid_model_io/data_types/_data_types.py,sha256=8kKDdYTF9BZL1BscnIEUHaz1d6B
25
25
  power_grid_model_io/data_types/tabular_data.py,sha256=3sLF3CAxwbA8GCxKf-MDMETBUakhVIZOVmaF5adIENk,8541
26
26
  power_grid_model_io/functions/__init__.py,sha256=l1PjXVh21UTlWmv3j_KvflEymTUcGNxm8BDDpt1jUYc,734
27
27
  power_grid_model_io/functions/_functions.py,sha256=tqwwZ0G8AeDza0IiS6CSMwKB0lV1hDo2D8e9-ARHXQM,2843
28
- power_grid_model_io/functions/filters.py,sha256=yF24k64r5FDFVSSgYGMpRq-JmrM6pfeTekkLeXXtnB8,1385
28
+ power_grid_model_io/functions/filters.py,sha256=Qoe0JzXy2PQbGkCms2Hcx1iZmVxQK7nP_wRrywWhs1U,1336
29
29
  power_grid_model_io/functions/phase_to_phase.py,sha256=Cufj3lcUESKa_AFHn27GsUMxjTFmF5mj0-sdFrE7V00,4495
30
30
  power_grid_model_io/mappings/__init__.py,sha256=qwbj1j-Aa_yRB-E3j35pEVtF3mgH8CVIXAnog5mOry0,138
31
31
  power_grid_model_io/mappings/field_mapping.py,sha256=YfrwKolNG06kIC1sbUYnYmxuOrbNbNo1dYtnF8rNItw,1659
@@ -43,8 +43,8 @@ power_grid_model_io/utils/modules.py,sha256=DJLmYKt9cV_GvqJI8wkXppNycqD4b8n5-o_8
43
43
  power_grid_model_io/utils/parsing.py,sha256=cw6d3S89BvB8dncN0SeFHDhFG7ZlDNx9iGYWjZk5fVU,4684
44
44
  power_grid_model_io/utils/uuid_excel_cvtr.py,sha256=FFsfnvELVTkIXE_qfEPjFlphsikAr7GyjnNwsDZ-AgY,7581
45
45
  power_grid_model_io/utils/zip.py,sha256=VXHX4xWPPZbhOlZUAbMDy3MgQFzK6_l7sRvGXihNUY4,3875
46
- power_grid_model_io-1.3.11.dist-info/licenses/LICENSE,sha256=7Pm2fWFFHHUG5lDHed1vl5CjzxObIXQglnYsEdtjo_k,14907
47
- power_grid_model_io-1.3.11.dist-info/METADATA,sha256=W9f1_AuTXU0o71d5g8m0dYiEcq9DuCYId-7IdE-GXAE,8196
48
- power_grid_model_io-1.3.11.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
49
- power_grid_model_io-1.3.11.dist-info/top_level.txt,sha256=7sq9VveemMm2R0RgTBa4tH8y_xF4_1hxbufmX9OjCTo,20
50
- power_grid_model_io-1.3.11.dist-info/RECORD,,
46
+ power_grid_model_io-1.3.13.dist-info/licenses/LICENSE,sha256=7Pm2fWFFHHUG5lDHed1vl5CjzxObIXQglnYsEdtjo_k,14907
47
+ power_grid_model_io-1.3.13.dist-info/METADATA,sha256=ITx0pvEdQfCAaNFNy3_9zQnzo3i_6wzAQWn63lvUO0Y,8196
48
+ power_grid_model_io-1.3.13.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
49
+ power_grid_model_io-1.3.13.dist-info/top_level.txt,sha256=7sq9VveemMm2R0RgTBa4tH8y_xF4_1hxbufmX9OjCTo,20
50
+ power_grid_model_io-1.3.13.dist-info/RECORD,,