MagicMirror Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • Donate
    • Discord

    Error while starting Magic Mirror

    Development
    2
    29
    1191
    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.
    • 1
      1BlauNitrox last edited by

      Hey guys,
      I am not able to start my Magic Mirror with the command pm2 start MagicMirror.

      There is always this error:

      [21.01.2022 14:17.17.199] [ERROR] Whoops! There was an uncaught exception...
      [21.01.2022 14:17.17.201] [ERROR] TypeError: Cannot read properties of undefined (reading 'on')
          at Object.<anonymous> (/home/pi/MagicMirror/js/electron.js:104:5)
          at Module._compile (node:internal/modules/cjs/loader:1101:14)
          at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
          at Module.load (node:internal/modules/cjs/loader:981:32)
          at Function.Module._load (node:internal/modules/cjs/loader:822:12)
          at Object.<anonymous> (/usr/lib/node_modules/pm2/lib/ProcessContainerFork.js:33:23)
          at Module._compile (node:internal/modules/cjs/loader:1101:14)
          at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
          at Module.load (node:internal/modules/cjs/loader:981:32)
          at Function.Module._load (node:internal/modules/cjs/loader:822:12)
      

      I have only installed Spotify and calender_monthly module. Yesterday everythink works fine, now nothing works without changing anything

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

        @1blaunitrox that looks like a bad position for a module

        module:
        position: ???

        see the list here
        https://docs.magicmirror.builders/modules/configuration.html

        Sam

        Create a working config
        How to add modules

        1 1 Reply Last reply Reply Quote 0
        • 1
          1BlauNitrox @sdetweil last edited by

          @sdetweil

          This is my config:

          modules: [
          		{
          			module: "alert",
          		},
          		{
          			module: "updatenotification",
          			position: "top_bar"
          		},
          		{
          			module: "clock",
          			position: "top_left"
          		},
          		{
          			module: "calendar_monthly",
          			position: "top_left",
          			config: {
          
          			}
          		},
          		{
          			module: "weather",
          			position: "top_right",
          			config: {
          				weatherProvider: "openweathermap",
          				type: "current",
          				location: "mycity",
          				locationID: "cityID", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
          				apiKey: "mykey"
          			}
          		},
          		{
          			module: "weather",
          			position: "top_right",
          			header: "Wettervorhersage",
          			config: {
          				weatherProvider: "openweathermap",
          				type: "forecast",
          				location: "mycity",
          				locationID: "cityID", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
          				apiKey: "mykey"
          			}
          		},
          		{
                      		 module: "MMM-NowPlayingOnSpotify",
           			 position: "bottom_left",
          			 config: {
             				 clientID: "myid",
              				 clientSecret: "myid",
              				 accessToken: "mytoken",
              				 refreshToken: "mytoken"
           			 }
          		},
          	]
          
          S 1 Reply Last reply Reply Quote 0
          • S
            sdetweil @1BlauNitrox last edited by

            @1blaunitrox I don’t see a calendar_monthly module

            Sam

            Create a working config
            How to add modules

            1 1 Reply Last reply Reply Quote 0
            • 1
              1BlauNitrox @sdetweil last edited by

              @sdetweil What do you mean?

              https://github.com/KirAsh4/calendar_monthly/

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

                @1blaunitrox thx… I used your module list and dont see any issues…

                you did npm install in both new module folders, right?

                Sam

                Create a working config
                How to add modules

                1 1 Reply Last reply Reply Quote 0
                • 1
                  1BlauNitrox @sdetweil last edited by

                  @sdetweil no, it worked without

                  S 1 2 Replies Last reply Reply Quote 0
                  • S
                    sdetweil @1BlauNitrox last edited by

                    @1blaunitrox both modules provide a package.json file, which means u must
                    npm install
                    in their folders

                    Sam

                    Create a working config
                    How to add modules

                    1 Reply Last reply Reply Quote 0
                    • 1
                      1BlauNitrox @1BlauNitrox last edited by

                      @1blaunitrox my mistake. I did it

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

                        @1blaunitrox did u update MM?? git pull?

                        did you npm install after?

                        Sam

                        Create a working config
                        How to add modules

                        1 1 Reply Last reply Reply Quote 0
                        • 1
                        • 2
                        • 3
                        • 1 / 3
                        • First post
                          Last post
                        Enjoying MagicMirror? Please consider a donation!
                        MagicMirror created by Michael Teeuw.
                        Forum managed by Paul-Vincent Roll and Rodrigo Ramírez Norambuena.
                        This forum is using NodeBB as its core | Contributors
                        Contact | Privacy Policy