DEV Community

Varun Hegde
Varun Hegde

Posted on

Config Error with Mongodb-Atlas and flask-MongoAlchemy

I did put password of that user in the field and i have tried all possible combination with dbname.I dont know which dbname it is referring to. I have searched many places, didnt get any answers. Can some one please help me how to configure.

app.config['DEBUG']=True
app.config['MONGOALCHEMY_CONNECTION_STRING']='mongodb+srv://user:
@test .usvae.mongodb.net/?retryWrites=true&w=majority'
db=MongoAlchemy(app)
This is my configeration. This is the error i am getting

raise ImproperlyConfiguredError("You should provide a database name " flask_mongoalchemy.ImproperlyConfiguredError: You should provide a database name (the MONGOALCHEMY_DATABASE setting)

Thanks in advance

Top comments (0)