It does not add a binding redirects even though it's needed

Open
#2,351 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
fsharp

Research direction

Reproduce the failure with paket install --redirects and the shown F#/.NET configuration, then inspect how Paket generates binding redirects. Compare the generated XML with the missing FSharp.Core redirect and verify that the affected test or sample can load the resolved assembly without the FileLoadException.

Written by the indexing model from the issue text.

Description

binding redirect bug needs-repro sdk: verbose sdk

paket install --redirects

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <runtime>
    <gcServer enabled="true" />
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="Shouldly" publicKeyToken="6042cbcb05cbc941" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-999.999.999.999" newVersion="2.5.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <Paket>True</Paket>
        <assemblyIdentity name="FSharp.Core" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6" />
  </startup>
</configuration>
Unhandled Exception: System.IO.FileLoadException: Could not load file or assembly 'FSharp.Core, Version=4.3.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)
   at Expecto.Tests.ExpectoConfigModule.fillFromArgs(ExpectoConfig baseConfig, String[] args)
   at Expecto.Tests.runTestsWithArgs(ExpectoConfig config, String[] args, Test tests)
   at Program.main(String[] args) in ...\Program.fs:line 6
Dominant language
F#
Stars
2.1k
Forks
528
Avg merge
1d 12m
Merged PRs (30d)
54

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from fsprojects/Paket

All issues in fsprojects/Paket

Similar issues

More Build System issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.