allow up to 4 work submits per second
authorForrest Voight <forrest@forre.st>
Wed, 2 May 2012 06:04:40 +0000 (02:04 -0400)
committerForrest Voight <forrest@forre.st>
Wed, 2 May 2012 06:18:14 +0000 (02:18 -0400)
p2pool/main.py

index ac74588..58df0d5 100644 (file)
@@ -551,7 +551,7 @@ def main(args, net, datadir_path, merged_urls, worker_endpoint):
                 if desired_pseudoshare_target is None:
                     if len(self.recent_shares_ts_work) == 50:
                         hash_rate = sum(work for ts, work in self.recent_shares_ts_work[1:])//(self.recent_shares_ts_work[-1][0] - self.recent_shares_ts_work[0][0])
-                        target = min(target, 2**256//hash_rate)
+                        target = min(target, 4*2**256//hash_rate)
                 else:
                     target = min(target, desired_pseudoshare_target)
                 target = max(target, share_info['bits'].target)