[MacPorts] #58638: port:youtube-dl : upgrade and performance improvement
MacPorts
noreply at macports.org
Tue Jun 25 13:48:06 UTC 2019
#58638: port:youtube-dl : upgrade and performance improvement
-------------------------+------------------------
Reporter: RJVB | Owner: ryandesign
Type: enhancement | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version:
Keywords: haspatch | Port: youtube-dl
-------------------------+------------------------
This started out when I noticed that `youtube-dl` is a zipped "script
bundle" which means that it has to be inflated and byte-compiled on each
and every invocation. That takes a noticeable amount of time, even on a
faster machine. Testing shows that startup time becomes roughly 4x shorter
when you install the application as a regular, uncompressed set of python
scripts, of which bytecode can be cached.
The patch introduces a +unpacked variant which creates such an install. It
takes a post-destroot approach, inflating the actual script, in order to
ensure that the exact same code will be executed. In-app upgrades are
impossible with this kind of install so there is no need to disable them
via a hack.
I propose to drop the compulsory use of a MacPorts Python interpreter; the
system one does just fine. The proposed +stock variant creates an install
that is the pure stock version. I see no hard reason to ban in-app
upgrades for such an install (the script will replace itself), leaving a
backdoor for people who somehow need the latest versions *now*.
The upgrade to the current version is almost an afterthought :)
--
Ticket URL: <https://trac.macports.org/ticket/58638>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list