1

I am using iron-meteor for scaffolding meteor crud apps and I am following this tutorial. I have iron meteor running but the problem arises when I install aldeed collections and other packages as follows;

iron add twbs:bootstrap aldeed:collection2 aldeed:autoform aldeed:delete-button momentjs:moment accounts-password ian:accounts-ui-bootstrap-3

I also have;

npm install -g --save simpl-schema

But I get errors when I run iron run

W20190716-20:45:24.894(2)? (STDERR) WARNING: npm peer requirements (for aldeed:collection2) not installed: W20190716-20:45:24.894(2)? (STDERR) - simpl-schema@>=0.0.0 not installed

I have tried changing npm directory rights and permissions to ensure that the current user has access to npm packages. I have also tried uninstalling and reinstalling aldeed:collections2 package and simpl-schema but the same error still persists

=> Started proxy.
=> Started MongoDB. W20190716-20:45:24.686(2)? (STDERR) Note: you are using a pure-JavaScript implementation of bcrypt. W20190716-20:45:24.714(2)? (STDERR) While this implementation will work correctly, it is known to be W20190716-20:45:24.714(2)? (STDERR) approximately three times slower than the native implementation. W20190716-20:45:24.719(2)? (STDERR) In order to use the native implementation instead, run W20190716-20:45:24.720(2)? (STDERR) W20190716-20:45:24.720(2)? (STDERR) meteor npm install --save bcrypt W20190716-20:45:24.720(2)? (STDERR) W20190716-20:45:24.720(2)? (STDERR) in the root directory of your application. W20190716-20:45:24.894(2)? (STDERR) WARNING: npm peer requirements (for aldeed:collection2) not installed: W20190716-20:45:24.894(2)? (STDERR) - simpl-schema@>=0.0.0 not installed. W20190716-20:45:24.894(2)? (STDERR) W20190716-20:45:24.895(2)? (STDERR) Read more about installing npm peer dependencies: W20190716-20:45:24.895(2)? (STDERR)
http://guide.meteor.com/using-packages.html#peer-npm-dependencies W20190716-20:45:24.895(2)? (STDERR) W20190716-20:45:24.937(2)? (STDERR) /home/kingzuru/.meteor/packages/meteor-tool/.1.8.1.1ehy8qi.j0unh++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:280 W20190716-20:45:24.940(2)? (STDERR) throw(ex); W20190716-20:45:24.941(2)? (STDERR) ^ W20190716-20:45:24.941(2)? (STDERR) W20190716-20:45:24.941(2)? (STDERR) Error: Cannot find module 'simpl-schema' W20190716-20:45:24.942(2)? (STDERR) at makeMissingError (packages/modules-runtime.js:222:12) W20190716-20:45:24.942(2)? (STDERR) at Module.require (packages/modules-runtime.js:241:17) W20190716-20:45:24.942(2)? (STDERR) at require (packages/modules-runtime.js:258:21) W20190716-20:45:24.943(2)? (STDERR) at collection2.js (packages/aldeed:collection2/collection2.js:13:22) W20190716-20:45:24.943(2)? (STDERR) at fileEvaluate (packages/modules-runtime.js:336:7) W20190716-20:45:24.943(2)? (STDERR) at Module.require (packages/modules-runtime.js:238:14) W20190716-20:45:24.944(2)? (STDERR) at require (packages/modules-runtime.js:258:21) W20190716-20:45:24.944(2)? (STDERR) at /var/www/testapp/app/.meteor/local/build/programs/server/packages/aldeed_collection2.js:895:15 W20190716-20:45:24.944(2)? (STDERR) at /var/www/testapp/app/.meteor/local/build/programs/server/packages/aldeed_collection2.js:902:3 W20190716-20:45:24.945(2)? (STDERR) at /var/www/testapp/app/.meteor/local/build/programs/server/boot.js:419:36 W20190716-20:45:24.945(2)? (STDERR) at Array.forEach () W20190716-20:45:24.945(2)? (STDERR) at /var/www/testapp/app/.meteor/local/build/programs/server/boot.js:228:19 W20190716-20:45:24.945(2)? (STDERR) at /var/www/testapp/app/.meteor/local/build/programs/server/boot.js:479:5 W20190716-20:45:24.945(2)? (STDERR) at Function.run (/var/www/testapp/app/.meteor/local/build/programs/server/profile.js:510:12) W20190716-20:45:24.946(2)? (STDERR) at /var/www/testapp/app/.meteor/local/build/programs/server/boot.js:478:11 => Exited with code: 1

Phemelo Khetho
  • 231
  • 1
  • 4
  • 14
  • If it is just the Meteor project try 'meteor add aldeed:simple-schema' . More info is here: https://atmospherejs.com/aldeed/simple-schema – aman_novice Jul 18 '19 at 03:39
  • I'm not using meteor outright, I am using iron-meteor found here, https://github.com/iron-meteor/iron-cli – Phemelo Khetho Jul 18 '19 at 13:27
  • Even then, it is meteor project at the end of the day. Can you check if .meteor/version file has `aldeed:simple-schema@1.3.0` From the link of your tutorial: https://github.com/seeschweiler/medium-issuetracker/tree/master/app/.meteor Secondly, I believe it should be `meteor npm install --save simpl-schema` . Check the Atmosphere Readme of the `aldeed:collection2` -> https://atmospherejs.com/aldeed/collection2 – aman_novice Jul 18 '19 at 15:05

1 Answers1

1

The command npm install -g --save simpl-schema installs Simple Schema on a global level (-g option means install globally) and thus it won't be usable on your local project.

You should rather do meteor npm install --save simpl-schema inside your project.

Note, that aldeed:simple-schema is deprecated, as well as aldeed:collection2-core (which is why you should use aldeed:collection2).

Jankapunkt
  • 8,128
  • 4
  • 30
  • 59
  • I have ran meteor npm install --save simpl-schema but I am still getting the same error. – Phemelo Khetho Jul 19 '19 at 08:28
  • Inside the project folder? Can you rebuild using `meteor reset`? – Jankapunkt Jul 19 '19 at 08:38
  • I did run iron reset and ran the application but I am still hitting the same error. – Phemelo Khetho Jul 19 '19 at 10:31
  • Can you provide a repo with a minimal project due reproduce? – Jankapunkt Jul 19 '19 at 11:04
  • I don't have a repo but what I did was just to follow the above sited tutorial and installed all the mentioned packages that's when a hit simpl-schema errors. For now, I noticed that iron scaffolding is working fine and as workaround I use it to generated files then I copy them over to a pure meteor application which has no problems with simple-schema or aldeed packages. It's a long process but it gets me through. – Phemelo Khetho Jul 20 '19 at 11:09