[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [emms-help] emms-stream constantly adds metadata to urls
From: |
Yoni Rabkin |
Subject: |
Re: [emms-help] emms-stream constantly adds metadata to urls |
Date: |
Sun, 08 Sep 2019 21:41:43 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) |
Konstantin Reich <address@hidden> writes:
> Hi,
>
> Any url added after a stream from the EMMS Streams interface has the stream
> metadata.
> I think it is a bug.
>
> One can reproduce it with the following steps.
>
> 1. (emms-streams)
> 2. Choose any stream
> 3. The stream has some metadata which is written in emms-stream-last-stream.
> 4. add url through emms-add-url.
> 5. The url has the same metadata.
>
> I can suggest the following correction:
>
>
> diff -u /tmp/emms-streams.el.orig /tmp/emms-streams.el
> --- /tmp/emms-streams.el.orig 2019-09-08 18:23:57.153293137 +0300
> +++ /tmp/emms-streams.el 2019-09-08 18:18:46.571817962 +0300
> @@ -602,7 +602,9 @@
> ; (add-to-list 'emms-info-methods-list 'emms-info-url)
>
> (defun emms-stream-add-data-to-track (track)
> - (emms-track-set track 'metadata emms-stream-last-stream))
> + (when emms-stream-last-stream
> + (emms-track-set track 'metadata emms-stream-last-stream)
> + (setq emms-stream-last-stream nil)))
>
> (add-to-list 'emms-track-initialize-functions
> 'emms-stream-add-data-to-track)
Thank you for catching this.
However, emms-steams.el is going to be completely replaced (see:
https://lists.gnu.org/archive/html/emms-help/2019-08/msg00000.html). I'll
hang onto this patch in case it is needed in the new implementation.
--
"Cut your own wood and it will warm you twice"