Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

"Binary has a problem" with 4.13.1 #2822

Closed
ckaczor opened this issue Jan 16, 2020 · 27 comments
Closed

"Binary has a problem" with 4.13.1 #2822

ckaczor opened this issue Jan 16, 2020 · 27 comments

Comments

@ckaczor
Copy link

ckaczor commented Jan 16, 2020

We're getting the following during builds with 4.13.1 - if we go back to 4.13.0 everything is fine.

2020-01-16T17:04:44.3993932Z > [email protected] postinstall /node_modules/node-sass
2020-01-16T17:04:44.4010867Z > node scripts/build.js
2020-01-16T17:04:44.4016913Z
2020-01-16T17:04:44.5530663Z Binary found at /node_modules/node-sass/vendor/linux_musl-x64-64/binding.node
2020-01-16T17:04:44.5548706Z Testing binary
2020-01-16T17:04:44.6559773Z Binary has a problem: Error: Error relocating /node_modules/node-sass/vendor/linux_musl-x64-64/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
2020-01-16T17:04:44.6609834Z at Object.Module._extensions..node (internal/modules/cjs/loader.js:718:18)
2020-01-16T17:04:44.6623255Z at Module.load (internal/modules/cjs/loader.js:599:32)
2020-01-16T17:04:44.6640744Z at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
2020-01-16T17:04:44.6653951Z at Function.Module._load (internal/modules/cjs/loader.js:530:3)
2020-01-16T17:04:44.6667669Z at Module.require (internal/modules/cjs/loader.js:637:17)
2020-01-16T17:04:44.6681340Z at require (internal/modules/cjs/helpers.js:22:18)
2020-01-16T17:04:44.6696639Z at module.exports (/node_modules/node-sass/lib/binding.js:19:10)
2020-01-16T17:04:44.6713582Z at Object. (/node_modules/node-sass/lib/index.js:14:35)
2020-01-16T17:04:44.6730091Z at Module._compile (internal/modules/cjs/loader.js:689:30)
2020-01-16T17:04:44.6743279Z at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)

@nschonni
Copy link
Contributor

Did you clear your node_modules or vendor folder? The binding code was changed so it won't be able to reusing the binding.node from 4.13.0

@rwoody
Copy link

rwoody commented Jan 16, 2020

We got this in a docker build as well. We aren't using any lock files. Changed the package.json from ^4.9.3 to 4.13.0 and everything works again.

Our npm installs were complaining about python 2 not being found...

@b3n01t
Copy link

b3n01t commented Jan 16, 2020

@xzyfer Are you guys fixing this?
We have dependencies using node-sass and we cannot have them pin their dependencies to what we need.

@b3n01t
Copy link

b3n01t commented Jan 16, 2020

Logs from npm install in a Docker image from node:10.14-alpine

> [email protected] postinstall /usr/src/node_modules/xxx/node_modules/node-sass
> node scripts/build.js

