Skip to content
Permalink
Browse files
chore: upgrade gapic-generator-python to 0.46.3 (#35)
fix: add async client to %name_%version/init.py

chore: add autogenerated snippets

chore: remove auth, policy, and options from the reserved names list

feat: support self-signed JWT flow for service accounts

chore: enable GAPIC metadata generation

chore: sort subpackages in %namespace/%name/init.py
  • Loading branch information
gcf-owl-bot committed May 20, 2021
1 parent c5b1e15 commit 879fd9014b358f220d47e381f2feac8fc931ea1e
Showing with 2,231 additions and 1,350 deletions.
  1. +0 −1 docs/retail_v2/catalog_service.rst
  2. +38 −38 google/cloud/retail/__init__.py
  3. +10 −3 google/cloud/retail_v2/__init__.py
  4. +195 −0 google/cloud/retail_v2/gapic_metadata.json
  5. +0 −1 google/cloud/retail_v2/services/__init__.py
  6. +0 −2 google/cloud/retail_v2/services/catalog_service/__init__.py
  7. +10 −22 google/cloud/retail_v2/services/catalog_service/async_client.py
  8. +34 −37 google/cloud/retail_v2/services/catalog_service/client.py
  9. +1 −3 google/cloud/retail_v2/services/catalog_service/pagers.py
  10. +0 −2 google/cloud/retail_v2/services/catalog_service/transports/__init__.py
  11. +84 −24 google/cloud/retail_v2/services/catalog_service/transports/base.py
  12. +11 −11 google/cloud/retail_v2/services/catalog_service/transports/grpc.py
  13. +11 −12 google/cloud/retail_v2/services/catalog_service/transports/grpc_asyncio.py
  14. +0 −2 google/cloud/retail_v2/services/prediction_service/__init__.py
  15. +8 −18 google/cloud/retail_v2/services/prediction_service/async_client.py
  16. +32 −31 google/cloud/retail_v2/services/prediction_service/client.py
  17. +0 −2 google/cloud/retail_v2/services/prediction_service/transports/__init__.py
  18. +82 −22 google/cloud/retail_v2/services/prediction_service/transports/base.py
  19. +11 −11 google/cloud/retail_v2/services/prediction_service/transports/grpc.py
  20. +11 −12 google/cloud/retail_v2/services/prediction_service/transports/grpc_asyncio.py
  21. +0 −2 google/cloud/retail_v2/services/product_service/__init__.py
  22. +12 −30 google/cloud/retail_v2/services/product_service/async_client.py
  23. +38 −49 google/cloud/retail_v2/services/product_service/client.py
  24. +0 −2 google/cloud/retail_v2/services/product_service/transports/__init__.py
  25. +91 −31 google/cloud/retail_v2/services/product_service/transports/base.py
  26. +17 −17 google/cloud/retail_v2/services/product_service/transports/grpc.py
  27. +17 −18 google/cloud/retail_v2/services/product_service/transports/grpc_asyncio.py
  28. +0 −2 google/cloud/retail_v2/services/user_event_service/__init__.py
  29. +12 −30 google/cloud/retail_v2/services/user_event_service/async_client.py
  30. +36 −43 google/cloud/retail_v2/services/user_event_service/client.py
  31. +0 −2 google/cloud/retail_v2/services/user_event_service/transports/__init__.py
  32. +91 −31 google/cloud/retail_v2/services/user_event_service/transports/base.py
  33. +23 −21 google/cloud/retail_v2/services/user_event_service/transports/grpc.py
  34. +22 −22 google/cloud/retail_v2/services/user_event_service/transports/grpc_asyncio.py
  35. +0 −2 google/cloud/retail_v2/types/__init__.py
  36. +4 −10 google/cloud/retail_v2/types/catalog.py
  37. +8 −13 google/cloud/retail_v2/types/catalog_service.py
  38. +13 −26 google/cloud/retail_v2/types/common.py
  39. +28 −52 google/cloud/retail_v2/types/import_config.py
  40. +13 −29 google/cloud/retail_v2/types/prediction_service.py
  41. +14 −29 google/cloud/retail_v2/types/product.py
  42. +8 −16 google/cloud/retail_v2/types/product_service.py
  43. +5 −10 google/cloud/retail_v2/types/purge_config.py
  44. +19 −43 google/cloud/retail_v2/types/user_event.py
  45. +8 −20 google/cloud/retail_v2/types/user_event_service.py
  46. +14 −17 scripts/fixup_retail_v2_keywords.py
  47. +1 −0 setup.py
  48. +2 −0 testing/constraints-3.6.txt
  49. +15 −0 tests/__init__.py
  50. +15 −0 tests/unit/__init__.py
  51. +15 −0 tests/unit/gapic/__init__.py
  52. +0 −1 tests/unit/gapic/retail_v2/__init__.py
  53. +285 −104 tests/unit/gapic/retail_v2/test_catalog_service.py
  54. +250 −67 tests/unit/gapic/retail_v2/test_prediction_service.py
  55. +328 −214 tests/unit/gapic/retail_v2/test_product_service.py
  56. +289 −143 tests/unit/gapic/retail_v2/test_user_event_service.py
@@ -5,7 +5,6 @@ CatalogService
:members:
:inherited-members:


.. automodule:: google.cloud.retail_v2.services.catalog_service.pagers
:members:
:inherited-members:
@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-

# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -15,26 +14,27 @@
# limitations under the License.
#

from google.cloud.retail_v2.services.catalog_service.client import CatalogServiceClient
from google.cloud.retail_v2.services.catalog_service.async_client import (
CatalogServiceAsyncClient,
)
from google.cloud.retail_v2.services.catalog_service.client import CatalogServiceClient
from google.cloud.retail_v2.services.prediction_service.async_client import (
PredictionServiceAsyncClient,
)
from google.cloud.retail_v2.services.prediction_service.client import (
PredictionServiceClient,
)
from google.cloud.retail_v2.services.product_service.async_client import (
ProductServiceAsyncClient,
from google.cloud.retail_v2.services.prediction_service.async_client import (
PredictionServiceAsyncClient,
)
from google.cloud.retail_v2.services.product_service.client import ProductServiceClient
from google.cloud.retail_v2.services.user_event_service.async_client import (
UserEventServiceAsyncClient,
from google.cloud.retail_v2.services.product_service.async_client import (
ProductServiceAsyncClient,
)
from google.cloud.retail_v2.services.user_event_service.client import (
UserEventServiceClient,
)
from google.cloud.retail_v2.services.user_event_service.async_client import (
UserEventServiceAsyncClient,
)

from google.cloud.retail_v2.types.catalog import Catalog
from google.cloud.retail_v2.types.catalog import ProductLevelConfig
from google.cloud.retail_v2.types.catalog_service import ListCatalogsRequest
@@ -77,52 +77,52 @@
from google.cloud.retail_v2.types.user_event_service import WriteUserEventRequest

__all__ = (
"BigQuerySource",
"Catalog",
"CatalogServiceAsyncClient",
"CatalogServiceClient",
"CollectUserEventRequest",
"CreateProductRequest",
"CatalogServiceAsyncClient",
"PredictionServiceClient",
"PredictionServiceAsyncClient",
"ProductServiceClient",
"ProductServiceAsyncClient",
"UserEventServiceClient",
"UserEventServiceAsyncClient",
"Catalog",
"ProductLevelConfig",
"ListCatalogsRequest",
"ListCatalogsResponse",
"UpdateCatalogRequest",
"CustomAttribute",
"DeleteProductRequest",
"GcsSource",
"GetProductRequest",
"Image",
"PriceInfo",
"UserInfo",
"BigQuerySource",
"GcsSource",
"ImportErrorsConfig",
"ImportMetadata",
"ImportProductsRequest",
"ImportProductsResponse",
"ImportUserEventsRequest",
"ImportUserEventsResponse",
"ListCatalogsRequest",
"ListCatalogsResponse",
"ProductInlineSource",
"ProductInputConfig",
"UserEventImportSummary",
"UserEventInlineSource",
"UserEventInputConfig",
"PredictRequest",
"PredictResponse",
"PredictionServiceAsyncClient",
"PredictionServiceClient",
"PriceInfo",
"Product",
"ProductDetail",
"ProductInlineSource",
"ProductInputConfig",
"ProductLevelConfig",
"ProductServiceAsyncClient",
"ProductServiceClient",
"PurchaseTransaction",
"CreateProductRequest",
"DeleteProductRequest",
"GetProductRequest",
"UpdateProductRequest",
"PurgeMetadata",
"PurgeUserEventsRequest",
"PurgeUserEventsResponse",
"ProductDetail",
"PurchaseTransaction",
"UserEvent",
"CollectUserEventRequest",
"RejoinUserEventsMetadata",
"RejoinUserEventsRequest",
"RejoinUserEventsResponse",
"UpdateCatalogRequest",
"UpdateProductRequest",
"UserEvent",
"UserEventImportSummary",
"UserEventInlineSource",
"UserEventInputConfig",
"UserEventServiceAsyncClient",
"UserEventServiceClient",
"UserInfo",
"WriteUserEventRequest",
)
@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-

# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -16,9 +15,14 @@
#

from .services.catalog_service import CatalogServiceClient
from .services.catalog_service import CatalogServiceAsyncClient
from .services.prediction_service import PredictionServiceClient
from .services.prediction_service import PredictionServiceAsyncClient
from .services.product_service import ProductServiceClient
from .services.product_service import ProductServiceAsyncClient
from .services.user_event_service import UserEventServiceClient
from .services.user_event_service import UserEventServiceAsyncClient

from .types.catalog import Catalog
from .types.catalog import ProductLevelConfig
from .types.catalog_service import ListCatalogsRequest
@@ -60,8 +64,11 @@
from .types.user_event_service import RejoinUserEventsResponse
from .types.user_event_service import WriteUserEventRequest


__all__ = (
"CatalogServiceAsyncClient",
"PredictionServiceAsyncClient",
"ProductServiceAsyncClient",
"UserEventServiceAsyncClient",
"BigQuerySource",
"Catalog",
"CatalogServiceClient",
@@ -103,7 +110,7 @@
"UserEventImportSummary",
"UserEventInlineSource",
"UserEventInputConfig",
"UserEventServiceClient",
"UserInfo",
"WriteUserEventRequest",
"UserEventServiceClient",
)
@@ -0,0 +1,195 @@
{
"comment": "This file maps proto services/RPCs to the corresponding library clients/methods",
"language": "python",
"libraryPackage": "google.cloud.retail_v2",
"protoPackage": "google.cloud.retail.v2",
"schema": "1.0",
"services": {
"CatalogService": {
"clients": {
"grpc": {
"libraryClient": "CatalogServiceClient",
"rpcs": {
"ListCatalogs": {
"methods": [
"list_catalogs"
]
},
"UpdateCatalog": {
"methods": [
"update_catalog"
]
}
}
},
"grpc-async": {
"libraryClient": "CatalogServiceAsyncClient",
"rpcs": {
"ListCatalogs": {
"methods": [
"list_catalogs"
]
},
"UpdateCatalog": {
"methods": [
"update_catalog"
]
}
}
}
}
},
"PredictionService": {
"clients": {
"grpc": {
"libraryClient": "PredictionServiceClient",
"rpcs": {
"Predict": {
"methods": [
"predict"
]
}
}
},
"grpc-async": {
"libraryClient": "PredictionServiceAsyncClient",
"rpcs": {
"Predict": {
"methods": [
"predict"
]
}
}
}
}
},
"ProductService": {
"clients": {
"grpc": {
"libraryClient": "ProductServiceClient",
"rpcs": {
"CreateProduct": {
"methods": [
"create_product"
]
},
"DeleteProduct": {
"methods": [
"delete_product"
]
},
"GetProduct": {
"methods": [
"get_product"
]
},
"ImportProducts": {
"methods": [
"import_products"
]
},
"UpdateProduct": {
"methods": [
"update_product"
]
}
}
},
"grpc-async": {
"libraryClient": "ProductServiceAsyncClient",
"rpcs": {
"CreateProduct": {
"methods": [
"create_product"
]
},
"DeleteProduct": {
"methods": [
"delete_product"
]
},
"GetProduct": {
"methods": [
"get_product"
]
},
"ImportProducts": {
"methods": [
"import_products"
]
},
"UpdateProduct": {
"methods": [
"update_product"
]
}
}
}
}
},
"UserEventService": {
"clients": {
"grpc": {
"libraryClient": "UserEventServiceClient",
"rpcs": {
"CollectUserEvent": {
"methods": [
"collect_user_event"
]
},
"ImportUserEvents": {
"methods": [
"import_user_events"
]
},
"PurgeUserEvents": {
"methods": [
"purge_user_events"
]
},
"RejoinUserEvents": {
"methods": [
"rejoin_user_events"
]
},
"WriteUserEvent": {
"methods": [
"write_user_event"
]
}
}
},
"grpc-async": {
"libraryClient": "UserEventServiceAsyncClient",
"rpcs": {
"CollectUserEvent": {
"methods": [
"collect_user_event"
]
},
"ImportUserEvents": {
"methods": [
"import_user_events"
]
},
"PurgeUserEvents": {
"methods": [
"purge_user_events"
]
},
"RejoinUserEvents": {
"methods": [
"rejoin_user_events"
]
},
"WriteUserEvent": {
"methods": [
"write_user_event"
]
}
}
}
}
}
}
}
@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-

# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-

# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -14,7 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#

from .client import CatalogServiceClient
from .async_client import CatalogServiceAsyncClient

Loading

0 comments on commit 879fd90

Please sign in to comment.