iZettle / sdk-android

Add card payments from Zettle to your own app
https://developer.zettle.com/docs/android-sdk
24 stars 20 forks source link

Ressources cannot be bundled with latest version of aapt #34

Closed fntc closed 2 years ago

fntc commented 3 years ago

Consuming SDK in Xamarin by creating Binding Wrappers. When using those Binding Libraries Ressources are bundled at apk level using a new version of aapt. The build fails because one ressource string (refunds_amount_description) uses multiple placeholders that are not numbered.

Old versions of aapt write only a warning into the log like that (all languages): _.....gradle\caches\transforms-2\files-2.1\259216afb29571d06e4d1303dd438c77\jetified-android-sdk-ui-1.14.15\res\values\values.xml:806:4: Multiple substitutions specified in non-positional format of string resource string/refunds_amountdescription. Did you mean to add the formatted="false" attribute?

For new versions of aapt this is thrown as an error, meaning the issue will be observed for pure java/kotlin android projects too.

Please fix refunds_amount_description by using something like %1$s and %2$s instead of %@

bobzettle commented 2 years ago

Hi, thank you for your feedback and patience!

I've added this to our backlog and the team will look into it.

bobzettle commented 2 years ago

Hi, the refunds_amount_description got updated with SDK version 1.24.0.

If your problem remains, feel free to to reopen the issue again. But until then I will resolve and close it.

Thank you!