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(case): fix dshape, error on noncomparable and empty cases #9559

Merged
merged 2 commits into from
Jul 24, 2024

Conversation

NickCrews
Copy link
Contributor

@NickCrews NickCrews commented Jul 12, 2024

This is pinning down the expected behavior for cases before tackling the case() to cases() switch in #9096 so that PR can be simpler

@NickCrews NickCrews force-pushed the tweak-case branch 2 times, most recently from c2b62bb to 2c5aaec Compare July 12, 2024 18:35
@cpcloud
Copy link
Member

cpcloud commented Jul 23, 2024

Ok, I think this is pretty close. I'm going to take it over and hopefully merge it.

NickCrews and others added 2 commits July 24, 2024 03:53
This is pinning down the expected behavior for cases before tackling
the case() to cases() switch in
ibis-project#9096
so that PR can be simpler

I move the validation for comparable-ness down into the operation so that
the logic is consolidated to one place.
in ibis-project#9096 there might be multiple places that construct an ops.SimpleCase, and we don't want
to have to implement the validation in all
calling locations.

We could consider relaxing the limitation for non-empty cases later, but for now lets be strict.

I already fixed the shape of ops.SearchedCase in ibis-project#9334,
but it looks like in that PR I forgot to also fix ops.SimpleCase, so I do that fix here.
@cpcloud cpcloud added refactor Issues or PRs related to refactoring the codebase bug Incorrect behavior inside of ibis ux User experience related issues internals Issues or PRs related to ibis's internal APIs labels Jul 24, 2024
@cpcloud cpcloud merged commit ff2d019 into ibis-project:main Jul 24, 2024
90 checks passed
@cpcloud cpcloud added this to the 9.3 milestone Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Incorrect behavior inside of ibis internals Issues or PRs related to ibis's internal APIs refactor Issues or PRs related to refactoring the codebase ux User experience related issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants