Update src/PIL/ImageFont.py

Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
This commit is contained in:
Yngve Mardal Moe 2024-09-11 14:54:53 +02:00 committed by GitHub
parent 77503156b1
commit 32c514d24c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -932,7 +932,7 @@ def load_path(filename: str | bytes) -> ImageFont:
return load(os.path.join(directory, filename))
except OSError:
pass
msg = f"cannot find font file '{filename}' in sys.path"
msg = f'cannot find font file "{filename}" in sys.path'
if os.path.exists(filename):
msg += f', did you mean ImageFont.load("{filename}") instead?'