3

I have searched and tried many solutions from stackoverflow, but i guess am having a different kind of problem. I have used branch io and sugar orm in my app.

I needed the RECEIVE_SMS & READ_SMS to implement two step authentication and got some map related activity.

Having just uploaded my app to the Play store I get: Supported devices 0 . The app is activated and here is my manifest:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.demo.dlm">

<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="26" />

<uses-permission android:name="android.permission.INTERNET" android:required="true" />
<uses-permission android:name="android.permission.ACCESS_GPS" android:required="true" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" android:required="true" />
<uses-permission android:name="android.permisssion.ACCESS_COARSE_LOCATION" android:required="true" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" android:required="true" />
<uses-permission android:name="android.permission.RECEIVE_SMS" android:required="false" />
<uses-permission android:name="android.permission.READ_SMS" android:required="false" />

<meta-data android:name="DATABASE" android:value="clm.db" />
<meta-data android:name="VERSION" android:value="1" />
<meta-data android:name="QUERY_LOG" android:value="true" />
<meta-data android:name="DOMAIN_PACKAGE_NAME" android:value="com.selise.clm.common.database.entity" />

<application
    android:name=".common.App"
    android:allowBackup="false"
    android:fullBackupContent="@xml/my_backup_rules"
    android:fullBackupOnly="true"
    android:icon="@mipmap/ic_launcher"
    android:label="@string/app_name"
    android:roundIcon="@mipmap/ic_launcher_round"
    android:hardwareAccelerated="true"
    android:supportsRtl="true"
    android:theme="@style/AppTheme">
    <activity
        android:name=".common.ui.activity.SplashScreenActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
        <intent-filter>
            <data android:scheme="clmdebug" android:host="open" />
            <action android:name="android.intent.action.VIEW" />
            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
        </intent-filter>
    </activity>
    <activity
        android:name=".login.ui.activity.LoginActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar">

        <!-- Branch URI scheme -->
        <intent-filter>
            <data
                android:host="open"
                android:scheme="clm" />

            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
        </intent-filter>
    </activity>

    <meta-data android:name="io.branch.sdk.BranchKey" android:value="key_live_jjuGmW0h4nBkf309aOCBbpikstjXj60T" />
    <meta-data android:name="io.branch.sdk.BranchKey.test" android:value="key_live_eetMk3Wl9w5Jo7kd3s3rPifnrzlZ8fp0" />

    <activity
        android:name=".login.ui.activity.RegistrationActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />
    <activity
        android:name=".shipment.ui.activity.ShipmentListActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />
    <activity
        android:name=".notification.ui.activity.NotificationListActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />
    <activity
        android:name=".notification.ui.activity.NotificationDetailsActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />
    <activity
        android:name=".shipment.ui.activity.AddShipmentActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />
    <activity
        android:name=".shipment.ui.activity.ShipmentDetailsActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />

    <meta-data
        android:name="com.google.android.geo.API_KEY"
        android:value="@string/google_maps_key" />

    <service
        android:name=".shipmentMap.service.GeofenceTransitionsIntentService"
        android:enabled="true" />
    <service android:name=".common.service.AccessTokenWithRefreshTokenService" />
    <service android:name=".common.service.LoadLastNotificationService" />
    <service
        android:name=".notification.service.NotificationSignalRService"
        android:enabled="true" />
    <service android:name=".shipmentMap.currentLocation.service.SendCurrentLocationService" />

    <activity
        android:name=".shipmentMap.ui.activity.MapsActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar" />

    <receiver android:name=".common.receiver.NotificationReceiver">
        <intent-filter>
            <action android:name="com.selise.clm.SHIPMENT_CHANGED_ROUTE" />
            <action android:name="com.selise.clm.SHIPMENT_FORWARD" />
            <action android:name="com.selise.clm.SHIPMENT_COMPLETE" />
            <action android:name="com.selise.clm.SHIPMENT_CANCELLED" />
            <action android:name="com.selise.clm.NOTIFICATION_SERVER_CONNECTED" />
            <action android:name="com.selise.clm.NOTIFICATION_SERVER_DISCONNECTED" />
        </intent-filter>
    </receiver>

    <receiver android:name=".common.receiver.AccessTokenAlarmReceiver" android:exported="true"/>

    <meta-data android:name="io.fabric.ApiKey" android:value="e7fe0e53b07c82fb5f682d0dddfc8aea6171cda8" />

    <!-- Branch init -->
    <meta-data
        android:name="io.branch.sdk.BranchKey"
        android:value="key_live_jjuGmW0h4nBkf309aOCBbpikstjXj60T" />
    <meta-data android:name="io.branch.sdk.BranchKey.test" android:value="key_live_eetMk3Wl9w5Jo7kd3s3rPifnrzlZ8fp0" />
    <!-- Branch testing (TestMode "true" to simulate fresh installs on dev environment) -->
    <meta-data android:name="io.branch.sdk.TestMode" android:value="false" />

    <receiver
        android:name="io.branch.referral.InstallListener"
        android:exported="true">
        <intent-filter>
            <action android:name="com.android.vending.INSTALL_REFERRER" />
        </intent-filter>
    </receiver>
    <receiver android:name=".login.receiver.SmsReceiver">
        <intent-filter>
            <action android:name="android.provider.Telephony.SMS_RECEIVED" />
        </intent-filter>
    </receiver>

    <activity android:name=".login.ui.activity.EnterSecurityCodeActivity"
        android:screenOrientation="portrait"
        android:theme="@style/AppTheme.NoActionBar"></activity>
</application>

Anik Dey
  • 616
  • 8
  • 17

2 Answers2

0

Try to fix a typo here:

<uses-permission android:name="android.permisssion.ACCESS_COARSE_LOCATION" android:required="true" />

You have a permisssion (with 3 s, should be permission instead of permisssion).

Vasily Kabunov
  • 6,511
  • 13
  • 49
  • 53
  • Sorry, I am not getting you. Can you please explain what do you mean by "should be ss" ? – Anik Dey Jan 07 '18 at 08:38
  • Tro to replace `permisssion` to `permission` – Vasily Kabunov Jan 07 '18 at 08:40
  • I have changed permisssion to permission and created an apk and uploaded but still Supported devices : 0. Thanks for your help. @red 39 mins ago Vasily Kabunov – Anik Dey Jan 07 '18 at 08:57
  • I would suggest to remove `READ_GSERVICES`, because it's not needed anymore https://stackoverflow.com/questions/24618806/is-read-gservices-permission-still-required-for-google-maps – Vasily Kabunov Jan 07 '18 at 09:05
  • In general, you can try to remove all the permissions and add it one by one, creating the new apk each time, to find what permission causes an issue. This might be helpful https://stackoverflow.com/questions/14020237/android-app-is-supported-by-0-devices – Vasily Kabunov Jan 07 '18 at 09:06
  • I finally found the problem. I used SignalIR in my project and it was causing the problem. Thanks for your help buddy @ Vasily Kabunov – Anik Dey Jan 08 '18 at 05:23
0

As i was using SignalIR in my project. I also added the required jar files. The problem was solved. But double check that after adding packagingOptions your notifications works fine.

I added the following lines in the app gradle file like this...

android {
   packagingOptions {
        exclude 'lib/getLibs.ps1'
        exclude 'lib/getLibs.sh'
        exclude 'lib/gson-2.2.2.jar'
   }
}
Anik Dey
  • 616
  • 8
  • 17