Skip to content

Commit

Permalink
feat: [google-analytics-data] add the EmptyFilter type to the Data …
Browse files Browse the repository at this point in the history
…API v1alpha (#13309)

- [ ] Regenerate this pull request now.

BEGIN_COMMIT_OVERRIDE
feat: add the `empty_filter` field to the `Filter` type
feat: add `sampling_metadatas` field to the `ResponseMetaData` type
feat: add the `EmptyFilter` type to the Data API v1alpha
END_COMMIT_OVERRIDE


PiperOrigin-RevId: 700547721

Source-Link:
googleapis/googleapis@f4d1743

Source-Link:
googleapis/googleapis-gen@7fe5885
Copy-Tag:
eyJwIjoicGFja2FnZXMvZ29vZ2xlLWFuYWx5dGljcy1kYXRhLy5Pd2xCb3QueWFtbCIsImgiOiI3ZmU1ODg1Mjc1M2U0ZTU2NGE4NWQ3Y2I5YjZkMDU3NTc1NTViOWQwIn0=

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Nov 27, 2024
1 parent fe13507 commit 4035ab8
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
DimensionExpression,
DimensionHeader,
DimensionValue,
EmptyFilter,
EventCriteriaScoping,
EventExclusionDuration,
EventSegment,
Expand Down Expand Up @@ -152,6 +153,7 @@
"DimensionExpression",
"DimensionHeader",
"DimensionValue",
"EmptyFilter",
"EventCriteriaScoping",
"EventExclusionDuration",
"EventSegment",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
DimensionExpression,
DimensionHeader,
DimensionValue,
EmptyFilter,
EventCriteriaScoping,
EventExclusionDuration,
EventSegment,
Expand Down Expand Up @@ -164,6 +165,7 @@
"DimensionExpression",
"DimensionHeader",
"DimensionValue",
"EmptyFilter",
"EventSegment",
"EventSegmentConditionGroup",
"EventSegmentCriteria",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"NumericFilter",
"OrderBy",
"BetweenFilter",
"EmptyFilter",
"NumericValue",
"CohortSpec",
"Cohort",
Expand Down Expand Up @@ -674,6 +675,11 @@ class Filter(proto.Message):
between_filter (google.analytics.data_v1alpha.types.BetweenFilter):
A filter for between two values.
This field is a member of `oneof`_ ``one_filter``.
empty_filter (google.analytics.data_v1alpha.types.EmptyFilter):
A filter for empty values such as "(not set)"
and "" values.
This field is a member of `oneof`_ ``one_filter``.
"""

Expand Down Expand Up @@ -705,6 +711,12 @@ class Filter(proto.Message):
oneof="one_filter",
message="BetweenFilter",
)
empty_filter: "EmptyFilter" = proto.Field(
proto.MESSAGE,
number=6,
oneof="one_filter",
message="EmptyFilter",
)


class StringFilter(proto.Message):
Expand Down Expand Up @@ -956,6 +968,10 @@ class BetweenFilter(proto.Message):
)


class EmptyFilter(proto.Message):
r"""Filter for empty values."""


class NumericValue(proto.Message):
r"""To represent a number.
Expand Down Expand Up @@ -1272,6 +1288,16 @@ class ResponseMetaData(proto.Message):
Interests <https://support.google.com/analytics/answer/2799357>`__.
This field is a member of `oneof`_ ``_subject_to_thresholding``.
sampling_metadatas (MutableSequence[google.analytics.data_v1alpha.types.SamplingMetadata]):
If this report's results are
`sampled <https://support.google.com/analytics/answer/13331292>`__,
this describes the percentage of events used in this report.
One ``samplingMetadatas`` is populated for each date range.
Each ``samplingMetadatas`` corresponds to a date range in
the order that date ranges were specified in the request.
However if the results are not sampled, this field will not
be defined.
"""

class SchemaRestrictionResponse(proto.Message):
Expand Down Expand Up @@ -1353,6 +1379,11 @@ class ActiveMetricRestriction(proto.Message):
number=8,
optional=True,
)
sampling_metadatas: MutableSequence["SamplingMetadata"] = proto.RepeatedField(
proto.MESSAGE,
number=9,
message="SamplingMetadata",
)


class DimensionHeader(proto.Message):
Expand Down Expand Up @@ -3145,8 +3176,8 @@ class FunnelResponseMetadata(proto.Message):
this describes what percentage of events were used in this
funnel report. One ``samplingMetadatas`` is populated for
each date range. Each ``samplingMetadatas`` corresponds to a
date range in order that date ranges were specified in the
request.
date range in the order that date ranges were specified in
the request.
However if the results are not sampled, this field will not
be defined.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11568,6 +11568,7 @@ def test_create_report_task_rest_call_success(request_type):
},
},
"between_filter": {"from_value": {}, "to_value": {}},
"empty_filter": {},
},
},
"metric_filter": {},
Expand Down

0 comments on commit 4035ab8

Please sign in to comment.