yunpian / yunpian-python-sdk Goto Github PK
View Code? Open in Web Editor NEWThe https://www.yunpian.com python sdk.
License: MIT License
The https://www.yunpian.com python sdk.
License: MIT License
ImportError: No module named 'lib' python3.5报错
你们的SDK里有重试机制,但是我遇到了一个情况,就是第一次请求超时了,这时候就会重试,发送第二次请求,但是第一次请求服务器已经处理了,只是返回超时了,于是第二次请求就报错了,实际情况如下!
如题,如果支持的话,能提供例子吗,谢谢!
安装 yunpian-sdk-python
及其依赖 requests
后尝试使用 Python 2 运行 README.md 中的示例代码出错如下:
root [ / ] # python2 test.py
Traceback (most recent call last):
File "test.py", line 4, in <module>
from lib.DES import DES
ImportError: No module named lib.DES
观察文件前部:
root [ / ] ! cat test.py
# -*- coding:utf-8 -*-
# filename:TestPost
#16/1/20 下午4:01
from lib.DES import DES
__author__ = 'bingone'
from lib.SmsOperator import SmsOperator
from lib.VoiceOperator import VoiceOperator
from lib.TplOperator import TplOperator
from lib.UserOperator import UserOperator
from lib.FlowOperator import FlowOperator
from lib.Tea import Tea
此处的 import 是否正确使用?因为查看包内内容,模块是以如下结构安装的:
root [ / ] # dpkg -L yunpian-sdk-python | grep DES
/usr/lib/python2.7/site-packages/yunpian/DES.py
/usr/lib/python2.7/site-packages/yunpian/DES.pyc
/usr/lib/python2.7/site-packages/yunpian/DES.pyo
望指点……
怎么不标明支持python的版本
RT
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.