diff --git a/herd/BitTornado/BT1/Choker.py b/herd/BitTornado/BT1/Choker.py index 3ad589d..f4d3e04 100644 --- a/herd/BitTornado/BT1/Choker.py +++ b/herd/BitTornado/BT1/Choker.py @@ -2,7 +2,7 @@ # see LICENSE.txt for license information from random import randrange, shuffle -from herd.BitTornado.clock import clock +from .. clock import clock try: True except: diff --git a/herd/BitTornado/BT1/Connecter.py b/herd/BitTornado/BT1/Connecter.py index 703b45f..f87ab07 100644 --- a/herd/BitTornado/BT1/Connecter.py +++ b/herd/BitTornado/BT1/Connecter.py @@ -1,8 +1,8 @@ # Written by Bram Cohen # see LICENSE.txt for license information -from herd.BitTornado.bitfield import Bitfield -from herd.BitTornado.clock import clock +from .. bitfield import Bitfield +from .. clock import clock from binascii import b2a_hex try: diff --git a/herd/BitTornado/BT1/Downloader.py b/herd/BitTornado/BT1/Downloader.py index 3266c5d..11b68eb 100644 --- a/herd/BitTornado/BT1/Downloader.py +++ b/herd/BitTornado/BT1/Downloader.py @@ -1,10 +1,10 @@ # Written by Bram Cohen # see LICENSE.txt for license information -from herd.BitTornado.CurrentRateMeasure import Measure -from herd.BitTornado.bitfield import Bitfield +from .. CurrentRateMeasure import Measure +from .. bitfield import Bitfield from random import shuffle -from herd.BitTornado.clock import clock +from .. clock import clock try: True except: diff --git a/herd/BitTornado/BT1/HTTPDownloader.py b/herd/BitTornado/BT1/HTTPDownloader.py index 33bcb90..ae3e116 100644 --- a/herd/BitTornado/BT1/HTTPDownloader.py +++ b/herd/BitTornado/BT1/HTTPDownloader.py @@ -1,13 +1,13 @@ # Written by John Hoffman # see LICENSE.txt for license information -from herd.BitTornado.CurrentRateMeasure import Measure +from .. CurrentRateMeasure import Measure from random import randint from urlparse import urlparse from httplib import HTTPConnection from urllib import quote from threading import Thread -from herd.BitTornado.__init__ import product_name,version_short +from .. __init__ import product_name,version_short try: True except: diff --git a/herd/BitTornado/BT1/PiecePicker.py b/herd/BitTornado/BT1/PiecePicker.py index d2752c8..7264d8a 100644 --- a/herd/BitTornado/BT1/PiecePicker.py +++ b/herd/BitTornado/BT1/PiecePicker.py @@ -2,7 +2,7 @@ # see LICENSE.txt for license information from random import randrange, shuffle -from herd.BitTornado.clock import clock +from .. clock import clock try: True except: diff --git a/herd/BitTornado/BT1/Rerequester.py b/herd/BitTornado/BT1/Rerequester.py index 540c9d0..b11d010 100644 --- a/herd/BitTornado/BT1/Rerequester.py +++ b/herd/BitTornado/BT1/Rerequester.py @@ -2,11 +2,11 @@ # modified for multitracker operation by John Hoffman # see LICENSE.txt for license information -from herd.BitTornado.zurllib import urlopen, quote +from .. zurllib import urlopen, quote from urlparse import urlparse, urlunparse from socket import gethostbyname from btformats import check_peers -from herd.BitTornado.bencode import bdecode +from .. bencode import bdecode from threading import Thread, Lock from cStringIO import StringIO from traceback import print_exc diff --git a/herd/BitTornado/BT1/Storage.py b/herd/BitTornado/BT1/Storage.py index fd02129..5f84f7a 100644 --- a/herd/BitTornado/BT1/Storage.py +++ b/herd/BitTornado/BT1/Storage.py @@ -1,7 +1,7 @@ # Written by Bram Cohen # see LICENSE.txt for license information -from herd.BitTornado.piecebuffer import BufferPool +from .. piecebuffer import BufferPool from threading import Lock from time import time, strftime, localtime import os diff --git a/herd/BitTornado/BT1/StorageWrapper.py b/herd/BitTornado/BT1/StorageWrapper.py index c200a0e..0613c76 100644 --- a/herd/BitTornado/BT1/StorageWrapper.py +++ b/herd/BitTornado/BT1/StorageWrapper.py @@ -1,12 +1,12 @@ # Written by Bram Cohen # see LICENSE.txt for license information -from herd.BitTornado.bitfield import Bitfield +from .. bitfield import Bitfield try: from hashlib import sha1 as sha except ImportError: from sha import sha -from herd.BitTornado.clock import clock +from .. clock import clock from traceback import print_exc from random import randrange try: diff --git a/herd/BitTornado/BT1/Uploader.py b/herd/BitTornado/BT1/Uploader.py index a5d12e2..249925d 100644 --- a/herd/BitTornado/BT1/Uploader.py +++ b/herd/BitTornado/BT1/Uploader.py @@ -1,7 +1,7 @@ # Written by Bram Cohen # see LICENSE.txt for license information -from herd.BitTornado.CurrentRateMeasure import Measure +from .. CurrentRateMeasure import Measure try: True diff --git a/herd/BitTornado/BT1/makemetafile.py b/herd/BitTornado/BT1/makemetafile.py index 9f18348..522b748 100644 --- a/herd/BitTornado/BT1/makemetafile.py +++ b/herd/BitTornado/BT1/makemetafile.py @@ -10,7 +10,7 @@ from sha import sha from copy import copy from string import strip -from herd.BitTornado.bencode import bencode +from .. bencode import bencode from btformats import check_info from threading import Event from time import time diff --git a/herd/BitTornado/BT1/track.py b/herd/BitTornado/BT1/track.py index 98fcff5..cb634f4 100644 --- a/herd/BitTornado/BT1/track.py +++ b/herd/BitTornado/BT1/track.py @@ -1,18 +1,18 @@ # Written by Bram Cohen # see LICENSE.txt for license information -from herd.BitTornado.parseargs import parseargs, formatDefinitions -from herd.BitTornado.RawServer import RawServer, autodetect_ipv6, autodetect_socket_style -from herd.BitTornado.HTTPHandler import HTTPHandler, months, weekdays -from herd.BitTornado.parsedir import parsedir +from .. parseargs import parseargs, formatDefinitions +from .. RawServer import RawServer, autodetect_ipv6, autodetect_socket_style +from .. HTTPHandler import HTTPHandler, months, weekdays +from .. parsedir import parsedir from NatCheck import NatCheck from T2T import T2TList -from herd.BitTornado.subnetparse import IP_List, ipv6_to_ipv4, to_ipv4, is_valid_ip, is_ipv4 -from herd.BitTornado.iprangeparse import IP_List as IP_Range_List -from herd.BitTornado.torrentlistparse import parsetorrentlist +from .. subnetparse import IP_List, ipv6_to_ipv4, to_ipv4, is_valid_ip, is_ipv4 +from .. iprangeparse import IP_List as IP_Range_List +from .. torrentlistparse import parsetorrentlist from threading import Event, Thread -from herd.BitTornado.bencode import bencode, bdecode, Bencached -from herd.BitTornado.zurllib import urlopen, quote, unquote +from .. bencode import bencode, bdecode, Bencached +from .. zurllib import urlopen, quote, unquote from Filter import Filter from urlparse import urlparse from os import rename, getpid @@ -20,7 +20,7 @@ from cStringIO import StringIO from traceback import print_exc from time import time, gmtime, strftime, localtime -from herd.BitTornado.clock import clock +from .. clock import clock from random import shuffle, seed, randrange try: from hashlib import sha1 as sha @@ -32,8 +32,8 @@ import sys, os import signal import re -import herd.BitTornado.__init__ -from herd.BitTornado.__init__ import version, createPeerID +#import .. __init__ +from .. __init__ import version, createPeerID try: True except: