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

[patreon][error] HTTP request failed: MissingSchema #444

Closed
espressoelf opened this issue Oct 12, 2019 · 2 comments
Closed

[patreon][error] HTTP request failed: MissingSchema #444

espressoelf opened this issue Oct 12, 2019 · 2 comments
Labels

Comments

@espressoelf
Copy link

When using https://www.patreon.com/home (download all posts from followed artists) as source, the downloader stops after 20 posts with the following (really long) error:

[patreon][error] HTTP request failed:  MissingSchema: Invalid URL 'www.patreon.com/api/stream?include=user%2Cimages%2Cattachments%2Cuser_defined_tags%2Ccampaign%2Cpoll.choices%2Cpoll.current_user_responses.user%2Cpoll.current_user_responses.choice%2Cpoll.current_user_responses.poll%2Caccess_rules.tier.null&fields%5Bpost%5D=change_visibility_at%2Ccomment_count%2Ccontent%2Ccurrent_user_can_delete%2Ccurrent_user_can_view%2Ccurrent_user_has_liked%2Cembed%2Cimage%2Cis_paid%2Clike_count%2Cmin_cents_pledged_to_view%2Cpost_file%2Cpublished_at%2Cpatron_count%2Cpatreon_url%2Cpost_type%2Cpledge_url%2Cthumbnail_url%2Cteaser_text%2Ctitle%2Cupgrade_url%2Curl%2Cwas_posted_by_campaign_owner&fields%5Buser%5D=image_url%2Cfull_name%2Curl&fields%5Bcampaign%5D=avatar_photo_url%2Cearnings_visibility%2Cis_nsfw%2Cis_monthly%2Cname%2Curl&fields%5Baccess_rule%5D=access_rule_type%2Camount_cents&page%5Bcursor%5D=2019-10-04T15%3A03%3A00&filter%5Bis_following%5D=true&json-api-use-default-includes=false&json-api-version=1.0': No schema supplied. Perhaps you meant http://www.patreon.com/api/stream?include=user%2Cimages%2Cattachments%2Cuser_defined_tags%2Ccampaign%2Cpoll.choices%2Cpoll.current_user_responses.user%2Cpoll.current_user_responses.choice%2Cpoll.current_user_responses.poll%2Caccess_rules.tier.null&fields%5Bpost%5D=change_visibility_at%2Ccomment_count%2Ccontent%2Ccurrent_user_can_delete%2Ccurrent_user_can_view%2Ccurrent_user_has_liked%2Cembed%2Cimage%2Cis_paid%2Clike_count%2Cmin_cents_pledged_to_view%2Cpost_file%2Cpublished_at%2Cpatron_count%2Cpatreon_url%2Cpost_type%2Cpledge_url%2Cthumbnail_url%2Cteaser_text%2Ctitle%2Cupgrade_url%2Curl%2Cwas_posted_by_campaign_owner&fields%5Buser%5D=image_url%2Cfull_name%2Curl&fields%5Bcampaign%5D=avatar_photo_url%2Cearnings_visibility%2Cis_nsfw%2Cis_monthly%2Cname%2Curl&fields%5Baccess_rule%5D=access_rule_type%2Camount_cents&page%5Bcursor%5D=2019-10-04T15%3A03%3A00&filter%5Bis_following%5D=true&json-api-use-default-includes=false&json-api-version=1.0?

My quick & dirty hack is adding

        if(url.find("http", 0, 4) == -1):
            url = "https://" + url;

to extractor/common.py line 78, but that probably should be done elsewhere / better.

mikf added a commit that referenced this issue Oct 13, 2019
The Patreon-provided URLs for the next set of posts aren't
always complete, i.e. they can be missing their scheme and
the subsequent double slash: "www.patreon.com/…"
@mikf
Copy link
Owner

mikf commented Oct 13, 2019

I've pushed a possible fix with 6abe5f5, but can't confirm if it actually works (no Patreon subscriptions.) Could you test this and report back if the error still persists?

@mikf mikf added the bug label Oct 13, 2019
@espressoelf
Copy link
Author

I've installed the dev version via pip install --upgrade https://github.com/mikf/gallery-dl/archive/master.zip and the error seems to be fixed. Thank you.

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