Fix #3501: pin Microsoft.Extensions.Logging to the v8 floor#3502
Merged
Conversation
The library referenced Microsoft.Extensions.Logging v10 for every target, including net8.0 and netstandard2.0. On .NET 8 projects that align with the v8 extensions stack, NuGet flagged a "Detected package downgrade" restore error because they reference v8 directly while we pulled in v10 transitively. Drop the floor to 8.0.0. Consumers on the v8 stack no longer downgrade, and consumers on v10 still get v10 through a normal transitive upgrade. Keeping the full Microsoft.Extensions.Logging package (rather than swapping to Abstractions) avoids removing a public assembly from the dependency graph, which would have been source-breaking for the documented LoggerFactory setup. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
Fixes #3501.
We were pulling in
Microsoft.Extensions.Loggingv10 on every target, including net8.0 and netstandard2.0. On .NET 8 apps that sit on the v8 extensions stack, that v10 transitive reference tripped NuGet's "Detected package downgrade" error and broke restore.Dropping the floor to 8.0.0 fixes it: v8 consumers restore cleanly, and v10 consumers still resolve to v10 through a normal transitive upgrade.
I kept the full
Microsoft.Extensions.Loggingpackage on purpose. Switching toMicrosoft.Extensions.Logging.Abstractionswould have shaved the graph, but it also dropsMicrosoft.Extensions.Logging.dllfrom the published dependencies — which would break the documentednew LoggerFactory()/LoggerFactory.Create(...)setup inLogCDPCommunication.mdfor anyone relying on the transitive reference. Not worth a breaking change in a fix release.Verification
.nupkg: all three dependency groups now referenceMicrosoft.Extensions.Logging8.0.0.LauncherTests(Chrome/CDP): 56 passed, 0 failed.🤖 Generated with Claude Code