Skip to content

feat: added decorator hover documentation#15

Open
pavanydg wants to merge 1 commit intoouterbounds:mainfrom
pavanydg:main
Open

feat: added decorator hover documentation#15
pavanydg wants to merge 1 commit intoouterbounds:mainfrom
pavanydg:main

Conversation

@pavanydg
Copy link
Copy Markdown

@pavanydg pavanydg commented Mar 6, 2026

Closes Issue #8

closes #8

Feature description:

  • This PR adds hover tooltips for Metaflow decorators that display the decorator name, a short description, available parameters, and a link to the official documentation.
  • Currently supports all the exposable decorators.

Approach:-

  • metaflow_introspect.py file extracts all valid decorators from metaflow. I've used a hybrid approach for extracting decorators because flow and step decorators can be accessed directly as they are subclasses of Flowdecorators and StepDecorators. But @step decorator is a special function. Hence this decorator has been added directly.
  • metaflowHoverProvider.js file is to implement the hover functionality. Currently this file has multiple functions and this will be simplified in later. The main functions include extracting decorators, generating the tooltip ( have use md for this) and creating the hover provider. There is an additional function called resolvePythonPath to get the path of the function to make this extension run efficiently in any environment.
  • modified extension.js so that the hover functionality can be used.

Screenshots/Recordings:

Screenshot 2026-03-06 at 11 39 34 PM
Screen.Recording.2026-03-07.at.12.56.49.AM.mov

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Decorator hover documentation

1 participant