MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Doesn't contain package.json file

    Scheduled Pinned Locked Moved Development
    8 Posts 2 Posters 1.9k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • A Offline
      allancherianbiju
      last edited by allancherianbiju

      Re: include npm module like firebase module into our own MM module

      I’ve been trying for a while and I got the same error every single time.

      WARNING! Could not load config file. Starting with default configuration. Error found: Error: Failed to load gRPC binary module because it was not installed for the current system
      Expected directory: electron-v3.0-linux-arm-glibc
      Found: [node-v59-linux-arm-glibc]
      
      cd ~/MagicMirror/modules/MMM-hellotsuhan
      npm install --save-dev electron-rebuild
      ./node_modules/.bin/electron-rebuild
      

      Tried executing this and I got this

      How do I get that file?

      :::

      I’m very new to this.

      :::

      S 1 Reply Last reply Reply Quote 0
      • S Offline
        sdetweil @allancherianbiju
        last edited by

        @allancherianbiju said in Doesn't contain package.json file:

        Tried executing this and I got this

        got what?

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        1 Reply Last reply Reply Quote 0
        • A Offline
          allancherianbiju
          last edited by

          Formatting mistake. The error I posted isn’t showing up due to some reason.

          npm ERR! Could not install from “node_modules/ .bin/electron-rebuild” as it does not contain a package.json file.

          1 Reply Last reply Reply Quote 0
          • S Offline
            sdetweil
            last edited by

            many components in a javascript application need to have their versions match the surrounding runtime. grpc is one of those… it will run in and outside the electron browser…

            the electron-rebuild module is loaded as part of the base,
            so you would do

            cd ~/MagicMirror
            node_modules/.bin/electron_rebuild
            

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 0
            • A Offline
              allancherianbiju
              last edited by

              Just closing notes. I was able to fix this!

              @sdetweil provided extra commands.

              cd ~/MagicMirror
              npm install electron-rebuild
              node_modules/.bin/electron-rebuild
              

              That worked for me, but I was faced with a new error.

              Error: Cannot find module 'node_helper_.

              Fixed that by running

              cd -/MagicMirror
              git checkout modules/node_modules/node_helper/index.js
              

              Thanks for the help guys!

              1 Reply Last reply Reply Quote 0
              • A Offline
                allancherianbiju
                last edited by

                I had to reinstall MM and had to go through all of this again. Rebuilding electron fixed the issue and I found out that the git command I used doesn’t work anymore. Zzz… Updating should help.

                cd -/MagicMirror
                git checkout modules/node_modules/node_helper/index.js
                
                S 1 Reply Last reply Reply Quote 0
                • S Offline
                  sdetweil @allancherianbiju
                  last edited by

                  @allancherianbiju in version 2.10 we fixed this problem, by moving the file to a different location.

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  A 1 Reply Last reply Reply Quote 0
                  • A Offline
                    allancherianbiju @sdetweil
                    last edited by

                    @sdetweil Oh! That’s great! Onward, then :D

                    1 Reply Last reply Reply Quote 0
                    • 1 / 1
                    • First post
                      Last post
                    Enjoying MagicMirror? Please consider a donation!
                    MagicMirror created by Michael Teeuw.
                    Forum managed by Sam, technical setup by Karsten.
                    This forum is using NodeBB as its core | Contributors
                    Contact | Privacy Policy