feat: Allow windowing in 'partial' ordering mode#861
Merged
TrevorBergeron merged 7 commits intomainfrom Aug 5, 2024
Merged
Conversation
tswast
reviewed
Jul 30, 2024
bigframes/session/__init__.py
Outdated
| return self._slot_millis_sum | ||
|
|
||
| @property | ||
| def allow_ambiguity(self) -> bool: |
Collaborator
There was a problem hiding this comment.
Does this need to be a public property? I'd prefer to keep it private until we have a request from users to modifying it.
Also, I'm not sold on the naming. Should it be specific and mention ambiguous orderings? Or rename to allow all forms of non-determinism?
Contributor
Author
There was a problem hiding this comment.
Yes, no reason to make this a public property. This is specifically for use in windowing - where ambiguous orderings produce ambiguous row values. Ordering ambiguity is introduced through "partial" ordering mode already.
tswast
approved these changes
Aug 2, 2024
bigframes/core/__init__.py
Outdated
| raise ValueError("Generating offsets not supported in unordered mode") | ||
| if self.node.order_ambiguous and not (self.session._strictly_ordered): | ||
| if not self.session._allows_ambiguity: | ||
| raise ValueError("Generating offsets not supported in unordered mode") |
Collaborator
There was a problem hiding this comment.
Nit: partial ordered mode
Let's try to be consistent with our naming of the feature.
bigframes/core/__init__.py
Outdated
| ) | ||
| if not self.session._allows_ambiguity: | ||
| raise ValueError( | ||
| "Generating offsets not supported in unordered mode" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #<issue_number_goes_here> 🦕