Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Loaded ObjectBox core dynamic library has unsupported version 0.18.1, expected ^0.19.0 #563

Closed
linememory opened this issue Sep 22, 2023 · 17 comments
Labels
bug Something isn't working
Milestone

Comments

@linememory
Copy link

I always get the following error. I tried it with the objectbox examples like objectbox_demo_relations

E/flutter ( 5963): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: Unsupported operation: Loaded ObjectBox core dynamic library has unsupported version 0.18.1, expected ^0.19.0
E/flutter ( 5963): #0      loadObjectBoxLib
bindings.dart:110
E/flutter ( 5963): #1      C
bindings.dart:119
E/flutter ( 5963): #2      C (package:objectbox/src/native/bindings/bindings.dart)
bindings.dart:1
E/flutter ( 5963): #3      new Model
model.dart:19
E/flutter ( 5963): #4      new Store
store.dart:192
E/flutter ( 5963): #5      openStore
objectbox.g.dart:93
E/flutter ( 5963): #6      ObjectBox.create
objectbox.dart:49
E/flutter ( 5963): <asynchronous suspension>
E/flutter ( 5963): #7      main
main.dart:19
E/flutter ( 5963): <asynchronous suspension>

This happens on Windows and on linux on a Lenovo Thinkpad yoga from 2017. I can not test it on an other machine atm.
I used bash <(curl -s https://raw.githubusercontent.com/objectbox/objectbox-dart/main/install.sh) to install the shared library and also downloaded the 0.19.0 and put it in /usr/lib and on Windows 11 in System32. I installed flutter manually.

  • ObjectBox version: 2.3.0
  • Flutter SDK: 3.13.5
  • Reproducible: always
  • Build OS: Pop!_OS 22.04 LTS and Windows 11
  • Deployment device or OS: Pixel 6, Android 13 and different Android versions on emulator

flutter doctor

[✓] Flutter (Channel stable, 3.13.5, on Pop!_OS 22.04 LTS 6.4.6-76060406-generic, locale en_US.UTF-8)
    • Flutter version 3.13.5 on channel stable at /home/lukas/Development/SDK/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 12fccda598 (3 days ago), 2023-09-19 13:56:11 -0700
    • Engine revision bd986c5ed2
    • Dart version 3.1.2
    • DevTools version 2.25.0

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /home/lukas/Android/Sdk
    • Platform android-33, build-tools 34.0.0
    • Java binary at: /home/lukas/Apps/android-studio/jbr/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)
    • All Android licenses accepted.

[✓] Chrome - develop for the web
    • Chrome at google-chrome

[✓] Linux toolchain - develop for Linux desktop
    • Ubuntu clang version 14.0.0-1ubuntu1.1
    • cmake version 3.22.1
    • ninja version 1.10.1
    • pkg-config version 0.29.2

[✓] Android Studio (version 2022.3)
    • Android Studio at /home/lukas/Apps/android-studio
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)

[✓] VS Code (version 1.82.2)
    • VS Code at /usr/share/code
    • Flutter extension version 3.72.0

[✓] Connected device (3 available)
    • sdk gphone x86 64 (mobile) • emulator-5554 • android-x64    • Android 13 (API 33) (emulator)
    • Linux (desktop)            • linux         • linux-x64      • Pop!_OS 22.04 LTS 6.4.6-76060406-generic
    • Chrome (web)               • chrome        • web-javascript • Google Chrome 117.0.5938.88

[✓] Network resources
    • All expected network resources are available.

• No issues found!
@linememory linememory added the bug Something isn't working label Sep 22, 2023
@PKiman
Copy link

PKiman commented Sep 22, 2023

Downgrade to 2.2.0 works but remove the caret syntax ^2.2.0

dependencies:
  flutter:
    sdk: flutter
 
  # Do not use caret syntax: objectbox: ^2.2.0 
  objectbox: 2.2.0 
  objectbox_sync_flutter_libs: 2.2.0
  objectbox_generator: 2.2.0 

#309 (comment)

@linememory
Copy link
Author

Same problem with 2.2.0

@PKiman
Copy link

PKiman commented Sep 22, 2023

Same problem with 2.2.0

And 2.1.0 too?

try to remove the caret syntax ^ from ^2.2.0.
This worked for me.

@linememory
Copy link
Author

Oh my bad. Now it works. Forgot to remove the caret.

@ririlya94
Copy link

was wondering why need to downgrade? is 2.3.0 can't be use?

@PKiman
Copy link

PKiman commented Sep 26, 2023

Because Objectbox 2.3.0 does not work on Android. See error in original post.

@techouse
Copy link

Confirmed, v2.2.1 works, v2.3.0 throws this error on Android.

@greenrobot
Copy link
Member

greenrobot commented Oct 2, 2023

Please check 2.3.1-dev.0 if it works for you...
Sorry, discovered some bug, dev.1 coming soon...

@greenrobot
Copy link
Member

2.3.1-dev.1 seems good, as soon as we have some external confirmation, this will become 2.3.1. So let us know...

@Gobbo89
Copy link

Gobbo89 commented Oct 2, 2023

2.3.1-dev.1 seems good, as soon as we have some external confirmation, this will become 2.3.1. So let us know...

2.3.1-dev.1 works on Android, the error we had with 2.3.0 is gone.

@greenrobot
Copy link
Member

2.3.1 is published with a fix.

@hongfeiyang

This comment was marked as resolved.

@greenrobot-team

This comment was marked as resolved.

@hongfeiyang

This comment was marked as resolved.

@greenrobot-team

This comment was marked as resolved.

@hongfeiyang

This comment was marked as resolved.

@hongfeiyang

This comment was marked as resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

8 participants