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

用 py2app 打包 Python 项目总是报: module 'itk' has no attribute 'Image'这个错误

  •  
  •   ccking · 2018-11-19 10:03:22 +08:00 · 1753 次点击
    这是一个创建于 2227 天前的主题,其中的信息可能已经有所发展或是发生改变。

    Traceback (most recent call last): File "/Users/admin/Developer/dist/launcher.app/Contents/Resources/boot.py", line 103, in <module> _run() File "/Users/admin/Developer/dist/launcher.app/Contents/Resources/boot.py", line 82, in _run exec(compile(source, path, 'exec'), globals(), globals()) File "/Users/admin/Developer/dist/launcher.app/Contents/Resources/launcher.py", line 21, in <module> from app.main import begin File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "app/main.pyc", line 16, in <module> File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "app/defs/init.pyc", line 1, in <module> File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "app/defs/defs.pyc", line 5, in <module> File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "bmutils/utils.pyc", line 25, in <module> File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "bmutils/insighttoolkit/init.pyc", line 1, in <module> File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "bmutils/insighttoolkit/utils.pyc", line 5, in <module> File "<frozen importlib._bootstrap="">", line 971, in _find_and_load File "<frozen importlib._bootstrap="">", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656, in _load_unlocked File "<frozen importlib._bootstrap="">", line 626, in _load_backward_compatible File "bmutils/insighttoolkit/defs.pyc", line 3, in <module> File "bmutils/insighttoolkit/defs.pyc", line 4, in ItkTypes File "itkLazy.pyc", line 40, in getattribute AttributeError: module 'itk' has no attribute 'Image'</module></frozen></frozen></frozen></frozen></module></frozen></frozen></frozen></frozen></module></frozen></frozen></frozen></frozen></module></frozen></frozen></frozen></frozen></module></frozen></frozen></frozen></frozen></module></frozen></frozen></frozen></frozen></module></frozen></frozen></frozen></frozen></module></module>

    2 条回复    2018-11-21 15:48:11 +08:00
    cbiqih
        1
    cbiqih  
       2018-11-21 15:47:25 +08:00
    Traceback (most recent call last):
    File "/Users/admin/Developer/dist/launcher.app/Contents/Resources/boot.py", line 103,
    in <module> _run()
    File "/Users/admin/Developer/dist/launcher.app/Contents/Resources/boot.py", line 82,
    in _run exec(compile(source, path, 'exec'), globals(), globals())
    File "/Users/admin/Developer/dist/launcher.app/Contents/Resources/launcher.py", line 21,
    in <module> from app.main import begin
    File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load
    File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked
    File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "app/main.pyc", line 16,
    in <module> File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "app/defs/init.pyc", line 1,
    in <module> File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "app/defs/defs.pyc", line 5,
    in <module> File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "bmutils/utils.pyc", line 25,
    in <module> File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "bmutils/insighttoolkit/init.pyc", line 1,
    in <module> File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "bmutils/insighttoolkit/utils.pyc", line 5,
    in <module> File "<frozen importlib._bootstrap="">", line 971,
    in _find_and_load File "<frozen importlib._bootstrap="">", line 955,
    in _find_and_load_unlocked File "<frozen importlib._bootstrap="">", line 656,
    in _load_unlocked File "<frozen importlib._bootstrap="">", line 626,
    in _load_backward_compatible File "bmutils/insighttoolkit/defs.pyc", line 3,
    in <module> File "bmutils/insighttoolkit/defs.pyc", line 4,
    in ItkTypes File "itkLazy.pyc", line 40,
    in getattribute AttributeError: module 'itk' has no attribute 'Image'
    cbiqih
        2
    cbiqih  
       2018-11-21 15:48:11 +08:00
    帮楼主左下格式化
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   5779 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 34ms · UTC 01:46 · PVG 09:46 · LAX 17:46 · JFK 20:46
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.