Skip to content

Add CodeLens "Spin" action above each @step method#9

Open
MayankJha0333 wants to merge 1 commit intoouterbounds:mainfrom
MayankJha0333:feature/codelens-spin-action
Open

Add CodeLens "Spin" action above each @step method#9
MayankJha0333 wants to merge 1 commit intoouterbounds:mainfrom
MayankJha0333:feature/codelens-spin-action

Conversation

@MayankJha0333
Copy link
Copy Markdown

Fix #4

Overview

This PR adds a clickable ⟳ Spin CodeLens button above every @step method in Metaflow flow files, similar to how VS Code shows Run Test above test functions.

This improves discoverability and allows users to run individual steps directly from the editor without relying on keyboard shortcuts.


Changes

extension.js

  • Added MetaflowCodeLensProvider

    • Scans Python files for @step decorators
    • Displays a ⟳ Spin button above each detected step
  • Added spinStep() command handler

    • Executes the following command in the integrated terminal:
    python myflow.py spin <step_name>

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.

Add CodeLens "Spin" action above each step method

2 participants