VisualDiagnostics.RegisterSourceInfo returns null if debugger is not attached
- Dominant language
- C#
- Stars
- 23.3k
- Forks
- 2k
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 297
Description
### Description
XAML Hot Reload not available when attaching to MAUI+WinUI process even if having system level env var ENABLE_XAML_DIAGNOSTICS_SOURCE_INFO=1.
### Steps to Reproduce
1. Set system wide env var ENABLE_XAML_DIAGNOSTICS_SOURCE_INFO=1
2. Open VS and create MAUI app.
3. Build.
4. Run without debugger (i.e. Ctrl+F5).
5. Debugger > Attach to Process, select MAUI app started on prev step.
6. Open Live Visual Tree, make sure Just My XAML is turned ON.
**Actual**: LVT is empty
**Expected**: LVT is not empty
**Note**: MAUI needs to update all places where it checks for DebuggerHelper.IsDebuggerAttached and switch to checking ENABLE_XAML_DIAGNOSTICS_SOURCE_INFO.
### Link to public reproduction project repository
n/a
### Version with bug
6.0 Release Candidate 3
### Last version that worked well
Unknown/Other
### Affected platforms
Windows, I was *not* able test on other platforms
### Affected platform versions
all
### Did you find any workaround?
_No response_
### Relevant log output
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.