Bug 453768 - file import error when path > MAX_PATH(260)
Summary: file import error when path > MAX_PATH(260)
Status: REPORTED
Alias: None
Product: digikam
Classification: Applications
Component: Import-Albums (show other bugs)
Version: unspecified
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-14 08:22 UTC by wodan71015
Modified: 2023-10-15 09:49 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description wodan71015 2022-05-14 08:22:38 UTC
STEPS TO REPRODUCE
1. create a file with long path: "\\\\?\UNC\\myserver\\pictures\\a\\b\\2022\\r\\3949f58a53d00e2da3b0a9de931123#food#carrot#fruit#soil#red#orange#green#bunny#food#carrot#fruit#soil#red#orange#green#bunny#food#carrot#fruit#soil#red#orange#green#bunny#food#carrot#fruit#soil#red#orange#green#bunny#.jpg"
2. import it

OBSERVED RESULT
digikam.dimg: Failed to open file  "//myserver/pictures/a/b/2022/r/3949f58a53d00e2da3b0a9de931123#food#carrot#fruit#soil#red#orange#green#bunny#food#carrot#fruit#soil#red#orange#green#bunny#food#carrot#fruit#soil#red#orange#green#bunny#food#carrot#fruit#soil#red#orange#green#bunny#.jpg"

EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows 10

ADDITIONAL INFORMATION
https://docs.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation
Comment 1 caulier.gilles 2022-05-14 08:45:07 UTC
Which digiKam version did you use ?
Comment 2 Maik Qualmann 2022-05-14 14:11:21 UTC
Which Windows build are you using exactly? It's possible that Qt on Windows is limited to 260 characters. Within digiKam we have no limit. Have you enabled long path support on Windows 10? Since Build 1607 long path support is possible, but by default it is 260 characters.

Maik
Comment 3 Maik Qualmann 2022-05-14 17:08:17 UTC
A test here with Windows 10 shows the following with activated long file name support: Windows Explorer still cannot support long file names, which corresponds to comments from the web. It is possible to create over 260 long file paths in digiKam. Files can also be copied. The Libjpeg, Exiv2 and ExifTool liberies cannot handle these long file paths. Images loaded with the QImage Loader do not have long path problems. So the problem is not Qt, but a multitude of different libraries. Since Windows Explorer currently doesn't support long file names either, I don't see the error as critical, but as normal.

Maik
Comment 4 caulier.gilles 2023-05-02 06:29:41 UTC
@wodan71015@duetube.com 

digiKam 8.0.0 is out. This entry still valid with this release ?

Best regards

Gilles Caulier
Comment 5 caulier.gilles 2023-10-15 09:49:26 UTC
@wodan71015@duetube.com,

This problem still reproducible with the new digiKam 8.2.0 pre-release Windows
installer available at usual place:

https://files.kde.org/digikam/

This new bundle is based on last Qt framework 5.15.11 and KDE framework 5.110.

Thanks in advance

Gilles Caulier