diff --git a/app/config.py b/app/config.py index 432fa075..c49109e8 100644 --- a/app/config.py +++ b/app/config.py @@ -45,7 +45,6 @@ if config_file: else: load_dotenv() -RESET_DB = "RESET_DB" in os.environ COLOR_LOG = "COLOR_LOG" in os.environ # Allow user to have 1 year of premium: set the expiration_date to 1 year more diff --git a/example.env b/example.env index 2e7e859f..5b00468e 100644 --- a/example.env +++ b/example.env @@ -74,9 +74,6 @@ EMAIL_SERVERS_WITH_PRIORITY=[(10, "email.hostname.")] # the DKIM private key used to compute DKIM-Signature # DKIM_PRIVATE_KEY_PATH=local_data/dkim.key -# delete and recreate the sqlite database, for local development -RESET_DB=true - # DB Connection # Local SQLite database DB_URI=sqlite:///db.sqlite diff --git a/server.py b/server.py index 15bda4b9..d0c60f51 100644 --- a/server.py +++ b/server.py @@ -49,7 +49,6 @@ from app.config import ( URL, SHA1, PADDLE_MONTHLY_PRODUCT_ID, - RESET_DB, FLASK_PROFILER_PATH, FLASK_PROFILER_PASSWORD, SENTRY_FRONT_END_DSN, @@ -951,15 +950,6 @@ def local_main(): app.debug = True DebugToolbarExtension(app) - # warning: only used in local - if RESET_DB: - from init_app import add_sl_domains - - LOG.warning("reset db, add fake data") - with app.app_context(): - fake_data() - add_sl_domains() - app.run(debug=True, port=7777) # uncomment to run https locally diff --git a/tests/test.env b/tests/test.env index 8b5669fd..3c5b3ff9 100644 --- a/tests/test.env +++ b/tests/test.env @@ -14,8 +14,6 @@ MAX_NB_EMAIL_FREE_PLAN=3 EMAIL_SERVERS_WITH_PRIORITY=[(10, "email.hostname.")] DKIM_PRIVATE_KEY_PATH=local_data/dkim.key -# Database -RESET_DB=true DB_URI=postgresql://test:test@localhost:5432/test # Flask