Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for latest deps for woodwork 0.28.0 #2644

Merged
merged 25 commits into from
Feb 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/tests_with_latest_deps.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ jobs:
$ProgressPreference = "silentlyContinue"
Invoke-WebRequest -Uri $Uri -Outfile "$env:USERPROFILE/$File"
$hashFromFile = Get-FileHash "$env:USERPROFILE/$File" -Algorithm SHA256
$hashFromUrl = "e841557c27d438b96e09126a2b0656154a3a34bdb9d87d59ceaea67515713515"
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
$hashFromUrl = "c9b32faa9262828702334b16bcb5b53556e630d54e5127f5c36c7ba7ed43179a"
if ($hashFromFile.Hash -ne "$hashFromUrl") {
Throw "$File hashes do not match"
}
Expand Down
3 changes: 2 additions & 1 deletion docs/source/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@ Future Release
==============
* Enhancements
* Fixes
* Fix dependency issues (:pr:`2644`)
* Changes
* Documentation Changes
* Testing Changes
* Update tests for compatibility with new versions of ``holidays`` (:pr:`2636`)
* Update ruff to 0.1.6 and use ruff linter/formatter (:pr:`2639`)

Thanks to the following people for contributing to this release:
:user:`gsheni`, :user:`thehomebrewnerd`
:user:`gsheni`, :user:`thehomebrewnerd`, :user:`tamargrey`


v1.28.0 Oct 26, 2023
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def time_since_previous_false(datetime_col, bool_col):
df.loc[not_false_indices, "last_false_datetime"] = np.nan
df["last_false_datetime"] = df["last_false_datetime"].fillna(method="ffill")
total_seconds = (
df["datetime"] - df["last_false_datetime"]
pd.to_datetime(df["datetime"]).subtract(df["last_false_datetime"])
).dt.total_seconds()
return pd.Series(total_seconds)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def time_since_previous_true(datetime_col, bool_col):
df.loc[~not_false_indices, "last_true_datetime"] = np.nan
df["last_true_datetime"] = df["last_true_datetime"].fillna(method="ffill")
total_seconds = (
df["datetime"] - df["last_true_datetime"]
pd.to_datetime(df["datetime"]).subtract(df["last_true_datetime"])
).dt.total_seconds()
return pd.Series(total_seconds)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ class DateToHoliday(TransformPrimitive):
>>> date_to_holiday_canada = DateToHoliday(country='Canada')
>>> dates = pd.Series([datetime(2016, 7, 1),
... datetime(2016, 11, 15),
... datetime(2018, 9, 3)])
... datetime(2018, 12, 25)])
>>> date_to_holiday_canada(dates).tolist()
['Canada Day', nan, 'Labour Day']
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
['Canada Day', nan, 'Christmas Day']
"""

name = "date_to_holiday"
Expand Down
4 changes: 2 additions & 2 deletions featuretools/tests/entityset_tests/test_serialization.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,9 @@ def test_to_pickle_id_none(tmp_path):
@pytest.fixture
def s3_client():
_environ = os.environ.copy()
from moto import mock_s3
from moto import mock_aws

with mock_s3():
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
with mock_aws():
s3 = boto3.resource("s3")
yield s3
os.environ.clear()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,9 @@ def serialize_name_unchanged(original):
@pytest.fixture
def s3_client():
_environ = os.environ.copy()
from moto import mock_s3
from moto import mock_aws

with mock_s3():
with mock_aws():
s3 = boto3.resource("s3")
yield s3
os.environ.clear()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@ def test_valid_country():
[
"2016-07-01",
"2016-11-11",
"2018-09-03",
"2018-12-25",
],
).astype("datetime64[ns]")
answer = ["Canada Day", np.nan, "Labour Day"]
answer = ["Canada Day", np.nan, "Christmas Day"]
given_answer = date_to_holiday(case).astype("str")
np.testing.assert_array_equal(given_answer, answer)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
boto3==1.17.46
boto3==1.34.32
cloudpickle==1.5.0
composeml==0.8.0
graphviz==0.8.4
holidays==0.13
moto[all]==3.0.7
moto[all]==5.0.0
numpy==1.21.0
packaging==20.0
pandas==1.5.0
Expand Down
15 changes: 7 additions & 8 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ requires-python = ">=3.8,<4"
dependencies = [
"cloudpickle >= 1.5.0",
"holidays >= 0.17",
"numpy >= 1.21.0",
"numpy >= 1.21.0, <2.0.0",
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
"packaging >= 20.0",
"pandas >= 1.5.0",
"pandas >= 1.5.0,<2.2.0",
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
"psutil >= 5.6.6",
"scipy >= 1.10.0",
"tqdm >= 4.32.0",
Expand All @@ -51,10 +51,10 @@ dependencies = [

[project.optional-dependencies]
test = [
"boto3 >= 1.17.46",
"boto3 >= 1.34.32",
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
"composeml >= 0.8.0",
"graphviz >= 0.8.4",
"moto[all] >= 3.0.7",
"moto[all] >= 5.0.0",
"pip >= 21.3.1",
"pyarrow >= 3.0.0,<13.0.0",
"pympler >= 0.8",
Expand All @@ -71,7 +71,7 @@ dask = [
"woodwork[dask] >= 0.23.0",
]
spark = [
"woodwork[spark] >= 0.23.0",
"woodwork[spark] >= 0.23.0, <0.28.0",
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
"pyspark >= 3.2.2",
"numpy < 1.24.0",
"pandas < 2.0.0",
Expand All @@ -84,7 +84,7 @@ tsfresh = [
"featuretools-tsfresh-primitives >= 1.0.0",
]
premium = [
"premium_primitives >= 0.0.2",
"premium_primitives @ git+https://github.com/alteryx/premium_primitives.git@main",
tamargrey marked this conversation as resolved.
Show resolved Hide resolved
]
autonormalize = [
"autonormalize >= 2.0.1",
Expand All @@ -107,10 +107,9 @@ docs = [
"sphinx-inline-tabs == 2022.1.2b11",
"sphinx-copybutton == 0.5.0",
"myst-parser == 0.18.0",
"premium_primitives >= 0.0.2",
"autonormalize >= 2.0.1",
"click >= 7.0.0",
"featuretools[sklearn,dask,spark,test]",
"featuretools[sklearn,dask,spark,test,premium]",
]
dev = [
"ruff >= 0.1.6",
Expand Down
Loading