Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Gelbooru] Failing to download from Gelbooru favorites page when having a certain number of favorites #4903

Closed
Phultin opened this issue Dec 9, 2023 · 0 comments
Labels

Comments

@Phultin
Copy link

Phultin commented Dec 9, 2023

When looking at your favorites on Gelbooru through your account, each page of favorites has at most 50 images. New favorites are put on page 1, and the oldest favorites are pushed back, with new pages being made as necessary. However, when the last page of favorites has 27 images, a new, blank page will be created. Trying to download your favorites list while this blank page exists will result in an error "tuple object has no attribute 'reverse'". This blank page will persist until you add enough new favorites to fill up the second-to-last page with 50 images, then add 1 more so that the last page is no longer blank.

gallery-dl --verbose "https://gelbooru.com/index.php?page=favorites&s=view&id=xxxxxx"
[gallery-dl][debug] Version 1.26.3
[gallery-dl][debug] Python 3.8.5 - Windows-10-10.0.17763-SP0
[gallery-dl][debug] requests 2.31.0 - urllib3 2.1.0
[gallery-dl][debug] Configuration Files ['%USERPROFILE%\\gallery-dl\\config.json']
[gallery-dl][debug] Starting DownloadJob for 'https://gelbooru.com/index.php?page=favorites&s=view&id=xxxxxx'
[gelbooru][debug] Using GelbooruFavoriteExtractor for 'https://gelbooru.com/index.php?page=favorites&s=view&id=xxxxxx'
[gelbooru][debug] Loading cookies from 'D:/username/gallery-dl/cookies/cookies.txt'
[urllib3.connectionpool][debug] Starting new HTTPS connection (1): gelbooru.com:443
[urllib3.connectionpool][debug] https://gelbooru.com:443 "GET /index.php?page=dapi&q=index&json=1&s=favorite&id=xxxxxx&limit=1 HTTP/1.1" 200 None
[urllib3.connectionpool][debug] https://gelbooru.com:443 "GET /index.php?page=dapi&q=index&json=1&s=favorite&id=xxxxxx&limit=100&pid=363 HTTP/1.1" 200 None
[gelbooru][error] An unexpected error occurred: AttributeError - 'tuple' object has no attribute 'reverse'. Please run gallery-dl again with the --verbose flag, copy its output and report this issue on https://github.com/mikf/gallery-dl/issues .
[gelbooru][debug]
Traceback (most recent call last):
  File "c:\users\username\appdata\local\programs\python\python38\lib\site-packages\gallery_dl\job.py", line 127, in run
    for msg in extractor:
  File "c:\users\username\appdata\local\programs\python\python38\lib\site-packages\gallery_dl\extractor\booru.py", line 34, in items
    for post in self.posts():
  File "c:\users\username\appdata\local\programs\python\python38\lib\site-packages\gallery_dl\extractor\gelbooru.py", line 187, in posts
    favs.reverse()
AttributeError: 'tuple' object has no attribute 'reverse'
@Phultin Phultin changed the title Failing to download from Gelbooru favorites page when having a certain number of favorites [Gelbooru] Failing to download from Gelbooru favorites page when having a certain number of favorites Dec 9, 2023
@mikf mikf added the site:bug label Dec 9, 2023
mikf added a commit that referenced this issue Jan 4, 2024
lots of +1/-1 and </<= mistakes
@Phultin Phultin closed this as completed Jan 6, 2024
bradenhilton pushed a commit to bradenhilton/gallery-dl that referenced this issue Feb 5, 2024
bradenhilton pushed a commit to bradenhilton/gallery-dl that referenced this issue Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants