-
[BUGFIX] Fix "File name too long" error when a title is used as a folder name (#1479)
Some checks failedytld-sub CI (Linux) / test-lint (push) Has been cancelledytld-sub CI (Linux) / test-unit (push) Has been cancelledytld-sub CI (Windows) / test-unit (push) Has been cancelledytld-sub CI (Windows) / test-integration (push) Has been cancelledytld-sub CI (Windows) / test-integration-prebuilt-presets (push) Has been cancelledytld-sub CI (Windows) / test-e2e (push) Has been cancelledytld-sub CI (Linux) / test-integration (push) Has been cancelledytld-sub CI (Linux) / test-integration-prebuilt-presets (push) Has been cancelledytld-sub CI (Linux) / test-e2e (push) Has been cancelledytld-sub Docker GUI Build / version (push) Has been cancelledytld-sub Docker GUI Build / build (3.12) (push) Has been cancelledytld-sub Docker Ubuntu Build / version (push) Has been cancelledytld-sub Docker Ubuntu Build / build (3.12) (push) Has been cancelledytld-sub Docker Build / version (push) Has been cancelledytld-sub Docker Build / build (3.12) (push) Has been cancelledytld-sub Release / version (push) Has been cancelledytld-sub CI (Linux) / codecov-upload (push) Has been cancelledytld-sub Docker GUI Build / package-arm64 (push) Has been cancelledytld-sub Docker GUI Build / package-amd64 (push) Has been cancelledytld-sub Docker GUI Build / deploy (push) Has been cancelledytld-sub Docker Ubuntu Build / package-arm64 (push) Has been cancelledytld-sub Docker Ubuntu Build / package-amd64 (push) Has been cancelledytld-sub Docker Ubuntu Build / deploy (push) Has been cancelledytld-sub Docker Build / package-arm64 (push) Has been cancelledytld-sub Docker Build / package-amd64 (push) Has been cancelledytld-sub Docker Build / deploy (push) Has been cancelledytld-sub Release / build-linux (push) Has been cancelledytld-sub Release / build-windows (push) Has been cancelledytld-sub Release / github-release (push) Has been cancelledytld-sub Release / pypi-publish (push) Has been cancelledreleased this
2026-06-23 18:05:10 +02:00 | 0 commits to master since this releaseSome presets put the video title into a folder name (not just the file name). The code only shortened the file name, never the folder name. So a title with multi-byte characters (like bold/fancy Unicode, which take 4 bytes each) could make the folder name go over the OS 255-byte limit and crash with OSError: [Errno 36] File name too long.
This fix shortens every folder in the path too, not just the file name, while keeping the file extension. output_directory is left alone so real folders aren't touched.
Added a test with a title made of 4-byte bold Unicode characters.
-- Thanks @Nojyto for the contribution!
Downloads
-
Source code (ZIP)
0 downloads
-
Source code (TAR.GZ)
1 download
-
Source code (ZIP)