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

Running into error while trying to add all items in a bundle to my account #34

Closed
Technerder opened this issue Mar 20, 2022 · 4 comments

Comments

@Technerder
Copy link

Technerder commented Mar 20, 2022

C:\Users\Username\Desktop\ItchioGames>python -m itchiodl.bundle_tool
Username: removed
Password:
Bundle URL: removed
Traceback (most recent call last):
  File "C:\Users\Username\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\Username\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "C:\Users\Username\AppData\Local\Programs\Python\Python310\lib\site-packages\itchiodl\bundle_tool\__main__.py", line 17, in <module>
    main()
  File "C:\Users\Username\AppData\Local\Programs\Python\Python310\lib\site-packages\itchiodl\bundle_tool\__main__.py", line 13, in main
    b.load_games()
  File "C:\Users\Username\AppData\Local\Programs\Python\Python310\lib\site-packages\itchiodl\bundle.py", line 15, in load_games
    pages = int(s.select("span.pager_label a")[-1].text)
IndexError: list index out of range

Extra info: I am not using 2FA, just username and password

How can I fix this?

@jacobbs
Copy link

jacobbs commented Mar 20, 2022

I suspect itch.io changed the HTML. I edited the [-1] to [0] in bundle.py and it worked.

@Emersont1
Copy link
Owner

That's odd
as [-1] selects the last one

@frostblooded
Copy link

I was getting a similar error when pasting a wrong link for the bundle. It worked when I added a link that looks like this "https://itch.io/bundle/download/...". You can get that link from My Library -> My Purchases -> Bundles -> Click on the desired bundle -> Copy the link you are currently at.

@Emersont1
Copy link
Owner

Okay, I'll improve documentation if this is ambiguous about the link to be used

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

No branches or pull requests

4 participants