Skip to content

Commit 045bc42

Browse files
committed
Replace types string with str.
Uses command: ag -l 'type ([^:]+): string' | \ xargs gsed -r -i.bak -e 's/type ([^:]+): string/type \1: str/g' Note: [-r for gsed (GNU sed) is needed for group matching](http://superuser.com/a/336819/125262).
1 parent c2bcd4e commit 045bc42

File tree

4 files changed

+16
-16
lines changed

4 files changed

+16
-16
lines changed

packages/google-cloud-dns/google/cloud/dns/changes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def name(self):
9393
def name(self, value):
9494
"""Update name of the change set.
9595
96-
:type value: string
96+
:type value: str
9797
:param value: New name for the changeset.
9898
"""
9999
if not isinstance(value, six.string_types):

packages/google-cloud-dns/google/cloud/dns/client.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
class Client(JSONClient):
2525
"""Client to bundle configuration needed for API requests.
2626
27-
:type project: string
27+
:type project: str
2828
:param project: the project which the client acts on behalf of. Will be
2929
passed when creating a zone. If not passed,
3030
falls back to the default inferred from the environment.
@@ -88,14 +88,14 @@ def list_zones(self, max_results=None, page_token=None):
8888
def zone(self, name, dns_name=None, description=None):
8989
"""Construct a zone bound to this client.
9090
91-
:type name: string
91+
:type name: str
9292
:param name: Name of the zone.
9393
94-
:type dns_name: string or :class:`NoneType`
94+
:type dns_name: str or :class:`NoneType`
9595
:param dns_name: DNS name of the zone. If not passed, then calls
9696
to :meth:`zone.create` will fail.
9797
98-
:type description: string or :class:`NoneType`
98+
:type description: str or :class:`NoneType`
9999
:param description: the description for the zone. If not passed,
100100
defaults to the value of 'dns_name'.
101101

packages/google-cloud-dns/google/cloud/dns/resource_record_set.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ class ResourceRecordSet(object):
2323
See:
2424
https://cloud.google.com/dns/api/v1/resourceRecordSets
2525
26-
:type name: string
26+
:type name: str
2727
:param name: the name of the record set.
2828
29-
:type record_type: string
29+
:type record_type: str
3030
:param record_type: the RR type of the zone.
3131
3232
:type ttl: integer

packages/google-cloud-dns/google/cloud/dns/zone.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -29,18 +29,18 @@ class ManagedZone(object):
2929
See:
3030
https://cloud.google.com/dns/api/v1/managedZones
3131
32-
:type name: string
32+
:type name: str
3333
:param name: the name of the zone
3434
35-
:type dns_name: string or :class:`NoneType`
35+
:type dns_name: str or :class:`NoneType`
3636
:param dns_name: the DNS name of the zone. If not passed, then calls
3737
to :meth:`create` will fail.
3838
3939
:type client: :class:`google.cloud.dns.client.Client`
4040
:param client: A client which holds credentials and project configuration
4141
for the zone (which requires a project).
4242
43-
:type description: string or :class:`NoneType`
43+
:type description: str or :class:`NoneType`
4444
:param description: the description for the zone. If not passed, defaults
4545
to the value of 'dns_name'.
4646
"""
@@ -135,7 +135,7 @@ def description(self):
135135
def description(self, value):
136136
"""Update description of the zone.
137137
138-
:type value: string, or ``NoneType``
138+
:type value: str, or ``NoneType``
139139
:param value: new description
140140
141141
:raises: ValueError for invalid value types.
@@ -162,7 +162,7 @@ def name_server_set(self):
162162
def name_server_set(self, value):
163163
"""Update named set of DNS name servers.
164164
165-
:type value: string, or ``NoneType``
165+
:type value: str, or ``NoneType``
166166
:param value: new title
167167
168168
:raises: ValueError for invalid value types.
@@ -174,10 +174,10 @@ def name_server_set(self, value):
174174
def resource_record_set(self, name, record_type, ttl, rrdatas):
175175
"""Construct a resource record set bound to this zone.
176176
177-
:type name: string
177+
:type name: str
178178
:param name: Name of the record set.
179179
180-
:type record_type: string
180+
:type record_type: str
181181
:param record_type: RR type
182182
183183
:type ttl: integer
@@ -323,7 +323,7 @@ def list_resource_record_sets(self, max_results=None, page_token=None,
323323
:param max_results: maximum number of zones to return, If not
324324
passed, defaults to a value set by the API.
325325
326-
:type page_token: string
326+
:type page_token: str
327327
:param page_token: opaque marker for the next "page" of zones. If
328328
not passed, the API will return the first page of
329329
zones.
@@ -356,7 +356,7 @@ def list_changes(self, max_results=None, page_token=None, client=None):
356356
:param max_results: maximum number of zones to return, If not
357357
passed, defaults to a value set by the API.
358358
359-
:type page_token: string
359+
:type page_token: str
360360
:param page_token: opaque marker for the next "page" of zones. If
361361
not passed, the API will return the first page of
362362
zones.

0 commit comments

Comments
 (0)