eschutho commented on a change in pull request #11207:
URL: 
https://github.com/apache/incubator-superset/pull/11207#discussion_r509627515



##########
File path: superset/cli.py
##########
@@ -628,3 +628,18 @@ def alert() -> None:
             resolution=6000,
             session=session,
         )
+
+
[email protected]()
+@with_appcontext
+def create_db() -> None:
+    """Resets database"""
+    db.create_all()
+
+
[email protected]()
+@with_appcontext
[email protected]_option(prompt="Are you sure you want to drop the db?")
+def drop_db() -> None:

Review comment:
       In addition to adding the db name in the prompt/confirmation, perhaps we 
can also wrap this in `if app.config["TESTING"]:` to ensure that this doesn't 
run in a production or dev environment. 




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to