Repository navigation
fix(blazor): remove the async pending race and gate every configuration - #68
Merged
kieronlanning merged 3 commits intoNov 11, 2026
Merged
Conversation
The async field validation suspends at its first await and queues its continuation on the renderer's dispatcher. Sampling IsValidationPending after the InvokeAsync call returned raced that continuation: on the Release Linux runner it resolved first, so the test asserted False. Read the state inside the same dispatcher work item, where the continuation cannot run yet.
The shared pipeline runs a single configuration (Release), so Debug - the configuration just test uses locally - was never exercised in CI. Add a Debug job that builds the solution and runs every test, keep run-tests explicit on the Release gate, and guard both with ReleaseGateTests. Pin build-version to the 0.9.0 in .config/dotnet-tools.json so CI runs what local runs and stops warning about an unpinned tool.
kieronlanning
deleted the
fix/blazor-async-pending-and-all-config-tests
branch
November 11, 2026 22:25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes the release failure in run 43066439932 and closes the coverage gap that let it reach main.
1. The failing test was a race
DataAnnotationsValidator_GivenAsyncOnlyMemberFieldChange_IsPendingThenShowsTheError sampled
editContext.IsValidationPending(field)afterawait form.InvokeAsync(...)returned. The async field validation suspends atTask.Yield()and queues its continuation on the renderer's dispatcher, so on the faster Release/Linux run the continuation resolved and cleared pending before the test thread resumed. The test now reads the state inside the same dispatcher work item, where the continuation is still queued, making the assertion deterministic rather than timing-dependent.PackModule failed only because it depends on RunTestsModule.
2. Every configuration is now gated
The shared pipeline runs a single configuration (Release). Debug - what
just testuses locally - was never exercised in CI.pr.ymldebugjob that builds the whole solution and runs every test in Debug.run-tests: trueexplicit on the Release gate.ReleaseGateTests.PrWorkflow_GivenTheTestGates_RunsEveryTestInBothConfigurationsso neither gate can be silently removed.build-version: 0.9.0(matching.config/dotnet-tools.json) inpr.ymlandrelease.yml, which also clears the "Unpinned build tool" warning.docs/wiki/development/Release-Flow.md.Verification
dotnet csharpier check .: clean (703 files).just pipeline-pr(the failing pipeline): 9 modules passed,PackValidation 16/16packages valid.