isar / isar/hive

Error: HiveError: Box not found. Did you forget to call Hive.openBox()

Open
#1,243 5 comments 1 reaction 0 assignees View on GitHub
Dominant language
Dart
Stars
4.4k
Forks
449
PR merge metrics
No merged PRs in 30d

Description

I am getting the following error when I try to open the box `tableDeviceShadow` in my code:

```
Error: HiveError: Box not found. Did you forget to call Hive.openBox()
```

I have already added the `await` keyword before the `Hive.openBox()` function, but the error is still occurring.

I have tried the following things to fix the issue:

* I have updated the Hive library to the latest version.
* I have restarted my computer.
* I have cleared the cache and data for the app.

None of these things have worked.

I am attaching a screenshot of the error message.

I would appreciate any help you can provide in resolving this issue.

Thank you.

![image](https://github.com/isar/hive/assets/135976997/f48247a1-0104-4aea-8955-f1addd3d9b93)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at the Hive.openBox call for the tableDeviceShadow box and reproduce the reported “Box not found” error. No source files or tests are named, so a useful outcome would first require a minimal reproduction and enough context to identify the cause and verify a fix.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart
Domain
database
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.