Open rafa-guedes opened 1 month ago
This is linked to https://github.com/pydantic/pydantic/discussions/7121. We are actually already setting the protected_namespaces parameter in RompyBaseModel, this particular warning was just because I didn't inherit BaseInterpolator from RompyBaseClass.
We may still want to consider renaming model_type though, up for discussion.
Still on this topic of confusing / conflicting namespaces, we use in rompy "model" and "config" broadly which have specific meaning in pydantic itself. Should we consider changing these to something a bit more distinguishable? For example, config
in rompy could be renamed into setup
. Thoughts @tomdurrant @benjaminleighton ?
/home/rguedes/.virtualenvs/xbeach/lib/python3.10/site-packages/pydantic/_internal/_fields.py:132: UserWarning: Field "modeltype" in BaseInterpolator has conflict with protected namespace "model".