Yarn: Yarn μΆ”κ°€/Yarn μ„€μΉ˜λŠ” fseventλ₯Ό μ„€μΉ˜ν•  수 μ—†μŠ΅λ‹ˆλ‹€.

에 λ§Œλ“  2017λ…„ 07μ›” 13일  Β·  29μ½”λ©˜νŠΈ  Β·  좜처: yarnpkg/yarn

κΈ°λŠ₯ 을 μš”μ²­ν•˜κ±°λ‚˜ 버그λ₯Ό 보고 ν•˜μ‹œκ² μŠ΅λ‹ˆκΉŒ?
벌레

ν˜„μž¬ 행동은 λ¬΄μ—‡μž…λ‹ˆκΉŒ?

힘:

yarn add jest λ₯Ό μ‹€ν–‰ν•˜λ €κ³  ν•˜λ©΄ λ‹€μŒ 였λ₯˜κ°€ λ°œμƒν•©λ‹ˆλ‹€.

β‡’  yarn add jest
yarn add v0.27.5
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/1] β’€ fsevents: 404 status code downloading tarball https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
[-/1] β’€ waiting...
[-/1] β’€ waiting...
[-/1] β’€ waiting...
warning Error running install script for optional dependency: "/Users/Ystartsev/Work/temp/debugger.html/node_modules/fsevents: Command failed.\nExit code: 1\nCommand: sh\nArguments: -c node install\nDirectory: /Users/Ystartsev/Work/temp/debugger.html/node_modules/fsevents\nOutput:\nnode-pre-gyp info it worked if it ends with ok\nnode-pre-gyp info using [email protected]\nnode-pre-gyp info using [email protected] | darwin | x64\nnode-pre-gyp info check checked for \"/Users/Ystartsev/Work/temp/debugger.html/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64/fse.node\" (not found)\nnode-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz\nnode-pre-gyp http 404 https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz\nnode-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz \nnode-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v57 ABI) (falling back to source compile with node-gyp) \nnode-pre-gyp http 404 status code downloading tarball https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz \nnode-pre-gyp ERR! build error \nnode-pre-gyp ERR! stack Error: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)\nnode-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/Users/Ystartsev/Work/temp/debugger.html/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/compile.js:77:29)\nnode-pre-gyp ERR! stack     at emitOne (events.js:115:13)\nnode-pre-gyp ERR! stack     at ChildProcess.emit (events.js:210:7)\nnode-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:195:12)\nnode-pre-gyp ERR! stack     at onErrorNT (internal/child_process.js:366:16)\nnode-pre-gyp ERR! stack     at _combinedTickCallback (internal/process/next_tick.js:102:11)\nnode-pre-gyp ERR! stack     at process._tickCallback (internasuccess Saved lockfile.
success Saved 1 new dependency.
└─ [email protected]
Done in 12.29s.

그런 λ‹€μŒ yarn ν…ŒμŠ€νŠΈ(jest의 별칭)λ₯Ό μ‹€ν–‰ν•˜λ©΄ λ‹€μŒ 였λ₯˜κ°€ λ°œμƒν•©λ‹ˆλ‹€.

yarn test v0.27.5
$ jest
TypeError: projects.map is not a function
    at Object.<anonymous> (/Users/Ystartsev/Work/temp/debugger.html/node_modules/jest-cli/build/cli/runCLI.js:112:28)
    at Generator.next (<anonymous>)
    at step (/Users/Ystartsev/Work/temp/debugger.html/node_modules/jest-cli/build/cli/runCLI.js:1:260)
    at /Users/Ystartsev/Work/temp/debugger.html/node_modules/jest-cli/build/cli/runCLI.js:1:490
    at Promise (<anonymous>)
    at Object.<anonymous> (/Users/Ystartsev/Work/temp/debugger.html/node_modules/jest-cli/build/cli/runCLI.js:1:171)
    at Object.module.exports [as runCLI] (/Users/Ystartsev/Work/temp/debugger.html/node_modules/jest-cli/build/cli/runCLI.js:139:50)
    at Object.run (/Users/Ystartsev/Work/temp/debugger.html/node_modules/devtools-source-map/node_modules/jest-cli/build/cli/index.js:42:17)
    at Object.<anonymous> (/Users/Ystartsev/Work/temp/debugger.html/node_modules/devtools-source-map/node_modules/jest-cli/bin/jest.js:16:25)
    at Module._compile (module.js:569:30)
error Command failed with exit code 1.

이것은 https://github.com/devtools-html/debugger.htmlμ—μ„œ μΌμ–΄λ‚˜κ³  μžˆμŠ΅λ‹ˆλ‹€.

μ˜ˆμƒλ˜λŠ” λ™μž‘μ€ λ¬΄μ—‡μž…λ‹ˆκΉŒ?
농담보닀 μ„€μΉ˜ν•˜κ³  μ‹€ν–‰ν•©λ‹ˆλ‹€.

node.js, 원사 및 운영 체제 버전을 μ–ΈκΈ‰ν•˜μ‹­μ‹œμ˜€.

mac OS Sierra
node version: 8.1.5 (tried on other versions, same issue)
yarn version: 0.27.5
needs-repro-script

κ°€μž₯ μœ μš©ν•œ λŒ“κΈ€

μ—¬λŸ¬ μ œμ•ˆλœ μ†”λ£¨μ…˜μ„ μ‘°ν•©ν•΄μ•Ό ν–ˆμŠ΅λ‹ˆλ‹€.

yarn cache clean && yarn upgrade && yarn

그게 νŠΈλ¦­μ„ ν–ˆλ‹€. Expo ν”„λ‘œμ νŠΈμ— 쒅속성을 μ„€μΉ˜ν•˜κΈ° μœ„ν•΄ expo install expo-notifications λ₯Ό μ‹€ν–‰ν•˜λ €κ³  ν–ˆμŠ΅λ‹ˆλ‹€. λ‚˜λŠ” 이미 μ‚­μ œν–ˆλ‹€ node_modules μ‹€ν–‰ yarn install , κ·ΈλŸ¬λ‚˜ μ–΄λ–€ 이유둜 μ—¬μ „νžˆ λ¬Έμ œκ°€ μžˆμ—ˆλ‹€. μΊμ‹œκ°€ 범인인 것 κ°™μŠ΅λ‹ˆλ‹€.

λͺ¨λ“  29 λŒ“κΈ€

이것은 원사 λ¬Έμ œκ°€ μ•„λ‹ˆλΌ fsevent의 이전 버전에 λ”°λ₯Έ ν•˜μœ„ 쒅속성 λ¬Έμ œμž…λ‹ˆλ‹€.

node.js 8용으둜 미리 컴파일된 λ°”μ΄λ„ˆλ¦¬κ°€ μžˆλŠ” 첫 번째 버전인 v1.1.2둜 μ—…κ·Έλ ˆμ΄λ“œν•˜μ„Έμš”.
https://github.com/strongloop/fsevents/issues/181

감사 ν•΄μš”!

흠, ν•˜μ§€λ§Œ 이것은 이전 λ²„μ „μ˜ 원사와 npmμ—μ„œ μž‘λ™ν•©λ‹ˆλ‹€.

ν•œ 가지 더 μ°Έκ³ : 이것은 yarn 0.24.xμ—μ„œ μž‘λ™ν•©λ‹ˆλ‹€.

μ—¬κΈ°μ—μ„œ μž¬ν˜„ν•  수 μ—†μŠ΅λ‹ˆλ‹€. yarn add [email protected] λŠ” 0.28.1 / λ…Έλ“œ 8.1.3μ—μ„œ 잘 μž‘λ™ν•©λ‹ˆλ‹€.

원사 0.27.5와 λ…Έλ“œ 8.1.4κ°€ μžˆμŠ΅λ‹ˆλ‹€(μ΅œμ‹  버전 λͺ¨λ‘ brew μ—μ„œ μ„€μΉ˜ν•  수 있음). λ˜ν•œ λ‹€μŒμ„ μ‹œλ„ν•  λ•Œ 404λ₯Ό μ–»μŠ΅λ‹ˆλ‹€.

yarn add [email protected]

Mac OS Sierra 10.12.5μ—μ„œ μ‹€ν–‰

저도 λ°˜μ„±ν•˜λŠ”λ° μ‹€νŒ¨ν–ˆμŠ΅λ‹ˆλ‹€. λ…Έλ“œ 6κ³Ό λ…Έλ“œ 8 λͺ¨λ‘μ—μ„œ 빈 μΊμ‹œλ‘œ μ‹œλ„ν–ˆμŠ΅λ‹ˆλ‹€.

@hequ @codehag μ‚¬μš© κ°€λŠ₯ν•œ μ΅œμ‹  μ›μ‚¬λ‘œ μ‹œλ„ν•΄ λ³Ό 수 μžˆμŠ΅λ‹ˆκΉŒ?

yarn init 둜 μƒˆλ‘œμš΄ 빈 원사 ν”„λ‘œμ νŠΈλ₯Ό λ§Œλ“€κ³  yarn cache clean μΊμ‹œλ₯Ό μ§€μš΄ λ‹€μŒ yarn add [email protected] μ„€μΉ˜λ₯Ό μ‹œλ„ν–ˆμŠ΅λ‹ˆλ‹€. 이듀은 λ…Έλ“œ 8.1.4 및 μ–€ 0.27.5μ—μ„œ μ‹€ν–‰λ˜μ—ˆμŠ΅λ‹ˆλ‹€.

λ‚˜λŠ” 이것을 원사 0.28.1둜 μ‹œλ„ν–ˆκ³  λ˜‘κ°™μ€ 였λ₯˜κ°€ λ°œμƒν–ˆμŠ΅λ‹ˆλ‹€.

hequ @ MacBook-Pro ~/Projects/omat/yarn
└─ $ β–Ά yarn add [email protected]
yarn add v0.28.1
info No lockfile found.
[1/4] πŸ”  Resolving packages...
[2/4] 🚚  Fetching packages...
[3/4] πŸ”—  Linking dependencies...
[4/4] πŸ“ƒ  Building fresh packages...
[1/1] β ‚ fsevents: GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
[-/1] β ‚ waiting...
[-/1] β ‚ waiting...
[-/1] β ‚ waiting...
error /Users/hequ/Projects/omat/yarn/node_modules/fsevents: Command failed.
Exit code: 1
Command: sh
Arguments: -c node install
Directory: /Users/hequ/Projects/omat/yarn/node_modules/fsevents
Output:
node-pre-gyp info it worked if it ends with ok
node-pre-gyp info using [email protected]
node-pre-gyp info using [email protected] | darwin | x64
node-pre-gyp info check checked for "/Users/hequ/Projects/omat/yarn/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64/fse.node" (not found)
node-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
node-pre-gyp http 404 https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
node-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v57 ABI) (falling back to source compile with node-gyp)
node-pre-gyp http 404 status code downloading tarball https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/Users/hequ/Projects/omat/yarn/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/compile.js:77:29)
node-pre-gyp ERR! stack     at emitOne (events.js:115:13)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:210:7)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:195:12)
node-pre-gyp ERR! stack     at onErrorNT (internal/child_process.js:366:16)
node-pre-gyp ERR! stack     at _combinedTickCallback (internal/process/next_tick.js:102:11)
node-pre-gyp ERR! stack     at process._tickCallback (internal/process/next_tick.js:161:9)
node-pre-gyp ERR! System Darwin 16.6.0
node-pre-gyp ERR! command "/usr/local/Cellar/node/8.1.4/bin/node" "/Users/hequ/Projects/omat/yarn/node_modules/fsevents/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /Users/hequ/Projects/omat/yarn/node_modules/fsevents
node-pre-gyp ERR! node -v v8.1.4
node-pre-gyp ERR! node-pre-gyp -v v0.6.33
node-pre-gyp ERR! not ok
Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

tarball이 μ—†λŠ” 것 κ°™μŠ΅λ‹ˆλ‹€.

hequ @ MacBook-Pro ~/Projects/omat/yarn
└─ $ β–Ά wget https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
--2017-07-18 13:21:30--  https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz
Resolving fsevents-binaries.s3-us-west-2.amazonaws.com... 52.218.192.81
Connecting to fsevents-binaries.s3-us-west-2.amazonaws.com|52.218.192.81|:443... connected.
HTTP request sent, awaiting response... 404 Not Found
2017-07-18 13:21:31 ERROR 404: Not Found.

예, 파일이 μ‘΄μž¬ν•˜μ§€ μ•ŠλŠ” 것 κ°™μŠ΅λ‹ˆλ‹€. 이것이 Yarn의 였λ₯˜μΈμ§€ fsevent의 였λ₯˜μΈμ§€ node-gyp의 였λ₯˜μΈμ§€ ν™•μ‹€ν•˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€.

μ•„, 그래. fsevents github νŽ˜μ΄μ§€μ—μ„œ ν•΄λ‹Ή 문제λ₯Ό μ°Ύμ•˜μŠ΅λ‹ˆλ‹€. λ”°λΌμ„œ 1.1.1 미리 컴파일된 버전은 s3에 μ—†μ§€λ§Œ 1.1.2μ—λŠ” μžˆμŠ΅λ‹ˆλ‹€.

https://github.com/strongloop/fsevents/issues/181

yarn add [email protected] μ‹œλ„ν•˜λ©΄ μ˜ˆμƒλŒ€λ‘œ μž‘λ™ν•©λ‹ˆλ‹€.

@hequλ‹˜, κ°μ‚¬ν•©λ‹ˆλ‹€. 그런 λ‹€μŒ 문제λ₯Ό λ‹«μŠ΅λ‹ˆλ‹€. λ‹€μ‹œ μ—΄μ–΄μ•Ό ν•œλ‹€λ©΄ LMK.

μ•ˆλ…•, λ‚˜λŠ” 이것이 λ‹«ν˜€μ„œλŠ” μ•ˆλœλ‹€κ³  μƒκ°ν•œλ‹€.

λ‹€λ₯Έ λ²„μ „μ˜ μ›μ‚¬μ—μ„œ μž‘λ™ν•˜λŠ” 것
yarn add jest

원사 0.27.5μ—μ„œ μž‘λ™ν•˜μ§€ μ•ŠλŠ” 것
yarn add jest

이것이 자주 μ‚¬μš©λ˜λŠ” λΌμ΄λΈŒλŸ¬λ¦¬λΌλŠ” 점을 κ°μ•ˆν•  λ•Œ 여기에 λ­”κ°€κ°€ μžˆλ‹€κ³  μƒκ°ν•©λ‹ˆλ‹€.

fseventsλŠ” νŠΉμ • 버전(예: 1.1.2)을 μ‚¬μš©ν•˜λŠ” 경우 μ˜¬λ°”λ₯΄κ²Œ μ„€μΉ˜ν•  수 μžˆμ§€λ§Œ μ΄μ „μ—λŠ” μž‘λ™ν–ˆμ§€λ§Œ μž‘λ™μ„ μ€‘μ§€ν•˜λ„λ‘ yarnμ—μ„œ 무언가가 λ³€κ²½λ˜μ—ˆμŠ΅λ‹ˆλ‹€.

λ˜ν•œ μœ„μ—μ„œ μ–ΈκΈ‰ν•œ 바와 같이 yarn add [email protected] λŠ” yarn 0.28 및 0.24μ—μ„œ μž‘λ™ν•˜λ―€λ‘œ 무언가가 μž‘λ™ν•˜λ„λ‘ μˆ˜μ •/μ‚¬μš©λ˜μ—ˆμ§€λ§Œ ν˜„μž¬ brewμ—μ„œ μ‚¬μš©ν•  수 μžˆλŠ” 것은 μ˜ˆμƒλŒ€λ‘œ μ„€μΉ˜λ˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€.

@codehag 적어도 λ‚΄ μ»΄ν“¨ν„°μ—μ„œλŠ” yarn 0.27.4μ—μ„œλ„ 404 였λ₯˜κ°€ λ°œμƒν•˜λ―€λ‘œ [email protected] λ₯Ό μ„€μΉ˜ν•΄λ„ 0.27.4 λ˜λŠ” 0.27.5μ—μ„œ μž‘λ™ν•˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€.

@codehag 이것은 fsevents 문제처럼 λ³΄μž…λ‹ˆλ‹€. 이λ₯Ό μ™„ν™”ν•˜κΈ° μœ„ν•΄ Yarn μΈ‘μ—μ„œ κΈ°λŒ€ν•˜λŠ” λ°”λŠ” λ¬΄μ—‡μž…λ‹ˆκΉŒ?

흠 μ•„λ‹ˆμ˜€, μ›μ‚¬μ˜ ν•œ λ²„μ „μ—μ„œ λ‹€μŒ λ²„μ „μœΌλ‘œ 일이 μ œλŒ€λ‘œ μž‘λ™ν•  κ²ƒμœΌλ‘œ κΈ°λŒ€ν•©λ‹ˆλ‹€./

방금 0.24둜 λ‹€μ‹œ μ‹œλ„ν–ˆμŠ΅λ‹ˆλ‹€. μ•„λ§ˆλ„ 당신이 μ˜³μ•˜κ³  더 이상 μž‘λ™ν•˜μ§€ μ•ŠκΈ° λ•Œλ¬Έμ— 무언가가 λ³€κ²½λ˜μ—ˆμ„ κ²ƒμž…λ‹ˆλ‹€. λΆˆν–‰νžˆλ„ 더 이상 쑰사할 μ‹œκ°„μ΄ μ—†μŠ΅λ‹ˆλ‹€. μ‹œκ°„ λ‚΄ μ€˜μ„œ κ³ λ§ˆμ›Œ.

흠 μ•„λ‹ˆμ˜€, μ›μ‚¬μ˜ ν•œ λ²„μ „μ—μ„œ λ‹€μŒ λ²„μ „μœΌλ‘œ 일이 μ œλŒ€λ‘œ μž‘λ™ν•  κ²ƒμœΌλ‘œ κΈ°λŒ€ν•©λ‹ˆλ‹€./

그것이 우리의 κΈ°λŒ€μ΄μž λͺ©ν‘œμ΄κΈ°λ„ ν•©λ‹ˆλ‹€! πŸ˜€

방금 0.24둜 λ‹€μ‹œ μ‹œλ„ν–ˆμŠ΅λ‹ˆλ‹€. μ•„λ§ˆλ„ 당신이 μ˜³μ•˜κ³  더 이상 μž‘λ™ν•˜μ§€ μ•ŠκΈ° λ•Œλ¬Έμ— 무언가가 λ³€κ²½λ˜μ—ˆμ„ κ²ƒμž…λ‹ˆλ‹€. λΆˆν–‰νžˆλ„ 더 이상 쑰사할 μ‹œκ°„μ΄ μ—†μŠ΅λ‹ˆλ‹€. μ‹œκ°„ λ‚΄ μ€˜μ„œ κ³ λ§ˆμ›Œ.

yarn 와 fsevents κ°€ μ„œλ‘œ κ°€κΉκ²Œ μƒˆ 버전을 μΆœμ‹œν–ˆκΈ° λ•Œλ¬Έμ— fsevents ' λΆ€λΆ„μ˜ 였λ₯˜λ₯Ό Yarn의 νƒ“μœΌλ‘œ λŒλ¦¬λŠ” 것은 이해할 λ§Œν•©λ‹ˆλ‹€. hequ의 μ˜κ²¬μ„ 읽고 [email protected] ν•˜λ©΄ λ¬Έμ œκ°€ ν•΄κ²°λ˜λŠ”μ§€ ν™•μΈν•˜μ‹­μ‹œμ˜€.

이것이 Yarn 문제인 μ΄μœ μ— λŒ€ν•΄ 이야기할 것이라고 μƒκ°ν–ˆμŠ΅λ‹ˆλ‹€. yarn add [email protected] λŠ” μ—¬μ „νžˆ S3μ—μ„œ 1.1.1 버전을 λ‹€μš΄λ‘œλ“œν•˜λ €κ³  μ‹œλ„ν•˜λŠ” 것 κ°™μŠ΅λ‹ˆλ‹€. yarn cache clean λ‘œλŠ” λ¬Έμ œκ°€ ν•΄κ²°λ˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€.

λ‹€μŒμ€ 좜λ ₯ μ˜ˆμž…λ‹ˆλ‹€.

[18:22:17] Miles:build-tool-config > yarn add [email protected]
yarn add v0.27.5
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/1] β ‚ fsevents: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)
[-/1] β ‚ waiting...
[-/1] β ‚ waiting...
[-/1] β ‚ waiting...
warning Error running install script for optional dependency: "/Users/Miles/Sites/build-tool-config/node_modules/rollup-watch/node_modules/fsevents: Command failed.\nExit code: 1\nCommand: sh\nArguments: -c node install\nDirectory: /Users/Miles/Sites/build-tool-config/node_modules/rollup-watch/node_modules/fsevents\nOutput:\nnode-pre-gyp info it worked if it ends with ok\nnode-pre-gyp info using [email protected]\nnode-pre-gyp info using [email protected] | darwin | x64\nnode-pre-gyp info check checked for \"/Users/Miles/Sites/build-tool-config/node_modules/rollup-watch/node_modules/fsevents/lib/binding/Release/node-v57-darwin-x64/fse.node\" (not found)\nnode-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz\nnode-pre-gyp http 404 https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz\nnode-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz \nnode-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v57 ABI) (falling back to source compile with node-gyp) \nnode-pre-gyp http 404 status code downloading tarball https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v57-darwin-x64.tar.gz \nnode-pre-gyp ERR! build error \nnode-pre-gyp ERR! stack Error: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)\nnode-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/Users/Miles/Sites/build-tool-config/node_modules/rollup-watch/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/compile.js:77:29)\nnode-pre-gyp ERR! stack     at emitOne (events.js:115:13)\nnode-pre-gyp ERR! stack     at ChildProcess.emit (events.js:210:7)\nnode-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)\nnode-pre-gyp ERR! stack     at onErrorNT (internal/child_process.js:374:16)\nnode-pre-gyp ERR! stack     at _combinedTickCallback (internal/process/next_tick.js:138:11)\nnode-pre-gyp ERR! stack     at process._tickCallback (internal/process/next_tick.js:180:9)\nnode-pre-gyp ERR! System Darwin 16.6.0\nnode-pre-gyp ERR! command \"/usr/local/Cellar/node/8.2.1/bin/node\" \"/Users/Miles/Sites/build-tool-config/node_modules/rollup-watch/node_modules/fsevents/node_modules/.bin/node-pre-gyp\" \"install\" \"--fallback-to-build\"\nnode-pre-gypsuccess Saved 0 new dependencies.
Done in 11.31s.

yarn list μ‹€ν–‰ν•˜λ©΄ fsevents κ°€ 두 번 λ‚˜μ—΄λ˜κ³  κ³ μ • 버전이 μš°μ„ ν•˜λŠ” κ²ƒμ²˜λŸΌ λ³΄μž…λ‹ˆλ‹€.

β”œβ”€ [email protected]
β”‚  β”œβ”€ anymatch@^1.3.0
β”‚  β”œβ”€ async-each@^1.0.0
β”‚  β”œβ”€ fsevents@^1.0.0
β”‚  β”œβ”€ [email protected]
β”‚  β”‚  β”œβ”€ nan@^2.3.0
β”‚  β”‚  └─ node-pre-gyp@^0.6.29
β”‚  β”œβ”€ glob-parent@^2.0.0
β”‚  β”œβ”€ inherits@^2.0.1
β”‚  β”œβ”€ is-binary-path@^1.0.0
β”‚  β”œβ”€ is-glob@^2.0.0
β”‚  β”œβ”€ [email protected]
β”‚  β”‚  β”œβ”€ mkdirp@^0.5.1
β”‚  β”‚  β”œβ”€ nopt@^4.0.1
β”‚  β”‚  β”œβ”€ npmlog@^4.0.2
β”‚  β”‚  β”œβ”€ rc@^1.1.7
β”‚  β”‚  β”œβ”€ request@^2.81.0
β”‚  β”‚  β”œβ”€ rimraf@^2.6.1
β”‚  β”‚  β”œβ”€ semver@^5.3.0
β”‚  β”‚  β”œβ”€ tar-pack@^3.4.0
β”‚  β”‚  └─ tar@^2.2.1
β”‚  β”œβ”€ path-is-absolute@^1.0.0
β”‚  └─ readdirp@^2.0.0

이유λ₯Ό λͺ¨λ₯΄κ² μŠ΅λ‹ˆλ‹€. Chokidarκ°€ μ˜¬λ°”λ₯΄κ²Œ λ³΄μž…λ‹ˆλ‹€: https://github.com/paulmillr/chokidar/blob/master/package.json

κ·Έλ ‡κΈ° λ•Œλ¬Έμ— 선택적 depsκ°€ μžˆλŠ” Yarn 문제라고 μƒκ°ν•©λ‹ˆλ‹€.

이 λ¬Έμ œλŠ” NPM v8을 μ‚¬μš©ν•  λ•Œ λ°œμƒν•˜λ©° NPM V6.10.3으둜 μ „ν™˜ν•˜μ—¬ 문제λ₯Ό ν•΄κ²°ν–ˆμŠ΅λ‹ˆλ‹€.

이것은 λ‹€μ‹œ λ°œμƒν•˜κΈ° μ‹œμž‘ν–ˆμœΌλ©° μ—¬μ „νžˆ FWIW λ¬Έμ œμž…λ‹ˆλ‹€. μ΅œμ‹  좜λ ₯:

yarn install v1.3.2
[1/5] πŸ”  Validating package.json...
[2/5] πŸ”  Resolving packages...
[3/5] 🚚  Fetching packages...
[4/5] πŸ”—  Linking dependencies...
warning " > [email protected]" has unmet peer dependency "babel-core@^6.0.0 || ^7.0.0-0".
warning " > [email protected]" has unmet peer dependency "babel-core<strong i="6">@6</strong> || 7 || ^7.0.0-alpha || ^7.0.0-beta || ^7.0.0-rc".
[5/5] πŸ“ƒ  Building fresh packages...
[1/5] β ‚ fsevents
[2/5] β ‚ uglifyjs-webpack-plugin
[1/5] β „ fsevents
[1/5] ⠈ fsevents: node-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v59-darwin-x64.tar.gz
[-/5] ⠈ waiting...
[3/5] ⠈ fsevents: node-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.3/fse-v1.1.3-node-v59-darwin-x64.tar.gz
[4/5] ⠈ fsevents: node-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz
[3/5] ⠁ fsevents: [fsevents] Success: "/Users/Miles/Sites/build-tool-config/node_modules/fsevents/lib/binding/Release/node-v59-darwin-x64/fse
[4/5] ⠁ fsevents: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)
warning Error running install script for optional dependency: "/Users/Miles/Sites/build-tool-config/node_modules/sane/node_modules/fsevents: Command failed.\nExit code: 1\nCommand: node install\nArguments: \nDirectory: /Users/Miles/Sites/build-tool-config/node_modules/sane/node_modules/fsevents\nOutput:\nnode-pre-gyp info it worked if it ends with ok\nnode-pre-gyp info using [email protected]\nnode-pre-gyp info using [email protected] | darwin | x64\nnode-pre-gyp info check checked for \"/Users/Miles/Sites/build-tool-config/node_modules/sane/node_modules/fsevents/lib/binding/Release/node-v59-darwin-x64/fse.node\" (not found)\nnode-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz\nnode-pre-gyp http 404 https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz\nnode-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz \nnode-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v59 ABI) (falling back to source compile with node-gyp) \nnode-pre-gyp http 404 status code downloading tarball https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.2/fse-v1.1.2-node-v59-darwin-x64.tar.gz \nnode-pre-gyp ERR! build error \nnode-pre-gyp ERR! stack Error: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)\nnode-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/Users/Miles/Sites/build-tool-config/node_modules/sane/node_modules/node-pre-gyp/lib/util/compile.js:77:29)\nnode-pre-gyp ERR! stack     at ChildProcess.emit (events.js:159:13)\nnode-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:207:12)\nnode-pre-gyp ERR! stack     at onErrorNT (internal/child_process.js:389:16)\nnode-pre-gyp ERR! stack     at process._tickCallback (internal/process/next_tick.js:152:19)\nnode-pre-gyp ERR! System Darwin 17.3.0\nnode-pre-gyp ERR! command \"/usr/local/Cellar/node/9.3.0_1/bin/node\" \"/Users/Miles/Sites/build-tool-config/node_modules/sane/node_modules/fsevents/node_modules/.bin/node-pre-gyp\" \"install\" \"--fallback-to-build\"\nnode-pre-gyp ERR! cwd /Users/Miles/Sites/build-tool-config/node_modules/sane/node_modules/fsevents\nnode-pre-gyp ERR! node -v v9.3.0\nnode-pre-gyp ERR! node-pre-gyp -v v0.6.37\nnode-pre-gyp ERR! not ok \nFailed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)"
info This module is OPTIONAL, you can safely ignore this error
warning Error running install script for optional dependency: "/Users/Miles/Sites/build-tool-config/node_modules/watchpack/node_modules/fsevents: Command failed.\nExit code: 1\nCommand: node install\nArguments: \nDirectory: /Users/Miles/Sites/build-tool-config/node_modules/watchpack/node_modules/fsevents\nOutput:\nnode-pre-gyp info it worked if it ends with ok\nnode-pre-gyp info using [email protected]\nnode-pre-gyp info using [email protected] | darwin | x64\nnode-pre-gyp info check checked for \"/Users/Miles/Sites/build-tool-config/node_modules/watchpack/node_modules/fsevents/lib/binding/Release/node-v59-darwin-x64/fse.node\" (not found)\nnode-pre-gyp http GET https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v59-darwin-x64.tar.gz\nnode-pre-gyp http 404 https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v59-darwin-x64.tar.gz\nnode-pre-gyp ERR! Tried to download(404): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v59-darwin-x64.tar.gz \nnode-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v59 ABI) (falling back to source compile with node-gyp) \nnode-pre-gyp http 404 status code downloading tarball https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.1/fse-v1.1.1-node-v59-darwin-x64.tar.gz \nnode-pre-gyp ERR! build error \nnode-pre-gyp ERR! stack Error: Failed to execute 'node-gyp clean' (Error: spawn node-gyp ENOENT)\nnode-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/Users/Miles/Sites/build-tool-config/node_modules/watchpack/node_modules/node-pre-gyp/lib/util/compile.js:77:29)\nnode-pre-gyp ERR! stack     at ChildProcess.emit (events.js:159:13)\nnode-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:207:12)\nnode-pre-gyp ERR! stack     at onErrorNT (internal/child_process.js:389:16)\nnode-pre-gyp ERR! stack     at process._tickCallback (internal/process/next_tick.js:152:19)\nnode-pre-gyp ERR! System Darwin 17.3.0\nnode-pre-gyp ERR! command \"/usr/local/Cellar/node/9.3.0_1/bin/node\" \"/Users/Miles/Sites[-/5] ⠐ waiting...
[-/5] β ‚ waiting...
[-/5] β ‚ waiting...
[-/5] β „ waiting...
[-/5] β „ waiting...
^C/5] β „ weak

λ‘€λ°±, μž¬μ„€μΉ˜, μž¬κ΅¬μΆ• 및 버전 λ³€κ²½μœΌλ‘œ λ¬Έμ œκ°€ ν•΄κ²°λ˜μ§€ μ•Šμ•˜μŠ΅λ‹ˆλ‹€.

μ•ˆλ…•ν•˜μ„Έμš”! κ·Έλž˜μ„œ μƒˆ λ…ΈνŠΈλΆμ— repoλ₯Ό μ„€μΉ˜ν•΄μ•Ό ν–ˆκ³  이것이 μ €μ—κ²Œ νš¨κ³Όμ μ΄μ—ˆμŠ΅λ‹ˆλ‹€.

Homebrewλ₯Ό μ‚¬μš©ν•˜μ—¬ 원사λ₯Ό μ„€μΉ˜ν–ˆμŠ΅λ‹ˆλ‹€.
λ‚΄ λ…ΈνŠΈλΆμ—μ„œ μ‹€ν–‰ μ€‘μž…λ‹ˆλ‹€.
node: 9.5.0
yarn: 1.3.2

yarn install 을 μ‹€ν–‰ν•˜λ €κ³  μ‹œλ„ν–ˆμ§€λ§Œ λͺ¨λ“  μ‚¬λžŒμ΄ μœ„μ— λΆ™μ—¬ 넣은 것과 λ™μΌν•œ 였λ₯˜κ°€ λ°œμƒν–ˆμŠ΅λ‹ˆλ‹€. 그런 λ‹€μŒ μ €μž₯μ†Œμ—μ„œ λ…Έλ“œ λͺ¨λ“ˆμ„ μ‚­μ œν–ˆμŠ΅λ‹ˆλ‹€.

그런 λ‹€μŒ μ‹€ν–‰ yarn add fsevents μ„€μΉ˜ ν•œ ^1.1.3 직접
그런 λ‹€μŒ yarn install λ‹€μ‹œ μ‹€ν–‰ν•˜λ©΄ λͺ¨λ“  것이 μ΅œμ‹  μƒνƒœμ΄κ³  λͺ¨λ“  λ…Έλ“œ λͺ¨λ“ˆμ΄ λ‹€μ‹œ λ‚˜νƒ€λ‚©λ‹ˆλ‹€.

