overtake / TelegramSwift

Source code of Telegram for macos on Swift 5.0
https://macos.telegram.org
GNU General Public License v2.0
5.07k stars 858 forks source link

[Bug] Conflicting amount of media across macOS and iOS devices #1117

Open 3raxton opened 6 months ago

3raxton commented 6 months ago

Description

I just moved to a new device and restored my phone from a backup of my previous device. When opening my most used Telegram chat on my old device and selecting media, it displays that I have 9,012 media items. Nonetheless, when opening the same chat on my new device and selecting media, it displays that the total media in the chat is 4,726 items.

Further, when looking at the number of photos and videos listed under the name of the chat, it reads that there are 7,377 photos and 1635 videos (9,012 total) yet only 4,726 items display.

When opening the same chat on my Mac, the number of media listed is 6,153.

I have no idea how these quantities are determined but two of them are incorrect and the largest number is correct. Any help is appreciated!

Expected Behavior

As all photos and videos are stored in Telegram cloud, all 9,012 pieces of media should be available.

Actual Behavior

Only about half of the media that should be in the media section of the chat is displayed.

Environment

Device: MacBook Pro, 16-inch, 2019

macOS version: Sonoma 14.1.1

App version: 10.12.2.262594 Stable

3raxton commented 6 months ago

On mobile I resolved this issue by scrolling through my media library and caching the items to memory which seems to increase the count until the accurate number was displayed.

All media is there, however, this does not seem to work for resolution on macOS so I am leaving this issue open