Release 1.1.0 - #42
Merged
Merged
Conversation
A minor rather than a patch. Nothing in the public API breaks, but the Runtime
package gains two members - [Intercept].Realm and a four-argument
DecoratorHelper.Decorate overload - and three diagnostics arrive. Both of those
are minor-version events under semver, and 1.0.0 said new diagnostics would come
in a minor release.
Version, changelog, and the analyzer release file moving DM0017-DM0019 from
unshipped to shipped.
Three documentation corrections that should not ship as they stand:
* The diagnostics reference said `dotnet_diagnostic.DM0005.severity = none`
had no effect. It works, including for the error-severity codes - verified
three ways on SDK 10.0.302: no .editorconfig gives two errors, severity=none
gives zero, removing it again gives two. What .editorconfig genuinely cannot
do is raise a severity, because a generator's diagnostics arrive with theirs
already fixed. Both halves are now stated, and the DM0018 descriptor comment
that told readers to promote it that way is corrected.
* DM0010 and DM0011 were described as never appearing in `dotnet build` at any
verbosity. They appear at -v detailed.
* DM0012 described the opposite of what the generator emits. A condition with
nothing to test cannot be false, so the guard is `if (true)` and the service
registers unconditionally; the page said it never registers.
DM0017, DM0018 and DM0019 are now documented on the reference page, including
that the two error-severity codes fire on shapes that previously built green -
so no working program breaks, but a build carrying one goes red on upgrade.
Verified: 1,830 tests, 0 warnings, scripts/verify-packages.sh green for net8.0
and net10.0, docs site builds with dead-link checking on. Separately, the four
applications written against 1.0.0 during the evaluation were re-run against
this build: 218 of 224 pass unchanged, and all six failures are the tests that
were pinning the defects this release fixes.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01R9DWh8FWTib6hRYURbypWU
The assembly version is part of assembly identity, so moving it every minor release means a library compiled against 1.0.0.0 no longer matches the version a consuming application resolves, and the reference only keeps working because the host papers over the difference. Holding it removes the question and costs nothing: FileVersion and AssemblyInformationalVersion carry the real version, and the package version is what anyone depends on. It moves at 2.0.0. Verified in the packed 1.1.0 package: AssemblyVersion 1.0.0.0, FileVersion 1.1.0.0, InformationalVersion 1.1.0+sha. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R9DWh8FWTib6hRYURbypWU
A module's identity is genuinely ambiguous once it carries parameters, and the generator picks type-only on the developer's behalf either way - so the choice is being made regardless, and only a warning makes it visible. Informational could never have been opted into: a generator's diagnostics arrive with their severity already fixed, so nothing can raise an Info into a build. Promoting it exposed a false positive in the condition, which counted every property. A read-only property is not a parameter - a module implementing an interface with `public string Value => "A";` has nothing anyone can configure, and the generated attribute never assigns it. The condition now mirrors exactly what ModuleAttributeWriter carries across: settable and non-static. That took the diagnostic from ten modules in this repository's own integration tests to three, and the seven that dropped out were all get-only properties implementing an interface. The three that remain are true positives and now declare their identity rather than being exempted, one of each shape: ParameterizedModule by its values, ArrayParameterModule by its type stated explicitly, DefaultedParameterModule by its values because two composers carry different ones. Zero warnings again. Seven tests added. Three of them fail against the old condition. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01R9DWh8FWTib6hRYURbypWU
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.
Version bump, changelog, analyzer release tracking, and three documentation
corrections that should not ship as they stand.
Why 1.1.0 and not 1.0.1
Nothing in the public API breaks — but two members are added to the Runtime
package, and adding public API is a MINOR event under semver, not a patch:
InterceptAttribute.RealmDecoratorHelper.Decorate<TService>(…, Type? implementationType)— a newoverload; the three-argument one is untouched, so generated code from 1.0.0
still binds.
Three diagnostics also arrive, and 1.0.0 already set the rule for that: "New
ones may be added in a minor release."
DependencyModules.SourceGenerator.Impldoes change incompatibly —LocationModelmoved namespace andModuleEntryPointModel's constructor gaineda required third parameter — but 1.0.0 put those extension points outside the
versioning promise explicitly, and the changelog records what moved.
Upgrade note, stated prominently in the changelog
DM0017andDM0019are errors on code that compiled before. Both fire onlyon shapes that built green and registered nothing, so no working program breaks —
but a build carrying one goes red on upgrade.
NoWarnand.editorconfigbothsilence them if the work needs staging.
Separately: an interceptor now applies only to the implementation it was declared
on, so a sibling implementation that was being intercepted stops being
intercepted. It was never asked for.
Documentation corrections
1. The
.editorconfigclaim was wrong. The reference saiddotnet_diagnostic.DM0005.severity = nonehas no effect. It works. Verified threeways on SDK 10.0.302 against a real DM0019:
.editorconfigdotnet_diagnostic.DM0019.severity = none.editorconfigremoved againWhat
.editorconfiggenuinely cannot do is raise a severity — a generator'sdiagnostics arrive with theirs already fixed, so
dotnet_diagnostic.DM0018.severity = warningdoes nothing. Both halves are nowstated, and the
DM0018descriptor comment that told readers to promote it thatway is corrected. That comment was mine, from #40.
2.
DM0010/DM0011were described as never appearing indotnet buildat anyverbosity. They appear at
-v detailed.3.
DM0012described the opposite of what the generator emits. A conditionwith nothing to test cannot be false, so the guard is
if (true)and the serviceregisters unconditionally — the page said it never registers.
DM0017,DM0018andDM0019now have table rows and sections on the reference,including the
DM0018note that it cannot be promoted.Verification
dotnet build DependencyModules.sln -c Release— 0 warningsdotnet test DependencyModules.sln -c Release— 1,830 passed, 0 failedscripts/verify-packages.sh 1.1.0— all checks green fornet8.0andnet10.0,including packing, consuming from a real feed, and running the consumer app
vitepress build— clean, withignoreDeadLinks: falseAnd the strongest gate available: the four applications written against 1.0.0
during the evaluation — a CLI, a worker daemon, an Avalonia desktop app and a
Native AOT tool, 11 assemblies, 224 tests — were re-run against this build with a
locally packed feed. 218 pass unchanged. All six failures are the tests that were
deliberately pinning the defects this release fixes:
AttributeSpellingTests×3KnownDefect_AnInterceptorWrapperIsAppliedToEveryRegistrationOfTheInterfaceKnownDefect_AnOnlyRealmModuleStillAppliesTheOtherModulesInterceptorsComposingThroughTheAttributeSilentlyResetsNonNullableParametersZero genuine regressions, and neither new error diagnostic false-positived across
those 11 assemblies.
Publishing
Merging this does not publish. The release workflow triggers on a
v*tag, whichis the source of truth for the published version — so
git tag v1.1.0 && git push origin v1.1.0once this is onmain.🤖 Generated with Claude Code
https://claude.ai/code/session_01R9DWh8FWTib6hRYURbypWU