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.

    Server mode on Gentoo: TypeError in logger.js

    Scheduled Pinned Locked Moved Troubleshooting
    2 Posts 1 Posters 230 Views 1 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.
    • V Offline
      vwegert
      last edited by

      Hi all,

      I’ve tried to perform a fresh install of MM2 on a Gentoo system, intended to run as a headless server system. There was no previous working installation of MM2 on that system - in fact, this is my very first installation of MM2. I’m using the Node.js version supplied via the Gentoo package management system portage, which is

      *  net-libs/nodejs
            Latest version available: 14.4.0
            Latest version installed: 14.4.0
            Size of files: 32232 KiB
            Homepage:      https://nodejs.org/
            Description:   A JavaScript runtime built on Chrome's V8 JavaScript engine
            License:       Apache-1.1 Apache-2.0 BSD BSD-2 MIT
      

      Other than that, I’ve followed the steps in the installation instructions exactly. Running the application with npm run start via a SSH connection with X11 tunneling works (slow, but that was to be expected), so there’s nothing obviously wrong with the config or the installation. Now I want to use the server-only feature, which does not work:

      ~/MagicMirror $ npm run server
      
      > magicmirror@2.12.0 server /home/magicmirror/MagicMirror
      > node ./serveronly
      
      /home/magicmirror/MagicMirror/js/logger.js:32
      		timeStamp: Function.prototype.bind.call(console.timeStamp, console)
      		                                   ^
      
      TypeError: Bind must be called on a function
          at bind (<anonymous>)
          at /home/magicmirror/MagicMirror/js/logger.js:32:38
          at /home/magicmirror/MagicMirror/js/logger.js:16:20
          at Object.<anonymous> (/home/magicmirror/MagicMirror/js/logger.js:21:3)
          at Module._compile (internal/modules/cjs/loader.js:1200:30)
          at Object.Module._extensions..js (internal/modules/cjs/loader.js:1220:10)
          at Module.load (internal/modules/cjs/loader.js:1049:32)
          at Function.Module._load (internal/modules/cjs/loader.js:937:14)
          at Module.require (internal/modules/cjs/loader.js:1089:19)
          at require (internal/modules/cjs/helpers.js:73:18)
      npm ERR! code ELIFECYCLE
      npm ERR! errno 1
      npm ERR! magicmirror@2.12.0 server: `node ./serveronly`
      npm ERR! Exit status 1
      npm ERR! 
      npm ERR! Failed at the magicmirror@2.12.0 server script.
      npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
      
      npm ERR! A complete log of this run can be found in:
      npm ERR!     /home/magicmirror/.npm/_logs/2020-09-26T06_38_24_702Z-debug.log
      

      Is this a bug I should report or is there something else I’m missing?

      Thanks
      Volker

      1 Reply Last reply Reply Quote 0
      • V Offline
        vwegert
        last edited by

        …commenting out the offending line in logger.js appears to resolve the issue, and I can find no other reference to timeStamp - is this line needed for anything…?

        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