lib.FileContext: Interpolate path in _is_dir()

_is_dir() logs a DEBUG message when _stat() is not implemented and it
must guess from the trailing slash whether a path is a directory. The
second part of that message is a plain string rather than an f-string,
so '{path}' is logged verbatim instead of the path.

Make it an f-string so the path is interpolated.

Assisted-by: unsloth/Qwen3.8-27B-GGUF:Q4_K_M with pi.dev v0.84.2
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2026-08-16 06:57:17 +02:00
commit 5230b44fa8
Signed by: Jan Lindemann
GPG key ID: 3750640C9E25DD61

View file

@ -287,7 +287,7 @@ class FileContext(abc.ABC):
DEBUG,
(
f"{self.log_name} doesn't implement stat(), judging by trailing "
'slash if {path} is a directory'
f'slash if {path} is a directory'
),
)
return path[-1] == '/'