Skip to content

Commit 5e386a2

Browse files
brizentalbirdsarah
authored andcommitted
Update glean_parser_ext to be compatible with glean_parser 7.0.0 (#5757)
With the breaking change on glean_parser not to support untyped event extras, the has_extra_types property was removed.
1 parent f23a91e commit 5e386a2

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

vpnglean/glean_parser_ext/templates/rust.jinja2

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,8 @@ use glean::RecordedEvent;
1515

1616
{% macro generate_extra_keys(obj) -%}
1717
{% for name, _ in obj["_generate_enums"] %}
18-
{# we always use the `extra` suffix, because we only expose the new event API #}
1918
{% set suffix = "Extra" %}
20-
{% if obj|attr(name)|length %}
21-
{% if obj.has_extra_types %}
22-
{{ extra_keys_with_types(obj, name, suffix)|indent }}
23-
{% else %}
24-
compile_error!("Untyped event extras not supported. Please annotate event extras with a type. See documentation for details. (Metric: {{obj.category}}.{{obj.name}}, defined in: {{obj.defined_in['filepath']}}:{{obj.defined_in['line']}})");
25-
{% endif %}
26-
{% endif %}
19+
{{ extra_keys_with_types(obj, name, suffix)|indent }}
2720
{% endfor %}
2821
{%- endmacro -%}
2922

0 commit comments

Comments
 (0)