Skip to content

Fix Clippy 1.87 large error#6529

Merged
timvisee merged 1 commit intodevfrom
clippy-1.87-ter
May 13, 2025
Merged

Fix Clippy 1.87 large error#6529
timvisee merged 1 commit intodevfrom
clippy-1.87-ter

Conversation

@agourlay
Copy link
Member

Follow up to #6518

There is a large amount of warning with:

error: the `Err`-variant returned from this function is very large
    --> lib/api/src/grpc/conversions.rs:2210:6
     |
2210 | ) -> Result<segment_vectors::NamedVectorStruct, Status> {
     |      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the `Err`-variant is at least 176 bytes
     |
     = help: try reducing the size of `tonic::Status`, for example by boxing large elements or replacing it with `Box<tonic::Status>`
     = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#result_large_err

Given that we use the Tonic's Status a lot as error type, I decided to simply raise the the threshold for the time being.

We can decide later if we want to Box all the call sites.

@agourlay agourlay requested a review from timvisee May 13, 2025 10:26
@coderabbitai

This comment was marked as resolved.

coderabbitai[bot]

This comment was marked as resolved.

@timvisee timvisee merged commit 718e842 into dev May 13, 2025
17 checks passed
@timvisee timvisee deleted the clippy-1.87-ter branch May 13, 2025 13:04
@agourlay
Copy link
Member Author

FYI hyperium/tonic#2253

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.

2 participants