Skip to content

Conversation

@ForNeVeR
Copy link
Member

@ForNeVeR ForNeVeR commented May 31, 2022

Closes #147.

It turns out we were writing our database in a wrong way. When I send a photo, Telegram will usually send to bot a message with several PhotoSize objects of different sizes. All of them were written to the database, which I don't think is required.

Instead, we should deduplicate the PhotoSize objects based on the FileUniqueId, but there's another problem: Funogram version we use doesn't provide the access to this field at all.

So, I had to update Funogram and change quite a lot of code in our tests to make it work.

The above isn't true and FileUniqueId turned out to not be useful for this use case. Anyway, I've decided to update Funogram.

TODO:

@ForNeVeR ForNeVeR self-assigned this May 31, 2022
@ForNeVeR
Copy link
Member Author

ForNeVeR commented Jul 3, 2022

One problem I am still struggling with is figuring out the FileUniqueId business.

For now, it seems Telegram sends us several different UniqueIds for each image send to Telegram, what the actual hell.

@ForNeVeR ForNeVeR marked this pull request as ready for review July 3, 2022 09:05
@ForNeVeR ForNeVeR merged commit eba4b78 into master Jul 3, 2022
@ForNeVeR ForNeVeR deleted the feature/147.web branch July 3, 2022 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

HTTP redirector service for Telegram content

2 participants