Hi,
This is essentially a question about Travis for which I apologise in advance
I’ve been using the GitHub & Travis setup for a long time without a problem. However, I recently started playing with MySensors and the configuration for MySensors breaks the Travis build and I can’t figure out how to stop it.
Right now my config is
mysensors:
gateways:
- device: mqtt
persistence_file: !secret mspf
topic_in_prefix: 'mygateway1-out'
topic_out_prefix: 'mygateway1-in'
version: '2.0'
optimistic: false
persistence: true
retain: true
The problem being the
persistence_file: !secret mspf
line which has said various other things like explicit filenames and paths and various relative paths. I’ve also tried creating the persistence file in the same way travis_secrets/secrets is created or just adding the persistence file to my commit AND I’ve tried putting the file in various locations on the computer.
Every time the build fails with
ERROR (MainThread) [homeassistant.config] Invalid config for [mysensors]: /home/homeassistant/.homeassistant directory does not exist or is not writetable for dictionary value @ data[‘mysensors’][‘gateways’][0][‘persistence_file’]. Got ‘/home/homeassistant/.homeassistant/mysensors.json’. (See /home/travis/build/stetho/home-assistant/./configuration.yaml, line 59). Please check the docs at https://home-assistant.io/components/mysensors/
2017-09-04 10:30:24 ERROR (MainThread) [homeassistant.setup] Setup failed for mysensors: Invalid config.
What this appears to be is that Travis can’t find that directory which is probably correct since it wouldn’t exist in the build environment. But what appears to be specifically failing is that it’s “not writeable”. That is - although this is a different error - things like adding
before_install:
touch mysensors.json
And then changing the config to
persistence_file: './mysensors.json'
Produces exactly the same error.
What’s further confusing me is that I have other components that refer to files on the local file system that don’t break the build.
Does anyone know what I need to do to get the build to get past this problem?
Again - sincere apologies for asking a Travis question. This just seemed the right place to ask.
Steve