Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

TypeError: Object #<error> has no method 'hasOwnProperty' #314

Closed
vorporeal opened this Issue Sep 15, 2012 · 7 comments

Comments

Projects
None yet
8 participants

When running 'jitsu deploy' on my application, I consistently encounter the following error.

Node version: 0.8.9

$ jitsu deploy
info:    Welcome to Nodejitsu vorp
info:    jitsu v0.9.8
info:    It worked if it ends with Nodejitsu ok
info:    Executing command deploy
info:    Analyzing application dependencies in app.js

/usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/lib/npm.js:299
  if (!conf.hasOwnProperty("prefix")) {
            ^
TypeError: Object #<error> has no method 'hasOwnProperty'
    at loadPrefix (/usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/lib/npm.js:299:13)
    at Array.0 (/usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/node_modules/slide/lib/bind-actor.js:15:8)
    at LOOP (/usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/node_modules/slide/lib/chain.js:15:14)
    at chain (/usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/node_modules/slide/lib/chain.js:20:5)
    at /usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/lib/npm.js:287:7
    at cb (/usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/lib/utils/ini.js:83:5)
    at /usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/lib/utils/ini.js:124:9
    at /usr/lib/node_modules/jitsu/node_modules/require-analyzer/node_modules/npm/lib/utils/ini.js:202:20
    at fs.js:117:20
    at /usr/lib/node_modules/jitsu/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/graceful-fs.js:53:5

skeggse commented Sep 24, 2012

I just started experiencing this issue as well. I'll look into it, but I don't have a lot of time or knowledge of the internals of npm/jitsu.

Contributor

jfhbrook commented Sep 24, 2012

My guess is that the require-analyzer needs to update its npm version.

Getting the same error here

just got this when trying to run deploy for the first time.

running node 0.8.12
and npm 1.1.63

the next time i ran deploy it worked fine.

I then deleted package.json (and the app from nodejitsu) and tried again. Again it worked fine. Not sure how to reproduce this.

Maybe it has something to do with working on windows and OSX with my node_modules checked into git (sometimes I have to do npm rebuild - but i'm pretty sure i did this before trying to deploy the first time)

I resolved this by adding "node" into the "start" in my package.json

"scripts": {
"test": "echo "Error: no test specified" && exit 1",
"start": "node script.js"
},

@nwkeeley this resolved too

I resolved this by adding "node" into the "start" in my package.json

"scripts": {
"test": "echo "Error: no test specified" && exit 1",
"start": "node script.js"
},

@dscape dscape closed this Dec 7, 2012

Member

dscape commented Dec 7, 2012

Assuming this got closed by what @thalesfsp said. Feel free to reopen if that's not the case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment