Home > front end >  Updating my website on heroku is not working
Updating my website on heroku is not working

Time:02-25

I wanted to make changes to my React.JS website hosted on heroku, I followed the following steps to edit my website:

  1. run git clone "my wesbite git repository link" on terminal
  2. then run heroku login
  3. cd my-cloned-website
  4. made my changes
  5. run git add .
  6. run git commit -m "make it better"
  7. and lastly run git push origin main

I have worked on it before, but never got this error, but I have tried to make changes to package.json, I have tried to install latest versions of node,

then I kept getting the following error:

and after editing, I wanted to push my changes to main branch.

-----> Building on the Heroku-20 stack
-----> Using buildpack: heroku/nodejs
-----> Node.js app detected
       
-----> Creating runtime environment
       
       NPM_CONFIG_LOGLEVEL=error
       NODE_VERBOSE=false
       NODE_ENV=production
       NODE_MODULES_CACHE=true
       
-----> Installing binaries
       engines.node (package.json):  unspecified
       engines.npm (package.json):   unspecified (use default)
       
       Resolving node version 16.x...
       Downloading and installing node 16.14.0...
       Using default npm version: 8.3.1
       
-----> Restoring cache
       Cached directories were not restored due to a change in version of node, npm, yarn or stack
       Module installation may take longer for this build
       
-----> Installing dependencies
       Installing node modules
       npm ERR! code 1
       npm ERR! path /tmp/build_5229914f/node_modules/node-sass
       npm ERR! command failed
       npm ERR! command sh -c node scripts/build.js
       npm ERR! Building: /tmp/build_5229914f/.heroku/node/bin/node /tmp/build_5229914f/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
       npm ERR! make: Entering directory '/tmp/build_5229914f/node_modules/node-sass/build'
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/check_nesting.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/check_nesting.o ../src/libsass/src/check_nesting.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/color_maps.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/color_maps.o ../src/libsass/src/color_maps.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/eval.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/eval.o ../src/libsass/src/eval.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/sass.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/sass.o ../src/libsass/src/sass.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/sass2scss.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/sass2scss.o ../src/libsass/src/sass2scss.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/sass_context.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/sass_context.o ../src/libsass/src/sass_context.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/sass_functions.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/sass_functions.o ../src/libsass/src/sass_functions.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/sass_util.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/sass_util.o ../src/libsass/src/sass_util.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/sass_values.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/sass_values.o ../src/libsass/src/sass_values.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/source_map.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/source_map.o ../src/libsass/src/source_map.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/subset_map.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/subset_map.o ../src/libsass/src/subset_map.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/to_c.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/to_c.o ../src/libsass/src/to_c.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/to_value.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/to_value.o ../src/libsass/src/to_value.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/units.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/units.o ../src/libsass/src/units.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/utf8_string.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/utf8_string.o ../src/libsass/src/utf8_string.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/util.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/util.o ../src/libsass/src/util.cpp
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu  14 -std=c  0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/values.o.d.raw   -c -o Release/obj.target/libsass/src/libsass/src/values.o ../src/libsass/src/values.cpp
       npm ERR!   rm -f Release/obj.target/src/sass.a && ar crs Release/obj.target/src/sass.a Release/obj.target/libsass/src/libsass/src/ast.o 
       npm ERR!   rm -rf "Release/sass.a" && cp -af "Release/obj.target/src/sass.a" "Release/sass.a"
       npm ERR!   g   '-DNODE_GYP_MODULE_NAME=binding' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DBUILDING_NODE_EXTENSION' -I/app/.node-gyp/16.14.0/include/node -I/app/.node-gyp/16.14.0/src -I/app/.node-gyp/16.14.0/deps/openssl/config -I/app/.node-gyp/16.14.0/deps/openssl/openssl/include -I/app/.node-gyp/16.14.0/deps/uv/include -I/app/.node-gyp/16.14.0/deps/zlib -I/app/.node-gyp/16.14.0/deps/v8/include -I../../nan -I../src/libsass/include  -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -fno-rtti -fno-exceptions -std=gnu  14 -std=c  0x -MMD -MF ./Release/.deps/Release/obj.target/binding/src/binding.o.d.raw   -c -o Release/obj.target/binding/src/binding.o ../src/binding.cpp
       npm ERR! make: Leaving directory '/tmp/build_5229914f/node_modules/node-sass/build'
       npm ERR! gyp info it worked if it ends with ok
       npm ERR! gyp verb cli [
       npm ERR! gyp verb cli   '/tmp/build_5229914f/.heroku/node/bin/node',
       npm ERR! gyp verb cli   '/tmp/build_5229914f/node_modules/node-gyp/bin/node-gyp.js',
       npm ERR! gyp verb cli   'rebuild',
       npm ERR! gyp verb cli   '--verbose',
       npm ERR! gyp verb cli   '--libsass_ext=',
       npm ERR! gyp verb cli   '--libsass_cflags=',
       npm ERR! gyp verb cli   '--libsass_ldflags=',
       npm ERR! gyp verb cli   '--libsass_library='
       npm ERR! gyp verb cli ]
       npm ERR! gyp info using [email protected]
       npm ERR! gyp info using [email protected] | linux | x64
       npm ERR! gyp verb command rebuild []
       npm ERR! gyp verb command clean []
       npm ERR! gyp verb clean removing "build" directory
       npm ERR! gyp verb command configure []
       npm ERR! gyp verb check python checking for Python executable "python2" in the PATH
       npm ERR! gyp verb `which` succeeded python2 /usr/bin/python2
       npm ERR! gyp verb check python version `/usr/bin/python2 -c "import sys; print "2.7.18
       npm ERR! gyp verb check python version .%s.%s" % sys.version_info[:3];"` returned: %j
       npm ERR! gyp verb get node dir no --target version specified, falling back to host node version: 16.14.0
       npm ERR! gyp verb command install [ '16.14.0' ]
       npm ERR! gyp verb install input version string "16.14.0"
       npm ERR! gyp verb install installing version: 16.14.0
       npm ERR! gyp verb install --ensure was passed, so won't reinstall if already installed
       npm ERR! gyp verb install version not already installed, continuing with install 16.14.0
       npm ERR! gyp verb ensuring nodedir is created /app/.node-gyp/16.14.0
       npm ERR! gyp verb created nodedir /app/.node-gyp
       npm ERR! gyp http GET https://nodejs.org/download/release/v16.14.0/node-v16.14.0-headers.tar.gz
    
       npm ERR! gyp verb extracted file from tarball include/node/openssl/archs/BSD-x86/asm/crypto/include/internal/dso_conf.h
       npm ERR! gyp verb extracted file from tarball include/node/openssl/archs/BSD-x86/asm/crypto/buildinf.h
-----> Build failed
       
       We're sorry this build is failing! You can troubleshoot common issues here:
       https://devcenter.heroku.com/articles/troubleshooting-node-deploys
       
       Some possible problems:
       
       - Node version not specified in package.json
         https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version
       
       Love,
       Heroku
       
 !     Push rejected, failed to compile Node.js app.
 !     Push failed

What can I do to fix this? Anyhelp would be appreciated. Thank you for your time, in advance.

CodePudding user response:

Node Sass has some very specific version requirements. You need to make sure your version of Node.js and your version of Node Sass are compatible.

But you aren't telling Heroku which version of Node.js you want to use so it is defaulting to Node.js 16:

-----> Installing binaries
       engines.node (package.json):  unspecified
       engines.npm (package.json):   unspecified (use default)
       
       Resolving node version 16.x...
       Downloading and installing node 16.14.0...
       Using default npm version: 8.3.1

This is different from the version you were using before, and likely different from what you are using locally:

-----> Restoring cache
       Cached directories were not restored due to a change in version of node, npm, yarn or stack

It is always a good idea to specify the version of Node.js you are using in your package.json.

You have two options:

  1. Specify whatever version you were using before and / or are using locally since that should be compatible with the version of Node Sass you have.

    I'm going to guess that's version 14.x:

    {
      "name": "your-app",
      "version": "1.0.0",
      "engines": {
        "node": "14.x"
      }
    }
    

    Note that Heroku only supports a few versions of Node.js at any given time and version 14.x is currently the oldest supported version. It will be deprecated at some point.

  2. Upgrade your local environment to Node.js 16 or 17, then upgrade the version of Node Sass you are using to a compatible version (looks like version 6.0 for Node 16 and version 7.0 for Node 17).

    In this case you'll want to specify version 16.x or 17.x in your package.json.

Heroku's error message makes the same suggestion at the bottom, though with a lot less detail:

Some possible problems:
       
- Node version not specified in package.json
  https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version

Finally, I'll note that Node Sass is not under active development:

Warning: LibSass and Node Sass are deprecated. While they will continue to receive maintenance releases indefinitely, there are no plans to add additional features or compatibility with any new CSS or Sass features. Projects that still use it should move onto Dart Sass.

  • Related