MCPcopy
hub / github.com/HelloZeroNet/ZeroNet / scrape

Method scrape

src/lib/subtl/subtl.py:69–79  ·  view source on GitHub ↗
(self, info_hash_list)

Source from the content-addressed store, hash-verified

67 return self._send(ANNOUNCE, payload)
68
69 def scrape(self, info_hash_list):
70 if len(info_hash_list) > 74:
71 raise UdpTrackerClientException('Max info_hashes is 74')
72
73 payload = ''
74 for info_hash in info_hash_list:
75 payload += info_hash
76
77 trans = self._send(SCRAPE, payload)
78 trans['sent_hashes'] = info_hash_list
79 return trans
80
81 def poll_once(self):
82 self.sock.settimeout(self.timeout)

Callers

nothing calls this directly

Calls 2

_sendMethod · 0.95

Tested by

no test coverage detected