You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've encountered a minor issue when using ModelSchema in the Config inner class. Pylance reports a conflict because ModelSchema already defines Config. Here's a minimal example that triggers the error:
"Config" overrides symbol of same name in class "ModelSchema"
"project.api_extra.UserOutSchema.Config" is not assignable to "ninja_schema.orm.model_schema.ModelSchema.Config"
Type "type[project.api_extra.UserOutSchema.Config]" is not assignable to type "type[ninja_schema.orm.model_schema.ModelSchema.Config]"
Would it be possible to adjust ModelSchema so that defining a Config class doesn't trigger the type checking error? The same happens with Schema.
Alternatively, is there a recommended way to achieve the same configuration without overriding Config?
The text was updated successfully, but these errors were encountered:
Hi eadwinCode!
I've encountered a minor issue when using
ModelSchema
in theConfig
inner class. Pylance reports a conflict becauseModelSchema
already definesConfig
. Here's a minimal example that triggers the error:And the error message from Pylance:
Would it be possible to adjust
ModelSchema
so that defining aConfig
class doesn't trigger the type checking error? The same happens withSchema
.Alternatively, is there a recommended way to achieve the same configuration without overriding
Config
?The text was updated successfully, but these errors were encountered: