esphome / esphome/feature-requests
Support additional components via pkg_resources entry points
- Dominant language
- No language data
- Stars
- 450
- Forks
- 29
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the problem you have/What new integration you would like**
Define an entry point for esphome (say `esphome.components`) for other python packages to advertise the presence of more components. Entry points are part of the [pkg_resources](https://setuptools.readthedocs.io/en/latest/pkg_resources.html#entry-points) package.
**Please describe your use case for this integration and alternatives you've tried:**
The primary use case would be to make more components available outside of the main esphome distribution, allow third parties to more easily add, test and package components outside of the esphome release cycle.
Another side benefit could be to separate components into smaller collections of related functionality or allow components to be on a different release cycle from the core platform.
In practice, a package would include an entry in their setup.cfg (or setup.py) eg:
[options.entry_points]
esphome.components =
my_components_name = my_package.components
ESPHome would then also use `my_package.components` when searching for matching components.
**Additional context**
I'd be happy to produce a proof of concept for this idea (am very familiar for the operation of entrypoints).
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the linked pkg_resources entry-point documentation and the setup.cfg/setup.py examples in the request. Locate ESPHome's component-discovery path and determine how external packages would be discovered and loaded; done means the integration approach, compatibility concerns, and validation coverage are defined.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- embedded-iot
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100