【问题标题】:MacVim vdebug python errorMacVim vdebug python 错误
【发布时间】:2013-03-19 22:15:39
【问题描述】:

我正在尝试将vdebug 与 MacVim 和 xdebug 一起使用来调试代码。我通过自制软件安装了 MacVim 和 python,并安装了 xdebug 并与 MacGDBp 一起正常工作。

当我使用 F5 键在 vdebug 中收听并重新加载页面(xdebug 远程自动启动已打开)时,我在 vdebug quickfix 窗口中收到 python 错误:

An error occured: <type 'exceptions.ImportError'>
Traceback (most recent call last):
  File "/Users/mikedfunk/dotfiles/.vim/bundle/vdebug/plugin/python/start_vdebug.py", line 31, in run
    self.runner.run()
  File "/Users/mikedfunk/dotfiles/.vim/bundle/vdebug/plugin/python/vdebug/runner.py", line 160, in run
    self.open()
  File "/Users/mikedfunk/dotfiles/.vim/bundle/vdebug/plugin/python/vdebug/runner.py", line 74, in open
    raise e
ImportError: No module named expat; use SimpleXMLTreeBuilder instead

我已经用谷歌搜索了一段时间,但找不到有效的解决方案。有什么想法吗?

【问题讨论】:

  • 其他question/answer是这样的吗?
  • 我不知道python,但我尝试将答案一中的代码添加到runner.py。这引发了另一个错误,因为我不知道 python。我确保我用brew updatebrew upgrade 更新了所有内容。一样。我不在 CentOS 上,所以回答两个没有帮助。答案四更蟒蛇。我认为问题出在我的 python 安装上,因为这个项目有一个测试套件并且似乎对其他人有用。我尝试卸载并重新安装 python view homebrew,没有运气。

标签: python macos vim xdebug


【解决方案1】:

这对我有用!发布以防其他人有同样的问题:

https://stackoverflow.com/a/12697440/557215

在重新安装 MacVim 之前,它会暂时将 python 的自制版本链接到 mac 系统版本。现在 xdebug 可以工作了!

【讨论】:

    猜你喜欢
    • 2018-02-15
    • 1970-01-01
    • 2017-12-24
    • 2018-03-14
    • 1970-01-01
    • 2021-04-19
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多