Skip to content

Commit 9ee9353

Browse files
committed
Improve pipe debug logs
1 parent fd5b2cc commit 9ee9353

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

inputremapper/configs/paths.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ def config_path() -> str:
4545
def chown(path):
4646
"""Set the owner of a path to the user."""
4747
try:
48+
logger.debug('Chown "%s", "%s"', path, UserUtils.user)
4849
shutil.chown(path, user=UserUtils.user, group=UserUtils.user)
4950
except LookupError:
5051
# the users group was unknown in one case for whatever reason

inputremapper/ipc/pipe.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ def __init__(self, path):
6767
PathUtils.mkdir(os.path.dirname(path))
6868

6969
if not os.path.exists(paths[0]):
70-
logger.debug('Creating new pipe for "%s"', path)
70+
logger.debug("Creating new pipes %s", paths)
7171
# The fd the link points to is closed, or none ever existed
7272
# If there is a link, remove it.
7373
if os.path.islink(paths[0]):
@@ -84,7 +84,7 @@ def __init__(self, path):
8484
os.symlink(f"{fds_dir}{self._fds[0]}", paths[0])
8585
os.symlink(f"{fds_dir}{self._fds[1]}", paths[1])
8686
else:
87-
logger.debug('Using existing pipe for "%s"', path)
87+
logger.debug("Using existing pipes %s", paths)
8888

8989
# thanks to os.O_NONBLOCK, readline will return b'' when there
9090
# is nothing to read

0 commit comments

Comments
 (0)