Skip to content

Conversation

@jeremiedbb
Copy link
Member

Switch from warning to error when there are pandas.NA but output is not set to pandas.

@jeremiedbb jeremiedbb added No Changelog Needed Quick Review For PRs that are quick to review labels Nov 4, 2024
@github-actions
Copy link

github-actions bot commented Nov 4, 2024

✔️ Linting Passed

All linting checks passed. Your pull request is in excellent shape! ☀️

Generated for commit: 55f3a32. Link to the linter CI: here

ct.fit_transform(df)
ct.set_output(transform="default")

# No warning when there are no pd.NA
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# No warning when there are no pd.NA
# No errors when there are no pd.NA

"""Check behavior when a tranformer's output contains pandas.NA
It should emit a warning unless the output config is set to 'pandas'.
It should emit an error unless the output config is set to 'pandas'.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
It should emit an error unless the output config is set to 'pandas'.
It should raise an error unless the output config is set to 'pandas'.

@thomasjpfan thomasjpfan merged commit e9c3942 into scikit-learn:main Nov 6, 2024
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants