Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Generator] (fix) Support date-time format enrichment #2867

Merged
merged 5 commits into from
Feb 26, 2025

Conversation

Supam
Copy link
Contributor

@Supam Supam commented Feb 25, 2025

Motivation

Strings with the 'format' fields set to 'date-time' were being read as strings.
Meanwhile the Go client automatically converts them to *time.Time and breaks the updateState function.
Such fields are now properly converted back to strings when updating the state.

Changes

  • Added a new formatting function and filter to support date-time enrichment
  • Changed the generation to use this filter
  • Tidied .generator/src/generator/utils.py

Strings with the 'format' fields set to 'date-time' were previously read as strings.
Meanwhile the Go client automatically converts them to `*time.Time`.
Such fields are now properly converted back to strings when updating the state.
@Supam Supam self-assigned this Feb 25, 2025
@Supam Supam requested a review from a team as a code owner February 25, 2025 08:24
@Supam Supam changed the title Thibault.viennot/support date time format enrichment [Generator] (fix) Support date-time format enrichment Feb 25, 2025
ecdatadog
ecdatadog previously approved these changes Feb 26, 2025
@Supam Supam merged commit e308b50 into master Feb 26, 2025
10 checks passed
@Supam Supam deleted the thibault.viennot/support-date-time-format-enrichment branch February 26, 2025 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants