Skip to content

chore: Suppress XmlException thrown internally on AppConfigGenerator::Generate method - #2817

Merged
timcassell merged 1 commit into
dotnet:masterfrom
filzrev:chore-suppress-exeption-thrown-when-nulltextreader
Aug 23, 2025
Merged

chore: Suppress XmlException thrown internally on AppConfigGenerator::Generate method#2817
timcassell merged 1 commit into
dotnet:masterfrom
filzrev:chore-suppress-exeption-thrown-when-nulltextreader

Conversation

@filzrev

@filzrev filzrev commented Aug 5, 2025

Copy link
Copy Markdown
Contributor

This PR add extra check logics to avoid issue that XmlException is internally thrown when TextReader.Null is passed to AppConfigGenerator::Generate method.

Background
When Break on Exception thrown setting is enabled on debugger attached environment.
It's always interrupted by XmlException is thrown on AppConfigGenerator::Generate method.

This PR fix this issue. By modifing code not throw exceptions on normal execution path.

Additional Changes

  • Add #nullable enable setting on AppConfigGenerator.cs
  • Refactor code to resolve errors that are relating nullability.

@filzrev
filzrev force-pushed the chore-suppress-exeption-thrown-when-nulltextreader branch from cf21588 to 49be942 Compare August 5, 2025 11:14
@timcassell timcassell added this to the v0.15.3 milestone Aug 23, 2025
@timcassell
timcassell merged commit e7cf8b4 into dotnet:master Aug 23, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants