It’s been a while that I’m receiving this duplicate errors when I start the editor, but until today I could just clear and move on with my life.
The problem is that I had to update the editor to a newer version because of the Localization package and now these errors won’t go away, there seems to be some classes duplicated inside the Purchasing Package, I have already uninstalled and reinstalled a couple times, tried deleting the @purchasing folder inside the Packages, but nothing seems to work. Here follows the main errors:
and
Library\PackageCache\com.unity.purchasing@3.0.2\Runtime\WinRTStub\Factory.cs(15,23): error CS0433: The type ‘IWindowsIAP’ exists in both ‘UnityEngine.Purchasing.WinRTCore, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null’ and ‘winrt, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null’
These are the ones that clearing the editor won’t go away, than there are another 74 errors that when I hit Clear they’ll disappear, here’s a snippet of my console
I managed to solve the first error by my own, deleted the folder Unity Purchasing inside of Assets/Plugins, than I deleted the folder Library\PackageCache\com.unity.purchasing@3.0.2 and finally uninstalled the Unity purchasing. When I reinstalled it the errors were gone.
All the others (Nearly 70 errors) are still there every time unity compiles a script, but I just hit Clear and get rid of them.
If you have any idea what’s happening I’d appreciate.
If you review the release notes, it mentions the need to remove /Assets/Plugins/Unity Purchasing folders. Ensure you no longer use the Services window to install or update IAP, it’s done now via Package Manager (only). The In App Purchasing library 4.1.0 has just been released. You might want to compare to a new/empty project and add IAP.