Hacker GitHub

← All repos

cool-RR/PySnooper

View on GitHub ↗ ★ 16,577 Python

Never use print for debugging again

10 mentions on Hacker News by 6 people: 2 stories, 8 comments · first 2019-04-22 · latest 2023-01-15

Mentions per year 10 mentions · busiest year 2019 (4)
20082026
  1. …this. For those that find this interesting, you might also like pysnooper - I use it all the time. https://github.com/cool-RR/PySnooper https://python.plainenglish.io/pysnooper-stop-debugging-pyth...
  2. …way that's as easy as adding print statements, but gives you a lot more information automatically. https://github.com/cool-RR/PySnooper/ HN thread: https://news.ycombinator.com/item?id=19717786
  3. The Python package PySnooper is pretty good for "fancy" print debug statements: https://github.com/cool-RR/pysnooper I've caught quite a few bugs using this show-me-all-locals() approach...
  4. …is a poor man's debugger. If you've used Bash, it's like set -x for Python, except it's fancier." https://github.com/cool-RR/PySnooper
  5. …total 08:46:58.742898 return 8 return total Return value:.. 579 Elapsed time: 00:00:00.000405 [1] https://github.com/cool-RR/PySnooper
  6. …function to get detailed debug info like you normally would get from a full debugger: (A) code: https://github.com/cool-RR/PySnooper (B) pypi: https://pypi.org/project/PySnooper/ (C) talk: https://www.youtube.com/watch?v=XP5imOJc_TE (D)…
    comment by ivan_ah · 2020-06-02 · in Guide to Python Debugging
  7. …"WARNING: Unusual situation: foo=foo_value, bar=bar_value" to the logs. It's so much clearer. [1] https://github.com/cool-RR/pysnooper
    comment by Grue3 · 2019-07-18 · in What's Coming in Python 3.8
  8. …new processes internally... I'm not sure. If you try it and it doesn't work, open an issue: https://github.com/cool-RR/PySnooper/issues