Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[repo] Bump Microsoft.Extensions.Logging.Configuration and clean up net462 targets #5020

Merged

Conversation

CodeBlanch
Copy link
Member

@CodeBlanch CodeBlanch commented Nov 2, 2023

Relates to #5015

Changes

  • Updates Microsoft.Extensions.Logging.Configuration to .NET 8 RC2.
  • Cleans up "net462" being sprinkled around all over the repo.
  • Uses '$(TargetFrameworkIdentifier)' == '.NETCoreApp' style in more places.

Merge requirement checklist

  • CONTRIBUTING guidelines followed (nullable enabled, static analysis, etc.)
  • Appropriate CHANGELOG.md files updated for non-trivial changes

@CodeBlanch CodeBlanch requested a review from a team as a code owner November 2, 2023 22:03
Copy link

codecov bot commented Nov 2, 2023

Codecov Report

Merging #5020 (9e5c05c) into main (d91be77) will increase coverage by 0.01%.
Report is 2 commits behind head on main.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #5020      +/-   ##
==========================================
+ Coverage   83.39%   83.41%   +0.01%     
==========================================
  Files         296      296              
  Lines       12403    12403              
==========================================
+ Hits        10344    10346       +2     
+ Misses       2059     2057       -2     
Flag Coverage Δ
unittests 83.41% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
src/OpenTelemetry/Metrics/Metric.cs 96.46% <100.00%> (ø)
src/Shared/HttpSemanticConventionHelper.cs 82.35% <100.00%> (ø)

... and 7 files with indirect coverage changes

Comment on lines +31 to +33
<ItemGroup>
<Reference Include="System.Net.Http" Condition="'$(TargetFramework)' == '$(NetFrameworkMinimumSupportedVersion)'" />
</ItemGroup>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good eye there @TimothyMothra! Not totally sure. This baffled me and @utpilla a bit. We used to reference the 3.1 versions of these packages. Interestingly they have a netstandard2.0 target but NOT a net462 target. We are jumping to the .NET 8 RC versions which do have a net462 target. For some reason, using that new dedicated net462 target a bunch of these projects started complaining about missing System.Net.Http! My theory is that HttpClient is part of netstandard2.0 but NOT net462. It seems like when the netstandard2.0 bits were used the whole .NET Standard 2.0 API layer came with it including HttpClient. Best guess 😆 If you want to spend some time on it and try to figure it out I am very curious to know exactly what is going on but I decided not enough so to keep spending time on it.

Copy link
Contributor

@utpilla utpilla Nov 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems like when the netstandard2.0 bits were used the whole .NET Standard 2.0 API layer came with it including HttpClient.

Yes, that's indeed the case here. This screenshot is from dotPeek, which shows that the netstandard2.0 bits for this package bring in netstandard2.0 APIs:

image

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.

None yet

3 participants