推荐学习书目
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
sunweiguo02
V2EX  ›  Python

使用 twilio 一直报错,求大牛们看下哪里出错了

  •  
  •   sunweiguo02 · Jan 24, 2017 · 4072 views
    This topic created in 3429 days ago, the information mentioned may be changed or developed.
    完全没有头绪是怎么回事,谷歌也没查到什么。。。。。。

    代码如下:
    from twilio.rest import TwilioRestClient

    account_sid = "AC1051ad791e2819985cbf04e********"
    auth_token = "76f04e0a842f4a1b77162345a*******"
    client = TwilioRestClient(account_sid, auth_token)

    message = client.messages.create(
    body="Hello there!",
    from_="+1414622****",
    to="+861860963****")

    print message.sid


    报错:
    Traceback (most recent call last):
    File "C:\Users\sunwe\Desktop\WorkPlace of Python\Lesson03\send_text.py", line 3, in <module>
    import twilio
    File "C:/Users/sunwe/Desktop/WorkPlace of Python/Lesson03\twilio.py", line 3, in <module>
    AttributeError: 'module' object has no attribute '__version__'
    rust
        1
    rust  
       Jan 24, 2017
    你知道为什么没有人回答你吗?

    因为 Google 一下就能得出答案
    sunweiguo02
        2
    sunweiguo02  
    OP
       Jan 24, 2017 via Android
    @rust 我就是没谷歌到才发帖,有什么问题?
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5532 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 30ms · UTC 06:58 · PVG 14:58 · LAX 23:58 · JFK 02:58
    ♥ Do have faith in what you're doing.