Skip to content
This repository has been archived by the owner on Dec 31, 2023. It is now read-only.

Commit

Permalink
chore: use gapic-generator-python 0.53.4 (#121)
Browse files Browse the repository at this point in the history
- [ ] Regenerate this pull request now.

docs: list oneofs in docstring
fix(deps): require google-api-core >= 1.28.0
fix(deps): drop packaging dependency

committer: busunkim96@
PiperOrigin-RevId: 406468269

Source-Link: googleapis/googleapis@83d81b0

Source-Link: googleapis/googleapis-gen@2ff001f
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMmZmMDAxZmJhY2I5ZTc3ZTcxZDczNGRlNWY5NTVjMDVmZGFlODUyNiJ9
  • Loading branch information
gcf-owl-bot[bot] committed Nov 1, 2021
1 parent 46dfc6f commit b90b6fe
Show file tree
Hide file tree
Showing 9 changed files with 131 additions and 161 deletions.
88 changes: 45 additions & 43 deletions grafeas/grafeas_v1/services/grafeas/async_client.py
Expand Up @@ -19,13 +19,15 @@
from typing import Dict, Sequence, Tuple, Type, Union
import pkg_resources

import google.api_core.client_options as ClientOptions # type: ignore
from google.api_core.client_options import ClientOptions # type: ignore
from google.api_core import exceptions as core_exceptions # type: ignore
from google.api_core import gapic_v1 # type: ignore
from google.api_core import retry as retries # type: ignore
from google.auth import credentials as ga_credentials # type: ignore
from google.oauth2 import service_account # type: ignore

OptionalRetry = Union[retries.Retry, object]

from google.protobuf import field_mask_pb2 # type: ignore
from google.protobuf import timestamp_pb2 # type: ignore
from grafeas.grafeas_v1.services.grafeas import pagers
Expand Down Expand Up @@ -134,17 +136,17 @@ def __init__(

async def get_occurrence(
self,
request: grafeas.GetOccurrenceRequest = None,
request: Union[grafeas.GetOccurrenceRequest, dict] = None,
*,
name: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Occurrence:
r"""Gets the specified occurrence.
Args:
request (:class:`grafeas.grafeas_v1.types.GetOccurrenceRequest`):
request (Union[grafeas.grafeas_v1.types.GetOccurrenceRequest, dict]):
The request object. Request to get an occurrence.
name (:class:`str`):
The name of the occurrence in the form of
Expand Down Expand Up @@ -214,18 +216,18 @@ async def get_occurrence(

async def list_occurrences(
self,
request: grafeas.ListOccurrencesRequest = None,
request: Union[grafeas.ListOccurrencesRequest, dict] = None,
*,
parent: str = None,
filter: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> pagers.ListOccurrencesAsyncPager:
r"""Lists occurrences for the specified project.
Args:
request (:class:`grafeas.grafeas_v1.types.ListOccurrencesRequest`):
request (Union[grafeas.grafeas_v1.types.ListOccurrencesRequest, dict]):
The request object. Request to list occurrences.
parent (:class:`str`):
The name of the project to list occurrences for in the
Expand Down Expand Up @@ -310,10 +312,10 @@ async def list_occurrences(

async def delete_occurrence(
self,
request: grafeas.DeleteOccurrenceRequest = None,
request: Union[grafeas.DeleteOccurrenceRequest, dict] = None,
*,
name: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> None:
Expand All @@ -322,7 +324,7 @@ async def delete_occurrence(
is no longer applicable for the given resource.
Args:
request (:class:`grafeas.grafeas_v1.types.DeleteOccurrenceRequest`):
request (Union[grafeas.grafeas_v1.types.DeleteOccurrenceRequest, dict]):
The request object. Request to delete an occurrence.
name (:class:`str`):
The name of the occurrence in the form of
Expand Down Expand Up @@ -385,18 +387,18 @@ async def delete_occurrence(

async def create_occurrence(
self,
request: grafeas.CreateOccurrenceRequest = None,
request: Union[grafeas.CreateOccurrenceRequest, dict] = None,
*,
parent: str = None,
occurrence: grafeas.Occurrence = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Occurrence:
r"""Creates a new occurrence.
Args:
request (:class:`grafeas.grafeas_v1.types.CreateOccurrenceRequest`):
request (Union[grafeas.grafeas_v1.types.CreateOccurrenceRequest, dict]):
The request object. Request to create a new occurrence.
parent (:class:`str`):
The name of the project in the form of
Expand Down Expand Up @@ -464,18 +466,18 @@ async def create_occurrence(

async def batch_create_occurrences(
self,
request: grafeas.BatchCreateOccurrencesRequest = None,
request: Union[grafeas.BatchCreateOccurrencesRequest, dict] = None,
*,
parent: str = None,
occurrences: Sequence[grafeas.Occurrence] = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.BatchCreateOccurrencesResponse:
r"""Creates new occurrences in batch.
Args:
request (:class:`grafeas.grafeas_v1.types.BatchCreateOccurrencesRequest`):
request (Union[grafeas.grafeas_v1.types.BatchCreateOccurrencesRequest, dict]):
The request object. Request to create occurrences in
batch.
parent (:class:`str`):
Expand Down Expand Up @@ -546,19 +548,19 @@ async def batch_create_occurrences(

async def update_occurrence(
self,
request: grafeas.UpdateOccurrenceRequest = None,
request: Union[grafeas.UpdateOccurrenceRequest, dict] = None,
*,
name: str = None,
occurrence: grafeas.Occurrence = None,
update_mask: field_mask_pb2.FieldMask = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Occurrence:
r"""Updates the specified occurrence.
Args:
request (:class:`grafeas.grafeas_v1.types.UpdateOccurrenceRequest`):
request (Union[grafeas.grafeas_v1.types.UpdateOccurrenceRequest, dict]):
The request object. Request to update an occurrence.
name (:class:`str`):
The name of the occurrence in the form of
Expand Down Expand Up @@ -632,10 +634,10 @@ async def update_occurrence(

async def get_occurrence_note(
self,
request: grafeas.GetOccurrenceNoteRequest = None,
request: Union[grafeas.GetOccurrenceNoteRequest, dict] = None,
*,
name: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Note:
Expand All @@ -644,7 +646,7 @@ async def get_occurrence_note(
belongs to a provider project.
Args:
request (:class:`grafeas.grafeas_v1.types.GetOccurrenceNoteRequest`):
request (Union[grafeas.grafeas_v1.types.GetOccurrenceNoteRequest, dict]):
The request object. Request to get the note to which the
specified occurrence is attached.
name (:class:`str`):
Expand Down Expand Up @@ -715,17 +717,17 @@ async def get_occurrence_note(

async def get_note(
self,
request: grafeas.GetNoteRequest = None,
request: Union[grafeas.GetNoteRequest, dict] = None,
*,
name: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Note:
r"""Gets the specified note.
Args:
request (:class:`grafeas.grafeas_v1.types.GetNoteRequest`):
request (Union[grafeas.grafeas_v1.types.GetNoteRequest, dict]):
The request object. Request to get a note.
name (:class:`str`):
The name of the note in the form of
Expand Down Expand Up @@ -795,18 +797,18 @@ async def get_note(

async def list_notes(
self,
request: grafeas.ListNotesRequest = None,
request: Union[grafeas.ListNotesRequest, dict] = None,
*,
parent: str = None,
filter: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> pagers.ListNotesAsyncPager:
r"""Lists notes for the specified project.
Args:
request (:class:`grafeas.grafeas_v1.types.ListNotesRequest`):
request (Union[grafeas.grafeas_v1.types.ListNotesRequest, dict]):
The request object. Request to list notes.
parent (:class:`str`):
The name of the project to list notes for in the form of
Expand Down Expand Up @@ -891,17 +893,17 @@ async def list_notes(

async def delete_note(
self,
request: grafeas.DeleteNoteRequest = None,
request: Union[grafeas.DeleteNoteRequest, dict] = None,
*,
name: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> None:
r"""Deletes the specified note.
Args:
request (:class:`grafeas.grafeas_v1.types.DeleteNoteRequest`):
request (Union[grafeas.grafeas_v1.types.DeleteNoteRequest, dict]):
The request object. Request to delete a note.
name (:class:`str`):
The name of the note in the form of
Expand Down Expand Up @@ -964,19 +966,19 @@ async def delete_note(

async def create_note(
self,
request: grafeas.CreateNoteRequest = None,
request: Union[grafeas.CreateNoteRequest, dict] = None,
*,
parent: str = None,
note_id: str = None,
note: grafeas.Note = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Note:
r"""Creates a new note.
Args:
request (:class:`grafeas.grafeas_v1.types.CreateNoteRequest`):
request (Union[grafeas.grafeas_v1.types.CreateNoteRequest, dict]):
The request object. Request to create a new note.
parent (:class:`str`):
The name of the project in the form of
Expand Down Expand Up @@ -1051,18 +1053,18 @@ async def create_note(

async def batch_create_notes(
self,
request: grafeas.BatchCreateNotesRequest = None,
request: Union[grafeas.BatchCreateNotesRequest, dict] = None,
*,
parent: str = None,
notes: Sequence[grafeas.BatchCreateNotesRequest.NotesEntry] = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.BatchCreateNotesResponse:
r"""Creates new notes in batch.
Args:
request (:class:`grafeas.grafeas_v1.types.BatchCreateNotesRequest`):
request (Union[grafeas.grafeas_v1.types.BatchCreateNotesRequest, dict]):
The request object. Request to create notes in batch.
parent (:class:`str`):
The name of the project in the form of
Expand Down Expand Up @@ -1131,19 +1133,19 @@ async def batch_create_notes(

async def update_note(
self,
request: grafeas.UpdateNoteRequest = None,
request: Union[grafeas.UpdateNoteRequest, dict] = None,
*,
name: str = None,
note: grafeas.Note = None,
update_mask: field_mask_pb2.FieldMask = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> grafeas.Note:
r"""Updates the specified note.
Args:
request (:class:`grafeas.grafeas_v1.types.UpdateNoteRequest`):
request (Union[grafeas.grafeas_v1.types.UpdateNoteRequest, dict]):
The request object. Request to update a note.
name (:class:`str`):
The name of the note in the form of
Expand Down Expand Up @@ -1217,11 +1219,11 @@ async def update_note(

async def list_note_occurrences(
self,
request: grafeas.ListNoteOccurrencesRequest = None,
request: Union[grafeas.ListNoteOccurrencesRequest, dict] = None,
*,
name: str = None,
filter: str = None,
retry: retries.Retry = gapic_v1.method.DEFAULT,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> pagers.ListNoteOccurrencesAsyncPager:
Expand All @@ -1231,7 +1233,7 @@ async def list_note_occurrences(
specified note.
Args:
request (:class:`grafeas.grafeas_v1.types.ListNoteOccurrencesRequest`):
request (Union[grafeas.grafeas_v1.types.ListNoteOccurrencesRequest, dict]):
The request object. Request to list occurrences for a
note.
name (:class:`str`):
Expand Down

0 comments on commit b90b6fe

Please sign in to comment.