-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Visual Studio 2022 crashes for certain solution after setting net6.0 instead of net5.0 #59190
Labels
Comments
This issue was moved from https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1454807. The attached solution crashes VS when opened. Debugging shows it's a stack overflow:
|
Somewhat similar stack overflow can be reproduced with the following unit-test:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
This issue has been moved from a ticket on Developer Community.
[severity:I'm unable to use this version]
I have existing solution for .NET 5 (ASP.NET Core), I worked with it in VS 2019, all works good.
Now I want upgrade all projects from this solution to .NET 6 and work in VS 2022.
I replaced net5.0 to net6.0 in all .csproj files in this solution.
And after that VS 2022 crashed.
If I launch VS 2022 again and open this solution then VS 2022 hangs and then crashes.
Problem is only for this solution.
For other similar solutions all works good - I replaced net5.0 to net6.0 and VS didn't crash.
Original Comments
Feedback Bot on 12/26/2021, 05:17 PM:
We have directed your feedback to the appropriate engineering team for further evaluation. The team will review the feedback and notify you about the next steps.
Peng Ge [MSFT] on 12/27/2021, 00:16 AM:
Dear customer, thank you for your feedback and I am sorry to hear that you are running into this issue.
You can try to repair Visual Studio, disable third-party extensions, delete the .vs and bin folders of the project and reload the project.
Pavel Mokshin on 12/27/2021, 09:22 AM:
Hi. I tried all these ways, they didn’t help.
Peng Ge [MSFT] on 12/29/2021, 00:18 AM:
Open the project in Visual Studio 2022, then modify the target framework in the project properties->application->General, will you encounter this issue?
Pavel on 12/29/2021, 00:37 PM:
Yes.
I did it now for all projects in solution.
Problem is only for one project - when I switch it to .NET 6 then Visual Studio 2022 hangs and crashes.
Don’t know is it important or not but in this project I use Roslyn SDK.
I attached this proj file which I use in .NET 5.
If change net5.0 to net6.0 in it then I encounter this issue.
At moment of switch I have old versions of Nuget packages which I used in .NET 5.
I also tried manually change versions of Nuget packages to latest (4.0.1 for Roslyn and 6.0.1 for .NET) but it didn’t help.
Also attached screenshot with some error messages from VS.
But I couldn’t click “Show stack trace” because VS hangs.
Pavel on 12/29/2021, 04:05 PM:
Created and attached small solution with one project, it has this problem too - VS 2022 hangs and crashes.
Here is used Antlr4.
Some files with code are very big.
Maybe this is the reason of problem.
Feedback Bot on 12/30/2021, 01:06 AM:
Thank you for sharing your feedback! Our teams prioritize action on product issues with broad customer impact. See details at: https://docs.microsoft.com/en-us/visualstudio/ide/report-a-problem?view=vs-2019#faq. In case you need answers to common questions or need assisted support, be sure to use https://visualstudio.microsoft.com/vs/support/. We’ll keep you posted on any updates to this feedback.
Pavel on 12/30/2021, 04:33 AM:
Also found similar ticket: https://developercommunity.visualstudio.com/t/visual-studio-2022-preview-crashes-opening-solutio/1519923
Here user (randyL2004) found workaround but it doesn’t work for me.
In this ticket MS Team said that it’s bug of Antlr and suggested write to them.
User created issue on Antlr github: antlr/antlr4#3274
Please look this discussion, maybe it will help.
Peng Ge [MSFT] on 1/18/2022, 01:53 AM:
Thank you for your feedback.
Will you encounter this issue without using Antlr?
We look forward to hearing from you!
Pavel Mokshin on 1/20/2022, 00:37 AM:
No, it’s only with Antlr. But Antlr is required for this project.
For now I’m forced to use Rider IDE from Jetbrains, it works good for this project.
Drew Noakes [MSFT] on 1/22/2022, 02:42 AM:
Hi @Pavel Mokshin, thanks very much for the bug report, especially for the attached project. I can reproduce the problem and have assigned this ticket to the relevant team, who will look into it for you.
Feedback Bot on 1/23/2022, 08:57 PM:
This issue is currently being investigated. Our team will get back to you if either more information is needed, a workaround is available, or the issue is resolved.
Original Solutions
(no solutions)
The text was updated successfully, but these errors were encountered: