Binding Redicts are added only occasionally
See original GitHub issueDescription
Can’t figure out why Binding Redirects are being added by paket only on some packages when I have set redirects: on
or add --redirects
parameter for paket.
Repro steps
In this simple example repo I have the following paket.dependencies file (and xunit is added to project ConsoleApplication):
redirects: on
source https://nuget.org/api/v2
nuget xunit
Now if i run any of the following
paket install
paket install -f
paket install -f --redirects
paket install -f --redirects --createnewbindingfiles
Expected behavior
Binding Redirects are added to the existing App.config file. For the package itself and also for all the transitive dependencies.
Could be that I’ve misunderstood something here, but the documentation quite clearly states:
tells paket to create Assembly Binding Redirects for all referenced libraries
So I’d assume that all libraries that are added as reference in *.csproj, would get matching Binding Redirects added to App.config as well (direct and transitive).
Actual behavior
Binding Redirects are not added. Not for the given package nor for the transitive dependencies.
Remarks and additional info
No known workarounds. I tried to add the package with --redirects
flag, but this did not help. Also tried to set nuget xunit redirects: force
on paket.dependencies
, but no luck there either.
On the other hand in the following test paket seems to add Binding Redirect for FSharp.Core, but not for UnionArgParser: https://github.com/Gonnagle/paket-tests/releases/tag/binding-redirects-partially-working
Weirdly if I try to add FSharp.Core to the original test (next to xunit) the redirects fail to appear for this package also…
Issue Analytics
- State:
- Created 7 years ago
- Reactions:3
- Comments:9 (8 by maintainers)
Top GitHub Comments
@isaacabraham that behaviour is easy enough to document 😆
Just tested this with
5.100.2
and it seems that the solution wide option atpaket.dependencies
now works as expected. So changing it as follows:And running
paket install -f
now creates the binding redirects as expected.