I have a function app deployed into Azure and I would like to remote debug it.
I have tested 32 and 64 bit platform
I have tried manually to "attach to the process" with the port requested in the microsoft documentation regarding Visual studio versions
I have tried from a VM in Azure
I have deactivated firewall in the VM
I have added an outbound rule will all permissions in the vm network settings
I have tried with VS 2019 version and the "Cloud explorer view"
I have tried with VS 2022 (Up to date --> Version 17.3.2) with "connected services"
And I always get this error:
System.Runtime.InteropServices.COMException (0x89710023): Unable to connect to the Microsoft Visual Studio Remote Debugger named 'HOSTNAME.azurewebsites.net:4024'. The input data was not in the expected format or did not have the expected value.
at Microsoft.WebTools.Azure.VS.Operations.IDebuggerInternal120.ConnectToServer(String szServerName, VsDebugRemoteConnectOptions[] pConnectOptions, CONNECT_REASON ConnectReason, Int32 fIncrementUsageCount, IDebugCoreServer3& ppServer) at Microsoft.WebTools.Azure.VS.Operations.RemoteDiagnosticsSessionBase`1.ConnectToServer(String hostNameWithPort, String user, String password)
Any idea how to fix?
Please check the following steps to remote debug in Visual Studio 2022:
Open Site
to check the function app is up and running. And then click Attach debugger
on Hosting options ( ...
) in the VS Publish window.It will take some time to attach the w3wp process automatically and activating the breakpoint we placed in the Function Code.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.