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
Nested input models like class BgpAfi(BaseModel) don't inherit from AntaTest.Input meaning they don't forbid extra attributes. This could lead to unexpected behaviors for a user who wants to override a default value but accidently provides the wrong key.
BGP tests for example. If a user provides vrfs instead of vrf, ANTA will silently ignore vrfs and use the default value of vrf. An error should be raised to the user since vrfs is not supported.
The text was updated successfully, but these errors were encountered:
Nested input models are being moved over to anta.input_models package (see #388) and model_config = ConfigDict(extra="forbid") should be added at the same time.
Nested input models like
class BgpAfi(BaseModel)
don't inherit fromAntaTest.Input
meaning they don't forbid extra attributes. This could lead to unexpected behaviors for a user who wants to override a default value but accidently provides the wrong key.BGP tests for example. If a user provides
vrfs
instead ofvrf
, ANTA will silently ignorevrfs
and use the default value ofvrf
. An error should be raised to the user sincevrfs
is not supported.The text was updated successfully, but these errors were encountered: