
So we have this recurring issue every time:
Version conflict detected for Microsoft.CodeAnalysis.CSharp.Workspaces. Install/reference Microsoft.CodeAnalysis.CSharp.Workspaces 4.8.0-3.final directly to project ProjectName to resolve this issue. ProjectName -> Microsoft.VisualStudio.Web.CodeGeneration.Design 8.0.0 -> Microsoft.VisualStudio.Web.CodeGenerators.Mvc 8.0.0 -> Microsoft.VisualStudio.Web.CodeGeneration 8.0.0 -> Microsoft.VisualStudio.Web.CodeGeneration.EntityFrameworkCore 8.0.0 -> Microsoft.VisualStudio.Web.CodeGeneration.Core 8.0.0 -> Microsoft.VisualStudio.Web.CodeGeneration.Templating 8.0.0 -> Microsoft.VisualStudio.Web.CodeGeneration.Utils 8.0.0 -> Microsoft.CodeAnalysis.CSharp.Workspaces (>= 4.8.0-3.final) ProjectName -> Telerik.UI.for.AspNet.Core 2023.3.1114 -> Microsoft.CodeAnalysis 4.4.0 -> Microsoft.CodeAnalysis.CSharp.Workspaces (= 4.4.0).
Now, Microsoft.CodeAnalysis and all DLLs are at v4.8. I have just installed Microsoft.CodeAnalysis v4.8 but I am getting the above error (it's not a warning, but an error). This has happened a few times before. I keep adding numerous DLLs until the error becomes a persistent warning. Is there a more professional solution to this?
2 Answers, 1 is accepted

Hello,
A similar subject has been discussed in the following forum thread that goes more into detail, accompanied by a standalone Telerik UI for ASP.NET Core sample with ".NET8" as a target framework and the "Microsoft.EntityFrameworkCore.Tools" dependency:
- .NET 8 Compatibility (Forum Thread) - Reply from "16 Nov 2023".
To be frank, we are currently in the process of considering whether we can proceed with an effort of bumping the "CodeAnalysis" dependency on our side. To give you more context we have stalled this process since the library currently supports prior .NET Core incarnations.
Clients or corporations that depend on prior .NET Core frameworks that are supported (for example 3.1), would inevitably have to migrate their dependencies which may prove intangible - given their infrastructure.
However, we are currently striving to follow Microsoft's strategy when it comes to the support of ''LTS", "STS" packages. I am personally taking on the responsibility of keeping this thread posted. In order for the community to be familiar when our migrational efforts are initiated.
To sum up, at this stage, the majority of the packages you have outlined are external and we depend indirectly on them. Hence, you should be able to update the respective versions as illustrated in the aforementioned forum thread.
I hope this helps.
Kind Regards,
Alexander
Progress Telerik
Has any progress been made on this? We are using the latest .NET and the latest ASP.NET Identity and it is causing an irreconcilable conflict. We have been waiting for a solution to this since November.
This has brought the admin portion of our project to a halt for months and is making us regret using Telerik.
I understand wanting legacy support but perhaps splitting the builds and creating a .NET 8 package is in order. I believe most of us are trying to stay on the latest .NET to avoid the costs of later migration.
I will open a ticket, although I don't know what can be done until Telerik decides to address this.
Hi Justin,
I'm happy to let you know that our developer subject matter experts have embarked on the task of omitting older .NET Core versions and dependencies as well.
As mentioned previously, the team has concluded that we should align with Microsoft’s recommended framework versions so that our products leverage the latest advancements in technology, security, and performance.
To be more specific, this change is scheduled for the next 2024 Q2 release and will support applications targeting .NET 6 and above, as mentioned in our latest release notes:
Hi Dan,
The Q2 release is scheduled to come to light around the middle of May. However, once I have further confirmation regarding the exact date, I will update this thread with more information. In order to keep you guys posted - should there be any alterations.
Hi Josh,
Our release is scheduled to come into light as of the 15th of May. However, if there seems to be a change, I will make sure the keep you up to date.
Tried the new 2024 Q2. Problem seems to still exist. Release note doesn't even seem to mention this issue.
Hi Prabhat,
Could you please verify whether you are utilizing the .NET8 as a target framework?
Hi Jeffrey,
Indeed, deleting the old versions of the Microsoft library should resolve the issue. Generally, we've had an internal effort in bumping the version of the "Microsoft.CodeAnalysis" dependency as a consequence of our latest release.
Here is how the aforementioned dependency is configured depending on the aforementioned versions, so that things are more transparent:
<ItemGroup Condition="'$(TargetFramework)' == 'net6.0'">
<FrameworkReference Include="Microsoft.AspNetCore.App" />
<PackageReference Include="Microsoft.CodeAnalysis" Version="4.4.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="6.0.*" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net7.0'">
<FrameworkReference Include="Microsoft.AspNetCore.App" />
<PackageReference Include="Microsoft.CodeAnalysis" Version="4.4.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="7.0.*" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net8.0'">
<FrameworkReference Include="Microsoft.AspNetCore.App" />
<PackageReference Include="Microsoft.CodeAnalysis" Version="4.8.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="8.0.*" />
</ItemGroup>
Since this is an indirect dependency, there should be no restrictions from altering the version depending on your target framework.
Thank you, Alexander. My comment was (mostly) directed toward the author of the previous response that indicated that the problem hadn't been fixed. ;)
Thank you and the Telerik team for addressing this issue and for you responsiveness to your customer requests!
Thank you for the clarification and your insights on what exactly has been rectified the issue.
I hope the community benefits from this discussion, so I wanted to spare some time and say thank you for being so proactive during the past couple of months. Your feedback was invaluable to the case, as it helped us move forward with the dependency migrational endeavor.
Thank you again and keep up the awesomeness!
Here is what it takes to get only warnings:
<ItemGroup> <PackageReference Include="Microsoft.CodeAnalysis" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.Common" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.Workspaces.Common" Version="4.8.0" /> </ItemGroup>
The error becomes 7 warnings:
Ultimately, thesèreferences solved the issue for me:
<ItemGroup> <PackageReference Include="Microsoft.CodeAnalysis" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.Common" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.CSharp.Features" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.Features" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.Scripting.Common" Version="4.8.0" /> <PackageReference Include="Microsoft.CodeAnalysis.Workspaces.Common" Version="4.8.0" /> </ItemGroup>
Adding references to the Microsoft.CodeAnalysis packages is a workaround.
There is a discrepancy in the dependencies of the Telerik UI toolset for .NET Core vs .NET 8 itself. The Telerik toolset requests for Version 4.4 ONLY of the several packages, whereas .NET 8 specifies Version 4.8.
If the package references are not included, the solution cannot compile. If they are include, then each project within the solution that references these packages gives a "version incompatible" warning (but compiles and runs).
In my view, if Telerik states that their toolset is compatible with .NET 8 (or .NET7 for that matter - I had the same issues before I updated to V8!), then they need to set up the dependencies to be consistent. The Nuget tools say that these packages should not be referenced directly by projects. But yet they have to be referenced directly because of this problem.
Hi Jeffrey,
I personally understand your point of view, as it indeed makes complete sense in terms of providing a suite of components that is in strong symbiosis with Microsoft's strategies.
Due to recent reports, I am happy to let you know that we are already working toward migrating the dependencies and hopefully, this will not be necessary for our upcoming version.
We apologize once again for the inconvenience. Your feedback is invaluable to us and I assure you, it is not taken for granted.