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

Microsoft.NET.Sdk.IL change from PackageVersion => Version suffix broke WinForms usage #1338

Closed
dagood opened this issue Jan 6, 2020 · 11 comments
Labels
area-ILTools-coreclr untriaged New issue has not been triaged by the area owner

Comments

@dagood
Copy link
Member

dagood commented Jan 6, 2020

dotnet/winforms#2533 (comment)

@dagood the PR is still failing to build due to an unresolved dependency

##[error]src\Accessibility\src\Accessibility.ilproj(0,0): error NU1102: Unable to find package runtime.win-x64.microsoft.netcore.ilasm with version (>= 5.0.0)
  - Found 1178 version(s) in dotnet-core [ Nearest version: 5.0.0-alpha.1.20054.2 ]
  - Found 792 version(s) in dotnet-coreclr [ Nearest version: 5.0.0-alpha1.19564.1 ]
  - Found 9 version(s) in nuget.org [ Nearest version: 2.0.8 ]
  - Found 0 version(s) in arcade
  - Found 0 version(s) in dotnet-eng

This is because WinForms uses MicrosoftNETCoreILAsmPackageVersion, but dotnet/coreclr#27606 changed the IL SDK to use MicrosoftNETCoreILAsmVersion.

<MicrosoftNETCoreILAsmVersion Condition="'$(MicrosoftNETCoreILAsmVersion)' == ''">5.0.0</MicrosoftNETCoreILAsmVersion>

I think it would be reasonable to accept both forms in the IL SDK. However, if it's better to just close this as "won't fix" and have WinForms change the property name instead, I think it will be useful to have had this issue open to track this breaking change.

@Dotnet-GitSync-Bot Dotnet-GitSync-Bot added area-Infrastructure-installer untriaged New issue has not been triaged by the area owner labels Jan 6, 2020
@dagood dagood changed the title Post-consolidation Microsoft.NET.Sdk.IL breaks WinForms Microsoft.NET.Sdk.IL change from PackageVersion => Version suffix broke WinForms usage Jan 6, 2020
@safern
Copy link
Member

safern commented Jan 6, 2020

I think we should stick with the current property name as we've been transition Versions.props to not contain PackageVersion but Version as a suffix only. It is cleaner and easier to read, and also PackageVersion is redundant. The reason why PackageVersion was supported at the beginning was because DARC had a bug where it only matched the property if the suffix was PackageVersion instead of Version

@dagood
Copy link
Member Author

dagood commented Jan 6, 2020

we've been transition Versions.props to not contain PackageVersion but Version as a suffix only.

Are all downstream users of Microsoft.NET.Sdk.IL also making this change? Is it ok to force this, and not have a clear error message?

@safern
Copy link
Member

safern commented Jan 6, 2020

I don't know which are the users, but when we were still in corefx we made this change. This was done 2 months ago, so I would've expected other people to be broken by this already:

cdc3339

I think we can error out if PackageVersion is set and Version is not or at least emit a warning.

@dagood
Copy link
Member Author

dagood commented Jan 6, 2020

Oh huh. This breaking change was absorbed in the past by dotnet/winforms#2278, but the fix was reverted by dotnet/winforms#2497 to go down to a version before this change happened. /cc @RussKie

Anyway, taking the breaking change again passed winforms CI: dotnet/winforms#2647. Just waiting for a winforms reviewer.

Having a reasonable error message would have made this really easy to resolve and had WinForms deps flowing 9 days ago, FWIW. But now that it's over with, I don't know if it'll be hit again in the future.

@safern
Copy link
Member

safern commented Jan 7, 2020

I guess we can close then? Or are you planning on putting up a PR to error/warn?

@dagood
Copy link
Member Author

dagood commented Jan 7, 2020

It's up to whoever makes decisions about Microsoft.NET.Sdk.IL to decide if the package should have these warnings/errors or not, IMO. I don't know enough about how/where this package is used to know for sure.

@RussKie
Copy link
Member

RussKie commented Jan 7, 2020

It would good be make a note of this for the future - add better error messages for breaking changes.

@dagood fixed us now (thank you!), so no further actions are required from our side.

@safern
Copy link
Member

safern commented Jan 16, 2020

cc: @jkoritzinsky I don't know who is the owner for Microsoft.NET.Sdk.IL

@jkoritzinsky
Copy link
Member

I think @tannergooding is the owner for the SDK, but I'm not positive.

@tannergooding
Copy link
Member

I did the initial implementation work for Microsoft.NET.Sdk.IL but I'm not sure if I'm the "owner". Most of the changes since the initial work have been done by those working on infrastructure.

@ViktorHofer
Copy link
Member

ViktorHofer commented Mar 26, 2020

Just found this issue. That change was done by me when we consolidated the repositories. As I believed that dotnet/runtime is the only consumer of Microsoft.NET.Sdk.IL I didn't warn in beforehand or add a fallback mechanism... Sorry for that. To learn from this, next time I'll:

  1. Gather potential consumers by scanning GitHub and devdiv/dnceng.
  2. Open an issue to discuss the potential breaking change and loop in (ideally) all consumers.
  3. Warn in beforehand / add a fallback mechanism (in this case it would have been as simple as accepting both properties).

Again sorry for the disruption here. For dotnet/runtime we will use #33821 going forward, in addition to the other mentioned steps.

I think there's no further action necessary, hence closing.

@ghost ghost locked as resolved and limited conversation to collaborators Dec 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-ILTools-coreclr untriaged New issue has not been triaged by the area owner
Projects
None yet
Development

No branches or pull requests

7 participants