Skip to content

Commit

Permalink
Package updates
Browse files Browse the repository at this point in the history
  • Loading branch information
aschonfeld committed Jul 18, 2023
1 parent ee5c006 commit 72935a7
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 13 deletions.
6 changes: 5 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ scipy<=1.5.4; python_version == '3.4'
scipy<=1.5.4; python_version == '3.5'
scipy<=1.5.4; python_version == '3.6'
scipy<=1.7.3; python_version == '3.7'
scipy<=1.9.3; python_version >= '3.8'
scipy<=1.10.1; python_version == '3.8'
scipy; python_version >= '3.9'
seaborn<=0.9.1; python_version < '3.6'
seaborn<=0.11.2; python_version == '3.6'
seaborn; python_version > '3.6'
Expand All @@ -104,8 +105,11 @@ strsimpy
six
# required for loading plotly
tenacity<=7.0.0; python_version == '3.6'
threadpoolctl<=3.1.0; python_version == '3.6'
threadpoolctl<=3.1.0; python_version == '3.7'
werkzeug<=1.0.1; python_version <= '3.6'
werkzeug<2.3; python_version >= '3.7'
xarray<=0.11.3; python_version < '3.0'
xarray; python_version >= '3.0'
xlrd
zipp<=3.15.0; python_version == '3.6'
6 changes: 2 additions & 4 deletions tests/arcticdb/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,8 +337,7 @@ def test_get_arcticdb_libraries(unittest, arcticdb_path, arcticdb):
load_libs_mock.assert_called_once()

with mock.patch(
"dtale.global_state.store._libraries",
["lib{}".format(v) for v in range(501)],
"dtale.global_state.store._libraries", ["lib{}".format(v) for v in range(501)]
):
with app.test_client() as c:
response = c.get("/dtale/arcticdb/libraries")
Expand Down Expand Up @@ -388,8 +387,7 @@ def test_get_arcticdb_symbols(unittest, arcticdb_path, arcticdb):
with ExitStack() as stack:
stack.enter_context(
mock.patch(
"dtale.global_state.store.load_symbols",
mock.Mock(return_value=None),
"dtale.global_state.store.load_symbols", mock.Mock(return_value=None)
)
)
stack.enter_context(
Expand Down
4 changes: 2 additions & 2 deletions tests/data/test_variance.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"jarqueBera": {
"pvalue": 0.0,
"statistic": 176.04166666666663
"statistic": 176.0417
},
"missingCt": 0,
"outlierCt": 0,
Expand Down Expand Up @@ -47,7 +47,7 @@
},
"jarqueBera": {
"pvalue": 0.0,
"statistic": 649480728.9999514
"statistic": 649480729.0
},
"missingCt": 0,
"outlierCt": 1,
Expand Down
3 changes: 1 addition & 2 deletions tests/dtale/test_reshapers.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,7 @@ def test_aggregate_str_joiner(unittest):
build_dtypes(dtypes)
build_settings(settings)
reshape_cfg = dict(
index="a",
agg=dict(type="col", cols={"b": ["count", "str_joiner"]}),
index="a", agg=dict(type="col", cols={"b": ["count", "str_joiner"]})
)
resp = c.get(
"/dtale/reshape/{}".format(c.port),
Expand Down
14 changes: 10 additions & 4 deletions tests/dtale/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,10 +317,7 @@ def test_startup(unittest):
)

many_cols = pd.DataFrame({"sec{}".format(v): [1] for v in range(500)})
instance = views.startup(
URL,
data=many_cols,
)
instance = views.startup(URL, data=many_cols)
unittest.assertEqual(
len([v for v in global_state.get_dtypes(instance._data_id) if v["visible"]]),
100,
Expand Down Expand Up @@ -1258,6 +1255,12 @@ def _df():
expected["x"]["check2"]["val2"]["val"] = 1
response_data = response.get_json()
del response_data["code"]
response_data["jarqueBera"]["pvalue"] = round(
response_data["jarqueBera"]["pvalue"], 4
)
response_data["jarqueBera"]["statistic"] = round(
response_data["jarqueBera"]["statistic"], 4
)
unittest.assertEqual(response_data, expected["x"])

response = c.get(
Expand All @@ -1268,6 +1271,9 @@ def _df():
response_data["shapiroWilk"]["statistic"] = round(
response_data["shapiroWilk"]["statistic"], 4
)
response_data["jarqueBera"]["statistic"] = round(
response_data["jarqueBera"]["statistic"], 4
)
unittest.assertEqual(response_data, expected["low_var"])


Expand Down

0 comments on commit 72935a7

Please sign in to comment.