Deployed Flutter application to Google Play Store but it's stuck at the splash screen
Asked Answered
S

5

7

Deployed Flutter application to Google Play Store but it's stuck at the splash screen and never open I did match my AppID and still facing the same issue

Here is my manifest.xml:

<!-- TODO: Changed by Parveen Before merge 1 -->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.mrbox.store">

    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <!--
    io.flutter.app.FlutterApplication is an android.app.Application that
    calls FlutterMain.startInitialization(this); in its onCreate method.
    In most cases you can leave this as-is, but you if you want to provide
    additional functionality it is fine to subclass or reimplement
    FlutterApplication and put your custom class here.
    -->
    <!-- TODO: Add By Parveen before merge 1 -->
    <application
        android:name="io.flutter.app.FlutterApplication"
        android:label="Mr.Box Store"
        android:usesCleartextTraffic="true"
        android:icon="@mipmap/launcher_icon">
        <activity
            android:name=".MainActivity"
            android:launchMode="singleTop"
            android:theme="@style/LaunchTheme"
            android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
            android:hardwareAccelerated="true"
            android:windowSoftInputMode="adjustResize">
            <!--
            Specifies an Android theme to apply to this Activity as soon as
            the Android process has started. This theme is visible to the user
            while the Flutter UI initializes. After that, this theme continues
            to determine the Window background behind the Flutter UI.
            -->
            <meta-data
                android:name="io.flutter.embedding.android.NormalTheme"
                android:resource="@style/NormalTheme"
                />
            <!--
            Displays an Android View that continues showing the launch screen
            Drawable until Flutter paints its first frame, then this splash
            screen fades out. A splash screen is useful to avoid any visual
            gap between the end of Android's launch screen and the painting of
            Flutter's first frame.
            -->
            <meta-data
                android:name="io.flutter.embedding.android.SplashScreenDrawable"
                android:resource="@drawable/launch_background"
                />
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
            <intent-filter>
                <action android:name="FLUTTER_NOTIFICATION_CLICK" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
            <!--
            TODO: Changed by parveen before merge 1
            android:name="default-url"
            android:value="https://inspireui.com"
            -->
            <meta-data
                android:name="default-url"
                android:value="https://www.mrboxstore.com" />
            <intent-filter android:autoVerify="true">
                <action android:name="android.intent.action.VIEW" />

                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />
                <!-- TODO: Changed by parveen before merge 1 android:value="inspireui.com" -->
                <data android:scheme="https"
                    android:host="mrboxstore.com" />
                <data android:scheme="http" />
            </intent-filter>
        </activity>
        <meta-data
            android:name="com.google.firebase.messaging.default_notification_icon"
            android:resource="@drawable/logo" />
        <!--
        Set color used with incoming notification messages. This is used when no color is set for the incoming
        notification message. 
        -->
        <meta-data
            android:name="com.google.firebase.messaging.default_notification_color"
            android:resource="@color/notiColor" />
        <!-- Google map and Admod setup -->
        <meta-data
            android:name="com.google.android.geo.API_KEY"
            android:value="@string/api_key" />
        <meta-data
            android:name="com.google.android.gms.ads.APPLICATION_ID"
            android:value="@string/admob_api" />
        <!-- Facebook Login configuration -->
        <meta-data
            android:name="com.facebook.sdk.ApplicationId"
            android:value="@string/facebook_app_id" />
        <activity
            android:name="com.facebook.FacebookActivity"
            android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
            android:label="@string/app_name"
            android:exported="true" />
        <activity
            android:name="com.facebook.CustomTabActivity"
            android:exported="true">
            <intent-filter>
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />
                <data android:scheme="@string/fb_login_protocol_scheme" />
            </intent-filter>
        </activity>
        <!--
        Don't delete the meta-data below.
        This is used by the Flutter tool to generate GeneratedPluginRegistrant.java
        -->
        <meta-data android:name="flutterEmbedding"
            android:value="2" />
    </application>
</manifest>
Subsolar answered 21/2, 2021 at 5:34 Comment(16)
You are tested app in release mode before publish it in Google Play?Ieper
I did and it was working perfectlySubsolar
Can you share the manifest?Nivernais
Did you check it?Subsolar
Anyone can help?Subsolar
Checked it, it looks ok.Nivernais
So why it's like that I need it to be solved badlySubsolar
Without error log it could be anything.Nivernais
But there is no such an errorSubsolar
Anyone faced this issue before? Please guide meSubsolar
Just checking, does flutter doctor -v return without ANY hick-ups?Conrado
How did you modify the build.gradle file? And did you do a flutter clean after doing so, before the signing?Conrado
Did you build an App Bundle or an APK package?Conrado
I had a similar error where my app used to crash without any error only when uploaded on PlayStore. Can you share both of your gradle files? I fixed my problems by changing a few things over there.Priestly
Have you tried running your application on production mode in IDE?Snakebird
@mohammedfahmy Did you solve this? I see that I've been given the bounty, but no update about what (if any) of the steps provided helped you get past the hurdle.Conrado
C
2

Things to try

  1. Make sure flutter doctor -v runs without ANY complaints
  2. Edit android/gradle.properties and add the flag: android.bundle.enableUncompressedNativeLibs=false
  3. Do a flutter clean command
  4. Try creating a release build using flutter build appbundle

Test Locally / Offline

  1. download bundletool
  2. Generate a set of APKs from your app bundle, following this guide
  3. Deploy the app to your connected device(s) following this Guide

Works?

  1. Upload your bundle to Google Play using the internal test track, or the alpha or beta channels to test the bundle before releasing it in production Instructions for doing this can be found here

  2. Good Luck :)

Conrado answered 24/2, 2021 at 8:2 Comment(0)
M
2

Assuming that you publish an App Bundle (.aab file) the issue can be related to the format itself since it is not testable via IDE. E.g. when running the app in Release mode on a device .apk is created and provisioned to it, not .aab.

What I did in the past to troubleshoot .aab (also had failures only with GPlay version, local Debug and Release modes worked fine) was to use Firebase Test Lab. You can run automated monkey tests on 5 physical devices and 15 virtual devices every day free-of-charge. Just log in to Firebase Console, cretae an empty project, go to Test, upload your .aab file, select devices (it's worth also to choose different locales) and wait for completion. After that check logs in test results, you might find answers there (in my cases there was an issue with localization resources which got broken while producing .aab release package).

This option can be esier/faster than splitting .aab locally with comand line into APKs and testing on a local device.

Meghanmeghann answered 28/2, 2021 at 22:34 Comment(0)
D
1

Because it is not working after uploading on google play. then there might be some issue with your app signing. You can follow the steps here

Duluth answered 24/2, 2021 at 7:19 Comment(0)
E
1

I have faced issues like this when I used facebook login sdk, so I would suggest checking following:

  1. Check if you have signed the apk/appbundle with proper release keystore

  2. Check if you have opt in for google's automatic signing on playstore while deploying app

    2.1 If yes then it will change the sha-1 value which is used in facebook app for authentication, for it to work use the one generated by google in playstore

Engler answered 28/2, 2021 at 12:40 Comment(0)
S
0

In my experience, try to check your database(sqlite) if created. Try to replace the path and check if the database is created properly.

Surpassing answered 5/6, 2021 at 18:24 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.