Squashing a bug

NodeBB Development
  • I'm trying to run the app locally and it's worked fine in the past. I don't remember making any changes, but maybe I accidentally did something with git that messed things up. When I run it now, here's what happens:

    $ node app
    info: NodeBB v0.3.0 Copyright (C) 2013 DesignCreatePlay Inc.
    info: This program comes with ABSOLUTELY NO WARRANTY.
    info: This is free software, and you are welcome to redistribute it under certain conditions.
    info:
    info: Initializing NodeBB v0.3.0, on port 4567, using redis store at 127.0.0.1:6379.
    info: NodeBB instance bound to: Any address (0.0.0.0)
    error: undefined

    /Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/src/routes/authentication.js:35
    if (meta.config['social:twitter:key'] && meta.config['social:twitter:secret']
    ^
    TypeError: Cannot read property 'social:twitter:key' of undefined
    at /Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/src/routes/authentication.js:35:17
    at Object.<anonymous> (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/src/routes/authentication.js:220:2)
    at Module._compile (module.js:449:26)
    at Object.Module._extensions..js (module.js:467:10)
    at Module.load (module.js:349:32)
    at Function.Module._load (module.js:305:12)
    at Module.require (module.js:357:17)
    at require (module.js:373:17)
    at Object.<anonymous> (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/src/routes/api.js:8:9)
    at Module._compile (module.js:449:26)
    Aarons-MacBook-Air-2:forum aaronclaytondunn$

    Any ideas? Thanks!

  • Mmm, that usually means your redis server is not turned on, or NodeBB can't communicate with it!

  • Haha oops. Thanks! I just started the redis and node servers and everything looked fine. But when I try to visit localhost:4567, there's nothing to be found at that address! Any idea what happened?

  • @aaron - What does your config.json say? Perhaps it's serving on a different port?

  • config.json:

    {
        "base_url": "http://localhost",
        "port": "4567",
        "use_port": true,
        "secret": "somesecret",
        "bind_address": "0.0.0.0",
        "database": "redis",
        "redis": {
            "host": "127.0.0.1",
            "port": "6379",
            "password": "",
            "database": "0"
        },
        "bcrypt_rounds": 12,
        "upload_path": "/public/uploads",
        "relative_path": ""
    }
    

    That should be fine, right?

  • This post is deleted!
  • Hm, that looks to be alright. Does NodeBB say "NodeBB Ready." when you start it? What errors crop up in the console or in the browser (using Chrome Inspector or Firebug) when you try to go to port 4567?

  • Sometimes on your "host" file .. it doesnt point "localhost" to 127.0.0.1 thats your original root ip.. 🙂

    could u check it?

  • Thanks everyone! Here's a screenshot of what happens when I run the app and try to visit the homepage with developer tools turned on. The only other thing that isn't working properly is redis. If I type in redis-cli ping, I get a blank cursor in response. You can see that happening in the image below. That said, I did kill and restart redis pointing to the proper configuration file that's worked before.

    Screen Shot 2014-02-04 at 10.23.15 AM.png

  • I re-downloaded Redis from scratch and it worked.


Suggested Topics