Bug 241585 - digikam hangs at 0% in editor when calling "Save as"
Summary: digikam hangs at 0% in editor when calling "Save as"
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Unclassified
Component: Database-Scan (show other bugs)
Version: 1.3.0
Platform: Compiled Sources Linux
: NOR major (vote)
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-12 22:38 UTC by eva
Modified: 2017-12-16 11:10 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.8.0


Attachments
backtrace (7.78 KB, text/plain)
2010-06-14 23:28 UTC, eva
Details

Note You need to log in before you can comment on or make changes to this bug.
Description eva 2010-06-12 22:38:09 UTC
Version:           1.3.0 (using KDE 4.4.3) 
OS:                Linux

This happens every now and then, not every time. I already had this seldomly since version 1.0 or so, but now it is every 5-10 images. I have to kill digikam and start editing all over. Nasty. 

Related to issue 233549? However, my case is somewhat different, because it happens at 0%

I also saw, that certain editor tools hang, maybe this is some multithreading issue in the first place?

Hint: I have tags set for all images.

Reproducible: Sometimes

Steps to Reproduce:
open images in editor, call save as
Comment 1 eva 2010-06-12 23:43:40 UTC
Here is debug output before it hangs. I added some more debug output below, which comes every few seconds when nothing happens:

digikam(20266)/digikam (core) Digikam::EditorToolThreaded::slotOk: Final  "Sharpen"  started...
digikam(20266)/digikam (core) Digikam::BlurFilter::gaussianBlurImage: BlurFilter::Process Computation...
digikam(20266)/digikam (core) Digikam::BlurFilter::gaussianBlurImage: BlurFilter::Finalization...
digikam(20266)/digikam (core) Digikam::EditorToolThreaded::slotFilterFinished: Final "Sharpen"  completed...
digikam(20266)/digikam (core) Digikam::DMetadata::setImageComments: ""  ==> Comment:  QMap()
digikam(20266)/digikam (core) Digikam::DMetadata::setImageRating: Rating value to write is out of range!
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2::setIptcKeywords:   ==> Iptc Keywords:  Paris
digikam(20266)/digikam (core) Digikam::EditorWindow::startingSaveAs: startSavingAs called
digikam(20266)/kio (KDirListerCache) KDirListerCache::listDir: Entry already in use: KUrl("trash:/")
digikam(20266)/kio (KDirListerCache) KDirListerCache::listDir: Entry already in use: KUrl("trash:/")
digikam(20266)/kio (KDirListerCache) KDirListerCache::listDir: Entry already in use: KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris")
digikam(20266)/kio (KIOJob) KIO::SlaveInterface::dispatch: error  111   "P1150565.JPG"
digikam(20266) KFileItemPrivate::init: "P1150565.JPG" does not exist anymore
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::setDialog: set dialog to  KFileDialog(0x9efeb968)
digikam(20266)/kio (KDirListerCache) KDirListerCache::listDir: Entry already in use: KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris")
digikam(20266)/kio (KDirListerCache) KDirListerCache::listDir: Entry already in use: KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris")
digikam(20266)/digikam (core) Digikam::EditorWindow::getWritingFilters: KImageIO offered pattern:  ("*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm|All Pictures", "*.bmp|Windows-BMP-Bild", "*.epsf *.epsi *.eps|EPS-Bild", "*.icb *.tga *.vst *.vda *.tpic|TGA-Bild", "*.j2k *.jp2 *.jpc *.jpf *.jpx|JPEG-2000-Bild", "*.jpeg *.jpe *.jpg|JPEG-Bild", "*.mng|MNG-Animation", "*.pbm|PBM-Bild", "*.pcx|PCX-Bild", "*.pgm|PGM-Bild", "*.png|PNG-Bild", "*.ppm|PPM-Bild", "*.rgb|RGB-Bild", "*.tiff *.tif|TIFF-Bild", "*.xbm|XBM-Bild", "*.xpm|XPM-Bild")
digikam(20266)/kio (KDirModel) KDirModelPrivate::_k_slotDeleteItems: No node found for item that was just removed: KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris/P1150592.RW2") 
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2::getImageDateTime: DateTime => Exif.Photo.DateTimeOriginal =>  QDateTime("Sa. Mai 15 13:30:08 2010")
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2Priv::printExiv2ExceptionError: Cannot find Exif key 'Exif.Sony2.LensID' into image using Exiv2   (Error # 6 :  Invalid key `Exif.Sony2.LensID'
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2::getImageDateTime: DateTime => Exif.Photo.DateTimeOriginal =>  QDateTime("Sa. Mai 15 13:30:08 2010")
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2Priv::printExiv2ExceptionError: Cannot find Exif key 'Exif.Sony2.LensID' into image using Exiv2   (Error # 6 :  Invalid key `Exif.Sony2.LensID'
digikam(20266)/kio (Slave) KIO::Slave::createSlave: createSlave "" for KUrl("P1150565.xpm")
digikam(20266)/kio (KIOConnection) KIO::ConnectionServer::listenForRemote: Listening on  "local:/tmp/ksocket-eva/digikamf20266.slave-socket"
digikam(20266): couldn't create slave: "Unable to create io-slave:
klauncher said: Unbekanntes Protokoll „“.
" 
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotFilterChanged: filter changed to ' "*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm" '
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotFilterChanged: use manual extension detection
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  "*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Using fallback format  0 
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::setAutoFilter: new auto filter is ' "*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm" '
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotFilterChanged: filter changed to ' "*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm" '
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotFilterChanged: use automatic extension detection
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  "P1150565.xpm"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "P1150565.xpm" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Using fallback format  0 
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  0
digikam(20266)/kio (KIOJob) KIO::SlaveInterface::dispatch: error  111   "P1150565.JPG"
digikam(20266) KFileItemPrivate::init: "P1150565.JPG" does not exist anymore
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  "P1150565.JPG"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "P1150565.JPG" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  1
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2::getImageDateTime: DateTime => Exif.Photo.DateTimeOriginal =>  QDateTime("Sa. Mai 15 13:30:08 2010")
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2Priv::printExiv2ExceptionError: Cannot find Exif key 'Exif.Sony2.LensID' into image using Exiv2   (Error # 6 :  Invalid key `Exif.Sony2.LensID'
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  "P1150565p.JPG"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "P1150565p.JPG" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  1
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  "P1150565pp.JPG"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "P1150565pp.JPG" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  1
digikam(20266)/kio (KIOJob) KIO::SlaveInterface::dispatch: error  111   "/home/Media/Fotos/1005_4_Paris/100515_Paris/P1150565pp.JPG"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  ""
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: filename ' "" ' does not contain an extension separated by a point.
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Using fallback format  0 
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  "/home/Media/Fotos/1004_2_garten/P1140075pp.jpg"
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "/home/Media/Fotos/1004_2_garten/P1140075pp.jpg" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  1
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileFormatChanged: Format selected:  ""
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Trying to discover format based on filename ' "" ', fallback =  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: filename ' "" ' does not contain an extension separated by a point.
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Using fallback format  0 
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::discoverFormat: Discovered format:  0
digikam(20266)/digikam (core) Digikam::FileSaveOptionsBox::slotImageFileSelected: called for filename  "file:///home/Media/Fotos/1005_4_Paris/100515_Paris/P1150565pp.JPG"
digikam(20266)/digikam (core) Digikam::EditorWindow::startingSaveAs: Writing file to  KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris/P1150565pp.JPG")
digikam(20266)/digikam (core) Digikam::EditorWindow::selectValidSavingFormat: Trying to find a saving format with filter =  "*.xpm *.pgm *.pbm *.rgb *.icb *.tga *.vst *.vda *.tpic *.ppm *.bmp *.epsf *.epsi *.eps *.j2k *.jp2 *.jpc *.jpf *.jpx *.mng *.tiff *.tif *.png *.jpeg *.jpe *.jpg *.pcx *.xbm" , targetUrl =  KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris/P1150565pp.JPG")
digikam(20266)/digikam (core) Digikam::EditorWindow::selectValidSavingFormat: KDE Offered types:  ("xpm", "pgm", "pbm", " rgb", "RGB", "rgba", "RGBA", "bw", "BW", "sgi", "SGI", "tga", "TGA", "xv", "ppm", "bmp", "eps", "EPS", "EPSI", "epsf", "EPSF", "jp2", "mng", "tiff", "tif", "png", "jpeg", "jpg", "pcx", "PCX", "xbm")
digikam(20266)/digikam (core) Digikam::EditorWindow::selectValidSavingFormat: Writable formats:  ("xpm", "pgm", "pbm", " rgb", "RGB", "rgba", "RGBA", "bw", "BW", "sgi", "SGI", "tga", "TGA", "xv", "ppm", "bmp", "eps", "EPS", "EPSI", "epsf", "EPSF", "jp2", "mng", "tiff", "tif", "png", "jpeg", "jpg", "pcx", "PCX", "xbm", "TIF", "TIFF", "JPG", "JPEG", "JPE", "J2K", "JP2", "PGF")
digikam(20266)/digikam (core) Digikam::EditorWindow::selectValidSavingFormat: Possible format from local file:  "JPG"
digikam(20266)/digikam (core) Digikam::EditorWindow::selectValidSavingFormat: Using format from target url  "JPG"
digikam(20266)/digikam (core) Digikam::DImgInterface::saveAs: Saving to : /home/Media/Fotos/1005_4_Paris/100515_Paris/r20266.digikamtempfile.tmp  ( "jpg" )
digikam(20266)/KEXIV2 KExiv2Iface::KExiv2Priv::printExiv2ExceptionError: Cannot set TIFF Thumbnail using Exiv2   (Error # 1 :  Exif.Image.NewSubfileType missing or not set as main image
digikam(20266)/digikam (core) Digikam::AlbumManager::slotDirWatchDirty: KDirWatch detected change at "/home/Media/Fotos/1005_4_Paris/100515_Paris"
digikam(20266)/kio (KDirListerCache) KDirListerCache::slotFileDirty: "/home/Media/Fotos/1005_4_Paris/100515_Paris"
digikam(20266)/kio (KDirListerCache) KDirListerCache::updateDirectory: KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris")
digikam(20266)/kio (KDirListerCache) KDirListerCache::updateDirectory: update started in KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris")
digikam(20266)/kio (KDirListerCache) KDirListerCache::slotUpdateResult: finished update KUrl("file:///home/Media/Fotos/1005_4_Paris/100515_Paris")


This is what comes every few seconds:

digikam(20266)/khtml (caret) DOM::Selection::moveTo: Selection[ Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) 1 ] Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 )
digikam(20266)/khtml (caret) DOM::Selection::validate: Selection[ Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) 1 ] 0
digikam(20266)/khtml (caret) DOM::Selection::validate: [character:baseIsStart] true Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 )
digikam(20266)/khtml (caret) DOM::Selection::moveTo: Selection[ Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 ) 1 ] Position( 0x0 "null" : 0 ) Position( 0x0 "null" : 0 )
Comment 2 Marcel Wiesweg 2010-06-13 15:25:52 UTC
Is it a freeze ( = UI unresponsive) or a hang (progress remains at 0% though UI is responsive, even if not functional)?

