Fix README installation instructions
I'm getting the following error trying to install:
mkdir -p ~/.webppl
npm install --prefix ~/.webppl webppl-agents
npm ERR! code E404
npm ERR! 404 Not Found: webppl-agents@latest
Here is the output of the log:
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/Cellar/node/10.8.0/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'install',
1 verbose cli '--prefix',
1 verbose cli '/Users/tobi/.webppl',
1 verbose cli 'webppl-agents' ]
2 info using [email protected]
3 info using [email protected]
4 verbose npm-session 6b142f7a1a56a2d9
5 silly install loadCurrentTree
6 silly install readLocalPackageData
7 http fetch GET 404 https://registry.npmjs.org/webppl-agents 217ms
8 silly fetchPackageMetaData error for webppl-agents@latest 404 Not Found: webppl-agents@latest
9 timing stage:rollbackFailedOptional Completed in 2ms
10 timing stage:runTopLevelLifecycles Completed in 498ms
11 verbose stack Error: 404 Not Found: webppl-agents@latest
11 verbose stack at fetch.then.res (/usr/local/lib/node_modules/npm/node_modules/pacote/lib/fetchers/registry/fetch.js:42:19)
11 verbose stack at tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
11 verbose stack at Promise._settlePromiseFromHandler (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:512:31)
11 verbose stack at Promise._settlePromise (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:569:18)
11 verbose stack at Promise._settlePromise0 (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:614:10)
11 verbose stack at Promise._settlePromises (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:693:18)
11 verbose stack at Async._drainQueue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:133:16)
11 verbose stack at Async._drainQueues (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:143:10)
11 verbose stack at Immediate.Async.drainQueues [as _onImmediate] (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:17:14)
11 verbose stack at runCallback (timers.js:693:18)
11 verbose stack at tryOnImmediate (timers.js:664:5)
11 verbose stack at processImmediate (timers.js:646:5)
12 verbose cwd /Users/tobi
13 verbose Darwin 17.7.0
14 verbose argv "/usr/local/Cellar/node/10.8.0/bin/node" "/usr/local/bin/npm" "install" "--prefix" "/Users/tobi/.webppl" "webppl-agents"
15 verbose node v10.8.0
16 verbose npm v6.4.0
17 error code E404
18 error 404 Not Found: webppl-agents@latest
19 verbose exit [ 1, true ]
Looks like we didn't publish the package on npm. Try
mkdir -p ~/.webppl
npm install --prefix ~/.webppl webppl-dp
npm install --prefix ~/.webppl agentmodels/webppl-agents
to install directly from Github?
Note: I haven't tested the package in a long time. It's possible that it has become incompatible with newer versions of webppl or other required packages.
thanks @stuhlmueller that worked!
however, when trying to run the test command: webppl --require webppl-dp --require . tests/tests.wppl it throws the following error:
/usr/local/lib/node_modules/webppl/src/pkg.js:88
throw new Error('Could not find WebPPL package: ' + name_or_path);
^
Error: Could not find WebPPL package: .
at readFirst (/usr/local/lib/node_modules/webppl/src/pkg.js:88:13)
at readFirst (/usr/local/lib/node_modules/webppl/src/pkg.js:84:16)
at Object.read (/usr/local/lib/node_modules/webppl/src/pkg.js:96:14)
at /usr/local/lib/node_modules/webppl/webppl:131:25
at Array.map (<anonymous>)
at main (/usr/local/lib/node_modules/webppl/webppl:130:45)
at Object.<anonymous> (/usr/local/lib/node_modules/webppl/webppl:161:1)
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)
any idea how to fix this?
You could try running it from the directory it's installed in:
cd ~/.webppl/node_modules/webppl-agents/
webppl --require webppl-dp --require . tests/tests.wppl
Unfortunately, I then run into issue #62 which I don't immediately know how to fix. It's probably not difficult to fix with some googling for someone with basic knowledge of the node/npm package system.
Sorry for the terrible instructions and state of the package.
same here. also have #62 in that case. will see whether i can find someone to look into it :)
Great!
I'm going to reopen this issue since we still need to fix the README.