Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Find a solution to declare peer dependencies #130

Closed
dylang opened this issue Mar 27, 2016 · 5 comments
Closed

Find a solution to declare peer dependencies #130

dylang opened this issue Mar 27, 2016 · 5 comments

Comments

@dylang
Copy link
Contributor

dylang commented Mar 27, 2016

npm@2 is installing the peer dependencies which is an unexpected behavior, as they are optional for depcheck, and this means when using npm@2, they are always installed.

npm@3 won't install them, but gives unexpected warnings:

├── UNMET PEER DEPENDENCY node-sass@^3.4.0
└── UNMET PEER DEPENDENCY typescript@^1.8.0

npm WARN depcheck@0.6.2 requires a peer of node-sass@^3.4.0 but none was installed.
npm WARN depcheck@0.6.2 requires a peer of typescript@^1.8.0 but none was installed.

I feel like the feature of using the dependencies when they are available is great, but instead of including them as peer dependencies, just include instructions in the docs what users need to do.

@lijunle
Copy link
Member

lijunle commented Mar 28, 2016

I follow the pattern from eslint-config-airbnb. They mark react as peer dependency. There is some discussions to remove the peer dependency or split the package into three sub-packages.

In my option, those UMET warnings are fine because they are warnings not errors. I could like to keep this open and wait for a better idea/solution.

@lijunle lijunle added this to the backlog milestone Mar 28, 2016
@lijunle
Copy link
Member

lijunle commented Mar 31, 2016

Because the peer dependencies is blocking npm shrinkwrap (dylang/npm-check#108) caused by NPM bug (npm/npm#10836), I decide to remove the peer dependencies from package.json and only keep them in README (#133).

However, let us keep this open and find a better solution to resolve these optional peer dependencies.

@lijunle lijunle changed the title Remove peer dependencies Find a solution to declare peer dependencies Apr 1, 2016
@lijunle lijunle removed this from the backlog milestone Nov 29, 2016
@CatzillaOrz
Copy link

try to use nvm ls-remote find a stable node version then use nvm use

@rumpl
Copy link
Member

rumpl commented May 12, 2019

Is this still an issue?

I'm not even sure I understand what's going on to be honest.

@rumpl rumpl closed this as completed Jun 26, 2019
@nnfans
Copy link

nnfans commented Jul 28, 2022

node-sass is deprecated and it makes the npm install throw an error
can we remove it or update to 7.0.1 so it does't throw an error

npm ERR! code 1
npm ERR! path /Users/ajaib/repo/depcheck/node_modules/node-sass
npm ERR! command failed
npm ERR! command sh -c node scripts/build.js
npm ERR! Building: /Users/ajaib/.nvm/versions/node/v16.14.2/bin/node /Users/ajaib/repo/depcheck/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
npm ERR!   c++ -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp '-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_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/include/node -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/src -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/openssl/config -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/openssl/openssl/include -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/uv/include -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/zlib -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/v8/include -I../src/libsass/include  -O3 -gdwarf-2 -mmacosx-version-min=10.7 -arch arm64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=c++11 -stdlib=libc++ -fno-strict-aliasing -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw   -c
npm ERR!   c++ -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp '-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_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/include/node -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/src -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/openssl/config -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/openssl/openssl/include -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/uv/include -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/zlib -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/v8/include -I../src/libsass/include  -O3 -gdwarf-2 -mmacosx-version-min=10.7 -arch arm64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=c++11 -stdlib=libc++ -fno-strict-aliasing -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw   -c
npm ERR!   c++ -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp '-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_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/include/node -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/src -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/openssl/config -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/openssl/openssl/include -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/uv/include -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/zlib -I/Users/ajaib/Library/Caches/node-gyp/16.14.2/deps/v8/include -I../src/libsass/include  -O3 -gdwarf-2 -mmacosx-version-min=10.7 -arch arm64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=c++11 -stdlib=libc++ -fno-strict-aliasing -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw   -c

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

No branches or pull requests

5 participants