V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
pc10201
V2EX  ›  Python

求 python 中能监控所有变量的值的所有变化的模块?

  •  
  •   pc10201 · 2014-02-17 15:53:00 +08:00 · 7038 次点击
    这是一个创建于 3692 天前的主题,其中的信息可能已经有所发展或是发生改变。
    用python写程序
    业务逻辑有点复杂,变量一堆,感觉用pdb调试太慢而且太麻烦~

    有没有一个模块能监控所有变量的值的所有变化,甚至能监测到跳转到哪个函数?
    第 1 条附言  ·  2014-02-18 13:55:18 +08:00
    4 条回复    1970-01-01 08:00:00 +08:00
    ritksm
        1
    ritksm  
       2014-02-17 16:17:42 +08:00
    PyCharm调试很爽
    mengzhuo
        2
    mengzhuo  
       2014-02-17 16:26:40 +08:00
    不喜欢IDE的
    可以用ipdb,直接输入变量名查看。
    locals(), globals()两个函数,查看所有变量
    traceback模块中的print_stack(),查看call stack
    wolegequ
        3
    wolegequ  
       2014-02-17 18:57:23 +08:00
    围观
    chevalier
        4
    chevalier  
       2014-02-18 14:09:29 +08:00
    马克
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3168 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 12:24 · PVG 20:24 · LAX 05:24 · JFK 08:24
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.