-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Ensure DiagnosticSource has correct package ID #52472
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
Conversation
The `AvoidRestoreCycleOnSelfReference` workaround was causing DiagnosticSource to get the wrong PackageID in the assets file when referenced by other projects. This wasn't a problem when using pkgproj since we'd calculate dependencies from assembly references, ignoring the assets file. This is a problem now that we're using csproj pack, since that gets dependencies from the assets file.
|
Tagging subscribers to this area: @Anipik, @safern, @ViktorHofer Issue DetailsThe Fixes #52459
|
| <Nullable>enable</Nullable> | ||
| <TargetFrameworks>$(NetCoreAppCurrent);net5.0;netstandard1.1;netstandard1.3;net45;net46;netstandard2.0</TargetFrameworks> | ||
| <ExcludeCurrentNetCoreAppFromPackage>true</ExcludeCurrentNetCoreAppFromPackage> | ||
| <AvoidRestoreCycleOnSelfReference>true</AvoidRestoreCycleOnSelfReference> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to remove this hack anyhow for when we eventually convert this project to CSProj packing.
I looked into completely removing https://github.com/dotnet/runtime/blob/main/eng/AvoidRestoreCycleOnSelfReference.targets but it's still used here:
runtime/src/libraries/Microsoft.NETCore.Platforms/src/Microsoft.NETCore.Platforms.csproj
Line 6 in 28b9c72
| <AvoidRestoreCycleOnSelfReference>true</AvoidRestoreCycleOnSelfReference> |
And that can't be removed in the same way (we could refactor the project into a separate task project to fix it). I'm not doing that now since the current issue is blocking consumption of dotnet/runtime.
|
Two test failures are #52464, one was a pass but an issue with helix reporting results https://github.com/dotnet/core-eng/issues/13026 |
ViktorHofer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks for the quick fix.
safern
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
The
AvoidRestoreCycleOnSelfReferenceworkaround was causingDiagnosticSource to get the wrong PackageID in the assets file when
referenced by other projects. This wasn't a problem when using pkgproj
since we'd calculate dependencies from assembly references, ignoring
the assets file. This is a problem now that we're using csproj pack,
since that gets dependencies from the assets file.
Fixes #52459