8000 Prevent stopping the proxy when github is out of order. · coderlv/stratum-mining-proxy@c7d7eec · GitHub
[go: up one dir, main page]

Skip to content

Commit c7d7eec

Browse files
author
slush
committed
Prevent stopping the proxy when github is out of order.
1 parent 5b3f6e1 commit c7d7eec

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

mining_proxy.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -152,9 +152,13 @@ def test_update():
152152

153153
import urllib2
154154
log.warning("Checking for updates...")
155-
if version.VERSION not in urllib2.urlopen(GIT_URL).read():
156-
print_deprecation_warning()
157-
return # New version already detected, stop periodic checks
155+
try:
156+
if version.VERSION not in urllib2.urlopen(GIT_URL).read():
157+
print_deprecation_warning()
158+
return # New version already detected, stop periodic checks
159+
except:
160+
log.warning("Check failed.")
161+
158162
reactor.callLater(3600*24, test_update)
159163

160164
@defer.inlineCallbacks

0 commit comments

Comments
 (0)
0