While the tool downloads the files from telegram following errors occures:
...............Exception in thread "MTProtoWatchdog-exec-thread-47" java.lang.Error: java
.nio.channels.ClosedChannelException
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1148
)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617
)
at java.lang.Thread.run(Thread.java:744)
Caused by: java.nio.channels.ClosedChannelException
at java.nio.channels.spi.AbstractSelectableChannel.configureBlocking(AbstractSele
ctableChannel.java:289)
at com.github.badoualy.telegram.mtproto.transport.MTProtoTcpConnection.unregister
(MTProtoTcpConnection.kt:120)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog.stop(MTProtoWatchdog.kt:1
32)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog$run$2$1$1.run(MTProtoWatc
hdog.kt:63)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142
)
... 2 more
Exception in thread "MTProtoWatchdog-exec-thread-48" java.lang.Error: java.nio.channels.C
losedChannelException
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1148
)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617
)
at java.lang.Thread.run(Thread.java:744)
Caused by: java.nio.channels.ClosedChannelException
at java.nio.channels.spi.AbstractSelectableChannel.configureBlocking(AbstractSele
ctableChannel.java:289)
at com.github.badoualy.telegram.mtproto.transport.MTProtoTcpConnection.unregister
(MTProtoTcpConnection.kt:120)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog.stop(MTProtoWatchdog.kt:1
32)
at com.github.badoualy.telegram.mtproto.MTProtoWatchdog$run$2$1$1.run(MTProtoWatc
hdog.kt:63)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142
)
... 2 more
Telegram took too long to respond to our request.
I'm going to wait a minute and then try again.```
It downloads the first 16 images correctly, but then more or less hangs while downloading a 15MB file. After looking in the code I saw, that the blocksize is equal to the file size, which leads to this error. After setting it to 1024 (bytes) the file gets downloaded correctly.
I will push my changes to my fork and make a merge request.
While the tool downloads the files from telegram following errors occures: