mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-23 17:47:31 +00:00
fix is_connected with http protocol
This commit is contained in:
parent
98f7d36313
commit
21c0578ca8
1 changed files with 5 additions and 0 deletions
|
@ -196,11 +196,15 @@ class Interface(threading.Thread):
|
||||||
try:
|
try:
|
||||||
self.poll()
|
self.poll()
|
||||||
except:
|
except:
|
||||||
|
print_error("http init session failed")
|
||||||
|
self.is_connected = False
|
||||||
return
|
return
|
||||||
|
|
||||||
if self.session_id:
|
if self.session_id:
|
||||||
print_error('http session:',self.session_id)
|
print_error('http session:',self.session_id)
|
||||||
self.is_connected = True
|
self.is_connected = True
|
||||||
|
else:
|
||||||
|
self.is_connected = False
|
||||||
|
|
||||||
def run_http(self):
|
def run_http(self):
|
||||||
self.is_connected = True
|
self.is_connected = True
|
||||||
|
@ -226,6 +230,7 @@ class Interface(threading.Thread):
|
||||||
|
|
||||||
def send_http(self, messages, channel='default'):
|
def send_http(self, messages, channel='default'):
|
||||||
import urllib2, json, time, cookielib
|
import urllib2, json, time, cookielib
|
||||||
|
print_error( "send_http", messages )
|
||||||
|
|
||||||
if self.proxy:
|
if self.proxy:
|
||||||
import socks
|
import socks
|
||||||
|
|
Loading…
Add table
Reference in a new issue