Skip to content
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

Update branch for debugpy 1.5.1 with last changes in main #124

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
9991e78
update pre release (#71)
paulacamargo25 Jul 28, 2023
117bc23
Add port provider (#85)
paulacamargo25 Sep 18, 2023
d73a20e
Add global configuration for justMyCode (#91)
paulacamargo25 Sep 25, 2023
77e97c9
Update extension name (#84)
paulacamargo25 Sep 25, 2023
ebab1f4
use version 1.7 (#95)
paulacamargo25 Sep 26, 2023
d2a7cb4
Remove default justMyCode (#100)
paulacamargo25 Sep 27, 2023
422bec7
Fix error in workspace (#101)
paulacamargo25 Sep 27, 2023
7815c67
Bump mheap/github-action-required-labels from 3 to 5 (#23)
dependabot[bot] Oct 3, 2023
5a5d700
Bump @typescript-eslint/parser from 5.59.11 to 5.62.0 (#61)
dependabot[bot] Oct 3, 2023
546cd93
Bump typescript from 5.1.3 to 5.2.2 (#79)
dependabot[bot] Oct 3, 2023
df90d43
Update npm packages (#105)
paulacamargo25 Oct 4, 2023
224bc8f
Update to node 18 (#106)
paulacamargo25 Oct 10, 2023
ec9e135
Platform-specific vsix (#89)
paulacamargo25 Oct 18, 2023
616f92e
Fix GDPR comments (#113)
lramos15 Oct 20, 2023
72efd8e
Update readme (#111)
paulacamargo25 Oct 23, 2023
3a55036
Remove build folder from bundled vsix (#120)
DonJayamanne Oct 26, 2023
0203bc8
Update debugpy version
paulacamargo25 Jul 28, 2023
92d65af
Update nox and pipelines
paulacamargo25 Jul 28, 2023
08cae80
update json file
paulacamargo25 Nov 1, 2023
8ddd17d
fix actions
paulacamargo25 Nov 1, 2023
1fe2017
fix 3.6 error
paulacamargo25 Nov 1, 2023
1d7f338
fix error running with 3.6
paulacamargo25 Nov 1, 2023
d1ed3cb
fix lint
paulacamargo25 Nov 1, 2023
441b7ce
update python version
paulacamargo25 Nov 2, 2023
cca7487
fix error in lint pipeline
paulacamargo25 Nov 2, 2023
6bda57e
update pipelines
paulacamargo25 Nov 2, 2023
12eb6ed
fix nox file
paulacamargo25 Nov 2, 2023
4fa43cb
fix tests
paulacamargo25 Nov 2, 2023
eac8810
fix pipeline error
paulacamargo25 Nov 22, 2023
6d05e53
fix lint
paulacamargo25 Nov 22, 2023
bfb007b
use python 3.6
paulacamargo25 Nov 23, 2023
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
13 changes: 6 additions & 7 deletions .github/actions/build-vsix/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,10 @@ runs:
node-version: ${{ inputs.node_version }}
cache: 'npm'

# Minimum supported version is Python 3.7
- name: Use Python 3.7
- name: Use Python 3.6
uses: actions/setup-python@v4
with:
python-version: 3.7
python-version: 3.6

- name: Pip cache
uses: actions/cache@v3
Expand All @@ -30,23 +29,23 @@ runs:
${{ runner.os }}-pip-build-vsix-

# For faster/better builds of sdists.
- name: Update pip, install pipx and install wheel
run: python -m pip install -U pip pipx wheel
- name: Update pip, install nox and install wheel
run: python -m pip install -U pip nox wheel
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is wheel installed?

And GitHub Actions includes pipx by default, so you should be able to skip installing both Nox and pipx and use pipx run nox.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed pipx because I got an error using python 3.6

shell: bash

- name: Run npm ci
run: npm ci --prefer-offline
shell: bash

- name: Install bundled python libraries
run: pipx run nox --session install_old_bundled_libs
run: python -m nox --session install_bundled_libs
shell: bash

# Use the GITHUB_RUN_ID environment variable to update the build number.
# GITHUB_RUN_ID is a unique number for each run within a repository.
# This number does not change if you re-run the workflow run.
- name: Update extension build number
run: pipx run nox --session update_build_number -- $GITHUB_RUN_ID
run: python -m nox --session update_build_number -- $GITHUB_RUN_ID
shell: bash

- name: Build VSIX
Expand Down
8 changes: 4 additions & 4 deletions .github/actions/lint/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,15 @@ runs:
${{ runner.os }}-pip-lint-

# For faster/better builds of sdists.
- name: Update pip, install pipx and install wheel
run: python -m pip install -U pip pipx wheel
- name: Update pip, install nox and install wheel
run: python -m pip install -U pip nox wheel
Comment on lines +44 to +45
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See my comments on the other action.

shell: bash

# This will install libraries to a target directory.
- name: Install bundled python libraries
run: pipx run nox --session install_old_bundled_libs
run: python -m nox --session install_bundled_libs
shell: bash

- name: Check linting and formatting
run: pipx run nox --session lint
run: python -m nox --session lint
shell: bash
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ on:
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
permissions:
actions: read
contents: read
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/issue-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
# From https://github.com/marketplace/actions/github-script#apply-a-label-to-an-issue.
add-triage-label:
name: "Add 'triage-needed'"
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- uses: actions/github-script@v6
with:
Expand Down
27 changes: 13 additions & 14 deletions .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
pull_request:

env:
NODE_VERSION: 16.17.0
NODE_VERSION: 18.17.1
TEST_RESULTS_DIRECTORY: .
# Force a path with spaces and unicode chars to test extension works in these scenarios
special-working-directory: './🐍 🐛'
Expand All @@ -13,7 +13,7 @@ env:
jobs:
build-vsix:
name: Create VSIX
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -25,7 +25,7 @@ jobs:

lint:
name: Lint
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -44,7 +44,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-20.04, windows-latest]
python: ['3.6']

steps:
Expand All @@ -53,19 +53,18 @@ jobs:
with:
path: ${{ env.special-working-directory-relative }}

# Install bundled libs using 3.6 even though you test it on other versions.
- name: Use Python 3.6
uses: actions/setup-python@v4
uses: actions/setup-python@v3
with:
python-version: '3.6'

- name: Update pip, install pipx and install wheel
run: python -m pip install -U pip pipx wheel
- name: Update pip, install nox and install wheel
run: python -m pip install -U pip nox wheel
shell: bash

# This will install libraries to a target directory.
- name: Install bundled python libraries
run: pipx run nox --session install_old_bundled_libs
run: python -m nox --session install_bundled_libs
shell: bash

- name: Install Node
Expand All @@ -78,16 +77,16 @@ jobs:
- name: Install dependencies (npm ci)
run: npm ci

# Now that the bundle is installed to target using python 3.7
# Now that the bundle is installed to target using python 3.6
# switch back the python we want to test with
- name: Use Python ${{ matrix.python }}
uses: actions/setup-python@v4
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python }}

# The new python may not have nox so install it again
- name: Update pip, install pipx and install wheel (again)
run: python -m pip install -U pip pipx wheel
- name: Update pip, install nox and install wheel (again)
run: python -m pip install -U pip nox wheel
shell: bash

- name: Start xvfb on Linux
Expand All @@ -98,7 +97,7 @@ jobs:
if: ${{ runner.os }} == 'Linux'

- name: Run tests
run: pipx run nox --session tests
run: python -m nox --session tests
shell: bash
env:
DISPLAY: ${{ env.DISPLAY }}
4 changes: 2 additions & 2 deletions .github/workflows/pr-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ on:
jobs:
add-pr-label:
name: 'Ensure Required Labels'
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: 'PR impact specified'
uses: mheap/github-action-required-labels@v3
uses: mheap/github-action-required-labels@v5
with:
mode: exactly
count: 1
Expand Down
27 changes: 13 additions & 14 deletions .github/workflows/push-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
- 'release-*'

env:
NODE_VERSION: 16.17.0
NODE_VERSION: 18.17.1
TEST_RESULTS_DIRECTORY: .
# Force a path with spaces and unicode chars to test extension works in these scenarios
special-working-directory: './🐍 🐛'
Expand All @@ -18,7 +18,7 @@ env:
jobs:
build-vsix:
name: Create VSIX
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -30,7 +30,7 @@ jobs:

lint:
name: Lint
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -49,7 +49,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
os: [ubuntu-20.04, windows-latest]
python: ['3.6']

steps:
Expand All @@ -58,19 +58,18 @@ jobs:
with:
path: ${{ env.special-working-directory-relative }}

# Install bundled libs using 3.6 even though you test it on other versions.
- name: Use Python 3.6
uses: actions/setup-python@v4
uses: actions/setup-python@v3
with:
python-version: '3.6'

- name: Update pip, install pipx and install wheel
run: python -m pip install -U pip pipx wheel
- name: Update pip, install nox and install wheel
run: python -m pip install -U pip nox wheel
shell: bash

# This will install libraries to a target directory.
- name: Install bundled python libraries
run: pipx run nox --session install_old_bundled_libs
run: python -m nox --session install_bundled_libs
shell: bash

- name: Install Node
Expand All @@ -83,16 +82,16 @@ jobs:
- name: Install dependencies (npm ci)
run: npm ci

# Now that the bundle is installed to target using python 3.7
# Now that the bundle is installed to target using python 3.6
# switch back the python we want to test with
- name: Use Python ${{ matrix.python }}
uses: actions/setup-python@v4
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python }}

# The new python may not have nox so install it again
- name: Update pip, install pipx and install wheel (again)
run: python -m pip install -U pip pipx wheel
- name: Update pip, install nox and install wheel (again)
run: python -m pip install -U pip nox wheel
shell: bash

- name: Start xvfb on Linux
Expand All @@ -103,5 +102,5 @@ jobs:
if: ${{ runner.os }} == 'Linux'

- name: Run tests
run: pipx run nox --session tests
run: python -m nox --session tests
shell: bash
3 changes: 2 additions & 1 deletion .vscodeignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.vscode/**
.vscode-test/**
build/**
out/**
node_modules/**
src/**
Expand All @@ -20,4 +21,4 @@ noxfile.py
.pytest_cache/**
.pylintrc
**/requirements.txt
**/requirements.in
**/requirements.in
30 changes: 21 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,37 @@
# Debugpy extension for Visual Studio Code
# Python Debugger extension for Visual Studio Code

A [Visual Studio Code](https://code.visualstudio.com/) [extension](https://marketplace.visualstudio.com/VSCode) that supports Python debugging with debugpy. debugpy provides a seamless debugging experience by allowing you to set breakpoints, step through code, inspect variables, and perform other essential debugging tasks. The debugy extension offers debugging support for various types of Python applications including scripts, web applications, remote processes, and multi-threaded processes.
A [Visual Studio Code](https://code.visualstudio.com/) [extension](https://marketplace.visualstudio.com/VSCode) that supports Python debugging with debugpy. Python Debugger provides a seamless debugging experience by allowing you to set breakpoints, step through code, inspect variables, and perform other essential debugging tasks. The debugy extension offers debugging support for various types of Python applications including scripts, web applications, remote processes, and multi-threaded processes.

Note:
- The Python extension offers the debugpy extension as an optional installation, including it during the setup process.
- The Python extension offers the python debugger extension as an optional installation, including it during the setup process.
- This extension is supported for all [actively supported versions](https://devguide.python.org/#status-of-python-branches) of the Python language (i.e., Python >= 3.7).


## Purpose

The main intent of this extension is to offer:

1. **Independence and Compatibility:** The Python Debugger extension aims to separate the debugging functionality from the main Python extension to prevent compatibility issues. This ensures that even as the Python extension drops support for older Python versions (e.g., Python 3.7), you can continue debugging projects with those versions without downgrading your Python extension. This allows you to access new features and bug fixes while keeping your debugging capabilities intact.

2. **Platform-Specific Builds:** Unlike the main Python extension, which bundles all debugpy builds for various platforms into a single extension package, the Python Debugger extension provides a more streamlined approach: it delivers platform-specific builds, ensuring you only receive the components relevant to your specific operating system. This reduces download times and unnecessary overhead.

3. **Feature Parity and Ongoing Updates:** This extension replicates all the functionality available in the main Python extension, and more. Going forward, any new debugger features will be added to this extension. In the future, the Python extension will no longer offer debugging support on its own, and we will transition all debugging support to this extension for all debugging functionality.


## Usage

Once installed in Visual Studio Code, debugpy will be automatically activated when you open a Python file.
Once installed in Visual Studio Code, python-debugger will be automatically activated when you open a Python file.

## Disabling the Debugpy extension
If you want to disable the Debugpy extension, you can [disable this extension](https://code.visualstudio.com/docs/editor/extension-marketplace#_disable-an-extension) per workspace in Visual Studio Code.
## Disabling the Python Debugger extension
If you want to disable the Python Debugger extension, you can [disable this extension](https://code.visualstudio.com/docs/editor/extension-marketplace#_disable-an-extension) per workspace in Visual Studio Code.

## Commands

| Command | Description |
| ---------------------- | --------------------------------- |
| Debugpy: viewOutput | Show the debugpy extension output. |
| Debugpy: clearCacheAndReload | Allows you to clear the global values set in the extension. |
| Debugpy: debugInTerminal | Allows you to debug a simple Python file in the terminal. |
| Python Debugger: viewOutput | Show the Python Debugger Extension output. |
| Python Debugger: clearCacheAndReload | Allows you to clear the global values set in the extension. |
| Python Debugger: debugInTerminal | Allows you to debug a simple Python file in the terminal. |

## Data and telemetry
The Debubpy Extension for Visual Studio Code collects usage data and sends it to Microsoft to help improve our products and services. Read our [privacy statement](https://privacy.microsoft.com/privacystatement) to learn more. This extension respects the `telemetry.enableTelemetry` setting which you can learn more about at https://code.visualstudio.com/docs/supporting/faq#_how-to-disable-telemetry-reporting.
40 changes: 33 additions & 7 deletions build/azure-pipeline.pre-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,36 @@ extends:
template: azure-pipelines/extension/pre-release.yml@templates
parameters:
l10nSourcePaths: ./src
buildPlatforms:
- name: Linux
packageArch: arm64
vsceTarget: linux-arm64
- name: Linux
packageArch: arm
vsceTarget: linux-armhf
- name: Linux
packageArch: x64
vsceTarget: linux-x64
- name: MacOS
packageArch: arm64
vsceTarget: darwin-arm64
- name: MacOS
packageArch: x64
vsceTarget: darwin-x64
- name: Windows
packageArch: arm
vsceTarget: win32-arm64
- name: Windows
packageArch: ia32
vsceTarget: win32-ia32
- name: Windows
packageArch: x64
vsceTarget: win32-x64

buildSteps:
- task: NodeTool@0
inputs:
versionSpec: '16.17.1'
versionSpec: '18.17.1'
displayName: Select Node version

- task: UsePythonVersion@0
Expand All @@ -47,14 +73,14 @@ extends:
- script: python -m pip install -U pip
displayName: Upgrade pip

- script: python -m pip install wheel
displayName: Install wheel

- script: python -m pip install nox
displayName: Install wheel
- script: python -m pip install wheel nox
displayName: Install wheel and nox

- script: python -m nox --session install_old_bundled_libs
# update according packageArch
- script: python -m nox --session install_bundled_libs
displayName: Install Python dependencies
env:
VSCETARGET: ${{ variables.VSCETARGET }}

- script: python ./build/update_ext_version.py --for-publishing
displayName: Update build number
Expand Down
Loading
Loading