pylance-release icon indicating copy to clipboard operation
pylance-release copied to clipboard

Show Type Hierarchy shows no results for types declared in notebooks

Open debonte opened this issue 1 year ago • 0 comments

Environment data

  • Language Server version: 2024.4.105
  • OS and version: Windows 11
  • Python version: 3.12.1

Code Snippet

class Base:
    pass

class Derived(Base):
    pass

Repro Steps

  1. Create a new notebook.
  2. Paste the code above in the first cell
  3. Right-click on Base and select "Show Type Hierarchy"

Expected behavior

Derived is listed as a subtype.

image

Actual behavior

No subtypes shown. This is because we're not decoding the URI within the TypeHierarchySubtypesParams and we attempt to use that within TypeHierarchyProvider.

image

debonte avatar Apr 30 '24 23:04 debonte