Skip to content

Comments

feat: add VariableDescriptor support to field data interfaces#4938

Draft
mayankansys wants to merge 12 commits intomainfrom
feat/api_strongly_variabledescriptor
Draft

feat: add VariableDescriptor support to field data interfaces#4938
mayankansys wants to merge 12 commits intomainfrom
feat/api_strongly_variabledescriptor

Conversation

@mayankansys
Copy link
Collaborator

Context

The API was originally designed to use strings (e.g., "temperature") to identify variables.
Although VariableDescriptor was later introduced as an alternative, strings were still commonly used.

This caused:

  • Mixed usage of strings and VariableDescriptor
  • Allowed values being exposed as strings
  • Error messages referring to raw strings
  • Inconsistent and less type-safe API behavior

Change Summary

  • Promote VariableDescriptor to be the primary way to identify variables.
  • Ensure allowed values are returned as VariableDescriptor objects instead of strings.
  • Update error and diagnostic messages to reference VariableDescriptor where appropriate.

Impact

  • APIs such as field_data will primarily accept VariableDescriptor instead of strings.
  • Allowed values returned by APIs will now be descriptors instead of string names.
  • Some internal validation and error handling logic may change.
  • Code that previously passed strings may require minor updates to use descriptors instead.

@github-actions github-actions bot added documentation Documentation related (improving, adding, etc) new feature labels Feb 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Documentation related (improving, adding, etc) new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Orient originally string-based APIs more strongly around VariableDescriptors

2 participants