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

Exception (undefined symbol: obx_version_is_at_least) when instantiating Store #252

Closed
sezaru opened this issue May 23, 2021 · 7 comments · Fixed by #429
Closed

Exception (undefined symbol: obx_version_is_at_least) when instantiating Store #252

sezaru opened this issue May 23, 2021 · 7 comments · Fixed by #429
Labels
enhancement New feature or request
Milestone

Comments

@sezaru
Copy link

sezaru commented May 23, 2021

After upgrading ObjectBox to version 1.0.0, I started receiving an exception every time I start the Store, I only catch this exception when I enable Visual Studio Code "All Exceptions" option, and it doesn't seem to affect anything (the database works fine).

Basic info (please complete the following information):

  • ObjectBox version: 1.0.0
  • Flutter/Dart SDK: 2.2.0/2.13.0
  • Null-safety enabled: yes
  • Reproducibility: always
  • OS: Ubuntu 21.04
  • Device/Emulator: Emulator

Steps to reproduce

  1. Enable VSCode All Exceptions option;
  2. Instantiate a new Store.

Expected behavior

No exception

Logs, stack traces

Since I couldn't get the stacktrace for the issue, I decide to add an image with the exception and the line in the code that it happens to help locate the issue:

image

@sezaru sezaru added the bug Something isn't working label May 23, 2021
@vaind
Copy link
Collaborator

vaind commented May 24, 2021

That's kinda expected and I wonder if we can do anything about it. This code branch is about checking if objectbox.dll/so/dylib is already loaded (as it always is on mac and iOS, but also may be on other platforms) and it does so by trying to check if the symbol exists, catching the exception thrown by DynamicLibrary.lookup() (package dart:ffi). There's currently no other way to do that as far as I know, but I'll try to open an issue upstream.

@vaind
Copy link
Collaborator

vaind commented May 24, 2021

the upstream issue: dart-archive/ffi#104

@vaind vaind added on-hold Blocked by some other issue or a lack of information/ideas how to proceed. and removed bug Something isn't working labels May 24, 2021
@sezaru
Copy link
Author

sezaru commented Jun 5, 2021

Just so you know, version 2.14.0 implemented your upstream suggestion :D

@dev-thinks
Copy link

dev-thinks commented Mar 18, 2022

how to overcome this issue. Objectbox with flutter worked fine in my mac. but suddenly getting this exception and completely blocked my development. @vaind any help would be appreciated.

Update: Nevermind. somehow "Break at all exception" option checked in IDE causes this blocker; reverting this option makes it works as before.

@greenrobot-team
Copy link
Member

greenrobot-team commented Mar 21, 2022

Side note: Dart 2.14.0 has shipped as part of Flutter 2.5.0. New API is DynamicLibrary.providesSymbol.

@greenrobot-team greenrobot-team added enhancement New feature or request and removed on-hold Blocked by some other issue or a lack of information/ideas how to proceed. labels Mar 21, 2022
@greenrobot-team greenrobot-team added this to the 1.5.1 milestone Jun 1, 2022
@greenrobot-team
Copy link
Member

Better late than never this is fixed in the 1.5.1-dev.0 preview release.

@greenrobot-team
Copy link
Member

Fix available with the 1.6.0 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants