lzoubek / xbmc-plugin-mpdc

XBMC plugin for remote control of multiple MPD servers
GNU General Public License v3.0
20 stars 13 forks source link

Auto-play if MPD is playing breaks. #34

Open Fludizz opened 7 years ago

Fludizz commented 7 years ago

When starting the MPD client on Kodi 17 (OpenElec 8), it raises the following error:

11:41:41.287 T:1859122080 ERROR: Traceback (most recent call last): 11:41:41.288 T:1859122080 ERROR: File "/storage/.kodi/addons/script.mpdc/resources/lib/gui.py", line 219, in _connect 11:41:41.289 T:1859122080 ERROR: self._handle_changes(self.client,['mixer','playlist','player','options']) 11:41:41.289 T:1859122080 ERROR: File "/storage/.kodi/addons/script.mpdc/resources/lib/gui.py", line 639, in _handle_changes 11:41:41.289 T:1859122080 ERROR: self._update_player_controls(current,state) 11:41:41.290 T:1859122080 ERROR: File "/storage/.kodi/addons/script.mpdc/resources/lib/gui.py", line 622, in _update_player_controls 11:41:41.290 T:1859122080 ERROR: self.update_playlist('play',current) 11:41:41.290 T:1859122080 ERROR: File "/storage/.kodi/addons/script.mpdc/resources/lib/gui.py", line 695, in update_playlist 11:41:41.290 T:1859122080 ERROR: self._play_stream() 11:41:41.290 T:1859122080 ERROR: File "/storage/.kodi/addons/script.mpdc/resources/lib/gui.py", line 866, in _play_stream 11:41:41.290 T:1859122080 ERROR: player = xbmc.Player(xbmc.PLAYER_CORE_MPLAYER) 11:41:41.290 T:1859122080 ERROR: AttributeError: 'module' object has no attribute 'PLAYER_CORE_MPLAYER' It subsequently fails to auto-play the stream and exits out the plugin.

This can be fixed by replacing player = xbmc.Player(xbmc.PLAYER_CORE_MPLAYER) on line 866 in gui.py with player = xbmc.Player()