Skip to content

Conversation

@benthecarman
Copy link
Collaborator

We weren't checking for any clippy issues. This fixes most of them and adds a few exceptions for ones not worth fixing or ones that will be fixed with future changes.

@benthecarman benthecarman requested a review from tnull December 17, 2025 00:42
@ldk-reviews-bot
Copy link

ldk-reviews-bot commented Dec 17, 2025

👋 Thanks for assigning @tnull as a reviewer!
I'll wait for their review and will help manage the review process.
Once they submit their review, I'll check if a second reviewer would be helpful.

}

/// A no-op implementation of the [`EventPublisher`] trait.
#[allow(dead_code)] // This is unused when rabbitmq feature is enabled
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why not cfg-gate it on not(feature = "events-rabbitmq") then?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

yeah much better, done

Copy link
Collaborator

Choose a reason for hiding this comment

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

Should be okay for now, but that's a reminder that before we have the codebases diverge even further, can should finally upstream PaginatedKVStore to LDK and add SqliteStore/PostgresStore there, too.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah good call out, will start on that soon

Copy link
Contributor

@Anyitechs Anyitechs left a comment

Choose a reason for hiding this comment

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

Looking good! Thanks for the clean ups.

}
}

#[allow(clippy::too_many_arguments)]
Copy link
Contributor

Choose a reason for hiding this comment

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

I believe this is one of the exceptions being mentioned in the commit message as refactoring the function here is more suitable than suppressing the warning. Could you add a TODO here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

no this makes more sense to keep as is imo

# enabled with --all-features. Proto generation is a developer-only tool that
# requires external dependencies (protoc) and shouldn't be triggered accidentally.
# This lint configuration tells Cargo that genproto is an expected custom cfg.
[lints.rust]
Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure I understand this correctly, but running the command to generate updated proto objects usually introduces some format changes to all the existing generated rust code, and will need you to re-format each file manually. Does this also fix that or is there a way we can handle that here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

you are just supposed to run cargo fmt after you generate, not really relevant here though

Copy link
Contributor

Choose a reason for hiding this comment

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

Right. Just wanted to know if there's a way to make it skip re-formatting files that weren't touched, but I agree it's not relevant here

@benthecarman benthecarman force-pushed the clippy branch 3 times, most recently from ab49b50 to f466ce2 Compare December 17, 2025 12:26
We weren't checking for any clippy issues. This fixes most of them and adds a few exceptions for ones not worth fixing or ones that will be fixed with future changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

4 participants