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

Adding the reference to a project assembly two times in csproj file crashes docfx #1414

Closed
xenux opened this issue Mar 13, 2017 · 4 comments
Closed
Assignees
Labels
bug

Comments

@xenux
Copy link

@xenux xenux commented Mar 13, 2017

Title

Adding the reference to a project assembly two times in csproj file crashes docfx during metadata extraction.

Functional impact

when editing csproj by hand (or with git automatic merge from two branches) it happens that the reference to the same assembly is added two times. when it happens docfx crash during metadata extraction.

Minimal repro steps

  • Create project A.
  • Create project B.
  • Add reference to project A from project B.
  • Save.
  • Open B.csproj
  • Duplicate following lines:
<ItemGroup>
   <ProjectReference Include="..\A\A.csproj">
     <Project>{046f7d79-105a-4cb1-aa39-5545f82b4b1a}</Project>
     <Name>A</Name>
   </ProjectReference>
 </ItemGroup>
  • Use one class of A inside B to be sure nothing is optimized out.
  • Build metadata on B.
    -> crash
    stacktrace.txt

Expected result

Second reference should be ignored

Actual result

Argument Exception the same assembly is added two times in a dictionary collection crashing the build
A task was

@vicancy vicancy added the bug label Mar 15, 2017
@vicancy
Copy link
Contributor

@vicancy vicancy commented Mar 15, 2017

Thanks for reporting the issue. We will take a look.

@superyyrrzz
Copy link
Contributor

@superyyrrzz superyyrrzz commented Mar 22, 2017

It's fixed since v2.14

@ElanHasson
Copy link

@ElanHasson ElanHasson commented Apr 9, 2019

@superyyrrzz this is still an issue, I encountered it with latest version,

@superyyrrzz
Copy link
Contributor

@superyyrrzz superyyrrzz commented Apr 11, 2019

@ElanHasson Could you please open an issue with detailed steps to help us reproduce?

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

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.