Skip to content

Not able to build with VS2019 #3132

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

Closed
Noemata opened this issue Feb 13, 2020 · 6 comments
Closed

Not able to build with VS2019 #3132

Noemata opened this issue Feb 13, 2020 · 6 comments
Labels
bug 🐛 An unexpected issue that highlights incorrect behavior build 🔥 documentation 📃

Comments

@Noemata
Copy link

Noemata commented Feb 13, 2020

Describe the bug

Not able to build with Visual Studio 2019. All the projects that use "MSBuild.Sdk.Extras" report this error:

Microsoft.Toolkit.Uwp.UI.csproj : error : The expression "[System.IO.Path]::GetDirectoryName('')" cannot be evaluated. The path is not of a legal form. ....nuget\packages\msbuild.sdk.extras\2.0.54\Sdk\Sdk.props

Steps to Reproduce

Steps to reproduce the behavior:

  1. Load Windows Community Toolkit.sln in VS2019

Expected behavior

Projects should load.

Environment

Latest of everything.

@Noemata Noemata added the bug 🐛 An unexpected issue that highlights incorrect behavior label Feb 13, 2020
@ghost ghost added the needs triage 🔍 label Feb 13, 2020
@ghost
Copy link

ghost commented Feb 13, 2020

Hello Noemata, thank you for opening an issue with us!

I have automatically added a "needs triage" label to help get things started. Our team will investigate the issue and help solve it ASAP. Other community members may also look into the issue and provide feedback 🙌

@michael-hawker
Copy link
Member

@Noemata there's a weird hard dependency on a specific version of some SDKs that VS doesn't install automatically. :( We're trying to better document this here: https://github.com/windows-toolkit/WindowsCommunityToolkit/pull/3115/files

But we also need to try removing our globals.json. If you check the version of the .NET Core 3.0.x SDK you have, make sure to modify the globals.json file to match it.

@michael-hawker
Copy link
Member

FYI @marcpems @Kyaa-dost

@Noemata
Copy link
Author

Noemata commented Feb 14, 2020

Wow @michael-hawker. You were right. Thank you.

My previous dotnet --info was:

.NET Core SDK (reflecting any global.json):
Version: 3.1.101
Commit: b377529961

Runtime Environment:
OS Name: Windows
OS Version: 10.0.18363
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\3.1.101\

Host (useful for support):
Version: 3.1.1
Commit: a1388f194c

.NET Core SDKs installed:
3.1.101 [C:\Program Files\dotnet\sdk]

.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.15 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.15 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.0.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.1 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.15 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.0.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.1 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.0.2 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 3.1.1 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

And with the installation of dotnet-sdk-3.0.101-win-x64.exe, it now reads:

.NET Core SDK (reflecting any global.json):
Version: 3.1.101
Commit: b377529961

Runtime Environment:
OS Name: Windows
OS Version: 10.0.18363
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\3.1.101\

Host (useful for support):
Version: 3.1.1
Commit: a1388f194c

.NET Core SDKs installed:
3.0.101 [C:\Program Files\dotnet\sdk]
3.1.101 [C:\Program Files\dotnet\sdk]

.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.15 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.15 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.0.1 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.0.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.1 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.15 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.0.1 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.0.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.1 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.0.1 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 3.0.2 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 3.1.1 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

I suppose the good news is that all the .Net Core SDKs play along with each other.

You're welcome to close this issue once the docs are a tad more clear on this requirement, although this is something that perhaps should come along with the VS2019 install payload as a default.

@Kyaa-dost
Copy link
Contributor

@Noemata Glad the info provided by Michael helped resolve the problem. We have a PR open in terms of doc instructions and requirements and will be merged soon.

@Kyaa-dost
Copy link
Contributor

Closing this as the Doc PR was merged.

@ghost ghost locked as resolved and limited conversation to collaborators Feb 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug 🐛 An unexpected issue that highlights incorrect behavior build 🔥 documentation 📃
Projects
None yet
Development

No branches or pull requests

3 participants