I use apktool 2.4.1 on Linux, today I tried to decompile and recompile whatsapp latest beta from apk mirror, and recompilation fails with manifest error No resource identifier found for attribute 'requestLegacyExternalStorage' in package 'android'
it maybe related to android q.
Relevant information: https://developer.android.com/training/data-storage/files/external-scoped#opt-out-of-scoped-storage
This is related to Android 10.
Looks like new attribute, will investigate.
Any updates?
I fixed the problem by installing android 10 framework-res.apk from my devices.
this is how i did it:
/system/framework-res.apkadb pull /system/framework-res.apk <path_to_your_computer>apktool_2.4.1.jar if <path_to_grabbed_framework>
Most devices has their framework apk path differents, so you can search by your own. and yes this grabbing framework apk requires no root as long as you know the framework apk location, /system/framework itself can be accessed without root so you know research your own!
But though that some framework actually located in root-needed directory.
Here is the framework-res.apk file from Android 10 emulator in case if you want it :)
https://drive.google.com/file/d/1NVYCc-29C39XSoDOTYBjivuSQzAQhD3A/view
remove AndroidManifest android:requestLegacyExternalStorage="true"
This was fixed during https://github.com/iBotPeaches/Apktool/issues/2399