I am running into an issue that is confusing me. It seems as if android apps are NOT fully compartmentalized is this the case.
I have a Samsung SIII phone and I am building apps that are used as templates. Basically it is the same app but with different content the content is retrieved from our database at startup.
So my process is to create a single app get it working, then copy it to another package through refactoring and I change the data retrieval calls and I have two apps the internal functioning and coding is basically identical.
What I am seeing is this I start one app and it seems to be working just fine and I can open and close it several times with no issue, then out of the blue I get a pop up that says a certain app has stopped functioning. The issue is I never opened that app I could have opened one of the duplicates but I even forgot I had the app that crashed on the phone let alone starting it.
I routinely shut down all running apps just to make sure things run smoothly and I never see that this mystery app is running anywhere.
The shut down message just simply appears but it is always after running apps that ran the same code but not all the time.
This may be the reason I have seen some other issues but can't tell
the basics of the other issue is two sets of code that are pretty much identical per my process where one works and the other doesn't
I am very confused
Can anyone help clear the smoke?
this may help it is a list of my permissions
uses-permission android:name="com.android.vending.BILLING"
uses-permission android:name="android.permission.INTERNET"
uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"
uses-permission android:name="android.permission.READ_PHONE_STATE"
uses-permission android:name="android.permission.ACCESS_WIFI_STATE"
uses-permission android:name="android.permission.BLUETOOTH"
The content for all of my template apps will be VERY similar except for the package name versions etc.
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.blah.blahblah"
android:versionCode="2"
android:versionName="0.75" >
<uses-sdk
android:minSdkVersion="5"
android:targetSdkVersion="7" />
<!-- VERY IMPORTANT! Don't forget this permission, or in-app billing won't work. -->
<uses-permission android:name="com.android.vending.BILLING" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.BLUETOOTH" />
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" >
<activity
android:name=".IntroActivity"
android:label="#string/title_activity_main"
android:screenOrientation="portrait" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".InfoActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".AudioActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".MovePlayActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".WebActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
</application>
Here is a second one
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.blah2.blah2blah2"
android:versionCode="4"
android:versionName="1.5" >
<uses-sdk
android:minSdkVersion="4"
android:targetSdkVersion="7" />
<!-- VERY IMPORTANT! Don't forget this permission, or in-app billing won't work. -->
<uses-permission android:name="com.android.vending.BILLING" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.BLUETOOTH" />
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" >
<activity
android:name=".IntroActivity"
android:label="#string/title_activity_main"
android:screenOrientation="portrait" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".AudioActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".MovePlayActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
<activity
android:name=".WebActivity"
android:configChanges="orientation|keyboardHidden"
android:screenOrientation="portrait" >
</activity>
</application>
I do see the min SDK version has changed I don't remember doing this right off hand but I must have for some reason
Related
I have an app that is being restarted after being in the background then re-opened from searching application(Searching from all apps on device screenshot attached).
If i open simple from recent apps tab then it will not reopen the application.
I already read App Startup time documentation
But not able to conclude on anything.
My manifest code is
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.test.android">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.GET_TASKS" />
<uses-permission android:name="android.permission.USE_CREDENTIALS" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.USE_FINGERPRINT" />
<application
android:name=".app.test"
android:allowBackup="false"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:largeHeap="false"
android:theme="#style/AppTheme"
tools:replace="android:allowBackup">
<activity
android:name=".activity.StartupActivity_"
android:screenOrientation="portrait"
android:theme="#style/Theme.NoTitleNoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".activity.test"
android:screenOrientation="portrait"
android:theme="#style/Theme.NoTitleNoActionBar" />
<! -- many more activity -->
</application>
</manifest>
If StartupActivity_ activity is that activity you leave it and then open from search!(complicated!) then you must add this line into manifest
android:launchMode="singleTop"
Manifest code
<activity
android:name=".activity.StartupActivity_"
android:screenOrientation="portrait"
android:launchMode="singleTop"
android:theme="#style/Theme.NoTitleNoActionBar">
This is good article to understand situations medium.com
The mobile I am going to talk about is Micromax A63, Android Version 4.2.2
When I was developing my app, I used it as a debug device and it worked fine. All the development is done on the system.
After development, I uploaded the apk to play store and registered as a beta tester. When I see the app in the play store it says "Your device is not compatible with this version"
I have checked the compatible list, interestingly this device is neither in Supported Devices List nor in Unsupported list.
I have the following in my gradle build
minSdkVersion 13
targetSdkVersion 22
The permissions i use in the app are
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
Help me understand what could be the issue.
Complete manifest file is as follows:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.ghr.ubietyapp" >
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<application
android:allowBackup="true"
android:icon="#drawable/genie"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<activity
android:name=".splash"
android:label="#string/title_activity_splash"
android:noHistory="true" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".ProfileActivity"
android:label="#string/title_activity_profile" >
</activity>
<activity
android:name=".LoginActivity"
android:label="#string/title_activity_login" >
</activity>
<activity
android:name=".RegisterActivity"
android:label="#string/title_activity_register"
android:noHistory="true" >
</activity>
<activity
android:name=".OTPActivity"
android:label="#string/title_activity_otp"
android:noHistory="true" >
</activity>
<activity
android:name=".AttendanceActivity"
android:label="#string/title_activity_attendance" >
</activity>
<activity
android:name=".UploadActivity"
android:label="#string/title_activity_upload" >
</activity>
</application>
</manifest>
thanks.
I've done an app and I've tried it on my tablet via USB.
But when I uploaded it to market it didnt show for my pad... :S
I guess the problem is in my manifest...
Here is my manifest:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.thorne.godnattsmamonster"
android:versionCode="2"
android:versionName="1.1" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="19" />
<uses-permission
android:name="android.permission.CAMERA"
android:maxSdkVersion="19" />
<uses-permission
android:name="android.permission.WRITE_EXTERNAL_STORAGE"
android:maxSdkVersion="19" />
<uses-permission
android:name="android.permission.VIBRATE"
android:maxSdkVersion="19" />
<application
android:allowBackup="true"
android:icon="#drawable/ic_launcher"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<activity
android:name="com.thorne.godnattsmamonster.MainActivity"
android:label="#string/app_name"
android:screenOrientation="sensorLandscape">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.thorne.godnattsmamonster.BookInterface"
android:label="#string/title_activity_book_interface"
android:screenOrientation="sensorLandscape" >
</activity>
<activity
android:name="com.thorne.godnattsmamonster.SettingsActivity"
android:label="#string/settings"
android:screenOrientation="sensorLandscape" >
</activity>
<activity
android:name="com.thorne.godnattsmamonster.Peekaboo"
android:label="#string/title_activity_peekaboo"
android:parentActivityName="com.thorne.godnattsmamonster.MainActivity"
android:screenOrientation="sensorLandscape">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="com.thorne.godnattsmamonster.MainActivity" />
</activity>
</application>
</manifest>
What do I need to add?
BR
android:name="android.permission.WRITE_EXTERNAL_STORAGE"
That's your problem there. Some/most tablets don't have external storage. Either use internal storage (in which case you don't need a permission), or try adding android:required="false" to your WRITE_EXTERAL_STORAGE permission. Either way though, you are going to have to go into your code where you are writing to external storage and change it to internal, or handle the case where a tablet doesn't have external storage.
I want to publish my new app in Play Store but see this message in app panel:
This application is only available to devices with these features,
as defined in your application manifest.
Screen layouts: SMALL NORMAL LARGE XLARGE
Required device features
android.hardware.location
android.hardware.location.gps
android.hardware.location.network
android.hardware.screen.portrait
android.hardware.sensor.accelerometer
android.hardware.touchscreen
This application is available to over 0 devices.
Why it said that my app available to over 0 devices? I have tested on my phone and it works. At least one device :)
My Manifest.xml:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="..."
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="7"
android:targetSdkVersion="15" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-feature android:name="android.hardware.sensor.accelerometer" />
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name"
android:theme="#android:style/Theme.Black.NoTitleBar" >
<activity
android:name="MainActivity"
android:configChanges="orientation"
android:label="#string/app_name"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="ListActivity"
android:screenOrientation="portrait">
</activity>
<activity
android:name="SettingsActivity"
android:screenOrientation="portrait">
</activity>
<activity
android:name="HelpActivity"
android:screenOrientation="portrait">
</activity>
<activity
android:name="AboutActivity"
android:screenOrientation="portrait">
</activity>
</application>
</manifest>
This shows up using IE. Go and look in Firefox, and you will have a large # of devices.
I have uploaded the android app in the android app store. The app is not visible from the mobile app store but from my browser it is visible.
The devices I have tried:
GT-S5360 (Samsung) gingerbread
A60 (Micromax) gingerbread
The AndroidManifest.xml code is
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.hyperwebenable.techpanels"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="4" />
<application android:icon="#drawable/sitelogo"
android:label="#string/app_name">
<activity android:name=".MessageList"
android:label="#string/app_name"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category
android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".SecondActivity"
android:theme="#android:style/Theme.NoTitleBar" >
</activity>
<meta-data android:name="com.mobclix.APPLICATION_ID"
android:value=""/>
<activity
android:name="com.mobclix.android.sdk.MobclixBrowserActivity"
android:theme="#android:style/Theme.Translucent.NoTitleBar" />
</application>
<uses-sdk android:minSdkVersion="2" />
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission
android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission
android:name="android.permission.READ_PHONE_STATE">
</uses-permission>
</manifest>
Please let me know what I am doing wrong here.
I'm not sure if this could cause a problem, but your uses-sdk is defined twice (with a different minSdkVersion). Try removing the second one.