This is a problem which more distributions have, but given the rate of change of the youtube-dl project I see a major mismatch between what Nix wants to offer, which is stability and the inherent instabity of youtube-dl.
I would like to see youtube-dl built at least everyday (but preferably every release of the upstream project).
One way to solve the larger problem of essentially executing arbitrary code on a machine would be to provide some small VM (docker/don't care) on which the program would be executed (such that there is no data being leaked into the VM environment).
I don't particularly care about the final solution you might pick in the end (one of them would be to consciously make the choice to not package it anymore).
See below for an example interaction.
nix-env -i youtube-dl &&
~/.nix-profile/bin/youtube-dl 'https://www.youtube.com/watch?v=ZBpkvR2-nQo2H'
results in a pile of errors (last one is)
AttributeError: 'module' object has no attribute 'sslwrap'
Nix 16.03 (Ubuntu 14.04.4 LTS)
I've been using youtube-dl quite frequently and it works just fine in the master branch. So probably all that would need to be done is to make sure new versions from master are back-ported to release-16.03 regularly -- or least more often that we do it right now. This is something you, @0xABAB, could actually help us with, i.e. by creating a PR every now and then.
I believe the immediate issue has been resolved by https://github.com/NixOS/nixpkgs/pull/16985
I tested youtube-dl on release-16.03 a few days ago and was unable to download a video. I don't remember the exact error message :-( Anyway, I cherry-picked the updates that are on master to release-16.03 and now I'm able to download that video.
@joachifm: Thanks for the ref.
That error ("AttributeError: 'module' object has no attribute 'sslwrap'") might be due to something else though. (I don't see why that error would appear just because youtube-dl is "old".)
Btw, I successfully ran this in Ubuntu 16.04 (not 14.04... I only had 16.04 readily available):
$ curl https://nixos.org/nix/install | sh
...
$ nix-env -i youtube-dl
$ youtube-dl 'https://www.youtube.com/watch?v=ZBpkvR2-nQo2H'
[download success]
That was on the nixpkgs-unstable channel, nix-instantiate --eval '<nixpkgs>' -A lib.nixpkgsVersion => "16.09pre86805.3223ef5".
Most helpful comment
I've been using youtube-dl quite frequently and it works just fine in the
masterbranch. So probably all that would need to be done is to make sure new versions frommasterare back-ported torelease-16.03regularly -- or least more often that we do it right now. This is something you, @0xABAB, could actually help us with, i.e. by creating a PR every now and then.