to_const_name generates invalid variable identifiers #59
Labels
enhancement
New feature or request
semconv/model
Related to the data model or YAML format of the semantic convention generator
semconv
Related to the semantic convention generator.
Recently in semantic conventions, two new types of id were introduced:
The const names generated for those ids are
ALIBABA CLOUD
and1XRTT
respectively. Those generated values are not valid variable identifiers in most languages.In opentelemetry-js, we use
to_const_name
to generate keys for those ids: https://github.com/open-telemetry/opentelemetry-js/blob/main/scripts/semconv/templates/SemanticAttributes.ts.j2#L57. In this case, the keys should be valid variable identifiers.Should we change the semantic conventions or update the generator to generate valid identifiers?
The text was updated successfully, but these errors were encountered: