realm-js: Missing dependencies
Goals
Try to run and build the new version 2.24.0.
Expected Results
The build process should download the new coca and decompress and unzip it.
Actual Results and Workaround
The packages “decompress” and “https-proxy-agent” are missing.
Error: Cannot find module 'https-proxy-agent'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object.<anonymous> (/ProjectPath/node_modules/realm/scripts/download-realm.js:25:25)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
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)
Command PhaseScriptExecution failed with a nonzero exit code
It works if you do
yarn add decompress
yarn add https-proxy-agent
Steps to Reproduce
Try to install the new version.
Version of Realm and Tooling
- Realm JS SDK Version: 2.24.0 React Native Environment Info: System: OS: macOS 10.14.3 CPU: (4) x64 Intel® Core™ i7-3520M CPU @ 2.90GHz Memory: 31.00 MB / 8.00 GB Shell: 3.2.57 - /bin/bash Binaries: Node: 10.11.0 - /usr/local/bin/node Yarn: 1.3.2 - ~/.yarn/bin/yarn npm: 6.8.0 - /usr/local/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman SDKs: iOS SDK: Platforms: iOS 12.1, macOS 10.14, tvOS 12.1, watchOS 5.1 Android SDK: API Levels: 22, 23, 25 Build Tools: 23.0.1, 23.0.2, 25.0.0, 25.0.1, 25.0.2 System Images: android-22 | Google APIs Intel x86 Atom, android-23 | ARM EABI v7a IDEs: Android Studio: 3.0 AI-171.4443003 Xcode: 10.1/10B61 - /usr/bin/xcodebuild npmPackages: react: 16.6.3 => 16.6.3 react-native: 0.58.5 => 0.58.5 npmGlobalPackages: create-react-native-app: 1.0.0 react-native-camera: 0.8.0 react-native-cli: 2.0.1 react-native-git-upgrade: 0.2.7
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 5
- Comments: 21 (7 by maintainers)
@StevenMasini We moved those dependencies in v2.26.0 so if you upgrade, it should have been solved.
Found issue.
In v2.24.0, The Xcode project will run
[ ! -d node_modules/fs-extra ] && npm install --no-saveWhich install those modules locally insidenode_modules/realm. Also installnodevia nvm (same as previous versions).I think those are not good behaviors.
realm-js.node.realm-jsshould hasnodesupport already.I also wrote a shell script
download-realm.shto replacedownload-realm.jsIt provides same behavior asdownload-realm.js. https://gist.github.com/shenjunru/2328b60558c769fe4975378c8eaacc7dIndeed in a clean space it works fine, don´t know what happend here then. Sry for bothering.