Skip to content

Commit

Permalink
Update app.py
Browse files Browse the repository at this point in the history
  • Loading branch information
sondregronas committed Jul 26, 2024
1 parent 95a890a commit 6e37798
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions BookingSystem/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,8 @@ def debug_login() -> flask.Response:
# We need to create an app object for gunicorn to use with the routine tasks only running on the main thread, not the
# workers. But since gunicorn doesn't run on Windows we need to catch the exception and run the app normally
try:
if os.environ.get('TESTING', 'false').lower() == 'true':
raise Exception('Testing environment, skipping gunicorn')
import gunicorn.app.base


Expand Down

0 comments on commit 6e37798

Please sign in to comment.