Conversation
theacodes
left a comment
There was a problem hiding this comment.
Looks mostly good, a few tiny nits. Thank you for doing this.
| """Raise ValueError if more than one keyword argument is not none. | ||
| Args: | ||
| kwargs (dict): The keyword arguments sent to the function. | ||
| Returns: None |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| """ | ||
| # Sanity check: If no keyword arguments were sent, this is fine. | ||
| if not kwargs: | ||
| return None |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| assert protobuf_helpers.check_oneof(foo='bar') is None | ||
| assert protobuf_helpers.check_oneof(foo='bar', baz=None) is None | ||
| assert protobuf_helpers.check_oneof(foo=None, baz='bacon') is None | ||
| assert (protobuf_helpers.check_oneof(foo='bar', spam=None, eggs=None) |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
|
There's an unrelated lint error blocking this, I sent #4250 to fix. Can you verify that |
|
That command ran successfully. |
No description provided.