Error while upgrading to 1.0.0-stable verison

66 views
Skip to first unread message
Assigned to scot...@google.com by eri...@google.com

LINGA venkatesh

unread,
Jun 23, 2021, 5:11:12 AM6/23/21
to Android CameraX Discussion Group
Hi All,

I am trying to upgrade CameraX version from 1.0.0-rc-04 to 1.0.0-stable and observed below error throughout our repo.

Class 'kotlin.Unit' was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.5.1, expected version is 1.1.15.
The class is loaded from /Users/runner/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.5.10/da6a904b132f0402fa4d79169a3c1770598d4702/kotlin-stdlib-1.5.10.jar!/kotlin/Unit.class

I have made only CameraX version change. 

@CameraX team:
Is there a kotlin version upgrade needed? We are at 1.3.41.

Regards,
Venkatesh.

Scott Nien

unread,
Jun 23, 2021, 11:50:40 AM6/23/21
to LINGA venkatesh, Android CameraX Discussion Group
CameraX libraries (camera-core, camera-camera2, camera-lifecycle, camera-view) have no kotlin related dependencies.  We only have kotlin dependencies in the tests which are not included in the artifacts apps are using. 

But I am not an expert on this , maybe I missed something,  I will investigate more on this issue. 

By the way, can you try changing it back to 1.0.0-rc04 again to see if the issue disappears?  

--
You received this message because you are subscribed to the Google Groups "Android CameraX Discussion Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to camerax-develop...@android.com.
To view this discussion on the web visit https://groups.google.com/a/android.com/d/msgid/camerax-developers/19a58e28-f406-4517-a2b3-93411336fc06n%40android.com.

Scott Nien

unread,
Jun 27, 2021, 11:17:17 PM6/27/21
to LINGA venkatesh, Android CameraX Discussion Group
HI LINGA, 

This might be something wrong in the kotlin plugin.   and there is some suggested solution in https://github.com/flutter/flutter/issues/83834.
It looks like changes ext.kotlin_version = "1.5.10" in build.gradle will fix the issue.   

Scott

LINGA venkatesh

unread,
Jul 1, 2021, 8:15:24 AM7/1/21
to Android CameraX Discussion Group, Scott Nien, Android CameraX Discussion Group, LINGA venkatesh
By the way, can you try changing it back to 1.0.0-rc04 again to see if the issue disappears?  
Yes, the issue is from the "1.0.0-rc-05" upgrade.

Thanks after upgrading the Kotlin version to 1.5.0 we are unblocked.

Regards,
Venkatesh.
Reply all
Reply to author
Forward
0 new messages