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 issue with merge task and comparisons #1609

Merged
merged 2 commits into from
Oct 9, 2019
Merged

Fix issue with merge task and comparisons #1609

merged 2 commits into from
Oct 9, 2019

Conversation

cicdw
Copy link
Member

@cicdw cicdw commented Oct 9, 2019

Thanks for contributing to Prefect!

Please describe your work and make sure your PR:

  • adds new tests (if appropriate)
  • updates CHANGELOG.md (if appropriate)
  • updates docstrings for any new functions or function arguments, including docs/outline.toml for API reference docs (if appropriate)

Note that your PR will not be reviewed unless all three boxes are checked.

What does this PR change?

This PR updates the merge task to do an isinstance check instead of a direct comparison; this allows for the merge task to work with objects that don't have a robust __bool__ method such as pandas dataframes and numpy arrays.

Why is this PR important?

We should strive to be agnostic to what types of objects tasks return

@codecov
Copy link

codecov bot commented Oct 9, 2019

Codecov Report

Merging #1609 into master will not change coverage.
The diff coverage is 100%.

return self

def __bool__(self):
raise SyntaxError("You can't handle the truth!")
Copy link

Choose a reason for hiding this comment

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

Great message

@cicdw cicdw merged commit 2f5bc42 into master Oct 9, 2019
@cicdw cicdw deleted the equality-fix branch October 9, 2019 18:12
zanieb pushed a commit that referenced this pull request Apr 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants