Port to python3, fix ssl support
This commit is contained in:
@@ -37,8 +37,8 @@ def run_phenny(config):
|
||||
p.run(config.host, config.port, config.ssl, config.ipv6)
|
||||
|
||||
try: Watcher()
|
||||
except Exception, e:
|
||||
print >> sys.stderr, 'Warning:', e, '(in __init__.py)'
|
||||
except Exception as e:
|
||||
print('Warning:', e, '(in __init__.py)', file=sys.stderr)
|
||||
|
||||
while True:
|
||||
try: connect(config)
|
||||
@@ -49,7 +49,7 @@ def run_phenny(config):
|
||||
break
|
||||
|
||||
warning = 'Warning: Disconnected. Reconnecting in %s seconds...' % delay
|
||||
print >> sys.stderr, warning
|
||||
print(warning, file=sys.stderr)
|
||||
time.sleep(delay)
|
||||
|
||||
def run(config):
|
||||
@@ -59,4 +59,4 @@ def run(config):
|
||||
else: t.start()
|
||||
|
||||
if __name__ == '__main__':
|
||||
print __doc__
|
||||
print(__doc__)
|
||||
|
||||
Reference in New Issue
Block a user