Forum Xamarin.Android

Process cannot access the file '....Android.csproj.nuget.dgspec.json' because it is being used by...

In a project I just started yesterday and was working, I'm getting this error message when I try to update the nugets (which I forgot to do when I first created it)...

"The process cannot access the file ......Android.csproj.nuget.dgspec.json because it is being used by another process"

I have nothing else open (even closed and restarted VS2019... which I've just updated, so I hope that hasn't broken something), have cleaned the solution, and checked that the path is correct, all to no avail. Any other suggestions on how to fix this (or have I maybe broken it with the latest VS update and need to wait for a fix)?

thanks,
Donald.

Best Answer

  • SmartmanAppsSmartmanApps AU ✭✭✭
    Accepted Answer

    @jezh said:
    This should be a known issue, you can follow up it here: https://github.com/NuGet/Home/issues/8692

    Thanks. That one didn't come up in my search. There's a comment "Pinning the sdk to an older version (e.g. 2.1.503) resolves the issue, but this is not sustainable" - how does one do that? i.e. where do you go in VS2019 and what do you click on?

    I had the thought to try VS2017, which thankfully I hadn't uninstalled yet (I was going to to save some room) and which I haven't updated, and that worked. Long term that won't work as some of my projects are using Csharp 8, which isn't supported in VS2017 (i.e. the projects won't load).

    Besides, in order to see if your VS update is successful, you can try a new app to test.

    Yeah, well that worked,so not any help in this case. Hopefully there'll be a fix coming through soon. Thanks!

Answers

  • jezhjezh Member, Xamarin Team Xamurai

    This should be a known issue, you can follow up it here: https://github.com/NuGet/Home/issues/8692

    Besides, in order to see if your VS update is successful, you can try a new app to test.

  • SmartmanAppsSmartmanApps AUMember ✭✭✭
    Accepted Answer

    @jezh said:
    This should be a known issue, you can follow up it here: https://github.com/NuGet/Home/issues/8692

    Thanks. That one didn't come up in my search. There's a comment "Pinning the sdk to an older version (e.g. 2.1.503) resolves the issue, but this is not sustainable" - how does one do that? i.e. where do you go in VS2019 and what do you click on?

    I had the thought to try VS2017, which thankfully I hadn't uninstalled yet (I was going to to save some room) and which I haven't updated, and that worked. Long term that won't work as some of my projects are using Csharp 8, which isn't supported in VS2017 (i.e. the projects won't load).

    Besides, in order to see if your VS update is successful, you can try a new app to test.

    Yeah, well that worked,so not any help in this case. Hopefully there'll be a fix coming through soon. Thanks!

Sign In or Register to comment.