-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Aapt errors when building release apk if using RNPaystack and React Navigation #13
Comments
I had to allow |
Hi @lordkiz, so it's a case of stock RN still shipping with v2.3.* of the Be that as it may, one should still be able to use v3.* of the Gradle plugin (where AAPT2 is enabled by default) and manage to have a working release build. Once I have some time on my hands, I would see if I can reproduce your issues. In the meantime, the downside of dropping down to an older version of the Paystack SDK is inheriting bugs already fixed in the newer versions. Do you care to share your |
I get what you mean. Thanks. Here is my
and
|
Hi @lordkiz this issue is mostly from React Navigation/React Native's implementation. AAPT2 is supposed to be enabled on Android. The old AAPT is deprecated. I found a recent workaround for react native by replacing my node_modules/react_native/react.gradle file with
Courtesy of #17967 from @CFKevinRef (that should really be merged) |
Am still experiencing this error |
@dansmog did you try my fix above? Better yet, what have you tried so far? |
@steveamaza I have tried the fix you mentioned, the one of changing the react.gradle, also the android.enableAapt2=true and also changing it to false, cleared my .gradle cache to, and it isnt working yet. |
@dansmog what's the error you're getting now? Because changing react.gradle worked for me |
If anyone still has issues assembling a release build, update to v3.2.0 of this lib and/or update RN to 0.57.0, if you cannot update RN yet, I added a workaround to the README |
@tolu360 As it stands, it is impossible to generate a release variant if using this react-native-paystack with react navigation.
This is because react-native-paystack requires having to set
android.enableAapt2=true
else you will get these errors:Meanwhile you will get this common error
arising from react navigation
\android\app\build\intermediates\res\merged\release\drawable-hdpi\node_modules_reactnavigation_src_views_assets_backicon.png: error: uncompiled PNG file passed as argument. Must be compiled first into .flat file..
if you haveandroid.enableAapt2=true
in your gradle.properties. (This temporary fix to this is changing toandroid.enableAapt2=false
in gradle.properties)react-native-paystack #9
react-navigation #3097
Any help will be greatly appreciated
The text was updated successfully, but these errors were encountered: