Skip to content

Commit b0785e6

Browse files
committed
removed incorrect use of context manager for loading pl banking data
1 parent 09c7f5a commit b0785e6

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

moddata/_utils.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,9 @@ def _load_btc():
5959

6060

6161
def _load_pl_banking_stocks() -> pd.DataFrame:
62-
with (
62+
return pd.read_parquet(str(
6363
resources.files('moddata.data').joinpath('pl_banking_stocks.parquet')
64-
as f
65-
):
66-
return pd.read_parquet(f)
64+
))
6765

6866

6967
def load_data(dataset: Dataset) -> pd.DataFrame | None:

tests/pipeline/test_bankchurn_pipeline.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,4 @@ def test_bankchurn_pipeline_tree_like():
2121
assert np.all(np.array(y_test.index[:3]) == np.array([7867, 1402, 8606]))
2222

2323

24+
test_bankchurn_pipeline_tree_like

0 commit comments

Comments
 (0)