Skip to content

Commit

Permalink
Merge pull request #1 from gitaarik/master
Browse files Browse the repository at this point in the history
fixed runserver --ipdb for latest ipdb version
  • Loading branch information
stuaxo authored Dec 5, 2023
2 parents 8f57b2c + a52f924 commit 21dfc04
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions django_pdb/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,11 @@ def has_ipdb():


def get_ipdb():
def_colors = get_def_colors()
try:
import ipdb
from ipdb import __main__
return ipdb.__main__.Pdb(def_colors)
import ipdb.__main__
return ipdb.__main__._init_pdb()
except ImportError: # old versions of ipdb
return ipdb.Pdb(def_colors)
return ipdb.Pdb(get_def_colors())


def get_pdb_set_trace():
Expand Down

0 comments on commit 21dfc04

Please sign in to comment.