iambus/xunlei-lixian — Issue #19: bt下载完成以后校验出错
Author: turygo
Created: 2011-12-16 06:14:31+00:00
State: open

Hashing bt ...
Traceback (most recent call last):
File "lx", line 738, in
execute_command()
File "lx", line 735, in execute_command
commands[command](args[1:])
File "lx", line 471, in download_task
download_multiple_tasks(client, download, tasks, **download_args)
File "lx", line 327, in download_multiple_tasks
download_single_task(client, download, task, output_dir=output_dir, delete=d
elete, resuming=resuming, overwrite=overwrite, mini_hash=mini_hash)
File "lx", line 310, in download_single_task
verified = lixian_hash_bt.verify_bt(filename, lixian_hash_bt.bdecode(torrent
_file)['info'], file_set=file_set, progress_callback=bar.update)
File "/thunder/lixian_hash_bt.py", line 219, in verify_bt
return verify_bt_multiple(path, info, file_set=file_set, progress_callback=p
rogress_callback)
File "/thunder/lixian_hash_bt.py", line 179, in verify_bt_multiple
if sha1sum.digest() != sha1_stream.next_sha1() and complete_piece:
File "/thunder/lixian_hash_bt.py", line 111, in next_sha1
self.progress_callback(float(self.processed)/self.total)
File "lx", line 228, in update
bar = '{:>3}%[{:<40}]'.format(percent, bar)
ValueError: zero length field name in format

运行环境是python 2.6.4-3