Skip to content

Microsoft.JSInterop.JSDisconnectedException: JavaScript interop calls cannot be issued at this time. This is because the circuit has disconnected and is being disposed.Β #4

@Wolfware2023

Description

@Wolfware2023

I found a new error int our log with this library:

Unhandled exception in circuit '"AXOSeY-MfXHMG7kocl7Xzql_DEwyYOURt6HSlUIy5kU"'.
Microsoft.JSInterop.JSDisconnectedException: JavaScript interop calls cannot be issued at this time. This is because the circuit has disconnected and is being disposed.
   at Microsoft.AspNetCore.Components.Server.Circuits.RemoteJSRuntime.BeginInvokeJS(Int64 asyncHandle, String identifier, String argsJson, JSCallResultType resultType, Int64 targetInstanceId)
   at Microsoft.JSInterop.JSRuntime.InvokeAsync[TValue](Int64 targetInstanceId, String identifier, CancellationToken cancellationToken, Object[] args)
   at Microsoft.JSInterop.JSRuntime.InvokeAsync[TValue](Int64 targetInstanceId, String identifier, Object[] args)
   at Microsoft.JSInterop.JSRuntimeExtensions.InvokeVoidAsync(IJSRuntime jsRuntime, String identifier, Object[] args)
   at Microsoft.JSInterop.Implementation.JSObjectReference.DisposeAsync()
   at Toolbelt.Blazor.FileDropZone.FileDropZone.OnAfterRenderAsync(Boolean firstRender)
   at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle, ComponentState owningComponentState)

Additional info:
We use the FileDropZone in a component used 4 times in one view. Mostly this works as expected. Just this error occurred once for one user so far.

We are currently still using .Net 6 and Blazor Server.
The app is hosted via IIS. The client browser I don't know. Likely Microsoft Edge.
Sadly the project is company property and cannot be shared.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions