|
发表于 2018-4-17 10:54:02
|
显示全部楼层
本帖最后由 yoyosuka 于 2018-4-17 11:35 编辑
小米电视4A待测试。
4A50吋报错,
Error executing service <ServiceCall media_player.turn_on: entity_id=['media_player.xiaomi_tv']>Traceback (most recent call last): File "/usr/local/lib/python3.6/site-packages/urllib3/connection.py", line 141, in _new_conn (self.host, self.port), self.timeout, **extra_kw) File "/usr/local/lib/python3.6/site-packages/urllib3/util/connection.py", line 83, in create_connection raise err File "/usr/local/lib/python3.6/site-packages/urllib3/util/connection.py", line 73, in create_connection sock.connect(sa)OSError: [Errno 113] No route to hostDuring handling of the above exception, another exception occurred:Traceback (most recent call last): File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 601, in urlopen chunked=chunked) File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 357, in _make_request conn.request(method, url, **httplib_request_kw) File "/usr/local/lib/python3.6/http/client.py", line 1239, in request self._send_request(method, url, body, headers, encode_chunked) File "/usr/local/lib/python3.6/http/client.py", line 1285, in _send_request self.endheaders(body, encode_chunked=encode_chunked) File "/usr/local/lib/python3.6/http/client.py", line 1234, in endheaders self._send_output(message_body, encode_chunked=encode_chunked) File "/usr/local/lib/python3.6/http/client.py", line 1026, in _send_output self.send(msg) File "/usr/local/lib/python3.6/http/client.py", line 964, in send self.connect() File "/usr/local/lib/python3.6/site-packages/urllib3/connection.py", line 166, in connect conn = self._new_conn() File "/usr/local/lib/python3.6/site-packages/urllib3/connection.py", line 150, in _new_conn self, "Failed to establish a new connection: %s" % e)urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPConnection object at 0x7fb1b4793b00>: Failed to establish a new connection: [Errno 113] No route to hostDuring handling of the above exception, another exception occurred:Traceback (most recent call last): File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 440, in send timeout=timeout File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "/usr/local/lib/python3.6/site-packages/urllib3/util/retry.py", line 388, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause))urllib3.exceptions.MaxRetryError: HTTPConnectionPool(host='192.168.99.75', port=6095): Max retries exceeded with url: /controller?action=keyevent&keycode=power (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fb1b4793b00>: Failed to establish a new connection: [Errno 113] No route to host',))During handling of the above exception, another exception occurred:Traceback (most recent call last): File "/usr/src/app/homeassistant/core.py", line 1002, in _event_to_service_call await service_handler.func(service_call) File "/usr/src/app/homeassistant/components/media_player/__init__.py", line 403, in async_service_handler yield from getattr(player, method['method'])(**params) File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run result = self.fn(*self.args, **self.kwargs) File "/config/custom_components/media_player/xiaomi_tv.py", line 110, in turn_on self._tv.wake() File "/usr/local/lib/python3.6/site-packages/pymitv/tv.py", line 35, in wake return self._sendKeystroke(Control.wake); File "/usr/local/lib/python3.6/site-packages/pymitv/tv.py", line 23, in _sendKeystroke return Control().sendKeystrokes(self.ip, keystroke) File "/usr/local/lib/python3.6/site-packages/pymitv/control.py", line 32, in sendKeystrokes r = requests.get(tv_url + keystroke) File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 72, in get return request('get', url, params=params, **kwargs) File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 508, in send raise ConnectionError(e, request=request)requests.exceptions.ConnectionError: HTTPConnectionPool(host='192.168.99.75', port=6095): Max retries exceeded with url: /controller?action=keyevent&keycode=power (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fb1b4793b00>: Failed to establish a new connection: [Errno 113] No route to host',))
|
|