I’ve submitted my first major pull request, and I’d really appreciate it if more experienced contributors could spare a few minutes to review it.
It’s new code to leverage leverage Environment Canada weather data, and includes weather, sensor, and camera platforms, along with a simple component to pull them all together. https://github.com/home-assistant/home-assistant/pull/15353
Thanks in advance!
It’s all running fine locally, but to be honest I’m a bit stuck on getting it merged into the project. A large part of this is my lack of familiarity with Git, but there’s also been a bit of back and forth about whether there should be a component or not. Thanks for your interest, and I’ll try to move it forward.
The core team has been quite busy with their October bug and tidy blitz. I sure hope they can give you some priority now at least for some kind of Alpha release…
I would be pleased to try it here and provide feedback. I run Hassio on a Pi3+ and pretty much push it to its limits. Could be a good test for the component’s tolerance to problems. I’m not sure that I’d give the camera component much priority but the individual sensors and weather aggregate would both get a real-world workout here.
You’ve done very well with a fairly steep learning curve from what I can gather of the GH chronology. Keep up the great work!
Sorry, I could have been more clear about that. The components haven’t been merged in yet, so you need load them as custom components, or in the case of the sensor, sideload it.
The required files can be downloaded from the Dropbox link above, then the files need to be placed in the following folders:
The time between updates is not currently configurable in the config file, though I should probably make it that way. In the meantime, you can set it for both the sensor and weather components at line 40 of sesnor/environment_canada.py, and for the camera at line 36 of its file. Both lines currently read:
I just found this and it’s something that I really want to implement.
I’m getting the 3 Platform not found messages
I am running my Home Assistant in docker.
I placed the camera and weather in my custom_components folder which is inside the config folder.
So my path for these two are ~/home-assistant/config/custom_components/camera and ~/home-assistant/config/custom_components/weather
For the sensor platform I placed that inside the ~/home-assistant/dep folder.
I don’t know if that is right as all my other sensors are located inside the docker container but I can’t for the life of me paste or copy file contents into the envirment_canada.py file I created (I deleted the empty file before creating the one in /dep)
I’m running it in Docker too. I have my custom_components folder in the config root, with the camera and weather sub-folders underneath and the appropriate environment_canada.py file in each. The sensor file is also in the config root (but could be anywhere) and is mapped in as a core component.
Here’s how I’m mapping things in as part of my docker run command:
I have this in my docker run aswell. I assumed this created the config folder in ~/home-assistant instead of it being in /usr/src/app/homeassistant/config, it looks like my assumption was correct
For this one, is it basically saying the the file ec_sensor.py located in ~/home-assistant/ will appear (map) to be environment_canada.py and be found in /usr/src/app/homeassistant/components/sensor/?
I’m a bit confused though on this one, you mentioned this file was in the config root. Is that the ~/home-assistant/ folder or the ~/home-assistant/config folder?
On the host, my config folder is located at ~/home-assistant. In the container, this is mapped to /config, i.e. it’s right off the root of the container file system. This folder is where the custom_components subfolder should be, and there isn’t a config subfolder below this.
It doesn’t matter where the sensor file is on the host (or what it’s called), but it needs to be mapped into /usr/src/app/homeassistant/components/sensor/environment_canada.py in the container, because the weather component relies on it being there.
I realize that this is a bit clunky, and I have a plan of how to address it, but haven’t been able to yet. Let me know if you’re still stuck.