Comments (5)
Merged @chaiwa-berian 's PR and released 0.3.2 👍
from run-rs.
@StephaneMartignier I am experiencing the exact same error. It worked the first time I used it, about a week ago, but it has been failing the whole of this week. Uninstalled and re-installed it several times to no luck!
from run-rs.
@StephaneMartignier After carefully looking at the code, I noticed that the code on line number 66 of the index.js could potentially be the cause of the error. Here is the reason:
If you run run-rs -v 4.0.2 --shell
without specifying the value for --dbpath
, the code will return ./data
as the dbPath
to be used on line number 69 and line number 80!
This will fail on windows because dbPath
will always be ./data whenever the --dbpath
option is not passed, and so the code on lines 69 and 80 will always resolve to the path below which is not a correct syntax for a windows path that md
command expects:
md .\./data
!
To resolve this potential bug for windows users, the code on line 66 can be refactored to something like below:
let dbPath;
if(typeof commander.dbpath === 'string'){
dbPath = `${commander.dbpath}` ;
}
else {
dbPath = isWin ? 'data' : './data';
}
Note: I have not tested this code but I believe it should be able to fix the issue! Let me know what you think about this! :)
from run-rs.
I have submitted a pull request for this issue. See Pull request #14
from run-rs.
I also think that your pr will solve the issue.
Also, in the documentation for the --dbpath option it's written "dbPath" in the example command. It's should be "dbpath"
from run-rs.
Related Issues (20)
- Gets stuck on 'Starting replica set...' HOT 8
- MongoDB 4.4.2 fails to start HOT 1
- Unable to start or create replica set with mongodb 4.4.1 HOT 1
- Is it possible to configure the ports? HOT 2
- Warnings HOT 1
- Starting rs with --keep throws an error HOT 1
- Error: Server is unavailable HOT 8
- run-rs nuked my existing databases HOT 1
- colors dependecy attack through prettyjson
- How to uninstall the mongodb rs installed by run-rs in macos?
- moment.js security vulnerability
- --keep option, way to avoid logging entire db contents on start? HOT 1
- No mongod process found at mongod, check your --mongod option
- Error: spawn Unknown system error -86 HOT 2
- Changing default ports with --portStart flag does not work
- Support Apple Silicon
- Not Working with Node Version 18 HOT 1
- Invalid namespace specified error when adding document to collection with feathers-mongodb and run-rs
- mongoDB is no longer available for download for Ubuntu 16.04
- Error "Server is unavailable" with Node >= 17 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from run-rs.