`distutils` is deprecated and removed in Python 3.12
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
Research direction
Start with setup.py and inspect the listed distutils references under src/debugpy/_vendored/pydevd, including its setup and build files and the version/inputhook modules. Check the affected paths under Python 3.12 and determine which references are active runtime or build dependencies. Done means the relevant distutils uses no longer block supported setup or execution paths.
Written by the indexing model from the issue text.
Description
setup.py currently falls back to distutils if versioneer does not provide the required "build" command:
https://github.com/microsoft/debugpy/blob/fb6158a059bcc6a0391eb0f670d5885d664c102d/setup.py#L62-L65
But distutils no longer exists in Python 3.12, so this code needs to be updated: either versioneer always provides this, in which case the try/except is unnecessary, or it doesn't, in which case the distutils call needs to be replaced.
There are also calls to distutils in several places in the vendored pydevd, some of which may be important to fix; an rgrep gives these occurrences:
src/debugpy/_vendored/pydevd/setup.py:from distutils.extension import Extension
src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_evaluator.c: "distutils": {
src/debugpy/_vendored/pydevd/pydev_ipython/inputhook.py: from distutils.version import LooseVersion as V
src/debugpy/_vendored/pydevd/pydev_ipython/version.py:from distutils.version import LooseVersion
src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_cython.c: "distutils": {
src/debugpy/_vendored/pydevd/setup_pydevd_cython.py: from distutils.extension import Extension
src/debugpy/_vendored/pydevd/build_tools/build.py: from distutils import msvc9compiler
- Dominant language
- Python
- Stars
- 2.5k
- Forks
- 202
- Avg merge
- 5d 1h
- Merged PRs (30d)
- 1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/debugpy
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
All issues in microsoft/debugpy
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
xinnan-tech/xiaozhi-fde-talk#263 ·
-
rules
Difficulty 1/5 Under an hour Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
huggingface/Repo2RLEnv#163 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 95/100
huggingface/sentence-transformers#4074 ·
-
comp/dashboard invalid P3
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
NousResearch/hermes-agent#121143 ·