Skip to content

slight issues with assembly-redirect-generation and VS2017.3 #2740

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

Closed
0x53A opened this issue Sep 7, 2017 · 4 comments
Closed

slight issues with assembly-redirect-generation and VS2017.3 #2740

0x53A opened this issue Sep 7, 2017 · 4 comments

Comments

@0x53A
Copy link
Contributor

0x53A commented Sep 7, 2017

Note: I have removed AutoGenerateBindingRedirects from my project file on purpose.

  1. Install VS2017.3 and/or the standalone msi
  2. build my repro: https://github.com/0x53A/net-quote-standard-paket-redirects
  3. check the app.config:
  <dependentAssembly>
    <Paket>True</Paket>
    <assemblyIdentity name="System.Threading.Thread" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-65535.65535.65535.65535" newVersion="4.0.1.0" />
  </dependentAssembly>
  1. check the actual file in the build output:
    image

  2. 4.0.1.0 != 4.0.2.0
    image

  3. check all files in the packages directory:
    image
    image

where does 4.0.2.0 come from?

image

  1. check the build log

image

This means it is no longer possible to deduce what version will land in the build output by analyzing just target-framework + set of packages.

@matthid
Copy link
Member

matthid commented Sep 7, 2017

so it should be removed for new sdk?

@0x53A
Copy link
Contributor Author

0x53A commented Sep 7, 2017

this is an old-sdk project

@0x53A 0x53A changed the title paket app.config assembly-redirect creation is broken and should be removed slight issues with assembly-redirect-generation and VS2017.3 Sep 7, 2017
@0x53A
Copy link
Contributor Author

0x53A commented Sep 8, 2017

Note: the new magic resolutions can be disabled by

    <PropertyGroup>
        <ImplicitlyExpandNETStandardFacades>false</ImplicitlyExpandNETStandardFacades>
        <DisableHandlePackageFileConflicts>true</DisableHandlePackageFileConflicts>
    </PropertyGroup>

@0x53A
Copy link
Contributor Author

0x53A commented Sep 14, 2017

Second note: if AutoGenerateBindingRedirects doesn't work, try

<PropertyGroup>
  <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
  <GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
</PropertyGroup>

(from dotnet/msbuild#1310)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants