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.
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
Stop harvesting old frameworks in some libraries #51689
Stop harvesting old frameworks in some libraries #51689
Changes from 2 commits
5e5872f
95b63aa
f460a19
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
Can you elaborate? What was going wrong here?
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.
These were the errors that I wasn't sure how to deal with them:
I made sure that the generated nupkg has the expected state, that's why I disabled the support check.
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.
This is because S.R.C is marked as inbox in the package index. The inbox validation doesn't understand that you can decide to not represent an assembly that's inbox (here it would just get a placeholder).
I think you can make this go away by adding
<InboxOnTargetFramework Include="portable-net45+win8" />
It looks like that Harvesting was only harvesting the placeholder files.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.
I can't get this working. After adding the InboxOnTargetFramework items for both portables and win8, I now get the following errors:
If there isn't an easy solution to it I'd be fine to keep the support check for this package disabled.
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.
I see, because those are OOB frameworks, so the package has to provide an asset. One solution would be to remove the inbox entries from the index just for this package. That would avoid the original issue you mentioned.
runtime/src/libraries/pkg/baseline/packageIndex.json
Lines 4908 to 4913 in 1cc11b1
Remove the
portable
entries andwin8
(effectively "lying" about what's in those targeting packs). Alternatively you could plumb a suppression that told validation to not check for support for some frameworks (take the existing hook you added and consider using it in more places) and consume that near here: https://github.com/dotnet/arcade/blob/e7ede87875f41a9b3df898ae08da5ebc96e24f56/src/Microsoft.DotNet.Build.Tasks.Packaging/src/ValidatePackage.cs#L585There 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.
Thanks a lot for the suggestion Eric. I decided to trim the packageIndex graph as I wouldn't want to spend much on a solution for obsolete frameworks. Either the deprecation of the packageIndex or the removal of old netstandard1.x assets will happen at some point which will hopefully make the consideration of these old framework unnecessary.