|
发表于 2018-2-8 20:53:06
|
显示全部楼层
本帖最后由 xingqiliuye 于 2018-2-8 22:31 编辑
加了语句 放了文件.. 但是什么也没有显示...
token文件都不自动生成. 应该是插件根本没有加载..
好吧我知道什么回事了.. 还要解压一级目录... 我以为是把PhicommTokenGetter文件夹直接放在config目录下...
但是整个ha启动不了了.. log里面是[homeassistant.bootstrap] Error loading /config/configuration.yaml: 13800138000"斐讯账号"[0m
真是想哭了.. 要把!secret 删掉....
[31m2018-02-08 22:22:10 ERROR (MainThread) [homeassistant.helpers.entity] Update for sensor.tokengetter fails[0mTraceback (most recent call last): File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 201, in async_update_ha_state yield from self.async_device_update() File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 308, in async_device_update yield from self.hass.async_add_job(self.update) File "/usr/lib/python3.6/asyncio/futures.py", line 332, in __iter__ yield self # This tells Task to wait for completion. File "/usr/lib/python3.6/asyncio/tasks.py", line 250, in _wakeup future.result() File "/usr/lib/python3.6/asyncio/futures.py", line 245, in result raise self._exception File "/usr/lib/python3.6/concurrent/futures/thread.py", line 56, in run result = self.fn(*self.args, **self.kwargs) File "/config/custom_components/sensor/PhicommTokenGetter.py", line 137, in update with open(self._tokenPath, 'w') as f:FileNotFoundError: [Errno 2] No such file or directory: '/home/homeassistant/.homeassistant/phicomm_token.txt'[0m
不但配置文件要改路径 python文件也要改路径.. 算了. 还是用默认路径了
|
|