Closed pradeep-systango closed 9 years ago
Similar problem compiling assets on OS X El Capitan, chokes on node-gyp rebuild / trying to install contextify :
14 errors generated.
make: *** [Release/obj.target/contextify/src/contextify.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 15.0.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/milesmuri/myapp/node_modules/contextify
gyp ERR! node -v v4.2.1
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
npm ERR! Darwin 15.0.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "contextify"
npm ERR! node v4.2.1
npm ERR! npm v2.14.7
npm ERR! code ELIFECYCLE
npm ERR! contextify@0.1.14 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the contextify@0.1.14 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the contextify package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls contextify
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /Users/milesmuri/myapp/npm-debug.log
This is part of the CODES.sh script from the Quick Start page. The script continues after these errors, but then hangs after this (processor at just shy of 100%, can run for hours with no output):
Files: 96
Modules: 0 ( 0 undocumented)
Classes: 95 ( 30 undocumented)
Constants: 0 ( 0 undocumented)
Methods: 422 ( 7 undocumented)
92.84% documented
API Documentation successfully generated in public/doc/api
See public/doc/api/index.html
--> Finished: 'Generate documentation [yardoc]' in 39.553938
I kill it with Ctrl-C and get this:
Parallel execution interrupted, exiting ...
rake aborted!
Interrupt: Interrupt
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:406:in `block in trap_interrupt'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:353:in `call'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:353:in `join'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:353:in `block in wait_for_threads'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:351:in `map'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:351:in `wait_for_threads'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:142:in `block in in_threads'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:394:in `kill_on_ctrl_c'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:142:in `in_threads'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:268:in `block in work_in_processes'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:394:in `kill_on_ctrl_c'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:267:in `work_in_processes'
/Users/milesmuri/.gem/ruby/2.1.6/gems/parallel-1.4.1/lib/parallel.rb:193:in `map'
/Users/milesmuri/canvas-lms/lib/tasks/canvas.rake:163:in `block (3 levels) in <top (required)>'
/Users/milesmuri/canvas-lms/lib/tasks/canvas.rake:162:in `block (2 levels) in <top (required)>'
Tasks: TOP => canvas:compile_assets
(See full trace by running task with --trace)
The asset compilation failed. This might be a permissions thing.
Re-run the compile with sudo? (Y/[N]): n
The asset compilation failed.
You can continue setup but the assets will need to be
successfully built before you can run Canvas
(You build them with 'bundle exec rake canvas:compile_assets')
Continue with setup? ([Y]/N): n
Error building Canvas assets. Please build manually and try again (bundle exec rake canvas:compile_assets)
I have tried re-running the compile with sudo as suggested in the script, with the same result.
Any possible solution paths appreciated.
Thanks, M.
Canvas isn't yet working with Node 4, you need to downgrade to Node 0.12.7. We try to keep the github issue tracker specific to bugs in the actual running application, for future issues like these you'll have better luck asking on our mailing list: https://groups.google.com/forum/#!forum/canvas-lms-users
node-gyp -v v3.0.3
node -v v4.2.1
npm -v 2.10.1
This is my console screen while I am trying to compile my assets.
nsgill@STPL-IND-PAGRAWAL:~/projects/canvas-lms$ bundle exec rake canvas:compile_assets --trace * Invoke canvas:compile_assets (first_time) * Execute canvas:compile_assets --> Starting: 'Making sure node_modules are up to date' npm WARN install Couldn't install optional dependency: Unsupported npm WARN install Couldn't install optional dependency: Unsupported npm WARN install Couldn't install optional dependency: Unsupported npm WARN ENOENT ENOENT: no such file or directory, open '/home/nsgill/projects/canvas-lms/node_modules/concat-stream/package.json' npm WARN ENOENT ENOENT: no such file or directory, open '/home/nsgill/projects/canvas-lms/node_modules/load-json-file/package.json' --> Finished: 'Making sure node_modules are up to date' in 122.05152510900007 --> Starting: 'compile css (including custom brands)' no sass changes detected --> Finished: 'compile css (including custom brands)' in 1.5083165989999543 working in 2 processes --> Starting: 'compile coffee, js 18n, and run r.js optimizer' --> Starting: 'js:generate' * Invoke js:generate (first_time) * Execute js:generate --> Starting: 'css:styleguide' * Invoke css:styleguide (first_time) * Execute css:styleguide --> creating styleguide * Invoke js:build_client_apps (first_time) * Execute js:build_client_apps Building client app 'canvas_quizzes' Running 'npm install'... npm WARN EPEERINVALID react@0.10.0 requires a peer of envify@~1.2.0 but none was installed. npm WARN EPACKAGEJSON canvas_quizzes@1.0.0 No repository field. npm WARN EPACKAGEJSON canvas_quizzes@1.0.0 No license field. Running 'npm run build'...
writing file: app/views/info/styleguide.html.erb
--> Finished: 'css:styleguide' in 7.147470806999991 --> Starting: 'Generate documentation [yardoc]' * Invoke doc:api (first_time) * Execute doc:api [error]: Unhandled exception in YARD::Handlers::Ruby::ModuleHandler: [error]: in
app/controllers/filters/quizzes.rb
:19:[error]: NoMethodError: undefined method
length' for nil:NilClass [error]: Stack trace: /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:210:in
on_ignored_nl' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:50:inparse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:50:in
parse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:15:inparse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/source_parser.rb:439:in
parse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/source_parser.rb:44:in `block in parse'Client app 'canvas_quizzes' was built successfully. --> Creating ember app bundles * Invoke js:bundle_ember_apps (first_time) * Execute js:bundle_ember_apps --> Pre-compiling ember handlebars templates * Invoke jst:ember (first_time) * Execute jst:ember --> Pre-compiling handlebars templates * Invoke jst:compile (first_time) * Execute jst:compile --> Compiling React JSX * Invoke js:jsx (first_time) * Execute js:jsx --> Creating ember app bundles finished in 0.019525174999216688--> Generating plugin extensions \ Invoke js:generate_extensions (first_time)
\ Execute js:generate_extensions --> Generating plugin extensions finished in 0.013264465998872765 --> Compiling CoffeeScript with 'coffee' binary /home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/node_modules/bindings/bindings.js:83 throw e ^
Error: Module did not self-register. at Error (native) at Object.Module._extensions..node (module.js:460:18) at Module.load (module.js:356:32) at Function.Module._load (module.js:311:12) at Module.require (module.js:366:17) at require (module.js:385:17) at bindings (/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/node_modules/bindings/bindings.js:76:44) at Object. (/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/lib/contextify.js:1:96)
at Module._compile (module.js:435:26)
at Object.Module._extensions..js (module.js:442:10)
/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/node_modules/bindings/bindings.js:83
throw e
^
Error: Module did not self-register. at Error (native) at Object.Module._extensions..node (module.js:460:18) at Module.load (module.js:356:32) at Function.Module._load (module.js:311:12) at Module.require (module.js:366:17) at require (module.js:385:17) at bindings (/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/node_modules/bindings/bindings.js:76:44) at Object. (/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/lib/contextify.js:1:96)
at Module._compile (module.js:435:26)
at Object.Module._extensions..js (module.js:442:10)
/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/node_modules/bindings/bindings.js:83
throw e
^
Error: Module did not self-register. at Error (native) at Object.Module._extensions..node (module.js:460:18) at Module.load (module.js:356:32) at Function.Module._load (module.js:311:12) at Module.require (module.js:366:17) at require (module.js:385:17) at bindings (/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/node_modules/bindings/bindings.js:76:44) at Object. (/home/nsgill/projects/canvas-lms/gems/canvas_i18nliner/node_modules/jsdom/node_modules/contextify/lib/contextify.js:1:96)
at Module._compile (module.js:435:26)
at Object.Module._extensions..js (module.js:442:10)
[error]: Unhandled exception in YARD::Handlers::Ruby::ModuleHandler:
[error]: in
app/controllers/filters/quiz_submissions.rb
:19:[error]: NoMethodError: undefined method
length' for nil:NilClass [error]: Stack trace: /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:210:in
on_ignored_nl' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:50:inparse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:50:in
parse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/ruby/ruby_parser.rb:15:inparse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/source_parser.rb:439:in
parse' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/yard-0.8.7.6/lib/yard/parser/source_parser.rb:44:in `block in parse'--> Compiling React JSX finished in 11.014921448999303b [warn]: @param tag has unknown parameter name: conversations in file
app/controllers/quizzes/quiz_submission_users_controller.rb' near line 139 ⌏ Generating /home/nsgill/projects/canvas-lms/public/doc/api/all_resources.html.................................................................⌌ Generating /home/nsgill/projects/canvas-lms/public/doc/api/all_resources.html.................................................................⌍ Generating /home/nsgill/projects/canvas-lms/public/doc/api/all_resources.html.................................................................⌎ Generating lms/public/doc/api/all_resources.html.................................................................Files: 94 Modules: 0 ( 0 undocumented) Classes: 93 ( 30 undocumented) Constants: 0 ( 0 undocumented) Methods: 416 ( 7 undocumented) 92.73% documented API Documentation successfully generated in public/doc/api See public/doc/api/index.html --> Finished: 'Generate documentation [yardoc]' in 40.264044159999685 rake aborted! Undumpable Exception -- #<EOFError: end of file reached> /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:63:in
work' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:280:inblock (4 levels) in work_in_processes' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:447:in
with_instrumentation' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:279:inblock (3 levels) in work_in_processes' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:273:in
loop' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:273:inblock (2 levels) in work_in_processes' /home/nsgill/projects/canvas-lms/vendor/bundle/ruby/2.2.0/gems/parallel-1.4.1/lib/parallel.rb:138:in
block (2 levels) in in_threads' Tasks: TOP => canvas:compile_assetswhen I am trying to "node-gyp rebuild" I am getting following error:-
gyp: binding.gyp not found (cwd: /home/nsgill/projects/canvas-lms) while trying to load binding.gyp gyp ERR! configure error gyp ERR! stack Error:
gyp
failed with exit code: 1I tried all possible solutions. I have tried this with different versions of npm but facing same issue.
please let me know if you have any solution.