sibi-dst 0.3.39__tar.gz → 0.3.40__tar.gz
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.
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/PKG-INFO +1 -1
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/pyproject.toml +1 -1
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/data_wrapper.py +11 -12
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/README.md +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/_df_helper.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/_parquet_artifact.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/_parquet_reader.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/django/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/django/_db_connection.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/django/_io_dask.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/django/_load_from_db.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/django/_sql_model_builder.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/http/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/http/_http_config.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/parquet/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/parquet/_filter_handler.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/parquet/_parquet_options.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_db_connection.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_filter_handler.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_io_dask.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_load_from_db.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_sql_model_builder.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/core/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/core/_defaults.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/core/_filter_handler.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/core/_params_config.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/core/_query_config.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/data_cleaner.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/geopy_helper/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/geopy_helper/geo_location_service.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/geopy_helper/utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/osmnx_helper/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/osmnx_helper/base_osm_map.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/osmnx_helper/basemaps/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/osmnx_helper/basemaps/calendar_html.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/osmnx_helper/basemaps/router_plotter.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/osmnx_helper/utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/tests/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/tests/test_data_wrapper_class.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/__init__.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/airflow_manager.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/clickhouse_writer.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/credentials.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/data_utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/date_utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/df_utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/file_utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/filepath_generator.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/log_utils.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/parquet_saver.py +0 -0
- {sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/utils/storage_manager.py +0 -0
@@ -91,7 +91,7 @@ class DataWrapper:
|
|
91
91
|
max_age_minutes: int = DEFAULT_MAX_AGE_MINUTES,
|
92
92
|
history_days_threshold: int = DEFAULT_HISTORY_DAYS_THRESHOLD,
|
93
93
|
show_progress: bool = False,
|
94
|
-
timeout: float =
|
94
|
+
timeout: float = 60):
|
95
95
|
self.dataclass = dataclass
|
96
96
|
self.date_field = date_field
|
97
97
|
self.data_path = self.ensure_forward_slash(data_path)
|
@@ -158,16 +158,16 @@ class DataWrapper:
|
|
158
158
|
"""
|
159
159
|
update_plan_table = self.generate_update_plan_with_conditions()
|
160
160
|
|
161
|
-
# Display the update plan table to the user if requested
|
162
|
-
if self.show_progress:
|
163
|
-
display(update_plan_table)
|
164
|
-
|
165
161
|
# Filter out rows that do not require updates (priority 0 means skip)
|
166
162
|
with self._lock:
|
167
163
|
update_plan_table = update_plan_table[
|
168
164
|
(update_plan_table["update_required"] == True) & (update_plan_table["update_priority"] != 0)
|
169
165
|
]
|
170
|
-
|
166
|
+
# Display the update plan table to the user if requested
|
167
|
+
if len(update_plan_table.index) == 0:
|
168
|
+
return
|
169
|
+
if self.show_progress:
|
170
|
+
display(update_plan_table)
|
171
171
|
# Group by priority
|
172
172
|
with self._lock:
|
173
173
|
priorities = sorted(update_plan_table["update_priority"].unique())
|
@@ -298,12 +298,16 @@ class DataWrapper:
|
|
298
298
|
within_history = history_start_date <= current_date <= today
|
299
299
|
missing_file = not file_exists and not self.ignore_missing
|
300
300
|
category = None
|
301
|
+
update_required = False
|
301
302
|
|
302
303
|
# Hierarchy 1: Overwrite
|
303
304
|
if self.overwrite:
|
304
305
|
category = "overwrite"
|
305
306
|
update_required = True
|
306
|
-
|
307
|
+
elif missing_file and current_date < today:
|
308
|
+
category = "missing_files"
|
309
|
+
update_required = True
|
310
|
+
|
307
311
|
elif within_history:
|
308
312
|
if file_exists:
|
309
313
|
if self.date_utils.is_file_older_than(
|
@@ -321,11 +325,6 @@ class DataWrapper:
|
|
321
325
|
else:
|
322
326
|
category = "missing_files"
|
323
327
|
update_required = True
|
324
|
-
|
325
|
-
# Hierarchy 3: Missing files
|
326
|
-
elif missing_file and current_date <= today:
|
327
|
-
category = "missing_files"
|
328
|
-
update_required = True
|
329
328
|
else:
|
330
329
|
category = "No Update Required"
|
331
330
|
update_required = False
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/django/_sql_model_builder.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_db_connection.py
RENAMED
File without changes
|
{sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_filter_handler.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
{sibi_dst-0.3.39 → sibi_dst-0.3.40}/sibi_dst/df_helper/backends/sqlalchemy/_sql_model_builder.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|