Hey hey.

I use the heck out of tuedachu/ytdl. One thing I would like to improve about it is that when you queue a download with ytdl-download it appears to be a synchronous call and it freezes emacs until youtube-dl/yt-dlp is able to start the actual download.

I’ve yet to dive into the code to see what synchronous function is being called – I’m very aware of the “single-threaded” nature of Emacs – but I use other libraries that are likely shelling and they do not hang like this and so I would like to see if there’s a way to I can bring whatever technique they are using over to a PR against tuedachu/ytdl.

Appreciate any advice from the crew here.

1 point

Multi-processing is the only way for staying asynchronous.

permalink
report
reply

I use dwim shell command for these things (async by default). For example https://github.com/xenodium/dwim-shell-command/blob/e4a139fe181ed1b576302fb36f3761fbf9914580/dwim-shell-commands.el#L83C7-L83C7

Disclosure: authored the package

permalink
report
reply

Emacs

!emacs@communick.news

Create post

A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!

Get Emacs

  • Windows
  • Mac OS X
  • GNU/Linux and BSD (Just get it from your distribution’s package manager)

Rules

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for “emacs” and “vi” link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

Community stats

  • 18

    Monthly active users

  • 562

    Posts

  • 2.4K

    Comments