Binary found at /usr/src/node_modules/xxx/node_modules/node-sass/vendor/linux_musl-x64-64/binding.node
Testing binary
Binary has a problem: Error: Error relocating /usr/src/node_modules/xxx/node_modules/node-sass/vendor/linux_musl-x64-64/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
    at Object.Module._extensions..node (internal/modules/cjs/loader.js:718:18)
    at Module.load (internal/modules/cjs/loader.js:599:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
    at Function.Module._load (internal/modules/cjs/loader.js:530:3)
    at Module.require (internal/modules/cjs/loader.js:637:17)
    at require (internal/modules/cjs/helpers.js:22:18)
    at module.exports (/usr/src/node_modules/xxx/node_modules/node-sass/lib/binding.js:19:10)
    at Object.<anonymous> (/usr/src/node_modules/xxx/node_modules/node-sass/lib/index.js:14:35)
    at Module._compile (internal/modules/cjs/loader.js:689:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
Building the binary locally
Building: /usr/local/bin/node /usr/src/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
gyp verb cli [ '/usr/local/bin/node',
gyp verb cli   '/usr/src/node_modules/node-gyp/bin/node-gyp.js',
gyp verb cli   'rebuild',
gyp verb cli   '--verbose',
gyp verb cli   '--libsass_ext=',
gyp verb cli   '--libsass_cflags=',
gyp verb cli   '--libsass_ldflags=',
gyp verb cli   '--libsass_library=' ]
gyp info using [email protected]
gyp info using [email protected] | linux | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed     at getNotFoundError (/usr/src/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/usr/src/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/usr/src/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /usr/src/node_modules/which/which.js:89:16
gyp verb `which` failed     at /usr/src/node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /usr/src/node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (/usr/src/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/usr/src/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/usr/src/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /usr/src/node_modules/which/which.js:89:16
gyp verb `which` failed     at /usr/src/node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /usr/src/node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed   stack:
gyp verb `which` failed    'Error: not found: python2\n    at getNotFoundError (/usr/src/node_modules/which/which.js:13:12)\n    at F (/usr/src/node_modules/which/which.js:68:19)\n    at E (/usr/src/node_modules/which/which.js:80:29)\n    at /usr/src/node_modules/which/which.js:89:16\n    at /usr/src/node_modules/isexe/index.js:42:5\n    at /usr/src/node_modules/isexe/mode.js:8:5\n    at FSReqWrap.oncomplete (fs.js:154:21)',
gyp verb `which` failed   code: 'ENOENT' }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` failed Error: not found: python
gyp verb `which` failed     at getNotFoundError (/usr/src/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/usr/src/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/usr/src/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /usr/src/node_modules/which/which.js:89:16
gyp verb `which` failed     at /usr/src/node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /usr/src/node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed  python { Error: not found: python
gyp verb `which` failed     at getNotFoundError (/usr/src/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/usr/src/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/usr/src/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /usr/src/node_modules/which/which.js:89:16
gyp verb `which` failed     at /usr/src/node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /usr/src/node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed   stack:
gyp verb `which` failed    'Error: not found: python\n    at getNotFoundError (/usr/src/node_modules/which/which.js:13:12)\n    at F (/usr/src/node_modules/which/which.js:68:19)\n    at E (/usr/src/node_modules/which/which.js:80:29)\n    at /usr/src/node_modules/which/which.js:89:16\n    at /usr/src/node_modules/isexe/index.js:42:5\n    at /usr/src/node_modules/isexe/mode.js:8:5\n    at FSReqWrap.oncomplete (fs.js:154:21)',
gyp verb `which` failed   code: 'ENOENT' }
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (/usr/src/node_modules/node-gyp/lib/configure.js:484:19)
gyp ERR! stack     at PythonFinder.<anonymous> (/usr/src/node_modules/node-gyp/lib/configure.js:406:16)
gyp ERR! stack     at F (/usr/src/node_modules/which/which.js:68:16)
gyp ERR! stack     at E (/usr/src/node_modules/which/which.js:80:29)
gyp ERR! stack     at /usr/src/node_modules/which/which.js:89:16
gyp ERR! stack     at /usr/src/node_modules/isexe/index.js:42:5
gyp ERR! stack     at /usr/src/node_modules/isexe/mode.js:8:5
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:154:21)
gyp ERR! System Linux 4.9.184-linuxkit
gyp ERR! command "/usr/local/bin/node" "/usr/src/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /usr/src/node_modules/xxx/node_modules/node-sass
gyp ERR! node -v v10.14.2
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.2.7 (node_modules/jest-haste-map/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN [email protected] requires a peer of react-router@^4.3.1 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of react@>=15.5 <16 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of react-dom@>=15.5 <16 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of webpack@^3.1.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/ansi-regex):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/ansi-regex' -> '/usr/src/node_modules/fsevents/node_modules/.ansi-regex.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/balanced-match):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/balanced-match' -> '/usr/src/node_modules/fsevents/node_modules/.balanced-match.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/code-point-at):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/code-point-at' -> '/usr/src/node_modules/fsevents/node_modules/.code-point-at.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/concat-map):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/concat-map' -> '/usr/src/node_modules/fsevents/node_modules/.concat-map.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/console-control-strings):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/console-control-strings' -> '/usr/src/node_modules/fsevents/node_modules/.console-control-strings.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/inherits):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/inherits' -> '/usr/src/node_modules/fsevents/node_modules/.inherits.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/minimist):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/minimist' -> '/usr/src/node_modules/fsevents/node_modules/.minimist.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/number-is-nan):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/number-is-nan' -> '/usr/src/node_modules/fsevents/node_modules/.number-is-nan.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/safe-buffer):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/safe-buffer' -> '/usr/src/node_modules/fsevents/node_modules/.safe-buffer.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/wrappy):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/wrappy' -> '/usr/src/node_modules/fsevents/node_modules/.wrappy.DELETE'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents/node_modules/yallist):
npm WARN enoent SKIPPING OPTIONAL DEPENDENCY: ENOENT: no such file or directory, rename '/usr/src/node_modules/fsevents/node_modules/yallist' -> '/usr/src/node_modules/fsevents/node_modules/.yallist.DELETE'

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall 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!     /root/.npm/_logs/2020-01-16T17_50_28_963Z-debug.log

@yury-sannikov
Copy link

yury-sannikov commented Jan 16, 2020

Seeing the same. Putting "node-sass": "4.13.0" into the package.json allowed me to build the project.

@amaschas
Copy link

amaschas commented Jan 16, 2020

Seeing in the same problem in our docker build using 3.7.2-alpine3.8. The check on the binary fails with a symbol not found and tries to build node-sass from source, which also fails because the relevant dependencies are not available in alpine. In our case node-sass was being installed by a downstream dependency, and adding "node-sass": "4.13.0" to our package.json allowed builds to proceed.

#28 121.2 Binary found at /app/node_modules/node-sass/vendor/linux_musl-x64-57/binding.node
#28 121.2 Testing binary
#28 121.3 Binary has a problem: Error: Error relocating /app/node_modules/node-sass/vendor/linux_musl-x64-57/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
#28 121.3     at Object.Module._extensions..node (module.js:682:18)
#28 121.3     at Module.load (module.js:566:32)
#28 121.3     at tryModuleLoad (module.js:506:12)
#28 121.3     at Function.Module._load (module.js:498:3)
#28 121.3     at Module.require (module.js:597:17)
#28 121.3     at require (internal/module.js:11:18)
#28 121.3     at module.exports (/app/node_modules/node-sass/lib/binding.js:19:10)
#28 121.3     at Object.<anonymous> (/app/node_modules/node-sass/lib/index.js:14:35)
#28 121.3     at Module._compile (module.js:653:30)
#28 121.3     at Object.Module._extensions..js (module.js:664:10)
#28 121.3 Building the binary locally

@xzyfer
Copy link
Contributor

xzyfer commented Jan 16, 2020

@ckaczor @b3n01t I've rebuilt the linux_musl-x64-64 binary. Can you try again?

@b3n01t
Copy link

b3n01t commented Jan 16, 2020

Thanks for looking at this.
Here is how I tested:

docker container run --name test --rm -i -t node:10.14-alpine npm i [email protected]

This is still failing:

#docker container run --name test2 --rm -i -t node:10.14-alpine npm i [email protected]

> [email protected] install /node_modules/node-sass
> node scripts/install.js

Downloading binary from https://github.com/sass/node-sass/releases/download/v4.13.1/linux_musl-x64-64_binding.node
Download complete  ] - :
Binary saved to /node_modules/node-sass/vendor/linux_musl-x64-64/binding.node
Caching binary to /root/.npm/node-sass/4.13.1/linux_musl-x64-64_binding.node

> [email protected] postinstall /node_modules/node-sass
> node scripts/build.js

Binary found at /node_modules/node-sass/vendor/linux_musl-x64-64/binding.node
Testing binary
Binary has a problem: Error: Error relocating /node_modules/node-sass/vendor/linux_musl-x64-64/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
    at Object.Module._extensions..node (internal/modules/cjs/loader.js:718:18)
    at Module.load (internal/modules/cjs/loader.js:599:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
    at Function.Module._load (internal/modules/cjs/loader.js:530:3)
    at Module.require (internal/modules/cjs/loader.js:637:17)
    at require (internal/modules/cjs/helpers.js:22:18)
    at module.exports (/node_modules/node-sass/lib/binding.js:19:10)
    at Object.<anonymous> (/node_modules/node-sass/lib/index.js:14:35)
    at Module._compile (internal/modules/cjs/loader.js:689:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
Building the binary locally
Building: /usr/local/bin/node /node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
gyp verb cli [ '/usr/local/bin/node',
gyp verb cli   '/node_modules/node-gyp/bin/node-gyp.js',
gyp verb cli   'rebuild',
gyp verb cli   '--verbose',
gyp verb cli   '--libsass_ext=',
gyp verb cli   '--libsass_cflags=',
gyp verb cli   '--libsass_ldflags=',
gyp verb cli   '--libsass_library=' ]
gyp info using [email protected]
gyp info using [email protected] | linux | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed     at getNotFoundError (/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /node_modules/which/which.js:89:16
gyp verb `which` failed     at /node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /node_modules/which/which.js:89:16
gyp verb `which` failed     at /node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed   stack:
gyp verb `which` failed    'Error: not found: python2\n    at getNotFoundError (/node_modules/which/which.js:13:12)\n    at F (/node_modules/which/which.js:68:19)\n    at E (/node_modules/which/which.js:80:29)\n    at /node_modules/which/which.js:89:16\n    at /node_modules/isexe/index.js:42:5\n    at /node_modules/isexe/mode.js:8:5\n    at FSReqWrap.oncomplete (fs.js:154:21)',
gyp verb `which` failed   code: 'ENOENT' }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` failed Error: not found: python
gyp verb `which` failed     at getNotFoundError (/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /node_modules/which/which.js:89:16
gyp verb `which` failed     at /node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed  python { Error: not found: python
gyp verb `which` failed     at getNotFoundError (/node_modules/which/which.js:13:12)
gyp verb `which` failed     at F (/node_modules/which/which.js:68:19)
gyp verb `which` failed     at E (/node_modules/which/which.js:80:29)
gyp verb `which` failed     at /node_modules/which/which.js:89:16
gyp verb `which` failed     at /node_modules/isexe/index.js:42:5
gyp verb `which` failed     at /node_modules/isexe/mode.js:8:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:154:21)
gyp verb `which` failed   stack:
gyp verb `which` failed    'Error: not found: python\n    at getNotFoundError (/node_modules/which/which.js:13:12)\n    at F (/node_modules/which/which.js:68:19)\n    at E (/node_modules/which/which.js:80:29)\n    at /node_modules/which/which.js:89:16\n    at /node_modules/isexe/index.js:42:5\n    at /node_modules/isexe/mode.js:8:5\n    at FSReqWrap.oncomplete (fs.js:154:21)',
gyp verb `which` failed   code: 'ENOENT' }
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (/node_modules/node-gyp/lib/configure.js:484:19)
gyp ERR! stack     at PythonFinder.<anonymous> (/node_modules/node-gyp/lib/configure.js:406:16)
gyp ERR! stack     at F (/node_modules/which/which.js:68:16)
gyp ERR! stack     at E (/node_modules/which/which.js:80:29)
gyp ERR! stack     at /node_modules/which/which.js:89:16
gyp ERR! stack     at /node_modules/isexe/index.js:42:5
gyp ERR! stack     at /node_modules/isexe/mode.js:8:5
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:154:21)
gyp ERR! System Linux 4.9.184-linuxkit
gyp ERR! command "/usr/local/bin/node" "/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /node_modules/node-sass
gyp ERR! node -v v10.14.2
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN enoent ENOENT: no such file or directory, open '/package.json'
npm WARN !invalid#1 No description
npm WARN !invalid#1 No repository field.
npm WARN !invalid#1 No README data
npm WARN !invalid#1 No license field.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall 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!     /root/.npm/_logs/2020-01-16T21_35_47_726Z-debug.log
b3n01t:~❱ docker container run --name test2 --rm -i -t node:10.14-alpine npm i [email protected]
npm ERR! code ETARGET
npm ERR! notarget No matching version found for [email protected]
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-01-16T21_37_01_037Z-debug.log

@chrflo
Copy link

chrflo commented Jan 16, 2020

This is still occurring for us as well.

Binary has a problem: Error: Error relocating /node_modules/node-sass/vendor/linux_musl-x64-64/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found

@xzyfer
Copy link
Contributor

xzyfer commented Jan 16, 2020 via email

@simoncoulton
Copy link

simoncoulton commented Jan 17, 2020

Seeing the same issue here in our CI/CD. Alpine Linux, was ^4.11.0 in the package.json file, will pin as per some other suggestions and report back.

EDIT: Previous build was running 4.13.0 with no issues, todays was 4.13.1, reverting to 4.13.0 resolved the issue.

Logs from failure:

[Fri Jan 17 01:10:41] Binary found at /app/static/node_modules/node-sass/vendor/linux_musl-x64-64/binding.node
 [Fri Jan 17 01:10:41] Testing binary
 [Fri Jan 17 01:10:41] Binary has a problem: Error: Error relocating /app/static/node_modules/node-sass/vendor/linux_musl-x64-64/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
 [Fri Jan 17 01:10:41]     at Object.Module._extensions..node (internal/modules/cjs/loader.js:718:18)
 [Fri Jan 17 01:10:41]     at Module.load (internal/modules/cjs/loader.js:599:32)
 [Fri Jan 17 01:10:41]     at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
 [Fri Jan 17 01:10:41]     at Function.Module._load (internal/modules/cjs/loader.js:530:3)
 [Fri Jan 17 01:10:41]     at Module.require (internal/modules/cjs/loader.js:637:17)
 [Fri Jan 17 01:10:41]     at require (internal/modules/cjs/helpers.js:20:18)
 [Fri Jan 17 01:10:41]     at module.exports (/app/static/node_modules/node-sass/lib/binding.js:19:10)
 [Fri Jan 17 01:10:41]     at Object.<anonymous> (/app/static/node_modules/node-sass/lib/index.js:14:35)
 [Fri Jan 17 01:10:41]     at Module._compile (internal/modules/cjs/loader.js:689:30)
 [Fri Jan 17 01:10:41]     at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
 [Fri Jan 17 01:10:41] Building the binary locally
 [Fri Jan 17 01:10:41] Building: /usr/local/bin/node /app/static/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
 [Fri Jan 17 01:10:42] gyp info it worked if it ends with ok
 [Fri Jan 17 01:10:42] gyp verb cli [ '/usr/local/bin/node',
 [Fri Jan 17 01:10:42] gyp verb cli   '/app/static/node_modules/node-gyp/bin/node-gyp.js',
 [Fri Jan 17 01:10:42] gyp verb cli   'rebuild',
 [Fri Jan 17 01:10:42] gyp verb cli   '--verbose',
 [Fri Jan 17 01:10:42] gyp verb cli   '--libsass_ext=',
 [Fri Jan 17 01:10:42] gyp verb cli   '--libsass_cflags=',
 [Fri Jan 17 01:10:42] gyp verb cli   '--libsass_ldflags=',
 [Fri Jan 17 01:10:42] gyp verb cli   '--libsass_library=' ]
 [Fri Jan 17 01:10:42] gyp info using [email protected]
 [Fri Jan 17 01:10:42] gyp info using [email protected] | linux | x64
 [Fri Jan 17 01:10:42] gyp verb command rebuild []
 [Fri Jan 17 01:10:42] gyp verb command clean []
 [Fri Jan 17 01:10:42] gyp verb clean removing "build" directory
 [Fri Jan 17 01:10:42] gyp verb command configure []
 [Fri Jan 17 01:10:42] gyp verb check python checking for Python executable "python2" in the PATH
 [Fri Jan 17 01:10:42] gyp verb `which` failed Error: not found: python2
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at getNotFoundError (/app/static/node_modules/which/which.js:13:12)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at F (/app/static/node_modules/which/which.js:68:19)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at E (/app/static/node_modules/which/which.js:80:29)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/which/which.js:89:16
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/index.js:42:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/mode.js:8:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:152:21)
 [Fri Jan 17 01:10:42] gyp verb `which` failed  python2 { Error: not found: python2
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at getNotFoundError (/app/static/node_modules/which/which.js:13:12)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at F (/app/static/node_modules/which/which.js:68:19)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at E (/app/static/node_modules/which/which.js:80:29)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/which/which.js:89:16
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/index.js:42:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/mode.js:8:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:152:21)
 [Fri Jan 17 01:10:42] gyp verb `which` failed   stack:
 [Fri Jan 17 01:10:42] gyp verb `which` failed    'Error: not found: python2\n    at getNotFoundError (/app/static/node_modules/which/which.js:13:12)\n    at F (/app/static/node_modules/which/which.js:68:19)\n    at E (/app/static/node_modules/which/which.js:80:29)\n    at /app/static/node_modules/which/which.js:89:16\n    at /app/static/node_modules/isexe/index.js:42:5\n    at /app/static/node_modules/isexe/mode.js:8:5\n    at FSReqWrap.oncomplete (fs.js:152:21)',
 [Fri Jan 17 01:10:42] gyp verb `which` failed   code: 'ENOENT' }
 [Fri Jan 17 01:10:42] gyp verb check python checking for Python executable "python" in the PATH
 [Fri Jan 17 01:10:42] gyp verb `which` failed Error: not found: python
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at getNotFoundError (/app/static/node_modules/which/which.js:13:12)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at F (/app/static/node_modules/which/which.js:68:19)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at E (/app/static/node_modules/which/which.js:80:29)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/which/which.js:89:16
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/index.js:42:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/mode.js:8:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:152:21)
 [Fri Jan 17 01:10:42] gyp verb `which` failed  python { Error: not found: python
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at getNotFoundError (/app/static/node_modules/which/which.js:13:12)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at F (/app/static/node_modules/which/which.js:68:19)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at E (/app/static/node_modules/which/which.js:80:29)
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/which/which.js:89:16
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/index.js:42:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at /app/static/node_modules/isexe/mode.js:8:5
 [Fri Jan 17 01:10:42] gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:152:21)
 [Fri Jan 17 01:10:42] gyp verb `which` failed   stack:
 [Fri Jan 17 01:10:42] gyp verb `which` failed    'Error: not found: python\n    at getNotFoundError (/app/static/node_modules/which/which.js:13:12)\n    at F (/app/static/node_modules/which/which.js:68:19)\n    at E (/app/static/node_modules/which/which.js:80:29)\n    at /app/static/node_modules/which/which.js:89:16\n    at /app/static/node_modules/isexe/index.js:42:5\n    at /app/static/node_modules/isexe/mode.js:8:5\n    at FSReqWrap.oncomplete (fs.js:152:21)',
 [Fri Jan 17 01:10:42] gyp verb `which` failed   code: 'ENOENT' }
 [Fri Jan 17 01:10:42] gyp ERR! configure error 
 [Fri Jan 17 01:10:42] gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
 [Fri Jan 17 01:10:42] gyp ERR! stack     at PythonFinder.failNoPython (/app/static/node_modules/node-gyp/lib/configure.js:484:19)
 [Fri Jan 17 01:10:42] gyp ERR! stack     at PythonFinder.<anonymous> (/app/static/node_modules/node-gyp/lib/configure.js:406:16)
 [Fri Jan 17 01:10:42] gyp ERR! stack     at F (/app/static/node_modules/which/which.js:68:16)
 [Fri Jan 17 01:10:42] gyp ERR! stack     at E (/app/static/node_modules/which/which.js:80:29)
 [Fri Jan 17 01:10:42] gyp ERR! stack     at /app/static/node_modules/which/which.js:89:16
 [Fri Jan 17 01:10:42] gyp ERR! stack     at /app/static/node_modules/isexe/index.js:42:5
 [Fri Jan 17 01:10:42] gyp ERR! stack     at /app/static/node_modules/isexe/mode.js:8:5
 [Fri Jan 17 01:10:42] gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:152:21)
 [Fri Jan 17 01:10:42] gyp ERR! System Linux 4.9.184-linuxkit
 [Fri Jan 17 01:10:42] gyp ERR! command "/usr/local/bin/node" "/app/static/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
 [Fri Jan 17 01:10:42] gyp ERR! cwd /app/static/node_modules/node-sass
 [Fri Jan 17 01:10:42] gyp ERR! node -v v10.9.0
 [Fri Jan 17 01:10:42] gyp ERR! node-gyp -v v3.8.0
 [Fri Jan 17 01:10:42] gyp ERR! not ok 
 [Fri Jan 17 01:10:42] Build failed with error code: 1
 [Fri Jan 17 01:10:44] npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents):
 [Fri Jan 17 01:10:44] npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
 [Fri Jan 17 01:10:44] 
 [Fri Jan 17 01:10:44] npm ERR! code ELIFECYCLE
 [Fri Jan 17 01:10:44] npm ERR! errno 1
 [Fri Jan 17 01:10:44] npm ERR! [email protected] postinstall: `node scripts/build.js`
 [Fri Jan 17 01:10:44] npm ERR! Exit status 1
 [Fri Jan 17 01:10:44] npm ERR! 
 [Fri Jan 17 01:10:44] npm ERR! Failed at the [email protected] postinstall script.

@yuchunyu97
Copy link

I had the same problem on Alpine.
But I upgraded Alpine from 3.10 to 3.11 to solve the problem.

I guess it may be caused by different versions of Alpine.

tomdrewes added a commit to tomdrewes/sass.js that referenced this issue Jan 17, 2020
@xzyfer
Copy link
Contributor

xzyfer commented Jan 19, 2020

I've digging into this. It looks an issue with node:-alpine containers < 10.18. Something may have changed in with the newer containers which is causing incompatibilities with older node:-alpine containers.

This works fine

docker container run --name test --rm -i -t node:10.18-alpine npm i [email protected]

Where this fails with the errors reported here

docker container run --name test --rm -i -t node:10.17-alpine npm i [email protected]

Judging by the reports in this issue this isn't isolated to Node 10 builds since we have reports from Node 8 also.

@xzyfer
Copy link
Contributor

xzyfer commented Jan 19, 2020

I've rebuilt the Node 10 alpine binary with node 10.16. This appears to address this issue.

@xzyfer xzyfer closed this as completed Jan 19, 2020
@amaschas
Copy link

Are you sure that the problem is related to Node 10 Alpine? I encountered it running a Python Alpine (3.7.2-alpine3.8) onto which we installed Node.

@rysinal
Copy link

rysinal commented Jan 19, 2020

Seeing the same. Putting "node-sass": "4.13.0" into the package.json allowed me to build the project.

This works fine

@turbidwater
Copy link

@xzyfer Retried a build with 4.13.1 today, and still getting the bad binary issue:
`> [email protected] postinstall /opt/atlassian/pipelines/agent/build/node_modules/node-sass

node scripts/build.js
Binary found at /opt/atlassian/pipelines/agent/build/node_modules/node-sass/vendor/linux_musl-x64-57/binding.node
Testing binary
Binary has a problem: Error: Error relocating /opt/atlassian/pipelines/agent/build/node_modules/node-sass/vendor/linux_musl-x64-57/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
at Object.Module._extensions..node (module.js:682:18)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Module.require (module.js:597:17)
at require (internal/module.js:11:18)
at module.exports (/opt/atlassian/pipelines/agent/build/node_modules/node-sass/lib/binding.js:19:10)
at Object. (/opt/atlassian/pipelines/agent/build/node_modules/node-sass/lib/index.js:14:35)
at Module._compile (module.js:653:30)
at Object.Module._extensions..js (module.js:664:10)`

@Darep
Copy link

Darep commented Jan 21, 2020

Also having this problem with node:8.12-alpine image:

docker run --rm -it node:8.12-alpine npm install [email protected]

[email protected] works fine

@anthonycarella
Copy link

anthonycarella commented Jan 21, 2020

Initially, I was able to resolve by also explicitly using node-sass 4.13.0.

However, one of the architects on my team ran docker system prune in our project's environment to clear out old containers and cache, and that allowed our container to use node-sass 4.13.1; seems to have also resolved the issue as well.

@turbidwater
Copy link

@anthonycarella Ah, excellent point. We have a private registry that serves as a proxy, and I bet it has the old 4.13.1 cached. I'll see if we can get that cleared.

rdok added a commit to rdok/indecision that referenced this issue Jan 22, 2020
- Bump from alpine 3.10 to 3.11 to avoid compiling node-sass. It's important to avoid this as it decreased the build time to ~2 mintues :/.  See sass/node-sass#2822 (comment)
- CI: cache node modules using the github action cache.
rdok added a commit to rdok/indecision that referenced this issue Jan 22, 2020
- Bump from alpine 3.10 to 3.11 to avoid compiling node-sass. It's important to avoid this as it decreased the build time to ~2 mintues :/.  See sass/node-sass#2822 (comment)
- CI: cache node modules using the github action cache.
rdok added a commit to rdok/indecision that referenced this issue Jan 22, 2020
- Bump from alpine 3.10 to 3.11 to avoid compiling node-sass. It's important to avoid this as it decreased the build time to ~2 mintues :/.  See sass/node-sass#2822 (comment)
- CI: cache node modules using the github action cache.
rdok added a commit to rdok/indecision that referenced this issue Jan 22, 2020
- Bump from alpine 3.10 to 3.11 to avoid compiling node-sass. It's important to avoid this as it decreased the build time to ~2 mintues :/.  See sass/node-sass#2822 (comment)
- CI: cache node modules using the github action cache.
rdok added a commit to rdok/indecision that referenced this issue Jan 22, 2020
- Bump from alpine 3.10 to 3.11 to avoid compiling node-sass. It's important to avoid this as it decreased the build time to ~2 mintues :/.  See sass/node-sass#2822 (comment)
- CI: cache node modules using the github action cache.
@xzyfer
Copy link
Contributor

xzyfer commented Jan 30, 2020

I've updated the Node 8 binary. It should work now.

@enricodvn
Copy link

I had this problem with linux kernel 5.0.0-38-generic. My coleagues, while building the same Dockerfile, did not encounter this error (with the version 4.13.1). They were running kernels version 5.3+. I had to downgrade to 4.13.0.

@artemtam
Copy link

Updating node:13.8-alpine3.10 to node:13.8-alpine3.11 solved the problem for me.

@EvaMalinina
Copy link

I used npm and had the same issue after I run "yarn add node-sass" and it's worked.

@Freddvch
Copy link

Updating node:13.8-alpin

same for me

@harrisoncramer
Copy link

harrisoncramer commented Dec 13, 2020

I'm using some other libraries that require a newer version of node.js (not 10.14-alpine). Has there been any progress in fixing this bug?

Logs:

 > [builder 4/4] RUN yarn install && yarn build:
#14 0.372 yarn install v1.22.5
#14 0.397 warning package.json: No license field
#14 0.495 warning [email protected]: No license field
#14 0.497 [1/4] Resolving packages...
#14 1.247 [2/4] Fetching packages...
#14 1.266 warning Pattern ["object-assign@latest"] is trying to unpack in the same destination "/usr/local/share/.cache/yarn/v6/npm-object-assign-4.1.1-2109adc7965887cfc05cbbd442cac8bfbb360863-integrity/nod
e_modules/object-assign" as pattern ["object-assign@^4.1.1","object-assign@^4.0.1","object-assign@^4.1.0","object-assign@^4.1.1","object-assign@^4.1.1","object-assign@^4.1.1","object-assign@^4.1.1","object-
assign@^4.0.1","object-assign@^4.1.0","object-assign@^4.1.1","object-assign@^4.0.1","object-assign@^4"]. This could result in non-deterministic behavior, skipping.
#14 1.266 warning Pattern ["send@latest"] is trying to unpack in the same destination "/usr/local/share/.cache/yarn/v6/npm-send-0.17.1-c1d8b059f7900f7466dd4938bdc44e11ddb376c8-integrity/node_modules/send" a
s pattern ["[email protected]","[email protected]"]. This could result in non-deterministic behavior, skipping.
#14 53.01 info [email protected]: The platform "linux" is incompatible with this module.
#14 53.01 info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
#14 53.03 info [email protected]: The platform "linux" is incompatible with this module.
#14 53.03 info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
#14 53.03 info [email protected]: The platform "linux" is incompatible with this module.
#14 53.03 info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
#14 53.05 [3/4] Linking dependencies...
#14 53.05 warning " > @apollo/[email protected]" has unmet peer dependency "subscriptions-transport-ws@^0.9.0".
#14 53.05 warning " > [email protected]" has unmet peer dependency "prop-types@^15.6.0".
#14 53.07 warning " > @typescript-eslint/[email protected]" has unmet peer dependency "eslint@^5.0.0 || ^6.0.0 || ^7.0.0".
#14 53.07 warning "@typescript-eslint/eslint-plugin > @typescript-eslint/[email protected]" has unmet peer dependency "eslint@*".
#14 53.07 warning " > @typescript-eslint/[email protected]" has unmet peer dependency "eslint@^5.0.0 || ^6.0.0 || ^7.0.0".
#14 53.07 warning " > [email protected]" has unmet peer dependency "eslint@^3 || ^4 || ^5 || ^6 || ^7".
#14 53.07 warning " > [email protected]" has unmet peer dependency "jest@>=26 <27".
#14 78.49 [4/4] Building fresh packages...
#14 80.43 error /app/node_modules/node-sass: Command failed.
#14 80.43 Exit code: 1
#14 80.43 Command: node scripts/build.js
#14 80.43 Arguments:
#14 80.43 Directory: /app/node_modules/node-sass
  🚀   ~/Desktop/Code/projects/ts_frontend_template   dockerize ±  docker build -t react-nginx-2 .
