maui icon indicating copy to clipboard operation
maui copied to clipboard

Warning NU1603 received in File New Maui 7.0 RC2 App

Open vsfeedback opened this issue 1 year ago • 10 comments

This issue has been moved from a ticket on Developer Community.


[severity:It bothers me. A fix would be nice] [regression] [worked-in:17.4.0.Preview 3.0, fails in Preview 4.0]

  1. Open the Visual Studio 2022 Startup window and Create a new Maui solution
  2. When prompted, select .Net 7.0 as the target
  3. Update Nuget (if needed; in my case no updates were necessary)
  4. Build | Clean Solution
  5. Build | Rebuild Solution

The output window shows the following warning messages:

2>MauiExtendedWindowsSample -> D:\Maui\MauiExtendedWindowsSample\bin\Debug\net7.0-android\MauiExtendedWindowsSample.dll
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Configuration (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Configuration 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Configuration 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.DependencyInjection (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.DependencyInjection 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.DependencyInjection 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Logging (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Logging 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Logging 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Logging.Abstractions (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Logging.Abstractions 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Logging.Abstractions 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Logging.Debug (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Logging.Debug 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Logging.Debug 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Configuration (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Configuration 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Configuration 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.DependencyInjection (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.DependencyInjection 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.DependencyInjection 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Logging (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Logging 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Logging 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Logging.Abstractions (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Logging.Abstractions 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Logging.Abstractions 7.0.0-rc.2.22472.3 was resolved.
2>D:\Maui\MauiExtendedWindowsSample\MauiExtendedWindowsSample.csproj : warning NU1603: MauiExtendedWindowsSample depends on Microsoft.Extensions.Logging.Debug (>= 7.0.0-rc.2.22430.11) but Microsoft.Extensions.Logging.Debug 7.0.0-rc.2.22430.11 was not found. An approximate best match of Microsoft.Extensions.Logging.Debug 7.0.0-rc.2.22472.3 was resolved.
2>Done building project "MauiExtendedWindowsSample.csproj".

Original Comments

Feedback Bot on 10/21/2022, 00:35 AM:

(private comment, text removed)

Peng Ge [MSFT] on 10/24/2022, 08:21 PM:

(private comment, text removed)

Gary Lewis on 10/25/2022, 01:02 PM:

(private comment, text removed)

Peng Ge [MSFT] on 10/26/2022, 11:27 PM:

(private comment, text removed)


Original Solutions

(no solutions)

vsfeedback avatar Nov 01 '22 18:11 vsfeedback

This persists with Maui 7.0 RC2.

IndianaGary avatar Nov 01 '22 22:11 IndianaGary

Can you attach a binlog? https://github.com/xamarin/xamarin-macios/wiki/Diagnosis

PureWeen avatar Nov 03 '22 19:11 PureWeen

Hi @vsfeedback. We have added the "s/needs-info" label to this issue, which indicates that we have an open question for you before we can take further action. This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

ghost avatar Nov 03 '22 19:11 ghost

Zipped binlog attached...

msbuild.zip

IndianaGary avatar Nov 04 '22 00:11 IndianaGary

This probably happens because we build against potentially internal versions that haven't been published to a public feed. Should go away when all the versions are released when we go GA in the upcoming week.

As a workaround, if you don't want to see these messages, you can add the packages with the specified version to go around the warnings.

Should be along the lines of, inside your csproj:

<PackageReference Include="Microsoft.Extensions.Logging" Version="7.0.0-rc.2.22472.3" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="7.0.0-rc.2.22472.3" />
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="7.0.0-rc.2.22472.3" />

jfversluis avatar Nov 04 '22 15:11 jfversluis

Hi @vsfeedback. We have added the "s/needs-info" label to this issue, which indicates that we have an open question for you before we can take further action. This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

ghost avatar Nov 07 '22 15:11 ghost

Hi @jfversluis

I still have these warnings with the GA.

Am I alone having these warnings ?

Marc

marcmognol avatar Nov 10 '22 20:11 marcmognol

Hi @vsfeedback. We have added the "s/try-latest-version" label to this issue, which indicates that we'd like you to try and reproduce this issue on the latest available public version. This can happen because we think that this issue was fixed in a version that has just been released, or the information provided by you indicates that you might be working with an older version.

You can install the latest version by installing the latest Visual Studio (Preview) with the .NET MAUI workload installed. If the issue still persists, please let us know with any additional details and ideally a reproduction project provided through a GitHub repository.

This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

ghost avatar Nov 11 '22 15:11 ghost

@marcmognol if you're still seeing on GA can you attach a binlog? repro?

PureWeen avatar Nov 11 '22 15:11 PureWeen

Thanks @PureWeen for your reply.

I checked again this afternoon, and it was due to my Azure Artifacts private feed.

It is working good now !

Thanks again.

marcmognol avatar Nov 11 '22 17:11 marcmognol