Can you attach gdb and give a backtrace when a hang occurs?
Comment 3 eva 2010-06-14 09:50:58 UTC
It hangs. With save I can select "file close" (it gives a dialog saying, that I can't close because an image is being saved...). As it doesn't crash a backtrace is not easy, that's why I attached the debug output. Is there a way to get a backtrace without crash? 

With tools I can press Esc. After that none of the tools works properly. Sometimes I still manage to save and I need to restart digikam. 
Somehow it seems to be in a strange stage.
Comment 4 Marcel Wiesweg 2010-06-14 18:56:25 UTC
> As it doesn't crash a
> backtrace is not easy, that's why I attached the debug output. Is there a way
> to get a backtrace without crash? 

Yes there is. Produce the hang. Then find out the process id of digikam, e.g. with ps -ax. Then in the console, type "gdb att <processid>", let gdb attach itself, then type "bt" and you have the backtrace. Press q to exit gdb.
Comment 5 eva 2010-06-14 23:28:47 UTC
Created attachment 48015 [details]
backtrace

backtrace of all running threads while hanging
Comment 6 Marcel Wiesweg 2010-06-15 14:54:39 UTC
Thanks. Is the file properly written? At least the dir watch indicates a change in the directory. So after you restart digikam, is the file there?
Comment 7 eva 2010-06-15 22:37:04 UTC
yes, it's there. indeed. 

I am not sure this is always the case. I think I had to reedit it sometimes.
Comment 8 caulier.gilles 2010-10-06 15:54:34 UTC
Eva, Can you try digiKam 1.4.0 ?

Gilles Caulier
Comment 9 eva 2010-10-17 21:30:31 UTC
I upgraded to current trunk yesterday. It took a lot longer lately, but just now it happened again :-(
Comment 10 caulier.gilles 2010-11-24 09:09:32 UTC
digiKam 1.6.0 is out:

http://www.digikam.org/drupal/node/550

Please update and check if this entry still valid.

Thanks in advance

Gilles Caulier
Comment 11 eva 2010-12-11 19:07:01 UTC
The issue happens much less often. But it just happened again. I am using trunk. 

Maybe I can give you some hints:
What I did differently in this moment was the following:
- edit the image, using a number of tools (contrast, saturation, noice reduction) 
- then I changed the rating
- I used "save as..."

usually I change the rating afterwards. Also noice reduction is a tool I rarely use. 

Best,
Eva
Comment 12 Marcel Wiesweg 2011-01-17 15:25:10 UTC
Still dont know what's happening here.
In any case, large parts have been changed in that area for 2.0, so chances are the bug is gone.
Comment 13 caulier.gilles 2011-07-06 11:25:03 UTC
We need feedback using a recent version. 2.0.0 RC is out, please test...

Thanks in advance

Gilles Caulier
Comment 14 Marcel Wiesweg 2011-09-25 13:31:42 UTC
Please reopen if still applicable with a recent 2.x version
Comment 15 caulier.gilles 2017-12-16 11:10:10 UTC
This crash is not reproducible use current 5.8.0 pre-release bundle available
here :

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

I close this file now. Re-open it if necessary.

Gilles Caulier