MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. philie
    3. Posts
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    P
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 2
    • Posts 15
    • Groups 0

    Posts

    Recent Best Controversial
    • RE: MMM-BMW-OW API Issues

      @sdetweil ahh ok I didn’t know there is a difference to restart… :(

      however now we’re talking:
      I could figure out and fix the error in the node_helper.js. Now its working and this is the output:

      root@magicmirror:/opt/magicmirror# npm run server
      
      > magicmirror@2.26.0 server
      > node ./serveronly
      
      [03.01.2024 22:54.21.808] [LOG]   Starting MagicMirror: v2.26.0
      [03.01.2024 22:54.21.809] [LOG]   Loading config ...
      [03.01.2024 22:54.21.809] [DEBUG] config template file not exists, no envsubst
      [03.01.2024 22:54.21.810] [LOG]   Loading module helpers ...
      [03.01.2024 22:54.21.811] [LOG]   No helper found for module: alert.
      [03.01.2024 22:54.21.814] [LOG]   Initializing new module helper ...
      [03.01.2024 22:54.21.814] [LOG]   Module helper loaded: updatenotification
      [03.01.2024 22:54.21.814] [LOG]   No helper found for module: clock.
      [03.01.2024 22:54.21.858] [LOG]   Initializing new module helper ...
      [03.01.2024 22:54.21.858] [LOG]   Module helper loaded: calendar
      [03.01.2024 22:54.21.858] [LOG]   No helper found for module: MMM-AareGuru.
      [03.01.2024 22:54.21.859] [ERROR] Whoops! There was an uncaught exception...
      [03.01.2024 22:54.21.861] [ERROR] Error: Cannot find module 'request'
      Require stack:
      - /opt/magicmirror/modules/MMM-BMW-OW/node_helper.js
      - /opt/magicmirror/js/app.js
      - /opt/magicmirror/serveronly/index.js
          at Module._resolveFilename (node:internal/modules/cjs/loader:1144:15)
          at Module._resolveFilename (/opt/magicmirror/node_modules/module-alias/index.js:49:29)
          at Module._load (node:internal/modules/cjs/loader:985:27)
          at Module.require (node:internal/modules/cjs/loader:1235:19)
          at require (node:internal/modules/helpers:176:18)
          at Object.<anonymous> (/opt/magicmirror/modules/MMM-BMW-OW/node_helper.js:9:17)
          at Module._compile (node:internal/modules/cjs/loader:1376:14)
          at Module._extensions..js (node:internal/modules/cjs/loader:1435:10)
          at Module.load (node:internal/modules/cjs/loader:1207:32)
          at Module._load (node:internal/modules/cjs/loader:1023:12)
          at Module.require (node:internal/modules/cjs/loader:1235:19)
          at require (node:internal/modules/helpers:176:18)
          at loadModule (/opt/magicmirror/js/app.js:181:19)
          at loadModules (/opt/magicmirror/js/app.js:211:10)
          at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
          at async App.start (/opt/magicmirror/js/app.js:259:3) {
        code: 'MODULE_NOT_FOUND',
        requireStack: [
          '/opt/magicmirror/modules/MMM-BMW-OW/node_helper.js',
          '/opt/magicmirror/js/app.js',
          '/opt/magicmirror/serveronly/index.js'
        ]
      }
      [03.01.2024 22:54.21.861] [ERROR] MagicMirror² will not quit, but it might be a good idea to check why this happened. Maybe no internet connection?
      [03.01.2024 22:54.21.861] [ERROR] If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues
      root@magicmirror:/opt/magicmirror#
      

      Still no functional MMM-BMW-OW though.

      posted in Troubleshooting
      P
      philie
    • RE: MMM-BMW-OW API Issues

      @sdetweil
      there have been many libraries missing.
      its the server version as LXC Container for proxmox. https://tteck.github.io/Proxmox/

      I’ve deployed this for testing purposes. Guess I’m switching on propper Pi installation though!
      Thank you very much for your help!

      posted in Troubleshooting
      P
      philie
    • RE: MMM-BMW-OW API Issues

      @sdetweil

      root@magicmirror:/opt/magicmirror/modules# npm restart
      
      > magicmirror@2.26.0 restart
      > npm stop --if-present && npm start
      
      
      > magicmirror@2.26.0 start
      > DISPLAY="${DISPLAY:=:0}" ./node_modules/.bin/electron js/electron.js
      
      /opt/magicmirror/node_modules/electron/dist/electron: error while loading shared libraries: libnss3.so: cannot open shared object file: No such file or directory
      

      This error did however already appear before the adjustement.
      I’ve uncommented even

      //	console.log(body); // for checking
      

      -> no logline. Quiet odd…

      posted in Troubleshooting
      P
      philie
    • RE: MMM-BMW-OW API Issues

      @sdetweil thank you very much for your quick response sam!
      I did therefore change the API in node_helper.js to

      https://api.openweathermap.org/data/3.0/onecall?lat=
      

      and registered a corresponding API key.
      API key pasted in config/config.js:

      {
                              disabled: false,
                              module: "MMM-BMW-OW",
                              position: "bottom_bar", // designed for bottom_bar(best) thirds should be good too
                              config: {
                                      api: "e9e02edummy/dummy/dummy/dummy0864", // Get at https://openweathermap.org/price
                                      ownTitle: "Current Conditions",
                                      lat: '43.574794', // Your latitude
                                      lon: '-77.112454', // Your longitude
                                      css: "2", // 1-6
                                      playSounds: "no",
                                      useHeader: false, // true if you want a header
                                      header: "Your header",
                                      maxWidth: "100%",
                                      updateInterval: 5 * 60 * 1000,
                              }
      

      Like before, in a browser its working but unfortunately not in the module.
      I’ve grepped over the magicmirror root directory for the API url to see if it’s referred elsewhere, but it seems not.

      What do I miss?

      posted in Troubleshooting
      P
      philie
    • MMM-BMW-OW API Issues

      Hi All
      My MMM-BMW.OW module does not get past “OpenWeather data…” when loading. I have configured everything as specified in the module’s readme. Troubleshooting on my part has revealed that the API endpoint at openweathermap.org may have changed.
      The endpoint should be as follows: api.openweathermap.org/data/2.5/weather?id=524901&appid=YOUR_API_KEY

      The API can therefore also be called up in a browser: http://api.openweathermap.org/data/2.5/weather?id=524901&lat=46.9481&lon=7.4474&units=metric&appid=YOUR_API_KEY

      However, in the node_helper.js script of the module, the API is specified as follows: https://api.openweathermap.org/data/2.5/onecall?lat= + config.

      I call up this endpoint in a browser: https://api.openweathermap.org/data/2.5/onecall?lat=46.9481&lon=7.4474&units=metric&appid=YOUR_API_KEY

      a 401 is returned.

      but the module does not run even if I replace the presumably broken endpoint in node_helper.js.

      Does anyone have more detailed information?
      Many thanks in advance
      philie

      posted in Troubleshooting
      P
      philie
    • 1
    • 2
    • 2 / 2