dotnet / dotnet/sdk

[iOS] Breakpoints not working when debugging on device

Open
#43,584 0 comments 0 reactions 0 assignees View on GitHub
Area-NetSDK untriaged
Dominant language
C#
Stars
3.2k
Forks
1.3k
PR merge metrics
PR metrics pending

Description

### Describe the bug
I have a project which consists of a main .NET 8 iOS App and a .NET 8 iOS Class Library. Everything seems to work properly on the iOS simulator but, for some reason, when I run the app on an iOS device (iPhone 14 - iOS 17.5.1) breakpoints on the class library are never triggered. Inspecting the VisualStudio Modules Window, I see that the Class Library project is not listed when debugging the app on the device.
I don't what is causing this exact issue but I have managed to create a simple repro that has a similar structure to my project and when I run that app on the device the same issue occurs. Weirdly, if I remove the line that calls the GroupBy() Linq method, the breakpoints start working again.

### To Reproduce
https://github.com/ricardommatias/ReproductionProject

### Further technical details
- I tested with both VS4Mac (17.6.14) and VS Code (1.93.1) and both have the same issue.
- Application output: [output.txt](https://github.com/user-attachments/files/17065760/output.txt)

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.