xr-codelabs icon indicating copy to clipboard operation
xr-codelabs copied to clipboard

NoSuchMethodError on part1

Open pChaAnthony opened this issue 1 year ago • 2 comments

Got a error after part 1 build without changes when running: java.lang.NoSuchMethodError: No virtual method createSystemRendererConnection(Landroid/app/Activity;Ljava/util/concurrent/Executor;)Lcom/android/extensions/xr/splitengine/SystemRendererConnection; in class Lcom/android/extensions/xr/XrExtensions; or its super classes (declaration of 'com.android.extensions.xr.XrExtensions' appears in /system_ext/framework/com.android.extensions.xr.jar)

Android Studio Narwhal 3 Feature Drop | 2025.1.3 Build #AI-251.26094.121.2513.14007798, built on August 28, 2025 Runtime version: 21.0.7+-13880790-b1038.58 aarch64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o. Toolkit: sun.lwawt.macosx.LWCToolkit macOS 15.6.1 Kotlin plugin: K2 mode GC: G1 Young Generation, G1 Concurrent GC, G1 Old Generation Memory: 2048M Cores: 10 Metal Rendering is ON Registry: ide.experimental.ui=true

pChaAnthony avatar Sep 11 '25 10:09 pChaAnthony

Thanks for reaching out with this issue! When you see a NoSuchMethodError, it's typically an indication that the version of the Jetpack XR libraries isn't aligned with the version of the system image on the emulator or device your app is running on.

Please update to the latest version of Android Studio (I believe it's Narwhal 4 Feature Drop | 2025.1.4 Canary 5 at the moment), and check in the SDK manager under the SDK Tools tab to ensure you're updated to the latest version of the XR emulator.

fuentespatrick avatar Sep 11 '25 22:09 fuentespatrick

it works, thank you very much.

pChaAnthony avatar Sep 12 '25 05:09 pChaAnthony