Closed WhyDidIHaveToDoThis closed 1 year ago
Thank you for this bug report! Here is your prize:
Congratulations. It should be fixed now! Little bit of a silly mistake on my part - I should know better than to forget to strip whitespace on user input, really. No need to set a page limit (that would annoy the people who are trying to download thousands of pages, I am sure)
note to self: clean up your links files, anything extraneous will cause this issue e.g. / or #something or ?view_adult=true some works in the format https://archiveofourown.org/works/number/chapters/number will cause the issue idk but the chapter/number part isn't necessary to download the work
Ignore everything below the line I figured it out!!!
When leaving a space at the end of the link ( \n) the script will try to download pages when fetching the other works in a series. This is the result of user error not a bug, because of the way I generated the list of links. This does not need to be fixed if a warning is added for users.
But I do have a suggestion for a setting to set a page limit, I keep sending ao3 100 requests for empty pages and getting temp banned all the time.
I encountered an error when downloading a list of links. Here is what my log file said:
um don't judge the works i just had random links in my OneTab for some reason, i jut exported them and fixed the links with csv so i could merge them all in calibre
This happened twice with these two links before I gave up and manually downloaded all the works. ;(
I tried to look through the code to fix this myself but having never seen python code I gave up after an hour of trying to figure it out... but I don't really understand why it did this? My test with two random works seemed to be fine; the second work was second in the series and the first one got downloaded too. I think it was simply because the series was too long?
But what I attempted to do to fix the issue was to get the prompt from "download from ao3 link" to show where I could set a limit on the pages downloaded, but that would be a janky solution anyways. Downloading a series shouldn't try to download pages in the first place.... wait what's that new line character doing there...