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

[Mixcloud] Harmonize ID generation from lists with full ID generation #27787

Merged
merged 1 commit into from
Jan 13, 2021

Conversation

akx
Copy link

@akx akx commented Jan 12, 2021

Before submitting a pull request make sure you have:

In order to be accepted and merged into youtube-dl each piece of code must be in public domain or released under Unlicense. Check one of the following options:

  • I am the original author of this code and I am willing to release it under Unlicense
  • I am not the original author of this code but it is in public domain or released under Unlicense (provide reliable evidence)

What is the purpose of your pull request?

  • Bug fix
  • Improvement
  • New extractor
  • New feature

Description of your pull request and other information

Mixcloud IDs are generated as username_slug when the full ID dict has been downloaded. When downloading a list (e.g. uploads, favorites, ...), the temporary ID is just the slug. This made e.g. archive file usage require the download of stream metadata before the download can be rejected as already downloaded.

This PR attempts to get the uploader username during the GraphQL query, so the temporary IDs are generated similarly, and archive file checks can occur before the full stream metadata is downloaded.

youtube_dl/extractor/mixcloud.py Outdated Show resolved Hide resolved
youtube_dl/extractor/mixcloud.py Outdated Show resolved Hide resolved
youtube_dl/extractor/mixcloud.py Outdated Show resolved Hide resolved
@akx akx requested a review from remitamine January 13, 2021 08:38
Mixcloud IDs are generated as `username_slug` when the full ID dict has been
downloaded.  When downloading a list (e.g. uploads, favorites, ...), the temporary
ID is just the `slug`.  This made e.g. archive file usage require the download
of stream metadata before the download can be rejected as already downloaded.

This PR attempts to get the uploader username during the GraphQL query, so the
temporary IDs are generated similarly.
@remitamine remitamine merged commit 7c2d18a into ytdl-org:master Jan 13, 2021
ThirumalaiK pushed a commit to ThirumalaiK/youtube-dl that referenced this pull request Jan 28, 2021
…ytdl-org#27787)

Mixcloud IDs are generated as `username_slug` when the full ID dict has been
downloaded.  When downloading a list (e.g. uploads, favorites, ...), the temporary
ID is just the `slug`.  This made e.g. archive file usage require the download
of stream metadata before the download can be rejected as already downloaded.

This commit attempts to get the uploader username during the GraphQL query, so the
temporary IDs are generated similarly.
ThirumalaiK pushed a commit to ThirumalaiK/youtube-dl that referenced this pull request Jan 28, 2021
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