Skip to content

Update code to not raise any FutureWarnings #190

Description

@patrickleonardy

Update code to not raise any FutureWarnings

Some code in the Cobra library raises FutureWarnings.

Task Description

Change the code such that those FutureWarnings do not end up generating problem later

FutureWarnings

tests/preprocessing/test_target_encoder.py::TestTargetEncoder::test_target_encoder_transform_new_category_linear_regression_median
/home/patrick/github_projects/work/cobra/tests/preprocessing/test_target_encoder.py:312: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead.
df_appended = df.append({"variable": "new", "target": 10},

tests/preprocessing/test_target_encoder.py::TestTargetEncoder::test_target_encoder_transform_new_category_binary_classification_median
/home/patrick/github_projects/work/cobra/tests/preprocessing/test_target_encoder.py:338: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead.
df_appended = df.append({"variable": "new", "target": 1},

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions