question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The script at https://yt-dl.org/downloads/latest/youtube_dl doesn't works at Ubuntu 20.04.

See original GitHub issue

Checklist

  • I’m reporting a broken site support issue
  • [x ] I’ve verified that I’m running youtube-dl version 2021.01.03
  • [x ] I’ve checked that all provided URLs are alive and playable in a browser
  • [x ] I’ve checked that all URLs and arguments with special characters are properly quoted or escaped
  • [x ] I’ve searched the bugtracker for similar bug reports including closed ones
  • [x ] I’ve read bugs section in FAQ

Verbose log

/usr/bin/env: 'python': No such file or directory

Description

The script at https://yt-dl.org/downloads/latest/youtube_dl use ‘python’ binary which is not existing at Ubuntu 20.04 and this introduces a bug that the script cannot find the ‘python’ binary. The only python binaries by default are ‘python3, python3.8, python3-futurize, python3-pasteurize’. So simple symbolic link can solve the issue.

Since there is no support for “python 2” anymore. I think this bug exist in many OS’s and further investigation is needed.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6

github_iconTop GitHub Comments

2reactions
rautamiekkacommented, Jan 3, 2021

^ The recurrence, the fact ppl can’t google, and the fact distros are being dicks are exactly the reasons why something has to be done.

But that’ll be problematic cuz the way the mentioned “binary” is created you can’t target Py2 and 3 with the same line, and you can’t have multiple shebangs, and you can’t have any code before the shebang.

^ The only way to circumvent that is a db of default Python versions (2 or 3, no need for stricter) for the script which creates the “binary”. Which, to be blunt, is gonna be an impossible cat-and-mouse.

^ And don’t get me started on the CI using separate distros running [near-]identical scripts.

0reactions
Kikobeatscommented, Jul 11, 2021

If you are under a Node.js project, consider using youtube-dl-exec since it checks for python version before installing the dependency, throwing an error if the right Python version is not found.

Read more comments on GitHub >

github_iconTop Results From Across the Web

【FranceTV】Download no longer possible #29956 - GitHub
It's working fine for me with the patch ! I'm on kubuntu 20.04, youtube-dl 2021.12.17, I patched it with youtube-dl-patch.txt and I have...
Read more >
Youtube-dl: Python not found (18.04) - Ask Ubuntu
The head of the youtube-dl script has #!/usr/bin/env python , meaning that it uses the "python" command. Per https://www.python.org/dev/peps/pep ...
Read more >
How to install & upgrade Youtube-dl on Ubuntu 20.04 - write
Downloading, installing and upgrading Youtube-dl on Ubuntu 20.04 ... sudo curl -L https://yt-dl.org/downloads/latest/youtube-dl -o ...
Read more >
Download YouTube Videos With Subtitles Using Youtube-dl
First download the youtube-dl script using curl or wget as shown below. $ sudo curl -L https://yt-dl.org/downloads/latest/youtube-dl -o ...
Read more >
Kubuntu Linux 20.04 for a digital painting workstation
In the settings: Windows Management > Windows behavior > Windows Action: Switch the Modifier 'Alt key' to 'Meta key'. Deactivate the hot corner....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found