-
Notifications
You must be signed in to change notification settings - Fork 310
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
Unable to retrieve package list Mac OS. #574
Comments
Not sure what you have configured but the base URL is a API version 3 but from the trace I can see that you are using the NuGetForUnity version that only supports API version 2. The NuGetForUnity version that support API version 3 is currently in "beta". |
Thank you for the reply, however this happened in a fresh project, and also happens with the head version of NuGetForUnity as well as v3.1.3. Are you saying that these versions don't have any support for v3 on Mac? Because they work fine on Windows. The default NuGet path that is configured fro nuget.org is: https://api.nuget.org/v3/index.json From the error, it looks like NuGet For Unity is trying to run a Windows .exe on mac. |
I get the same type of error even on v3.0.5 and using the v2 NuGet API:
Yet https://www.nuget.org/api/v2/Packages(Id='System.Runtime.CompilerServices.Unsafe',Version='6.0.0') very much exists. |
I also get this error using the CLI tool:
|
The error seems to come from
It uses a encoding that is only available on windows. But normally the code should not run, if you don't have a credential provider lying around on your Mac. It searches in the environment variable NUGET_CREDENTIALPROVIDERS_PATH and in the Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "Nuget", "CredentialProviders")) . So if you delete the files inside this folders it should work.
|
Thanks, renaming/deleting that file seemed to fix both issues. There definitely should be a check to verify that the file is actually executable before using it. It seems that NuGetForUnity keeps regenerating that file as well. |
Yeah the issue is that |
As far as I can see the file isn't downloaded / created it already exists. It is only downloaded if you use azure package source. |
That would partially explain it then, we do use a package from: https://pkgs.dev.azure.com/UnityDeveloperTools/MSBuildForUnity/_packaging/UnityDeveloperTools/nuget/v2/ Then I guess the simplest fix would be to check if CredentialProvider.VSS.exe is actually executable on the provided os (check for executable flag). |
I fixed the issue in #575. I don't have a Mac to test if it works, so it would be nice if you can test if it fixes the issue? You can install it using the .unitypackage build by the Github Action or by installing the package from the PR branch using UPM Git-Url. |
This seems to have fixed the issues, thanks! |
@jbvirt Thanks for testing |
Description
I just added NuGetForUnity to a new project on Mac and am getting this error when trying to view the package list.
The text was updated successfully, but these errors were encountered: