Skip to content

fix: isolate .NET 11 Razor support in preview builds - #11176

Merged
vicancy merged 1 commit into
mainfrom
codex/fix-net11-razor
Sep 24, 2026
Merged

vicancy merged 1 commit into
mainfrom
codex/fix-net11-razor

Conversation

@vicancy

@vicancy vicancy commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Related to #11171.

Add opt-in net11.0 DocFX assets for the .NET 11 RC1 Razor source generator while preserving stable compiler dependencies in ordinary builds. Measure every nightly tool target so the compatibility report exposes both the fix and the older tools' remaining limitations.

  • Normal builds target net8.0/net9.0/net10.0 with Roslyn 5.6/5.6/5.9. A single RoslynVersion property selects the version per target for all eight compiler packages. DOCFX_PREVIEW_BUILD=true additionally builds net11.0 with Roslyn 5.11.0-1.26425.128; the public preview restore source and experimental symbol API adaptations apply only to net11.0.
  • Nightly builds and tests all four targets. Each nightly net8.0/net9.0/net10.0/net11.0 tool runs all five SDK/project pairs and both Basic/Razor scenarios: 40 nightly cases plus 10 released net10.0 controls, 50 total. PR smoke remains net10.0.
  • Installations, work directories, and logs are isolated by tool target. Reports distinguish requested and observed tool targets, reject incomplete matrices and fallback runtimes presented as measured results, and display the target in page headers and CI summaries. Earlier reports remain readable with their original coverage.

Tool target and project target are independent. SDK 11 Razor projects need the net11.0 preview tool even when the project targets net10.0. Older tools retain stable Roslyn and their incompatibilities remain visible. Direct consumers of the preview Docfx.Dotnet net11.0 library assets also need Microsoft's public dotnet-tools source.

Full test and 50-case matrix evidence at 1dd3822:

  • PR CI passes on Windows, macOS, and Linux, including net10.0 packaged smoke. Format, coverage, and visual checks pass.
  • Validation-only nightly passes four target-framework test suites, packaging, installed-tool checks, and reporting. Its 50-case report and logs record the clean commit, exact tool targets, and consistent package hashes. All cases were measured: 40 passed, 10 incompatible, no unavailable cases or infrastructure errors.
Package Tool target Passed Incompatible
Latest stable net10.0 8 2
Nightly net8.0 7 3
Nightly net9.0 7 3
Nightly net10.0 8 2
Nightly net11.0 10 0

The net8.0/net9.0 tools are incompatible with SDK 10 and SDK 11 Razor; the net10.0 tools are incompatible with SDK 11 Razor. SDK 11 is tested with both net10.0 and net11.0 projects. These observations remain visible and do not block reporting mode.

All 55 reporting tests pass, including 50 distinct case identities, missing-target and fallback detection, package identity, rendering, and archive export. A local 24-case comparison also completes without environment errors. Inspection of the actual package confirms stable Roslyn for net8.0/net9.0/net10.0 and preview Roslyn only for net11.0.

Current-head verification (f8eb636c2): complete normal and preview solution restores pass. The resolved dependency graphs for all four targets match the previous configuration exactly, including the net8.0/net9.0 exact version pins; ordinary restore uses no preview feed.

@vicancy
vicancy marked this pull request as ready for review September 24, 2026 01:39
@vicancy
vicancy force-pushed the codex/fix-net11-razor branch from 79e7954 to 736e451 Compare September 24, 2026 01:41
@vicancy
vicancy marked this pull request as draft September 24, 2026 02:31
@vicancy
vicancy force-pushed the codex/fix-net11-razor branch from 736e451 to 4448c36 Compare September 24, 2026 02:38
@vicancy vicancy changed the title fix: support Razor metadata extraction with .NET 11 SDK fix: isolate .NET 11 Razor support in preview builds Sep 24, 2026
@vicancy
vicancy marked this pull request as ready for review September 24, 2026 02:43
@vicancy
vicancy force-pushed the codex/fix-net11-razor branch 2 times, most recently from 1dd3822 to d0c5801 Compare September 24, 2026 05:34
@vicancy
vicancy force-pushed the codex/fix-net11-razor branch from d0c5801 to f8eb636 Compare September 24, 2026 05:38
@vicancy
vicancy merged commit ac91100 into main Sep 24, 2026
9 checks passed
@vicancy
vicancy deleted the codex/fix-net11-razor branch September 24, 2026 07:45
This was referenced Sep 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant