Skip to content

Erro build in Expo SDK 52 and MMKV 3.2.0 #792

Open
@danieljuniorce

Description

@danieljuniorce

Hey, I'm trying to build with npx expo run:android I'm getting this specific error from mmkv.

Expo: 52.0.28
react-native-mmkv: 3.2.0
JDK: 17

> Configure project :react-native-mmkv
[react-native-mmkv] Thank you for using react-native-mmkv ❤️
[react-native-mmkv] If you enjoy using react-native-mmkv, please consider sponsoring this project: https://github.com/sponsors/mrousavy

> Configure project :react-native-reanimated
Android gradle plugin: 8.6.0
Gradle: 8.10.2

> Task :app:processDebugMainManifest
/home/danieljuniorce/develop/fluke/whitelabel-app/android/app/src/debug/AndroidManifest.xml:6:5-162 Warning:
        application@android:usesCleartextTraffic was tagged at AndroidManifest.xml:6 to replace other declarations but no other declaration present
/home/danieljuniorce/develop/fluke/whitelabel-app/android/app/src/debug/AndroidManifest.xml Warning:
        provider#expo.modules.filesystem.FileSystemFileProvider@android:authorities was tagged at AndroidManifest.xml:0 to replace other declarations but no other declaration present

> Task :react-native-mmkv:compileDebugJavaWithJavac FAILED
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPlatformContextModule.java:7: error: cannot find symbol
public class MmkvPlatformContextModule extends NativeMmkvPlatformContextSpec {
                                               ^
  symbol: class NativeMmkvPlatformContextSpec
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPlatformContextModule.java:15: error: method does not override or implement a method from a supertype
    @Override
    ^
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPlatformContextModule.java:21: error: method does not override or implement a method from a supertype
    @Override
    ^
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPackage.java:19: error: cannot find symbol
    if (name.equals(MmkvPlatformContextModule.NAME)) {
                                             ^
  symbol:   variable NAME
  location: class MmkvPlatformContextModule
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPackage.java:20: error: incompatible types: MmkvPlatformContextModule cannot be converted to NativeModule
      return new MmkvPlatformContextModule(reactContext);
             ^
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPackage.java:31: error: cannot find symbol
              MmkvPlatformContextModule.NAME,
                                       ^
  symbol:   variable NAME
  location: class MmkvPlatformContextModule
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPackage.java:33: error: cannot find symbol
                      MmkvPlatformContextModule.NAME,
                                               ^
  symbol:   variable NAME
  location: class MmkvPlatformContextModule
/home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPackage.java:34: error: cannot find symbol
                      MmkvPlatformContextModule.NAME,
                                               ^
  symbol:   variable NAME
  location: class MmkvPlatformContextModule
Note: /home/danieljuniorce/develop/fluke/whitelabel-app/node_modules/react-native-mmkv/android/src/main/java/com/mrousavy/mmkv/MmkvPackage.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
8 errors

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':react-native-mmkv:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

* Try:
> Run with --info option to get more log output.
> Run with --scan to get full insights.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions