luxorasap 0.2.19__tar.gz → 0.2.21__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.
- {luxorasap-0.2.19 → luxorasap-0.2.21}/PKG-INFO +1 -1
- {luxorasap-0.2.19 → luxorasap-0.2.21}/pyproject.toml +2 -2
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/__init__.py +1 -1
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/datareader/core.py +14 -11
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap.egg-info/PKG-INFO +1 -1
- {luxorasap-0.2.19 → luxorasap-0.2.21}/README.md +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/setup.cfg +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/btgapi/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/btgapi/auth.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/btgapi/reports.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/btgapi/trades.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/datareader/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/ingest/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/ingest/cloud/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/ingest/legacy_local/dataloader.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/dataframe/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/dataframe/reader.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/dataframe/transforms.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/storage/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/storage/blob.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/storage/change_tracker.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/tools/__init__.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap/utils/tools/excel.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap.egg-info/SOURCES.txt +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap.egg-info/dependency_links.txt +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap.egg-info/entry_points.txt +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap.egg-info/requires.txt +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/src/luxorasap.egg-info/top_level.txt +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_btgapi_auth.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_btgapi_reports.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_btgapi_trades.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_datareader.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_ingest_cloud.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_ingest_legacy_local.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_utils_change_tracker.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_utils_dataframe.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/test_utils_storage.py +0 -0
- {luxorasap-0.2.19 → luxorasap-0.2.21}/tests/tests_utils_pickle_excel.py +0 -0
|
@@ -10,7 +10,7 @@ build-backend = "setuptools.build_meta"
|
|
|
10
10
|
#############################
|
|
11
11
|
[project]
|
|
12
12
|
name = "luxorasap"
|
|
13
|
-
version = "0.2.
|
|
13
|
+
version = "0.2.21"
|
|
14
14
|
description = "Toolbox da Luxor para ingestão, análise e automação de dados financeiros."
|
|
15
15
|
readme = "README.md"
|
|
16
16
|
requires-python = ">=3.9"
|
|
@@ -78,7 +78,7 @@ exclude = ["tests*"]
|
|
|
78
78
|
# bumpver (sem-ver)
|
|
79
79
|
#############################
|
|
80
80
|
[tool.bumpver]
|
|
81
|
-
current_version = "0.2.
|
|
81
|
+
current_version = "0.2.21"
|
|
82
82
|
version_pattern = "MAJOR.MINOR.PATCH"
|
|
83
83
|
|
|
84
84
|
# regex explícito – obrigatório no bumpver 2024+
|
|
@@ -13,7 +13,7 @@ from types import ModuleType
|
|
|
13
13
|
try:
|
|
14
14
|
__version__: str = metadata.version(__name__)
|
|
15
15
|
except metadata.PackageNotFoundError: # editable install
|
|
16
|
-
__version__ = "0.2.
|
|
16
|
+
__version__ = "0.2.21"
|
|
17
17
|
|
|
18
18
|
# ─── Lazy loader ─────────────────────────────────────────────────
|
|
19
19
|
def __getattr__(name: str) -> ModuleType:
|
|
@@ -145,17 +145,15 @@ class LuxorQuery:
|
|
|
145
145
|
|
|
146
146
|
|
|
147
147
|
table_data = self.__load_table(table_name, index=index, index_name=index_name, dtypes_override=dtypes_override,
|
|
148
|
-
auto_convert_mapped_types=auto_convert_mapped_types
|
|
149
|
-
|
|
150
|
-
if (table_data is not None) and drop_last_updated_columns:
|
|
151
|
-
if "Last_Updated" in table_data.columns:
|
|
152
|
-
return table_data.drop(columns=["Last_Updated"])
|
|
148
|
+
auto_convert_mapped_types=auto_convert_mapped_types,
|
|
149
|
+
drop_last_updated_columns=drop_last_updated_columns)
|
|
153
150
|
|
|
154
151
|
return table_data
|
|
155
152
|
|
|
156
153
|
|
|
157
154
|
|
|
158
|
-
def __load_table(self, table_name, index=False, index_name="index", dtypes_override={}, auto_convert_mapped_types=True
|
|
155
|
+
def __load_table(self, table_name, index=False, index_name="index", dtypes_override={}, auto_convert_mapped_types=True,
|
|
156
|
+
drop_last_updated_columns=True):
|
|
159
157
|
def __load_parquet(table_name):
|
|
160
158
|
table_path = f"{self.blob_directory}/{table_name}.parquet"#self.tables_path/"parquet"/f"{table_name}.parquet"
|
|
161
159
|
|
|
@@ -236,8 +234,6 @@ class LuxorQuery:
|
|
|
236
234
|
|
|
237
235
|
for col in table_columns.intersection(str_nan_format):
|
|
238
236
|
table_data[col] = table_data[col].replace("<NA>", pd.NA).replace("nan", pd.NA).replace("", pd.NA)
|
|
239
|
-
|
|
240
|
-
|
|
241
237
|
|
|
242
238
|
return table_data.copy(), table_path, update_time
|
|
243
239
|
|
|
@@ -277,13 +273,17 @@ class LuxorQuery:
|
|
|
277
273
|
if table_data is None:
|
|
278
274
|
logging.info(f"Nao foi possivel carregar a tabela <{table_name}>.")
|
|
279
275
|
return table_data
|
|
280
|
-
|
|
276
|
+
|
|
281
277
|
if index:
|
|
282
278
|
try:
|
|
283
279
|
table_data = table_data.set_index(index_name, drop=True)
|
|
284
280
|
|
|
285
281
|
except Exception:
|
|
286
282
|
logging.info(f"Nao foi possível setar a coluna {index_name} como index para a tabela {table_name}.")
|
|
283
|
+
|
|
284
|
+
if (table_data is not None) and drop_last_updated_columns:
|
|
285
|
+
if "Last_Updated" in table_data.columns:
|
|
286
|
+
table_data = table_data.drop(columns=["Last_Updated"])
|
|
287
287
|
|
|
288
288
|
#table_data = self.__persist_column_formatting(table_data)
|
|
289
289
|
|
|
@@ -868,8 +868,11 @@ class LuxorQuery:
|
|
|
868
868
|
if ticker == 'mcor34 bz equity':
|
|
869
869
|
return 4 #TODO remover quando atualizacao da table for reestabelecida
|
|
870
870
|
sizes = self.get_table("bdr_sizes", index=True, index_name="Ticker")
|
|
871
|
-
|
|
872
|
-
|
|
871
|
+
# dropar coluna Last_Updated caso exista
|
|
872
|
+
if "Last_Updated" in sizes.columns:
|
|
873
|
+
sizes = sizes.drop(columns=["Last_Updated"])
|
|
874
|
+
|
|
875
|
+
return sizes.loc[ticker.lower()].tail(1).squeeze()
|
|
873
876
|
|
|
874
877
|
|
|
875
878
|
def get_cash_movements(self, fund_name, ref_date):
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|