-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
[Hue] Suddenly can't connect to Bridge #9301
Comments
Thank you for opening this issue! 🔔 @pindab0ter @thomaspaulmann @robertvanhoesel you might want to have a look. 💡 Author and Contributors commandsThe author and contributors of
|
I've also been experiencing this so I thought I'd dig in to work out what's going on - with the caveat I'm not a JS dev by trade. Whilst the docs recommend any Node.js version from 16 onwards, versions >= 20 have different networking behaviour which leads to incorrect error handling on some cases on Forking the extension and making the following change instantly fixed all of the issues I was having. I used the latest version of Node.js available via nvm (21.2.0). I've verified this doesn't break anything on 16.20.2 either. Happy to submit a PR if this seems reasonable. diff --git a/src/lib/createHueClient.ts b/src/lib/createHueClient.ts
index 78ddc58..cb4b495 100644
--- a/src/lib/createHueClient.ts
+++ b/src/lib/createHueClient.ts
@@ -58,7 +58,7 @@ export default async function createHueClient(
lookup: (hostname, options, callback) => {
if (hostname.toLowerCase() === bridgeConfig.id && bridgeConfig.ipAddress !== undefined) {
// Resolve the Bridge ID to the IP address of the Hue Bridge
- callback(null, bridgeConfig.ipAddress, 4);
+ callback(null, [{ address: bridgeConfig.ipAddress, family: 4 }]);
} else {
// Fallback to the default DNS lookup
dns.lookup(hostname, options, callback); |
Thank you for looking into it. Always appreciated! I'm experiencing the same issue and if you change fixes it I would approve it as soon as I could test it. So yes, please do submit it as a PR if you like! |
Seems that this has been fixed by #9337. Thank you both! |
Extension
https://www.raycast.com/pindab0ter/hue
Description
I've been using this extension for some time and never had any issues. However, today when I tried to control my lights, a connection to the Bridge couldn't be established so I tried disconnecting and reconnecting. When I tried to reconnect to the Hue bridge I got the following error:
TypeError [ERR_INVALID_IP_ADDRESS]: Invalid IP address: undefined
. I also tried manually setting the IP of my Bridge (and disabling DHCP) in the extension's settings, but again, no luck. I disabled my VPN and everything else I thought might interfere with the network too. I am using MacOS Sonoma 14.1.1 if that's relevant.Steps To Reproduce
Control Lights
commandThe text was updated successfully, but these errors were encountered: