-
Notifications
You must be signed in to change notification settings - Fork 6
Add support for live rule field in sift-client #463
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
base: main
Are you sure you want to change the base?
Conversation
| asset_tag_ids: list[str] | None = None | ||
| contextual_channels: list[str] | None = None | ||
| is_external: bool = False | ||
| is_live_evaluation_enabled: bool = False |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we come up with a better name for this? Perhaps "evaluate_on_live_data"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would rather use the same name as the API to be consistent. Keeping it consistent makes it easier to find and search for.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah it keeps the update code a bit simpler as well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The intention of the SiftClient is to abstract the API and its (possibly) confusing or inconsistent implementation. Not overly concerned about this case, but we should not simply match the API topology to be consistent.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, we could go ahead and change it then. I do agree that it's a bit unclear as is
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alexluck-sift Makes sense. I feel like we should get rid of is_enabled since that's a deprecated field anyway, and just consolidate to is_live. Seems like a bigger change that we don't need to make in this PR right now but should consider in the future to simplify the interface.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, if it is deprecated, I don't see a reason to keep it. Seems like a trivial change to include in this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, I just made those changes
Live rule evaluation was added to UpdateRulesRequest proto here: #424. Updating python class to correspond