runtime: System.IO.Compression.ZipFile missing classes for net46
Hi there!
Trying to use System.IO.Compression.ZipFile with net46 platform from nuget version 4.0.1-rc3-24013-00 (from myget/dotnet-core feed), and it seems that ZipFile is missing from the assembly for this TFM.
Note that the only valid assembly that contains the class is for dotnet5.4 TFM
Is this a known issue?
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 1
- Comments: 20 (17 by maintainers)
This actually looks like a side-effect of shipping a new version of System.IO.Compression out of band. ResolveAssemblyReferences is not seeing the assembly conflict between the inbox version and the OOB version. As a result you don’t have a binding redirect in the built app.config.
If you add the following, it should fix the issue:
/cc @weshaggard @ianhays
I apologize @xavierpena, I misunderstood the effect that removing the OOB package would have on your scenario. I expected that removing the build would cause our packaging to make the net46/net463 binary for any future Compression packages be a pure type-forward to desktop. After talking with @ericstj more in detail, I found that to be incorrect. What actually will happen is that the new packages will just bundle-in the last stable version of the OOB package which was 4.3.0 (the one that is causing you issues).
FWIW, this issue is a part of a class of issues (e.g. https://github.com/dotnet/corefx/issues/9846, https://github.com/dotnet/corefx/issues/17014) that are causing us headaches elsewhere due to requiring manual redirects. I’m re-opening this.
cc: @karelz, @ericstj, @weshaggard
I have a commit which fixes this by adding my force-conflict assembly to our netfx support package: https://github.com/ericstj/corefx/commit/4e42db47fb4998f677347596bf975ac83922fdce
This is waiting for https://github.com/dotnet/corefx/pull/18246 to merge then I’ll make it a separate PR.
I plan to address the primary cause of this issue in the desktop support package that we create for NETStandard2 : https://github.com/dotnet/standard/issues/274. In that package I’ll include a shim that will force RAR to see conflicts between the inbox assemblies and the OOB ones. That package will also effectively eliminate all runtime-only conflicts that were being missed, since it will bring in all the facades to support NS2.0, which will be closure complete for all the implementation assemblies.
Closing this as it has been resolved in CoreFX. Just waiting on that new package to be uploaded…
4.3.0 is the latest stable, yeah. That version references a System.IO.Compression that contains the OOB package for desktop (4.3.0).
I was referring to the latest prerelease package on dotnet.myget.org published after the merging of https://github.com/dotnet/corefx/pull/16045. However, I apologize; I spoke too soon and there hasn’t been a package push since that change, so there isn’t a new (fixed) package available yet. So that’s not very helpful for you at the moment, but it will be when it gets pushed.