django import ipdb; ipdb.set_trace(); still want to run debugger even if commented. WHY?

StackOverflow https://stackoverflow.com/questions/23386550

  •  12-07-2023
  •  | 
  •  

سؤال

Ihave problem with IPDB. I comment out it after I do not use it but after I run the web page after single refresh the debbuger is fired anyway. I have to referesh at least two times or so, to force django not willing going into debugging.

additionally I am expiriencing extremlly often error: [Errno 32] Broken pipe

(if it matters I am running it in vagrant based vm)

هل كانت مفيدة؟

المحلول

I'd ensure I've killed the runserver/gunicorn and restarted it cleanly, to ensure there are no threads that are still running ipdb. (if you're using django-devserver, for instance, that's multi-threaded)

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top