Aucune description

Afshin T. Darian 4596e82a01 Update Debugger.Session il y a 4 ans
.github 32f3967858 Unpin xeus il y a 5 ans
binder 4ca9ab2aca v0.3.0-beta.4 il y a 4 ans
examples 6e5c2743e0 Add sidebar section to the tutorial notebook il y a 5 ans
schema 23621497eb Filter _xpython-prefixed variables il y a 5 ans
src 4596e82a01 Update Debugger.Session il y a 4 ans
style 4dd77c1d72 Fix file editor toolbar CSS il y a 4 ans
test 4596e82a01 Update Debugger.Session il y a 4 ans
.eslintignore 356d1fe8a5 Switch to ESLint il y a 5 ans
.eslintrc.js c783799976 Require jsdoc description for eslint il y a 5 ans
.gitignore ef32662519 Add yarn.lock il y a 4 ans
.prettierignore 1910f45233 Add .prettierignore file il y a 5 ans
.prettierrc 65b4154a8c Add .prettierrc il y a 5 ans
DESIGN.md f8f82ebdfe Fix design file location. il y a 5 ans
LICENSE 64db2dfe4b Update LICENSE il y a 5 ans
README.md 32f3967858 Unpin xeus il y a 5 ans
babel.config.js 63b8370600 Switch to JupyterServer from @jupyterlab/testutils il y a 5 ans
jest.config.js 63b8370600 Switch to JupyterServer from @jupyterlab/testutils il y a 5 ans
lint-staged.config.js e9a52f476b Add explicit return types to functions and methods il y a 5 ans
package.json 3434444978 Update to JupyterLab 2.2 final il y a 4 ans
screencast.gif d7015ddb03 Add screencast il y a 5 ans
tdoptions.json 9e67f61b69 Add a shell JupyterLab extension. il y a 5 ans
tsconfig.eslint.json 63b8370600 Switch to JupyterServer from @jupyterlab/testutils il y a 5 ans
tsconfig.json 25bfc84fb0 Add scaffolding for tests il y a 5 ans
tsconfig.test.json 63b8370600 Switch to JupyterServer from @jupyterlab/testutils il y a 5 ans
yarn.lock 3434444978 Update to JupyterLab 2.2 final il y a 4 ans

README.md

@jupyterlab/debugger

Github Actions Status Binder npm

A JupyterLab debugger UI extension. This extension is under active development.

screencast

Prerequisites

  • JupyterLab 2.0+
  • xeus-python 0.8.0+
  • notebook 6+

Installation

A kernel with support for debugging is required to be able to use the debugger.

It is generally recommended to create a new conda environment to install the dependencies:

conda create -n jupyterlab-debugger -c conda-forge xeus-python=0.8.0 notebook=6 jupyterlab=2 ptvsd nodejs
conda activate jupyterlab-debugger

Then, run the following command to install the extension:

jupyter labextension install @jupyterlab/debugger

Usage

For now xeus-python is the only Jupyter kernel that supports debugging. xeus-python can be selected from the JupyterLab launcher:

xpython-launcher

Alternatively, it is also possible to switch to the xpython kernel using the kernel selection dialog:

xpython-dialog

Enable the debugger, set breakpoints and step into the code:

xpython-step

Development

# Create a new conda environment
conda create -n jupyterlab-debugger -c conda-forge nodejs xeus-python=0.8.0 ptvsd jupyterlab=2

# Activate the conda environment
conda activate jupyterlab-debugger

# Install dependencies
jlpm

# Build TypeScript source
jlpm build

# Link your development version of the extension with JupyterLab
jupyter labextension link .

# Rebuild TypeScript source after making changes
jlpm build

# Rebuild JupyterLab after making any changes
jupyter lab build

# Start JupyterLab with the kernel logs enabled and watch mode enabled
XEUS_LOG=1 jupyter lab --no-browser --watch

Tests

To run the tests:

# [Optional] to enable the logs for xeus-python
export XEUS_LOG=1

jlpm run test

To run tests for a specific test suite name:

jlpm run test --testNamePattern=<regex>

To run tests for a specific test module name:

jlpm run test --testPathPattern=<regex>

Inspecting debug messages

The kernelspy extension for JupyterLab can be used to inspect the debug messages sent between the debugger UI and the kernel.

To install it:

jupyter labextension install jupyterlab-kernelspy