Skip to content

Conversation

@StephaneDelcroix
Copy link
Contributor

Description of Change

if EnableDiagnostics isn't set, defaut to true on Debug builds

Issues Fixed

@StephaneDelcroix StephaneDelcroix added this to the .NET 10.0 GA milestone Oct 17, 2025
Copilot AI review requested due to automatic review settings October 17, 2025 20:04
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR changes the default behavior for XAML diagnostics in source generation to enable them by default in Debug builds when not explicitly configured. Previously, diagnostics were disabled unless explicitly enabled; now they default to enabled in Debug and disabled in Release configurations.

Key Changes

  • Modified the EnableDiagnostics property logic to check build configuration
  • Added explicit true/false checks for EnableMauiXamlDiagnostics before falling back to configuration-based default
  • Changed default behavior from false to configuration-dependent (enabled for Debug, disabled for Release)

@rmarinho
Copy link
Member

/backport to release/10.0.1xx

@github-actions
Copy link
Contributor

@rmarinho
Copy link
Member

/rebase

@github-actions github-actions bot force-pushed the dev/stdelc/fix32047 branch from 098a377 to f22baa2 Compare October 22, 2025 12:42
@StephaneDelcroix StephaneDelcroix changed the title [XSG] enable diagnostis by default on Debug [XSG] enable diagnostics by default on Debug Oct 23, 2025
mattleibow
mattleibow previously approved these changes Oct 23, 2025
@mattleibow
Copy link
Member

/backport to release/10.0.1xx

@github-actions
Copy link
Contributor

if EnableDiagnostics isn't set, defaut to true on Debug builds

- fixes #32047
@rmarinho rmarinho merged commit d287475 into net10.0 Oct 24, 2025
157 of 163 checks passed
@rmarinho rmarinho deleted the dev/stdelc/fix32047 branch October 24, 2025 09:19
@PureWeen PureWeen added the area-xaml XAML, CSS, Triggers, Behaviors label Nov 6, 2025
@github-actions github-actions bot locked and limited conversation to collaborators Dec 7, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-xaml XAML, CSS, Triggers, Behaviors

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants