Can't stream local mp3 to Google Cast Audio

I tried that earlier but that didn’t work. I assumed that would be because I have SSL enabled (?).

I guess so

Yes, because of SSL.

I’m sorry that I wasn’t clearer on my post; I thought that you would see it as an example and instead replace that with the actual folder you were using.

No need to apologize!

I replaced it with my own credentials, the "local’ instead of “www” did the trick

Well back to square one…
Suddenly stopped working after updating to 0.36 + installing the picotts library…

MP3 plays fine in my browser

same for me after updating to 0.36

Permissions look fine on the www folder (right?).

Can’t it be it has something to do with root user instead of home assistant user?

Traceback error

17-01-16 20:30:30 aiohttp.server: Error handling request
Traceback (most recent call last):
  File "/home/pi/.homeassistant/deps/aiohttp/web_server.py", line 61, in handle_request
    resp = yield from self._handler(request)
  File "/home/pi/.homeassistant/deps/aiohttp/web.py", line 249, in _handle
    resp = yield from handler(request)
  File "/usr/lib/python3.4/asyncio/coroutines.py", line 143, in coro
    res = yield from res
  File "/usr/lib/python3.4/asyncio/coroutines.py", line 143, in coro
    res = yield from res
  File "/usr/local/lib/python3.4/dist-packages/homeassistant/components/http/static.py", line 62, in static_middleware_handler
    resp = yield from handler(request)
  File "/home/pi/.homeassistant/deps/aiohttp/web_urldispatcher.py", line 486, in _handle
    ret = yield from self._file_sender.send(request, filepath)
  File "/home/pi/.homeassistant/deps/aiohttp/file_sender.py", line 201, in send
    yield from self._sendfile(request, resp, f, count)
  File "/usr/local/lib/python3.4/dist-packages/homeassistant/components/http/static.py", line 30, in sendfile
    yield from orig_sendfile(request, resp, fobj, count)
  File "/home/pi/.homeassistant/deps/aiohttp/file_sender.py", line 108, in _sendfile_system
    yield from fut
  File "/usr/lib/python3.4/asyncio/futures.py", line 388, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.4/asyncio/tasks.py", line 286, in _wakeup
    value = future.result()
  File "/usr/lib/python3.4/asyncio/futures.py", line 269, in result
    raise CancelledError
concurrent.futures._base.CancelledError

more users reporting the same issue:
https://community.home-assistant.io/t/36-0-aiohttp-update-errors/9782

To be fair, we don’t know that to be the case yet. The user was reporting errors with the conversation component and hasn’t reported back yet if disabling conversation solved his particular error.

This issue on github may be more applicable though:

You may want to look it over and see if you should be adding your observations.

After updating to 0.36.1 it works again

Great, will test tonight as soon as I get home

Well, after updating to 0.36.1, errors are still here:

Traceback (most recent call last):
  File "/home/homeassistant/.homeassistant/deps/aiohttp/web_server.py", line 61, in handle_request
    resp = yield from self._handler(request)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/web.py", line 249, in _handle
    resp = yield from handler(request)
  File "/usr/lib/python3.4/asyncio/coroutines.py", line 143, in coro
    res = yield from res
  File "/usr/lib/python3.4/asyncio/coroutines.py", line 143, in coro
    res = yield from res
  File "/srv/homeassistant/homeassistant_venv/lib/python3.4/site-packages/homeassistant/components/http/static.py", line 62, in static_middleware_handler
    resp = yield from handler(request)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/web_urldispatcher.py", line 486, in _handle
    ret = yield from self._file_sender.send(request, filepath)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/file_sender.py", line 201, in send
    yield from self._sendfile(request, resp, f, count)
  File "/srv/homeassistant/homeassistant_venv/lib/python3.4/site-packages/homeassistant/components/http/static.py", line 30, in sendfile
    yield from orig_sendfile(request, resp, fobj, count)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/file_sender.py", line 60, in _sendfile_system
    yield from self._sendfile_fallback(request, resp, fobj, count)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/file_sender.py", line 137, in _sendfile_fallback
    resp.set_tcp_nodelay(True)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/web_reqrep.py", line 737, in set_tcp_nodelay
    resp_impl.transport.set_tcp_nodelay(value)
  File "/home/homeassistant/.homeassistant/deps/aiohttp/parsers.py", line 253, in set_tcp_nodelay
    self._socket.setsockopt(socket.IPPROTO_TCP, CORK, False)
OSError: [Errno 9] Bad file descriptor

And still no mp3 play

arrffff, it worked this morning and not anymore. I am rebooting my pi and give another try.

Looks like there is a fix here: https://github.com/home-assistant/home-assistant/pull/4118/commits/50dcb1df4c4e0880f5f2b06f3c588d39e48b7a7b

I don’t have a clue how to implement it though, I can’t navigate to the /home/homeassistant/components folder (doesn’t exist). It also doesn’t exist in the .homeassistant folder

The fix has been merged on Oct 30, 2016.

The reboot didn’t help. I have downgraded HA to 0.35.3 and it works fine. So now I am going to upgrade it to 0.36.1 and give another try.

Good luck, let me know if it makes any difference please

It doesn’t work. I have reopen the issue on GitHub.

You should had your traceback, it seems a little bit different than mine but we have the same issue.

Here is the link
https://github.com/home-assistant/home-assistant/issues/5375

Thanks for your assistance, much appriciated!

I reverted back to 0.35.3 for now and everything is working as it’s supposed to be :slight_smile:

Traceback added on Github

In case anyone is still reading this: working again on 0.41.0.

3 Likes