BrowserDimensionWatcher.DisposeAsync lets JS-interop cancellation escape, surfacing a benign TaskCanceledException as an unhandled circuit error
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 1/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 76/100
Research direction
Start with MeshWeaver.Portal/Resize/BrowserDimensionWatcher.cs, especially DisposeAsync() around line 157; review OnAfterRenderAsync around line 97 for the related pattern. Check how the component disposes its JS object reference and handle cancellation or disconnection as described in the issue. Done when teardown no longer lets those exceptions escape; verify with the relevant component tests, if present.
Written by the indexing model from the issue text.
Description
What is failing
The portal's BrowserDimensionWatcher component fails its circuit teardown: its DisposeAsync disposes a JSObjectReference via JS interop, and when the circuit is already being torn down (client disconnect / tab close), that call surfaces as a TaskCanceledException that Blazor logs as a fatal unhandled circuit error (CircuitHost event 111).
Probable cause
High confidence. BrowserDimensionWatcher.DisposeAsync() (BrowserDimensionWatcher.cs, line 157) calls JSObjectReference.DisposeAsync() without catching cancellation. When the SignalR connection is gone, the pending InvokeVoidAsync is canceled by the circuit's token and the exception escapes DisposeAsync, which the renderer treats as an unhandled asynchronous disposal error. This is the exact case the Blazor guidance covers: JS interop in DisposeAsync must catch JSDisconnectedException / OperationCanceledException. The defect is ours — unlike the sibling incident for this log category (7439658a1a28dfa0, filed as Systemorph/MeshWeaver#5362), the top application frame here is portal code, not the framework's RemoteNavigationManager, so this is not a duplicate of that ticket. The same component has form for throwing during JS interop: Ops/Logs/memex-cloud-1790087318865198321-4645f8-8pdzb (2026-09-22) shows it throwing out of OnAfterRenderAsync (line 97).
Impact
None in practice — a single occurrence on one pod, in a circuit that was already being disposed because the client left. No data loss, no user-visible failure beyond the disconnect itself. Worth fixing because the fix is trivial and it keeps the noisy CircuitHost[111] channel clean for real errors; alternatively, if the team prefers, this shape could be suppressed at the log-filter level instead.
Where to look
MeshWeaver.Portal/Resize/BrowserDimensionWatcher.cs — DisposeAsync() at line 157 (and, for the same pattern, OnAfterRenderAsync around line 97). Wrap the JSObjectReference.DisposeAsync() call in a try/catch for OperationCanceledException and JSDisconnectedException, per the standard Blazor Server disposal pattern.
Evidence
| Fingerprint | 160407785cd655f5 |
| Category | Microsoft.AspNetCore.Components.Server.Circuits.CircuitHost |
| Severity | Error |
| Exception | System.Threading.Tasks.TaskCanceledException |
| Top frame | MeshWeaver.Blazor.Portal.Resize.BrowserDimensionWatcher.DisposeAsync() |
| Namespace | memex-cloud |
| Pods | memex-portal-deployment-546888968f-9fx75 |
| Occurrences | 1 |
| First seen | 2026-10-03 06:27:35Z |
| Last seen | 2026-10-03 06:27:35Z |
| Routing | not determined — no configured route matches the category Microsoft.AspNetCore.Components.Server.Circuits.CircuitHost. This repository is the configured fallback, not a finding about who owns the fault; the category names the LOGGER, which may not be the subject. |
Recent log lines
2026-10-03 06:27:35Z memex-portal-deployment-546888968f-9fx75 fail: Microsoft.AspNetCore.Components.Server.Circuits.CircuitHost[111]
Unhandled exception in circuit '0jKRXVKmiBdRPvxB3Vpi_hbJJCFhDAkK1B0V8pYEjZM'.
System.Threading.Tasks.TaskCanceledException: A task was canceled.
at Microsoft.JSInterop.JSRuntime.InvokeAsync[TValue](Int64 targetInstanceId, String identifier, JSCallType callType, Object[] args)
at Microsoft.JSInterop.JSRuntimeExtensions.InvokeVoidAsync(IJSRuntime jsRuntime, String identifier, Object[] args)
at Microsoft.JSInterop.Implementation.JSObjectReference.DisposeAsync()
at MeshWeaver.Blazor.Portal.Resize.BrowserDimensionWatcher.DisposeAsync() in /home/runner/work/MeshWeaver/MeshWeaver/plugins-repo/src/MeshWeaver.Blazor.Portal/Resize/BrowserDimensionWatcher.cs:line 157
at Microsoft.AspNetCore.Components.RenderTree.Renderer.<ProcessDisposalQueueInExistingBatch>g__GetHandledAsynchronousDisposalErrorsTask|99_0(Task result)
Opened automatically from Admin/_LogIncident/160407785cd655f5. Recurrences are folded into this issue rather than opening new ones.
It also stands for the whole log site d85dd830f4de07a8: other fingerprints of this site fold in here as comments rather than opening tickets of their own.
- Dominant language
- C#
- Stars
- 12
- Forks
- 5
- Avg merge
- 5h 57m
- Merged PRs (30d)
- 967
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Systemorph/MeshWeaver
-
bug sev:H
Difficulty 4/5 3-5 days Newbie friendliness 20/100
Systemorph/MeshWeaver#7018 · 1 comment ·
Maintainers usually reply within 1 day
-
bug sev:L
Difficulty 4/5 3-5 days Newbie friendliness 35/100
Systemorph/MeshWeaver#7002 ·
Maintainers usually reply within 1 day
-
bug sev:L
Difficulty 4/5 3-5 days Newbie friendliness 25/100
Systemorph/MeshWeaver#7003 ·
Maintainers usually reply within 1 day
-
Terminal NotFound NACK undeliverable to a portal hub whose pod-hub registration was already releasedOpenbug sev:L
Difficulty 4/5 3-5 days Newbie friendliness 35/100
Systemorph/MeshWeaver#7001 ·
Maintainers usually reply within 1 day
-
bug sev:H
Difficulty 4/5 3-5 days Newbie friendliness 45/100
Systemorph/MeshWeaver#6989 · 3 comments ·
Maintainers usually reply within 1 day
All issues in Systemorph/MeshWeaver
Similar issues
-
/api/oauth/introspect emits clientId and tokenType instead of RFC 7662's client_id and token_typeOpenbug P2
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
nightscout/nocturne#2317 ·
Maintainers usually reply within 1 day
-
[BUG]: Position intent set on a simple order is dropped when it becomes a bracket, OCO or OTO orderPossibly taken @RaphaelFakhri claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
alpacahq/alpaca-trade-api-csharp#903 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
joinrpg/joinrpg-net#5752 ·
Maintainers usually reply within 1 day
-
bug ux
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
CodeForFire/lagebuch#714 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
dimitar-radenkov/Pointframe#294 ·
Maintainers usually reply within 1 day