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

CopyCoverletDataCollectorFiles overwrites newer version of NewtonSoft.Json.dll #1226

Closed
sturnberg opened this issue Sep 20, 2021 · 7 comments · Fixed by #1243
Closed

CopyCoverletDataCollectorFiles overwrites newer version of NewtonSoft.Json.dll #1226

sturnberg opened this issue Sep 20, 2021 · 7 comments · Fixed by #1243
Labels
bug Something isn't working driver-collectors Issue related to collectors driver duplicate This issue or pull request already exists

Comments

@sturnberg
Copy link

sturnberg commented Sep 20, 2021

I recently upgraded my project to .NET 5. When I publish the project I find that the latest version of NewtonSoft.Json.dll 13.0.1 is being overwritten by the version used by coverlet, 9.0.1. The version of Coverlet I'm using is 3.1.0.

If I publish with increased verbosity I can see exactly where the dll is being copied over.
10:6>CopyCoverletDataCollectorFiles:
Copying file from "C:\st.nuget\packages\coverlet.collector\3.1.0\build\netstandard1.0\Newtonsoft.Json.dll" to "C:\src\myProject\Source\Tests\Unit\MyProject.Tests.Unit\bin\Release\net5.0\publish\Newtonsoft.Json.dll".

@petli
Copy link
Collaborator

petli commented Sep 20, 2021

Could this be the same issue as discussed in #1045?

@sturnberg sturnberg changed the title CopyCoverletDataCollectorFiles overwrites newer version of NewtonSoft.Json.dll 1 CopyCoverletDataCollectorFiles overwrites newer version of NewtonSoft.Json.dll Sep 20, 2021
@daveMueller
Copy link
Collaborator

Yes I think it is the same and there are also workarounds. Maybe you can try one of the workarounds there until someone has time to analyze and fix this.

@sturnberg
Copy link
Author

The issues are the same but the workaround does not work for me. If I don't publish the tests I get the error "Could not find data collector 'XPlat Code Coverage" as explained in this issue #521.

@MarcoRossignoli
Copy link
Collaborator

Hi all!

Can someone dogfood this preview version with the fix attempt and tell me if it works?
https://f.feedz.io/marcorossignoli/coverletunofficial/nuget/index.json version 3.1.1-preview.10

@scnanney
Copy link

scnanney commented Jan 4, 2022

When is a new version containing this fix going to be released to Nuget?

@MarcoRossignoli
Copy link
Collaborator

@scnanney can you try the nightly build to confirm that is properly fixed?

https://f.feedz.io/marcorossignoli/coverletunofficial/nuget/index.json version 3.1.1-preview.10

@willemk
Copy link

willemk commented Jan 17, 2022

@MarcoRossignoli I just tried the 3.1.1 preview on our code, and I can confirm that it's now working as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working driver-collectors Issue related to collectors driver duplicate This issue or pull request already exists
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants