{"action":"created","issue":{"url":"https://api.github.com/repos/balloob/home-assistant/issues/432","labels_url":"https://api.github.com/repos/balloob/home-assistant/issues/432/labels{/name}","comments_url":"https://api.github.com/repos/balloob/home-assistant/issues/432/comments","events_url":"https://api.github.com/repos/balloob/home-assistant/issues/432/events","html_url":"https://github.com/balloob/home-assistant/issues/432","id":107838504,"number":432,"title":"MediaPlayer Resolving State With Wrong Service Calls","user":{"login":"maddox","id":260,"avatar_url":"https://avatars.githubusercontent.com/u/260?v=3","gravatar_id":"","url":"https://api.github.com/users/maddox","html_url":"https://github.com/maddox","followers_url":"https://api.github.com/users/maddox/followers","following_url":"https://api.github.com/users/maddox/following{/other_user}","gists_url":"https://api.github.com/users/maddox/gists{/gist_id}","starred_url":"https://api.github.com/users/maddox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maddox/subscriptions","organizations_url":"https://api.github.com/users/maddox/orgs","repos_url":"https://api.github.com/users/maddox/repos","events_url":"https://api.github.com/users/maddox/events{/privacy}","received_events_url":"https://api.github.com/users/maddox/received_events","type":"User","site_admin":true},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-09-23T02:26:17Z","updated_at":"2015-09-24T03:34:11Z","closed_at":null,"body":"In testing my Good Night scene, I noticed that my media player was not actually getting paused.\r\n\r\n```yaml\r\n  - name: Good Night\r\n    entities:\r\n      media_player.itunes: paused\r\n      media_player.kitchen_music_airtunes_speaker: on\r\n      media_player.family_room_airtunes_speaker: off\r\n      media_player.deck_airtunes_speaker: off\r\n      media_player.kitchen_airtunes_speaker: off\r\n      media_player.bedroom_airtunes_speaker: off\r\n      media_player.office_airtunes_speaker: off\r\n      switch.kitchen_tv: off\r\n      switch.family_room_tv: off\r\n      light.living_room_left: off\r\n      light.living_room_right: off\r\n      light.living_room_lamp: off\r\n      light.family_room_left: off\r\n      light.family_room_right: off\r\n      light.family_room_lamp: off\r\n      light.family_room_window:\r\n        state: on\r\n        brightness: 50\r\n```\r\n\r\nWith some digging around I found this error:\r\n\r\n```\r\n15-09-22 21:42:29 WARNING (Thread-20) [homeassistant.helpers.state] reproduce_state: Unable to reproduce state <state media_player.itunes=paused @ 21:38:11 22-09-2015>\r\n```\r\n\r\nWith more digging, I found this:\r\n\r\n```\r\n15-09-22 21:48:37 INFO (Thread-34) [homeassistant.core] Bus:Handling <Event call_service[L]: service=media_play_pause, domain=media_player, service_call_id=4507326728-21, entity_id=media_player.itunes>\r\n```\r\n\r\nSpecifically this part: `service=media_play_pause `\r\n\r\nThe iTunes media player does not implement the `play_pause` method, so this is failing. More importantly, it shouldn't be calling this service. It should be calling the discrete methods for `play` and `pause`, rather than the toggle.\r\n\r\nI did some spelunking, but couldn't really figure out where it was making the decision to use this service call."},"comment":{"url":"https://api.github.com/repos/balloob/home-assistant/issues/comments/142797245","html_url":"https://github.com/balloob/home-assistant/issues/432#issuecomment-142797245","issue_url":"https://api.github.com/repos/balloob/home-assistant/issues/432","id":142797245,"user":{"login":"maddox","id":260,"avatar_url":"https://avatars.githubusercontent.com/u/260?v=3","gravatar_id":"","url":"https://api.github.com/users/maddox","html_url":"https://github.com/maddox","followers_url":"https://api.github.com/users/maddox/followers","following_url":"https://api.github.com/users/maddox/following{/other_user}","gists_url":"https://api.github.com/users/maddox/gists{/gist_id}","starred_url":"https://api.github.com/users/maddox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maddox/subscriptions","organizations_url":"https://api.github.com/users/maddox/orgs","repos_url":"https://api.github.com/users/maddox/repos","events_url":"https://api.github.com/users/maddox/events{/privacy}","received_events_url":"https://api.github.com/users/maddox/received_events","type":"User","site_admin":true},"created_at":"2015-09-24T03:34:11Z","updated_at":"2015-09-24T03:34:11Z","body":"OK, you were right. It must have been a stray call in the logs. So the only issue seems to be the:\r\n\r\n```\r\n15-09-22 21:42:29 WARNING (Thread-20) [homeassistant.helpers.state] reproduce_state: Unable to reproduce state <state media_player.itunes=paused @ 21:38:11 22-09-2015>\r\n```\r\n\r\n...due to the fact that it's asking for a state that isn't supported. This is sort of unfortunate :("}}