"Hi guys!..." <- > <@dicklessgreat:matrix.org> Hi guys! > Can I ask current best practices of embedded-hal compatibility? > > I'm now working on my own warehouse temperature/humidity sensor project, using dht-11. > Seems like this crate is best fit for my use case. > https://github.com/michaelbeaumont/dht-sensor > But I found this crate is not compatible with `embedded-hal 1.0.0`(using `0.2.7`). > I've forked this repo, would like to fix its compability, and plan to make pull request. > Before I start this project, can I ask how should I fix it? > Can I break backward compatibility(completely discard `0.2.7`)? > Or should I add `#cfg` macros and add flag for the older versions compatibility? > > Any best practices, good examples, or blog posts? > Thanks. that depends on what the original creator/maintainer wants to do with it, if your goal is to get the PR accepted. So best to try to ask him directly. ( After you get that sorted you can decided if his answer is working on you or not and proceed) For the transition period it would not be bad to have both versions available, by eitere have them both in tree and have them selected by a feature flag or just fully upgrade it and release a new version. The question is only if the 0.2 version would still receive any non patching releases in the future. If its otherwise "finished" i don't see a big problem in it bering a new version replacing the old. As a potential user still can use the older version if he needs to.