Bug 341594 - hangs when trying to access a directory containing 1GB AVI file
Summary: hangs when trying to access a directory containing 1GB AVI file
Status: REPORTED
Alias: None
Product: gwenview
Classification: Applications
Component: general (show other bugs)
Version: Other (add details in bug description)
Platform: Debian unstable Linux
: NOR grave
Target Milestone: ---
Assignee: Gwenview Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-12-06 02:22 UTC by Ki Yung Ahn
Modified: 2022-11-10 16:10 UTC (History)
10 users (show)

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


Attachments
attachment-10051-0.html (1.67 KB, text/html)
2014-12-07 00:31 UTC, Ki Yung Ahn
Details
attachment-10336-0.html (2.29 KB, text/html)
2014-12-07 00:35 UTC, Ki Yung Ahn
Details
attachment-10474-0.html (2.97 KB, text/html)
2014-12-07 00:42 UTC, Ki Yung Ahn
Details
attachment-10816-0.html (3.77 KB, text/html)
2014-12-07 00:56 UTC, Ki Yung Ahn
Details
Log of Gwenview starting in teminal session then froze (4.62 KB, text/plain)
2015-06-23 16:35 UTC, Maurice Batey
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ki Yung Ahn 2014-12-06 02:22:59 UTC
Hangs (freezes) when trying to access a directory with more than 1000 image files.
Same result when trying to access open indivdidual image file in that directory.

I'm using gwenview version:
Qt: 4.8.6
KDE Development Platform: 4.14.2
Gwenview: 4.14.0 pre

Running "uname -a" output:
Linux kyahp 3.16.0-4-amd64 #1 SMP Debian 3.16.7-2 (2014-11-06) x86_64 GNU/Linux

Reproducible: Always

Steps to Reproduce:
1. open a directory (or file in that directory) with thousands of image files

Actual Results:  
All UI just freeze no refersh. If you overlap with other window, then the gewnview window content becomes just blank background color.

Expected Results:  
It should not hang as it used to be.
Comment 1 Imran Tatriev 2014-12-06 14:03:32 UTC
Comment by a GCI student:
Hi, Ki Yung Ahn! I tried to reproduce your bug and it worked fine for me even with more than 1000 images. I tried many different ways to open directory with images/individual file, but all worked just fine. Can you provide more information: How much RAM do you have? Have you tried to reproduce this bug on another computer?
Comment 2 Ki Yung Ahn 2014-12-07 00:31:53 UTC
Created attachment 89849 [details]
attachment-10051-0.html

In fact, I just rebooted and it started to work again. After that I was not
able to reproduce it. Thanks.

2014-12-06 6:03 GMT-08:00 Imran Tatriev <itatriev@gmail.com>:

> https://bugs.kde.org/show_bug.cgi?id=341594
>
> Imran Tatriev <itatriev@gmail.com> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>                  CC|                            |itatriev@gmail.com
>
> --- Comment #1 from Imran Tatriev <itatriev@gmail.com> ---
> Comment by a GCI student:
> Hi, Ki Yung Ahn! I tried to reproduce your bug and it worked fine for me
> even
> with more than 1000 images. I tried many different ways to open directory
> with
> images/individual file, but all worked just fine. Can you provide more
> information: How much RAM do you have? Have you tried to reproduce this
> bug on
> another computer?
>
> --
> You are receiving this mail because:
> You reported the bug.
>
Comment 3 Ki Yung Ahn 2014-12-07 00:35:33 UTC
Created attachment 89851 [details]
attachment-10336-0.html

Wait, I just reproduced it. It worked for once after the reboot and it
starts to hang again at that directory :(

2014-12-06 16:31 GMT-08:00 Ahn, Ki Yung <kyagrd@gmail.com>:

> In fact, I just rebooted and it started to work again. After that I was
> not able to reproduce it. Thanks.
>
> 2014-12-06 6:03 GMT-08:00 Imran Tatriev <itatriev@gmail.com>:
>
> https://bugs.kde.org/show_bug.cgi?id=341594
>>
>> Imran Tatriev <itatriev@gmail.com> changed:
>>
>>            What    |Removed                     |Added
>>
>> ----------------------------------------------------------------------------
>>                  CC|                            |itatriev@gmail.com
>>
>> --- Comment #1 from Imran Tatriev <itatriev@gmail.com> ---
>> Comment by a GCI student:
>> Hi, Ki Yung Ahn! I tried to reproduce your bug and it worked fine for me
>> even
>> with more than 1000 images. I tried many different ways to open directory
>> with
>> images/individual file, but all worked just fine. Can you provide more
>> information: How much RAM do you have? Have you tried to reproduce this
>> bug on
>> another computer?
>>
>> --
>> You are receiving this mail because:
>> You reported the bug.
>>
>
>
>
> --
> Ahn, Ki Yung
>
Comment 4 Ki Yung Ahn 2014-12-07 00:42:51 UTC
Created attachment 89852 [details]
attachment-10474-0.html

I tried to reproduce it in another directory by copying all its image files
but failed. It doesn't seem to be number of files. There is some other
reason. I'll update the bug report once I can guess the reason

2014-12-06 16:35 GMT-08:00 Ahn, Ki Yung <kyagrd@gmail.com>:

> Wait, I just reproduced it. It worked for once after the reboot and it
> starts to hang again at that directory :(
>
> 2014-12-06 16:31 GMT-08:00 Ahn, Ki Yung <kyagrd@gmail.com>:
>
> In fact, I just rebooted and it started to work again. After that I was
>> not able to reproduce it. Thanks.
>>
>> 2014-12-06 6:03 GMT-08:00 Imran Tatriev <itatriev@gmail.com>:
>>
>> https://bugs.kde.org/show_bug.cgi?id=341594
>>>
>>> Imran Tatriev <itatriev@gmail.com> changed:
>>>
>>>            What    |Removed                     |Added
>>>
>>> ----------------------------------------------------------------------------
>>>                  CC|                            |itatriev@gmail.com
>>>
>>> --- Comment #1 from Imran Tatriev <itatriev@gmail.com> ---
>>> Comment by a GCI student:
>>> Hi, Ki Yung Ahn! I tried to reproduce your bug and it worked fine for me
>>> even
>>> with more than 1000 images. I tried many different ways to open
>>> directory with
>>> images/individual file, but all worked just fine. Can you provide more
>>> information: How much RAM do you have? Have you tried to reproduce this
>>> bug on
>>> another computer?
>>>
>>> --
>>> You are receiving this mail because:
>>> You reported the bug.
>>>
>>
>>
>>
>> --
>> Ahn, Ki Yung
>>
>
>
>
> --
> Ahn, Ki Yung
>
Comment 5 Ki Yung Ahn 2014-12-07 00:56:05 UTC
Created attachment 89853 [details]
attachment-10816-0.html

I finally figured out what is causing the hang.

There was 1GB avi file in that directory with a bunch of images. When I
moved that movie file to another directory it started to work.

However, I think this is a serious bug that should be fixed. It shouldn't
hang trying to meaninglessly process one gigantic AVI file.

2014-12-06 16:42 GMT-08:00 Ahn, Ki Yung <kyagrd@gmail.com>:

> I tried to reproduce it in another directory by copying all its image
> files but failed. It doesn't seem to be number of files. There is some
> other reason. I'll update the bug report once I can guess the reason
>
> 2014-12-06 16:35 GMT-08:00 Ahn, Ki Yung <kyagrd@gmail.com>:
>
> Wait, I just reproduced it. It worked for once after the reboot and it
>> starts to hang again at that directory :(
>>
>> 2014-12-06 16:31 GMT-08:00 Ahn, Ki Yung <kyagrd@gmail.com>:
>>
>> In fact, I just rebooted and it started to work again. After that I was
>>> not able to reproduce it. Thanks.
>>>
>>> 2014-12-06 6:03 GMT-08:00 Imran Tatriev <itatriev@gmail.com>:
>>>
>>> https://bugs.kde.org/show_bug.cgi?id=341594
>>>>
>>>> Imran Tatriev <itatriev@gmail.com> changed:
>>>>
>>>>            What    |Removed                     |Added
>>>>
>>>> ----------------------------------------------------------------------------
>>>>                  CC|                            |itatriev@gmail.com
>>>>
>>>> --- Comment #1 from Imran Tatriev <itatriev@gmail.com> ---
>>>> Comment by a GCI student:
>>>> Hi, Ki Yung Ahn! I tried to reproduce your bug and it worked fine for
>>>> me even
>>>> with more than 1000 images. I tried many different ways to open
>>>> directory with
>>>> images/individual file, but all worked just fine. Can you provide more
>>>> information: How much RAM do you have? Have you tried to reproduce this
>>>> bug on
>>>> another computer?
>>>>
>>>> --
>>>> You are receiving this mail because:
>>>> You reported the bug.
>>>>
>>>
>>>
>>>
>>> --
>>> Ahn, Ki Yung
>>>
>>
>>
>>
>> --
>> Ahn, Ki Yung
>>
>
>
>
> --
> Ahn, Ki Yung
>
Comment 6 rlaggren 2014-12-10 02:58:23 UTC
Linux 3.16.6-2-desktop
openSUSE 13.2 (Harlequin) (x86_64)
kde 4.14.3

Gwenview
Version 4.14.0 pre
Using KDE Development Platform 4.14.3

AMD Phenom(tm) II X6 1055T Processor
4GB ram
Gigabyte mobo (I'll dig out the model if needed)
Terrabyte standard harddrive
----------------------------------------------------------------------
ext4 file system
Directory has 2500 files, 33 dirs, 38GB used. 
All image/vid files less than 600MB
A couple dmg files (CAD, I think) about 950MB

Same problem. Intermittent.  Gwenview can be started OK but as soon as you enter that directory it hangs - before any file has been selected (in fact it hangs before displaying file list).  When starting from clicking on a file in Dolphin file manager it displays the file then hangs (the gui is dead). One processor always goes 100% and stays there.  

Rufus
Comment 7 Gordon 2014-12-28 15:32:39 UTC
Same problem here.

Environment = OpenSUSE 13.2, KDE 4.14.3, Gwenview 4.14.0 pre.

Gwinview will hang every time if a directory is opened that has ***any*** AVI or WMV files of any size. Tested with AVI/WMV files as small as 10MB.

This needs to be fixed ASAP!

Thanks,

Gordon
Comment 8 madworm_de.kde 2015-04-06 22:00:54 UTC
Same here: openSUSE 13.2 + KDE
Comment 9 Maurice Batey 2015-06-23 14:55:30 UTC
I have the same kind of problem here on 64-bit KDE Mageia-5, with Gwenview 4.14.3:

(Photo library in /photos, which has master folder /mypictures containing 203 sub-folders and over 5,000 .jpg files (+ a handful of video clips).

Gwenview freezes as soon as any access to folder is attempted.

(No problem with Gwenview 4.12.2 on Mageia-4.)

rpm -qif /usr/bin/gwenview
Name        : gwenview
Epoch       : 2
Version     : 4.14.3
Release     : 2.mga5
Architecture: x86_64
Install Date: Sun 21 Jun 2015 13:46:03 BST
Group       : Graphics/Viewers
Size        : 877111
License     : GPLv2
Signature   : RSA/SHA1, Mon 18 May 2015 21:50:16 BST, Key ID b742fa8b80420f66
Source RPM  : gwenview-4.14.3-2.mga5.src.rpm
Build Date  : Mon 18 May 2015 21:44:14 BST
Build Host  : ecosse.mageia.org
Relocations : (not relocatable)
Packager    : ennael <ennael>
Vendor      : Mageia.Org
URL         : http://www.kde.org
Comment 10 Maurice Batey 2015-06-23 16:35:12 UTC
Created attachment 93305 [details]
Log of Gwenview starting in teminal session then froze
Comment 11 Maurice Batey 2015-06-23 16:38:04 UTC
Have attached 'Log of Gwenview starting'  on 32-bit KDE Mageia-5 - see above
Comment 12 Maurice Batey 2015-06-23 17:39:36 UTC
> Have attached 'Log of Gwenview starting' on 32-bit KDE Mageia-5 - see above

That was on 32-bit Mageia-5 on laptop, with similar photo library:

  1st time: Worked perfectly!
  2nd & subsequent times: Froze, at different stages...
Comment 13 Maurice Batey 2015-06-24 15:23:44 UTC
I have tried with the Gwenview 'delete thumbnails on exit' option selected.
Made no difference. 
  After doing /gwenview /photos/mypictures, gwenview displayed all 203 subfolders, but no thumbnails visible, and the app was totally unresponsive. Had to force exit.
  Checked ~/.thumbnails several times during freeze:  Always empty.
Comment 14 Maurice Batey 2015-06-24 15:28:09 UTC
> After doing /gwenview ...

  Oops, sorry:  Superfluous  '/'  there.
Comment 15 Angelo Naselli 2015-06-24 16:14:50 UTC
Maurice your log has three errors:
Error: XMP Toolkit error 203: Duplicate property or field node
Warning: Failed to decode XMP metadata.
[...]
Error: Upper boundary of data for directory Pentax, entry 0x002e is out 
of bounds: Offset = 0x000006a6, size = 494, exceeds buffer size by 240 
Bytes; truncating the entry
[...]
Error: Directory Samsung2 with 55551 entries considered invalid; not 
read.
Last us very odd, if as you said in mageia bug you have less photos.
Try to understand what are the offending picture or directory, and that maybe can help
developers to find a solution to your problem
Comment 16 Maurice Batey 2015-06-24 17:02:40 UTC
> Error: Directory Samsung2 with 55551 entries considered invalid; not read.
> Last us very odd, if as you said in mageia bug you have less photos. 

Exactly, 5,500+ rather than 55.551+!
And where is "directory Samsung2"?

> Try to understand what are the offending picture or directory, and that maybe 
> can help developers to find a solution to your problem

Given 203 subfolders and 5,500+ files, that is the veritable needle in a haystack!
It may not be *any* of the folders or files - just the quantity?
  The really odd thing is that occasionally it works - perfectly, yet mostly it's locked up.
(And when it's locked up there are no thumbnails in ~/.thumbnails, so perhaps that's a red herring.
I.e. it locks up before generating thumbnails.)
Comment 17 Maurice Batey 2015-06-24 17:07:16 UTC
> Try to understand what are the offending picture or directory,

Perhaps this bug report's Subject line holds a clue ("1GB AVI file")?

What changes have been made since Version 4.12.2?
  That's where the regression presumably happened.crept in.
Comment 18 Maurice Batey 2015-06-24 17:49:58 UTC
I have run an strace of the call on gwenview that freezes.

Can be seen here:
      https://dl.dropboxusercontent.com/u/10969499/gwenview-strace.txt

(Too big to Attach, I think)
Comment 19 Maurice Batey 2015-06-26 16:13:23 UTC
> Perhaps this bug report's Subject line holds a clue ("1GB AVI file")?

I have now identified the 1 file in 5,5500+ that was screwing gwenview 4.14.3 here on Mageia-5:
   "TaleofTwoBrains.wmv"
 
No problem if given to gwenview directly (runs the video),  but if is in a directory and that given to gwenview, it freezes with an empty window.

Having removed that one file from my 5,500+ file photo library (containing 203 sub-folders, some with .MOV video clips), gwenview 4.14.3 handles it perfectly normally now, as e.g. 4.12.2   has always done on Mageia-4.

Here is an strace of gwenview being handed a directory containing the above video file:

     https://dl.dropboxusercontent.com/u/10969499/gwenview-strace-3.txt

(Too big to Attach)
Comment 20 Maurice Batey 2015-06-26 16:14:50 UTC
>  "TaleofTwoBrains.wmv" 

  4.6MiB
Comment 21 Nate Graham 2017-11-09 18:34:26 UTC
*** Bug 369255 has been marked as a duplicate of this bug. ***
Comment 22 Justin Zobel 2022-11-10 08:51:56 UTC
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 23 rnet723 2022-11-10 16:09:37 UTC
(In reply to Justin Zobel from comment #22)
> Thank you for reporting this issue in KDE software. As it has been a while
> since this issue was reported, can we please ask you to see if you can
> reproduce the issue with a recent software version?
> 
> If you can reproduce the issue, please change the status to "REPORTED" when
> replying. Thank you!

I tested Gwenview 22.08.2 on a directory with 100k+ jpeg files. 

It does not freeze completely, but it's so slow that it is effectively useless. 

It seems the issue is still valid.