#13870·MudBlazor

System.InvalidOperationException in PersistentComponentState

Author: IngoMantheyCreated Sep 15, 2026Updated Sep 15, 2026
Labelsbugneeds: example

Before reporting

  • I searched existing issues
  • I tried in private/incognito browser

What went wrong?

System.InvalidOperationException: Cannot update existing state: previous state has not been cleared or state is not initialized. File "PersistentComponentState.cs", line 249, in void PersistentComponentState.UpdateExistingState(IDictionary<string, byte[]> state, RestoreContext context) throw new InvalidOperationException("Cannot update existing state: previous state has not been cleared or state is not initialized."); File "ComponentStatePersistenceManager.cs", line 80, in async Task ComponentStatePersistenceManager.RestoreStateAsync(IPersistentComponentStateStore store, RestoreContext context) State.UpdateExistingState(data, context); File "CircuitHost.cs", line 874, in async Task CircuitHost.EnqueueRestore(TaskCompletionSource taskCompletionSource, ComponentStatePersistenceManager manager, RestoreContext context, IPersistentComponentStateStore store) await manager.RestoreStateAsync(store, context);

System.AggregateException: A Task's exception(s) were not observed either by Waiting on the Task or accessing its Exception property. As a result, the unobserved exception was rethrown by the finalizer thread.

Unfortunately, I couldn't figure out where the call took place.

Reproduction link

can not create

Reproduction steps

Version (bug)

9.9.0

Version (working)

9.8.0

Environment

Chrome

Blazor rendering mode

Server