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

Replace validating property boilerplate w/ custom descriptors. #1075

Merged
merged 1 commit into from
Aug 23, 2015
Merged

Replace validating property boilerplate w/ custom descriptors. #1075

merged 1 commit into from
Aug 23, 2015

Conversation

tseaver
Copy link
Contributor

@tseaver tseaver commented Aug 20, 2015

Addresses point #3 of:
#1072 (comment)

@tseaver tseaver added api: bigquery Issues related to the BigQuery API. hygiene labels Aug 20, 2015
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Aug 20, 2015
@tseaver
Copy link
Contributor Author

tseaver commented Aug 20, 2015

@dhermes PTAL: I think you'll like the linecount reduction.

return self
return getattr(instance._configuration, self._backing_name)

def _validate(self, value):

This comment was marked as spam.

@dhermes
Copy link
Contributor

dhermes commented Aug 21, 2015

General comment: this is awesome. Let's also file a bug to do this for other discovery-based APIs and then put these classes in core?


:raises: ValueError for invalid value types.
"""
if not isinstance(value, bool):

This comment was marked as spam.

@dhermes
Copy link
Contributor

dhermes commented Aug 21, 2015

LGTM. Do or don't update the error message for multiple types (e.g. six.integer_types).

tseaver added a commit that referenced this pull request Aug 23, 2015
Replace validating property boilerplate w/ custom descriptors.
@tseaver tseaver merged commit 6df44a2 into googleapis:master Aug 23, 2015
@tseaver tseaver deleted the bigquery-reduce_config_boilerplate branch August 23, 2015 16:36
parthea pushed a commit that referenced this pull request Oct 21, 2023
…oogleCloudPlatform/python-docs-samples#1075)

In particular, this change:
- changes to use a consistent "_id" suffix for resource name components
- uses "data" instead of "text", since encryption is not restricted to text
- substitutes "ciphertext" for "encrypted {text, data}"
- spells "crypto key" and "key ring" each as two separate words, as in the API

Tracking bug: http://b/64758639
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the BigQuery API. cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants