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

Add dns.Client.get_zone #1718

Closed
wants to merge 1 commit into from
Closed

Conversation

theacodes
Copy link
Contributor

No description provided.

@theacodes theacodes added type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. api: dns Issues related to the Cloud DNS API. labels Apr 12, 2016
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Apr 12, 2016
@tseaver
Copy link
Contributor

tseaver commented Apr 12, 2016

Adding this method kind of violates "There should be one-- and preferably only one --obvious way to do it.", given that is is an alias for:

zone = client.zone('my-zone')
zone.reload()

@theacodes
Copy link
Contributor Author

Yeah, so is Storage.get_bucket, but this makes things a lot more usable.

@theacodes
Copy link
Contributor Author

Also as an aside, client.zone() requires more than just the name as an argument. Separate issue, but related.

@dhermes
Copy link
Contributor

dhermes commented Apr 12, 2016

Client.get_bucket (in storage) was somewhat forced on us. In general we prefer the noun->verb approach rather than the imperative "gimme a noun".

@theacodes
Copy link
Contributor Author

Seems I'm outvoted. That's fine. I'm going to file a few bugs that keep the preferred method from working today.

@theacodes theacodes closed this Apr 12, 2016
@jgeewax jgeewax reopened this Apr 13, 2016
@jgeewax
Copy link
Contributor

jgeewax commented Apr 13, 2016

I don't think you're outvoted yet. I'm still +1 to .get_zone() rather than the two-phase "get" (.zone() + .reload())

For example::

>>> try:
>>> zone = client.get_zone('my-zone')

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

@theacodes
Copy link
Contributor Author

Is this PR still relevant? If not, feel free to close it.

@daspecster
Copy link
Contributor

Not sure, but we can reopen this if it comes back up!
Or maybe we should just move discussion to #1722?

@daspecster daspecster closed this Jul 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: dns Issues related to the Cloud DNS API. cla: yes This human has signed the Contributor License Agreement. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants