Meteor 1.3 React npm conflict - meteor

I'm upgrading from Meteor 1.2 to 1.3, and running into a NPM dependency issue with React. When I install the latest version of React (15.0.1), Meteor wants an earlier version (0.14.x). Then, I change my package.json file to 0.14.8, but Meteor wants (15.0.1).
Specifically,
When I install the npm React packages mentioned in the "Migrating to Meteor 1.3" doc, Meteor wants every package to use an earlier version:
W20160412-14:56:42.318(-5)? (STDERR) WARNING: npm peer requirements not installed:
W20160412-14:56:42.318(-5)? (STDERR) - react#15.0.1 installed, react#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-dom#15.0.1 installed, react-dom#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-addons-transition-group#15.0.1 installed, react-addons-transition-group#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-addons-css-transition-group#15.0.1 installed, react-addons-css-transition-group#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-addons-linked-state-mixin#15.0.1 installed, react-addons-linked-state-mixin#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-addons-create-fragment#15.0.1 installed, react-addons-create-fragment#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-addons-update#15.0.1 installed, react-addons-update#0.14.x needed
W20160412-14:56:42.319(-5)? (STDERR) - react-addons-pure-render-mixin#15.0.1 installed, react-addons-pure-render-mixin#0.14.x needed
W20160412-14:56:42.320(-5)? (STDERR) - react-addons-test-utils#15.0.1 installed, react-addons-test-utils#0.14.x needed
W20160412-14:56:42.320(-5)? (STDERR) - react-addons-perf#15.0.1 installed, react-addons-perf#0.14.x needed
But, when I go into package.json and downgrade these packages to 0.14.8, I get this error
W20160412-17:31:33.167(-5)? (STDERR) WARNING: npm peer requirements not installed:
W20160412-17:31:33.169(-5)? (STDERR) - react#0.14.8 installed, react#15.x needed
W20160412-17:31:33.169(-5)? (STDERR) - react-addons-pure-render-mixin#0.14.8 installed, react-addons-pure-render-mixin#15.x needed

In case anyone else ran into this problem, it was caused by the popular ReactLayout package on Atmosphere. (If you use FlowRouter, you almost definitely use ReactLayout.) The Kadira team, which built FlowRouter and ReactLayout, decided not to upgrade ReactLayout for Meteor 1.3.
Instead, they built a new NPM module instead called react-mounter. You need remove ReactLayout and then install react-mounter via npm.
The directions are here https://voice.kadira.io/getting-started-with-meteor-1-3-and-react-15e071e41cd1#.u5quqwvum
Hope this saves you some time!

I followed the instructions here and installed node.js and use the modules from npm and my meteor 1.3 started working again.
https://forums.meteor.com/t/how-to-setup-meteor-1-3beta-react-react-router-via-npm/16013

Related

Meteor. Error after update to 1.9 from 1.8.3

I updated the Meteor to 1.9 with all packages(meteor/npm). The bcrypt was already installed.
I followed and executed all migration steps. Despite that I got the follow errors:
(Important to note if I downgrade to 1.8.3 everything works fine)
What is going wrong?
W20200720-17:39:36.075(3)? (STDERR) Note: you are using a pure-JavaScript implementation of bcrypt.
W20200720-17:39:36.078(3)? (STDERR) While this implementation will work correctly, it is known to be
W20200720-17:39:36.079(3)? (STDERR) approximately three times slower than the native implementation.
W20200720-17:39:36.079(3)? (STDERR) In order to use the native implementation instead, run
W20200720-17:39:36.080(3)? (STDERR)
W20200720-17:39:36.080(3)? (STDERR) meteor npm install --save bcrypt
W20200720-17:39:36.080(3)? (STDERR)
W20200720-17:39:36.081(3)? (STDERR) in the root directory of your application.
=> Exited with code: 7
=> Your application is crashing. Waiting for file change.
Start meteor all logs:
backend $ meteor
[[[[[ ~/job/meteor/backend ]]]]]
=> Started proxy.
=> Meteor 1.10.2 is available. Update this project with 'meteor update'.
WARNING: npm peer requirements (for juliancwirko:postcss) not installed:
- postcss#7.0.6 installed, postcss#^6.0.22 needed
- postcss-load-config#2.0.0 installed, postcss-load-config#^1.2.0 needed
Read more about installing npm peer dependencies:
http://guide.meteor.com/using-packages.html#peer-npm-dependencies
=> Started MongoDB.
Browserslist: caniuse-lite is outdated. Please run next command `npm update caniuse-lite browserslist`
W20200722-11:50:38.504(3)? (STDERR) Note: you are using a pure-JavaScript implementation of bcrypt.
W20200722-11:50:38.538(3)? (STDERR) While this implementation will work correctly, it is known to be
W20200722-11:50:38.539(3)? (STDERR) approximately three times slower than the native implementation.
W20200722-11:50:38.539(3)? (STDERR) In order to use the native implementation instead, run
W20200722-11:50:38.539(3)? (STDERR)
W20200722-11:50:38.540(3)? (STDERR) meteor npm install --save bcrypt
W20200722-11:50:38.540(3)? (STDERR)
W20200722-11:50:38.540(3)? (STDERR) in the root directory of your application.
=> Exited with code: 7
=> Your application is crashing. Waiting for file change.

Cannot find module '#babel/runtime/helpers/builtin/objectSpread' after update meteor to 1.6.1.1

i updated my meteor project to Meteor 1.6.1.1. and i got this error message
=> Exited with code: 1
W20180403-15:33:17.531(2)? (STDERR) E:\Personnal folders\quicktext5\.meteor\local\build\programs\server\boot.js:475
W20180403-15:33:17.534(2)? (STDERR) }).run();
W20180403-15:33:17.535(2)? (STDERR) ^
W20180403-15:33:17.539(2)? (STDERR)
W20180403-15:33:17.540(2)? (STDERR) Error: Cannot find module '#babel/runtime/helpers/builtin/objectSpread'
W20180403-15:33:17.541(2)? (STDERR) at Function.Module._resolveFilename (module.js:547:15)
W20180403-15:33:17.543(2)? (STDERR) at Function.resolve (internal/module.js:18:19)
W20180403-15:33:17.547(2)? (STDERR) at Object.require (E:\Personnal folders\quicktext5\.meteor\local\build\programs\server\boot.js:288:32)
W20180403-15:33:17.548(2)? (STDERR) at makeInstallerOptions.fallback (packages\modules-runtime.js:651:18)
W20180403-15:33:17.548(2)? (STDERR) at require (packages\modules-runtime.js:244:16)
W20180403-15:33:17.549(2)? (STDERR) at livedata_connection.js (E:\Personnal folders\quicktext5\.meteor\local\build\programs\server\packages\ddp-client.js:149:45)
W20180403-15:33:17.550(2)? (STDERR) at fileEvaluate (packages\modules-runtime.js:343:9)
W20180403-15:33:17.550(2)? (STDERR) at require (packages\modules-runtime.js:238:16)
W20180403-15:33:17.551(2)? (STDERR) at namespace.js (packages/ddp-client/common/namespace.js:1:300)
W20180403-15:33:17.556(2)? (STDERR) at fileEvaluate (packages\modules-runtime.js:343:9)
i tried to delete the node_modules folder and run npm install .
I also tried to install meteor npm install --save babel-runtime
but still got the same Error
Any suggestions ?
Well since the meteor-babel npm package has been updated to version 7.0.0-beta.44, which may require updating any custom Babel plugins I have enabled in a .babelrc file, I tried to running the following command to update #babel/runtime:
meteor npm install #babel/runtime#latest
Thanks to #robfallows who answered my question in Meteor forums
https://forums.meteor.com/t/cannot-find-module-babel-runtime-helpers-builtin-objectspread-after-update-meteor-to-1-6-1-1/43034
In case someone is still having the same problem, if you are not using meteor1.7.x then the latest version of babel/runtime might not fix the error for you as it didn't fix for me, what worked however was to use.
meteor npm install babel/runtime#7.0.0-beta.55
The best option would be however to update to the latest version of Meteor but if you aren't ready use the beta version above it will fix the error.
Updated to Meteor 1.7 which identified the error, said to do this:
meteor npm install --save-exact #babel/runtime#7.0.0-beta.55
Back online!

Meteor fails in production mode but runs on local development server

The OS is Centos 6.2 on an intel X86_64 architecture. Node version is 4.0.0. I created the starter project and tried building and running it using
meteor
as well as
meteor run
for running in a local development server and
meteor run --production
for emulating production mode. Only the "meteor run" command worked. Both the plain "meteor" and "meteor run --production" gave the following error:
=> Started proxy.
W20151229-23:28:35.043(0)? (STDERR)
W20151229-23:28:35.046(0)? (STDERR)
W20151229-23:28:35.047(0)? (STDERR) #
W20151229-23:28:35.047(0)? (STDERR) # Fatal error in ../deps/v8/src/platform-linux.cc, line 776
W20151229-23:28:35.048(0)? (STDERR) # CHECK_EQ(0, result) failed
W20151229-23:28:35.048(0)? (STDERR) # Expected: 0
W20151229-23:28:35.048(0)? (STDERR) # Found: 11
W20151229-23:28:35.049(0)? (STDERR) #
W20151229-23:28:35.049(0)? (STDERR)
=> Exited from signal: SIGTRAP
I have searched for answers and one suggestion is to use meteor-up, but centos is not supported. I'd love to able to use Meteor for my next project, but can't until I can get a production version running on this server. Any suggestions would be appreciated.

accounts-password from meteor breaking because of bcrypt

I am getting this error:
Error: Can't find npm module 'bcrypt'. Did you forget to call 'Npm.depends' in package.js within the 'npm-bcrypt' package?
I'm not sure what to make of it.. I am just learning meteor but I have userd accounts-password and accounts-ui before without any problems. However now its asking for dependencies. If I comment out the accounts-password page in ".meteor/packages" then the server will boot up without problems.
Has anyone had this problem before? This is the full error.
W20150602-09:54:54.633(-7)? (STDERR)
W20150602-09:54:54.635(-7)? (STDERR)
/Users/VCarlos/.meteor/packages/meteor-tool/.1.1.3.1wysac9++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:245 W20150602-09:54:54.635(-7)? (STDERR) throw(ex);
W20150602-09:54:54.635(-7)? (STDERR) ^
W20150602-09:54:54.639(-7)? (STDERR) Error: Can't find npm module
'bcrypt'. Did you forget to call 'Npm.depends' in package.js within
the 'npm-bcrypt' package? W20150602-09:54:54.640(-7)? (STDERR) at
Object.Npm.require
(/Users/VCarlos/Dropbox/wdi/inslim/.meteor/local/build/programs/server/boot.js:155:17)
W20150602-09:54:54.640(-7)? (STDERR) at Package
(packages/npm-bcrypt/wrapper.js:1:1) W20150602-09:54:54.640(-7)?
(STDERR) at
/Users/VCarlos/Dropbox/wdi/inslim/.meteor/local/build/programs/server/packages/npm-bcrypt.js:21:4
W20150602-09:54:54.640(-7)? (STDERR) at
/Users/VCarlos/Dropbox/wdi/inslim/.meteor/local/build/programs/server/packages/npm-bcrypt.js:30:3
W20150602-09:54:54.641(-7)? (STDERR) at
/Users/VCarlos/Dropbox/wdi/inslim/.meteor/local/build/programs/server/boot.js:222:10
W20150602-09:54:54.641(-7)? (STDERR) at Array.forEach (native)
W20150602-09:54:54.642(-7)? (STDERR) at Function..each..forEach
(/Users/VCarlos/.meteor/packages/meteor-tool/.1.1.3.1wysac9++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/underscore/underscore.js:79:11) W20150602-09:54:54.642(-7)? (STDERR) at
/Users/VCarlos/Dropbox/wdi/inslim/.meteor/local/build/programs/server/boot.js:117:5
This is happening because you create your bundle on one platform (OS X, Windows, etc) then deploy your project on another platform (different from the original).
To fix this install bcrypt in your app:
In your untarred and ungziped directory:
(cd programs/server && npm install)
cd programs/server/npm/npm-bcrypt/node_modules/
rm -rf bcrypt
npm install bcrypt
Since yours is a development mode you may have to go into .meteor/local/build to make get to the bundle directory.
Your app has a weird structure its not common to have the packages/npm-bcrypt in your app. This is a native meteor package. You may want to contact the author of the app to ask why s/he has placed this package here and if its not modified remove it so Meteor can use the native bcrypt package designed for your platform.
The accepted answer didn't work for me, but this did:
rm -rf ~/.meteor/packages/npm-bcrypt.
Then after running meteor it downloaded bcrypt again and all was fine.
I have found that many of my bugs occur when I install or uninstall packages from my project while the server is still running. Simply restarting my server fixed my bcrypt issue.

Installation of Natural package in meteor throws uncaught exception

I am working on a project based on meteor framework. For natural language facility, have installed natural package using "npm install natural" command. For this, have used following link "https://github.com/NaturalNode/natural".
When I run the app,it is throwing the following error
--
W20140521-14:22:08.096(1)? (STDERR) /home/priya/.meteor/tools/09b63f1ed5/lib/node_modules/fibers/future.js:173
W20140521-14:22:08.385(1)? (STDERR) throw(ex);
W20140521-14:22:08.386(1)? (STDERR) ^
W20140521-14:22:08.386(1)? (STDERR) ReferenceError: require is not defined
W20140521-14:22:08.387(1)? (STDERR) at app/node_modules/natural/node_modules/apparatus/lib/apparatus/classifier/bayes_classifier.js:23:12
W20140521-14:22:08.387(1)? (STDERR) at app/node_modules/natural/node_modules/apparatus/lib/apparatus/classifier/bayes_classifier.js:134:3
W20140521-14:22:08.387(1)? (STDERR) at /home/priya/gbproject/.meteor/local/build/programs/server/boot.js:155:10
W20140521-14:22:08.388(1)? (STDERR) at Array.forEach (native)
W20140521-14:22:08.388(1)? (STDERR) at Function..each..forEach (/home/priya/.meteor/tools/09b63f1ed5/lib/node_modules/underscore/underscore.js:79:11)
W20140521-14:22:08.388(1)? (STDERR) at /home/priya/gbproject/.meteor/local/build/programs/server/boot.js:82:5
=> Exited with code: 8
--
I have not written any code after it's installation, then why showing this error. Googled also but could not get the solution. Any pointers please. Thanks in advance
0: Remove the "node_modules" directory at the root of your application if it exists (it should be created when you run npm install natural).
1: If you need to install a NPM package with Meteor, I recommend you add the NPM package with mrt:
mrt add npm
2: Then, you should add your npm package inside the packages.json file (created during step 1 at the root of your application).
{
"natural": "0.1.27",
}
3: Then, use Meteor.require('natural')in your file instead of NPM.require('natural').
4: Launch Meteor and check that everything works as expected.

Resources