그런 λ‹€μŒ ν”„λ‘œμ νŠΈκ°€ μ˜ˆμƒλŒ€λ‘œ 컴파일되고 μ‹€ν–‰λ˜μ—ˆμŠ΅λ‹ˆλ‹€. λΆ„λͺ…νžˆ μ΄μƒμ μ΄μ§€λŠ” μ•Šμ§€λ§Œ νš¨κ³Όκ°€ μžˆμ—ˆμŠ΅λ‹ˆλ‹€.

Macμ—μ„œ 개발 μ€‘μ΄μ§€λ§Œ λΉŒλ“œ/μ‹€ν–‰ λ˜λŠ” Linux인 경우 optionalDependencies 직접 1.1.3 버전을 μΆ”κ°€ν•˜λ©΄ λ¬Έμ œκ°€ ν•΄κ²°λ©λ‹ˆλ‹€.

λˆ„κ΅°κ°€μ—κ²Œ 도움이 될 수 μžˆλ„λ‘ 여기에 남겨 λ‘‘λ‹ˆλ‹€.
https://github.com/nodejs/node-gyp/issues/809#issuecomment -473261194

μ—…κ·Έλ ˆμ΄λ“œμ— λ¬Έμ œκ°€ μ—†λ‹€λ©΄ μ•„λ§ˆλ„ 이전 버전일 μˆ˜λ„ μžˆμŠ΅λ‹ˆλ‹€. yarn upgrade μ‚¬μš©ν•΄ λ³΄μ„Έμš”. :)

μƒˆ μž‘μ—… 곡간을 μΆ”κ°€ν•œ ν›„ 이 λ¬Έμ œκ°€ λ°œμƒν–ˆμŠ΅λ‹ˆλ‹€. Node: 12.3.1, Yarn: 1.16.0 및 Lerna: 3.13.3

λ‚˜λ₯Ό μœ„ν•œ μ†”λ£¨μ…˜μ€ yarn cache clean && yarn

μ—¬λŸ¬ μ œμ•ˆλœ μ†”λ£¨μ…˜μ„ μ‘°ν•©ν•΄μ•Ό ν–ˆμŠ΅λ‹ˆλ‹€.

yarn cache clean && yarn upgrade && yarn

그게 νŠΈλ¦­μ„ ν–ˆλ‹€. Expo ν”„λ‘œμ νŠΈμ— 쒅속성을 μ„€μΉ˜ν•˜κΈ° μœ„ν•΄ expo install expo-notifications λ₯Ό μ‹€ν–‰ν•˜λ €κ³  ν–ˆμŠ΅λ‹ˆλ‹€. λ‚˜λŠ” 이미 μ‚­μ œν–ˆλ‹€ node_modules μ‹€ν–‰ yarn install , κ·ΈλŸ¬λ‚˜ μ–΄λ–€ 이유둜 μ—¬μ „νžˆ λ¬Έμ œκ°€ μžˆμ—ˆλ‹€. μΊμ‹œκ°€ 범인인 것 κ°™μŠ΅λ‹ˆλ‹€.

npm install -g [email protected] λ…Έλ“œ 버전을 λ‹€μš΄κ·Έλ ˆμ΄λ“œν–ˆλŠ”λ° μž‘λ™ μ€‘μž…λ‹ˆλ‹€.

μ–€ μΊμ‹œ 클린 && μ–€ μ—…κ·Έλ ˆμ΄λ“œ && μ–€

@squattoλ‹˜, κ°μ‚¬ν•©λ‹ˆλ‹€. 방금 LTS λ²„μ „μ˜ Node(10.x -> 12.x)둜 μ—…κ·Έλ ˆμ΄λ“œν–ˆμœΌλ©° 이 문제(Expo ν”„λ‘œμ νŠΈμ—μ„œλ„)κ°€ μžˆμ—ˆμ§€λ§Œ κ·€ν•˜μ˜ μ†”λ£¨μ…˜μ΄ μ €μ—κ²Œ νš¨κ³Όμ μ΄μ—ˆμŠ΅λ‹ˆλ‹€. πŸ‘

λˆ„κ΅°κ°€ 이 였λ₯˜λ₯Ό λ°›λŠ” 경우 no-xcode-or-clt-version-detected-macos λ‹€μŒμ„ λ”°λ₯΄μ‹­μ‹œμ˜€.
https://medium.com/flawless-app-stories/gyp-no-xcode-or-clt-version-detected-macos-catalina-anansewaa-38b536389e8d

이 νŽ˜μ΄μ§€κ°€ 도움이 λ˜μ—ˆλ‚˜μš”?
0 / 5 - 0 λ“±κΈ‰