Install this library in a virtualenv using pip. virtualenv is a tool to
create isolated Python environments. The basic problem it addresses is one of
dependencies and versions, and indirectly permissions.
With virtualenv, it's possible to install this library without needing system
install permissions, and without clashing with the installed system
dependencies.
def test_ctor(self):
zone = _Zone()
rrs = self._make_one(
"test.example.com", "CNAME", 3600, ["www.example.com"], zone
)
tests/unit/test_resource_record_set.py:32:
tests/unit/test_resource_record_set.py:26: in _make_one
return self._get_target_class()(*args, **kw)
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
def test_from_api_repr_missing_rrdatas(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:43:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
def test_from_api_repr_missing_name(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:80:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
Cloning into 'working_repo'...
Switched to branch 'autosynth'
Running synthtool
['/tmpfs/src/git/autosynth/env/bin/python3', '-m', 'synthtool', 'synth.py', '--']
synthtool > Executing /tmpfs/src/git/autosynth/working_repo/synth.py.
On branch autosynth
nothing to commit, working tree clean
HEAD detached at FETCH_HEAD
nothing to commit, working tree clean
.coveragerc
.flake8
.github/CONTRIBUTING.md
.github/ISSUE_TEMPLATE/bug_report.md
.github/ISSUE_TEMPLATE/feature_request.md
.github/ISSUE_TEMPLATE/support_request.md
.github/PULL_REQUEST_TEMPLATE.md
.github/release-please.yml
.gitignore
.kokoro/build.sh
.kokoro/continuous/common.cfg
.kokoro/continuous/continuous.cfg
.kokoro/docs/common.cfg
.kokoro/docs/docs.cfg
.kokoro/presubmit/common.cfg
.kokoro/presubmit/presubmit.cfg
.kokoro/publish-docs.sh
.kokoro/release.sh
.kokoro/release/common.cfg
.kokoro/release/release.cfg
.kokoro/trampoline.sh
CODE_OF_CONDUCT.md
CONTRIBUTING.rst
LICENSE
MANIFEST.in
docs/_static/custom.css
docs/_templates/layout.html
docs/conf.py.j2
noxfile.py.j2
renovate.json
setup.cfg
Running session blacken
Creating virtual environment (virtualenv) using python3.6 in .nox/blacken
pip install black==19.3b0
Error: pip is not installed into the virtualenv, it is located at /tmpfs/src/git/autosynth/env/bin/pip. Pass external=True into run() to explicitly allow this.
Session blacken failed.
synthtool > Failed executing nox -s blacken:
None
synthtool > Wrote metadata to synth.metadata.
Traceback (most recent call last):
File "/home/kbuilder/.pyenv/versions/3.6.1/lib/python3.6/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/home/kbuilder/.pyenv/versions/3.6.1/lib/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/__main__.py", line 102, in <module>
main()
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 764, in __call__
return self.main(*args, **kwargs)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 717, in main
rv = self.invoke(ctx)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 555, in invoke
return callback(*args, **kwargs)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/__main__.py", line 94, in main
spec.loader.exec_module(synth_module) # type: ignore
File "<frozen importlib._bootstrap_external>", line 678, in exec_module
File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
File "/tmpfs/src/git/autosynth/working_repo/synth.py", line 30, in <module>
s.shell.run(["nox", "-s", "blacken"], hide_output=False)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/shell.py", line 39, in run
raise exc
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/shell.py", line 33, in run
encoding="utf-8",
File "/home/kbuilder/.pyenv/versions/3.6.1/lib/python3.6/subprocess.py", line 418, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['nox', '-s', 'blacken']' returned non-zero exit status 1.
Synthesis failed
Google internal developers can see the full log here.
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Does google-cloud-dns python client supports dry-run? Sorry for the trouble! ๐
If yes, could you please redirect me to the documentation.
WHY
I am using google-cloud-dns python client. I think it would be a good idea to do dry-run to see the changes. But i could not find anything related here.
def test_from_api_repr_missing_ttl(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:52:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Cloning into 'working_repo'...
Switched to branch 'autosynth'
Running synthtool
['/tmpfs/src/git/autosynth/env/bin/python3', '-m', 'synthtool', 'synth.py', '--']
synthtool > Executing /tmpfs/src/git/autosynth/working_repo/synth.py.
.coveragerc
.flake8
.github/CONTRIBUTING.md
.github/ISSUE_TEMPLATE/bug_report.md
.github/ISSUE_TEMPLATE/feature_request.md
.github/ISSUE_TEMPLATE/support_request.md
.github/PULL_REQUEST_TEMPLATE.md
.github/release-please.yml
.gitignore
.kokoro/build.sh
.kokoro/continuous/common.cfg
.kokoro/continuous/continuous.cfg
.kokoro/docs/common.cfg
.kokoro/docs/docs.cfg
.kokoro/presubmit/common.cfg
.kokoro/presubmit/presubmit.cfg
.kokoro/publish-docs.sh
.kokoro/release.sh
.kokoro/release/common.cfg
.kokoro/release/release.cfg
.kokoro/trampoline.sh
CODE_OF_CONDUCT.md
CONTRIBUTING.rst
LICENSE
MANIFEST.in
docs/_static/custom.css
docs/_templates/layout.html
docs/conf.py.j2
noxfile.py.j2
renovate.json
setup.cfg
Running session blacken
Creating virtual environment (virtualenv) using python3.6 in .nox/blacken
pip install black==19.3b0
Error: pip is not installed into the virtualenv, it is located at /tmpfs/src/git/autosynth/env/bin/pip. Pass external=True into run() to explicitly allow this.
Session blacken failed.
synthtool > Failed executing nox -s blacken:
None
synthtool > Wrote metadata to synth.metadata.
Traceback (most recent call last):
File "/home/kbuilder/.pyenv/versions/3.6.1/lib/python3.6/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/home/kbuilder/.pyenv/versions/3.6.1/lib/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/__main__.py", line 99, in <module>
main()
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 764, in __call__
return self.main(*args, **kwargs)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 717, in main
rv = self.invoke(ctx)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/click/core.py", line 555, in invoke
return callback(*args, **kwargs)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/__main__.py", line 91, in main
spec.loader.exec_module(synth_module) # type: ignore
File "<frozen importlib._bootstrap_external>", line 678, in exec_module
File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
File "/tmpfs/src/git/autosynth/working_repo/synth.py", line 30, in <module>
s.shell.run(["nox", "-s", "blacken"], hide_output=False)
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/shell.py", line 39, in run
raise exc
File "/tmpfs/src/git/autosynth/env/lib/python3.6/site-packages/synthtool/shell.py", line 33, in run
encoding="utf-8",
File "/home/kbuilder/.pyenv/versions/3.6.1/lib/python3.6/subprocess.py", line 418, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['nox', '-s', 'blacken']' returned non-zero exit status 1.
Synthesis failed
Google internal developers can see the full log here.
"test.example.com", "CNAME", 3600, ["www.example.com"], zone
)
tests/unit/test_resource_record_set.py:31:
tests/unit/test_resource_record_set.py:26: in _make_one
return self._get_target_class()(*args, **kw)
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
def test_from_api_repr_missing_ttl(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:52:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
OS type and version: macOS Mojave (10.14.6 (18G5033))
Python version: Python 3.7.4
pip version: pip 20.2.3 from /Users/thadmegow/dev/google-cloud-dns/.venv/lib/python3.7/site-packages/pip (python 3.7)
google-cloud-dns version:
Version: 0.32.0
Summary: Google Cloud DNS API client library
Home-page: https://github.com/googleapis/python-dns
Author: Google LLC
Author-email: [email protected]
License: Apache 2.0
Location: /Users/thadmegow/dev/google-cloud-dns/.venv/lib/python3.7/site-packages
Requires: google-cloud-core
Required-by:
Steps to reproduce
Ensure authentication is properly setup (I'm using a Service Account)
Execute code below, substituting "my-project" for a valid projectID
Code example
fromgoogle.cloudimportdnsclient=dns.Client(project="my-project")
quotas=client.quotas() # API request
Stack trace
Traceback (most recent call last):
File "google-cloud-dns-search.py", line 3, in <module>
quotas = client.quotas() # API request
File "/Users/thadmegow/dev/google-cloud-dns/.venv/lib/python3.7/site-packages/google/cloud/dns/client.py", line 100, in quotas
key: int(value) for key, value in resp["quota"].items() if key != "kind"
File "/Users/thadmegow/dev/google-cloud-dns/.venv/lib/python3.7/site-packages/google/cloud/dns/client.py", line 100, in <dictcomp>
key: int(value) for key, value in resp["quota"].items() if key != "kind"
TypeError: int() argument must be a string, a bytes-like object or a number, not 'list'
def test_from_api_repr_missing_name(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:80:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
def test_from_api_repr_missing_name(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:80:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
def test_from_api_repr_missing_type(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:66:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
def test_from_api_repr_missing_rrdatas(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:43:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
def test_from_api_repr_missing_type(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:66:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
tests/unit/test__http.py:28: in _make_one
return self._get_target_class()(*args, **kw)
tests/unit/test__http.py:23: in _get_target_class
from google.cloud.dns._http import Connection
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
def test_from_api_repr_missing_type(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:66:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Is your feature request related to a problem? Please describe.
When operating against a list of zones, I have a situation where I'd like to be able to (e.g.) only operate on public zones.
Describe the solution you'd like
I'd like to be able to get public / private status (say, as zone.visibility) when listing zones in the Python API
For example, https://cloud.google.com/dns/docs/reference/v1/managedZones
lists visibility, however, list_zones() returns (e.g.) zone.name, but not zone.visibility.
Describe alternatives you've considered
Let me know if I need to make another call, but I'm assuming since list_zones returns objects of type ManagedZone that this should already be there if it's available.
def test_from_api_repr_missing_rrdatas(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:43:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
tests/unit/test__http.py:28: in _make_one
return self._get_target_class()(*args, **kw)
tests/unit/test__http.py:23: in _get_target_class
from google.cloud.dns._http import Connection
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Use case: if you need to update a resource record set you have to make a zone delete/create change operation, so you need the current record set to delete it. You have to get the full list and then cycle to get the one you need, if you have hundreds/thousands of record sets this is a waste.
"test.example.com", "CNAME", 3600, ["www.example.com"], zone
)
tests/unit/test_resource_record_set.py:31:
tests/unit/test_resource_record_set.py:26: in _make_one
return self._get_target_class()(*args, **kw)
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.
def test_from_api_repr_missing_ttl(self):
zone = _Zone()
klass = self._get_target_class()
tests/unit/test_resource_record_set.py:52:
tests/unit/test_resource_record_set.py:21: in _get_target_class
from google.cloud.dns.resource_record_set import ResourceRecordSet
google/cloud/dns/init.py:32: in
from google.cloud.dns.zone import Changes
"""Define API ManagedZones."""
import six
E ModuleNotFoundError: No module named 'six'
Many tests failed at the same time in this package.
I will close this issue when there are no more failures in this package and
there is at least one pass.
No new issues will be filed for this package until this issue is closed.
If there are already issues for individual test cases, I will close them when
the corresponding test passes. You can close them earlier, if you prefer, and
I won't reopen them while this issue is still open.