X Tutup
Skip to content

Add support for downloading bundles#2

Open
jackwilsdon wants to merge 2 commits intoDragoonAethis:mainfrom
jackwilsdon:download-bundles
Open

Add support for downloading bundles#2
jackwilsdon wants to merge 2 commits intoDragoonAethis:mainfrom
jackwilsdon:download-bundles

Conversation

@jackwilsdon
Copy link
Contributor

No description provided.

@jackwilsdon jackwilsdon force-pushed the download-bundles branch 2 times, most recently from 574681e to 37011d5 Compare June 19, 2022 12:12
@DragoonAethis
Copy link
Owner

While the job fetching for bundles looks good, there's some stuff I'd like to have handled before declaring support for downloading bundles in the readme, etc:

  • The client is able to fetch jobs, but not claim titles from the bundle. At least the bundles I own have this description set on the bundle page: Note: Projects in this bundle are hidden in your library by default until you first access them in order to avoid flooding your library. You can return to this page at any time to access any projects you wish to show in your library. - and sure enough, none of those games have their download keys available to actually fetch files. There should be a warning for this case, but I don't know what determines this behavior, of if it's all of them.
  • What if someone provides a bundle URL with the download key? They look like itch.io/bundle/download/AAbca...1234 and don't contain the bundle ID in the link, but it could be scrapped by looking up the link on elements like <a href="/b/123/bundle-slug" class="return_link"> - this doesn't have to be supported right away, but a warning could be nice.
  • What if the link w/ download key is claimed? Itch will throw a 404 if the page is requested while logged out. (Not sure if the API key authenticates web requests, probably not.)


elif site in ("b", "bundle"): # Bundles
raise NotImplementedError("itch-dl cannot download bundles yet.")
bundle_json = get_bundle_json(url_path_parts[1], client)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The 2nd URL part does not have to be a bundle ID, it could be download.

game jam. The input can also be a path to a itch.io JSON file with game jam entries, or just
a list of itch.io game URLs (not browse/jam pages!) to download.
The input URL can be any "Browse" page (top, popular, newest, filtered by tags, etc), any
game jam or any bundle. The input can also be a path to a itch.io JSON file with game jam
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like some clarification that this does not claim bundles - we'll handle this later.

@DragoonAethis
Copy link
Owner

See comments for the changes I'd like to see now, I'll merge it with those and add issues to deal with the remaining stuff later.

@DragoonAethis
Copy link
Owner

@jackwilsdon I'll have some time this weekend for itch-dl, would you like to finish this PR or can I take it as is and fix up what's left?

@jackwilsdon
Copy link
Contributor Author

I don't think I'll have any free time to work on this PR this weekend sorry - feel free to take it 👍

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

Successfully merging this pull request may close these issues.

2 participants

X Tutup