Repository navigation
|
A simple model like this #[sea_orm::model]
#[derive(Clone, Debug, PartialEq, Eq, DeriveEntityModel)]
#[sea_orm(table_name = "cake")]
pub struct Model {
#[sea_orm(primary_key)]
pub id: i32,
pub name: String,
}causes a clippy error with the sea-orm/sea-orm-macros/src/derives/model_ex.rs Lines 100 to 102 in 13be0db |
Answered by
kapalla
Aug 21, 2026
Replies: 1 comment
|
After creating additional models, I started receiving more specific error messages explaining why However, instead of suppressing the Clippy error manually in these cases, it would be better if the macro handled it automatically. Accordingly, I’ve submitted a PR #3180 |
0 replies
Answer selected by
kapalla
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
After creating additional models, I started receiving more specific error messages explaining why
Eqcannot be applied toModelEx. As I understand it, this is due to relations that are defined as attributes inModelEx. If these cannot beEq(for example, because of anf32attribute) then the related model can no longer beEqeither.However, instead of suppressing the Clippy error manually in these cases, it would be better if the macro handled it automatically. Accordingly, I’ve submitted a PR #3180