Page 1 of 1

HTTP Stream: Tracks switch every second

Posted: February 15th, 2021, 10:39 am
by thomas
Hi,

I use HTTP stream (mpd 0.22.4), here is my very basic config:

Code: Select all

audio_output {
  type    "httpd"
  name    "MPD"
  encoder   "lame"    # optional
  port    "8000"
  bitrate   "256"     # do not define if quality is defined
  format    "44100:16:2"
  always_on       "yes"     # prevent MPD from disconnecting all listeners when playback is stopped.
  tags            "yes"     # httpd supports sending tags to listening streams.
  max_clients "0"     # optional 0=no limit
}
When playing current track after a "long" pause (more than a minute), tracks switch to the next very quickly (every second). At this time, sometimes I can still listen tracks with my client even if I pause it, sometimes client exited. It happens also if I stop client myself.
To fix that, I have to stop my streaming client, and pausing current track. Then I can restart playing and start client.
There is nothing in logs about that.

This issue happens very often but I don't know what to do. Can you help me please?

Re: HTTP Stream: Tracks switch every second

Posted: February 15th, 2021, 11:25 am
by max
I don't understand. Can you rephrase, and be more specific? Maybe a verbose log would help.

Re: HTTP Stream: Tracks switch every second

Posted: February 15th, 2021, 2:27 pm
by thomas
OK, sorry, english is not my first language.
Even with "log_level" to verbose, there is nothing interesting , but I understand a little more what happened.

Here the steps to reproduce the issue:
  1. I start playing music:

    Code: Select all

    mpc play ; mpv http://localhost:8000
    It works!
  2. Then I pause music:

    Code: Select all

    mpc pause
    So "mpc status" tells mpd is in "[paused]".
  3. I wait 10 minutes in pause mode then I listen music again :

    Code: Select all

    mpc play
    But it plays immediatly the track it should play 10 minutes later, like if mpd was not in pause mode.
I hope it's easier to understand. Thanks!

Re: HTTP Stream: Tracks switch every second

Posted: February 16th, 2021, 6:08 am
by max
"mpc play" re-starts playback at whatever song is the current song. This is not the proper way to resume playback after "pause". You can use "mpc toggle" to resume playback properly.

Re: HTTP Stream: Tracks switch every second

Posted: February 16th, 2021, 7:10 am
by thomas
Hi,

I said I use "mpc pause" and "mpc play" to be specific/explicit, but in reality, I only use "mpc toggle". But it doesn't change anything at the issue.

Re: HTTP Stream: Tracks switch every second

Posted: February 16th, 2021, 12:20 pm
by max
So your instructions above were wrong. They were very specific, but they were wrong. That's not helpful. It's a waste of time. Now we need to start from scratch analyzing your problem.