diff --git a/docs/dap/images/python-debugpy/set_breakpoint.png b/docs/dap/images/python-debugpy/breakpoint_hit.png similarity index 100% rename from docs/dap/images/python-debugpy/set_breakpoint.png rename to docs/dap/images/python-debugpy/breakpoint_hit.png diff --git a/docs/dap/images/python-debugpy/set_breakpoint_step_1.png b/docs/dap/images/python-debugpy/set_breakpoint_step_1.png new file mode 100644 index 000000000..651e7a219 Binary files /dev/null and b/docs/dap/images/python-debugpy/set_breakpoint_step_1.png differ diff --git a/docs/dap/images/python-debugpy/set_breakpoint_step_2.png b/docs/dap/images/python-debugpy/set_breakpoint_step_2.png new file mode 100644 index 000000000..9a6dc7d1a Binary files /dev/null and b/docs/dap/images/python-debugpy/set_breakpoint_step_2.png differ diff --git a/docs/dap/user-defined-dap/python-debugpy.md b/docs/dap/user-defined-dap/python-debugpy.md index e56103682..904d68217 100644 --- a/docs/dap/user-defined-dap/python-debugpy.md +++ b/docs/dap/user-defined-dap/python-debugpy.md @@ -13,7 +13,7 @@ if __name__ == "__main__": main() ``` -![Set Breakpoint](../images/python-debugpy/set_breakpoint.png) +![Breakpoint hit](../images/python-debugpy/breakpoint_hit.png) ## Configure DAP server @@ -105,9 +105,15 @@ in the IntelliJ console. Read [Python debugging in VS Code](https://code.visuals ## Set Breakpoint After applying the run configuration, you should set a breakpoint to files which matches file mappings. -Set a breakpoint in the `test.py` file: +Setting a breakpoint requires two steps due to the default Python Line Breakpoint type provided by PyCharm: -![Set Breakpoint](../images/python-debugpy/set_breakpoint.png) +Step 1: Click on the line number in the gutter where you want the breakpoint to set a Python Breakpoint +![Set Breakpoint Step 1](../images/python-debugpy/set_breakpoint_step_1.png) + +Step 2: Click on the faded red dot next to the code on the same line to create a **DAP Breakpoint** +![Set Breakpoint Step 2](../images/python-debugpy/set_breakpoint_step_2.png) + +Please note that if you only set the Python Breakpoint (step 1), then the breakpoint will not be hit. You must complete both steps. ## Start Python program in a Terminal