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
Describe the bug
In the latest version if I use underscored attributes, which are private attributes, when I try to use them like self._private_attr, the IDE shows Unresolved attribute reference error.
The same if I use PrivateAttr(default).
To Reproduce
classTest(BaseModel):
_private_attr: int=42defget(self):
print(self._private_attr) # Unresolved attribute reference '_private_attr' for class 'Test' @classmethoddeftest(cls):
print(cls._private_attr.defaut) # Unresolved attribute reference 'default' for class 'int'
Expected behavior
It shoud not show errors.
Environments (please complete the following information):
IDE: PyCharm Professional 2023.3.5
OS: e.g. macOS 14.4.1
Pydantic Version: 2.6.3
Plugin version 0.4.12
The text was updated successfully, but these errors were encountered:
Describe the bug
In the latest version if I use underscored attributes, which are private attributes, when I try to use them like
self._private_attr
, the IDE showsUnresolved attribute reference
error.The same if I use
PrivateAttr(default)
.To Reproduce
Expected behavior
It shoud not show errors.
Environments (please complete the following information):
The text was updated successfully, but these errors were encountered: