I have now exactly the same proplem. I recently updated the VS...
edit and continue: Error BC36970 Changing the version of an assembly reference is not allowed during debugging
Hi,
I've a VS2022 solution with several project. Basically it's a .NET 6.0 SPA app with WebAPI.
Every time I try to perform an edit and continue in my C# code, VS fails with this kind of error:
Error BC36970 Failed to emit module XXXX Changing the version of an assembly reference is not allowed during debugging: XXXX changed version to "1.0.0.0"
I cannot find a way to fix it, and so I'm not able to use edit and continue. Any idea?
thanks
Developer technologies | Visual Studio | Debugging
Developer technologies | C#
4 answers
Sort by: Most helpful
-
-
Anna Xiu-MSFT 31,056 Reputation points Microsoft External Staff
2022-01-17T07:43:50.343+00:00 Hi @Topogigio ,
Welcome to Microsoft Q&A!
Please update your Visual Studio 2022 to the latest version and create a new project to verify if the issue persists or not.
Meanwhile, please try to delete the .vs folder in your project folder and rebuild your project.
By the way, you can refer to the similar issue and check if you have the same behavior or not:
https://github.com/dotnet/roslyn/issues/28224#issuecomment-447017910Sincerely,
Anna
*
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. -
Topogigio 16 Reputation points
2022-01-20T15:45:22.767+00:00 Hi, VS is updated of course.
The problem sometimes goes away for a while, then it returns after a few days.
deleting .vs folder does not fix nothing
-
Mojix 0 Reputation points
2023-07-30T18:24:22.4333333+00:00 Hi, I have also faced this problem recently and could not find the problem