Its better to have _LOG_PATH than _CWD
This commit is contained in:
parent
22611b6444
commit
47378715d0
1 changed files with 2 additions and 2 deletions
4
vigil
4
vigil
|
|
@ -63,12 +63,12 @@ import termstr
|
|||
import tools
|
||||
|
||||
|
||||
_CWD = os.getcwd()
|
||||
_LOG_PATH = os.path.join(os.getcwd(), "vigil.log")
|
||||
|
||||
|
||||
def _log_error(message=None):
|
||||
message = traceback.format_exc() if message is None else message + "\n"
|
||||
with open(os.path.join(_CWD, "vigil.log"), "a") as log_file:
|
||||
with open(_LOG_PATH, "a") as log_file:
|
||||
log_file.write(message)
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue