checkout / frames-android

Frames Android: making native card payments simple
https://www.checkout.com/docs/integrate/sdks/android-sdk
MIT License
47 stars 32 forks source link

The compose version difference caused me to be unable to use the sdk #208

Closed powerzd closed 8 months ago

powerzd commented 1 year ago

Describe the bug I also use compose in my project, and version is "def composeBom = platform('androidx.compose:compose-bom:2023.05.01') implementation composeBom", when i try to use credit card to pay, app crash, crash info: Crash Throwable: java.lang.NoSuchMethodError: No virtual method outlinedTextFieldColors-l59Burw(JJJJJLandroidx/compose/foundation/text/selection/TextSelectionColors;JJJJJJJJJJJJJJJJJJJJJJLandroidx/compose/runtime/Composer;IIII)Landroidx/compose/material3/TextFieldColors; in class Landroidx/compose/material3/TextFieldDefaults; or its super classes (declaration of 'androidx.compose.material3.TextFieldDefaults' appears in /data/app/~~Kyb7KI5B4BDjDVzfWynHqA==/com.vivosun.android-06f3BGiqymsZaqxqqYJ7kQ==/base.apk). Please tell me how to fix it. I want to use latest version of compose and i also want to use your sdk. Thanks.

To Reproduce

  1. Create a demo and import latest compose version.
  2. import your sdk
  3. When try to pay, crash will occur

Expected behavior I want to use latest version of compose and i also want to use your sdk.

Screenshots

image

Smartphone (please complete the following information): Any device

praveenathuru commented 1 year ago

Downgrade material3 lib like this. implementation 'androidx.compose.material3:material3:1.0.1'

Latest sdk 4.0.2 doesn't work with 'androidx.compose.material3:material3:1.1.0'.

powerzd commented 1 year ago

Downgrade material3 lib like this. implementation 'androidx.compose.material3:material3:1.0.1'

Latest sdk 4.0.2 doesn't work with 'androidx.compose.material3:material3:1.1.0'.

When would you update to work with androidx.compose.material3:material3:1.1.0

parveensharmayml commented 1 year ago

Downgrade material3 lib like this. implementation 'androidx.compose.material3:material3:1.0.1' Latest sdk 4.0.2 doesn't work with 'androidx.compose.material3:material3:1.1.0'.

When would you update to work with androidx.compose.material3:material3:1.1.0

Until they provide a fix for that.

patrick-hoban-cko commented 1 year ago

Hi @powerzd and @parveensharmayml, thank you for raising this issue.

Compose v1.1.0 is a recent release (being only released last month in May) and we therefore need to assess the broader impact of using the newer version on our SDKs. This is an improvement we do want to make, but it takes time to make sure we get it right.

The workaround for now, as you've mentioned, is to use Compose v1.0.1 which is the version our SDKs are compatible with.

Once I have more info regarding timelines for updating our SDKs to use Compose v1.1.0, I will update you here.

Best,

Patrick

mouness2020 commented 11 months ago

Any new news or fix for this crash?

patrick-hoban-cko commented 11 months ago

Hi @mouness2020 thanks for reaching out. We don't have a hard timeline right now for updating compose version, we still recommend the workaround of using v1.0.1.

Thanks,

Patrick

patrick-hoban-cko commented 8 months ago

Hi @powerzd, @praveenathuru, @mouness2020, and @nunofvalente, we have now made release 4.2.0 of the SDK which includes some major upgrades for key dependencies. Hopefully this resolves the Compose version issue for you!