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

Add ability to list a collection's Headers without the document contents #221

Merged
merged 8 commits into from
Mar 21, 2022

Conversation

vbmade2000
Copy link
Contributor

@vbmade2000 vbmade2000 commented Mar 5, 2022

Closes #193.

@vbmade2000
Copy link
Contributor Author

Still WIP. Confused about what to implement next.

Copy link
Member

@ecton ecton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you feel is missing from the issue? Other than the unit test not verifying the output, I think this completes all the requirements in the issue?

crates/bonsaidb-core/src/test_util.rs Outdated Show resolved Hide resolved
@ecton
Copy link
Member

ecton commented Mar 5, 2022

Ah, after running the CI, I see this error:

no method named `headers` found for struct `connection::List` in the current scope

This is telling you that you need to add a method named headers to connection::List. As per the linked issue, this should be implemented similarly to connection::List::count

@vbmade2000
Copy link
Contributor Author

I introduced a typo in commit message by mistake. It should be Write test for list_headers

@vbmade2000 vbmade2000 requested a review from ecton March 20, 2022 16:28
Copy link
Member

@ecton ecton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of the code looks good at first glance, but the CI is failing to compile with this error:

 error[E0308]: mismatched types
Error:    --> crates/bonsaidb-core/src/connection.rs:961:60
    |
961 |                     .list_headers::<Cl, _, _>(range, sort, limit)
    |                                                            ^^^^^ expected `usize`, found `u32`
    |
    = note: expected enum `std::option::Option<usize>`
               found enum `std::option::Option<u32>`

@vbmade2000 vbmade2000 force-pushed the list_col_header_193 branch from 707e917 to 20800e6 Compare March 20, 2022 17:41
@vbmade2000 vbmade2000 requested a review from ecton March 20, 2022 18:20
@ecton ecton merged commit b2294eb into khonsulabs:main Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add ability to list a collection's Headers without the document contents.
2 participants