AL icon indicating copy to clipboard operation
AL copied to clipboard

Debugging Sorry, that didn't work

Open gnaaktgeboren opened this issue 8 years ago • 8 comments

When I try to debug the webclient gives the error Sorry, that didn't work I've disable the NetFx40_LegacySecurityPolicy. <configuration> <configSections> </configSections> <appSettings file="D:\Program Files\Microsoft Dynamics NAV\110\Service\Instances\NAV110-NAP-DEVELOPMENT\CustomSettings.config" />\ <runtime> <NetFx40_LegacySecurityPolicy enabled="false"/> </runtime> </configuration> What am I doing wrong?

gnaaktgeboren avatar Feb 20 '18 13:02 gnaaktgeboren

I have a similar issue - if the debugger hits a breakpoint it just hangs -- resulting in the "Sorry.." error. Symbol download, app publish, app run -- all work fine, I just can't debug.

I have disabled the security policy - <NetFx40_LegacySecurityPolicy enabled="false"/> I have made sure the server is properly configured for development. I have run symbol generation. I have setup the launch.json and app.json as per other input in this forum. I am using a vanilla Cronus database.

If I watch the network traffic in the browser debugger I see this rather fatal looking error: HTTP502: BAD GATEWAY - The server, while acting as a gateway or proxy, received an invalid response from the upstream server it accessed in attempting to fulfill the request. (XHR)POST - http://localhost:8080/dynamicsnav110/cbs?aid=NAV

If I look in the Event Viewer on the server I see the ominous error listed below. Obviously this is telling me something is misconfigured -- but I can't figure out what. Anybody ?

Event Viewer error on server: instanceName DynamicsNAV110 message Failed request -- Method:GET; Url:http://localhost:7049/DynamicsNAV110/dev/signalr/start?clientProtocol=1.4&transport=webSockets&connectionData=[{"Name":"DebuggerHub"}]&connectionToken=AQAAANCMnd8BFdERjHoAwE%2FCl%2BsBAAAAiVyPfhFbpEiuF5dQhiT8LQAAAAACAAAAAAAQZgAAAAEAACAAAACaIH6pZZVlHkcc8y%2BDL6sny1rLA94tOomMyDdVsQJYhwAAAAAOgAAAAAIAACAAAADWFwDLWKEAtibK3cf3yhpswNM2FqyhUb%2B6pzHq5OJorEAAAAAIzvOeu6lwnuLVFvPl6qxRqvSZh%2Fd%2B4NeXp0YanLu3xpK69mRpyE6L6w26%2FRn3fsFMZkxHoNTAw2wbbn2OyxjuQAAAAJ9tX8a7sbUFjO5tNLF6UNIJjMqerHShvF5ACEmxnlG0kR6xHkVKyBI2LI4fJ6muClFCTyGwDJQRtde%2FOmBQubs%3D; StatusCode:NotFound; ReasonPhrase:Not Found; ResponseBody: {"Message":"No HTTP resource was found that matches the request URI 'http://localhost:7049/DynamicsNAV110/dev/signalr/start?clientProtocol=1.4&transport=webSockets&connectionData=[{"Name":"DebuggerHub"}]&connectionToken=AQAAANCMnd8BFdERjHoAwE%2FCl%2BsBAAAAiVyPfhFbpEiuF5dQhiT8LQAAAAACAAAAAAAQZgAAAAEAACAAAACaIH6pZZVlHkcc8y%2BDL6sny1rLA94tOomMyDdVsQJYhwAAAAAOgAAAAAIAACAAAADWFwDLWKEAtibK3cf3yhpswNM2FqyhUb%2B6pzHq5OJorEAAAAAIzvOeu6lwnuLVFvPl6qxRqvSZh%2Fd%2B4NeXp0YanLu3xpK69mRpyE6L6w26%2FRn3fsFMZkxHoNTAw2wbbn2OyxjuQAAAAJ9tX8a7sbUFjO5tNLF6UNIJjMqerHShvF5ACEmxnlG0kR6xHkVKyBI2LI4fJ6muClFCTyGwDJQRtde%2FOmBQubs%3D'.","MessageDetail":"No route data was found for this request."}

quadfin avatar Feb 20 '18 18:02 quadfin

Hi, we would like to ask for some additional information. @gnaaktgeboren - could you please provide Event Log error? We would like to see if this is indeed the same error that both of you are facing.

In addition, which versions of the NAV server and AL Language extension are you using? Are you on the latest February Developer Preview?

StanislawStempin avatar Feb 21 '18 10:02 StanislawStempin

Hi,

I've attached the errors as a text file.

The versions that I'm using are: AL extension 0.12.16641 NAV version CU2 (11.0.20348.0).

Nav errors.txt

gnaaktgeboren avatar Feb 21 '18 10:02 gnaaktgeboren

Hi @gnaaktgeboren, Try signing out and signing in again. It solved the error for me. Although I was not getting any error in VSCode, just the webclient would crash.

olisterr avatar Feb 21 '18 11:02 olisterr

Hi @olisterrcf ,

Just tried that, no luck.

gnaaktgeboren avatar Feb 21 '18 12:02 gnaaktgeboren

@gnaaktgeboren have you restarted the server after setting the <NetFx40_LegacySecurityPolicy enabled="false"/> ?
Your error log shows that this setting is still enabled.

StanislawStempin avatar Feb 21 '18 12:02 StanislawStempin

@StanislawStempin I just did that again but with no luck.

gnaaktgeboren avatar Feb 21 '18 13:02 gnaaktgeboren

Thanks. Since you're on NAV 2018 and this potentially requires deeper investigation please log a support case for your problem: https://github.com/Microsoft/AL/wiki/Frequently-Asked-Questions#nav-2018-issues

StanislawStempin avatar Feb 21 '18 13:02 StanislawStempin