Generic type aliases show two inlay hints that each function independently, with no visual separation between them. I'm not sure if it's just restricted to type aliases with generics, but I first noticed it happening when hints from numpy functions such as np.array(3) would be things like Anyndarray[Any, dtype[Any]]. I tried to reduce it down to a minimal example from there.
Environment data
Language Server version: 2024.9.101
OS and version: darwin arm64
Python version (and distribution if applicable, e.g. Anaconda): 3.12.4
python.analysis.indexing: true
python.analysis.typeCheckingMode: off
Code Snippet
from typing import TypeVar
T = TypeVar("T")
type U = list[T]
def func() -> U: ...
a = func()
def func2() -> U[int]: ...
b = func2()
Expected behavior
I'd expect only the second inlay hint to be present, for example a: list and b: list[int].
@StellaHuang95, reassigned to you. Given that this regressed in 2024.8.101, I'm guessing this has something to do with the inlay hint go to def feature.
Generic type aliases show two inlay hints that each function independently, with no visual separation between them. I'm not sure if it's just restricted to type aliases with generics, but I first noticed it happening when hints from numpy functions such as
np.array(3)
would be things likeAnyndarray[Any, dtype[Any]]
. I tried to reduce it down to a minimal example from there.Environment data
Code Snippet
Expected behavior
I'd expect only the second inlay hint to be present, for example
a: list
andb: list[int]
.Actual behavior
(Previous) Behavior in 2024.8.100:
(Current) Behavior from 2024.8.101 to 2024.9.101:
Logs