cannot import ipykernel debugger in Pycharm debug mode

Open
#983 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
jupyter, python
Domain
devtools

Research direction

Reproduce the imports in PyCharm debug mode using the reported Python 3.9 environment, starting with debugpy/_vendored/force_pydevd.py and the ipykernel.debugger import. Trace the incompatible pydevd warning and ImportError; done means Debugger imports successfully in that mode without the pydevd_defaults failure.

Written by the indexing model from the issue text.

Description

when execute

import debugpy
from ipykernel.debugger import Debugger

in pycharm debug mode, result in ImportError: cannot import name 'pydevd_defaults' from '_pydevd_bundle'

and an more specfic notice is :

/Users/suoyi/miniforge3/envs/aicoder/lib/python3.9/site-packages/debugpy/_vendored/force_pydevd.py:20: UserWarning: incompatible copy of pydevd already imported

Dominant language
Python
Stars
734
Forks
411
Avg merge
1d 2h
Merged PRs (30d)
9

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ipython/ipykernel

All issues in ipython/ipykernel

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.