[+] Building 83.4s (12/15)
 => [internal] load build definition from Dockerfile                                                                                                                                                     0.0s
 => => transferring dockerfile: 652B                                                                                                                                                                     0.0s
 => [internal] load .dockerignore                                                                                                                                                                        0.0s
 => => transferring context: 35B                                                                                                                                                                         0.0s
 => [internal] load metadata for docker.io/library/node:15.4.0-alpine3.10                                                                                                                                0.9s
 => [internal] load metadata for docker.io/library/nginx:alpine                                                                                                                                          0.7s
 => [auth] library/node:pull token for registry-1.docker.io                                                                                                                                              0.0s
 => [auth] library/nginx:pull token for registry-1.docker.io                                                                                                                                             0.0s
 => [stage-1 1/4] FROM docker.io/library/nginx:alpine@sha256:efc93af57bd255ffbfb12c89ec0714dd1a55f16290eb26080e3d1e7e82b3ea66                                                                            0.0s
 => [builder 1/4] FROM docker.io/library/node:15.4.0-alpine3.10@sha256:f85a3927c3428dc2fa591bf229d82fd7e3e5e1082bdafd16a3f3b5f61078d963                                                                  0.0s
 => [internal] load build context                                                                                                                                                                        0.1s
 => => transferring context: 591.63kB                                                                                                                                                                    0.1s
 => CACHED [builder 2/4] WORKDIR /app                                                                                                                                                                    0.0s
 => [builder 3/4] COPY . .                                                                                                                                                                               0.1s
 => ERROR [builder 4/4] RUN yarn install && yarn build                                                                                                                                                  82.2s
------
 > [builder 4/4] RUN yarn install && yarn build:
#14 0.504 yarn install v1.22.5
#14 0.542 warning package.json: No license field
#14 0.697 warning [email protected]: No license field
#14 0.701 [1/4] Resolving packages...
#14 1.529 [2/4] Fetching packages...
#14 1.533 warning Pattern ["@apollo/client@latest"] is trying to unpack in the same destination "/usr/local/share/.cache/yarn/v6/npm-@apollo-client-3.3.6-f359646308167f38d5bc498dfc2344c888400093-integrity/n
ode_modules/@apollo/client" as pattern ["@apollo/[email protected]"]. This could result in non-deterministic behavior, skipping.
#14 1.550 warning Pattern ["object-assign@latest"] is trying to unpack in the same destination "/usr/local/share/.cache/yarn/v6/npm-object-assign-4.1.1-2109adc7965887cfc05cbbd442cac8bfbb360863-integrity/nod
e_modules/object-assign" as pattern ["object-assign@^4.1.1","object-assign@^4.0.1","object-assign@^4.1.0","object-assign@^4.1.1","object-assign@^4.1.1","object-assign@^4.1.1","object-assign@^4.1.1","object-
assign@^4.0.1","object-assign@^4.1.0","object-assign@^4.1.1","object-assign@^4.0.1","object-assign@^4"]. This could result in non-deterministic behavior, skipping.
#14 1.550 warning Pattern ["send@latest"] is trying to unpack in the same destination "/usr/local/share/.cache/yarn/v6/npm-send-0.17.1-c1d8b059f7900f7466dd4938bdc44e11ddb376c8-integrity/node_modules/send" a
s pattern ["[email protected]","[email protected]"]. This could result in non-deterministic behavior, skipping.
#14 52.36 info [email protected]: The platform "linux" is incompatible with this module.
#14 52.36 info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
#14 52.38 info [email protected]: The platform "linux" is incompatible with this module.
#14 52.38 info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
#14 52.38 info [email protected]: The platform "linux" is incompatible with this module.
#14 52.38 info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
#14 52.39 [3/4] Linking dependencies...
#14 52.40 warning " > [email protected]" has unmet peer dependency "prop-types@^15.6.0".
#14 52.40 warning " > @typescript-eslint/[email protected]" has unmet peer dependency "eslint@^5.0.0 || ^6.0.0 || ^7.0.0".
#14 52.41 warning " > @typescript-eslint/[email protected]" has unmet peer dependency "eslint@^5.0.0 || ^6.0.0 || ^7.0.0".
#14 52.41 warning " > [email protected]" has unmet peer dependency "eslint@^3 || ^4 || ^5 || ^6 || ^7".
#14 52.43 warning " > [email protected]" has unmet peer dependency "jest@>=26 <27".
#14 79.45 [4/4] Building fresh packages...
#14 81.95 error /app/node_modules/node-sass: Command failed.
#14 81.95 Exit code: 1
#14 81.95 Command: node scripts/build.js
#14 81.95 Arguments:
#14 81.95 Directory: /app/node_modules/node-sass
#14 81.95 Output:
#14 81.95 Binary found at /app/node_modules/node-sass/vendor/linux_musl-x64-88/binding.node
#14 81.95 Testing binary
#14 81.95 Binary has a problem: Error: Error relocating /app/node_modules/node-sass/vendor/linux_musl-x64-88/binding.node: _ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev: symbol not found
#14 81.95     at Object.Module._extensions..node (node:internal/modules/cjs/loader:1167:18)
#14 81.95     at Module.load (node:internal/modules/cjs/loader:973:32)
#14 81.95     at Function.Module._load (node:internal/modules/cjs/loader:813:14)
#14 81.95     at Module.require (node:internal/modules/cjs/loader:997:19)
#14 81.95     at require (node:internal/modules/cjs/helpers:92:18)
#14 81.95     at module.exports (/app/node_modules/node-sass/lib/binding.js:19:10)
#14 81.95     at Object.<anonymous> (/app/node_modules/node-sass/lib/index.js:13:35)
#14 81.95     at Module._compile (node:internal/modules/cjs/loader:1108:14)
#14 81.95     at Object.Module._extensions..js (node:internal/modules/cjs/loader:1137:10)
#14 81.95     at Module.load (node:internal/modules/cjs/loader:973:32) {
#14 81.95   code: 'ERR_DLOPEN_FAILED'
#14 81.95 }
#14 81.95 Building the binary locally
#14 81.95 Building: /usr/local/bin/node /app/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
#14 81.95 gyp info it worked if it ends with ok
#14 81.95 gyp verb cli [
#14 81.95 gyp verb cli   '/usr/local/bin/node',
#14 81.95 gyp verb cli   '/app/node_modules/node-gyp/bin/node-gyp.js',
#14 81.95 gyp verb cli   'rebuild',
#14 81.95 gyp verb cli   '--verbose',
#14 81.95 gyp verb cli   '--libsass_ext=',
#14 81.95 gyp verb cli   '--libsass_cflags=',
#14 81.95 gyp verb cli   '--libsass_ldflags=',
#14 81.95 gyp verb cli   '--libsass_library='
#14 81.95 gyp verb cli ]
#14 81.95 gyp info using [email protected]
#14 81.95 gyp info using [email protected] | linux | x64
#14 81.95 gyp verb command rebuild []
#14 81.95 gyp verb command clean []
#14 81.95 gyp verb clean removing "build" directory
#14 81.95 gyp verb command configure []
#14 81.95 gyp verb find Python Python is not set from command line or npm configuration
#14 81.95 gyp verb find Python Python is not set from environment variable PYTHON
#14 81.95 gyp verb find Python checking if "python3" can be used
#14 81.95 gyp verb find Python - executing "python3" to get executable path
#14 81.95 gyp verb find Python - "python3" is not in PATH or produced an error
#14 81.95 gyp verb find Python checking if "python" can be used
#14 81.95 gyp verb find Python - executing "python" to get executable path
#14 81.95 gyp verb find Python - "python" is not in PATH or produced an error
#14 81.95 gyp verb find Python checking if "python2" can be used
#14 81.95 gyp verb find Python - executing "python2" to get executable path
#14 81.95 gyp verb find Python - "python2" is not in PATH or produced an error
#14 81.95 gyp ERR! find Python
#14 81.95 gyp ERR! find Python Python is not set from command line or npm configuration
#14 81.95 gyp ERR! find Python Python is not set from environment variable PYTHON
#14 81.95 gyp ERR! find Python checking if "python3" can be used
#14 81.95 gyp ERR! find Python - "python3" is not in PATH or produced an error
#14 81.95 gyp ERR! find Python checking if "python" can be used
#14 81.95 gyp ERR! find Python - "python" is not in PATH or produced an error
#14 81.95 gyp ERR! find Python checking if "python2" can be used
#14 81.95 gyp ERR! find Python - "python2" is not in PATH or produced an error
#14 81.95 gyp ERR! find Python
#14 81.95 gyp ERR! find Python **********************************************************
#14 81.95 gyp ERR! find Python You need to install the latest version of Python.
#14 81.95 gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
#14 81.95 gyp ERR! find Python you can try one of the following options:
#14 81.95 gyp ERR! find Python - Use the switch --python="/path/to/pythonexecutable"
#14 81.95 gyp ERR! find Python   (accepted by both node-gyp and npm)
#14 81.95 gyp ERR! find Python - Set the environment variable PYTHON
#14 81.95 gyp ERR! find Python - Set the npm configuration variable python:
#14 81.95 gyp ERR! find Python   npm config set python "/path/to/pythonexecutable"
#14 81.95 gyp ERR! find Python For more information consult the documentation at:
#14 81.95 gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
#14 81.95 gyp ERR! find Python **********************************************************
#14 81.95 gyp ERR! find Python
#14 81.95 gyp ERR! configure error
#14 81.95 gyp ERR! stack Error: Could not find any Python installation to use
#14 81.95 gyp ERR! stack     at PythonFinder.fail (/app/node_modules/node-gyp/lib/find-python.js:302:47)
#14 81.95 gyp ERR! stack     at PythonFinder.runChecks (/app/node_modules/node-gyp/lib/find-python.js:136:21)
#14 81.95 gyp ERR! stack     at PythonFinder.<anonymous> (/app/node_modules/node-gyp/lib/find-python.js:179:16)
#14 81.95 gyp ERR! stack     at PythonFinder.execFileCallback (/app/node_modules/node-gyp/lib/find-python.js:266:16)
#14 81.95 gyp ERR! stack     at exithandler (node:child_process:340:5)
#14 81.95 gyp ERR! stack     at ChildProcess.errorhandler (node:child_process:352:5)
#14 81.95 gyp ERR! stack     at ChildProcess.emit (node:events:376:20)
#14 81.95 gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:282:12)
#14 81.95 gyp ERR! stack     at onErrorNT (node:internal/child_process:476:16)
#14 81.95 gyp ERR! stack     at processTicksAndRejections (node:internal/process/task_queues:80:21)
#14 81.95 gyp ERR! System Linux 4.19.121-linuxkit
#14 81.95 gyp ERR! command "/usr/local/bin/node" "/app/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
#14 81.95 gyp ERR! cwd /app/node_modules/node-sass
#14 81.95 gyp ERR! node -v v15.4.0
#14 81.95 gyp ERR! node-gyp -v v7.1.2
#14 81.95 gyp ERR! not ok
#14 81.95 Build failed with error code: 1
#14 81.95 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

@saper
Copy link
Member

saper commented Dec 21, 2020

@KingOfCramers We don't know what the bug really is, sorry. Most certainly not in the node-sass JavaScript or even C++ code.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests