Downloading multiple DocumentAttributeVideo not possible
Closed this issue · 5 comments
def getFilename(event: events.NewMessage.Event): for attribute in event.media.document.attributes: if isinstance(attribute, DocumentAttributeFilename): return attribute.file_name if isinstance(attribute, DocumentAttributeVideo): return "DocumentAttributeVideo"
Because DocumentAttributVideos have no Filenames you overide the last download of DocumentAttributeVideo
It would be bether if the Daemon asks if you want to rename the file before.
I can not reproduce the problem. Could you give an example of use case?
I can not reproduce the problem. Could you give an example of use case?
You need a Video that you can stream with telegram.
If you give me your telegram name i would could share you such a video
I am afraid that publishing my Telegram name here would make me a target for spammers.
These kind of videos do not include a file name we can use, so I have browsed the different attributes available and changed the generic "DocumentAttributeVideo" to the full original message text.
I can not see another option for automated downloads, and this one will avoid overwritting former video files.
I hope it will work for your. Please, test it and give some feedback.
These kind of videos do not include a file name we can use, so I have browsed the different attributes available and changed the generic "DocumentAttributeVideo" to the full original message text.
I can not see another option for automated downloads, and this one will avoid overwritting former video files.
I hope it will work for your. Please, test it and give some feedback.
thanks. this solved the problem