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
tonghuashuai
V2EX  ›  Python

Vim 下调试的问题

  •  
  •   tonghuashuai ·
    tonghuashuai · 2013-11-30 08:44:20 +08:00 · 3539 次点击
    这是一个创建于 3793 天前的主题,其中的信息可能已经有所发展或是发生改变。
    最近在折腾 Vim 下调试,用了 vim-debug,怎么弄都不行啊,:Dbg break 以后出现

    failed to start a browser. aborting debug session

    然后再弄就是报错了:
    Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/usr/local/lib/python2.7/dist-packages/vim_debug-1.5.4-py2.7.egg/vim_deb
    ug/commands.py", line 44, in debugger_cmd
    cmd['function'](*args)
    File "/usr/local/lib/python2.7/dist-packages/vim_debug-1.5.4-py2.7.egg/vim_deb
    ug/new_debugger.py", line 207, in break_
    tid = self.bend.cid + 1
    AttributeError: Debugger instance has no attribute 'bend'

    pydbgp 没有问题,为啥这货要打开 browser 呢,我是 ssh 到 vps 上的。


    各位现在用啥调试啊?我说的是单步调试,别告诉我你们用 print……
    6 条回复    1970-01-01 08:00:00 +08:00
    likaci
        1
    likaci  
       2013-11-30 08:58:04 +08:00
    现在处理纯文本用 vim, 写东西还是用 ide + vim 插件.
    sandtears
        2
    sandtears  
       2013-11-30 10:10:28 +08:00
    .... 我觉得Print调试挺好的啊
    duhastmich
        3
    duhastmich  
       2013-11-30 10:14:30 +08:00
    https://zapier.com/engineering/debugging-python-boss/
    脚本语言print 为什么不行呢
    usoluyun
        4
    usoluyun  
       2013-11-30 22:29:48 +08:00
    尝试用过vimpdb,超级难用,要先在后台起一个vim的实例,然后才能在另一个vim里面调用。真没直接用pdb方便。
    gkiwi
        5
    gkiwi  
       2013-12-04 00:38:56 +08:00
    用下这个pudb 试试 https://github.com/inducer/pudb
    tonghuashuai
        6
    tonghuashuai  
    OP
       2013-12-04 08:53:17 +08:00
    @gkiwi
    哦,多谢
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   890 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 22:02 · PVG 06:02 · LAX 15:02 · JFK 18:02
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.