Reputation: 11971
I'm using meteor.js
and I just went to change some of the HTML output in the .html file only and it started giving me the error:
Error: database names cannot contain the character '.'
I haven't changed anything, the only thing I recall doing inbetween is starting a new project which I created using meteor.js, which then updated meteor and now I have this problem.
Rest of error details:
Error: database names cannot contain the character '.'
W20130828-09:52:22.049(1)? (STDERR) at validateDatabaseName (/Users/jumpingcode/.meteor/packages/mongo-livedata/86ae77f282/npm/node_modules/mongodb/lib/mongodb/db.js:216:59)
W20130828-09:52:22.050(1)? (STDERR) at new Db (/Users/jumpingcode/.meteor/packages/mongo-livedata/86ae77f282/npm/node_modules/mongodb/lib/mongodb/db.js:90:3)
W20130828-09:52:22.050(1)? (STDERR) at MongoClient.connect.connectFunction (/Users/jumpingcode/.meteor/packages/mongo-livedata/86ae77f282/npm/node_modules/mongodb/lib/mongodb/mongo_client.js:238:29)
W20130828-09:52:22.050(1)? (STDERR) at Function.MongoClient.connect (/Users/jumpingcode/.meteor/packages/mongo-livedata/86ae77f282/npm/node_modules/mongodb/lib/mongodb/mongo_client.js:291:5)
W20130828-09:52:22.050(1)? (STDERR) at Function.Db.connect (/Users/jumpingcode/.meteor/packages/mongo-livedata/86ae77f282/npm/node_modules/mongodb/lib/mongodb/db.js:1854:23)
W20130828-09:52:22.051(1)? (STDERR) at new MongoConnection (packages/mongo-livedata/mongo_driver.js:113)
W20130828-09:52:22.051(1)? (STDERR) at new MongoInternals.RemoteCollectionDriver (packages/mongo-livedata/remote_collection_driver.js:3)
W20130828-09:52:22.051(1)? (STDERR) at Object. (packages/mongo-livedata/remote_collection_driver.js:34)
W20130828-09:52:22.051(1)? (STDERR) at Object._.once [as defaultRemoteCollectionDriver] (packages/underscore/underscore.js:704)
W20130828-09:52:22.053(1)? (STDERR) at new Meteor.Collection (packages/mongo-livedata/collection.js:66)
Upvotes: 3
Views: 3726
Reputation: 567
when I use expressjs with mongoose, above error was occured.It resolve by doing
1.create a database.js file
make a exportble database configuration inside it as follows
module.exports = {database : "mongodb://myUsername:[email protected]:61039/accounttest"};
2.Require it to your current JS file
var connection = mongoose.connect(config.database);
Upvotes: 0
Reputation: 75945
Have a look at your collection in .meteor/local/db
to see if any files were added in.
If it really still continues you could use meteor reset
but it would clear your database.
The issue arises from mongodb, because .
notation lets you peak inside objects in javascript the character is reserved and can't be used as a collection or database name.
If there is any environmental variable that you've used it could also cause the issue with a new typo or something. Try using just meteor
like you usually would in a fresh terminal window.
Upvotes: 1