Skip to content

Update docs to reference Python Debugger extension #6979

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Jan 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions docs/containers/docker-compose.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ Create an **Attach** [launch configuration](/docs/editor/debugging.md#launch-con

For debugging Python with Docker Compose, follow these steps:

1. On the **Debug** tab, choose the **Configuration** dropdown, choose **New Configuration**, choose **Python**, and select the `Remote Attach` configuration template.
1. On the **Debug** tab, choose the **Configuration** dropdown, choose **New Configuration**, choose **Python Debugger**, and select the `Remote Attach` configuration template.

![Screenshot of Python Remote Attach](images/compose/docker-compose-python-remote-attach.png)

Expand All @@ -116,8 +116,8 @@ For debugging Python with Docker Compose, follow these steps:
```json
"configurations": [
{
"name": "Python: Remote Attach",
"type": "python",
"name": "Python Debugger: Remote Attach",
"type": "debugpy",
"request": "attach",
"port": 5678,
"host": "localhost",
Expand All @@ -130,7 +130,7 @@ For debugging Python with Docker Compose, follow these steps:
}
```

1. When done editing the **Attach** configuration, save the `launch.json`. Navigate to the **Debug** tab and select **Python: Remote Attach** as the active configuration.
1. When done editing the **Attach** configuration, save the `launch.json`. Navigate to the **Debug** tab, and select **Python Debugger: Remote Attach** as the active configuration.

1. If you already have a valid Dockerfile, we recommend running the command **Docker: Add Docker Compose Files to Workspace**. This will create a `docker-compose.yml` file and also a `docker-compose.debug.yml`, which volume maps and starts the Python debugger in the container. If you do not have a Dockerfile already, we recommend running **Docker: Add Docker Files to Workspace** and selecting **Yes** to include Docker Compose files.

Expand All @@ -153,7 +153,7 @@ For debugging Python with Docker Compose, follow these steps:
- 5678:5678
```

1. Once your container is built and running, attach the debugger by hitting `kb(workbench.action.debug.start)` with the **Python: Remote Attach** launch configuration selected.
1. Once your container is built and running, attach the debugger by hitting `kb(workbench.action.debug.start)` with the **Python Debugger: Remote Attach** launch configuration selected.

![Screenshot of debugging in Python](images/compose/docker-compose-python-debug.png)

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

This file was deleted.

4 changes: 2 additions & 2 deletions docs/languages/python.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ The Python extension can apply a number of different linters including Pylint, p

## Debugging

No more `print` statement debugging! VS Code comes with great debugging support for Python, allowing you to set breakpoints, inspect variables, and use the debug console for an in-depth look at how your program is executing step by step. Debug a number of different types of Python applications, including multi-threaded, web, and remote applications.
No more `print` statement debugging! VS Code comes with great debugging support for Python via the [Python Debugger extension](https://marketplace.visualstudio.com/items?itemName=ms-python.debugpy), allowing you to set breakpoints, inspect variables, and use the debug console for an in-depth look at how your program is executing step by step. Debug a number of different types of Python applications, including multi-threaded, web, and remote applications.

For more specific information on debugging in Python, such as configuring your `launch.json` settings and implementing remote debugging, see [Debugging](/docs/python/debugging.md). General VS Code debugging information is found in the [debugging document](/docs/editor/debugging.md).

Expand All @@ -93,7 +93,7 @@ The Python extension automatically detects Python interpreters that are installe

The current environment is shown on the right side of the VS Code Status Bar:

![Status Bar showing a selected interpreter](images/python/selected-interpreter-status-bar.png)
![Status Bar showing a selected interpreter](/docs/python/images/shared/environment-in-status-bar.png)

The Status Bar also indicates if no interpreter is selected:

Expand Down
Loading