Closed Bug 1146077 Opened 9 years ago Closed 9 years ago

Building mac profile for unit and integration tests broken after js-runner updates

Categories

(Firefox OS Graveyard :: Gaia, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: kgrandon, Unassigned)

References

Details

It works for me after reverting the js-runner bump. I saw this in my logs: 

npm ERR! marionette-js-runner@1.0.15 postinstall: `./scripts/setup_python.sh`
npm ERR! Exit status 126
npm ERR! 
npm ERR! Failed at the marionette-js-runner@1.0.15 postinstall script.
npm ERR! This is most likely a problem with the marionette-js-runner package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     ./scripts/setup_python.sh
npm ERR! You can get their info via:
npm ERR!     npm owner ls marionette-js-runner
npm ERR! There is likely additional logging output above.
npm ERR! System Darwin 14.1.0
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "rebuild"
npm ERR! cwd /Users/kevin/workspace/gaia
npm ERR! node -v v0.10.31
npm ERR! npm -v 1.4.23
npm ERR! code ELIFECYCLE
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/kevin/workspace/gaia/npm-debug.log
npm ERR! not ok code 0
make: *** [node_modules] Error 1
Full log after running make node_modules:

# Running make without using a dependency ensures that we can run
# "make node_modules" with a custom NODE_MODULES_GIT_URL variable, and then
# run another target without specifying the variable
/Applications/Xcode.app/Contents/Developer/usr/bin/make modules.tar
make[1]: `modules.tar' is up to date.
tar --strip-components 1 -x -m -f modules.tar "mozilla-b2g-gaia-node-modules-*/node_modules"
tar: Failed to set default locale
node --version
v0.10.31
npm --version
1.4.23
VIRTUALENV_EXISTS= npm install && npm rebuild
npm WARN package.json mail-fakeservers@0.0.24 No README data
npm WARN package.json mocha-json-proxy@0.0.7 No repository field.
npm WARN package.json dateformat@1.0.6-1.2.3 No repository field.
npm WARN package.json marionette-client@1.7.1 No repository field.
npm WARN package.json marionette-content-script@0.0.4 No repository field.
npm WARN package.json marionette-device-host@0.1.0 No repository field.
npm WARN package.json marionette-file-manager@0.0.4 No repository field.
npm WARN package.json marionette-profile-builder@0.0.4 No repository field.
npm WARN package.json mocha-parallel@0.1.0 No repository field.

> ffi-prebuilt@1.2.9 install /Users/kevin/workspace/gaia/node_modules/ffi-prebuilt
> ./tools/copy.js || node-gyp configure build

[ffi-prebuilt] platform not linux
  CC(target) Release/obj.target/ffi/deps/libffi/src/prep_cif.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/types.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/raw_api.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/java_raw_api.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/closures.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/ffi.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/ffi64.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/darwin.o
  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/darwin64.o
  LIBTOOL-STATIC Release/libffi.a
  CXX(target) Release/obj.target/ffi_bindings/src/ffi.o
  CXX(target) Release/obj.target/ffi_bindings/src/callback_info.o
  CXX(target) Release/obj.target/ffi_bindings/src/threaded_callback_invokation.o
  SOLINK_MODULE(target) Release/ffi_bindings.node
ld: warning: could not create compact unwind for _ffi_call_unix64: does not use RBP or RSP based frame
  SOLINK_MODULE(target) Release/ffi_bindings.node: Finished

> ref-prebuilt@0.1.3 install /Users/kevin/workspace/gaia/node_modules/ffi-prebuilt/node_modules/ref-prebuilt
> ./tools/copy.js || node-gyp configure build

[ref-prebuilt] platform not linux
  CXX(target) Release/obj.target/binding/src/binding.o
  SOLINK_MODULE(target) Release/binding.node
  SOLINK_MODULE(target) Release/binding.node: Finished

> sockit-to-me@0.3.2 install /Users/kevin/workspace/gaia/node_modules/marionette-client/node_modules/sockit-to-me
> ./tools/copy.js || node-gyp configure build

[sockit-to-me] platform not linux
  CXX(target) Release/obj.target/sockit/src/node-0.10/addon.o
  CXX(target) Release/obj.target/sockit/src/node-0.10/sockit.o
../src/node-0.10/sockit.cc:41:21: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
    fprintf(stderr, aMsg);
                    ^~~~
1 warning generated.
  SOLINK_MODULE(target) Release/sockit.node
  SOLINK_MODULE(target) Release/sockit.node: Finished

> dtrace-provider@0.2.8 install /Users/kevin/workspace/gaia/node_modules/restify/node_modules/dtrace-provider
> node-gyp rebuild

  ACTION binding_gyp_libusdt_target_build_libusdt .
Building libusdt for x86_64
gmake[2]: Entering directory '/Users/kevin/workspace/gaia/node_modules/restify/node_modules/dtrace-provider/libusdt'
rm -f *.gch
rm -f *.o
rm -f libusdt.a
rm -f test_usdt
rm -f test_usdt32
rm -f test_usdt64
rm -f test_mem_usage
gcc -O2 -arch x86_64   -c -o usdt.o usdt.c
usdt.c:212:9: warning: implicit declaration of function 'usdt_dof_section_free' is invalid in C99 [-Wimplicit-function-declaration]
        usdt_dof_section_free(&strtab);
        ^
usdt.c:238:9: warning: implicit declaration of function 'usdt_dof_file_free' is invalid in C99 [-Wimplicit-function-declaration]
        usdt_dof_file_free(provider->file);
        ^
2 warnings generated.
gcc -O2 -arch x86_64   -c -o usdt_dof_file.o usdt_dof_file.c
gcc -arch x86_64 -o usdt_tracepoints.o -c usdt_tracepoints_x86_64.s
gcc -O2 -arch x86_64   -c -o usdt_probe.o usdt_probe.c
gcc -O2 -arch x86_64   -c -o usdt_dof.o usdt_dof.c
gcc -O2 -arch x86_64   -c -o usdt_dof_sections.o usdt_dof_sections.c
rm -f libusdt.a
ar cru libusdt.a usdt.o usdt_dof_file.o usdt_tracepoints.o usdt_probe.o usdt_dof.o usdt_dof_sections.o 
ranlib libusdt.a
gmake[2]: Leaving directory '/Users/kevin/workspace/gaia/node_modules/restify/node_modules/dtrace-provider/libusdt'
  TOUCH Release/obj.target/libusdt.stamp
  CXX(target) Release/obj.target/DTraceProviderBindings/dtrace_provider.o
  CXX(target) Release/obj.target/DTraceProviderBindings/dtrace_probe.o
  CXX(target) Release/obj.target/DTraceProviderBindings/dtrace_argument.o
  SOLINK_MODULE(target) Release/DTraceProviderBindings.node
  SOLINK_MODULE(target) Release/DTraceProviderBindings.node: Finished

> sockit-to-me@0.2.3 install /Users/kevin/workspace/gaia/node_modules/marionette-plugin-forms/node_modules/marionette-client/node_modules/sockit-to-me
> ./tools/copy.js || node-gyp configure build

[sockit-to-me] platform not linux
  CXX(target) Release/obj.target/sockit/src/addon.o
  CXX(target) Release/obj.target/sockit/src/sockit.o
  SOLINK_MODULE(target) Release/sockit.node
  SOLINK_MODULE(target) Release/sockit.node: Finished

> ws@0.4.20 install /Users/kevin/workspace/gaia/node_modules/test-agent/node_modules/websocket.io/node_modules/ws
> node install.js

[ws v0.4.20] Attempting to compile blazing fast native extensions.
[ws v0.4.20] Native extension compilation successful!

> ws@0.4.32 install /Users/kevin/workspace/gaia/node_modules/test-agent/node_modules/ws
> (node-gyp rebuild 2> builderror.log) || (exit 0)

  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/bufferutil.node
  SOLINK_MODULE(target) Release/bufferutil.node: Finished
  CXX(target) Release/obj.target/validation/src/validation.o
  SOLINK_MODULE(target) Release/validation.node
  SOLINK_MODULE(target) Release/validation.node: Finished
npm WARN prefer global jshint@2.6.0 should be installed with -g

> marionette-js-runner@1.0.15 postinstall /Users/kevin/workspace/gaia/node_modules/marionette-js-runner
> ./scripts/setup_python.sh

checking python version
Python version found: 2 7 9 
Setting up virtualenv
/usr/local/bin/pip
/usr/local/bin/virtualenv
./scripts/setup_python.sh: /usr/local/bin/virtualenv: /usr/bin/python: bad interpreter: No such file or directory

npm ERR! marionette-js-runner@1.0.15 postinstall: `./scripts/setup_python.sh`
npm ERR! Exit status 126
npm ERR! 
npm ERR! Failed at the marionette-js-runner@1.0.15 postinstall script.
npm ERR! This is most likely a problem with the marionette-js-runner package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     ./scripts/setup_python.sh
npm ERR! You can get their info via:
npm ERR!     npm owner ls marionette-js-runner
npm ERR! There is likely additional logging output above.
npm ERR! System Darwin 14.1.0
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "rebuild"
npm ERR! cwd /Users/kevin/workspace/gaia
npm ERR! node -v v0.10.31
npm ERR! npm -v 1.4.23
npm ERR! code ELIFECYCLE
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/kevin/workspace/gaia/npm-debug.log
npm ERR! not ok code 0
make: *** [node_modules] Error 1
Flags: needinfo?(jlal)
Flags: needinfo?(gaye)
I'm seeing the exact same error when trying to run my unit tests locally.  Is there any easier workaround than reverting the commit?

Thanks,

-tamara
Hi Kevin,

Is there any way we can back this out?  It's preventing me from running tests locally.  

Thanks,
-tamara
Flags: needinfo?(kgrandon)
Tamara - I was able to resolve this by uninstalling and re-installing venv. Try that and see if it works for you? I'm not sure if we should back it out, seems a shame that this would stop working after an OS update, though I'm not sure where the bug lies.

Anyway, I got it working and kind of forgot about it, but I think a lot of people are going to run into this situation =/
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: needinfo?(kgrandon)
Flags: needinfo?(jlal)
Flags: needinfo?(gaye)
Resolution: --- → WORKSFORME
Hi Kevin,

Thanks, that helped me get past the error above.  I just did a |pip uninstall virtualenv| and then a |pip install virtualenv|.  Oddly after I ran the ./bin/gaia-test -d and was able to execute the tests just once.  Not sure what happened, but I'm getting different errors now where the tests just don't execute. I will keep looking at it and if I find a resolution, I will post back here in case anyone else runs into it.

I agree we shouldn't back it out.

thanks,

-tamara
You need to log in before you can comment on or make changes to this bug.