File tree 2 files changed +4
-3
lines changed
2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 16
16
package_dir = {"" : "src" },
17
17
packages = ["cs50" ],
18
18
url = "https://github.com/cs50/python-cs50" ,
19
- version = "9.1 .0"
19
+ version = "9.2 .0"
20
20
)
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ def _enable_logging(f):
9
9
10
10
import logging
11
11
import functools
12
+ import os
12
13
13
14
@functools .wraps (f )
14
15
def decorator (* args , ** kwargs ):
@@ -19,9 +20,9 @@ def decorator(*args, **kwargs):
19
20
except ModuleNotFoundError :
20
21
return f (* args , ** kwargs )
21
22
22
- # Enable logging
23
+ # Enable logging in development mode
23
24
disabled = logging .getLogger ("cs50" ).disabled
24
- if flask .current_app :
25
+ if flask .current_app and os . getenv ( "FLASK_ENV" ) == "development" :
25
26
logging .getLogger ("cs50" ).disabled = False
26
27
try :
27
28
return f (* args , ** kwargs )
You can’t perform that action at this time.
0 commit comments