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

Visual Studio 2019 and ability to build/debug a project that will target .NET 6 REL #5567

Closed
bairog opened this issue Nov 11, 2020 · 39 comments

Comments

@bairog
Copy link

bairog commented Nov 11, 2020

UPDATE
For today latest Visual Studio 2019 (16.11.x) doesn't officially support .NET 6 development. Possible workround is described here.
As .NET 5.0 reaches EOL in 05.2022 and .NET Core 3.1 - in 12.2022 (.Net Core Lifecycle) so Visual Studio 2019 will be unable to target .NET in a supported manner. But Visual Studio 2019 16.11 itself is supported untill 2029 (VS 2019 Product Lifecycle).

I've created Developer Community feature demand asking to make .NET 6 LTS development available in Visual Studio 2019.

ORIGINAL POST
Is it planned to support Windows 7 SP1 and Debian 9 by .NET 6 LTS (and MAUI)?
According to .NET Core Supported OS Lifecycle Policy block Exceptions to the supported platform policy:

One example is Windows 7 SP1. Windows 7 SP1 is out of support, but enterprise customers can buy Extended Security Updates, and many do. Given the widespread use of Windows 7 in the .NET ecosystem we chose to include Windows 7 SP1 (with Extended Security Updates installed) as a supported platform for .NET 5.0.

According to Lifecycle FAQ - Extended Security Updates block ESU Availability and End Dates:

Windows 7 Extended Security Updates 2022: January 12, 2022 - January 10, 2023

Debian 9 EOL is June 30, 2022.

So are you planning to support both operating systems by .NET 6 LTS (and MAUI)?

Thank you.

P. S. Are you planning to support .NET 6 LTS (and MAUI) development with Visual Studio 2019? Or it will be an upcoming Visual Studio 2021-only feature? Or maybe you don't have plans to release a new Visual Studio version in 2021?

@bairog
Copy link
Author

bairog commented Feb 15, 2021

@davidortinau You've asked about user experience and MAUI expectations The New .NET Multi-platform App UI article. I've wrote you an email almost a week ago - still no reponse. Any uptades on this?

@bairog
Copy link
Author

bairog commented Feb 18, 2021

@richlander According to latest announcement and this NET 6.0 supports Windows 7 SP1 (Extended Security Updates EOL – January 10, 2023) but drops supporting Debian 9 (EOL is June 30, 2022) if compared to .NET 5. What is the reason for this decision?
And I still have no answer about OS support plans for MAUI for more than 3 month.
Even @davidortinau ignores my emails and this github topic..

@mairaw
Copy link
Contributor

mairaw commented Feb 18, 2021

Adding @leecow to see if he can comment on support plans as well

@leecow
Copy link
Member

leecow commented Feb 18, 2021

With respect to the Debian 9 decision, our general process is to exclude support for an OS version when that version will go EOL early in the new .NET version lifecycle. I haven't had any discussions with @davidortinau about MAUI OS support plans and expectations yet so can't offer anything on that topic.

@davidortinau
Copy link
Contributor

.NET MAUI will support what WinUI 3 offers for Windows. https://microsoft.github.io/microsoft-ui-xaml/about.html#controls

Additional platform and version information is available here https://github.com/dotnet/maui#xamarinforms-vs-net-maui

Linux support will not be part of the .NET 6 release for .NET MAUI. It is under consideration for a future release, so please connect with me so we can better understand your needs for .NET MAUI and Linux. david.ortinau@microsoft.com or join one of the several discussions at https://github.com/dotnet/maui/discussions/

@mairaw
Copy link
Contributor

mairaw commented Feb 19, 2021

Closing the issue since I believe all questions were answered. Please let us know otherwise @bairog.

@mairaw mairaw closed this as completed Feb 19, 2021
@bairog
Copy link
Author

bairog commented Feb 19, 2021

@mairaw my questions about Visual Studio IDE are still unanswered..

.NET MAUI will support what WinUI 3 offers for Windows. https://microsoft.github.io/microsoft-ui-xaml/about.html#controls

No support for Windows 7 SP1 with ESU - sad to hear, Uno project still supporting it..

Linux support will not be part of the .NET 6 release for .NET MAUI. It is under consideration for a future release

You are talking about plans for .NET 7, right?
Is it planned that .NET 7 development will be supported by Visual Studio 2019?
What are MS plans for Visual Studio 2021/2022/etc.?

@bairog
Copy link
Author

bairog commented Feb 19, 2021

With respect to the Debian 9 decision, our general process is to exclude support for an OS version when that version will go EOL early in the new .NET version lifecycle.

Debian 9 goes EOL (June 30, 2022) 7 month after .NET 6 planned release (November 2021). It is considered as "will go EOL early".
Windows 7 SP1 with ESU goes EOL (January 10, 2023) 14 month after .NET 6 planned release and is still supported. So it is considered as "will NOT go EOL so early".
Am I understanded correctly that Windows 7 SP1 with ESU will be very unlikely supported by .NET 7 (planned at November 2022)?
Or maybe MS already have plans for .NET 7 OS support?

@mairaw mairaw reopened this Feb 19, 2021
@bairog
Copy link
Author

bairog commented Mar 3, 2021

@JacquelineWiddis Visual Studio 2019 16.9 is released and considered to be a new Servicing Baseline.
In Servicing Baseline docs there is an image:

Did I understand it correctly that Visual Studio 16.9 will be the penultimate baseline version (before last baseline version 16.final)?
Does this mean that .NET 6 LTS will be the last version that can be targeted by Visual Studio 2019?
Does .NET 7 development will be available exclusively in Visual Studio VNext?

@bairog bairog changed the title OS support plans for .NET 6 LTS (and MAUI) - Windows 7 SP1 and Debian 9 OS support plans for .NET 6, .NET 7 and MAUI - Windows 7 SP1 and Debian 9 Mar 3, 2021
@bairog bairog changed the title OS support plans for .NET 6, .NET 7 and MAUI - Windows 7 SP1 and Debian 9 OS support plans for .NET 6, .NET 7 and MAUI - Windows 7SP1 and Debian 9 Mar 3, 2021
@bairog bairog changed the title OS support plans for .NET 6, .NET 7 and MAUI - Windows 7SP1 and Debian 9 OS support plans for .NET 6, .NET 7 and MAUI - Windows 7 SP1 and Debian 9 Mar 3, 2021
@bairog
Copy link
Author

bairog commented Apr 20, 2021

@JacquelineWiddis @madskristensen @timheuer Visual Studio 2022 is announced and it is stated that

Visual Studio 2022 will have full support for .NET 6 and its unified framework for web, client, and mobile apps for both Windows and Mac developers. That includes the .NET Multi-platform App UI (.NET MAUI) for cross-platform client apps on Windows, Android, macOS, and iOS. You can also use ASP.NET Blazor web technologies to write desktop apps via .NET MAUI.

Does .NET 6 development will be available exclusively in VS 2022 or it will be also possibe in latest versions of VS 2019?
What about plans for .NET 7?

@bairog
Copy link
Author

bairog commented May 26, 2021

.NET Hot Reload was announced today and it is stated that

While some capability is being made available in early .NET 6 previews and in Visual Studio 2019, for the full power of this feature we are targeting .NET 6 (and future releases of .NET) and Visual Studio 2022 as the set of frameworks and tooling that will have the most complete and optimized experience.

@LyalinDotCom maybe you can clarify MS intentions: does .NET 6 (I mean final version, not preview) development will be available exclusively in Visual Studio 2022 or it will be also possibe in future versions of Visual Studio 2019?
Thank you in advance.

@timheuer
Copy link
Member

@bairog Yes the current plan is that Visual Studio 2022 will be the supported tool version for .NET 6 development (when final as you note).

@bairog
Copy link
Author

bairog commented May 26, 2021

@bairog Yes the current plan is that Visual Studio 2022 will be the supported tool version for .NET 6 development (when final as you note).

@timheuer @mikadumont I think Microsoft should reconsider that plan and make .NET 6 (final version) development available both for Visual Studio 2019 and 2022 (latter may have more rich tooling and have more capabilities for example).
Many companies recently invested in the purchase of Visual Studio 2019 due to the long lack of news about Visual Studio VNext.
Developer Community topic
Thank you in advance.

@John0King
Copy link

I can't understand why the dotnet team interested in Drop OS(eg. Devs, Enterprise, customers) , why can not you guys make thin native layer to make OS support easier ? I mean look at Java, they never try to drop any OS in the past/ now / future !!!!

@bairog
Copy link
Author

bairog commented Jul 19, 2021

@JacquelineWiddis @madskristensen @timheuer @mikadumont @richlander .NET 6 Preview 6 is announced and it is stated that

Starting with .NET 6 Preview 6, we’ve tested and support Visual Studio 2022 Preview 2.

But what exactly does it mean? Visual Studio 2022 is tested and supported in addittion to Visual Studio 2019?
Is it still possible to develop applications for .NET 6 preview 6 with Visual studio 2019?
Thank you in advance.

@mairaw
Copy link
Contributor

mairaw commented Jul 20, 2021

You can see in the download page @bairog what's the minimum version of VS supported:
https://dotnet.microsoft.com/download/dotnet/6.0

@bairog
Copy link
Author

bairog commented Jul 20, 2021

You can see in the download page @bairog what's the minimum version of VS supported:
https://dotnet.microsoft.com/download/dotnet/6.0

On that page for example .NET 6.0.0-preview.5 has some strange VS version Visual Studio 2019 (v17.0 latest preview). Misprint?

P.S. According to Visual Studio 2019 16.11 Preview 2 announce

Version 16.11 will be the final version of Visual Studio 2019 and receive support through April 2029

Please make .NET 6.0 final available both for Visual Studio 2019 version 16.11 and Visual Studio 2022. Visual Studio 2022 may have more rich tooling for example. But Visual Studio 2019 version 16.11 should be able to build and debug a project targeting NET 6 final. It is not good practice for a later .NET6 preview to drop support of IDE that was supported in the previous .NET6 preview.

Moreover, Visual Studio 2019 is stable and supported in production use. Visual Studio 2022 by contrast is in an early preview and is unlikely to be stable and production-ready until November 2021, when the final version of .NET 6 is released.

Hope MS will hear me and understand my argumentation .

@mairaw
Copy link
Contributor

mairaw commented Jul 20, 2021

@rbhanda can you check on the VS version for .NET 6 preview 5? @bairog is right that there's a mismatch there.

I'll let others on the team chime in about future support plans re. Visual Studio and .NET 6.

@rbhanda
Copy link
Contributor

rbhanda commented Jul 20, 2021

#6485 is created to correct the VS support version for .NET 6 Preview 5

@bairog
Copy link
Author

bairog commented Jul 29, 2021

I perfectly understand (at least it looks like this) that Microsoft plans to release Visual Studio 2019 version 16.11 (the final planned minor version) sometime in August-September, and then concentrate all its efforts on polishing Visual Studio 2022 and .NET 6 until their joint final release in November.
And most likely the final version of Visual Studio 2022 by November will have more features and tooling regarding .NET development. I really hope that at least the ability to build and debug a project targeting NET 6 final will be then backported to Visual Studio 2019 version 16.11.x. Looking forward to your final correct decision.

@bairog bairog changed the title OS support plans for .NET 6, .NET 7 and MAUI - Windows 7 SP1 and Debian 9 Visual Studio 2019 and ability to build/debug a project will target .NET 6 REL Jul 30, 2021
@bairog bairog changed the title Visual Studio 2019 and ability to build/debug a project will target .NET 6 REL Visual Studio 2019 and ability to build/debug a project that will target .NET 6 REL Jul 30, 2021
@mairaw
Copy link
Contributor

mairaw commented Aug 10, 2021

Tagging @jamshedd to help with this question.

@jamshedd
Copy link
Member

Tagging @jamshedd to help with this question.

There were many questions in this thread so which one were you particularly thinking about :)

I will take the Win7 one - while this is by no means a final decision yet it is likely .NET 7 will not support Win7 since we would be shipping .NET 7 very close (Nov 2022) to when Win7 ESU ends (Jan 2023). But there are many factors that go into the decision including the portion of customers actively using Win7 at that point. We should have something to share around that next year.

Regarding VS support, as Tim already mentioned .NET 6 development (and also .NET7, etc.) will be supported on Visual Studio 2022.

@bairog
Copy link
Author

bairog commented Aug 11, 2021

Regarding VS support, as Tim already mentioned .NET 6 development (and also .NET7, etc.) will be supported on Visual Studio 2022.

Very sad to hear. .NET 6 preview 4 development was supported on Visual Studio 2019 16.11 preview. Starting from .NET 6 preview 5 onwards only Visual Studio 2022 preview is supported. It is not good practice to drop support of IDE between adjacent previews.

P. S. Since Visual Studio 2019 16.11 was released yesterday - looks like it's final MS decision concerning .NET 6.

@timheuer
Copy link
Member

Very sad to hear. .NET 6 preview 4 development was supported on Visual Studio 2019 16.11 preview. Starting from .NET 6 preview 5 onwards only Visual Studio 2022 preview is supported. It is not good practice to drop support of IDE between adjacent previews.

We tested the preview of .NET on top of the preview of 16.x builds because VS 2022 wasn't even yet available. As soon as it was and where we've been focusing our support for best experiences with tooling capabilities, we made that change and announced in our release blogs. We're making specific tooling investments for .NET 6 scenarios in VS2022 across different aspects of IDE scenarios.

@bairog
Copy link
Author

bairog commented Aug 12, 2021

We tested the preview of .NET on top of the preview of 16.x builds because VS 2022 wasn't even yet available.

I know. I read MS devblogs regularly.

As soon as it was and where we've been focusing our support for best experiences with tooling capabilities, we made that change and announced in our release blogs. We're making specific tooling investments for .NET 6 scenarios in VS2022 across different aspects of IDE scenarios.

@timheuer Let me clarify once again: I'm not talking about tooling capabilites parity for VS 2022 and VS 2019. I'm only asking for build and debug capability (regarding .NET 6 REL in VS 2019). VS 2019 16.11 today allows to compile a project with net6.0 TFM (even with the latest .NET 6 preview 7 SDK) and then attach a debuger to a running process. And I'm trying to convince you to preserve this two simple funtionalities also for .NET 6 REL.
VS 2022 without any doubt should be a next gen IDE (compared to VS 2019) with a richer tooling, more functional designer, etc. But Microsoft should let VS 2019 customers just simply build and debug their applications targeting .NET 6 REL. So that VS 2019 will have "closed development chain" from one LTS version of .NET to the next one (.NET Core 3.1 LTS -> .NET 5.0 -> .NET 6.0 LTS). The same logic can be used for VS 2022 as well (.NET 6.0 LTS -> .NET 7.0 -> .NET 8.0 LTS development can be available for it in future).
I really hope that Microsoft will carefully consider my proposal and allow building and debugging .NET 6.0 REL with VS 2019 16.11.

@bairog
Copy link
Author

bairog commented Sep 15, 2021

@timheuer @jamshedd @mairaw
.NET 6.0-rc1 was released yesterday and is “go live” - so there should be an IDE with the same license type.
But as I can see yesterday's VS 2022-preview4 is still in preview.
VS 2019 16.11.x is stable but Microsoft team again and again says that it is not supported for .NET 6.0.

  1. So what’s the recommended and supported way to build .NET 6.0-rc1 applications in production?
  2. For today I can still build and debug .NET 6.0-rc1 applications (at least console, WinForms and WPF) with VS 2019 by enabling preview SDKs in VS2019 settings and manually setting TFM in .csproj file - many thanks for leaving this possibility for developers. I kindly ask Microsoft to leave this unchanged also for .NET 6.0 GA. Thank you in advance.

@timheuer
Copy link
Member

timheuer commented Sep 15, 2021

@timheuer @jamshedd @mairaw
.NET 6.0-rc1 was released yesterday and is “go live” - so there should be an IDE with the same license type.

  1. So what’s the recommended and supported way to build .NET 6.0-rc1 applications in production?

This is correct the runtime platforms now have a go-live license. VS 2022 Preview 4 is the recommended tool for .NET 6 rc1 still. The tools are still in preview as you note and this is very common given platforms lock down a bit before giving tools some more time to finish support for final runtime APIs, scenarios, packages, naming, etc. We are still finishing VS features for .NET 6 around areas like hot reload, editor support for new C# 10 Lang features, and more. In general VS is more than just the current runtime release and so many features across the IDE are still finishing and this is not uncommon to have a platform have a go-live license for deployment while an IDE is still in preview. In fact as you and other devs use VS2022 for development please keep logging feedback bugs from VS for things that may not be working for your project/scenarios. We are still working on finishing and improving quality for .NET 6 projects but for many more things across the IDE.

@bairog
Copy link
Author

bairog commented Nov 9, 2021

@timheuer @jamshedd @mairaw
Visual Studio 2022 17.0.0 and .NET 6.0 were released yesterday. According to .NET 6.0 Known Issues docs:

.NET 6 is supported with Visual Studio 2022 and MSBuild 17. It is not supported with Visual Studio 2019 and MSBuild 16.
If you build .NET 6 projects with MSBuild 16.11, for example, you will see the following error:
warning NETSDK1182: Targeting .NET 6.0 in Visual Studio 2019 is not supported
You can use the .net 6 SDK to target downlevel runtimes in 16.11.

Could you clarify what exactly does phrase You can use the .net 6 SDK to target downlevel runtimes in 16.11 mean?
For today I was able to build and debug test .NET 6.0 applications (at least Console, WinForms and WPF) with latest Visual Studio 2019 16.11.5 by enabling preview SDKs in VS 2019 settings and manually setting TFM in .csproj file. Warning NETSDK1182 appears in command line but allows me to build, run and debug my test applications with no issues.

@timheuer
Copy link
Member

You can use the .net 6 SDK to target downlevel runtimes in 16.11

If you target net5.0 or lower you can use the .NET 6 SDK to still build them and target.

@SymbioticKilla
Copy link

SymbioticKilla commented Nov 15, 2021

@timheuer @jamshedd @mairaw There is a problem with NET Analyzers in VS2019 + NET 6.0 SDK is installed:
image

Warning CS8032 An instance of analyzer Microsoft.CodeAnalysis.MakeFieldReadonly.MakeFieldReadonlyDiagnosticAnalyzer cannot be created from C:\Program Files\dotnet\sdk\6.0.100\Sdks\Microsoft.NET.Sdk\codestyle\cs\Microsoft.CodeAnalysis.CodeStyle.dll: Could not load file or assembly 'Microsoft.CodeAnalysis, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

Will it be fixed or is there any workaround? VS2019 should actually use lower version for analyzing.

@mairaw
Copy link
Contributor

mairaw commented Nov 16, 2021

@SymbioticKilla is your project targeting .NET 6 or earlier versions? If targeting .NET 6, you need to use Visual Studio 2022. But typically, VS issues should be reported through Help > Send Feedback > Report a Problem to help us triage issues better.

@SymbioticKilla
Copy link

@SymbioticKilla is your project targeting .NET 6 or earlier versions? If targeting .NET 6, you need to use Visual Studio 2022. But typically, VS issues should be reported through Help > Send Feedback > Report a Problem to help us triage issues better.

Hi @mairaw,

thank you for reply. No, the projects target .NET Core 3.1. The problem shows up after installing SDK 6.0.
I will try to report the issue.

@timheuer
Copy link
Member

@SymbioticKilla please report through VS Feedback and send me the link of the issue you reported...I'll route it accordingly.

@SymbioticKilla
Copy link

@SymbioticKilla please report through VS Feedback and send me the link of the issue you reported...I'll route it accordingly.

@timheuer Thank you! https://developercommunity.visualstudio.com/t/VS2019--Installation-of-SDK-60-produce/1585314?space=8&q=vs2019+3.1&stateGroup=active

@bairog bairog closed this as completed Nov 22, 2021
@bairog
Copy link
Author

bairog commented Apr 13, 2022

BTW. For today I was able to build and debug my test .NET 6.0 applications (at least Class Library, Console, WinForms and WPF) with latest Visual Studio 2019 16.11.12 by enabling Environment->Preview Features->Use previews of the .NET SDKs (requires restart) checkbox in VS 2019 options, creating a new project targeting .NET 5.0 and then manually setting tag to net6.0 in .csproj.
Warning NETSDK1182 appears in command line but allows me to build, run and debug applications with no issues.
That workaround is not officially supported by Microsoft but still working for today…
You can also add <LangVersion>preview</LangVersion> line to .csproj file to be able to use C# 9 features with Visual Studio 2019. C# 10 and above cannot be used with Visual Studio 2019.

@timheuer People are still adding comments to Developer Community feature demand asking to make .NET 6 LTS development available in Visual Studio 2019.
.NET 5 reaches end of support at 8 May 2022. Developers that use Visual Studio 2019 (whose companies doesn't plan to upgrade IDEs in near future) soon will have only two options: stay on unsupported (and potentially insecure) .NET 5 or downgrade to . NET 3.1 or even .NET Framewrok 4.8 (which is hardy acceptable). I really hope that Microsoft will carefully consider that proposal, reconsider current desicion and allow building and debugging .NET 6.0 LTS with VS 2019 16.11.x.

@bairog bairog reopened this Apr 13, 2022
@Applesauce314
Copy link

@timheuer People are still adding comments to Developer Community feature demand asking to make .NET 6 LTS development available in Visual Studio 2019. .NET 5 reaches end of support at 8 May 2022. Developers that use Visual Studio 2019 (whose companies doesn't plan to upgrade IDEs in near future) soon will have only two options: stay on unsupported (and potentially insecure) .NET 5 or downgrade to . NET 3.1 or even .NET Framework 4.8 (which is hardy acceptable). I really hope that Microsoft will carefully consider that proposal, reconsider current decision and allow building and debugging .NET 6.0 LTS with VS 2019 16.11.x.

Even if you downgrade to 3.1 Core that reaches end of support in December 2022 (.Net Core Lifecycle).

The support for Visual Studio 2019 v16.11 is listed to be until 2029 (VS 2019 Product Lifecycle) so if things remain as they currently are you will be unable to target a supported .Net version for the last 7 years of its lifecycle. (Ironically .NET Framework is still supported since its lifecycle is tied to Windows).

As it stands the latest LTS version of visual studio available on November 7, 2021, will be unable to target .Net in a supported manner 11 months and 26 days later.

@bairog
Copy link
Author

bairog commented Apr 21, 2022

@Applesauce314 Absolutelly agree.
Don't forget to leave a comment and vote on Developer Community feature demand - maybe Microsoft will finally hear us.

@richlander
Copy link
Member

We are not going to support .NET 6 with Visual Studio 2019. This decision will not be changed. You need to use Visual Studio 2022 for .NET 6. I appreciate that some companies have not upgraded to that version.

Is it possible to close this issue given that clarity?

@bairog
Copy link
Author

bairog commented Apr 22, 2022

Very disappointing to hear that this decision will not be changed.

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

No branches or pull requests