Forums

OverviewFelgo Plugins Support › Firebase login causes crash?

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #19663

    Edward

    Hey!

    I am having an issue with my Firebase login, user registration works fine, with no issues at all and writes to the database, when  try to log an existing user it causes a crash on every attempt?

    below is my code for my firebase auth and also login/resiter button! does anyone know what could be causing this?

    Thanks

            onUserRegistered: {
    
                indicator.stopAnimating()
    
                console.debug("User login " + success + " - " + message)
    
                if(success) {
                    loginDialog.title = "Success!"
                    firebaseDb.setUserValue("Firstname", firstname.text)
                    firebaseDb.setUserValue("Surname", surname.text)
                } else {
                    loginDialog.title = "An Issue occured!"
                }
                loginDialog.text = message
                loginbutton.visible = true
                registerCheckbox.visible = true
                loginDialog.open()
            }
    
            onLoggedIn:  {
                indicator.stopAnimating()
    
                console.debug("User login " + success + " - " + message)
    
                if(success) {
                    loginDialog.title = "Success!"
                    firebaseDb.getUserValue("Firstname")
                } else {
                    loginDialog.title = "An Issue occured!"
                }
                loginDialog.text = message
                loginbutton.visible = true
                registerCheckbox.visible = true
                loginDialog.open()
            }

     

     

     

     AppButton {
                            id: loginbutton
                            text: registerCheckbox.checked ? "Register" : "Login"
                            flat: false
                            anchors.horizontalCenter: parent.horizontalCenter
                            onClicked: {
                                loginPage.forceActiveFocus()
                                loginbutton.visible = false
                                registerCheckbox.visible = false
                                indicator.visible = true;
                                indicator.startAnimating()
    
                                if(registerCheckbox.checked) {
                                    firebaseAuth.registerUser(txtUsername.text, txtPassword.text);
                                } else {
                                    firebaseAuth.loginUser(txtUsername.text, txtPassword.text)
                                }
                            }
                        }

     

    #19670

    Günther
    Felgo Team

    Hi Edward,

    On which platforms (iOS and/or Android?) do you run into this issue? And are you using Felgo Live or custom build/deployment?
    Also, is there any error you get in your application output?

    Best,
    Günther

    #19671

    Edward

    Hi Gunther,

    I am using Vplayive through android when this happens, no error is logged, i click the loggin button and it hangs then force closes?

     

    Thanks

    Edd

    #19676

    Günther
    Felgo Team

    Thanks Edward,

    As it’s possible this issue only affects Felgo Live, can you also test building the app with Felgo for Android yourself?
    You can find more information about android deployment here: https://felgo.com/doc/vplay-deployment-android/

    In case the crash persists, please send a minimum example project to reproduce the issue to support@felgo.com.

    Let me know if it only affects Felgo Live – I’ll file a bug report then.

    Best,
    Günther

    #19677

    Edward

    I will do this and let you know hopefully later today, will i still be able to build my app with forebase as a trial as i am unable to upgrade my account just yet

     

    Thanks

    Edd

    #19684

    Edward

    Hi Gunther,

    When building my app I receive the following issues, what would you suggest?

    18:00:31: Running steps for project MyDiary…

    18:00:31: Configuration unchanged, skipping qmake step.

    18:00:31: Starting: “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe”

    mingw32-make: Nothing to be done for ‘first’.

    18:00:32: The process “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe” exited normally.

    18:00:32: Removing directory C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build/assets

    18:00:33: Removing directory C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build/libs

    18:00:33: Starting: “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe” “INSTALL_ROOT=C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build” install

    C:\FelgoSDK\Felgo\android_armv7\bin\qmake.exe -install qinstall C:\Users\Edward\Documents\MyDiary\qml C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build\assets\qml

    C:\FelgoSDK\Felgo\android_armv7\bin\qmake.exe -install qinstall C:\Users\Edward\Documents\MyDiary\assets C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build\assets\assets

    C:\FelgoSDK\Felgo\android_armv7\bin\qmake.exe -install qinstall -exe libMyDiary.so C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build\libs\armeabi-v7a\libMyDiary.so

    18:00:36: The process “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe” exited normally.

    18:00:36: Starting: “C:\FelgoSDK\Felgo\android_armv7\bin\androiddeployqt.exe” –input C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-libMyDiary.so-deployment-settings.json –output C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-build –deployment bundled –android-platform android-28 –jdk “C:/Program Files (x86)/Java/jdk1.8.0_181” –gradle

    Generating Android Package

    Input file: C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-libMyDiary.so-deployment-settings.json

    Output directory: C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-build/

    Application binary: C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/libMyDiary.so

    Android build platform: android-28

    Install to device: No

    NDK is missing a “platforms” directory.

    If you are using NDK, verify the ndk.dir is set to a valid NDK directory. It is currently set to C:\Development\Android-SDK\ndk-bundle.

    If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.

    FAILURE: Build failed with an exception.

    * What went wrong:

    A problem occurred configuring root project ‘android-build’.

    > Could not resolve all dependencies for configuration ‘:_debugApkCopy’.

    > Could not find com.google.firebase:firebase-core:17.0.1.

    Required by:

    project :

    > Could not find com.google.firebase:firebase-core:17.0.1.

    Required by:

    project : > net.vplay.plugins:plugin-firebase:2.17.1-1

    * Try:

    Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output.

    BUILD FAILED

    Total time: 10.634 secs

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Extras.Private.CppUtils

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Extras.Private.CppUtils

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Material.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Fusion.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Imagine.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Universal.impl

    Building the android package failed!

    — For more information, run this command with –verbose.

    18:01:15: The process “C:\FelgoSDK\Felgo\android_armv7\bin\androiddeployqt.exe” exited with code 14.

    Error while building/deploying project MyDiary (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.10.1 Android armv7 Felgo))

    When executing step “Build Android APK”

    18:01:15: Elapsed time: 00:44.

    #19690

    Günther
    Felgo Team
    #19693

    Edward

    Hi Gunther,

    I have tried the NDK download link in the deployment section of vplay which did not work and also r10e from the link sent,

    when using r10e I had partial success at first but it was unsuccessful, the following occurred:

     

    15:49:53: Running steps for project MyDiary…

    15:49:53: Configuration unchanged, skipping qmake step.

    15:49:53: Starting: “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe”

    mingw32-make: Nothing to be done for ‘first’.

    15:49:55: The process “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe” exited normally.

    15:49:56: Removing directory C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build/assets

    15:49:57: Removing directory C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build/libs

    15:49:57: Starting: “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe” “INSTALL_ROOT=C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build” install

    C:\FelgoSDK\Felgo\android_armv7\bin\qmake.exe -install qinstall C:\Users\Edward\Documents\MyDiary\qml C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build\assets\qml

    C:\FelgoSDK\Felgo\android_armv7\bin\qmake.exe -install qinstall C:\Users\Edward\Documents\MyDiary\assets C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build\assets\assets

    C:\FelgoSDK\Felgo\android_armv7\bin\qmake.exe -install qinstall -exe libMyDiary.so C:\Users\Edward\Documents\build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug\android-build\libs\armeabi-v7a\libMyDiary.so

    15:49:59: The process “C:\FelgoSDK\Tools\mingw530_32\bin\mingw32-make.exe” exited normally.

    15:49:59: Starting: “C:\FelgoSDK\Felgo\android_armv7\bin\androiddeployqt.exe” –input C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-libMyDiary.so-deployment-settings.json –output C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-build –deployment bundled –android-platform android-28 –jdk “C:/Program Files (x86)/Java/jdk1.8.0_181” –gradle

    Generating Android Package

    Input file: C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-libMyDiary.so-deployment-settings.json

    Output directory: C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/android-build/

    Application binary: C:/Users/Edward/Documents/build-MyDiary-Android_for_armeabi_v7a_GCC_4_9_Qt_5_10_1_Android_armv7_V_Play-Debug/libMyDiary.so

    Android build platform: android-28

    Install to device: No

    NDK is missing a “platforms” directory.

    If you are using NDK, verify the ndk.dir is set to a valid NDK directory. It is currently set to C:\Development\Android-SDK\ndk-bundle.

    If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.

    FAILURE: Build failed with an exception.

    * What went wrong:

    A problem occurred configuring root project ‘android-build’.

    > Could not resolve all dependencies for configuration ‘:_debugApkCopy’.

    > Could not find com.google.firebase:firebase-core:17.0.1.

    Required by:

    project :

    > Could not find com.google.firebase:firebase-core:17.0.1.

    Required by:

    project : > net.vplay.plugins:plugin-firebase:2.17.1-1

    * Try:

    Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output.

    BUILD FAILED

    Total time: 22.795 secs

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Extras.Private.CppUtils

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Extras.Private.CppUtils

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Material.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Fusion.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Imagine.impl

    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Universal.impl

    Building the android package failed!

    — For more information, run this command with –verbose.

    15:50:52: The process “C:\FelgoSDK\Felgo\android_armv7\bin\androiddeployqt.exe” exited with code 14.

    Error while building/deploying project MyDiary (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.10.1 Android armv7 Felgo))

    When executing step “Build Android APK”

    15:50:52: Elapsed time: 00:59.

    #19694

    Günther
    Felgo Team

    Hi Edward,

    I just also noticed the following lines:

    > Could not find com.google.firebase:firebase-core:17.0.1.
    
    Required by:
    
    project :
    
    > Could not find com.google.firebase:firebase-core:17.0.1.

    When building for Android, did you also make sure that you performed all plugin integration steps, like adding the Firebase Dependency to your build.gradle?
    The steps are described in the Firebase Docs: https://felgo.com/doc/plugin-firebase/#android-integration-steps

    Best,
    Günther

    #19696

    Edward

    Hi Gunther
    <div dir=”auto”></div>
    <div dir=”auto”>I followed the steps and am able to read/write to my database and also auth users, would this still be possible without the dependencies?</div>
    <div dir=”auto”></div>
    <div dir=”auto”>I will check to confirm also!</div>
    <div dir=”auto”></div>

    #19705

    Günther
    Felgo Team

    Hi Edward,

    the Firebase Plugin builds upon the native Firebase SDK for Android and iOS. It is thus required to add these dependencies in order to use Firebase. The Felgo Live Client app already comes with all plugin dependencies bundled so you can test right away. When building your own app, all plugin dependencies require to be bundled with the app.

    As you the built app works correctly, it seems the login-crash only occurs for Felgo Live – I’ll file a bug report so we can include a fix for one of the next Felgo Live versions.

    Best,
    Günther

     

     

    #19871

    Edward

    Hey!

    I have jusy updated vplay live app on android and just thought id let you know i am able to log in without crashing!!

    Thaaaaanks!!!

Viewing 12 posts - 1 through 12 (of 12 total)

RSS feed for this thread

You must be logged in to reply to this topic.

Voted #1 for:

  • Easiest to learn
  • Most time saving
  • Best support

Develop Cross-Platform Apps and Games 50% Faster!

  • Voted the best supported, most time-saving and easiest to learn cross-platform development tool
  • Based on the Qt framework, with native performance and appearance on all platforms including iOS and Android
  • Offers a variety of plugins to monetize, analyze and engage users
FREE!
create apps
create games
cross platform
native performance
3rd party services
game network
multiplayer
level editor
easiest to learn
biggest time saving
best support