👷 Hacky workaround marked with TODO.

This commit is contained in:
Robert Honz
2024-04-21 19:16:13 +02:00
parent 67166861e9
commit 78670a38ba
+1 -1
View File
@@ -209,7 +209,7 @@ def path_file_sanitize(path_file: str, adapt: bool = False, uniquify: bool = Fal
# TODO: Implement proper exception handling and logging. # TODO: Implement proper exception handling and logging.
# print(e) # print(e)
# Hacky stuff, since the sanitizing function does not shorten the filename somehow (bug?) # Hacky stuff, since the sanitizing function does not shorten the filename somehow (bug?)
# Remove after pathvalidate update. # TODO: Remove after pathvalidate update.
# If filename too long # If filename too long
if e.description.startswith("[PV1101]"): if e.description.startswith("[PV1101]"):
byte_ct: int = len(filename.encode("utf-8")) - 255 byte_ct: int = len(filename.encode("utf-8")) - 255