Hi, This is my first post to the community, so hope its in the right place…
In the release notes for the latest version there is a breaking change for the way custom components work.
“We finished the great migration. All built-in platforms are now in their own folder. This means that if you had a custom component or platform that had the same name as a built-in one, you have to rename it. If you still have platforms in your custom_components/
directory in the old file format, sensor/my_platform.py
, rename it to my_platform/sensor.py
. It still works but it will not be supported in a future release.”
I’m using one such integration for Sonoff switches using original firmware ( https://github.com/peterbuga/HASS-sonoff-ewelink ), so after the upgrade I altered the directory structure and naming conventions as per the release notes and it all broke… (sensors and switches unavailable, with a mis configuration message in the main logs)
The old working structure and names is:
custom_components
├── sonoff.py
└── switch
└── sonoff.py
└── sensor
└── sonoff.py
And I changed this to:
custom_components
├── sonoff.py
└── sonoff
└── switch.py
└── sensor.py
`
Any ideas why this does not work ? (or have I misinterpreted the instructions ?)
Phil.