-
Notifications
You must be signed in to change notification settings - Fork 522
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for .NET debugging on Apple M1 (and ARM64) #2884
Comments
Is the 'blocked' tag for awaiting the release of vsdbg? |
Yes. |
@philliphoff where is this vsdbg being tracked? |
As of 25 May, the debugger acquisition scripts have been updated to return arm64 flavors, so we should now be unblocked. |
when is this expected to release? currently it is blocking any docker dependent dev stuff on MAC M1 :(. tried to use linux/amd64 based images but that is failing to start the app due to .net core is based on ARM not AMD. not sure my analysis is correct or not! |
@Vikas413 probably in the next extension release. They happen every month, typically |
So, it looks like OmniSharp doesn't yet support arm64 in general (e.g. Also, since we pull down the debuggers during debug configuration resolution, which is before the image is actually created, we don't have an easy way to determine the architecture of the resulting image. (There will be many factors that funnel into that, from the architecture of the host, to the architectures supported by the base image, to platform parameters passed to the build command (directly or via environment variables), etc.) I'm not sure if there's a much better way than just pulling them all down, ideally in parallel in order to minimize the extra hit. |
@Vikas413 @Jonatthu @jp4u There is now some limited support for Let me know if you run into problems. |
@philliphoff now it is different issue, check below log. Failed to create CoreCLR, HRESULT: 0x8007FF06 I am using default docker file which is been generated by project template as given below.
any thought? how to resolve this. |
@Vikas413 It looks like you're trying to debug in an |
@philliphoff yes, you are correct I am trying to debug, as that' what is most important thing for developers like me. what are our options here? even running it in release mode is also failing with below error. HelloWorld/HelloWorld.csproj HelloWorld/ breaking at 'RUN dotnet restore "HelloWorld/HelloWorld.csproj"' step |
@Vikas413 I see the same thing when running an The only suggestion I have, which works for me, is to remove the |
@philliphoff Has there been any recent updates to this topic? I tested your suggestion in the last comment by removing the platform flag and even tested specifying platform tag as --platform=arm64 inside the dockerfile but I'm still receiving errors. I attempted attaching to pre-existing container spun up via docker compose as well as letting the debugger build the container from vs code. Container won't even build without crashing from debugger but when attaching to pre-existing it seems to come closer to working but when I set a break point it crashes the debugger with an attach error. Here's my Dockerfile:
If I try to attach from within the container with attached vscode I get this: |
Marking as blocked for now; there's things we need from external (.NET 6 GA, Omnisharp support, etc.). |
.NET 6 is now GA'd. Omnisharp support has not yet arrived but seems to be close. I will move this to 1.20 since it will take time for that to become available. |
@philliphoff is there anything more that needs to be done for this? |
Discussed offline, @philliphoff will try out arm64 alpine container debugging (where breakpoints were not being hit but everything else appeared to work), to see if that issue still occurs. Other than that we will close this and await user feedback. |
It looks like |
Awesome! We'll close this for now then, and await further feedback. |
Updated debuggers for .NET are coming soon that support
arm64
(in particular, the Apple M1). We need some changes to our debugging infrastructure to ensure the proper debugger is used within aarm64
container. See the PoC. The logic could be a bit more nuanced to eliminate downloading debuggers unnecessarily, and the "attach" scenario needs updating as well.Test matrix for launch and attach scenarios:
qemu: uncaught target signal 11 (Segmentation fault) - core dumped
qemu: uncaught target signal 11 (Segmentation fault) - core dumped
The text was updated successfully, but these errors were encountered: