“Mac OS X 10.9.5 + pypy 2.6上没有名为_vmprof的模块”错误

时间:2015-07-21 08:10:53

标签: pypy

我从这里复制了这个问题,希望有更多的知名度,谢谢:) https://github.com/vmprof/vmprof-python/issues/24

大家好, 我跑的时候

#pypy -m vmprof test.py
No module named _vmprof; 'vmprof' is a package and cannot be directly executed

另一个案例:

#vmprofshow 
Traceback (most recent call last):
  File "<builtin>/app_main.py", line 75, in run_toplevel
  File "/vmprofshow", line 9, in <module>
    load_entry_point('vmprof==0.1.3', 'console_scripts', 'vmprofshow')()
  File "/site-packages/pkg_resources.py", line 352, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/site-packages/pkg_resources.py", line 2307, in load_entry_point
    return ep.load()
  File "/site-packages/pkg_resources.py", line 2021, in load
    entry = __import__(self.module_name, globals(),globals(), ['__name__'])
  File "/site-packages/vmprof/__init__.py", line 7, in <module>
    import _vmprof
ImportError: No module named _vmprof

我的环境:

  • mac os x 10.9.5
  • pypy 2.6

非常感谢:)

1 个答案:

答案 0 :(得分:2)

关于PyPy的vmprof现在只在64位Linux上启用。 https://vmprof.readthedocs.org/en/latest/的文档具有误导性:OS / X或FreeBSD上的vmprof测试版仅适用于CPython,不适用于PyPy。