SkyLothar / flask-wechat

超轻量的 微信 公告号/企业号 Blueprint
5 stars 3 forks source link

Pip install ImportError: No module named messages #2

Open ghost opened 8 years ago

ghost commented 8 years ago

当你从pip install,

$ pip install --upgrade flask-wechat
Requirement already up-to-date: flask-wechat in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages
Requirement already up-to-date: requests==2.9.1 in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages (from flask-wechat)
Requirement already up-to-date: Flask==0.10.1 in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages (from flask-wechat)
Requirement already up-to-date: itsdangerous>=0.21 in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages (from Flask==0.10.1->flask-wechat)
Requirement already up-to-date: Werkzeug>=0.7 in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages (from Flask==0.10.1->flask-wechat)
Requirement already up-to-date: Jinja2>=2.4 in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages (from Flask==0.10.1->flask-wechat)
Requirement already up-to-date: MarkupSafe in /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages (from Jinja2>=2.4->Flask==0.10.1->flask-wechat)

Runing:

 python application.py
Traceback (most recent call last):
  File "application.py", line 2, in <module>
    from flask.ext.wechat import WeChat, filters
  File "/Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages/flask/exthook.py", line 81, in load_module
    reraise(exc_type, exc_value, tb.tb_next)
  File "/Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages/flask_wechat/__init__.py", line 9, in <module>
    from .filters import all as filter_all
  File "/Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages/flask_wechat/filters.py", line 5, in <module>
    from .messages import WeChatRequest
ImportError: No module named messages
$ ls /Users/vng/Dropbox/Code/Paw/venv/lib/python2.7/site-packages/flask_wechat/
__init__.py   __init__.pyc  apiclient.py  apiclient.pyc callback.py   callback.pyc  filters.py    filters.pyc   signals.py    signals.pyc

No messages.py found in the directory. Any ideas?

SkyLothar commented 8 years ago

hmm...似乎pip上的版本有问题... 多些支持... 我会补上示例

ykbj commented 8 years ago

我也遇到了这个问题,怎么破?

SkyLothar commented 8 years ago

...pypi上的flask-wechat 不是我这个 我的包在pip上的名字叫 flask-wechat-kit 建议你从github安装或者 pip install flask-wechat-kit