Skip to content

Conversation

@KasemJaffer
Copy link
Contributor

This fixes an exception that gets thrown in runtime (for some reason) if you try to call CameraXHelper.createCameraProvider without the optional useCases argument.

FATAL EXCEPTION: main Process: io.livekit.android, PID: 30063 java.lang.NoSuchMethodError: No virtual method createCameraProvider(Landroidx/lifecycle/LifecycleOwner;)Lio/livekit/android/room/track/video/CameraCapturerUtils$CameraProvider; in class Llivekit/org/webrtc/CameraXHelper$Companion; or its super classes

@changeset-bot
Copy link

changeset-bot bot commented Nov 21, 2024

⚠️ No Changeset found

Latest commit: a2d9c99

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@KasemJaffer
Copy link
Contributor Author

@davidliu I'm not sure if i need to create release changeSet for this. It's a patch for a yet to be released version.

@davidliu
Copy link
Contributor

@davidliu I'm not sure if i need to create release changeSet for this. It's a patch for a yet to be released version.

Nah, won't need a changeset for this.

@davidliu
Copy link
Contributor

This fixes an exception that gets thrown in runtime (for some reason) if you try to call CameraXHelper.createCameraProvider without the optional useCases argument.

FATAL EXCEPTION: main Process: io.livekit.android, PID: 30063 java.lang.NoSuchMethodError: No virtual method createCameraProvider(Landroidx/lifecycle/LifecycleOwner;)Lio/livekit/android/room/track/video/CameraCapturerUtils$CameraProvider; in class Llivekit/org/webrtc/CameraXHelper$Companion; or its super classes

Hmm, I'm guessing the original code was linked against the old version, and then the dependency upgraded somewhere else in the tree, changing the method signature in the final product.

@davidliu davidliu merged commit 2237525 into livekit:main Nov 26, 2024
1 check passed
jeankruger pushed a commit to jeankruger/client-sdk-android that referenced this pull request May 1, 2025
… without useCases (livekit#546)

* Fix NoSuchMethodError No virtual method createCameraProvider caused by method kotlin optional argument

* Fix typo in readme

* Use JvmOverloads
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants