Skip to content

Honor custom DateTimeOffset converters - #791

Merged
Vincent Biret (baywet) merged 5 commits into
microsoft:mainfrom
shubmittal:fix-datetimeoffset-converter-692
Sep 8, 2026
Merged

Vincent Biret (baywet) merged 5 commits into
microsoft:mainfrom
shubmittal:fix-datetimeoffset-converter-692

Conversation

@shubmittal

Copy link
Copy Markdown
Contributor

Summary

  • Try custom DateTimeOffset converters before built-in parsing.
  • Keep the current fallback when a converter cannot parse a value.
  • Add regression tests for both paths.

Fixes #692

Validation

  • JSON serialization tests: 144 passed on .NET 8.
  • JSON serialization tests: 144 passed on .NET 10.
  • JSON serialization tests: 144 passed on .NET Framework.
  • JSON serialization test project build passed with no warnings or errors.
  • Formatting check passed.

AI assistance

GitHub Copilot helped implement and validate this change.

@shubmittal
shubmittal requested a review from a team as a code owner September 4, 2026 17:46

@baywet Vincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution!

This comment was marked as outdated.

@github-actions

This comment was marked as outdated.

Shubhra Mittal and others added 2 commits September 4, 2026 19:32
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@shubmittal
shubmittal force-pushed the fix-datetimeoffset-converter-692 branch from fbd219f to a5ad954 Compare September 4, 2026 18:40

@baywet Vincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for making the changes!

This comment was marked as outdated.

@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Conflicts have been resolved. A maintainer will take a look shortly.

@shubmittal shubmittal closed this Sep 5, 2026
@github-project-automation github-project-automation Bot moved this from In Progress 🚧 to Done ✔️ in Kiota Sep 5, 2026
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@shubmittal shubmittal reopened this Sep 5, 2026
@github-project-automation github-project-automation Bot moved this from Done ✔️ to In Progress 🚧 in Kiota Sep 5, 2026
# Conflicts:
#	src/serialization/json/JsonParseNode.cs

@baywet Vincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for making the changes!

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The change directly addresses the reported regression with targeted converter detection and adds regression tests for both the custom-converter and fallback paths.

Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Regression in 1.22.1: loss of ability to customize DateTimeOffset parsing

3 participants