dotnet / dotnet/project-system

Unable to debug source generator: "The project doesn't know how to run the profile '<name>' with command 'DebugRoslynComponent'"

Open
#9,547 7 comments 0 reactions 0 assignees View on GitHub
Feature-Debugging Triage-Approved
Dominant language
C#
Stars
1k
Forks
415
PR merge metrics
No merged PRs in 30d

Description

## Visual Studio Version
2022.17.11.4 (Community edition)

## Summary
As title.

Suspect that the work done in https://github.com/dotnet/roslyn-sdk/pull/896 for https://github.com/dotnet/roslyn-sdk/issues/850 has either been reverted or broken.

## Steps to Reproduce
1. Clone https://github.com/riok/mapperly
2. Attempt to debug source generator in Visual Studio by following https://mapperly.riok.app/docs/contributing/debugging/#integration-tests
3. Get error
![image](https://github.com/user-attachments/assets/6ffdfd05-88f4-4929-8184-4ddb2ef1ec9a)

Creating a new "Roslyn Component" launch profile is also not possible, as that option is missing from the "Launch Profiles" UI
![image](https://github.com/user-attachments/assets/a7d6f1ac-3812-4f60-89b8-d999bdb01e68)

## Expected Behavior
Source generator debugging works

## Actual Behavior
Source generator debugging does not work

## User Impact
Can't debug source generators

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.