Closed wakaryry closed 6 years ago
Run npm install —save typescript
in the project folder, it appears that didn’t install properly.
$ ros init hello
$ cd /.../hello
$ npm install --save typescript
$ npm start
Then it says:
> my-ros-app@1.0.0 start /Users/dafangyang/hello
> npm run build && node dist/index.js
> my-ros-app@1.0.0 build /Users/dafangyang/hello
> rm -rf dist; ./node_modules/.bin/tsc
src/index.ts(1,29): error TS2307: Cannot find module 'realm-object-server'.
src/index.ts(2,23): error TS2307: Cannot find module 'path'.
src/index.ts(8,29): error TS2304: Cannot find name '__dirname'.
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! my-ros-app@1.0.0 build: `rm -rf dist; ./node_modules/.bin/tsc`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the my-ros-app@1.0.0 build 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! /Users/dafangyang/.npm/_logs/2018-01-27T18_52_55_651Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! my-ros-app@1.0.0 start: `npm run build && node dist/index.js`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the my-ros-app@1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Can you try running npm install
?
npm install
in the project folder.
$ npm install
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN my-ros-app@1.0.0 No repository field.
npm WARN my-ros-app@1.0.0 No license field.
npm WARN The package typescript is included as both a dev and production dependency.
Actually when I used npm
to install realm-object-server
, and the source is https://registry.npmjs.org/
, npm throws a error: cb() never called
.
Then I changed the source to registry.npm.taobao.org/
in China. npm install realm-object-server
can not fetch data.
Then I changed npm
into cnpm
. cnpm
is the same with npm
, but it download packages from source in China.
cnpm
could install realm-object-server
, but some packges like realm-sync-server
was in s3.amazon
. It's slow to dowmload it from China. I tried several times, even used a vpn (but a packge include parts need a vpn, some do not, the install broke times since the network).
I got excited when the install was finished, but, oh no.
Hi @wakaryry, Perhaps it will much easier for you to use the cloud service we are building now. HAve you signed up at https://cloud.realm.io/?
Version of Realm and Tooling
Realm Object Server Version: 2.6.2
Developer
Server OS & Version: Mac 10.13.2
node: 8.9.4
npm: 5.6.0
It says:
Installing dependencies... A little patience is good.undefined
Whatundefined
means?2018-01-27T12_56_31_332Z-debug.log
Need HELP!