Git Product home page Git Product logo

Comments (5)

caseywebdev avatar caseywebdev commented on August 16, 2024

Ah sorry I should have probably mentioned this in the README, but this plugin uses syntax only supported by node.js >= 6. If you're using Homebrew like you say, you should be able to run brew update && brew upgrade node and you'll be on the latest version of node (v6.6.0 at the time of writing).

from homebridge-chamberlain.

danielballance avatar danielballance commented on August 16, 2024

Thanks Casey. I'm sure this would have fixed the problem, but I believe Homebridge itself is behind the curve on node.js 6.6.0. Error below for reference; thanks for your help! Closing this issue.

/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/mdns/lib/dns_sd.js:35
    throw ex;
    ^

Error: Module version mismatch. Expected 48, got 46.
    at Error (native)
    at Object.Module._extensions..node (module.js:583:18)
    at Module.load (module.js:473:32)
    at tryModuleLoad (module.js:432:12)
    at Function.Module._load (module.js:424:3)
    at Module.require (module.js:483:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/mdns/lib/dns_sd.js:24:20)
    at Module._compile (module.js:556:32)
    at Object.Module._extensions..js (module.js:565:10)

from homebridge-chamberlain.

caseywebdev avatar caseywebdev commented on August 16, 2024

You just have to run npm rebuild and mdns will work properly.

from homebridge-chamberlain.

caseywebdev avatar caseywebdev commented on August 16, 2024

Nothing about the homebridge code doesn't work on newer node versions, I'm running 6.6.0 in my house right now.

from homebridge-chamberlain.

HanSooloo avatar HanSooloo commented on August 16, 2024

For people who were running into similar problems, documented the process on how to make this work:

  1. Install NodeJS 4.x
  2. Follow homebridge and homebridge-chamberlain installation instructions all the way.
  3. Update to NodeJS 6.x: http://thisdavej.com/upgrading-to-more-recent-versions-of-node-js-on-the-raspberry-pi/
    1. curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash -
    2. sudo apt install nodejs
  4. Go to HAP-NodeJS directory and rebuild some modules
    1. cd /usr/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules
    2. npm rebuild mdns
    3. npm rebuild bignum --build-from-source
    4. npm rebuild ed25519
    5. npm rebuild curve25519-n

from homebridge-chamberlain.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.