Merge pull request #102 from ndokter/issue-101

fix FileReader from not completing
This commit is contained in:
Nigel Dokter 2022-02-22 20:33:31 +01:00 committed by GitHub
commit 304593c246
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -64,8 +64,11 @@ class FileReader(object):
with open(self._file, "rb") as file_handle:
while True:
data = file_handle.readline()
str = data.decode()
self.telegram_buffer.append(str)
if not data:
break
self.telegram_buffer.append(data.decode())
for telegram in self.telegram_buffer.get_all():
try: