Skip to content
This repository has been archived by the owner on Jan 24, 2024. It is now read-only.

retry failed/cancelled download #14

Closed
adocampo opened this issue Nov 19, 2019 · 11 comments
Closed

retry failed/cancelled download #14

adocampo opened this issue Nov 19, 2019 · 11 comments

Comments

@adocampo
Copy link

Hi there!

I'm using this awesome bot to in conjunction with medusa to save and then rename and place the file into the correct path.

Sometimes, but, medusa moves the file when it didn't complete to download, so I need to re-download it again, and it seems it cannot be downloaded more than once. I have tried to /allow_duplicates and /clear_history but it seems it does nothing. (in fact, the only two commands with any output are /start@username and /stop@username commands.

Am I doing something wrong?

@Nukesor
Copy link
Owner

Nukesor commented Nov 19, 2019

Did you do /allow_duplicates@username true?
Try /info@username to see the current settings for a chat

@adocampo
Copy link
Author

I didn't do (I miss the @username part on the commands) but I did just now. Still seems to not to download already downloaded files.

Current settings:

Name: 19338....
Active: True
Accepted Media: document
Verbose: True
Allow duplicates: True
Sort files by User: True

@Nukesor
Copy link
Owner

Nukesor commented Nov 19, 2019

Allow duplicates is basically a flag, which enable downloading of files that have the same download.
If you want to download files that actually failed to download, you need to start a /scan_chat
This will go through the whole chat history and download files (if they haven't been downloaded yet)

@adocampo
Copy link
Author

I have this on my history chat
imagen
But it doesn't donwload anything
imagen

I'm on my own chat (Saved Messages), can be this perhaps? (I don't know if/how I can download to a bot). I cannot see either a verbosed ouput nor in the chat neither in the command line output

@Nukesor
Copy link
Owner

Nukesor commented Nov 19, 2019

That's because this is probably a photo.
As you can see, your accepted media is set to documents, which only includes file uploads.
Type /accept@user document photo

It's obvious, that some things in the current documentation are unclear. It would be awesome, if you could adjust the documentation text, remove any uncertainties and create a PR :)

@Nukesor
Copy link
Owner

Nukesor commented Nov 19, 2019

Verbose:
This is from the docs:
/verbose ['true', 'false'] The bot will complain if there are duplicate files or uncompressed images are sent, whilst not being accepted.

@Nukesor
Copy link
Owner

Nukesor commented Nov 19, 2019

Just tested the verbose output. Seems to be silently ignored.
Feel free to debug and create a PR :) Shouldn't be too hard, the code base is pretty straight forward.

@adocampo
Copy link
Author

adocampo commented Nov 19, 2019

That's because this is probably a photo.
As you can see, your accepted media is set to documents, which only includes file uploads.
Type /accept@user document photo

It's obvious, that some things in the current documentation are unclear. It would be awesome, if you could adjust the documentation text, remove any uncertainties and create a PR :)

Still doesn't work, and as verbose tells nothing, it's quite hard to know what's happening.
I can PR the changes to de documentation to be a bit more clear, and perhaps after the tests, if I can create a systemd unit file to autostart the bot on boot.

Just tested the verbose output. Seems to be silently ignored.
Feel free to debug and create a PR :) Shouldn't be too hard, the code base is pretty straight forward.

I can't take a look, yet I do not know anything about telegram bots, to see at least why verbose isn't working.

@Nukesor
Copy link
Owner

Nukesor commented Nov 19, 2019

A few lines in the documention would be very much appreciated, though ;)

@adocampo
Copy link
Author

The /clear_history@username did the trick.
I'm gonna PR some suggestions to the README, so command won't be ambiguous.

@Nukesor
Copy link
Owner

Nukesor commented Nov 20, 2019

Nice. Thanks a lot! 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants