Quote:
Originally Posted by Horizon
I have played with the code & I think the problem is in "r1 = self.session.get(m)"
because the second count "c" now imediately counts to "5" & calls "self.ok = False"
if r1.ok:
c = 0
d1 = self.decode_m3u8(r1)
for i in d1:
self.pool.spawn(self.get_and_decode, i)
else:
c += 1
if c >= 5 :
self.ok = False
I can change 'self.ok = False' to 'self.ok = True' and everything works as used to, which is ok as long as there is no error or cam reset. But it does give demo of how it should run while all is ok with the stream, although it wont close the stream and reset. Or increase 5 to 1000 for similar effect. But this is only a hack /work around in the crudest sense.
|
@Horizon correctly noted where to intervene for what he should congratulate. I managed to solve the problem of closing the file and at one point I thought the script was repaired but I noticed that the stream is being recorded in different resolutions, mostly at the beginning of the file.
So after recording I processed the files by converting TS to FLV and then remove about 11 seconds of file startup.
I also added colors for better visibility. For that must be installed:
pip install colorama
pip install termcolor
All of the above problems don't have my 'cbffr.py' and 'cbffrts.py' scripts (
https://codeload.github.com/horacio9...ous/zip/master) but I see most of you want just this 'chat.py' script. In fact, I did not try this script at a time when it worked without problems, so I'm interested in what are the differences compared to this version?
Link for my version of chat.py is:
http://www.mediafire.com/file/x1x41o...t_20170807.rar