Over the last few months I’ve made myself familiar with the structure of HA and its components, integrations, plugins. Also developed some for internal use. Running HA on a home server in a docker environment.
Now I want to enhance the NetData component which is part of core. I’d like to also optionally collect alarms from the NetData host and show a green/yellow/red indicator depending on the alarm status at any given time.
I already know how to do that, developed and use a prototype of a custom component for a long period of time successfully. Only downside, there is duplicated code in the core component and my custom component. I’d like to bring my enhancement to the core component. It’s only minimal code change and it will deliver huge extra benefit.
My question is: how do I best enhance an existing core component, use it as a custom component as a replacement for the time being such that if my enhancement gets accepted, I can then switch back to the core component without having to change all my UI and automations - i.e. I want to make sure that the entity names remain the same.
Also, where do you expect such an enhancement being proposed? I guess a PR on GitHub might work but it frightens me a bit because it being one big repository for all of HA and not just that one component.
Hope somebody can help me with this. It’s actually a best practice question I guess.
If you want it to be core, PR on github. Clearly explain your reasons for the changes / enhancements follow the guidelines and be thick skinned about the response you may receive.
That’s what I did and setting up the development environment was quite clearly explained in the dev docs. That’s fine.
With regard to utilizing my changes while not yet being merged, I wrote a little script which copies the changed files into the Docker container and then restarts my HA instance. Working quite nicely.
But I’m also on the Discord server and will hopefully contribute there too soon.
@pydog setting up a development environment is best described in the dev docs.
As soon as you fixed the bug and created a PR on GitHub for it, you could use my approach to patch your production environment in Docker with something like this: