2

From several days I'm trying to open a Xamarin Forms Project in Visual Studio for Mac, but it gets stuck at "Restoring packages for solution" and I cannot pass that, I cannot work on the project.

I also tried to import that project into Windows machine, in Visual Studio and I have the same situation, it gets stuck loading the resources.

I have tried to clear the cache, to uninstall the Visual Studio, to clear the temp folder, but no luck...

It gets stucked at "Getting restore information for project /Users/admin/Desktop/Development/MyProjectApp/MyProject/MyProject.Android/MyProject.Android.csproj". Even with this, I can click on deploy on android button, on Macos I get no output, and is loading forever... and on Windows it gets stucked at "Creating C:\Users\admin\AppData\Local\Xamarin.Android\Cache\Mono.Android.Platform.ApiLevel_28.apk"

Could you please help me with this situation? It is anyone else who had this problem?

codirxd
  • 37
  • 1
  • 7
  • 1
    You need to provide some more info. Have you checked package restore logs, what do they say? – Cheesebaron Aug 27 '20 at 07:03
  • Yes, it gets stucked at "Getting restore information for project /Users/admin/Desktop/Development/MyProjectApp/MyProject/MyProject.Android/MyProject.Android.csproj". Even with this, I can click on deploy on android button, on Macos I get no output, and is loading forever... and on Windows it gets stucked at "Creating C:\Users\admin\AppData\Local\Xamarin.Android\Cache\Mono.Android.Platform.ApiLevel_28.apk". – codirxd Aug 27 '20 at 08:07
  • Make sure the version of VS is latest . Check https://developercommunity.visualstudio.com/content/problem/499891/cloud-not-restore-nuget-packages-for-xamarin-forms.html – Lucas Zhang Aug 27 '20 at 13:53
  • 1
    Clear Nuget cache (https://stackoverflow.com/questions/30933277/how-can-i-clear-the-nuget-package-cache-using-the-command-line) Delete bin obj and packages (if there) folders and restore again. – Singhal2 Aug 27 '20 at 20:22
  • Did you came up with a solution? – giorgos Nov 22 '20 at 10:47
  • Actually no... :( Unfortunatelly I had to create a new project and 'copy' the files. – codirxd Nov 25 '20 at 15:10

2 Answers2

1

For me it only happens when it is on full screen mode. If I put it on a Desktop normal window it seems to work normally... I don't know if it is the reason but for me works all the time..

What I normally do is to ensure that VS is not on full screen mode at start...

HTP
  • 11
  • 1
0

For me, deleting bin and obj folders from the shared project fixed this issue.

  1. Unload project
  2. Delete bin and shared folder
  3. Reload project
user10398433
  • 426
  • 3
  • 10