Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(98)  |  Call(81)  |  Derive(0)  |  Import(17)
Encode a data structure into a string.

Creates a list in which to collect string segments and returns the
joined result.

See encode_* for details.

src/o/w/OwnTube-HEAD/videoportal/BitTornadoABC/BitTornado/BT1/track.py   OwnTube(Download)
from BitTornado.torrentlistparse import parsetorrentlist
from threading import Event, Thread
from BitTornado.bencode import bencode, bdecode, Bencached
from BitTornado.zurllib import urlopen
from urllib import quote, unquote
            if self.config['scrape_allowed'] not in ['specific', 'full']:
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'specific scrape function is not available with this tracker.'}))
            for hash in paramslist['info_hash']:
            if self.config['scrape_allowed'] != 'full':
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'full scrape function is not available with this tracker.'}))
            if self.allowed is not None:
                fs[hash] = self.scrapedata(hash)
 
        return (200, 'OK', {'Content-Type': 'text/plain'}, bencode({'files': fs}))
 
 
                        and paramslist['password'][0] == self.aggregator_key ) ):
            return (200, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                bencode({'failure reason':
                'Requested download is not authorized for use with this tracker.'}))
 

src/f/r/FriendlyTorrent-HEAD/src/tornado/BitTornado/BT1/track.py   FriendlyTorrent(Download)
from BitTornado.torrentlistparse import parsetorrentlist
from threading import Event, Thread
from BitTornado.bencode import bencode, bdecode, Bencached
from BitTornado.zurllib import urlopen, quote, unquote
from Filter import Filter
            if self.config['scrape_allowed'] not in ['specific', 'full']:
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'specific scrape function is not available with this tracker.'}))
            for hash in paramslist['info_hash']:
            if self.config['scrape_allowed'] != 'full':
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'full scrape function is not available with this tracker.'}))
            if self.allowed is not None:
                fs[hash] = self.scrapedata(hash)
 
        return (200, 'OK', {'Content-Type': 'text/plain'}, bencode({'files': fs}))
 
 
                        and paramslist['password'][0] == self.aggregator_key ) ):
            return (200, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                bencode({'failure reason':
                'Requested download is not authorized for use with this tracker.'}))
 

src/b/i/BitTornado-HEAD/BitTornado/BT1/track.py   BitTornado(Download)
from T2T import T2TList
from BitTornado.torrentlistparse import parsetorrentlist
from BitTornado.bencode import bencode, bdecode, Bencached
from BitTornado.zurllib import urlopen
from Filter import Filter
                return (400, 'Not Authorized', {'Content-Type': 'text/plain',
                                                'Pragma': 'no-cache'},
                        bencode({'failure reason': 'specific scrape function '
                                 'is not available with this tracker.'}))
            for hash in paramslist['info_hash']:
                return (400, 'Not Authorized', {'Content-Type': 'text/plain',
                                                'Pragma': 'no-cache'},
                        bencode({'failure reason': 'full scrape function is '
                                 'not available with this tracker.'}))
            if self.allowed is not None:
 
        return (200, 'OK', {'Content-Type': 'text/plain'},
                bencode({'files': fs}))
 
    def get_file(self, hash):
            return (200, 'Not Authorized', {'Content-Type': 'text/plain',
                                            'Pragma': 'no-cache'},
                    bencode({'failure reason': 'Requested download is not '
                             'authorized for use with this tracker.'}))
 

src/h/e/Herd-HEAD/BitTornado/BT1/track.py   Herd(Download)
from BitTornado.torrentlistparse import parsetorrentlist
from threading import Event, Thread
from BitTornado.bencode import bencode, bdecode, Bencached
from BitTornado.zurllib import urlopen, quote, unquote
from Filter import Filter
            if self.config['scrape_allowed'] not in ['specific', 'full']:
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'specific scrape function is not available with this tracker.'}))
            for hash in paramslist['info_hash']:
            if self.config['scrape_allowed'] != 'full':
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'full scrape function is not available with this tracker.'}))
            if self.allowed is not None:
                fs[hash] = self.scrapedata(hash)
 
        return (200, 'OK', {'Content-Type': 'text/plain'}, bencode({'files': fs}))
 
 
                        and paramslist['password'][0] == self.aggregator_key ) ):
            return (200, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                bencode({'failure reason':
                'Requested download is not authorized for use with this tracker.'}))
 

src/s/w/swarm-HEAD/BitTornado/BT1/track.py   swarm(Download)
from BitTornado.torrentlistparse import parsetorrentlist
from threading import Event, Thread
from BitTornado.bencode import bencode, bdecode, Bencached
from BitTornado.zurllib import urlopen, quote, unquote
from Filter import Filter
            if self.config['scrape_allowed'] not in ['specific', 'full']:
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'specific scrape function is not available with this tracker.'}))
            for hash in paramslist['info_hash']:
            if self.config['scrape_allowed'] != 'full':
                return (400, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                    bencode({'failure reason':
                    'full scrape function is not available with this tracker.'}))
            if self.allowed is not None:
                fs[hash] = self.scrapedata(hash)
 
        return (200, 'OK', {'Content-Type': 'text/plain'}, bencode({'files': fs}))
 
 
                        and paramslist['password'][0] == self.aggregator_key ) ):
            return (200, 'Not Authorized', {'Content-Type': 'text/plain', 'Pragma': 'no-cache'},
                bencode({'failure reason':
                'Requested download is not authorized for use with this tracker.'}))
 

src/o/w/OwnTube-HEAD/videoportal/BitTornadoABC/BitTornado/BT1/makemetafile.py   OwnTube(Download)
from sha import sha
from copy import copy
from BitTornado.bencode import bencode
from btformats import check_info
from threading import Event
        data['httpseeds'] = params['httpseeds'].split('|')
 
    h.write(bencode(data))
    h.close()
 

src/b/i/BitTornado-HEAD/btshowmetainfo.py   BitTornado(Download)
import hashlib
from BitTornado.Info import MetaInfo
from BitTornado.bencode import bencode
 
NAME, EXT = os.path.splitext(os.path.basename(sys.argv[0]))
    metainfo = MetaInfo.read(metainfo_name)
    info = metainfo['info']
    info_hash = hashlib.sha1(bencode(info))
 
    print 'metainfo file.: %s' % os.path.basename(metainfo_name)

src/f/r/FriendlyTorrent-HEAD/src/tornado/BitTornado/BT1/makemetafile.py   FriendlyTorrent(Download)
from copy import copy
from string import strip
from BitTornado.bencode import bencode
from btformats import check_info
from threading import Event
        data['httpseeds'] = params['httpseeds'].split('|')
 
    h.write(bencode(data))
    h.close()
 

src/o/w/OwnTube-HEAD/videoportal/BitTornadoABC/btmakemetafile.py   OwnTube(Download)
    ENCODING = getdefaultencoding()
 
from BitTornado.bencode import bencode
from BitTornado.BT1.btformats import check_info
 
 
    h.write(bencode(data))
    h.close()
 
def calcsize(file):

src/h/e/Herd-HEAD/BitTornado/BT1/makemetafile.py   Herd(Download)
from copy import copy
from string import strip
from BitTornado.bencode import bencode
from btformats import check_info
from threading import Event
        data['httpseeds'] = params['httpseeds'].split('|')
 
    h.write(bencode(data))
    h.close()
 

  1 | 2  Next