fabianonline/telegram_backup

Exceptions thrown while runnung in daemon mode

Opened this issue · 1 comments

aldem commented

Hi,

Just installed, version 1.1.3 - works like a charm, but when I run it in daemon mode, after a short while I am getting this:

Exception in thread "RxComputationThreadPool-3" java.lang.IllegalStateException: Exception thrown on Scheduler.Worker thread. Add onError handling.
at rx.internal.schedulers.ScheduledAction.run(ScheduledAction.java:60)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:514)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:299)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.base/java.lang.Thread.run(Thread.java:844)
Caused by: rx.exceptions.OnErrorNotImplementedException: Reached end-of-stream
at rx.Observable$26.onError(Observable.java:7881)
at rx.observers.SafeSubscriber._onError(SafeSubscriber.java:159)
at rx.observers.SafeSubscriber.onError(SafeSubscriber.java:120)
at rx.internal.operators.OperatorDoOnEach$1.onError(OperatorDoOnEach.java:71)
at rx.internal.operators.OperatorDoOnEach$1.onError(OperatorDoOnEach.java:71)
at rx.internal.operators.OperatorObserveOn$ObserveOnSubscriber.pollQueue(OperatorObserveOn.java:191)
at rx.internal.operators.OperatorObserveOn$ObserveOnSubscriber$2.call(OperatorObserveOn.java:162)
at rx.internal.schedulers.ScheduledAction.run(ScheduledAction.java:55)
... 6 more
Caused by: java.io.IOException: Reached end-of-stream
at com.github.badoualy.telegram.mtproto.transport.MTProtoTcpConnection.readBytes(MTProtoTcpConnection.kt:143)
at com.github.badoualy.telegram.mtproto.transport.MTProtoTcpConnection.readBytes$default(MTProtoTcpConnection.kt:134)
at com.github.badoualy.telegram.mtproto.transport.MTProtoTcpConnection.readMessage(MTProtoTcpConnection.kt:65)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog.readMessage(MTProtoWatchdog.kt:94)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog.access$readMessage(MTProtoWatchdog.kt:18)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog$run$2$1$1.run(MTProtoWatchdog.kt:56)
... 3 more

It repeats once, and then nothing happens - no output and no new messages are received (at least I see nothing new in database).

Not sure if this could be an issue of Java 9 (I have JDK 9 on Debian stretch), but it looks like that connection is closed by the server and this is not handled at all.

It's a bug in the Kotlogram library. I can't do anything against this bug - except possibly for updating the library, but that needs a lot of other stuff to happen first...