dotnet / dotnet/msbuild

2nd Level Dependency With Mismatched Version Missing

Open
#2,635 2 comments 0 reactions 0 assignees View on GitHub
triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 8h
Merged PRs (30d)
141

Description

## Setup

ProjectA (Class Library) - Direct Nuget dependency on Lib1 which has indirect nuget dependency on Lib2
ProjectB (Console Application) - Project reference to ProjectA

Lib1 nuget states version >= 1.0.0
Lib2 is version 1.1.0

## The Observed Result

ProjectA compiles fine & has both Lib1 and Lib2 in the bin.
ProjectB compiles fine, has ProjectA.dll and Lib1 in the bin.
ProjectB is missing Lib2.
ProjectB (Console Application) has a runtime error since Lib2 is not present

## Initial Findings

MSBuild output states that it will not take Lib2 (when compiling ProjectB) as there is a mismatch in the "FusionName" which appears to be the assembly plus the version and key.

## Looking at MSBuild Code

This may be (i'm tried debugging, but its tough) related to assembly unification.
For some reason ProjectB requires a specific version whereas ProjectA does not.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.