sandbox1
parent
9e9f80c313
commit
3515b3a571
|
@ -268,6 +268,7 @@ class TorrentFS(object):
|
||||||
self.save_path = localize_path(self.root.torrentParams['save_path'])
|
self.save_path = localize_path(self.root.torrentParams['save_path'])
|
||||||
self.priorities = list(self.handle.file_priorities())
|
self.priorities = list(self.handle.file_priorities())
|
||||||
self.files = self.__files_()
|
self.files = self.__files_()
|
||||||
|
self.handle.set_piece_deadline(self.files[startIndex].startPiece, 50)
|
||||||
if startIndex < 0:
|
if startIndex < 0:
|
||||||
logging.info('No -file-index specified, downloading will be paused until any file is requested')
|
logging.info('No -file-index specified, downloading will be paused until any file is requested')
|
||||||
|
|
||||||
|
@ -374,7 +375,7 @@ class TorrentFS(object):
|
||||||
tf.num = self.fileCounter
|
tf.num = self.fileCounter
|
||||||
tf.log('Opening %s...' % (tf.name,))
|
tf.log('Opening %s...' % (tf.name,))
|
||||||
tf.SetPriority(1)
|
tf.SetPriority(1)
|
||||||
self.handle.set_piece_deadline(tf.startPiece, 50)
|
#self.handle.set_piece_deadline(tf.startPiece, 50)
|
||||||
self.lastOpenedFile = tf
|
self.lastOpenedFile = tf
|
||||||
self.addOpenedFile(tf)
|
self.addOpenedFile(tf)
|
||||||
self.checkPriorities()
|
self.checkPriorities()
|
||||||
|
@ -779,14 +780,8 @@ class Pyrrent2http(object):
|
||||||
logging.info('Encryption not supported: %s' % (e.args,))
|
logging.info('Encryption not supported: %s' % (e.args,))
|
||||||
|
|
||||||
def Status(self):
|
def Status(self):
|
||||||
#try:
|
|
||||||
# info = self.torrentHandle.torrent_file()
|
|
||||||
#except:
|
|
||||||
# info = self.torrentHandle.get_torrent_info()
|
|
||||||
info = self.TorrentFS.info
|
info = self.TorrentFS.info
|
||||||
logging.info('getting status')
|
tstatus = self.torrentHandle.status()
|
||||||
tstatus = self.torrentHandle.status(0)
|
|
||||||
logging.info('status is here')
|
|
||||||
|
|
||||||
status = {
|
status = {
|
||||||
'name' : info.name(),
|
'name' : info.name(),
|
||||||
|
|
Loading…
Reference in New Issue