Skip to content
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

Blazor Webassembly - Debugger crashes app #66149

Closed
1 task done
softwaretirol opened this issue Mar 2, 2022 · 10 comments
Closed
1 task done

Blazor Webassembly - Debugger crashes app #66149

softwaretirol opened this issue Mar 2, 2022 · 10 comments
Assignees
Labels
arch-wasm WebAssembly architecture area-Debugger-mono needs-author-action An issue or pull request that requires more info or actions from the author. no-recent-activity

Comments

@softwaretirol
Copy link

softwaretirol commented Mar 2, 2022

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

If we start to debug our webassembly project, the app is crashing (With IIS Express or even without..).
The app works perfect if we dont attach the debugger, or if we remove the inspectUri from the launchSettings.json.

Any hints how we can diagnose this problem?

image

Expected Behavior

Debugger works like expected :-).

Steps To Reproduce

No response

Exceptions (if any)

Microsoft.WebAssembly.Diagnostics.DevToolsProxy[0] DevToolsProxy::Run: Exception System.AggregateException: One or more errors occurred. (Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')) ---> System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index') at System.Collections.Generic.List1.get_Item(Int32 index) at Newtonsoft.Json.Linq.JContainer.GetItem(Int32 index) at Newtonsoft.Json.Linq.JArray.get_Item(Object key) at Microsoft.WebAssembly.Diagnostics.MonoProxy.AcceptEvent(SessionId sessionId, String method, JObject args, CancellationToken token) at Microsoft.WebAssembly.Diagnostics.DevToolsProxy.OnEvent(SessionId sessionId, String method, JObject args, CancellationToken token) --- End of inner exception stack trace --- at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification) at System.Threading.Tasks.Task1.get_Result() at Microsoft.WebAssembly.Diagnostics.DevToolsProxy.Run(Uri browserUri, WebSocket ideSocket)

.NET Version

6.0.2

Anything else?

No response

@mkArtakMSFT
Copy link
Member

Thank you for filing this issue. In order for us to investigate this issue, please provide a minimalistic repro project (ideally a GitHub repo) that illustrates the problem.

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label Mar 3, 2022
@mkArtakMSFT mkArtakMSFT transferred this issue from dotnet/aspnetcore Mar 3, 2022
@ghost
Copy link

ghost commented Mar 3, 2022

Tagging subscribers to this area: @thaystg
See info in area-owners.md if you want to be subscribed.

Issue Details

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

If we start to debug our webassembly project, the app is crashing (With IIS Express or even without..).
The app works perfect if we dont attach the debugger, or if we remove the inspectUri from the launchSettings.json.

Any hints how we can diagnose this problem?

image

Expected Behavior

Debugger works like expected :-).

Steps To Reproduce

No response

Exceptions (if any)

Microsoft.WebAssembly.Diagnostics.DevToolsProxy[0] DevToolsProxy::Run: Exception System.AggregateException: One or more errors occurred. (Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')) ---> System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index') at System.Collections.Generic.List1.get_Item(Int32 index) at Newtonsoft.Json.Linq.JContainer.GetItem(Int32 index) at Newtonsoft.Json.Linq.JArray.get_Item(Object key) at Microsoft.WebAssembly.Diagnostics.MonoProxy.AcceptEvent(SessionId sessionId, String method, JObject args, CancellationToken token) at Microsoft.WebAssembly.Diagnostics.DevToolsProxy.OnEvent(SessionId sessionId, String method, JObject args, CancellationToken token) --- End of inner exception stack trace --- at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification) at System.Threading.Tasks.Task1.get_Result() at Microsoft.WebAssembly.Diagnostics.DevToolsProxy.Run(Uri browserUri, WebSocket ideSocket)

.NET Version

6.0.2

Anything else?

No response

Author: softwaretirol
Assignees: -
Labels:

untriaged, area-Debugger-mono

Milestone: -

@mkArtakMSFT
Copy link
Member

mkArtakMSFT commented Mar 3, 2022

@lewing FYI

@thaystg thaystg self-assigned this Mar 3, 2022
@thaystg
Copy link
Member

thaystg commented Mar 3, 2022

Can you please attach the Log that you can find at:
C:\Users[USER_NAME]\AppData\Local\Temp\visualstudio-js-debugger.txt
Please debug the app and after the application crashes you attach the log here.

Thanks for your help.

@lewing lewing added the needs-author-action An issue or pull request that requires more info or actions from the author. label Mar 3, 2022
@ghost
Copy link

ghost commented Mar 3, 2022

This issue has been marked needs-author-action since it may be missing important information. Please refer to our contribution guidelines for tips on how to report issues effectively.

@radical radical added the arch-wasm WebAssembly architecture label Mar 10, 2022
@ghost
Copy link

ghost commented Mar 10, 2022

Tagging subscribers to 'arch-wasm': @lewing
See info in area-owners.md if you want to be subscribed.

Issue Details

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

If we start to debug our webassembly project, the app is crashing (With IIS Express or even without..).
The app works perfect if we dont attach the debugger, or if we remove the inspectUri from the launchSettings.json.

Any hints how we can diagnose this problem?

image

Expected Behavior

Debugger works like expected :-).

Steps To Reproduce

No response

Exceptions (if any)

Microsoft.WebAssembly.Diagnostics.DevToolsProxy[0] DevToolsProxy::Run: Exception System.AggregateException: One or more errors occurred. (Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')) ---> System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index') at System.Collections.Generic.List1.get_Item(Int32 index) at Newtonsoft.Json.Linq.JContainer.GetItem(Int32 index) at Newtonsoft.Json.Linq.JArray.get_Item(Object key) at Microsoft.WebAssembly.Diagnostics.MonoProxy.AcceptEvent(SessionId sessionId, String method, JObject args, CancellationToken token) at Microsoft.WebAssembly.Diagnostics.DevToolsProxy.OnEvent(SessionId sessionId, String method, JObject args, CancellationToken token) --- End of inner exception stack trace --- at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification) at System.Threading.Tasks.Task1.get_Result() at Microsoft.WebAssembly.Diagnostics.DevToolsProxy.Run(Uri browserUri, WebSocket ideSocket)

.NET Version

6.0.2

Anything else?

No response

Author: softwaretirol
Assignees: thaystg
Labels:

arch-wasm, untriaged, area-Debugger-mono, needs-author-action

Milestone: -

@radical radical removed the untriaged New issue has not been triaged by the area owner label Mar 10, 2022
@radical
Copy link
Member

radical commented Mar 10, 2022

We could add some error checking to that code, like https://gist.github.com/radical/0cf3dc140068c05f3c2a988ddd9d89c8

@thaystg
Copy link
Member

thaystg commented Mar 14, 2022

Sure. Do you want to open the PR?

@ghost ghost added the no-recent-activity label Mar 28, 2022
@ghost
Copy link

ghost commented Mar 28, 2022

This issue has been automatically marked no-recent-activity because it has not had any activity for 14 days. It will be closed if no further activity occurs within 14 more days. Any new comment (by anyone, not necessarily the author) will remove no-recent-activity.

@ghost
Copy link

ghost commented Apr 11, 2022

This issue will now be closed since it had been marked no-recent-activity but received no further activity in the past 14 days. It is still possible to reopen or comment on the issue, but please note that the issue will be locked if it remains inactive for another 30 days.

@ghost ghost closed this as completed Apr 11, 2022
@ghost ghost locked as resolved and limited conversation to collaborators May 11, 2022
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
arch-wasm WebAssembly architecture area-Debugger-mono needs-author-action An issue or pull request that requires more info or actions from the author. no-recent-activity
Projects
None yet
Development

No branches or pull requests

7 participants