hassio-addons / addon-zwave2mqtt

Z-Wave to MQTT - Home Assistant Community Add-ons
https://addons.community
MIT License
57 stars 27 forks source link

Alpine Linux's openzwave{,-dev} packages are unmaintained and outdated. #61

Closed rtrox closed 3 years ago

rtrox commented 4 years ago

Problem/Motivation

The openzwave packages in Alpine Linux, which are used by this package, were last built in 11/2019. It's using 1.6-974, while upstream's latest stable release is 1.16.1149: https://pkgs.alpinelinux.org/packages?name=openzwave&branch=edge https://pkgs.alpinelinux.org/packages?name=openzwave-dev&branch=edge

The package also appears to be unmaintained, and is therefore unlikely to be updated. This package also has a few bugs, some of which are referenced here (path issues). I also suspect, and am working to prove in that issue, that the actual TriggerRefreshValue issue is related as well. https://github.com/OpenZWave/open-zwave/issues/2264

Expected behavior

OpenZWave dependency is maintained, and is able to remain relatively up to date.

Actual behavior

The opposite.

Steps to reproduce

The age of the package is visible in the links above.

Proposed changes

I'm working right now to adjust the Dockerfile to build OpenZWave from source. Will open a PR once ready, if this approach is acceptable.

Another option might be to try and wrap the official Zwave2Mqtt image with the hassio magic. Dockerfile here: https://github.com/OpenZWave/Zwave2Mqtt/tree/master/docker

GitHub
OpenZWave/Zwave2Mqtt
Fully configurable Zwave to MQTT gateway and Control Panel using NodeJS and Vue - OpenZWave/Zwave2Mqtt
addons-assistant[bot] commented 4 years ago

:wave: Thanks for opening your first issue here! If you're reporting a :bug: bug, please make sure you include steps to reproduce it. Also, logs, error messages and information about your hardware might be useful.

rtrox commented 4 years ago

Update, got an image built using openzwave source tarball (v1.6.1149). It's getting late here in PST, will pick this back up and test the image tomorrow. The Dockerfile needs some serious clean-up (I'll remove all the unnecessary changes -- I added a bunch of layers so I could iterate more quickly while working on the new image), but dropping where I am here for initial comments on the approach:

https://github.com/rtrox/addon-zwave2mqtt/blob/master/zwave2mqtt/Dockerfile

GitHub
rtrox/addon-zwave2mqtt
Z-Wave to MQTT - Home Assistant Community Add-ons. Contribute to rtrox/addon-zwave2mqtt development by creating an account on GitHub.
rtrox commented 4 years ago

Alright, tested the image this morning, it seems to work without issue (and I was able to confirm that the new image fixed the bugs in the linked issue). I'm testing my cleaned up commit, and will send a PR later today to use the official source tarball instead of the outdated alpine package.

frenck commented 4 years ago

I suggest you open up a PR with Alpine so they can update their package. 👍

rtrox commented 4 years ago

@frenck good thought, I can go that route. This issue should probably stay open though -- the version is pinned in the Dockerfile, so I'll need to update the Dockerfile once the new package is available:

https://github.com/hassio-addons/addon-zwave2mqtt/blob/master/zwave2mqtt/Dockerfile#L28

GitHub
hassio-addons/addon-zwave2mqtt
Z-Wave to MQTT - Home Assistant Community Add-ons. Contribute to hassio-addons/addon-zwave2mqtt development by creating an account on GitHub.
frenck commented 4 years ago

Sorry, I just noticed by your reply I closed the issue, that I didn't mean to do.

rtrox commented 4 years ago

No prob, thanks @frenck! I can definitely work on updating the APKBUILD for Alpine tonight -- I haven't built an alpine package before, but it doesn't look too terrible. That said, it does still look as though the package is unmaintained and the last update was made without a Maintainer:

https://git.alpinelinux.org/aports/tree/community/openzwave/APKBUILD

Do you think it's better to do a one-off update here, rather than pinning the version and building from source? I'm a bit concerned that without a maintainer, that package will just become stale again in another 6 months -- that's why I was looking to pin the version and build from source instead. Here's the Dockerfile I was preparing for PR (ignore the NODE_OPTIONS, that was a hacky workaround to let me build the image on a Pi. That would be removed before PR):

https://github.com/rtrox/addon-zwave2mqtt/commit/0411e3f32b3a6e2b15f1dff517b528db88d0403e

Let me know, glad to send PRs for either route.

APKBUILD\openzwave\community - aports - Unnamed repository; edit this file 'description' to name the repository.
github-actions[bot] commented 3 years ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!