Bug 204006 - Automatic renaming of duplicate filenames while importing
Summary: Automatic renaming of duplicate filenames while importing
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: AdvancedRename-Import (show other bugs)
Version: 0.10.0
Platform: unspecified Linux
: NOR wishlist
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-16 02:31 UTC by andrew
Modified: 2016-11-21 16:13 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.4.0


Attachments
attachment-9528-0.html (827 bytes, text/html)
2016-07-18 22:29 UTC, andrew
Details

Note You need to log in before you can comment on or make changes to this bug.
Description andrew 2009-08-16 02:31:59 UTC
Version:           0.10.0 (using 4.3.00 (KDE 4.3.0), Chakra KDE)
Compiler:          gcc
OS:                Linux (i686) release 2.6.30-ARCH

One thing I just noticed about my new Nikon camera is that it re-uses filenames.  In practice this means that after each time you format your media you will get photos with the same name.  Combine that with date based folders in your collection and things get difficult - if for example you fill your media multiple times in a day, which I have been doing :-(

At the moment the download task in digikam stops when a download would cause a file to be overwritten.  What I would like would be the option to automatically rename (instead of just the usual skip, abort etc).  Just adding a single character prefix or suffix would do the job and prevent me having to drop back to a shell to do this.

A slightly more sophisticated variation on this might analyse the image (metadata and or thumbnails) to see if the image appeared to be the same as the one already on disk and automatically rename whenever the images are different; prompting if they appeared to be the same image.
Comment 1 caulier.gilles 2011-08-10 14:04:50 UTC
Andrew,

Can you reproduce the problem using last digiKam 2.0.0 ?

Gilles Caulier
Comment 2 andrew 2011-08-11 01:01:41 UTC
On 08/11/2011 12:04 AM, Gilles Caulier wrote:
> https://bugs.kde.org/show_bug.cgi?id=204006
>
>
>
>
>
> --- Comment #1 from Gilles Caulier<caulier gilles gmail com>   2011-08-10 14:04:50 ---
> Andrew,
>
> Can you reproduce the problem using last digiKam 2.0.0 ?
>
> Gilles Caulier

I'm afraid I gave up on KDE about a year ago... was spending as much (or 
more) time reporting bugs as using.
Comment 3 caulier.gilles 2011-08-12 10:17:08 UTC
Andrew,

Please, take a look in this entry:

https://bugs.kde.org/show_bug.cgi?id=257806

...and let's me hear if it's the same problem. Look like user from #257806 provide a patch.

Gilles Caulier
Comment 4 andrew 2011-08-12 13:09:19 UTC
On 08/12/2011 08:17 PM, Gilles Caulier wrote:
> --- Comment #3 from Gilles Caulier<caulier gilles gmail com>   2011-08-12 10:17:08 ---
> Andrew,
>
> Please, take a look in this entry:
>
> https://bugs.kde.org/show_bug.cgi?id=257806
>
> ...and let's me hear if it's the same problem. Look like user from #257806
> provide a patch.
>
That bug is a different problem.  In that case duplicate images are 
downloaded because the camera has redundant storage.  In my bug the 
problem was that new (non-redundant) images could not be downloaded if 
they had  the same file name (and destination folder) as a previously 
imported image.

Cheers,
A
Comment 5 caulier.gilles 2011-08-12 13:35:58 UTC
As Petri said in #257806 :

"Nikon D7000 has two card slots. Another card can be selected to be a backup of
the first card. When photos are imported they are imported from both cards
producing a duplicate of every photo."

It's strange that your NIKON camera provide duplicates file as well, excepted if it's a gphoto2 camera driver problem.

Are you sure that it's not the same problem here ?

Anyway, as the side effect is to have duplicate entries in icon view, Petri provide a patch in #257806 to solve the problem + some improvements to filter icon view contents.

This patch can solve your problem...

Gilles Caulier
Comment 6 andrew 2011-08-12 14:17:13 UTC
On 08/12/2011 11:35 PM, Gilles Caulier wrote:
> --- Comment #5 from Gilles Caulier<caulier gilles gmail com>   2011-08-12 13:35:58 ---
> As Petri said in #257806 :
>
> "Nikon D7000 has two card slots. Another card can be selected to be a backup of
> the first card. When photos are imported they are imported from both cards
> producing a duplicate of every photo."
>
> It's strange that your NIKON camera provide duplicates file as well, excepted
> if it's a gphoto2 camera driver problem.
>
> Are you sure that it's not the same problem here ?
>
> Anyway, as the side effect is to have duplicate entries in icon view, Petri
> provide a patch in #257806 to solve the problem + some improvements to filter
> icon view contents.
>
> This patch can solve your problem...
>
> Gilles Caulier

There is one other difference that I should perhaps point out.  In 
Petri's case the redundant photos were downloaded together - they exist 
on the camera together.  I assume they had different names or they would 
have cause the same problem as in my bug.

In my case, duplicate filenames were created as a result of reformating 
the memory card between shoots on the same day.  The duplicates are not 
on the camera.  In my case I need the downloader to notice that files 
with the same names but different sizes (or checksums) already exist on 
the computer in the destination folder, and do some automatic renaming 
during download.

So despite your optimism I don't believe this patch is not relevant to 
my bug.

Thanks for paying it some attention though :-)
Comment 7 caulier.gilles 2011-12-18 14:14:10 UTC
Andrew,

Please review digiKam 2.4 and look if something is missing accordingly to this entry

Gilles Caulier
Comment 8 Teemu Rytilahti 2013-12-05 01:15:11 UTC
Still valid?
Comment 9 caulier.gilles 2014-09-01 08:40:55 UTC
Andrew,

Can you test with last digiKam 4.2.0 ?

Gilles Caulier
Comment 10 caulier.gilles 2015-06-28 09:42:11 UTC
New digiKam 4.11.0 is available :

https://www.digikam.org/node/740

Can you reproduce the problem with this release ?

Gilles Caulier
Comment 11 caulier.gilles 2016-07-15 18:39:38 UTC
Andrew,

Can you test with last digiKam 5.0.0 ?

Gilles Caulier
Comment 12 andrew 2016-07-18 22:29:50 UTC
Created attachment 100161 [details]
attachment-9528-0.html

Sorry no, stopped using this software years ago.

On 16/07/2016 4:39 am, "via KDE Bugzilla" <bugzilla_noreply@kde.org> wrote:

> https://bugs.kde.org/show_bug.cgi?id=204006
>
> --- Comment #11 from caulier.gilles@gmail.com ---
> Andrew,
>
> Can you test with last digiKam 5.0.0 ?
>
> Gilles Caulier
>
> --
> You are receiving this mail because:
> You reported the bug.
>
Comment 13 caulier.gilles 2016-07-19 07:11:08 UTC
Maik,

As with BQM, do you fix the behavior to ask to use a new name in Import GUI ? I want mean to have an automatic renaming if target file already exists in collection while downloading from camera...

I remember that you have implemented something like that when we drop KDE rename dialog dependency while Qt5 port

Gilles Caulier
Comment 14 caulier.gilles 2016-11-21 16:13:08 UTC
Since 5.0.0, as with BQM, the renaming of downloaded file from camera is done automatically without to prompt user.

Gilles Caulier