fabianonline / telegram_backup

Java app to download all your telegram data.
GNU General Public License v3.0
450 stars 91 forks source link

Download of files stalls without any message #44

Open lovkraft opened 7 years ago

lovkraft commented 7 years ago

I managed to download 200.000 messages without a hiccup - immediately after starting downloading the first of 10.000 files, but after 5 files successfully and quickly downloaded, it just halts and stays there, for over an hour.

This is the message I get using --trace:

Checking and downloading media.
Legend:
'V' - Video         'P' - Photo         'D' - Document
'S' - Sticker       'A' - Audio         'G' - Geolocation
'.' - Previously downloaded file        'e' - Empty file
' ' - Ignored media type (weblinks or contacts, for example)
'x' - File skipped because of timeout errors
10926 Files to check / download
20:12:21 TRACE DownloadManager._downloadMedia     : message 17, …Geo, GeoFileManager, non-empty, downloaded
.20:12:21 TRACE DownloadManager._downloadMedia     : message 21, …Photo, PhotoFileManager, non-empty, downloaded
.20:12:21 TRACE DownloadManager._downloadMedia     : message 41, …Photo, PhotoFileManager, non-empty, downloaded
.20:12:21 TRACE DownloadManager._downloadMedia     : message 63, …Photo, PhotoFileManager, non-empty, downloaded
.20:12:21 TRACE DownloadManager._downloadMedia     : message 169, …Photo, PhotoFileManager, non-empty, downloaded
.20:12:21 TRACE DownloadManager._downloadMedia     : message 328, …Photo, PhotoFileManager, non-empty, downloaded
.20:12:21 TRACE DownloadManager._downloadMedia     : message 329, …Photo, PhotoFileManager, non-empty, not downloaded
20:12:21 DEBUG DownloadManager.downloadFileFromDc : Downloading file /Users/jens/.telegram_backup/+5561982033066/files/329.jpg
20:12:21 TRACE DownloadManager.downloadFileFromDc : Temporary filename: /Users/jens/.telegram_backup/+5561982033066/files/329.jpg.downloading
20:12:21 INFO  DownloadManager.downloadFileFromDc : Temporary filename already exists; continuing this file
20:12:21 TRACE DownloadManager.downloadFileFromDc : offset before the loop is 0
20:12:21 TRACE DownloadManager.downloadFileFromDc : offset: 0 block_size: 95595 size: 95595

I delete the 5 downloaded files and ran again. Same app freeze. Here are the details:

