GUI-based Python code generator extension for Jupyter Lab, Jupyter Notebook, and Google Colab
npx @tessl/cli install tessl/pypi-jupyterlab-visualpython@3.0.0Visual Python is a GUI-based Python code generator extension for JupyterLab that enables users to create Python code through an intuitive visual interface. It provides a comprehensive visual programming environment within JupyterLab, making data science and Python programming accessible to users with minimal coding experience.
pip install jupyterlab-visualpythonThe package provides both Python module imports and JupyterLab extension functionality:
# Python module import (for extension discovery)
import visualpython// JupyterLab extension is automatically loaded
// Commands and UI components are registered automaticallyAfter installation, Visual Python integrates directly into JupyterLab:
# Install the extension
pip install jupyterlab-visualpython
# Start JupyterLab (Visual Python will be available)
jupyter labVisual Python provides:
Visual Python consists of several key components:
Core Python module providing JupyterLab extension discovery and version information.
# Module-level functions
def _jupyter_labextension_paths() -> List[Dict[str, str]];
# Module variables
__version__: strMain extension plugin that integrates Visual Python into JupyterLab interface with panel management and command registration.
// Extension activation
function activate(app: JupyterLab, palette: ICommandPalette): void;
// Global variables set by extension
global.vpBase: string;
global.vpExtType: string;
global.vpLab: JupyterLab;
global.$: jQuery;Interactive panel component providing the main Visual Python GUI interface within JupyterLab.
class VpPanel extends Panel {
constructor(app: JupyterLab);
onResize(msg: ResizeMessage): void;
onBeforeShow(): void;
onAfterHide(): void;
onAfterAttach(): void;
onCloseRequest(msg: CloseRequestMessage): void;
}Command system integration providing keyboard shortcuts and menu access to Visual Python functionality.
// Available commands
'jupyterlab-visualpython:toggle': Command;
// Keyboard shortcuts
'Accel Shift V': 'jupyterlab-visualpython:toggle'; // Toggle Visual Python panel# Python types
Dict = dict
List = list// JupyterLab types
interface JupyterLab extends JupyterFrontEnd {
shell: ILabShell;
commands: CommandRegistry;
version: string;
}
interface ICommandPalette {
addItem(options: IPaletteItem): IDisposable;
}
interface Panel extends Widget {
id: string;
title: Title<Widget>;
isVisible: boolean;
}
type ResizeMessage = Message;
type CloseRequestMessage = Message;
type Message = any; // Lumino message base type