runtimejs / runtime

[not maintained] Lightweight JavaScript library operating system for the cloud
http://runtimejs.org
Apache License 2.0
1.93k stars 128 forks source link

Exception: bundle.js:9290: error: this program requires runtime.js environment #94

Closed diversemix closed 8 years ago

diversemix commented 8 years ago

I've followed the instructions in the README.md trying to run this example: https://github.com/runtimejs/helloworld and I get the following error:

@1.0.0 start /.../helloworld runtimeify index.js -o initrd && runtime-qemu ./initrd

--- starting qemu --- [INITRD] Load /bundle.js len 270375 Uncaught exception: /bundle.js:9290: error: this program requires runtime.js environment [ terminate thread (reason: refcount 0) ] Kernel error: Assertion failed: !"main isolate exited" (src/kernel/thread.cc: TearDown: 141)

--------------------------------- VERSIONS ---------------------------------

Linux version 4.2.8-300.fc23.x86_64 (mockbuild@bkernel01.phx2.fedoraproject.org) (gcc version 5.3.1 20151207 (Red Hat 5.3.1-2) (GCC) ) Node v.10.36 Npm 1.3.6 runtimejs 0.2.5 runtimeify 1.0.0 runtime-tools 2.0.0

facekapow commented 8 years ago

runtimeify is deprecated, use runtime-cli:

From the README:

First thing is the command line tool runtime-cli, it will add runtime command to the shell. Type runtime to get full usage help. npm install runtime-cli -g

and

Create new project and add index.js entry point file:

mkdir project
cd project
npm init
npm install runtimejs --save
echo "console.log('ok')" > index.js

Run project locally in the QEMU VM: runtime start

Yeah, we need to update the helloworld.

diversemix commented 8 years ago

Ok, it works great now thanks!

I did have to update my version of npm before it would install the runtime-cli due to an unmet dependency. But works great now, if its helpful my npm verions is now "3.5.3"

iefserge commented 8 years ago

I see it doesn't work in npm@1 (1.4.29), but works using npm@2 (2.14.9). npm@1 is deprecated now, I think it doesn't make sense to support it. Thank you, closing.