0.67 whitelisted dir issues

Hello everyone

So I upgraded to 0.67 and I get errors with my file sensor component it basically throws the following errors:

2018-04-14 01:03:05 ERROR (MainThread) [homeassistant.components.sensor.file] '/home/homeassistant/.homeassistant/python_scripts/1.txt' is not a whitelisted directory
2018-04-14 01:03:05 ERROR (MainThread) [homeassistant.components.sensor.file] '/home/homeassistant/.homeassistant/python_scripts/2.txt' is not a whitelisted directory
2018-04-14 01:03:05 ERROR (MainThread) [homeassistant.components.sensor.file] '/home/homeassistant/.homeassistant/python_scripts/3.txt' is not a whitelisted directory
2018-04-14 01:03:16 WARNING (MainThread) [homeassistant.setup] Setup of config is taking over 10 seconds.

Also mqtt switches which I have setup dont appear anymore on my frontend.

Is anyone else experiencing the same issues?


can you show the configuration for how you whitelisted it? would be helpful to others who update

I havent whitelisted it yet how do I do that?

1 Like

right I resolved that by adding the following to my config:

     - /home/homeassistant/.homeassistant/

Perfect, just came across same situation, and only found that default whitelisted directory is www/ under the config root directory. It is like that since 0.48 or something, wonder why this was working until upgrade to 0.67 :slight_smile:

I had the same failure after 0.67 with a file sensor

ERROR (MainThread) [homeassistant.components.sensor.file] ‘/home/thomas/.homeassistant/file.txt’ is not a whitelisted directory

fixed by: whitelist_external_dirs:

@thomas70 I created a PR to address your issue here


Got stung by the same problem. Trying to add the whitelist_external_dirs: for a file called speech.txt in the config directory. I have tried;


Any help is appreciated!

I don’t think you need to whitelist that directory but you need to create a new one, place the file in there and whitelist the new directory.

config/newdir is what should be whitelisted

Thanks for the reply. Tried that by adding a directly named speech to config and got the following error.

2018-04-27 14:41:56 ERROR (MainThread) [homeassistant.config] Invalid config for [homeassistant]: not a directory @ data[‘whitelist_external_dirs’][0]. Got ‘config/speech’. (See /config/configuration.yaml, line 2).

oh sorry for got 1 character :slight_smile: /config/speech

Thanks! That solved one error. Now I have this on the sensor. Any thoughts?

2018-04-27 15:35:09 ERROR (MainThread) [homeassistant.config] Invalid config for [sensor.file]: not a file for dictionary value @ data[‘file_path’]. Got ‘config\speech\speech.txt’. (See ?, line ?).

Is it the \ again?

yup, you need it to match

Thanks. I really appreciate your time and help!

because in my case it does not work in / backup but does / share work?