Skip to content

Don't explicitly import Arcade SDK in AfterSigning.targets #22429

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

Merged
merged 4 commits into from
Jun 3, 2020

Conversation

wtgodbe
Copy link
Member

@wtgodbe wtgodbe commented Jun 1, 2020

@ghost ghost added the area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework label Jun 1, 2020
@wtgodbe
Copy link
Member Author

wtgodbe commented Jun 1, 2020

@wtgodbe wtgodbe marked this pull request as ready for review June 2, 2020 19:41
@wtgodbe
Copy link
Member Author

wtgodbe commented Jun 2, 2020

The internal build produced the checksum files without the warnings.

The issue was that sdk.props and AfterSigning.proj (both in Arcade) import some of the same files

@wtgodbe wtgodbe requested a review from a team June 2, 2020 19:41
Copy link
Contributor

@dougbu dougbu left a comment

Choose a reason for hiding this comment

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

Might work but it's not clear why AfterSigning.targets uses the Arcade SDK at all. Isn't it imported from an Arcade SDK project. We don't do anything similar in Publishing.props or Signing.props for example.

@@ -29,5 +27,5 @@
</Target>

<Import Project="Sdk.targets" Sdk="Microsoft.DotNet.Arcade.Sdk" Condition="'$(GenerateChecksums)' == 'true'" />
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is this <Import/> both still needed and 🆗❔

Copy link
Member Author

Choose a reason for hiding this comment

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

The checksums weren't produced without it, because SDK.targets imports https://github.com/dotnet/arcade/blob/master/src/Microsoft.DotNet.Arcade.Sdk/tools/Imports.targets, which imports GenerateChecksums.targets. AfterSigning.targets doesn't import that. Presumably publishing/signing.props don't need to import anything because they don't use custom tasks like GenerateChecksums

Copy link
Member Author

Choose a reason for hiding this comment

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

Is there a way to directly import a specific .targets file from the Arcade SDK (@riarenas @JohnTortugo @chcosta)? If so that'd probably be best

Copy link
Member Author

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.

Also @jcagme

Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure if there's a way to import a specific targets file from an msbuild sdk

@wtgodbe
Copy link
Member Author

wtgodbe commented Jun 3, 2020

@rainersigwald confirmed we can't import a specific .targets file without calculating the path to the file on-disk, so I'll just merge this as-is

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework
Projects
None yet
3 participants