-
Notifications
You must be signed in to change notification settings - Fork 9
Uses a newer websockets version #95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
Thanks for the PR @flatsiedatsie! Do you happen to know whether there were any major API changes in the jump from 0.57 to 1.5.0 which could cause problems? I assume the WebSocket client is only used by IPC to communicate with the gateway process, so should be relatively easy to test. Unfortunately it looks like this PR has failed automated checks, but it may just be that a Python 3.7 package is no longer available on the ubuntu-latest test runner! As an aside, I have upgraded the gateway from Node.js 10 to Node.js 20 and would really like to upgrade the Python version used too if that's something you might be able to help with? WebThingsIO/gateway#3141 Then we can upgrade gateway-addon-python to a more up to date version of Python too and get all this stuff working again. |
|
If I remember correctly this was the only Python upgrade showstopper. Candle moved to 3.9 and then 3.11 (for Matter support) without any other changes being necessary. Very happy with the change to Node 20 :-) I'm curious though: for me the old addons wouldn't run, so I had to install both Node 20 node 12. I added some code that lets addons choose which node version they want. This was was necessary to allow Zigbee2MQTT to run, which needs a recent version of Node.
As you can see in the code, they added another parameter to the function call. |
|
@flatsiedatsie wrote:
👍
What do you mean by wouldn't run? Currently many add-ons are filtered out of the list of add-ons available to install if addon-list says the add-on needs Node.js 10 but the gateway says it's running Node.js 20 when retrieving the list. Many add-ons need to be individually tested with Node.js 20 and then have their manifests updated in the add-on list. If there are other issues you've experienced then please file issues for those.
👍 I think we may need to increase the Python version at https://github.com/WebThingsIO/gateway-addon-python/blob/master/.github/workflows/pythonpackage.yml#L16 in order to get the Python package GitHub action to run on this repo, because Python 3.7 is no longer available on ubuntu-latest. In #3141 I suggested version 3.11.2 since that is the current version in Debian Bookworm (though we may want to upgrade to Trixie soon!). |
|
@flatsiedatsie Does this work? I'm aiming to release 2.0.0 today and it would be great to include this new version of gateway-addon-python in the gateway. What is a good add-on to test it with that's in the WebThings Gateway add-on directory? I'm hoping that if we change https://github.com/WebThingsIO/gateway-addon-python/blob/master/.github/workflows/pythonpackage.yml#L16 to 3.11 it will make the GitHub Action work. |
I don't know. But you could manually install a Candle addon through github to do a quick test? I have some recent ones that only work with python 3.11, so those should be useful. Try this one, it only has a 3.11 release: Note: this is 64 bit. Is the Gateway 2.0.0 using 64 bit? Will you be releasing a disk image of some sort? I'd love to try it out!
My vague memory is tht once I set the node version to 20 for the gateway, addons from the Webthings list that were compiled for v10/v12 wouldn't run. So as a work around Candle now comes with multiple Node versions installed: 12 - for legacy addons I created a hacky system where a preference for a certain version can be set if the manifest.json, and the gateway uses that to invoke the addon with the specific node binary. |
No description provided.