Reputation: 45
We have recently uploaded the increased version of application on play store. Whenever we are trying to update application from playstroe, its crashing and throwing ResourceNotFound Exception as given below :
--------- beginning of system
12-25 15:17:26.608 21693-21693/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.ultimatix.grs.application, PID: 21693
android.content.res.Resources$NotFoundException: Drawable com.ultimatix.grs.application:string/availability_united_states_with_asterisk with resource ID #0x7f0600b9
Caused by: android.content.res.Resources$NotFoundException: File <font color=#FF0000>* </font>Available to join TCS on from drawable resource ID #0x7f0600b9
at android.content.res.ResourcesImpl.loadDrawableForCookie(ResourcesImpl.java:729)
at android.content.res.ResourcesImpl.loadDrawable(ResourcesImpl.java:575)
at android.content.res.Resources.getDrawable(Resources.java:767)
at android.support.v7.widget.ResourcesWrapper.getDrawable(Unknown Source)
at android.content.Context.getDrawable(Context.java:525)
at android.support.v4.content.ContextCompatApi21.getDrawable(Unknown Source)
at android.support.v4.content.ContextCompat.getDrawable(Unknown Source)
at android.support.v7.widget.AppCompatDrawableManager.getDrawable(Unknown Source)
at android.support.v7.widget.AppCompatDrawableManager.getDrawable(Unknown Source)
at android.support.v7.widget.AppCompatImageHelper.setImageResource(Unknown Source)
at android.support.v7.widget.AppCompatImageView.setImageResource(Unknown Source)
at com.tcs.grs.grsnavdrawer.a.a.a(Unknown Source)
at com.tcs.grs.grsnavdrawer.a.a.onBindViewHolder(Unknown Source)
at android.support.v7.widget.RecyclerView$Adapter.onBindViewHolder(Unknown Source)
at android.support.v7.widget.RecyclerView$Adapter.bindViewHolder(Unknown Source)
at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(Unknown Source)
at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(Unknown Source)
at android.support.v7.widget.LinearLayoutManager$LayoutState.next(Unknown Source)
at android.support.v7.widget.LinearLayoutManager.layoutChunk(Unknown Source)
at android.support.v7.widget.LinearLayoutManager.fill(Unknown Source)
at android.support.v7.widget.LinearLayoutManager.onLayoutChildren(Unknown Source)
at android.support.v7.widget.RecyclerView.dispatchLayoutStep2(Unknown Source)
But this resource is available. Secondly, if I am not updating the app instead directly downloading the new version, its working fine.
I banged my head to find out the root cause, didn't get the same. If anyone can suggest, would be really helpful. Note: This is unused resource in the project.
Here is @string.xml
<string name="personal_detail_age_with_asterisk"><![CDATA[<font color=#FF0000>* </font><font color=#bdbdbe>Age</font>]]></string>
<string name="date_label_with_asterisk"><![CDATA[<font color=#FF0000>* </font><font color=#bdbdbe>Date</font>]]></string>
<string name="availability_united_states">Available to join TCS on</string>
<string name="availability_united_states_with_asterisk"><![CDATA[<font color=#FF0000>* </font>Available to join TCS on]]></string>
<string name="availability_united_states_disabled"><![CDATA[<font color=#FF0000>* </font><font color=#bdbdbe>Available to join TCS on</font>]]></string>
<string name="under_age_label_united_states">If you are under the age of 18 years, can you provide a work permit ?</string>
<string name="under_age_label_united_states_with_asterisk"><![CDATA[<font color=#FF0000>* </font>If you are under the age of 18 years, can you provide a work permit ?]]></string>
<string name="authorized_to_work_united_states">If an offer of employment is extended to you, will you be able to demonstrate that you are authorized to work in the U.S ?</string>
<string name="authorized_to_work_united_states_with_asterisk"><![CDATA[<font color=#FF0000>* </font>If an offer of employment is extended to you, will you be able to demonstrate that you are authorized to work in the U.S ?]]></string>
<string name="military_training_usa">List any military training or experience that you feel relevant to the position you are applying to</string>
Please find required gradle's lines
minSdkVersion 17
targetSdkVersion 23
versionCode 3
versionName "1.2"
multiDexEnabled = true
}
repositories {
maven { url 'http://repo1.maven.org/maven2' }
}
buildTypes {
release {
minifyEnabled true
debuggable false
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.config
}
debug {
minifyEnabled false
debuggable true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.config1
}
}
Upvotes: 3
Views: 158
Reputation: 13842
This sounds extremely strange. Can you check that the APKs you get by updating and by installing the new version fresh are the same?
You can pull the APK off the device as described in this stackoverflow answer.
If the two APKs are the same, then this is really weird. If the two APKs are different that suggests there is a bug in the Google Play store, and you should contact Google Play Developer support via the Google Play console. They will take this very seriously and escalate to the appropriate people.
Upvotes: 2