dotnet / maui

.NET MAUI is the .NET Multi-platform App UI, a framework for building native device applications spanning mobile, tablet, and desktop.
https://dot.net/maui
MIT License
22.06k stars 1.73k forks source link

Getting 403 when trying to download MAUI nightly #25112

Open JohnTraDolta opened 1 week ago

JohnTraDolta commented 1 week ago

Description

When i add the package in my csproj eg

...
<MauiVersion>8.0.99-ci.net8.24505.3</MauiVersion>
...
<PackageReference Include="Microsoft.Maui.Controls" Version="$(MauiVersion)" />
...

and run restore i get 403 from nuget. log entry:

Failed to download package 'Microsoft.Maui.Controls.Core.8.0.99-ci.net8.24505.3' from 'https://pkgs.dev.azure.com/xamarin/6fd3d886-57a5-4e31-8db7-52a1b47c07a8/_packaging/42c1603f-3d61-4146-8020-ec5b7b392084/nuget/v3/flat2/microsoft.maui.controls.core/8.0.99-ci.net8.24505.3/microsoft.maui.controls.core.8.0.99-ci.net8.24505.3.nupkg'.
Response status code does not indicate success: 403 (Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature.).

When i go to https://dev.azure.com/xamarin/public/_artifacts/feed/maui-nightly and try to download the package manually i get the same error.

Do i need to be authenticated or do I do anything wrong here?

I followed the guide from here: maui nightly

I got it to work with 8.0.99-ci.net8.24504.1, but initially had the same problems. I cant remember what i did to get it to work

Thanks in advance

Steps to Reproduce

  1. Add the nightly nuget feed
  2. Update the maui packages to 8.0.99-ci.net8.24505.3
  3. Restore nuget packages

Link to public reproduction project repository

No response

Version with bug

Nightly / CI build (Please specify exact version)

Is this a regression from previous behavior?

No, this is something new

Last version that worked well

8.0.91 SR9.1

Affected platforms

iOS, Android

Affected platform versions

No response

Did you find any workaround?

No

Relevant log output

No response

jaosnz-rep commented 1 week ago

The 403 issue cannot be reproduced on the latest 17.12.0 Preview 2.1(8.0.91 & 8.0.99-ci.net8.24505.3 & 8.0.99-ci.net8.24508.1).

JohnTraDolta commented 1 week ago

When i run "dotnet restore --interactive" in the terminal i get this prompt.

[CredentialProvider]DeviceFlow: https://pkgs.dev.azure.com/xamarin/public/_packaging/maui-nightly/nuget/v3/index.json
      [CredentialProvider]ATTENTION: User interaction required.

      **********************************************************************

      To sign in, use a web browser to open the page https://microsoft.com/devicelogin and enter the code ******* to authenticate.

      **********************************************************************

When i follow the link and enter the code i get this message

Pick an account You will be signed in to Azure Artifacts on a remote device or service. Select Back if you aren’t trying to sign in to this application on a remote device or service. Selected user account does not exist in tenant 'Microsoft' and cannot access the application 'd5a56ea4-7369-46b8-a538-c370805301bf' in that tenant. The account needs to be added as an external user in the tenant first. Please use a different account.

I dont get why i need to login in the first place because the packages should be public?

JohnTraDolta commented 1 week ago

And also, im on a mac so can not use visual studio 17.12.0 Preview 2.1