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

Setting WindowsPackageType to None makes Visual Studio think it is missing SDK references #2870

Closed
Balkoth opened this issue Aug 18, 2022 · 8 comments
Assignees
Labels
area-DeveloperTools Issues related to authoring (source and IDL), debugging, HotReload, LiveVisualTree, VS integration bug Something isn't working

Comments

@Balkoth
Copy link

Balkoth commented Aug 18, 2022

Describe the bug

Setting WindowsPackageType to None makes Visual Studio think it is missing SDK references. I could not find any information on how to resolve this, the project builds and runs fine. Is there something wrong with my installation or is this common behaviour?

What needs to be done to get rid of those exclamation marks?

Steps to reproduce the bug

  1. Create a new WinUI3 project
  2. Add <WindowsPackageType>None</WindowsPackageType>
  3. An SDK node gets added under Dependencies with exclamation marks showing something is wrong
    image

Expected behavior

No response

Screenshots

No response

NuGet package version

1.1.4

Packaging type

Packaged (MSIX), Unpackaged

Windows version

Windows 10 version 21H2 (19044, November 2021 Update)

IDE

Visual Studio 2022

Additional context

No response

@btueffers btueffers added area-DeveloperTools Issues related to authoring (source and IDL), debugging, HotReload, LiveVisualTree, VS integration bug Something isn't working labels Aug 18, 2022
@dhoehna
Copy link
Contributor

dhoehna commented Aug 29, 2022

Just curious. I also ran into the, somewhat same issue with <WindowsPackageType>None</WindowsPackageType> are you getting any errors when building?

This is what I got when I set the WindowsPackageType property to none.

#2671

@Balkoth
Copy link
Author

Balkoth commented Aug 29, 2022

In a C# project I do not see any build errors.

@dhoehna
Copy link
Contributor

dhoehna commented Aug 29, 2022

I was able to repro the issue.

All locations referenced via VS are on my computer. I verified all of them.

@btueffers do you know of any VS folks who could chime in and tell us what the issue is?

Dotnet restore does not work. Says everything is up to date. @DrusTheAxe do you know if WASDK behind-the-scenes magic adds SDK depdencies?

@DrusTheAxe
Copy link
Member

Dotnet restore does not work. Says everything is up to date. @DrusTheAxe do you know if WASDK behind-the-scenes magic adds SDK depdencies?

If you're making a packaged app then yes, I think VCLibs may be automagically added to your manifest. Not sure that's going on here or any other 'magic' VS props/targets may be doing. But I know who to ask ;-)

@Scottj1s @evelynwu-msft ?

@Scottj1s
Copy link
Member

This issue is fixed in the next release of Windows App SDK, 1.2 Preview 1.

Internal:
https://dev.azure.com/microsoft/WinUI/_git/microsoft-ui-xaml-lift/pullrequest/7348995?_a=files

@dhoehna
Copy link
Contributor

dhoehna commented Aug 30, 2022

This issue is fixed in the next release of Windows App SDK, 1.2 Preview 1.

Tight. Can this be closed then?

@Scottj1s
Copy link
Member

It's generally best to leave closing to the opener, after verifying.

@Balkoth
Copy link
Author

Balkoth commented Nov 17, 2022

With WASDK 1.2 and Visual Studio 17.4.1 no more SDK node is being shown, so i guess this is fixed.

@Balkoth Balkoth closed this as completed Nov 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-DeveloperTools Issues related to authoring (source and IDL), debugging, HotReload, LiveVisualTree, VS integration bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants