We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hey!
I might be missing something here, but from what it looks like, DUP_SORT is not behaving as expected.
I have the following test code:
use lmdb::{Cursor, Database, DatabaseFlags, Environment, RwTransaction, Transaction, WriteFlags}; use std::sync::Arc; use tempdir::TempDir; fn main() { let db_tmp = TempDir::new("test").unwrap().into_path(); let db_path = db_tmp.to_str().unwrap(); let env = Arc::new( Environment::new() .set_max_dbs(10) .set_map_size(10000000) .open(db_path.as_ref()) .unwrap(), ); let db = env .create_db(Some("db_name"), DatabaseFlags::DUP_SORT) .unwrap(); let key = vec![3u8; 32]; let val = vec![4u8; 32]; { let mut db_txn = env.begin_rw_txn().unwrap(); db_txn.put(db, &key, &val, WriteFlags::empty()).unwrap(); db_txn.commit().unwrap(); } { let mut db_txn = env.begin_rw_txn().unwrap(); db_txn.del(db, &key, Some(&val)).unwrap(); db_txn.commit().unwrap(); } }
The code panics at db_txn.del(db, &key, Some(&val)).unwrap(); with Err value: NotFound'`. Is this expected to work?
db_txn.del(db, &key, Some(&val)).unwrap();
Err
Thank you!
The text was updated successfully, but these errors were encountered:
Merge pull request danburkert#58 from mozilla/lmdb-tests
df2dc92
Run lmdb tests alongside `cargo test`
No branches or pull requests
Hey!
I might be missing something here, but from what it looks like, DUP_SORT is not behaving as expected.
I have the following test code:
The code panics at
db_txn.del(db, &key, Some(&val)).unwrap();
withErr
value: NotFound'`. Is this expected to work?Thank you!
The text was updated successfully, but these errors were encountered: