Skip to content

[DO NOT MERGE] CI vehicle for #2095 — .NET 10 experiment chain - #2111

Draft
NickJosevski wants to merge 5 commits into
mainfrom
nj/net10-prep-deps-v2-ci
Draft

[DO NOT MERGE] CI vehicle for #2095 — .NET 10 experiment chain#2111
NickJosevski wants to merge 5 commits into
mainfrom
nj/net10-prep-deps-v2-ci

Conversation

@NickJosevski

Copy link
Copy Markdown
Contributor

Do not merge. Do not review. This PR exists only so TeamCity can build the contents of #2095.

Why this exists

#2095 targets nj/deps-cve-test-tooling (it is stacked on #2094). The .NET 10 experiment chain's
pullRequests build feature filters on filterTargetBranch = %VCSRoot.DefaultBranch%, so TeamCity
never creates a pull/2095 logical branch — which is why +:pull/2095 was already in the ChainFull
branch filter and still matched nothing.

This PR targets main, so it gets a real pull/<this number> branch that can be wired into the
trigger filter.

What to wire up

  • .NET 10 experimentTeamModernDeployments_Calamari_Experiments_Dotnet10_Chains_ChainFull,
    trigger TRIGGER_155: add +:pull/<this number>
  • Calamari vNext..._VNext_Chains_ChainFull: add -:pull/<this number> so this does not
    also run the live 58-build chain. Without this, every push doubles agent load. Same treatment
    [WIP] .NET 10 experiment #2110 documents.

Contents

Identical to nj/net10-prep-deps-v2 at c349943b6 — i.e. #2094 + #2095 combined, since #2095 is
stacked on #2094. Deliberately not rebased onto current main, so CI tests exactly what is in
#2095 rather than a different tree.

Commit From
Upgrade test dependencies carrying known vulnerabilities #2094
Remove framework-provided package references #2095
Upgrade Autofac 4.8.0 -> 9.3.1 #2095
Align remaining dependency versions #2095
Let dotnet-script roll forward to a newer .NET runtime #2095
Align Serilog versions with Microsoft.Extensions.Logging 10.0.10 #2095

Re-syncing after new commits on #2095

git push origin +nj/net10-prep-deps-v2:nj/net10-prep-deps-v2-ci

Caveat on what a green run here proves

Product code on this branch is still net8. A green chain proves the dependency bumps hold; it
does not validate the dotnet-script change. DOTNET_ROLL_FORWARD=Major is a no-op whenever an
8.x runtime is present, so on any agent that has .NET 8 the roll-forward path is never taken.
Exercising it needs an environment with .NET 10 and no 8.x runtime. See
research/dotnet-script-net10.md in the migration notes.

Close this once #2094 lands and #2095 retargets to main.

🤖 Generated with Claude Code

@NickJosevski
NickJosevski marked this pull request as draft August 5, 2026 12:10
@NickJosevski
NickJosevski force-pushed the nj/net10-prep-deps-v2-ci branch from 5a197ad to a9c3d46 Compare August 7, 2026 04:32
NickJosevski and others added 5 commits August 7, 2026 15:40
Five transitive advisories exist on main today. One is critical.

.NET 10's transitive package auditing surfaced the advisories. Auditing did not
create them. The net8 SDK does not audit transitives at restore.

WireMock.Net goes to 2.13.0. That clears Scriban.Signed 5.5.0 with 13 advisories,
System.Linq.Dynamic.Core 1.3.12 and RestSharp 110.2.0.
System.DirectoryServices.AccountManagement goes to 10.0.10, clearing
System.DirectoryServices.Protocols 4.7.0. RestSharp is pinned to 112.1.0 in
Calamari.Testing, clearing the version reached through Octopus.1Password.Sdk.

Scope is build-time exposure only. Nuke packs Calamari.Contracts and
Calamari.ConsolidateCalamariPackages and nothing else. Calamari.Testing declares a
PackageId but nothing packs it. No shipped artifact changes.

WireMock 1.x to 2.x is a major bump. All 13 call sites were exercised behaviourally
rather than just compiled. 9 tests pass.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Calamari.csproj still referenced Microsoft.NETFramework.ReferenceAssemblies.net462.
That reference has done nothing since net462 was dropped as a target framework in
#1669.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Autofac 4.8.0 dates from 2018 and is five majors behind. Octopus Server already
runs 9.3.1 on net10.

Done while Calamari still targets net8. Autofac 9.3.1 resolves on net8. The DI
upgrade is therefore verified against a known-good baseline instead of being
entangled with the framework change.

Notes for reviewers. ContainerBuilder.Update() is the headline Autofac 5 removal
and was never used here. The .Update call sites in this repo belong to LibGit2Sharp.
The API surface in use is mainstream and unchanged across the version range. The
custom RegisterPrioritisedList<T> extension builds on Meta<T> and WithMetadata.
Both APIs are stable.

Verified: clean rebuild with no new warnings. 26 tests pass covering the custom
registration ordering and flavour resolution.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Bundled dotnet-script 1.6.0 is a framework-dependent app targeting
Microsoft.NETCore.App 8.0.0. Framework-dependent apps do not roll forward across a
major version by default. On a machine with only .NET 10 installed dotnet-script
fails to launch.

Calamari itself is unaffected. Calamari ships self-contained. The failure is in the
separate dotnet-script process.

Setting DOTNET_ROLL_FORWARD=Major on that invocation lets dotnet-script run on
whatever newer runtime is present. An explicit value already set in the environment
is respected rather than overwritten.

This is a customer-facing fix as much as a CI one. Without the fix a target with
.NET 10 and no .NET 8 runtime cannot run C# script steps at all.

SilentProcessRunner applies EnvironmentVars additively. Passing a dictionary where
one was previously null does not discard the inherited environment.

Not done here: upgrading the bundled dotnet-script. The 2.0.1 release zip Calamari
vendors is still net8 targeted. Only the NuGet package ships a net10 build. The upgrade
also changes the NuGet version dotnet-script bundles. The change invalidates the
premise of UsingIsolatedAssemblyLoadContext.

Verified: 10 DotnetScriptFixture tests pass.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Net8-safe preparatory change, so main carries it before the TFM flip lands.

KubernetesContextScriptWrapperLiveFixtureEks.UsingEc2Instance provisions a
Debian 12 EC2 instance via terraform, uploads the built test assemblies and
runs `dotnet test Calamari.Tests.dll` on it. test.sh installed only
dotnet-sdk-8.0, so once those assemblies become net10.0 the instance cannot run
them, and the non-zero exit surfaces as a terraform remote-exec provisioner
failure ("Process exited with status 145"). That is exactly what happens on
#2091 today: the test failed 5/5 there and passed 25/25 on every other branch,
including main and this one.

Installing 10.0 alongside 8.0 keeps this branch working on net8 while removing
the blocker for the net10 flip. dotnet-sdk-10.0 is published in the feed
test.sh already configures (packages.microsoft.com/debian/12, bookworm main
binary-amd64).

Debian 12 ships glibc 2.36, so this is unrelated to .NET 10's 2.27 floor - it
is purely a hardcoded SDK version in the test harness.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@NickJosevski
NickJosevski force-pushed the nj/net10-prep-deps-v2-ci branch from a9c3d46 to 4c549d7 Compare August 7, 2026 05:43
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