From f42abbe31d386bd6ee03159dbc04b4c50bc91e4c Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Mon, 11 Oct 2021 20:49:53 +0200 Subject: [PATCH 1/6] chore(deps): update dependency google-analytics-data to v0.9.0 (#151) --- samples/snippets/requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/snippets/requirements.txt b/samples/snippets/requirements.txt index 3d7a7ed..eac014f 100644 --- a/samples/snippets/requirements.txt +++ b/samples/snippets/requirements.txt @@ -1,2 +1,2 @@ -google-analytics-data==0.8.1 +google-analytics-data==0.9.0 google-auth-oauthlib==0.4.6 \ No newline at end of file From f431414f8d248edd1926ac02b4570bd0eaebbf50 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Thu, 21 Oct 2021 12:40:55 -0400 Subject: [PATCH 2/6] chore(python): modify templated noxfile to support non-cloud APIs (#153) Source-Link: https://github.com/googleapis/synthtool/commit/76d5fec7a9e77a12c28654b333103578623a0c1b Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:979d9498e07c50097c1aeda937dcd32094ecc7440278a83e832b6a05602f62b6 Co-authored-by: Owl Bot --- .github/.OwlBot.lock.yaml | 2 +- noxfile.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 7d98291..4423944 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest - digest: sha256:58f73ba196b5414782605236dd0712a73541b44ff2ff4d3a36ec41092dd6fa5b + digest: sha256:979d9498e07c50097c1aeda937dcd32094ecc7440278a83e832b6a05602f62b6 diff --git a/noxfile.py b/noxfile.py index 173f966..de41c6b 100644 --- a/noxfile.py +++ b/noxfile.py @@ -101,7 +101,7 @@ def default(session): "py.test", "--quiet", f"--junitxml=unit_{session.python}_sponge_log.xml", - "--cov=google.analytics", + "--cov=google", "--cov=tests/unit", "--cov-append", "--cov-config=.coveragerc", From a7e437ebafe7d91f197b2bb4d6b4eabfbf6d4c9e Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 25 Oct 2021 17:11:07 -0400 Subject: [PATCH 3/6] chore(python): push cloud library docs to staging bucket for Cloud RAD (#154) Source-Link: https://github.com/googleapis/synthtool/commit/7fd61f8efae782a7cfcecc599faf52f9737fe584 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:4ee57a76a176ede9087c14330c625a71553cf9c72828b2c0ca12f5338171ba60 Co-authored-by: Owl Bot --- .github/.OwlBot.lock.yaml | 2 +- .kokoro/docs/common.cfg | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 4423944..108063d 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest - digest: sha256:979d9498e07c50097c1aeda937dcd32094ecc7440278a83e832b6a05602f62b6 + digest: sha256:4ee57a76a176ede9087c14330c625a71553cf9c72828b2c0ca12f5338171ba60 diff --git a/.kokoro/docs/common.cfg b/.kokoro/docs/common.cfg index 55bb9de..10c3260 100644 --- a/.kokoro/docs/common.cfg +++ b/.kokoro/docs/common.cfg @@ -30,6 +30,8 @@ env_vars: { env_vars: { key: "V2_STAGING_BUCKET" + # Push non-cloud library docs to `docs-staging-v2-staging` instead of the + # Cloud RAD bucket `docs-staging-v2` value: "docs-staging-v2-staging" } From 1f81d4eacc5f00bd6666fb4437aed9b78b3cd761 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 1 Nov 2021 15:16:13 +0000 Subject: [PATCH 4/6] chore: use gapic-generator-python 0.53.4 (#155) - [ ] Regenerate this pull request now. docs: list oneofs in docstring fix(deps): require google-api-core >= 1.28.0 committer: busunkim96@ PiperOrigin-RevId: 406468269 Source-Link: https://github.com/googleapis/googleapis/commit/83d81b0c8fc22291a13398d6d77f02dc97a5b6f4 Source-Link: https://github.com/googleapis/googleapis-gen/commit/2ff001fbacb9e77e71d734de5f955c05fdae8526 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMmZmMDAxZmJhY2I5ZTc3ZTcxZDczNGRlNWY5NTVjMDVmZGFlODUyNiJ9 --- .../beta_analytics_data/async_client.py | 46 ++++---- .../services/beta_analytics_data/client.py | 16 +-- .../beta_analytics_data/transports/base.py | 35 +----- .../transports/grpc_asyncio.py | 1 - google/analytics/data_v1beta/types/data.py | 63 +++++++++++ setup.py | 2 +- testing/constraints-3.6.txt | 3 +- .../data_v1beta/test_beta_analytics_data.py | 100 ++---------------- 8 files changed, 108 insertions(+), 158 deletions(-) diff --git a/google/analytics/data_v1beta/services/beta_analytics_data/async_client.py b/google/analytics/data_v1beta/services/beta_analytics_data/async_client.py index ccfa59d..d5ac261 100644 --- a/google/analytics/data_v1beta/services/beta_analytics_data/async_client.py +++ b/google/analytics/data_v1beta/services/beta_analytics_data/async_client.py @@ -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.analytics.data_v1beta.types import analytics_data_api from google.analytics.data_v1beta.types import data from .transports.base import BetaAnalyticsDataTransport, DEFAULT_CLIENT_INFO @@ -163,9 +165,9 @@ def __init__( async def run_report( self, - request: analytics_data_api.RunReportRequest = None, + request: Union[analytics_data_api.RunReportRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.RunReportResponse: @@ -180,7 +182,7 @@ async def run_report( criteria, such as country or event name. Args: - request (:class:`google.analytics.data_v1beta.types.RunReportRequest`): + request (Union[google.analytics.data_v1beta.types.RunReportRequest, dict]): The request object. The request to generate a report. retry (google.api_core.retry.Retry): Designation of what errors, if any, should be retried. @@ -219,9 +221,9 @@ async def run_report( async def run_pivot_report( self, - request: analytics_data_api.RunPivotReportRequest = None, + request: Union[analytics_data_api.RunPivotReportRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.RunPivotReportResponse: @@ -233,7 +235,7 @@ async def run_pivot_report( dissect your data. Args: - request (:class:`google.analytics.data_v1beta.types.RunPivotReportRequest`): + request (Union[google.analytics.data_v1beta.types.RunPivotReportRequest, dict]): The request object. The request to generate a pivot report. retry (google.api_core.retry.Retry): Designation of what errors, if any, @@ -273,9 +275,9 @@ async def run_pivot_report( async def batch_run_reports( self, - request: analytics_data_api.BatchRunReportsRequest = None, + request: Union[analytics_data_api.BatchRunReportsRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.BatchRunReportsResponse: @@ -283,7 +285,7 @@ async def batch_run_reports( be for the same GA4 Property. Args: - request (:class:`google.analytics.data_v1beta.types.BatchRunReportsRequest`): + request (Union[google.analytics.data_v1beta.types.BatchRunReportsRequest, dict]): The request object. The batch request containing multiple report requests. retry (google.api_core.retry.Retry): Designation of what errors, if any, @@ -323,9 +325,9 @@ async def batch_run_reports( async def batch_run_pivot_reports( self, - request: analytics_data_api.BatchRunPivotReportsRequest = None, + request: Union[analytics_data_api.BatchRunPivotReportsRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.BatchRunPivotReportsResponse: @@ -333,7 +335,7 @@ async def batch_run_pivot_reports( reports must be for the same GA4 Property. Args: - request (:class:`google.analytics.data_v1beta.types.BatchRunPivotReportsRequest`): + request (Union[google.analytics.data_v1beta.types.BatchRunPivotReportsRequest, dict]): The request object. The batch request containing multiple pivot report requests. retry (google.api_core.retry.Retry): Designation of what errors, if any, @@ -373,10 +375,10 @@ async def batch_run_pivot_reports( async def get_metadata( self, - request: analytics_data_api.GetMetadataRequest = None, + request: Union[analytics_data_api.GetMetadataRequest, 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]] = (), ) -> analytics_data_api.Metadata: @@ -393,7 +395,7 @@ async def get_metadata( such as ``country`` and ``totalUsers``. Args: - request (:class:`google.analytics.data_v1beta.types.GetMetadataRequest`): + request (Union[google.analytics.data_v1beta.types.GetMetadataRequest, dict]): The request object. Request for a property's dimension and metric metadata. name (:class:`str`): @@ -464,9 +466,9 @@ async def get_metadata( async def run_realtime_report( self, - request: analytics_data_api.RunRealtimeReportRequest = None, + request: Union[analytics_data_api.RunRealtimeReportRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.RunRealtimeReportResponse: @@ -476,7 +478,7 @@ async def run_realtime_report( last 30 minutes. Args: - request (:class:`google.analytics.data_v1beta.types.RunRealtimeReportRequest`): + request (Union[google.analytics.data_v1beta.types.RunRealtimeReportRequest, dict]): The request object. The request to generate a realtime report. retry (google.api_core.retry.Retry): Designation of what errors, if any, @@ -516,9 +518,9 @@ async def run_realtime_report( async def check_compatibility( self, - request: analytics_data_api.CheckCompatibilityRequest = None, + request: Union[analytics_data_api.CheckCompatibilityRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.CheckCompatibilityResponse: @@ -535,7 +537,7 @@ async def check_compatibility( for Core reports. Args: - request (:class:`google.analytics.data_v1beta.types.CheckCompatibilityRequest`): + request (Union[google.analytics.data_v1beta.types.CheckCompatibilityRequest, dict]): The request object. The request for compatibility information for a report's dimensions and metrics. Check compatibility provides a preview of the compatibility of diff --git a/google/analytics/data_v1beta/services/beta_analytics_data/client.py b/google/analytics/data_v1beta/services/beta_analytics_data/client.py index 8c056f3..6225f61 100644 --- a/google/analytics/data_v1beta/services/beta_analytics_data/client.py +++ b/google/analytics/data_v1beta/services/beta_analytics_data/client.py @@ -30,6 +30,8 @@ from google.auth.exceptions import MutualTLSChannelError # type: ignore from google.oauth2 import service_account # type: ignore +OptionalRetry = Union[retries.Retry, object] + from google.analytics.data_v1beta.types import analytics_data_api from google.analytics.data_v1beta.types import data from .transports.base import BetaAnalyticsDataTransport, DEFAULT_CLIENT_INFO @@ -348,7 +350,7 @@ def run_report( self, request: Union[analytics_data_api.RunReportRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.RunReportResponse: @@ -405,7 +407,7 @@ def run_pivot_report( self, request: Union[analytics_data_api.RunPivotReportRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.RunPivotReportResponse: @@ -460,7 +462,7 @@ def batch_run_reports( self, request: Union[analytics_data_api.BatchRunReportsRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.BatchRunReportsResponse: @@ -511,7 +513,7 @@ def batch_run_pivot_reports( self, request: Union[analytics_data_api.BatchRunPivotReportsRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.BatchRunPivotReportsResponse: @@ -563,7 +565,7 @@ def get_metadata( request: Union[analytics_data_api.GetMetadataRequest, 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]] = (), ) -> analytics_data_api.Metadata: @@ -653,7 +655,7 @@ def run_realtime_report( self, request: Union[analytics_data_api.RunRealtimeReportRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.RunRealtimeReportResponse: @@ -706,7 +708,7 @@ def check_compatibility( self, request: Union[analytics_data_api.CheckCompatibilityRequest, dict] = None, *, - retry: retries.Retry = gapic_v1.method.DEFAULT, + retry: OptionalRetry = gapic_v1.method.DEFAULT, timeout: float = None, metadata: Sequence[Tuple[str, str]] = (), ) -> analytics_data_api.CheckCompatibilityResponse: diff --git a/google/analytics/data_v1beta/services/beta_analytics_data/transports/base.py b/google/analytics/data_v1beta/services/beta_analytics_data/transports/base.py index 98511b7..656959f 100644 --- a/google/analytics/data_v1beta/services/beta_analytics_data/transports/base.py +++ b/google/analytics/data_v1beta/services/beta_analytics_data/transports/base.py @@ -15,7 +15,6 @@ # import abc from typing import Awaitable, Callable, Dict, Optional, Sequence, Union -import packaging.version import pkg_resources import google.auth # type: ignore @@ -35,15 +34,6 @@ except pkg_resources.DistributionNotFound: DEFAULT_CLIENT_INFO = gapic_v1.client_info.ClientInfo() -try: - # google.auth.__version__ was added in 1.26.0 - _GOOGLE_AUTH_VERSION = google.auth.__version__ -except AttributeError: - try: # try pkg_resources if it is available - _GOOGLE_AUTH_VERSION = pkg_resources.get_distribution("google-auth").version - except pkg_resources.DistributionNotFound: # pragma: NO COVER - _GOOGLE_AUTH_VERSION = None - class BetaAnalyticsDataTransport(abc.ABC): """Abstract transport class for BetaAnalyticsData.""" @@ -96,7 +86,7 @@ def __init__( host += ":443" self._host = host - scopes_kwargs = self._get_scopes_kwargs(self._host, scopes) + scopes_kwargs = {"scopes": scopes, "default_scopes": self.AUTH_SCOPES} # Save the scopes. self._scopes = scopes @@ -129,29 +119,6 @@ def __init__( # Save the credentials. self._credentials = credentials - # TODO(busunkim): This method is in the base transport - # to avoid duplicating code across the transport classes. These functions - # should be deleted once the minimum required versions of google-auth is increased. - - # TODO: Remove this function once google-auth >= 1.25.0 is required - @classmethod - def _get_scopes_kwargs( - cls, host: str, scopes: Optional[Sequence[str]] - ) -> Dict[str, Optional[Sequence[str]]]: - """Returns scopes kwargs to pass to google-auth methods depending on the google-auth version""" - - scopes_kwargs = {} - - if _GOOGLE_AUTH_VERSION and ( - packaging.version.parse(_GOOGLE_AUTH_VERSION) - >= packaging.version.parse("1.25.0") - ): - scopes_kwargs = {"scopes": scopes, "default_scopes": cls.AUTH_SCOPES} - else: - scopes_kwargs = {"scopes": scopes or cls.AUTH_SCOPES} - - return scopes_kwargs - def _prep_wrapped_messages(self, client_info): # Precompute the wrapped methods. self._wrapped_methods = { diff --git a/google/analytics/data_v1beta/services/beta_analytics_data/transports/grpc_asyncio.py b/google/analytics/data_v1beta/services/beta_analytics_data/transports/grpc_asyncio.py index 6a43694..edcedcf 100644 --- a/google/analytics/data_v1beta/services/beta_analytics_data/transports/grpc_asyncio.py +++ b/google/analytics/data_v1beta/services/beta_analytics_data/transports/grpc_asyncio.py @@ -20,7 +20,6 @@ from google.api_core import grpc_helpers_async # type: ignore from google.auth import credentials as ga_credentials # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore -import packaging.version import grpc # type: ignore from grpc.experimental import aio # type: ignore diff --git a/google/analytics/data_v1beta/types/data.py b/google/analytics/data_v1beta/types/data.py index aac76c1..07f2a7e 100644 --- a/google/analytics/data_v1beta/types/data.py +++ b/google/analytics/data_v1beta/types/data.py @@ -135,6 +135,7 @@ class MinuteRange(proto.Message): minutes of event data (``startMinutesAgo <= 29``), and 360 Analytics properties can request up to the last 60 minutes of event data (``startMinutesAgo <= 59``). + This field is a member of `oneof`_ ``_start_minutes_ago``. end_minutes_ago (int): The inclusive end minute for the query as a number of minutes before now. Cannot be before ``startMinutesAgo``. @@ -146,6 +147,7 @@ class MinuteRange(proto.Message): last 30 minutes of event data (``endMinutesAgo <= 29``), and 360 Analytics properties can request any minute in the last 60 minutes of event data (``endMinutesAgo <= 59``). + This field is a member of `oneof`_ ``_end_minutes_ago``. name (str): Assigns a name to this minute range. The dimension ``dateRange`` is valued to this name in a report response. @@ -203,17 +205,27 @@ class DimensionExpression(proto.Message): 1) lower_case(dimension) 2) concatenate(dimension1, symbol, dimension2). + This message has `oneof`_ fields (mutually exclusive fields). + For each oneof, at most one member field can be set at the same time. + Setting any member of the oneof automatically clears all other + members. + + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: lower_case (google.analytics.data_v1beta.types.DimensionExpression.CaseExpression): Used to convert a dimension value to lower case. + This field is a member of `oneof`_ ``one_expression``. upper_case (google.analytics.data_v1beta.types.DimensionExpression.CaseExpression): Used to convert a dimension value to upper case. + This field is a member of `oneof`_ ``one_expression``. concatenate (google.analytics.data_v1beta.types.DimensionExpression.ConcatenateExpression): Used to combine dimension values to a single dimension. For example, dimension "country, city": concatenate(country, ", ", city). + This field is a member of `oneof`_ ``one_expression``. """ class CaseExpression(proto.Message): @@ -301,17 +313,28 @@ class FilterExpression(proto.Message): The fields in the same FilterExpression need to be either all dimensions or all metrics. + This message has `oneof`_ fields (mutually exclusive fields). + For each oneof, at most one member field can be set at the same time. + Setting any member of the oneof automatically clears all other + members. + + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: and_group (google.analytics.data_v1beta.types.FilterExpressionList): The FilterExpressions in and_group have an AND relationship. + This field is a member of `oneof`_ ``expr``. or_group (google.analytics.data_v1beta.types.FilterExpressionList): The FilterExpressions in or_group have an OR relationship. + This field is a member of `oneof`_ ``expr``. not_expression (google.analytics.data_v1beta.types.FilterExpression): The FilterExpression is NOT of not_expression. + This field is a member of `oneof`_ ``expr``. filter (google.analytics.data_v1beta.types.Filter): A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics. + This field is a member of `oneof`_ ``expr``. """ and_group = proto.Field( @@ -342,18 +365,29 @@ class FilterExpressionList(proto.Message): class Filter(proto.Message): r"""An expression to filter dimension or metric values. + This message has `oneof`_ fields (mutually exclusive fields). + For each oneof, at most one member field can be set at the same time. + Setting any member of the oneof automatically clears all other + members. + + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: field_name (str): The dimension name or metric name. Must be a name defined in dimensions or metrics. string_filter (google.analytics.data_v1beta.types.Filter.StringFilter): Strings related filter. + This field is a member of `oneof`_ ``one_filter``. in_list_filter (google.analytics.data_v1beta.types.Filter.InListFilter): A filter for in list values. + This field is a member of `oneof`_ ``one_filter``. numeric_filter (google.analytics.data_v1beta.types.Filter.NumericFilter): A filter for numeric or date values. + This field is a member of `oneof`_ ``one_filter``. between_filter (google.analytics.data_v1beta.types.Filter.BetweenFilter): A filter for two values. + This field is a member of `oneof`_ ``one_filter``. """ class StringFilter(proto.Message): @@ -454,14 +488,24 @@ class BetweenFilter(proto.Message): class OrderBy(proto.Message): r"""The sort options. + This message has `oneof`_ fields (mutually exclusive fields). + For each oneof, at most one member field can be set at the same time. + Setting any member of the oneof automatically clears all other + members. + + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: metric (google.analytics.data_v1beta.types.OrderBy.MetricOrderBy): Sorts results by a metric's values. + This field is a member of `oneof`_ ``one_order_by``. dimension (google.analytics.data_v1beta.types.OrderBy.DimensionOrderBy): Sorts results by a dimension's values. + This field is a member of `oneof`_ ``one_order_by``. pivot (google.analytics.data_v1beta.types.OrderBy.PivotOrderBy): Sorts results by a metric's values within a pivot column group. + This field is a member of `oneof`_ ``one_order_by``. desc (bool): If true, sorts by descending order. """ @@ -903,10 +947,13 @@ class Row(proto.Message): class DimensionValue(proto.Message): r"""The value of a dimension. + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: value (str): Value as a string if the dimension type is a string. + This field is a member of `oneof`_ ``one_value``. """ value = proto.Field(proto.STRING, number=1, oneof="one_value",) @@ -915,9 +962,12 @@ class DimensionValue(proto.Message): class MetricValue(proto.Message): r"""The value of a metric. + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: value (str): Measurement value. See MetricHeader for type. + This field is a member of `oneof`_ ``one_value``. """ value = proto.Field(proto.STRING, number=4, oneof="one_value",) @@ -926,11 +976,20 @@ class MetricValue(proto.Message): class NumericValue(proto.Message): r"""To represent a number. + This message has `oneof`_ fields (mutually exclusive fields). + For each oneof, at most one member field can be set at the same time. + Setting any member of the oneof automatically clears all other + members. + + .. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields + Attributes: int64_value (int): Integer value + This field is a member of `oneof`_ ``one_value``. double_value (float): Double value + This field is a member of `oneof`_ ``one_value``. """ int64_value = proto.Field(proto.INT64, number=1, oneof="one_value",) @@ -1090,10 +1149,12 @@ class DimensionCompatibility(proto.Message): for this compatibility information. The dimension metadata also contains other helpful information like the UI name and description. + This field is a member of `oneof`_ ``_dimension_metadata``. compatibility (google.analytics.data_v1beta.types.Compatibility): The compatibility of this dimension. If the compatibility is COMPATIBLE, this dimension can be successfully added to the report. + This field is a member of `oneof`_ ``_compatibility``. """ dimension_metadata = proto.Field( @@ -1113,10 +1174,12 @@ class MetricCompatibility(proto.Message): this compatibility information. The metric metadata also contains other helpful information like the UI name and description. + This field is a member of `oneof`_ ``_metric_metadata``. compatibility (google.analytics.data_v1beta.types.Compatibility): The compatibility of this metric. If the compatibility is COMPATIBLE, this metric can be successfully added to the report. + This field is a member of `oneof`_ ``_compatibility``. """ metric_metadata = proto.Field( diff --git a/setup.py b/setup.py index d53906a..88e101e 100644 --- a/setup.py +++ b/setup.py @@ -48,7 +48,7 @@ # NOTE: Maintainers, please do not require google-api-core>=2.x.x # Until this issue is closed # https://github.com/googleapis/google-cloud-python/issues/10566 - "google-api-core[grpc] >= 1.26.0, <3.0.0dev", + "google-api-core[grpc] >= 1.28.0, <3.0.0dev", "libcst >= 0.2.5", "proto-plus >= 1.4.0", "packaging >= 14.3", diff --git a/testing/constraints-3.6.txt b/testing/constraints-3.6.txt index 9371b39..61f0ec4 100644 --- a/testing/constraints-3.6.txt +++ b/testing/constraints-3.6.txt @@ -5,8 +5,7 @@ # # e.g., if setup.py has "foo >= 1.14.0, < 2.0.0dev", # Then this file should have foo==1.14.0 -google-api-core==1.26.0 +google-api-core==1.28.0 libcst==0.2.5 proto-plus==1.4.0 packaging==14.3 -google-auth==1.24.0 # TODO: remove when google-auth>=1.25.0 is required through google-api-core diff --git a/tests/unit/gapic/data_v1beta/test_beta_analytics_data.py b/tests/unit/gapic/data_v1beta/test_beta_analytics_data.py index 2ce45e7..e52e083 100644 --- a/tests/unit/gapic/data_v1beta/test_beta_analytics_data.py +++ b/tests/unit/gapic/data_v1beta/test_beta_analytics_data.py @@ -15,7 +15,6 @@ # import os import mock -import packaging.version import grpc from grpc.experimental import aio @@ -31,9 +30,6 @@ BetaAnalyticsDataClient, ) from google.analytics.data_v1beta.services.beta_analytics_data import transports -from google.analytics.data_v1beta.services.beta_analytics_data.transports.base import ( - _GOOGLE_AUTH_VERSION, -) from google.analytics.data_v1beta.types import analytics_data_api from google.analytics.data_v1beta.types import data from google.api_core import client_options @@ -48,20 +44,6 @@ import google.auth -# TODO(busunkim): Once google-auth >= 1.25.0 is required transitively -# through google-api-core: -# - Delete the auth "less than" test cases -# - Delete these pytest markers (Make the "greater than or equal to" tests the default). -requires_google_auth_lt_1_25_0 = pytest.mark.skipif( - packaging.version.parse(_GOOGLE_AUTH_VERSION) >= packaging.version.parse("1.25.0"), - reason="This test requires google-auth < 1.25.0", -) -requires_google_auth_gte_1_25_0 = pytest.mark.skipif( - packaging.version.parse(_GOOGLE_AUTH_VERSION) < packaging.version.parse("1.25.0"), - reason="This test requires google-auth >= 1.25.0", -) - - def client_cert_source_callback(): return b"cert bytes", b"key bytes" @@ -219,7 +201,7 @@ def test_beta_analytics_data_client_client_options( options = client_options.ClientOptions(api_endpoint="squid.clam.whelk") with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class(client_options=options) + client = client_class(transport=transport_name, client_options=options) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -236,7 +218,7 @@ def test_beta_analytics_data_client_client_options( with mock.patch.dict(os.environ, {"GOOGLE_API_USE_MTLS_ENDPOINT": "never"}): with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class() + client = client_class(transport=transport_name) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -253,7 +235,7 @@ def test_beta_analytics_data_client_client_options( with mock.patch.dict(os.environ, {"GOOGLE_API_USE_MTLS_ENDPOINT": "always"}): with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class() + client = client_class(transport=transport_name) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -282,7 +264,7 @@ def test_beta_analytics_data_client_client_options( options = client_options.ClientOptions(quota_project_id="octopus") with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class(client_options=options) + client = client_class(transport=transport_name, client_options=options) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -351,7 +333,7 @@ def test_beta_analytics_data_client_mtls_env_auto( ) with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class(client_options=options) + client = client_class(transport=transport_name, client_options=options) if use_client_cert_env == "false": expected_client_cert_source = None @@ -393,7 +375,7 @@ def test_beta_analytics_data_client_mtls_env_auto( expected_client_cert_source = client_cert_source_callback patched.return_value = None - client = client_class() + client = client_class(transport=transport_name) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -415,7 +397,7 @@ def test_beta_analytics_data_client_mtls_env_auto( return_value=False, ): patched.return_value = None - client = client_class() + client = client_class(transport=transport_name) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -446,7 +428,7 @@ def test_beta_analytics_data_client_client_options_scopes( options = client_options.ClientOptions(scopes=["1", "2"],) with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class(client_options=options) + client = client_class(transport=transport_name, client_options=options) patched.assert_called_once_with( credentials=None, credentials_file=None, @@ -477,7 +459,7 @@ def test_beta_analytics_data_client_client_options_credentials_file( options = client_options.ClientOptions(credentials_file="credentials.json") with mock.patch.object(transport_class, "__init__") as patched: patched.return_value = None - client = client_class(client_options=options) + client = client_class(transport=transport_name, client_options=options) patched.assert_called_once_with( credentials=None, credentials_file="credentials.json", @@ -1688,7 +1670,6 @@ def test_beta_analytics_data_base_transport(): transport.close() -@requires_google_auth_gte_1_25_0 def test_beta_analytics_data_base_transport_with_credentials_file(): # Instantiate the base transport with a credentials file with mock.patch.object( @@ -1712,29 +1693,6 @@ def test_beta_analytics_data_base_transport_with_credentials_file(): ) -@requires_google_auth_lt_1_25_0 -def test_beta_analytics_data_base_transport_with_credentials_file_old_google_auth(): - # Instantiate the base transport with a credentials file - with mock.patch.object( - google.auth, "load_credentials_from_file", autospec=True - ) as load_creds, mock.patch( - "google.analytics.data_v1beta.services.beta_analytics_data.transports.BetaAnalyticsDataTransport._prep_wrapped_messages" - ) as Transport: - Transport.return_value = None - load_creds.return_value = (ga_credentials.AnonymousCredentials(), None) - transport = transports.BetaAnalyticsDataTransport( - credentials_file="credentials.json", quota_project_id="octopus", - ) - load_creds.assert_called_once_with( - "credentials.json", - scopes=( - "https://www.googleapis.com/auth/analytics", - "https://www.googleapis.com/auth/analytics.readonly", - ), - quota_project_id="octopus", - ) - - def test_beta_analytics_data_base_transport_with_adc(): # Test the default credentials are used if credentials and credentials_file are None. with mock.patch.object(google.auth, "default", autospec=True) as adc, mock.patch( @@ -1746,7 +1704,6 @@ def test_beta_analytics_data_base_transport_with_adc(): adc.assert_called_once() -@requires_google_auth_gte_1_25_0 def test_beta_analytics_data_auth_adc(): # If no credentials are provided, we should use ADC credentials. with mock.patch.object(google.auth, "default", autospec=True) as adc: @@ -1762,21 +1719,6 @@ def test_beta_analytics_data_auth_adc(): ) -@requires_google_auth_lt_1_25_0 -def test_beta_analytics_data_auth_adc_old_google_auth(): - # If no credentials are provided, we should use ADC credentials. - with mock.patch.object(google.auth, "default", autospec=True) as adc: - adc.return_value = (ga_credentials.AnonymousCredentials(), None) - BetaAnalyticsDataClient() - adc.assert_called_once_with( - scopes=( - "https://www.googleapis.com/auth/analytics", - "https://www.googleapis.com/auth/analytics.readonly", - ), - quota_project_id=None, - ) - - @pytest.mark.parametrize( "transport_class", [ @@ -1784,7 +1726,6 @@ def test_beta_analytics_data_auth_adc_old_google_auth(): transports.BetaAnalyticsDataGrpcAsyncIOTransport, ], ) -@requires_google_auth_gte_1_25_0 def test_beta_analytics_data_transport_auth_adc(transport_class): # If credentials and host are not provided, the transport class should use # ADC credentials. @@ -1801,29 +1742,6 @@ def test_beta_analytics_data_transport_auth_adc(transport_class): ) -@pytest.mark.parametrize( - "transport_class", - [ - transports.BetaAnalyticsDataGrpcTransport, - transports.BetaAnalyticsDataGrpcAsyncIOTransport, - ], -) -@requires_google_auth_lt_1_25_0 -def test_beta_analytics_data_transport_auth_adc_old_google_auth(transport_class): - # If credentials and host are not provided, the transport class should use - # ADC credentials. - with mock.patch.object(google.auth, "default", autospec=True) as adc: - adc.return_value = (ga_credentials.AnonymousCredentials(), None) - transport_class(quota_project_id="octopus") - adc.assert_called_once_with( - scopes=( - "https://www.googleapis.com/auth/analytics", - "https://www.googleapis.com/auth/analytics.readonly", - ), - quota_project_id="octopus", - ) - - @pytest.mark.parametrize( "transport_class,grpc_helpers", [ From 583920a4d0efd8c4c08e9f40379732052773c1d0 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 1 Nov 2021 15:30:18 +0000 Subject: [PATCH 5/6] feat: add the `schema_restriction_response` field to the `ResponseMetaData` type (#157) ..that contains the schema restrictions actively enforced in creating a report - [ ] Regenerate this pull request now. PiperOrigin-RevId: 406725448 Source-Link: https://github.com/googleapis/googleapis/commit/c1176cd3140f249d6d0340070d7933142b821575 Source-Link: https://github.com/googleapis/googleapis-gen/commit/4d391c476d0fcf76fd884a677d6a16a0fc44a22b Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNGQzOTFjNDc2ZDBmY2Y3NmZkODg0YTY3N2Q2YTE2YTBmYzQ0YTIyYiJ9 feat: add the `currency_code`, `time_zone` fields to the `ResponseMetaData` type feat: add the `empty_reason` field to the `ResponseMetaData` type that contains an empty report reason feat: add the `blocked_reasons` field to the `MetricMetadata` type that contains reasons why access was blocked --- google/analytics/data/__init__.py | 2 + google/analytics/data_v1beta/__init__.py | 2 + .../analytics/data_v1beta/types/__init__.py | 2 + google/analytics/data_v1beta/types/data.py | 100 ++++++++++++++++++ 4 files changed, 106 insertions(+) diff --git a/google/analytics/data/__init__.py b/google/analytics/data/__init__.py index dbfffbd..4dd9061 100644 --- a/google/analytics/data/__init__.py +++ b/google/analytics/data/__init__.py @@ -81,6 +81,7 @@ from google.analytics.data_v1beta.types.data import Compatibility from google.analytics.data_v1beta.types.data import MetricAggregation from google.analytics.data_v1beta.types.data import MetricType +from google.analytics.data_v1beta.types.data import RestrictedMetricType __all__ = ( "BetaAnalyticsDataClient", @@ -131,4 +132,5 @@ "Compatibility", "MetricAggregation", "MetricType", + "RestrictedMetricType", ) diff --git a/google/analytics/data_v1beta/__init__.py b/google/analytics/data_v1beta/__init__.py index 9b9f490..ca076de 100644 --- a/google/analytics/data_v1beta/__init__.py +++ b/google/analytics/data_v1beta/__init__.py @@ -63,6 +63,7 @@ from .types.data import Compatibility from .types.data import MetricAggregation from .types.data import MetricType +from .types.data import RestrictedMetricType __all__ = ( "BetaAnalyticsDataAsyncClient", @@ -106,6 +107,7 @@ "PropertyQuota", "QuotaStatus", "ResponseMetaData", + "RestrictedMetricType", "Row", "RunPivotReportRequest", "RunPivotReportResponse", diff --git a/google/analytics/data_v1beta/types/__init__.py b/google/analytics/data_v1beta/types/__init__.py index 408fe4f..61c607e 100644 --- a/google/analytics/data_v1beta/types/__init__.py +++ b/google/analytics/data_v1beta/types/__init__.py @@ -62,6 +62,7 @@ Compatibility, MetricAggregation, MetricType, + RestrictedMetricType, ) __all__ = ( @@ -111,4 +112,5 @@ "Compatibility", "MetricAggregation", "MetricType", + "RestrictedMetricType", ) diff --git a/google/analytics/data_v1beta/types/data.py b/google/analytics/data_v1beta/types/data.py index 07f2a7e..5d89f8c 100644 --- a/google/analytics/data_v1beta/types/data.py +++ b/google/analytics/data_v1beta/types/data.py @@ -21,6 +21,7 @@ manifest={ "MetricAggregation", "MetricType", + "RestrictedMetricType", "Compatibility", "DateRange", "MinuteRange", @@ -81,6 +82,15 @@ class MetricType(proto.Enum): TYPE_KILOMETERS = 13 +class RestrictedMetricType(proto.Enum): + r"""Categories of data that you may be restricted from viewing on + certain GA4 properties. + """ + RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0 + COST_DATA = 1 + REVENUE_DATA = 2 + + class Compatibility(proto.Enum): r"""The compatibility types for a single dimension or metric.""" COMPATIBILITY_UNSPECIFIED = 0 @@ -821,9 +831,82 @@ class ResponseMetaData(proto.Message): If true, indicates some buckets of dimension combinations are rolled into "(other)" row. This can happen for high cardinality reports. + schema_restriction_response (google.analytics.data_v1beta.types.ResponseMetaData.SchemaRestrictionResponse): + Describes the schema restrictions actively enforced in + creating this report. To learn more, see `Access and + data-restriction + management `__. + This field is a member of `oneof`_ ``_schema_restriction_response``. + currency_code (str): + The currency code used in this report. Intended to be used + in formatting currency metrics like ``purchaseRevenue`` for + visualization. If currency_code was specified in the + request, this response parameter will echo the request + parameter; otherwise, this response parameter is the + property's current currency_code. + + Currency codes are string encodings of currency types from + the ISO 4217 standard + (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + "EUR", "JPY". To learn more, see + https://support.google.com/analytics/answer/9796179. + This field is a member of `oneof`_ ``_currency_code``. + time_zone (str): + The property's current timezone. Intended to be used to + interpret time-based dimensions like ``hour`` and + ``minute``. Formatted as strings from the IANA Time Zone + database (https://www.iana.org/time-zones); for example + "America/New_York" or "Asia/Tokyo". + This field is a member of `oneof`_ ``_time_zone``. + empty_reason (str): + If empty reason is specified, the report is + empty for this reason. + This field is a member of `oneof`_ ``_empty_reason``. """ + class SchemaRestrictionResponse(proto.Message): + r"""The schema restrictions actively enforced in creating this report. + To learn more, see `Access and data-restriction + management `__. + + Attributes: + active_metric_restrictions (Sequence[google.analytics.data_v1beta.types.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction]): + All restrictions actively enforced in creating the report. + For example, ``purchaseRevenue`` always has the restriction + type ``REVENUE_DATA``. However, this active response + restriction is only populated if the user's custom role + disallows access to ``REVENUE_DATA``. + """ + + class ActiveMetricRestriction(proto.Message): + r"""A metric actively restricted in creating the report. + + Attributes: + metric_name (str): + The name of the restricted metric. + This field is a member of `oneof`_ ``_metric_name``. + restricted_metric_types (Sequence[google.analytics.data_v1beta.types.RestrictedMetricType]): + The reason for this metric's restriction. + """ + + metric_name = proto.Field(proto.STRING, number=1, optional=True,) + restricted_metric_types = proto.RepeatedField( + proto.ENUM, number=2, enum="RestrictedMetricType", + ) + + active_metric_restrictions = proto.RepeatedField( + proto.MESSAGE, + number=1, + message="ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction", + ) + data_loss_from_other_row = proto.Field(proto.BOOL, number=3,) + schema_restriction_response = proto.Field( + proto.MESSAGE, number=4, optional=True, message=SchemaRestrictionResponse, + ) + currency_code = proto.Field(proto.STRING, number=5, optional=True,) + time_zone = proto.Field(proto.STRING, number=6, optional=True,) + empty_reason = proto.Field(proto.STRING, number=7, optional=True,) class DimensionHeader(proto.Message): @@ -1124,12 +1207,28 @@ class MetricMetadata(proto.Message): custom_definition (bool): True if the metric is a custom metric for this property. + blocked_reasons (Sequence[google.analytics.data_v1beta.types.MetricMetadata.BlockedReason]): + If reasons are specified, your access is blocked to this + metric for this property. API requests from you to this + property for this metric will succeed; however, the report + will contain only zeros for this metric. API requests with + metric filters on blocked metrics will fail. If reasons are + empty, you have access to this metric. + + To learn more, see `Access and data-restriction + management `__. category (str): The display name of the category that this metrics belongs to. Similar dimensions and metrics are categorized together. """ + class BlockedReason(proto.Enum): + r"""Justifications for why this metric is blocked.""" + BLOCKED_REASON_UNSPECIFIED = 0 + NO_REVENUE_METRICS = 1 + NO_COST_METRICS = 2 + api_name = proto.Field(proto.STRING, number=1,) ui_name = proto.Field(proto.STRING, number=2,) description = proto.Field(proto.STRING, number=3,) @@ -1137,6 +1236,7 @@ class MetricMetadata(proto.Message): type_ = proto.Field(proto.ENUM, number=5, enum="MetricType",) expression = proto.Field(proto.STRING, number=6,) custom_definition = proto.Field(proto.BOOL, number=7,) + blocked_reasons = proto.RepeatedField(proto.ENUM, number=8, enum=BlockedReason,) category = proto.Field(proto.STRING, number=10,) From 8b430739693a6ed3ce361afcf2a11c64fcc7315f Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Mon, 1 Nov 2021 21:34:13 +0000 Subject: [PATCH 6/6] chore: release 0.10.0 (#159) :robot: I have created a release \*beep\* \*boop\* --- ## [0.10.0](https://www.github.com/googleapis/python-analytics-data/compare/v0.9.0...v0.10.0) (2021-11-01) ### Features * add the `blocked_reasons` field to the `MetricMetadata` type that contains reasons why access was blocked ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) * add the `currency_code`, `time_zone` fields to the `ResponseMetaData` type ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) * add the `empty_reason` field to the `ResponseMetaData` type that contains an empty report reason ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) * add the `schema_restriction_response` field to the `ResponseMetaData` type ([#157](https://www.github.com/googleapis/python-analytics-data/issues/157)) ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) ### Bug Fixes * **deps:** require google-api-core >= 1.28.0 ([1f81d4e](https://www.github.com/googleapis/python-analytics-data/commit/1f81d4eacc5f00bd6666fb4437aed9b78b3cd761)) ### Documentation * list oneofs in docstring ([1f81d4e](https://www.github.com/googleapis/python-analytics-data/commit/1f81d4eacc5f00bd6666fb4437aed9b78b3cd761)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 20 ++++++++++++++++++++ setup.py | 2 +- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0c30925..a75de78 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,25 @@ # Changelog +## [0.10.0](https://www.github.com/googleapis/python-analytics-data/compare/v0.9.0...v0.10.0) (2021-11-01) + + +### Features + +* add the `blocked_reasons` field to the `MetricMetadata` type that contains reasons why access was blocked ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) +* add the `currency_code`, `time_zone` fields to the `ResponseMetaData` type ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) +* add the `empty_reason` field to the `ResponseMetaData` type that contains an empty report reason ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) +* add the `schema_restriction_response` field to the `ResponseMetaData` type ([#157](https://www.github.com/googleapis/python-analytics-data/issues/157)) ([583920a](https://www.github.com/googleapis/python-analytics-data/commit/583920a4d0efd8c4c08e9f40379732052773c1d0)) + + +### Bug Fixes + +* **deps:** require google-api-core >= 1.28.0 ([1f81d4e](https://www.github.com/googleapis/python-analytics-data/commit/1f81d4eacc5f00bd6666fb4437aed9b78b3cd761)) + + +### Documentation + +* list oneofs in docstring ([1f81d4e](https://www.github.com/googleapis/python-analytics-data/commit/1f81d4eacc5f00bd6666fb4437aed9b78b3cd761)) + ## [0.9.0](https://www.github.com/googleapis/python-analytics-data/compare/v0.8.1...v0.9.0) (2021-10-11) diff --git a/setup.py b/setup.py index 88e101e..08a0925 100644 --- a/setup.py +++ b/setup.py @@ -19,7 +19,7 @@ import os import setuptools # type: ignore -version = "0.9.0" +version = "0.10.0" package_root = os.path.abspath(os.path.dirname(__file__))