Skip to content

Commit a4cd2bc

Browse files
authored
revert property to variable (#35)
1 parent 01d83e5 commit a4cd2bc

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

src/whisper_api/log_setup.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ def __init__(self, log_pipe: Connection, log_dir: str, log_file: str, **rotating
6262

6363
super().__init__(self.log_path, **rotating_file_handler_kwargs)
6464
self.log_pipe = log_pipe
65+
self.am_I_main = multiprocessing.current_process().name == "MainProcess"
6566

6667
if multiprocessing.current_process().name == "MainProcess":
6768
# start listening for logs from children
@@ -71,10 +72,6 @@ def __init__(self, log_pipe: Connection, log_dir: str, log_file: str, **rotating
7172
atexit.register(self.wait_for_listener)
7273
self.is_end = False
7374

74-
@property
75-
def am_I_main(self):
76-
return multiprocessing.current_process().name == "MainProcess"
77-
7875
def wait_for_listener(self):
7976
"""Ensure that we wait for thread when we shall exit"""
8077
# well, we won't try to use the logger when waiting for logging to be finished :)

0 commit comments

Comments
 (0)