Skip to content

Commit

Permalink
load env first
Browse files Browse the repository at this point in the history
  • Loading branch information
bloombar committed Nov 25, 2023
1 parent 155ae9d commit eac37ef
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
from bson.objectid import ObjectId
from dotenv import load_dotenv

# instantiate the app
app = Flask(__name__)

# load credentials and configuration options from .env file
# if you do not yet have a file named .env, make one based on the template in env.example
load_dotenv() # take environment variables from .env.

# instantiate the app
app = Flask(__name__)

# # turn on debugging if in development mode
# if os.getenv("FLASK_ENV", "development") == "development":
# # turn on debugging, if in development
Expand Down Expand Up @@ -131,4 +131,4 @@ def handle_error(e):

# import logging
# logging.basicConfig(filename='/home/ak8257/error.log',level=logging.DEBUG)
app.run(port=FLASK_PORT, debug=True)
app.run(port=FLASK_PORT)

0 comments on commit eac37ef

Please sign in to comment.