Legend:
'V' - Video         'P' - Photo         'D' - Document
'S' - Sticker       'A' - Audio         'G' - Geolocation
'.' - Previously downloaded file        'e' - Empty file
' ' - Ignored media type (weblinks or contacts, for example)
'x' - File skipped because of timeout errors
10934 Files to check / download
15:17:38 TRACE DownloadManager._downloadMedia     : message 17, …Geo, GeoFileManager, non-empty, not downloaded
G15:17:40 TRACE DownloadManager._downloadMedia     : message 21, …Photo, PhotoFileManager, non-empty, not downloaded
15:17:40 DEBUG DownloadManager.downloadFileFromDc : Downloading file /Users/jens/.telegram_backup/+5561982033066/files/21.jpg
15:17:40 TRACE DownloadManager.downloadFileFromDc : Temporary filename: /Users/jens/.telegram_backup/+5561982033066/files/21.jpg.downloading
15:17:40 TRACE DownloadManager.downloadFileFromDc : offset before the loop is 0
15:17:40 TRACE DownloadManager.downloadFileFromDc : offset: 0 block_size: 68965 size: 68965
15:17:40 TRACE DownloadManager.downloadFileFromDc : response: 68965 total size: 68965
15:17:40 TRACE DownloadManager.downloadFileFromDc : Renaming /Users/jens/.telegram_backup/+5561982033066/files/21.jpg.downloading to /Users/jens/.telegram_backup/+5561982033066/files/21.jpg
P15:17:40 TRACE DownloadManager._downloadMedia     : message 41, …Photo, PhotoFileManager, non-empty, not downloaded
15:17:40 DEBUG DownloadManager.downloadFileFromDc : Downloading file /Users/jens/.telegram_backup/+5561982033066/files/41.jpg
15:17:40 TRACE DownloadManager.downloadFileFromDc : Temporary filename: /Users/jens/.telegram_backup/+5561982033066/files/41.jpg.downloading
15:17:40 TRACE DownloadManager.downloadFileFromDc : offset before the loop is 0
15:17:40 TRACE DownloadManager.downloadFileFromDc : offset: 0 block_size: 51674 size: 51674
15:17:40 TRACE DownloadManager.downloadFileFromDc : response: 51674 total size: 51674
15:17:41 TRACE DownloadManager.downloadFileFromDc : Renaming /Users/jens/.telegram_backup/+5561982033066/files/41.jpg.downloading to /Users/jens/.telegram_backup/+5561982033066/files/41.jpg
P15:17:41 TRACE DownloadManager._downloadMedia     : message 63, …Photo, PhotoFileManager, non-empty, not downloaded
15:17:41 DEBUG DownloadManager.downloadFileFromDc : Downloading file /Users/jens/.telegram_backup/+5561982033066/files/63.jpg
15:17:41 TRACE DownloadManager.downloadFileFromDc : Temporary filename: /Users/jens/.telegram_backup/+5561982033066/files/63.jpg.downloading
15:17:41 TRACE DownloadManager.downloadFileFromDc : offset before the loop is 0
15:17:41 TRACE DownloadManager.downloadFileFromDc : offset: 0 block_size: 65867 size: 65867
15:17:41 TRACE DownloadManager.downloadFileFromDc : response: 65867 total size: 65867
15:17:41 TRACE DownloadManager.downloadFileFromDc : Renaming /Users/jens/.telegram_backup/+5561982033066/files/63.jpg.downloading to /Users/jens/.telegram_backup/+5561982033066/files/63.jpg
P15:17:41 TRACE DownloadManager._downloadMedia     : message 169, …Photo, PhotoFileManager, non-empty, not downloaded
15:17:41 DEBUG DownloadManager.downloadFileFromDc : Downloading file /Users/jens/.telegram_backup/+5561982033066/files/169.jpg
15:17:41 TRACE DownloadManager.downloadFileFromDc : Temporary filename: /Users/jens/.telegram_backup/+5561982033066/files/169.jpg.downloading
15:17:41 TRACE DownloadManager.downloadFileFromDc : offset before the loop is 0
15:17:41 TRACE DownloadManager.downloadFileFromDc : offset: 0 block_size: 27829 size: 27829
15:17:41 TRACE DownloadManager.downloadFileFromDc : response: 27829 total size: 27829
15:17:41 TRACE DownloadManager.downloadFileFromDc : Renaming /Users/jens/.telegram_backup/+5561982033066/files/169.jpg.downloading to /Users/jens/.telegram_backup/+5561982033066/files/169.jpg
P15:17:41 TRACE DownloadManager._downloadMedia     : message 328, …Photo, PhotoFileManager, non-empty, not downloaded
15:17:41 DEBUG DownloadManager.downloadFileFromDc : Downloading file /Users/jens/.telegram_backup/+5561982033066/files/328.jpg
15:17:41 TRACE DownloadManager.downloadFileFromDc : Temporary filename: /Users/jens/.telegram_backup/+5561982033066/files/328.jpg.downloading
15:17:41 TRACE DownloadManager.downloadFileFromDc : offset before the loop is 0
15:17:41 TRACE DownloadManager.downloadFileFromDc : offset: 0 block_size: 128876 size: 128876
fabianonline commented 6 years ago

I've added some timeout code some time ago... Did that fix this bug? Did it happen again in the last time?