We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Start with this code in ipython with jedi enabled for tab completion:
from typing import Iterable, Any class Bar: def __dir__(self) -> Iterable[str]: return ("a", "b", "c") def __getattr__(self, key: str) -> Any: if key not in ("a", "b", "c"): raise AttributeError return self[key] def __getitem__(self, key: str) -> "Bar": return Bar() class Foo: _b: Bar | None def __init__(self) -> None: self._b = None @property def b(self): if not self._b: self._b = Bar() return self._b f = Foo() f.b. <hit tab>
We get what we expect with a menu of a, b, c in jedi 0.18.1 or 0.19.0 and later
Now add a type annotation to the @property in Foo:
@property
from typing import Iterable, Any class Bar: def __dir__(self) -> Iterable[str]: return ("a", "b", "c") def __getattr__(self, key: str) -> Any: if key not in ("a", "b", "c"): raise AttributeError return self[key] def __getitem__(self, key: str) -> "Bar": return Bar() class Foo: _b: Bar | None def __init__(self) -> None: self._b = None @property def b(self) -> Bar: if not self._b: self._b = Bar() return self._b f = Foo() f.b. <hit tab>
This now works in 0.18.2 but fails in 0.19.0 and above.
Possibly as a result of one of these commits: 972123c ff3a7f3 886279f
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Start with this code in ipython with jedi enabled for tab completion:
We get what we expect with a menu of a, b, c in jedi 0.18.1 or 0.19.0 and later
Now add a type annotation to the
@property
in Foo:This now works in 0.18.2 but fails in 0.19.0 and above.
Possibly as a result of one of these commits:
972123c
ff3a7f3
886279f
The text was updated successfully, but these errors were encountered: