Skip to content

feat: bidirectional references (non-batched operations) #503

feat: bidirectional references (non-batched operations)

feat: bidirectional references (non-batched operations) #503

GitHub Actions / clippy succeeded Feb 11, 2025 in 1s

clippy

78 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 0
Warning 78
Note 0
Help 0

Versions

  • rustc 1.84.1 (e71f9a9a9 2025-01-27)
  • cargo 1.84.1 (66221abde 2024-11-19)
  • clippy 0.1.84 (e71f9a9a98 2025-01-27)

Annotations

Check warning on line 942 in grovedb/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/lib.rs:933:5
    |
933 | /     fn verify_merk_and_submerks_in_transaction<'db, B: AsRef<[u8]>, S: StorageContext<'db>>(
934 | |         &'db self,
935 | |         merk: Merk<S>,
936 | |         path: &SubtreePath<B>,
...   |
941 | |         grove_version: &GroveVersion,
942 | |     ) -> Result<VerificationIssues, Error> {
    | |__________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 237 in grovedb/src/operations/proof/verify.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/proof/verify.rs:228:5
    |
228 | /     fn verify_layer_proof<T>(
229 | |         layer_proof: &LayerProof,
230 | |         prove_options: &ProveOptions,
231 | |         query: &PathQuery,
...   |
236 | |         grove_version: &GroveVersion,
237 | |     ) -> Result<CryptoHash, Error>
    | |__________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 215 in grovedb/src/operations/proof/generate.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> grovedb/src/operations/proof/generate.rs:215:74
    |
215 |             self.open_transactional_merk_at_path(path.as_slice().into(), &tx, None, grove_version)
    |                                                                          ^^^ help: change this to: `tx`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow

Check warning on line 175 in grovedb/src/operations/insert/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/insert/mod.rs:166:5
    |
166 | /     fn add_element_on_transaction<'db, B: AsRef<[u8]>>(
167 | |         &'db self,
168 | |         path: SubtreePath<B>,
169 | |         key: &[u8],
...   |
174 | |         grove_version: &GroveVersion,
175 | |     ) -> CostResult<Merk<PrefixedRocksDbTransactionContext<'db>>, Error> {
    | |________________________________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 126 in grovedb/src/operations/insert/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/insert/mod.rs:117:5
    |
117 | /     fn insert_on_transaction<'db, 'b, B: AsRef<[u8]>>(
118 | |         &self,
119 | |         path: SubtreePath<'b, B>,
120 | |         key: &[u8],
...   |
125 | |         grove_version: &GroveVersion,
126 | |     ) -> CostResult<(), Error> {
    | |______________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 117 in grovedb/src/operations/insert/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the following explicit lifetimes could be elided: 'b, 'db

warning: the following explicit lifetimes could be elided: 'b, 'db
   --> grovedb/src/operations/insert/mod.rs:117:30
    |
117 |     fn insert_on_transaction<'db, 'b, B: AsRef<[u8]>>(
    |                              ^^^  ^^
118 |         &self,
119 |         path: SubtreePath<'b, B>,
    |                           ^^
...
123 |         transaction: &'db Transaction,
    |                       ^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
help: elide the lifetimes
    |
117 ~     fn insert_on_transaction<B: AsRef<[u8]>>(
118 |         &self,
119 ~         path: SubtreePath<'_, B>,
120 |         key: &[u8],
121 |         element: Element,
122 |         options: InsertOptions,
123 ~         transaction: &Transaction,
    |

Check warning on line 26 in grovedb/src/operations/insert/v1.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
  --> grovedb/src/operations/insert/v1.rs:17:1
   |
17 | / pub(super) fn insert_on_transaction<'db, 'b, B: AsRef<[u8]>>(
18 | |     db: &GroveDb,
19 | |     path: SubtreePath<'b, B>,
20 | |     key: &[u8],
...  |
25 | |     grove_version: &GroveVersion,
26 | | ) -> CostResult<(), Error> {
   | |__________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 17 in grovedb/src/operations/insert/v1.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the following explicit lifetimes could be elided: 'b, 'db

warning: the following explicit lifetimes could be elided: 'b, 'db
  --> grovedb/src/operations/insert/v1.rs:17:37
   |
17 | pub(super) fn insert_on_transaction<'db, 'b, B: AsRef<[u8]>>(
   |                                     ^^^  ^^
18 |     db: &GroveDb,
19 |     path: SubtreePath<'b, B>,
   |                       ^^
...
23 |     transaction: &'db Transaction,
   |                   ^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
help: elide the lifetimes
   |
17 ~ pub(super) fn insert_on_transaction<B: AsRef<[u8]>>(
18 |     db: &GroveDb,
19 ~     path: SubtreePath<'_, B>,
20 |     key: &[u8],
21 |     element: Element,
22 |     options: InsertOptions,
23 ~     transaction: &Transaction,
   |

Check warning on line 21 in grovedb/src/operations/insert/v0.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
  --> grovedb/src/operations/insert/v0.rs:12:1
   |
12 | / pub(super) fn insert_on_transaction<'db, 'b, B: AsRef<[u8]>>(
13 | |     db: &GroveDb,
14 | |     path: SubtreePath<'b, B>,
15 | |     key: &[u8],
...  |
20 | |     grove_version: &GroveVersion,
21 | | ) -> CostResult<(), Error> {
   | |__________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 638 in grovedb/src/operations/get/query.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/get/query.rs:629:5
    |
629 | /     pub fn query_raw(
630 | |         &self,
631 | |         path_query: &PathQuery,
632 | |         allow_cache: bool,
...   |
637 | |         grove_version: &GroveVersion,
638 | |     ) -> CostResult<(QueryResultElements, u16), Error> {
    | |______________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 264 in grovedb/src/operations/get/query.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/get/query.rs:255:5
    |
255 | /     pub fn query(
256 | |         &self,
257 | |         path_query: &PathQuery,
258 | |         allow_cache: bool,
...   |
263 | |         grove_version: &GroveVersion,
264 | |     ) -> CostResult<(QueryResultElements, u16), Error> {
    | |______________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 133 in grovedb/src/operations/get/query.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/get/query.rs:124:5
    |
124 | /     pub fn query_many_raw(
125 | |         &self,
126 | |         path_queries: &[&PathQuery],
127 | |         allow_cache: bool,
...   |
132 | |         grove_version: &GroveVersion,
133 | |     ) -> CostResult<QueryResultElements, Error>
    | |_______________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 548 in grovedb/src/operations/delete/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/delete/mod.rs:532:5
    |
532 | /     fn delete_internal_on_transaction<B: AsRef<[u8]>>(
533 | |         &self,
534 | |         path: SubtreePath<B>,
535 | |         key: &[u8],
...   |
547 | |         grove_version: &GroveVersion,
548 | |     ) -> CostResult<bool, Error> {
    | |________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 418 in grovedb/src/operations/delete/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/delete/mod.rs:409:5
    |
409 | /     pub fn delete_operation_for_delete_internal<B: AsRef<[u8]>>(
410 | |         &self,
411 | |         path: SubtreePath<B>,
412 | |         key: &[u8],
...   |
417 | |         grove_version: &GroveVersion,
418 | |     ) -> CostResult<Option<QualifiedGroveDbOp>, Error> {
    | |______________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 122 in grovedb/src/operations/delete/worst_case.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/delete/worst_case.rs:113:5
    |
113 | /     pub fn worst_case_delete_operation_for_delete<'db, S: Storage<'db>>(
114 | |         path: &KeyInfoPath,
115 | |         key: &KeyInfo,
116 | |         in_parent_tree_type: TreeType,
...   |
121 | |         grove_version: &GroveVersion,
122 | |     ) -> CostResult<QualifiedGroveDbOp, Error> {
    | |______________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 208 in grovedb/src/operations/delete/delete_up_tree.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/delete/delete_up_tree.rs:199:5
    |
199 | /     pub fn add_delete_operations_for_delete_up_tree_while_empty<B: AsRef<[u8]>>(
200 | |         &self,
201 | |         path: SubtreePath<B>,
202 | |         key: &[u8],
...   |
207 | |         grove_version: &GroveVersion,
208 | |     ) -> CostResult<Option<Vec<QualifiedGroveDbOp>>, Error> {
    | |___________________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 176 in grovedb/src/operations/delete/delete_up_tree.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/delete/delete_up_tree.rs:167:5
    |
167 | /     pub fn delete_operations_for_delete_up_tree_while_empty<B: AsRef<[u8]>>(
168 | |         &self,
169 | |         path: SubtreePath<B>,
170 | |         key: &[u8],
...   |
175 | |         grove_version: &GroveVersion,
176 | |     ) -> CostResult<Vec<QualifiedGroveDbOp>, Error> {
    | |___________________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 147 in grovedb/src/operations/delete/average_case.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
   --> grovedb/src/operations/delete/average_case.rs:138:5
    |
138 | /     pub fn average_case_delete_operation_for_delete<'db, S: Storage<'db>>(
139 | |         path: &KeyInfoPath,
140 | |         key: &KeyInfo,
141 | |         in_parent_tree_type: TreeType,
...   |
146 | |         grove_version: &GroveVersion,
147 | |     ) -> CostResult<QualifiedGroveDbOp, Error> {
    | |______________________________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 184 in grovedb/src/operations/delete/v1.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the following explicit lifetimes could be elided: 'c, 'db

warning: the following explicit lifetimes could be elided: 'c, 'db
   --> grovedb/src/operations/delete/v1.rs:184:6
    |
184 | impl<'c, 'db, 'b, B: AsRef<[u8]>> util::Visit<'b, B> for DeletionVisitor<'c, 'db, 'b, B> {
    |      ^^  ^^^                                                             ^^  ^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
help: elide the lifetimes
    |
184 - impl<'c, 'db, 'b, B: AsRef<[u8]>> util::Visit<'b, B> for DeletionVisitor<'c, 'db, 'b, B> {
184 + impl<'b, B: AsRef<[u8]>> util::Visit<'b, B> for DeletionVisitor<'_, '_, 'b, B> {
    |

Check warning on line 35 in grovedb/src/operations/delete/v1.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
  --> grovedb/src/operations/delete/v1.rs:19:1
   |
19 | / pub(super) fn delete_internal_on_transaction<B: AsRef<[u8]>>(
20 | |     db: &GroveDb,
21 | |     path: SubtreePath<B>,
22 | |     key: &[u8],
...  |
34 | |     grove_version: &GroveVersion,
35 | | ) -> CostResult<bool, Error> {
   | |____________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 33 in grovedb/src/operations/delete/v0.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (8/7)

warning: this function has too many arguments (8/7)
  --> grovedb/src/operations/delete/v0.rs:17:1
   |
17 | / pub(super) fn delete_internal_on_transaction<B: AsRef<[u8]>>(
18 | |     db: &GroveDb,
19 | |     path: SubtreePath<B>,
20 | |     key: &[u8],
...  |
32 | |     grove_version: &GroveVersion,
33 | | ) -> CostResult<bool, Error> {
   | |____________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments

Check warning on line 254 in grovedb/src/merk_cache.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> grovedb/src/merk_cache.rs:254:33
    |
254 | ...                   &self.version,
    |                       ^^^^^^^^^^^^^ help: change this to: `self.version`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow

Check warning on line 114 in grovedb/src/merk_cache.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> grovedb/src/merk_cache.rs:114:59
    |
114 |                     Element::get(&merk, parent_key, true, &self.version)
    |                                                           ^^^^^^^^^^^^^ help: change this to: `self.version`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow

Check warning on line 114 in grovedb/src/merk_cache.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> grovedb/src/merk_cache.rs:114:34
    |
114 |                     Element::get(&merk, parent_key, true, &self.version)
    |                                  ^^^^^ help: change this to: `merk`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow

Check warning on line 730 in grovedb/src/element/query.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this function has too many arguments (12/7)

warning: this function has too many arguments (12/7)
   --> grovedb/src/element/query.rs:717:5
    |
717 | /     fn query_item(
718 | |         storage: &RocksDbStorage,
719 | |         item: &QueryItem,
720 | |         results: &mut Vec<QueryResultElement>,
...   |
729 | |         grove_version: &GroveVersion,
730 | |     ) -> CostResult<(), Error> {
    | |______________________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments