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

All FSharp.Core redirects removed after updating to FSharp.Core 5.0.0 #3961

Open
vasily-kirichenko opened this issue Dec 1, 2020 · 8 comments

Comments

@vasily-kirichenko
Copy link
Contributor

paket update FSharp.Core

The expected change in paket.lock:

image

But all the redirects (in ~150 projects) are gone:

image

which results with runtime errors, like this:

System.TypeInitializationException : The type initializer for 'xxx' threw an exception.
  ----> System.TypeInitializationException : The type initializer for '<StartupCode$xxx>.$Settings' threw an exception.
  ----> System.IO.FileLoadException : Could not load file or assembly 'FSharp.Core, Version=4.4.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

The header of paket.dependencies is:

redirects: on
framework: net462
source ./nuget
source https://api.nuget.org/v3/index.json
@forki
Copy link
Member

forki commented Dec 1, 2020 via email

@vasily-kirichenko
Copy link
Contributor Author

@forki Yes, I've tried redirects: force, no effect.

What I need is just to add the redirection for FSharp.Core to version 5.0.0 to all app.configs. Is it possible?

I cannot see how the structure of the package's /libs or the target framework could break it :(

@forki
Copy link
Member

forki commented Dec 1, 2020

do you have a simple repro with just one project as a zip? I would look at it asap

@vasily-kirichenko
Copy link
Contributor Author

@forki
Copy link
Member

forki commented Dec 1, 2020

Ok I looked at it. As I expected it's the change in /lib folder. The new FSharp.Core 5.0 only comes with netstandard2.0 support.

And netstandard2.0 and net462 don't really fit together.
Short story: If we activate the compatibilty in Paket then stuff breaks. If we don't then scenarios like this one here doesn't work.

There is a PR by @0x53A which tries to mitigate this. see #3447 - it also gives a lot more details on the history. Funnily one of those mentioned issues is by you. So you already run into this before.

@0x53A any ideas why we dropped the ball here?

@vasily-kirichenko
Copy link
Contributor Author

@forki I've created net462 dir, copied netstandard2.0 dir's content into it, zip all this into 5.0.1 package and use it locally. Problem solved, Microsoft, thank you, as always! :)

@forki
Copy link
Member

forki commented Dec 1, 2020 via email

@0x53A
Copy link
Contributor

0x53A commented Dec 1, 2020

@forki I didn't have the time and motivation to finish it, and by now I've migrated to .net 5 ¯\_(ツ)_/¯

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

No branches or pull requests

3 participants