Bug 389657 - QFile::rename: Empty or null file name
Summary: QFile::rename: Empty or null file name
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: AdvancedRename-file (show other bugs)
Version: 5.8.0
Platform: Appimage Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-30 20:31 UTC by Nicolas.HOUDELOT
Modified: 2022-01-31 21:57 UTC (History)
2 users (show)

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


Attachments
error i get (11.58 KB, image/png)
2018-01-30 20:31 UTC, Nicolas.HOUDELOT
Details
screenshot of the renaming (47.77 KB, image/png)
2018-01-30 20:35 UTC, Nicolas.HOUDELOT
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolas.HOUDELOT 2018-01-30 20:31:04 UTC
Created attachment 110230 [details]
error i get

Sometime,s it's impossible to rename the files.
Digikam tell me that image with name "", cannot be renamed
The error does not happen all the time.

but preview works, and even adding tags.
even after moving the files, it doesn't change anything.
(error present from digikam 5.5 through digikam 5.8)


here is the log file :
digikam.general: Selected URLs to rename:  (QUrl("file:///media/NAS/archives/archives_amisinternet/CBU/Belgacom_CBU4U.jpg"), QUrl("file:///media/NAS/archives/archives_amisinternet/CBU/Belgacom_CBU4U2.jpg"), QUrl("file:///media/NAS/archives/archives_amisinternet/CBU/Belgacom1.jpg"))
digikam.general: QUrl("file:///media/NAS/archives/archives_amisinternet/CBU/Belgacom_CBU4U.jpg")
digikam.general: QUrl("file:///media/NAS/archives/archives_amisinternet/CBU/Belgacom_CBU4U2.jpg")
digikam.general: QUrl("file:///media/NAS/archives/archives_amisinternet/CBU/Belgacom1.jpg")
digikam.database: No itemShortInfo could be retrieved from the database for image "Belgacom_CBU4U.jpg"
digikam.general: Using  8  CPU core to run threads
digikam.general: Using  8  CPU core to run threads
digikam.general: Action Thread run  1  new jobs
digikam.general: Action Thread run  1  new jobs
digikam.iojob: Destination Url: QUrl("2002-10-16_21-15-09.jpg")
digikam.iojob: Destination Url: QUrl("file:.xmp")
digikam.iojob: Trying to rename "" to ""
digikam.iojob: Trying to rename "" to ".xmp"
QFile::rename: Empty or null file name
QFile::rename: Empty or null file name
digikam.iojob: File couldn't be renamed!
digikam.iojob: File couldn't be renamed!
Comment 1 Nicolas.HOUDELOT 2018-01-30 20:34:40 UTC
forgot to give the rename pattern
[meta:Exif.Image.DateTime]{replace:":","-"}{replace:" ","_"}{unique}.[ext]{lower}
Comment 2 Nicolas.HOUDELOT 2018-01-30 20:35:17 UTC
Created attachment 110231 [details]
screenshot of the renaming
Comment 3 Maik Qualmann 2018-01-30 20:41:39 UTC
The empty file names come from the invisible sidecar files. You have enabled sidecar files? The question is, why is the file name of the sidecar files empty?

Maik
Comment 4 Nicolas.HOUDELOT 2018-01-30 21:15:25 UTC
no it's not enabled.
i saw that and checked if it was. but no.

long time ago i tested sidecar files, but deactivate it.

right now i just activate/deactivate, in case there's a reset to do in config files, but it didn't change anything
Comment 5 Maik Qualmann 2018-01-30 21:20:50 UTC
> digikam.iojob: Destination Url: QUrl("2002-10-16_21-15-09.jpg")

The next question is why here is a file:/ missing in the QUrl. This causes the URL to be considered non-local. We have a special function here at the renaming, which we actually do not need any more in the treatment of remote files.

Maik
Comment 6 Nicolas.HOUDELOT 2018-01-30 22:00:55 UTC
in fact, it seems that i can't rename on the entire collection.
even on a single file Belgacom_CBU4U2.jpg => Belgacom_CBU4U2_.jpg

but on another collection, it's working without any problem.
and there is no empty sidecar files on the log
(both are considered as local collection)

is there a possibility that there's an old configuration remaining ?

i'm still having digikam 4, from my distribution. As i often have problems with upgrades. (thumbnails disappear, sql migrations fails, etc..)

i dropped the sql database sooner, to restart from a fresh install.
so collections are brand new in the database.
Comment 7 caulier.gilles 2018-08-29 07:52:19 UTC
The AppImage Linux Bundle have been recompiled with last changes from source code and is available here for testing :

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

Take a care : 6.0.0 is a beta release for the moment. Make a database backup before to test.

Problem still here ?

Gilles Caulier
Comment 8 caulier.gilles 2019-03-20 15:16:06 UTC
After 3 weeks of work, i finally completed the compilation of AppImage using Qt
5.11.3 + QWebkit 5.212.

New 6.1.0 pre-release AppImage bundle can be found here (64 bits only for the
moment) :

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

Please check if this bugzilla entry still valid.

Thanks in advance

Gilles Caulier
Comment 9 Nicolas.HOUDELOT 2019-04-16 22:55:52 UTC
hello
the problem seems to be solved on the 6.1 beta version (appimage)
Comment 10 Nicolas.HOUDELOT 2019-07-24 14:05:21 UTC
resolved in 6.2 beta for me