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

Fix JSONDecodeError on get_channel from EU countries #38

Merged
merged 2 commits into from
Sep 3, 2023

Conversation

twissell-
Copy link
Contributor

This fixes #36

More info here.

@Nutzer123
Copy link

Nutzer123 commented Sep 2, 2023

hey,
it looks like there is an smarter way - i checked this for the videos

def get_initial_data(session: requests.Session, url: str) -> str:
    url = url+"&ucbcb=1"
    response = session.get(url)
    html = response.text
    return html

@twissell-
Copy link
Contributor Author

Hey @Nutzer123!

I certainly prefer your fix better. I've implemented it into this PR, but I've changed how the parameter is passed to the request.

Thanks!

@twissell- twissell- changed the title Added SOCS cookie Fix JSONDecodeError on get_channel from EU countries Sep 3, 2023
@dermasmid dermasmid merged commit 73b37fd into dermasmid:master Sep 3, 2023
@dermasmid
Copy link
Owner

thanks for this @twissell- and @Nutzer123

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.

JSONDecodeError: Expecting value: line 1 column 1 (char 0)
3 participants