Skip to content
New issue

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

type alias docstring doesn't show in tooltip #3402

Closed
beauxq opened this issue Sep 28, 2022 · 4 comments
Closed

type alias docstring doesn't show in tooltip #3402

beauxq opened this issue Sep 28, 2022 · 4 comments
Assignees
Labels
fixed in next version (main) A fix has been implemented and will appear in an upcoming version

Comments

@beauxq
Copy link

beauxq commented Sep 28, 2022

I found this issue #1815 saying this is implemented, but it isn't working.

type-alias-tooltip

Environment data

  • Language Server version: v2022.9.40
  • OS and version: Ubuntu 20.04
  • Python version (& distribution if applicable, e.g. Anaconda): 3.8.10

Code Snippet

from typing import Dict

A = Dict[int, int]
""" xyz """

Expected behavior

tooltip says "xyz"

Actual behavior

tooltip is for dict class

@judej judej added the needs investigation Could be an issue - needs investigation label Sep 29, 2022
@macintacos
Copy link

Agreed, this seems like a regression, since I know it was working before when I reported #1815. Here's a screenshot of an alias I made recently - surprised to see that it didn't show the docstring that I wrote.

CleanShot 2022-10-08 at 23 29 33@2x

@rchiodo rchiodo self-assigned this Oct 24, 2022
@rchiodo
Copy link
Contributor

rchiodo commented Oct 25, 2022

I believe this will be fixed in the next release. If you install the latest pyright extension this behaves as expected.

The next version of pylance will pick up any changes in pyright.

@rchiodo rchiodo added fixed in next version (main) A fix has been implemented and will appear in an upcoming version and removed needs investigation Could be an issue - needs investigation labels Oct 25, 2022
@rchiodo
Copy link
Contributor

rchiodo commented Oct 26, 2022

Looks like I was wrong. This is caused by pylance including Dict's doc string. This is not fixed yet.

@rchiodo rchiodo added needs investigation Could be an issue - needs investigation and removed fixed in next version (main) A fix has been implemented and will appear in an upcoming version labels Oct 26, 2022
@rchiodo
Copy link
Contributor

rchiodo commented Nov 3, 2022

This issue has been fixed in prerelease version 2022.11.11, which we've just released. You can find the changelog here: CHANGELOG.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fixed in next version (main) A fix has been implemented and will appear in an upcoming version
Projects
None yet
Development

No branches or pull requests

4 participants