Skip to content

Commit

Permalink
chore: update formatting (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
yoshi-automation committed Aug 10, 2020
1 parent 96f3c62 commit 2395c0d
Show file tree
Hide file tree
Showing 17 changed files with 88 additions and 66 deletions.
6 changes: 3 additions & 3 deletions packages/grafeas/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
(master_doc, "grafeas.tex", u"grafeas Documentation", author, "manual")
(master_doc, "grafeas.tex", u"grafeas Documentation", author, "manual",)
]

# The name of an image file (relative to this directory) to place at the top of
Expand Down Expand Up @@ -283,7 +283,7 @@

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [(master_doc, "grafeas", u"grafeas Documentation", [author], 1)]
man_pages = [(master_doc, "grafeas", u"grafeas Documentation", [author], 1,)]

# If true, show URL addresses after external links.
# man_show_urls = False
Expand Down Expand Up @@ -323,7 +323,7 @@
intersphinx_mapping = {
"python": ("http://python.readthedocs.org/en/latest/", None),
"google-auth": ("https://google-auth.readthedocs.io/en/stable", None),
"google.api_core": ("https://googleapis.dev/python/google-api-core/latest/", None),
"google.api_core": ("https://googleapis.dev/python/google-api-core/latest/", None,),
"grpc": ("https://grpc.io/grpc/python/", None),
}

Expand Down
6 changes: 5 additions & 1 deletion packages/grafeas/grafeas/grafeas.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,8 @@
from grafeas.grafeas_v1 import types


__all__ = ("enums", "types", "GrafeasClient")
__all__ = (
"enums",
"types",
"GrafeasClient",
)
6 changes: 5 additions & 1 deletion packages/grafeas/grafeas/grafeas_v1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,8 @@ class GrafeasClient(grafeas_client.GrafeasClient):
enums = enums


__all__ = ("enums", "types", "GrafeasClient")
__all__ = (
"enums",
"types",
"GrafeasClient",
)
38 changes: 19 additions & 19 deletions packages/grafeas/grafeas/grafeas_v1/gapic/grafeas_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
from grafeas.grafeas_v1.proto import grafeas_pb2_grpc


_GAPIC_LIBRARY_VERSION = pkg_resources.get_distribution("grafeas").version
_GAPIC_LIBRARY_VERSION = pkg_resources.get_distribution("grafeas",).version


class GrafeasClient(object):
Expand Down Expand Up @@ -69,7 +69,7 @@ class GrafeasClient(object):
def note_path(cls, project, note):
"""Return a fully-qualified note string."""
return google.api_core.path_template.expand(
"projects/{project}/notes/{note}", project=project, note=note
"projects/{project}/notes/{note}", project=project, note=note,
)

@classmethod
Expand All @@ -85,7 +85,7 @@ def occurrence_path(cls, project, occurrence):
def project_path(cls, project):
"""Return a fully-qualified project string."""
return google.api_core.path_template.expand(
"projects/{project}", project=project
"projects/{project}", project=project,
)

def __init__(self, transport, client_config=None, client_info=None):
Expand Down Expand Up @@ -125,7 +125,7 @@ def __init__(self, transport, client_config=None, client_info=None):

if client_info is None:
client_info = google.api_core.gapic_v1.client_info.ClientInfo(
gapic_version=_GAPIC_LIBRARY_VERSION
gapic_version=_GAPIC_LIBRARY_VERSION,
)
else:
client_info.gapic_version = _GAPIC_LIBRARY_VERSION
Expand All @@ -136,7 +136,7 @@ def __init__(self, transport, client_config=None, client_info=None):
# (Ordinarily, these are the defaults specified in the `*_config.py`
# file next to this one.)
self._method_configs = google.api_core.gapic_v1.config.parse_method_configs(
client_config["interfaces"][self._INTERFACE_NAME]
client_config["interfaces"][self._INTERFACE_NAME],
)

# Save a dictionary of cached API call functions.
Expand Down Expand Up @@ -202,7 +202,7 @@ def get_occurrence(
client_info=self._client_info,
)

request = grafeas_pb2.GetOccurrenceRequest(name=name)
request = grafeas_pb2.GetOccurrenceRequest(name=name,)
if metadata is None:
metadata = []
metadata = list(metadata)
Expand Down Expand Up @@ -300,7 +300,7 @@ def list_occurrences(
)

request = grafeas_pb2.ListOccurrencesRequest(
parent=parent, filter=filter_, page_size=page_size
parent=parent, filter=filter_, page_size=page_size,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -385,7 +385,7 @@ def delete_occurrence(
client_info=self._client_info,
)

request = grafeas_pb2.DeleteOccurrenceRequest(name=name)
request = grafeas_pb2.DeleteOccurrenceRequest(name=name,)
if metadata is None:
metadata = []
metadata = list(metadata)
Expand Down Expand Up @@ -468,7 +468,7 @@ def create_occurrence(
)

request = grafeas_pb2.CreateOccurrenceRequest(
parent=parent, occurrence=occurrence
parent=parent, occurrence=occurrence,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -552,7 +552,7 @@ def batch_create_occurrences(
)

request = grafeas_pb2.BatchCreateOccurrencesRequest(
parent=parent, occurrences=occurrences
parent=parent, occurrences=occurrences,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -641,7 +641,7 @@ def update_occurrence(
)

request = grafeas_pb2.UpdateOccurrenceRequest(
name=name, occurrence=occurrence, update_mask=update_mask
name=name, occurrence=occurrence, update_mask=update_mask,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -717,7 +717,7 @@ def get_occurrence_note(
client_info=self._client_info,
)

request = grafeas_pb2.GetOccurrenceNoteRequest(name=name)
request = grafeas_pb2.GetOccurrenceNoteRequest(name=name,)
if metadata is None:
metadata = []
metadata = list(metadata)
Expand Down Expand Up @@ -791,7 +791,7 @@ def get_note(
client_info=self._client_info,
)

request = grafeas_pb2.GetNoteRequest(name=name)
request = grafeas_pb2.GetNoteRequest(name=name,)
if metadata is None:
metadata = []
metadata = list(metadata)
Expand Down Expand Up @@ -889,7 +889,7 @@ def list_notes(
)

request = grafeas_pb2.ListNotesRequest(
parent=parent, filter=filter_, page_size=page_size
parent=parent, filter=filter_, page_size=page_size,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -972,7 +972,7 @@ def delete_note(
client_info=self._client_info,
)

request = grafeas_pb2.DeleteNoteRequest(name=name)
request = grafeas_pb2.DeleteNoteRequest(name=name,)
if metadata is None:
metadata = []
metadata = list(metadata)
Expand Down Expand Up @@ -1060,7 +1060,7 @@ def create_note(
)

request = grafeas_pb2.CreateNoteRequest(
parent=parent, note_id=note_id, note=note
parent=parent, note_id=note_id, note=note,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -1143,7 +1143,7 @@ def batch_create_notes(
client_info=self._client_info,
)

request = grafeas_pb2.BatchCreateNotesRequest(parent=parent, notes=notes)
request = grafeas_pb2.BatchCreateNotesRequest(parent=parent, notes=notes,)
if metadata is None:
metadata = []
metadata = list(metadata)
Expand Down Expand Up @@ -1231,7 +1231,7 @@ def update_note(
)

request = grafeas_pb2.UpdateNoteRequest(
name=name, note=note, update_mask=update_mask
name=name, note=note, update_mask=update_mask,
)
if metadata is None:
metadata = []
Expand Down Expand Up @@ -1332,7 +1332,7 @@ def list_note_occurrences(
)

request = grafeas_pb2.ListNoteOccurrencesRequest(
name=name, filter=filter_, page_size=page_size
name=name, filter=filter_, page_size=page_size,
)
if metadata is None:
metadata = []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def __init__(self, address, scopes, channel=None, credentials=None):
# exception (channels come with credentials baked in already).
if channel is not None and credentials is not None:
raise ValueError(
"The `channel` and `credentials` arguments are mutually " "exclusive."
"The `channel` and `credentials` arguments are mutually " "exclusive.",
)

# Create the channel.
Expand All @@ -68,7 +68,9 @@ def __init__(self, address, scopes, channel=None, credentials=None):

# gRPC uses objects called "stubs" that are bound to the
# channel and provide a basic method for each RPC.
self._stubs = {"grafeas_stub": grafeas_pb2_grpc.GrafeasStub(channel)}
self._stubs = {
"grafeas_stub": grafeas_pb2_grpc.GrafeasStub(channel),
}

@classmethod
def create_channel(cls, address, scopes, credentials=None, **kwargs):
Expand Down
8 changes: 4 additions & 4 deletions packages/grafeas/grafeas/grafeas_v1/proto/attestation_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/grafeas/grafeas/grafeas_v1/proto/build_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions packages/grafeas/grafeas/grafeas_v1/proto/deployment_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/grafeas/grafeas/grafeas_v1/proto/discovery_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 2395c0d

Please sign in to comment.