Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  2. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

IAP Erros in Unity 2019.2.9f

Discussion in 'Unity IAP' started by justtime, Oct 12, 2019.

  1. justtime

    justtime

    Joined:
    Oct 6, 2013
    Posts:
    351
    Hi there! There are some errors on project open in Editor

    1)
    Code (CSharp):
    1. Error: Could not load signature of UnityEngine.Purchasing.UIFakeStore:GetOkayButton due to: Could not load file or assembly 'UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. assembly:UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null type:<unknown type> member:(null) signature:<none>
    2)
    Code (CSharp):
    1. Assembly 'Assets/Plugins/UnityPurchasing/Bin/Editor.dll' will not be loaded due to errors:
    2. Reference has errors 'Stores'.
    3)
    Code (CSharp):
    1. Assembly 'Assets/Plugins/UnityPurchasing/Bin/Stores.dll' will not be loaded due to errors:
    2. Unable to resolve reference 'UnityEngine.UI'. Is the assembly missing or incompatible with the current platform?
    3. Reference validation can be disabled in the Plugin Inspector.
    Is it important or i can skip these ones?

    How IAP should be properly installed? Via PM, Asset Store, Services window?
     
    Last edited: Oct 13, 2019
  2. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Unity 2019 support will be coming in the next IAP release, hopefully this week.
     
    justtime likes this.
  3. rockin

    rockin

    Joined:
    Dec 11, 2013
    Posts:
    11
    I upgraded to the latest version, but I still get:
    Error: Could not load signature of UnityEngine.Purchasing.UIFakeStore:GetOkayButton due to: Could not load file or assembly 'UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. assembly:UnityEngine.UI,


    and


    error CS1704: An assembly with the same simple name 'Editor' has already been imported. Try removing one of the references (e.g. '[..]\Library\ScriptAssemblies\Editor.dll') or sign them to enable side-by-side.



    Help :(
     
    Last edited: Oct 21, 2019
  4. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    I'm getting the same issue using cloud build (and have been since I started using 2019.2.x), and I completely wiped out my plugins directory and re-imported IAP after this latest update.
     
  5. JustForFunHZ

    JustForFunHZ

    Joined:
    Dec 10, 2018
    Posts:
    1
    same error in 2019.2.3f1
     
  6. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Steps to reproduce please
     
  7. rockin

    rockin

    Joined:
    Dec 11, 2013
    Posts:
    11
    Update: in my case, I had to remove the Xiaomi SDK from the package manager. (Unity 2019.2.9)
    On brand new projects I wasn't having this error, so that's what indicated that something with this specific project could be the culprit.
     
  8. Livealot

    Livealot

    Joined:
    Sep 2, 2013
    Posts:
    137
    I've been encountering this as well as I'm trouble-shooting the 1.23 update

    My repro scenario involves two machines and switching platforms, using Git in between. While a 2 machine scenario may sound exotic, I think it's pretty common to have a Mac setup for iOS builds and a Windows machine setup for Android builds.
    1. I get a stable plugin import for Android on my Windows machine. All good
    2. I push that commit from my Windows machine to my repo
    3. I pull that commit to my Mac and get that error
    4. I re-import the plugin from the Asset Store onto my Mac, and all is good again.
    5. I push that commit from my Mac to my repo
    6. I pull that commit back to my Windows machine and get that error again
    7. rinse and repeat
     
  9. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Would be good to test first without Git involved to see where the issue may be. One thing you might want to test without Git is to make a back up and delete the /Library folder and test. Source control systems often ignore and don't include the /Library folder.
     
  10. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    I'm using Unity Cloud Build, and had no issues with IAP in Unity 2018.x. I'm using Bitbucket as source control, and auto-build. This issue has occurred in every upgraded version of Unity since 2019.2.3f1 that I've tried, up through 2019.3.9f1 and the latest Unity IAP version available.

    In earlier of versions of Unity 2019.x I was getting IAP errors in the Unity Editor console. But not in the newer versions.

    If you have trouble reproducing this, let me know if looking at my cloud build setup or repo would help.
     
  11. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    Does the Library folder need to be in source control for Unity Cloud Build to work properly?

    I've never needed it before.
     
  12. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    No, it was a suggestion for testing locally without source control.
     
  13. Livealot

    Livealot

    Joined:
    Sep 2, 2013
    Posts:
    137
    Gave this a try and it did not pop the error. So looks like it has to do with a 2nd machine or the platform switch between iOS and Android
     
  14. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    I just updated my project from 2019.2.9f1 to 2019.2.10f1 and the same error appeared in the console:

    Error: Could not load signature of UnityEngine.Purchasing.UIFakeStore:GetOkayButton due to: Could not load file or assembly 'UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. assembly:UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null type:<unknown type> member:(null) signature:<none>


    I also get the error when I Cloud Build. I completely wiped out everything except for the Assets folder, rebuilt, and pushed to source control for Cloud Build here's the error I'm getting:


    1251: [Unity] Registering precompiled user dll's ...
    1252: [Unity] Registered in 0.358621 seconds.
    1253: [Unity] Platform modules already initialized, skipping
    1254: [Unity] Begin MonoManager ReloadAssembly
    1255: [Unity] Symbol file LoadedFromMemory doesn't match image /BUILD_PATH/keith-244032.aerial.default-android/Library/PackageCache/com.unity.ext.nunit@1.0.0/net35/unity-custom/nunit.framework.dll
    1256: [Unity] Error: Could not load signature of UnityEngine.Purchasing.UIFakeStore:GetOkayButton due to: Could not load file or assembly 'UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. assembly:UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null type:<unknown type> member:(null) signature:<none>
    1257: [Unity] (Filename: ./Runtime/Mono/MonoAttributeHelpers.cpp Line: 372)
    1258: [Unity] Unloading broken assembly Assets/Plugins/UnityPurchasing/Bin/Stores.dll, this assembly can cause crashes in the runtime
    1259: [Unity] (Filename: ./Runtime/Mono/MonoManager.cpp Line: 1231)
     
  15. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Please test the build locally first, before using Cloud Build. Make sure you are using IAP 1.23. UnityEngine.UI is now in a package in Unity 2019.2 and above
     
  16. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    Local build works fine for Android, I'm using IAP 1.23 and UnityEngine.UI.

    Should I post in the Cloud Build forum instead?
     
  17. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Yes
     
  18. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    I'm still experiencing this problem, and I haven't received any response on the Unity Cloud Build forum.

    When I upgrade my project from 2019.2.10f1 to 2019.2.11f1 I get this error at the top of my console when I open the project in the editor.

    Code (CSharp):
    1. Error: Could not load signature of UnityEngine.Purchasing.UIFakeStore:GetOkayButton due to: Could not load file or assembly 'UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. assembly:UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null type:<unknown type> member:(null) signature:<none>
    It happens again when I upgrade my project from 2019.2.11f1 to 2019.2.12f1, it doesn't seem to me like the fix that was implemented fully resolved the issue, and some sort of local build workaround was put in place that didn't correct the underlying problem with the project (in the editor). This error is manifesting in the editor when the project is upgraded, and is also carrying over to Unity Cloud Build. It seems like IAP is (and has been) completely broken in Unity Cloud Build for all 2019.x versions.

    Is there anyone using Unity 2019.x and the Unity IAP plugin not receiving this error when they upgrade their project?
     
  19. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Can you still build your project? I've seen that message too, but I can still build my project.
     
  20. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    Yes, I can build locally last time I tried, but I don't have all my iOS and Google certs / signing set up locally, as I've been relying on Unity Cloud Build for that.

    I know that there are different Unity dev teams and it seems the implication is that the (unresponsive) Unity Cloud Build Team should be fixing this problem on their end, but this appears to be a problem with the underlying project. And, it doesn't seem like that problem was "properly" fixed as the error is still appearing in the editor console when upgrading a project, and that problem seems like it's propagating over to Unity Cloud Build.
     
    iluhin-pro likes this.
  21. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    So for clarity, it does build locally but not on Cloud Build? This is an IAP issue
     
  22. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    It builds locally with no errors for Android, but the console does give an error when I upgrade the project to a new version of Unity. Cloud Build for Android gives the error twice if I do a normal build, or once if I do a clean build.
     
  23. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    But does the build complete, even if you see the errors? Trying to get a sense of proper priority.
     
  24. _Keith

    _Keith

    Joined:
    Nov 7, 2015
    Posts:
    27
    The cloud build completes, but the IAP components do not seem to work when I test them in the Google Play Store.

    It may be that I'm not implementing the IAP components correctly though. I had it working properly in 2018.x, but the way the plugin worked seemed to have some substantial updates, and I modified my codebase for 2019.x, when I started getting the error. I tried uploading the Android package to the Google Play Store for testing, but the IAP did not work with 2019.x build and my code changes.
     
  25. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    You would want to test with your local build first, much easier and faster. The device logs would explain why it's not working https://forum.unity.com/threads/how-to-capturing-device-logs-on-android.528680/ . And of course you need to publish on Google Play https://docs.unity3d.com/Manual/UnityIAPGoogleConfiguration.html
     
  26. eladleb4

    eladleb4

    Joined:
    Apr 25, 2016
    Posts:
    34

    Attached Files:

  27. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Separate issue, please see here https://forum.unity.com/threads/iap-crashes-unity-with-unitytls-error-code-7-in.787847/ Please respond there with your input, specifically if it's actually exiting your Editor at runtime and crashing to the desktop (Unity Editor disappears)
     
    eladleb4 likes this.
  28. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    122
    This happen to me... UCB gave this error but build seems complete, and on the other side, my client got the collab project and he got the same error on the Editor Console. Could it be related with Receipt Validation Obfuscator?
     
  29. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    122
    Yeah, seems that UCB doesn't know how to commit the obfuscated receipt validation... I told my client how to do it and the error disappeared from his Editor console.
     
  30. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Can you elaborate, "commit the obfuscated receipt validation" and the solution you provided for your client?
     
  31. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    122
    My client downloaded all the changes from Collab... and was getting that error in the Editor console, so the only thing I thought to try is to set the "license key" into the Window -> Unity IAP -> Receipt Validation Obfuscator and that fixed the error, So I assume that for some reason collab didn't synced that part from my computer to the cloud... maybe Collab doesn't cover that part?
     
  32. JeffDUnity3D

    JeffDUnity3D

    Unity Technologies

    Joined:
    May 2, 2017
    Posts:
    7,174
    Are you able to see the list of file changes after they performed your suggestion?
     
  33. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    122
    There were no file changes is like if that part is not included.
     
  34. sajjadgameactor

    sajjadgameactor

    Joined:
    May 27, 2015
    Posts:
    1
    I had same error after update my unity version from 2019.2.15 to 2019.3.2
    The solution in my case was to comment this line in my IAP manager script
    Code (CSharp):
    1. //builder.Configure<IMicrosoftConfiguration>().useMockBillingSystem = false;
    I also comment
    Code (CSharp):
    1.   //using UnityEngine.UI;
    in that script.
     
    Dazo1985 likes this.
unityunity