You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
报下面的错误:
Traceback (most recent call last):
File "../115/115.py", line 10, in
u = api.upload('/root/sh/115/115_cookies.txt')
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 306, in upload
directory = self.downloads_directory
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 214, in downloads_directory
self._load_lixian_space()
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 618, in _load_lixian_space
self._torrents_directory = self._load_directory(torrent_cid)
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 608, in _load_directory
kwargs = self._req_directory(cid)
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 511, in _req_directory
raise RequestFailure('No directory found.')
u115.api.RequestFailure: No directory found.
谢谢你写的这个代码,今天用这个代码上传东西的时候报错,下面是我的代码:
import u115
api = u115.API()
api.login('usename', 'password')
u = api.upload('/root/sh/115/115_cookies.txt')
报下面的错误:
Traceback (most recent call last):
File "../115/115.py", line 10, in
u = api.upload('/root/sh/115/115_cookies.txt')
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 306, in upload
directory = self.downloads_directory
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 214, in downloads_directory
self._load_lixian_space()
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 618, in _load_lixian_space
self._torrents_directory = self._load_directory(torrent_cid)
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 608, in _load_directory
kwargs = self._req_directory(cid)
File "/usr/local/lib/python2.7/dist-packages/u115/api.py", line 511, in _req_directory
raise RequestFailure('No directory found.')
u115.api.RequestFailure: No directory found.
不知道怎么回事?还有请问在用api.upload 函数上传文件的时候,后面的directory 要怎么写,比如我要上传文件到movie文件夹,directory要怎么写?
The text was updated successfully, but these errors were encountered: