Bug Report
Version
react-native-audio-api 0.12.2
Description
Android build fails with a Kotlin compilation error because AudioAPIModule.kt does not implement the abstract method resolveAndroidReleaseAsset declared in NativeAudioAPIModuleSpec.java.
Error
e: file://.../node_modules/react-native-audio-api/android/src/main/java/com/swmansion/audioapi/AudioAPIModule.kt:27:1
Class 'AudioAPIModule' is not abstract and does not implement abstract base class member 'resolveAndroidReleaseAsset'.
> Task :react-native-audio-api:compileDebugKotlin FAILED
Root Cause
NativeAudioAPIModuleSpec.java (oldarch codegen spec, line 106-108) declares:
@ReactMethod(isBlockingSynchronousMethod = true)
@DoNotStrip
public abstract @Nullable String resolveAndroidReleaseAsset(String assetPath);
But AudioAPIModule.kt in 0.12.2 never overrides this method. The async companion readAndroidReleaseAssetBytesAsBase64 is implemented, but the synchronous resolveAndroidReleaseAsset is missing.
Workaround
Apply a patch via patch-package adding the missing override (consistent with the intent of PR #989):
override fun resolveAndroidReleaseAsset(path: String): String {
return path
}
Steps to Reproduce
- Install
react-native-audio-api@0.12.2
- Run Android build
compileDebugKotlin fails
Expected Behavior
Build succeeds — AudioAPIModule.kt implements all abstract members from its base class.
Bug Report
Version
react-native-audio-api0.12.2Description
Android build fails with a Kotlin compilation error because
AudioAPIModule.ktdoes not implement the abstract methodresolveAndroidReleaseAssetdeclared inNativeAudioAPIModuleSpec.java.Error
Root Cause
NativeAudioAPIModuleSpec.java(oldarch codegen spec, line 106-108) declares:But
AudioAPIModule.ktin 0.12.2 never overrides this method. The async companionreadAndroidReleaseAssetBytesAsBase64is implemented, but the synchronousresolveAndroidReleaseAssetis missing.Workaround
Apply a patch via
patch-packageadding the missing override (consistent with the intent of PR #989):Steps to Reproduce
react-native-audio-api@0.12.2compileDebugKotlinfailsExpected Behavior
Build succeeds —
AudioAPIModule.ktimplements all abstract members from its base class.