Merge 793f0b207f
into d98a3546a3
This commit is contained in:
commit
976149edd4
S'han modificat 1 arxius amb 23 adicions i 20 eliminacions
|
@ -41,6 +41,7 @@ class StreamListener(object):
|
||||||
|
|
||||||
response; a requests response object with the open stream for reading.
|
response; a requests response object with the open stream for reading.
|
||||||
"""
|
"""
|
||||||
|
try:
|
||||||
event = {}
|
event = {}
|
||||||
line_buffer = bytearray()
|
line_buffer = bytearray()
|
||||||
for chunk in response.iter_content(chunk_size = 1):
|
for chunk in response.iter_content(chunk_size = 1):
|
||||||
|
@ -61,6 +62,8 @@ class StreamListener(object):
|
||||||
line_buffer = bytearray()
|
line_buffer = bytearray()
|
||||||
else:
|
else:
|
||||||
line_buffer.extend(chunk)
|
line_buffer.extend(chunk)
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
def _parse_line(self, line, event):
|
def _parse_line(self, line, event):
|
||||||
if line.startswith(':'):
|
if line.startswith(':'):
|
||||||
|
|
Loading…
Referencia en una nova incidència