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

Video unavailable #811

Open
simmstein opened this issue Oct 9, 2019 · 19 comments

Comments

@simmstein
Copy link

commented Oct 9, 2019

Hello,

Versions

  • Invidious version: 0.19.1-e03b4b7 (sha256 of the compiled file 271291b36749ee7bae51c3834d08da8eb8bc7e4842525489c56a3399ef0b5d17)
  • OS: Debian 10 (amd64)
  • Crystal version: 0.31.1 [0e2e1d067] (2019-09-30)
  • Database: Postgresql 9.6+181+deb9u2
  • Logs: empty (no error)

What happened

I click on a video's thumbnail and the message "Video unavailable." is shown.

Expected

Play the video clicked.

Information

The video is played using invidio.us (0.19.1-e03b4b7 master).

@simmstein

This comment has been minimized.

Copy link
Author

commented Oct 9, 2019

From the server:

$ youtube-dl "https://www.youtube.com/watch?v=XXXXXXXXX"
[youtube] -OZ--RQcaY4: Downloading webpage
[youtube] -OZ--RQcaY4: Downloading video info webpage
WARNING: unable to download video info webpage: HTTP Error 429: Too Many Requests
WARNING: unable to download video info webpage: HTTP Error 429: Too Many Requests
WARNING: unable to download video info webpage: HTTP Error 429: Too Many Requests
WARNING: unable to download video info webpage: HTTP Error 429: Too Many Requests
WARNING: unable to download video info webpage: HTTP Error 429: Too Many Requests
Traceback (most recent call last):
  File "/usr/bin/youtube-dl", line 11, in <module>
    load_entry_point('youtube-dl==2019.1.17', 'console_scripts', 'youtube-dl')()
  File "/usr/lib/python3/dist-packages/youtube_dl/__init__.py", line 477, in main
    _real_main(argv)
  File "/usr/lib/python3/dist-packages/youtube_dl/__init__.py", line 467, in _real_main
    retcode = ydl.download(all_urls)
  File "/usr/lib/python3/dist-packages/youtube_dl/YoutubeDL.py", line 2002, in download
    url, force_generic_extractor=self.params.get('force_generic_extractor', False))
  File "/usr/lib/python3/dist-packages/youtube_dl/YoutubeDL.py", line 793, in extract_info
    ie_result = ie.extract(url)
  File "/usr/lib/python3/dist-packages/youtube_dl/extractor/common.py", line 508, in extract
    ie_result = self._real_extract(url)
  File "/usr/lib/python3/dist-packages/youtube_dl/extractor/youtube.py", line 1672, in _real_extract
    token = video_info.get('token') or video_info.get('account_playback_token')
AttributeError: 'NoneType' object has no attribute 'get'

To be confirmed: this is not a issue from invidious.

@atahanacar

This comment has been minimized.

Copy link

commented Oct 9, 2019

12 hours ago, I had the same issue, but the issue is no longer there right now. Seems like Youtube changed some policies regarding connections.

@Perflyst

This comment has been minimized.

Copy link
Contributor

commented Oct 9, 2019

Your IP got blocked by Google, other instances face the same issues.

An example to test if you are blocked:

root@invidious:~# curl 'https://www.youtube.com/watch?v=ukDht4jRcT0&gl=US&hl=en&disable_polymer=1&has_verified=1&bpctr=9999999999'
<HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8">
<TITLE>302 Moved</TITLE></HEAD><BODY>
<H1>302 Moved</H1>
The document has moved
<A HREF="https://www.google.com/sorry/index?continue=https://www.youtube.com/watch%3Fv%3DukDht4jRcT0%26gl%3DUS%26hl%3Den%26disable_polymer%3D1%26has_verified%3D1%26bpctr%3D9999999999&amp;hl=en&amp;q=EgRf2BjmGJjv9uwFIhkA8aeDS2A2A_pZaQC7pukXkNR0Cy6xim-gMgFy">here</A>.
</BODY></HTML>
@PureTryOut

This comment has been minimized.

Copy link

commented Oct 9, 2019

I have the same error since like a week, but I get a full result if I try that test of @Perflyst.

@simmstein

This comment has been minimized.

Copy link
Author

commented Oct 9, 2019

By using my server as a proxy, I had to fill recaptcha to play a video on youtube.com (private tab).
By using curl, I had the full page and not a redirection.

@omarroth omarroth added the bug label Oct 9, 2019
@OdinGitDat

This comment has been minimized.

Copy link
Contributor

commented Oct 9, 2019

I have the same for every video on v0.19.1-d36c536 vanilla docker container.

How do other instances get around this if it's a block on Google's end?

@omarroth

This comment has been minimized.

Copy link
Owner

commented Oct 9, 2019

You will also want to check the output for /das_captcha which will also indicate rate-limiting:

$ curl 'https://www.youtube.com/watch?v=ukDht4jRcT0&gl=US&hl=en&disable_polymer=1&has_verified=1&bpctr=9999999999' -s | grep '/das_captcha
<form action="/das_captcha" method="POST">

Testing with youtube-dl should return a 429 as well if this is the case.

As @Perflyst mentioned, this is due to rate-limiting/IP banning by Google. This has been an issue for other projects as well, see fent/node-ytdl-core#444, Tyrrrz/YoutubeExplode#292, and ytdl-org/youtube-dl#21729.

If IPv6 is available for your box, I would recommend testing with force_resolve: ipv4 or force_resolve: ipv6 in your config. Otherwise, you'll unfortunately have to wait for Google to unban you or get a new IP.

@OdinGitDat

This comment has been minimized.

Copy link
Contributor

commented Oct 9, 2019

When I use a browser on my server to watch a video on youtube it asks for a captcha and then lets me watch videos for as long as the cookie stays in the browser.

Isn't there a way to relay this captcha to invidious webmasters and use the cookie for subsequent requests?

@omarroth

This comment has been minimized.

Copy link
Owner

commented Oct 9, 2019

It's possible. It's just not a practical workaround IMO since the cookie will only be valid for ~3 hours.

@jaruiz59

This comment has been minimized.

Copy link

commented Oct 10, 2019

Yep getting the same message .Video unavailable.

@asorel1942

This comment has been minimized.

Copy link

commented Oct 11, 2019

I don't quite understand what everyone in this thread means by hosting invidio locally. Is there a way to utilize the service without a browser? If so, will this be able to circumvent the "video is unavailable" messages everyone seems to be getting?

@BurnyBoi

This comment has been minimized.

Copy link

commented Oct 11, 2019

Does this mean invidio.us has been IP blocked by Google?

@HumanG33k

This comment has been minimized.

Copy link

commented Oct 11, 2019

Doing that they provide bad experience and people want to move back to YT. It’s a better option that blocking IP which provide badbuzz. They have done some similar things for ie when they downgrade qualities based on user agent in order to push FF users to Chrome.

@OdinGitDat

This comment has been minimized.

Copy link
Contributor

commented Oct 11, 2019

You can always host it locally to avoid the IP banning.

@nchristensen Can you please stop spreading this as a solution? The OP specifically has this problem on his own instance and so do I. Yes I am the only user of my instance, I watch max 10 videos a day, and I've still been banned twice within 3 days. Both my bans lasted 12 hours and afaik they all do.

I don't like to be pessimistic, but I think this may be the end of invidious if relaying a captcha/cookie is impractical as omarroth said.

@coolcoderplus

This comment has been minimized.

Copy link

commented Oct 11, 2019

Why not redirect instance traffic to tor > towards youtube? The ip of the instance will be protected from being banned. Or use some open proxies and couple it all with proxychains and tor, it would be perfect !

@simmstein

This comment has been minimized.

Copy link
Author

commented Oct 14, 2019

@coolcoderplus it could work but this is not a fix.

@Gert-dev

This comment has been minimized.

Copy link

commented Oct 15, 2019

@coolcoderplus I regularly use Tor and am often blocked by Google services due to "too much traffic". The list of endpoints is constantly changing, but likely the majority remains fairly constant. As also only a subset of Tor nodes function as actual endpoints, the pool of IP addresses is also said subset.

In a grossly simplifying sense, it's comparable to a dynamic list of proxies, of which the IP addresses end up flagged after a while.

@sentriz

This comment has been minimized.

Copy link

commented Oct 15, 2019

i am experiencing this on my home network too. youtube-dl doesn't work either. but surprisingly newpipe on my phone is working

@2secslater

This comment has been minimized.

Copy link
Contributor

commented Oct 15, 2019

I have a somewhat public instance (other folk can access it) running on my home network, and has been for rougly three days now. I have had the same IP address, using the instance most of the time and I haven't been sniped by Google (yet). My instance is running commit 7b77f20

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
You can’t perform that action at this time.