From 61e0b63e8f02ba054baef242fec593a28e753dc2 Mon Sep 17 00:00:00 2001 From: Anthonios Partheniou Date: Thu, 25 May 2023 16:30:54 +0000 Subject: [PATCH] regenerate client with workarounds removed --- .../vision_v1/services/image_annotator/client.py | 12 ------------ .../services/image_annotator/client.py | 3 --- .../services/image_annotator/client.py | 6 ------ .../services/image_annotator/client.py | 6 ------ .../services/image_annotator/client.py | 12 ------------ .../snippet_metadata_google.cloud.vision.v1.json | 2 +- ...ippet_metadata_google.cloud.vision.v1p1beta1.json | 2 +- ...ippet_metadata_google.cloud.vision.v1p2beta1.json | 2 +- ...ippet_metadata_google.cloud.vision.v1p3beta1.json | 2 +- ...ippet_metadata_google.cloud.vision.v1p4beta1.json | 2 +- 10 files changed, 5 insertions(+), 44 deletions(-) diff --git a/google/cloud/vision_v1/services/image_annotator/client.py b/google/cloud/vision_v1/services/image_annotator/client.py index f4f30a06..f9d96c7c 100644 --- a/google/cloud/vision_v1/services/image_annotator/client.py +++ b/google/cloud/vision_v1/services/image_annotator/client.py @@ -551,9 +551,6 @@ def sample_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateImagesRequest): request = image_annotator.BatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -658,9 +655,6 @@ def sample_batch_annotate_files(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateFilesRequest): request = image_annotator.BatchAnnotateFilesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateFileRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -786,9 +780,6 @@ def sample_async_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.AsyncBatchAnnotateImagesRequest): request = image_annotator.AsyncBatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -914,9 +905,6 @@ def sample_async_batch_annotate_files(): # there are no flattened fields. if not isinstance(request, image_annotator.AsyncBatchAnnotateFilesRequest): request = image_annotator.AsyncBatchAnnotateFilesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AsyncAnnotateFileRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: diff --git a/google/cloud/vision_v1p1beta1/services/image_annotator/client.py b/google/cloud/vision_v1p1beta1/services/image_annotator/client.py index 1b42e920..31d786e3 100644 --- a/google/cloud/vision_v1p1beta1/services/image_annotator/client.py +++ b/google/cloud/vision_v1p1beta1/services/image_annotator/client.py @@ -503,9 +503,6 @@ def sample_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateImagesRequest): request = image_annotator.BatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: diff --git a/google/cloud/vision_v1p2beta1/services/image_annotator/client.py b/google/cloud/vision_v1p2beta1/services/image_annotator/client.py index efa9c4a6..665437e1 100644 --- a/google/cloud/vision_v1p2beta1/services/image_annotator/client.py +++ b/google/cloud/vision_v1p2beta1/services/image_annotator/client.py @@ -505,9 +505,6 @@ def sample_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateImagesRequest): request = image_annotator.BatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -621,9 +618,6 @@ def sample_async_batch_annotate_files(): # there are no flattened fields. if not isinstance(request, image_annotator.AsyncBatchAnnotateFilesRequest): request = image_annotator.AsyncBatchAnnotateFilesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AsyncAnnotateFileRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: diff --git a/google/cloud/vision_v1p3beta1/services/image_annotator/client.py b/google/cloud/vision_v1p3beta1/services/image_annotator/client.py index b2ef2b1c..37f31d03 100644 --- a/google/cloud/vision_v1p3beta1/services/image_annotator/client.py +++ b/google/cloud/vision_v1p3beta1/services/image_annotator/client.py @@ -551,9 +551,6 @@ def sample_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateImagesRequest): request = image_annotator.BatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -667,9 +664,6 @@ def sample_async_batch_annotate_files(): # there are no flattened fields. if not isinstance(request, image_annotator.AsyncBatchAnnotateFilesRequest): request = image_annotator.AsyncBatchAnnotateFilesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AsyncAnnotateFileRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: diff --git a/google/cloud/vision_v1p4beta1/services/image_annotator/client.py b/google/cloud/vision_v1p4beta1/services/image_annotator/client.py index 9d5a9e1e..b857ef9a 100644 --- a/google/cloud/vision_v1p4beta1/services/image_annotator/client.py +++ b/google/cloud/vision_v1p4beta1/services/image_annotator/client.py @@ -551,9 +551,6 @@ def sample_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateImagesRequest): request = image_annotator.BatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -658,9 +655,6 @@ def sample_batch_annotate_files(): # there are no flattened fields. if not isinstance(request, image_annotator.BatchAnnotateFilesRequest): request = image_annotator.BatchAnnotateFilesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateFileRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -786,9 +780,6 @@ def sample_async_batch_annotate_images(): # there are no flattened fields. if not isinstance(request, image_annotator.AsyncBatchAnnotateImagesRequest): request = image_annotator.AsyncBatchAnnotateImagesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AnnotateImageRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: @@ -914,9 +905,6 @@ def sample_async_batch_annotate_files(): # there are no flattened fields. if not isinstance(request, image_annotator.AsyncBatchAnnotateFilesRequest): request = image_annotator.AsyncBatchAnnotateFilesRequest(request) - if requests is not None: - for i in range(len(requests)): - requests[i] = image_annotator.AsyncAnnotateFileRequest(requests[i]) # If we have keyword arguments corresponding to fields on the # request, apply these. if requests is not None: diff --git a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1.json b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1.json index e4f113a7..e29e0ec2 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-vision", - "version": "3.4.1" + "version": "0.1.0" }, "snippets": [ { diff --git a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p1beta1.json b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p1beta1.json index 47dc4134..70f20c5e 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p1beta1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p1beta1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-vision", - "version": "3.4.1" + "version": "0.1.0" }, "snippets": [ { diff --git a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p2beta1.json b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p2beta1.json index 5428660b..52e22f36 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p2beta1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p2beta1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-vision", - "version": "3.4.1" + "version": "0.1.0" }, "snippets": [ { diff --git a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p3beta1.json b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p3beta1.json index 404722cf..2dae915e 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p3beta1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p3beta1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-vision", - "version": "3.4.1" + "version": "0.1.0" }, "snippets": [ { diff --git a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p4beta1.json b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p4beta1.json index 4a02eef9..a1201ce4 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p4beta1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.vision.v1p4beta1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-vision", - "version": "3.4.1" + "version": "0.1.0" }, "snippets": [ {