Open yuji-10473 opened 1 year ago
I have the same error on Mac Big Sur
Hi folks,
Thanks for bringing this to our attention. I have a few questions about your implementation:
Hi folks,
Thanks for bringing this to our attention. I have a few questions about your implementation:
Thank you for reply.
- Does the error message appear in both the editor and the app build?
We have confirmed that the same error occurs in the Unity Editor and Linux executable apps.
- Does the issue persist when using the quickstart project?
quickstart I'm trying to clone this.
- Could you verify if a FirebaseCppApp-x_x_x.bundle file exists in your Firebase/Plugins/x86_64 folder?
It cannot be imported because it is not checked when importing the package.
- Could you try if reimporting the SDK made any difference?
I've tried re-importing several times, but nothing changes.
I think that this problem is caused by trying to apply a compatibility check that is not necessary for the execution environment, but is it correct?
Hi @yuji-10473,
Are you importing the SDK as a .unitypackage
file? If so, could you try clicking All when importing the SDK and see if it makes a difference? This ensures all files in the SDK are included in the import.
Hi @paulinon, Yes, all the files were properly imported but still facing the same issue on Mac.
I resolved this Issue on Mac by simply Going to the Folder
It looks like the attached image. The file exists, but I get the same error when running it.
Thanks for the additional information, @yuji-10473. I haven't reproduced the behavior you're facing so far, but I'd like to get to the bottom of this. That said, could you try if @fardeen-khan17's solution made any difference in your implementation? Additionally, could you specify the macOS version you're using? It's possible that an OS update could resolve the issue.
If what @fardeen-khan17 recommended resolves your issue, this seems to be due to macOS blocking untrusted libraries. This issue seems to be reoccurring whenever there is a new macOS release, which is quite annoying.
Alternatively, check your Privacy & Security
system settings and see if there is any notification there about blocking libraries. If so, allow those Firebase libraries.
Please let us know if that is the case. If so, we should probably change this into a task like macOS blocking untrusted Firebase libraries
.
Hi, i have the same issue on Android Studio.
DllNotFoundException: Unable to load DLL 'FirebaseCppApp-11_2_0'. Tried the load the following dynamic libraries: Unable to load dynamic library 'FirebaseCppApp-11_2_0' because of 'Failed to open the requested dynamic library (0x06000000) dlerror() = dlopen failed: library "FirebaseCppApp-11_2_0" not found at Firebase.AppUtilPINVOKE+SWIGExceptionHelper.SWIGRegisterExceptionCallbacks_AppUtil (Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate applicationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate arithmeticDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate divideByZeroDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate indexOutOfRangeDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidCastDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidOperationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate ioDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+E
On my Editor it runs without problems. I have done the Force Resolve of Android too.
I have imported all of FirebaseStorage.unitypackage
and tried more and more times to clear and re-import the package.
Any help? thanks :)
Hey @yuji-10473. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically.
If you have more information that will help us get to the bottom of this, just add a comment!
As yet, the problem is not resolved. I will provide any necessary information. However, I believe that this problem is caused by unnecessary compatibility checks when running in the Unity Editor.
Error: System.TypeInitializationException: The type initializer for 'Firebase.FirebaseApp' threw an exception. ---> System.TypeInitializationException: The type initializer for 'Firebase.LogUtil' threw an exception. ---> System.TypeInitializationException: The type initializer for 'Firebase.AppUtilPINVOKE' threw an exception. ---> System.TypeInitializationException: The type initializer for 'Firebase.AppUtilPINVOKE.SWIGExceptionHelper' threw an exception. ---> System.DllNotFoundException: Unable to load DLL 'FirebaseCppApp-11_3_0'. Tried the load the following dynamic libraries: Unable to load dynamic library 'FirebaseCppApp-11_3_0' because of 'Failed to open the requested dynamic library (0x06000000) dlerror() = dlopen failed: library "FirebaseCppApp-11_3_0" not found
at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0
at System.Runtime.CompilerServices.AsyncTaskMethodBuilder1[TResult].Start[TStateMachine] (TStateMachine& stateMachine) [0x00000] in <00000000000000000000000000000000>:0 at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0 at DJ.GooglePlayGamesSDKPlatform.<Login>b__0_1 (System.String code) [0x00000] in <00000000000000000000000000000000>:0 at System.Runtime.CompilerServices.AsyncVoidMethodBuilder.Start[TStateMachine] (TStateMachine& stateMachine) [0x00000] in <00000000000000000000000000000000>:0 at DJ.GooglePlayGamesSDKPlatform.<Login>b__0_1 (System.String code) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtilPINVOKE+SWIGExceptionHelper.SWIGRegisterExceptionCallbacks_AppUtil (Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate applicationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate arithmeticDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate divideByZeroDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate indexOutOfRangeDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidCastDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidOperationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate ioDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate nullReferenceDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate outOfMemoryDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate overflowDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate systemExceptionDelegate) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtilPINVOKE+SWIGExceptionHelper..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtilPINVOKE..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtil.SetLogFunction (Firebase.LogUtil+LogMessageDelegate arg0) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.LogUtil..ctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.LogUtil..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.FirebaseApp..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Auth.FirebaseAuth.get_DefaultInstance () [0x00000] in <00000000000000000000000000000000>:0 at GooglePlayGames.OurUtils.PlayGamesHelperObject.Update () [0x00000] in <00000000000000000000000000000000>:0 --- End of inner exception stack trace --- at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0 at System.Runtime.CompilerServices.AsyncTaskMethodBuilder
1[TResult].Start[TStateMachine] (TStateMachine& stateMachine) [0x00000] in <00000000000000000000000000000000>:0
at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0
at DJ.GooglePlayGamesSDKPlatform.1[TResult].Start[TStateMachine] (TStateMachine& stateMachine) [0x00000] in <00000000000000000000000000000000>:0 at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0 at DJ.GooglePlayGamesSDKPlatform.<Login>b__0_1 (System.String code) [0x00000] in <00000000000000000000000000000000>:0 at System.Runtime.CompilerServices.AsyncVoidMethodBuilder.Start[TStateMachine] (TStateMachine& stateMachine) [0x00000] in <00000000000000000000000000000000>:0 at DJ.GooglePlayGamesSDKPlatform.<Login>b__0_1 (System.String code) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.FirebaseApp..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Auth.FirebaseAuth.get_DefaultInstance () [0x00000] in <00000000000000000000000000000000>:0 at GooglePlayGames.OurUtils.PlayGamesHelperObject.Update () [0x00000] in <00000000000000000000000000000000>:0 --- End of inner exception stack trace --- at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0 at System.Runtime.CompilerServices.AsyncTaskMethodBuilder
1[TResult].Start[TStateMachine] (TStateMachine& stateMachine) [0x00000] in <00000000000000000000000000000000>:0
at DJ.GooglePlayGamesSDKPlatform.FirebaseAuth (System.String authCode) [0x00000] in <00000000000000000000000000000000>:0
at DJ.GooglePlayGamesSDKPlatform.
at DJ.GooglePlayGamesSDKPlatform.
at DJ.GooglePlayGamesSDKPlatform.
@rekcah1986, @yuji-10473, @SabeenoGH, @juzdepeche
Can any of you confirm whether or not the workaround suggested by fardeen-khan17 is effective in your case?
Specifically, attempt to open Assets/Firebase/Plugins/x86_64/FirebaseCppApp-11_3_0.bundle using a random program like VS code, and see if any permission errors popup and if so attempt to resolve them.
On Mac this is typically a prompt like "FirebaseCppApp.bundle” cannot be opened because it is from an unidentified developer." When that happens you can click "Ok", and then go to your Mac's Security Settings to find an entry like "FirebaseCppApp.bundle” was blocked from use because it is not from an identified developer." and you can click "Open Anyway" and the next time you attempt to open the bundle you should have an "Open" option instead of just ok/cancel.
I have the same problem. OS:macOS Big Sur
DllNotFoundException: FirebaseCppApp-10_4_0 Firebase.AppUtilPINVOKE+SWIGExceptionHelper..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/macos_unity/x86_64/app/swig/Firebase.App_fixed.cs:4072) Rethrow as TypeInitializationException: The type initializer for 'SWIGExceptionHelper' threw an exception. Firebase.AppUtilPINVOKE..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/macos_unity/x86_64/app/swig/Firebase.App_fixed.cs:4092) Rethrow as TypeInitializationException: The type initializer for 'Firebase.AppUtilPINVOKE' threw an exception. Firebase.AppUtil.SetLogFunction (Firebase.LogUtil+LogMessageDelegate arg0) (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/macos_unity/x86_64/app/swig/Firebase.App_fixed.cs:4802) Firebase.LogUtil..ctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/app/src/LogUtil.cs:81) Firebase.LogUtil..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/app/src/LogUtil.cs:37) Rethrow as TypeInitializationException: The type initializer for 'Firebase.LogUtil' threw an exception. Firebase.FirebaseApp..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/macos_unity/x86_64/app/swig/Firebase.App_fixed.cs:2014) Rethrow as TypeInitializationException: The type initializer for 'Firebase.FirebaseApp' threw an exception.
I was having the same problem with Big Sur on my Mac, but after upgrading to Ventura, it went away. FYI.
@AlmostMatt
My environment is not MAC, so I don't get a warning. It is possible to open the file in VS Code. We are aware of the issues that occur with MACs. I believe that the problems that occur on Linux are occurring separately.
@AlmostMatt In my case it is not an error related to Mac permissions. However, I have given up on using Firebase on Unity for now. If I pick it up again later I will let you know.
I had this error for ANDROID and I fix it (I haven't tested it for iOS jet) DllNotFoundException: FirebaseCppApp-11_2_0 assembly:
1) The Firebase and ExternalDependencyManager folders must be located in the Asset folder; you should not move them elsewhere.
2) Delete the Firebase and ExternalDependencyManager folders and then install each Firebase SDK asset you need.
3) Run Force resolve.
Same on Windows
For me the project runs fine on editor and android but on iOS my build is made but only a black screen is shown. The output of the build is the same as the error you guys are facing. I can provide details if anyone knows how to deal with this kindly help
Uploading Crash Report DllNotFoundException: Unable to load DLL 'FirebaseCppApp-11_3_0'. Tried the load the following dynamic libraries: Unable to load dynamic library '/FirebaseCppApp-11_3_0' because of 'Failed to open the requested dynamic library (0x06000000) dlerror() = dlopen(/FirebaseCppApp-11_3_0, 0x0005): tried: '/FirebaseCppApp-11_3_0' (no such file), '/private/preboot/Cryptexes/OS/FirebaseCppApp-11_3_0' (no such file), '/FirebaseCppApp-11_3_0' (no such file) at Firebase.AppUtilPINVOKE+SWIGExceptionHelper.SWIGRegisterExceptionCallbacks_AppUtil (Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate applicationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate arithmeticDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate divideByZeroDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate indexOutOfRangeDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidCastDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidOperationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate ioDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate nullReferenceDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate outOfMemoryDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate overflowDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate systemExceptionDelegate) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtilPINVOKE+SWIGExceptionHelper..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtilPINVOKE..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtil.SetLogFunction (Firebase.LogUtil+LogMessageDelegate arg0) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.LogUtil..ctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.LogUtil..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.FirebaseApp..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Messaging.FirebaseMessaging+Listener..ctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Messaging.FirebaseMessaging+Listener.Create () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Messaging.FirebaseMessaging..cctor () [0x00000] in <00000000000000000000000000000000>:0 at FirebaseMessaging.OnEnable () [0x00000] in <00000000000000000000000000000000>:0 Rethrow as TypeInitializationException: The type initializer for 'Firebase.AppUtilPINVOKE.SWIGExceptionHelper' threw an exception. at Firebase.AppUtilPINVOKE..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.AppUtil.SetLogFunction (Firebase.LogUtil+LogMessageDelegate arg0) [0x00000] in <00000000000000000000000000000000>:0 at Firebase.LogUtil..ctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.LogUtil..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.FirebaseApp..cctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Messaging.FirebaseMessaging+Listener..ctor () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Messaging.FirebaseMessaging+Listener.Create () [0x00000] in <00000000000000000000000000000000>:0 at Firebase.Messaging.FirebaseMessaging..cctor () [0x00000] in <00000000000000000000000000000000>:0 at FirebaseMessaging.OnEnable () [0x00000] in <00000000000000000000000000000000>:0
In Windows, I ran into this issue as well. I tried to open the bundle with VS-Code as did on a mac, but the issue still persisted. My colleague also uses Windows, but he doesn't have this problem.
I got the same error on 11.5.0 version and I've upgraded to 11.6.0. Then I got the system warning "Cannot open 'FirebaseCppApp-11_6_0.bundle'; the application is from an unidentified developer." and this tutorial was the solution: https://www.youtube.com/watch?v=0AyHEyGx1-g
I have found a solution. Follow these steps -
не помогло
FirebaseCppApp 11 uses function getTimeZone in icu.dll (according Dependency Walker), that is missing on OS prior windows10. Copying icu.dll into folder with FirebaseCppApp-11.#.#.dll resolved the problem
FYI, I got the same issue on BigSur OS. The bug was gone after I updated the OS to Sonoma version 14.1.2
I used Windows and solved it with this.
https://github.com/firebase/firebase-unity-sdk/issues/443#issuecomment-1231976123
In my case (MacOS, running in Editor), reinstalling then going to System Settings->Privacy & Security and allowing the dll, and then clicking "Open" next time I ran it fixed the issue.
For Windows 10 64 bit download icu.dll 64 bit form dll-files.com. copy it to C:\Windows\System32 and C:\Windows\SysWOW64 throught PowerShell (copy command). in PowerShell go to C:\Windows\System32 and run "regsvr32 icu.dll". check result in app Dependencies v.1.11.1.0 (open DLL)
[READ] For Firebase Unity SDK issues, please report to Firebase Unity open-source
Once you've read this section and determined that your issue is appropriate for this repository, please delete this section.
[REQUIRED] Please fill in the following fields:
[REQUIRED] Please describe the issue here:
(Please list the full steps to reproduce the issue. Include device logs, Unity logs, and stack traces if available.)
I get this error when I call any firebase functions in a project.
DllNotFoundException: FirebaseCppApp-11_2_0 assembly: type: member:(null)
Firebase.AppUtilPINVOKE+SWIGExceptionHelper..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/android_unity/armeabi-v7a/app/swig/Firebase.App_fixed.cs:4087)
Rethrow as TypeInitializationException: The type initializer for 'SWIGExceptionHelper' threw an exception.
Firebase.AppUtilPINVOKE..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/android_unity/armeabi-v7a/app/swig/Firebase.App_fixed.cs:4107)
Rethrow as TypeInitializationException: The type initializer for 'Firebase.AppUtilPINVOKE' threw an exception.
Firebase.AppUtil.SetLogFunction (Firebase.LogUtil+LogMessageDelegate arg0) (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/android_unity/armeabi-v7a/app/swig/Firebase.App_fixed.cs:4817)
Firebase.LogUtil..ctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/app/src/LogUtil.cs:81)
Firebase.LogUtil..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/app/src/LogUtil.cs:37)
Rethrow as TypeInitializationException: The type initializer for 'Firebase.LogUtil' threw an exception.
Firebase.FirebaseApp..cctor () (at /Users/runner/work/firebase-unity-sdk/firebase-unity-sdk/android_unity/armeabi-v7a/app/swig/Firebase.App_fixed.cs:2014)
Rethrow as TypeInitializationException: The type initializer for 'Firebase.FirebaseApp' threw an exception.
Firebase.Sample.Auth.UIHandler.Start () (at Assets/Firebase/Sample/Auth/UIHandler.cs:80)
Steps to reproduce:
Have you been able to reproduce this issue with just the Firebase Unity quickstarts (this GitHub project)? What's the issue repro rate? (eg 100%, 1/5 etc) 100%
What happened? How can we make the problem occur? This could be a description, log/console output, etc.
If you have a downloadable sample project that reproduces the bug you're reporting, you will likely receive a faster response on your issue.
Relevant Code:
https://github.com/firebase/quickstart-unity/issues/1130 It seems that the compatibility of the Unity-SDK package cannot be maintained. In a Windows environment, it works fine.