-
-
Notifications
You must be signed in to change notification settings - Fork 62
using badger as shown in readme does not work #154
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
Comments
Are you sure you are pulling the latest version? |
Hello,
I run go mod tidy and get this go.mod:
From this moment, I get this error : Cannot use 'badger.DefaultOptions("").WithInMemory(true)' (type "github.com/dgraph-io/badger/v4".Options) as the type "github.com/dgraph-io/badger/v3".Options and Cannot resolve c.OpenWithStore Changing the import c "github.com/ostafen/clover" into c "github.com/ostafen/clover/v2" resolves the "Cannot resolve c.OpenWithStore" error. Changing the import "github.com/dgraph-io/badger/v4" into "github.com/dgraph-io/badger/v3" resolve the WithInMemory issue. But continuing in the Readme file, if I try to use |
Hi there, thanks in advance for your time. Looking at this part of the readme:
I have copy-pasted this exactly, but on this line:
store, _ := badgerstore.Open(badger.DefaultOptions("").WithInMemory(true)) // opens a badger in memory database
I get this error:
"Cannot use 'badger.DefaultOptions("").WithInMemory(true)' (type "github.com/dgraph-io/badger/v4".Options) as the type "github.com/dgraph-io/badger/v3".Options"
It appears that if I use badger v3 it works; however, given that the readme example uses badger v4 I spent a while thinking I've done something wrong. Is badger v4 not supported?
The text was updated successfully, but these errors were encountered: