r351 - in /debtorrent/trunk: DebTorrent/BT1/makemetafile.py DebTorrent/download_bt1.py debtorrent-client.conf
camrdale-guest at users.alioth.debian.org
camrdale-guest at users.alioth.debian.org
Thu Jan 24 01:11:41 UTC 2008
Author: camrdale-guest
Date: Thu Jan 24 01:11:41 2008
New Revision: 351
URL: http://svn.debian.org/wsvn/debtorrent/?sc=1&rev=351
Log:
Dont download piece ordering info if separate_all is 0.
Modified:
debtorrent/trunk/DebTorrent/BT1/makemetafile.py
debtorrent/trunk/DebTorrent/download_bt1.py
debtorrent/trunk/debtorrent-client.conf
Modified: debtorrent/trunk/DebTorrent/BT1/makemetafile.py
URL: http://svn.debian.org/wsvn/debtorrent/debtorrent/trunk/DebTorrent/BT1/makemetafile.py?rev=351&op=diff
==============================================================================
--- debtorrent/trunk/DebTorrent/BT1/makemetafile.py (original)
+++ debtorrent/trunk/DebTorrent/BT1/makemetafile.py Thu Jan 24 01:11:41 2008
@@ -687,12 +687,14 @@
sub_pieces = getsubpieces(file, pieces_file)
- (piece_ordering, ordering_headers) = getordering(file, torrent_file)
+ piece_ordering_all = {}
+ ordering_all_headers = {}
+ piece_ordering = {}
+ ordering_headers = {}
if separate_all:
- (piece_ordering_all, ordering_all_headers) = getordering(file, torrent_all_file, True)
- else:
- piece_ordering_all = {}
- ordering_all_headers = {}
+ (piece_ordering, ordering_headers) = getordering(file, torrent_file)
+ if separate_all in [1, 3]:
+ (piece_ordering_all, ordering_all_headers) = getordering(file, torrent_all_file, True)
file = abspath(file)
if file.endswith('.gz'):
@@ -835,12 +837,14 @@
try:
sub_pieces = getsubpieces('_'.join(self.path))
- (piece_ordering, ordering_headers) = getordering('_'.join(self.path))
- if self.config['separate_all']:
- (piece_ordering_all, ordering_all_headers) = getordering('_'.join(self.path), all = True)
- else:
- piece_ordering_all = {}
- ordering_all_headers = {}
+ piece_ordering_all = {}
+ ordering_all_headers = {}
+ piece_ordering = {}
+ ordering_headers = {}
+ if separate_all:
+ (piece_ordering, ordering_headers) = getordering('_'.join(self.path))
+ if separate_all in [1, 3]:
+ (piece_ordering_all, ordering_all_headers) = getordering('_'.join(self.path), all = True)
(info, info_all) = getpieces(h, separate_all = self.config['separate_all'],
sub_pieces = sub_pieces,
Modified: debtorrent/trunk/DebTorrent/download_bt1.py
URL: http://svn.debian.org/wsvn/debtorrent/debtorrent/trunk/DebTorrent/download_bt1.py?rev=351&op=diff
==============================================================================
--- debtorrent/trunk/DebTorrent/download_bt1.py (original)
+++ debtorrent/trunk/DebTorrent/download_bt1.py Thu Jan 24 01:11:41 2008
@@ -429,12 +429,14 @@
sub_pieces = getsubpieces(name)
- (piece_ordering, ordering_headers) = getordering(name)
+ piece_ordering_all = {}
+ ordering_all_headers = {}
+ piece_ordering = {}
+ ordering_headers = {}
if separate_all:
- (piece_ordering_all, ordering_all_headers) = getordering(name, all = True)
- else:
- piece_ordering_all = {}
- ordering_all_headers = {}
+ (piece_ordering, ordering_headers) = getordering(name)
+ if separate_all in [1, 3]:
+ (piece_ordering_all, ordering_all_headers) = getordering(name, all = True)
(info, info_all) = getpieces(h, separate_all = separate_all, sub_pieces = sub_pieces,
piece_ordering = piece_ordering,
Modified: debtorrent/trunk/debtorrent-client.conf
URL: http://svn.debian.org/wsvn/debtorrent/debtorrent/trunk/debtorrent-client.conf?rev=351&op=diff
==============================================================================
--- debtorrent/trunk/debtorrent-client.conf (original)
+++ debtorrent/trunk/debtorrent-client.conf Thu Jan 24 01:11:41 2008
@@ -457,8 +457,15 @@
# 2 -- Separate, and run the non-architecture:all torrent
# 3 -- Separate, and run both torrents
#
-
-# separate_all = 0
+# WARNING: Using 0 will cause your torrent to be different from all peers
+# using the default of 3, which will make it difficult to find peers.
+# On testing/unstable, it will also prevent the use of unique piece
+# numbers to create a longer-lived torrent.
+# Using 1 or 2 will prevent DebTorrent from downloading some files
+# (architecture:all files for 2, non-architecture:all files for 1).
+# In other words, you probably want to leave this at the default.
+
+# separate_all = 3
###############################################################################
# E N D O F N O R M A L O P T I O N S
More information about the Debtorrent-commits
mailing list