qarmin / czkawka

Multi functional app to find duplicates, empty folders, similar images etc.
Other
18.39k stars 606 forks source link

Similar images "Scanning" step hangs #1078

Open anonymous721 opened 9 months ago

anonymous721 commented 9 months ago

Desktop (please complete the following information):

Bug Description

Lately, when starting a similar image scan, the process has gotten stuck on the "Scanning X file" stage. Hitting the stop button is usually unable to cancel it, and I need to kill the GUI entirely. Sometimes, hitting Stop and waiting several minutes will eventually work, but typically it has not stopped for as long as I waited (in some cases more than half an hour). If it does manage to stop, then the next attempt to run the search will work.

This occurs even if I run the search on a test folder that is actually empty. It sticks on "Scanning 0 file", just like other searches. Also, even if the selected folder is on my SSD, for the entire time it's on the "Scanning" step I can hear hard drive activity. So it seems like the scanning process isn't scanning the right place at all.

I'm not sure exactly what changed, since this wasn't an issue I was running into before on either version. I did add an additional drive recently, but I've got it set as an excluded directory so that shouldn't matter (aside from the apparent scanning of untargeted folders).

qarmin commented 9 months ago

Can you download this latest version from - https://github.com/qarmin/czkawka/actions/runs/6442653449

and try to run it via

RUST_LOG=debug ./czkawka_gui

and print here output?

It uses different cache mechanism, so images will need to be checked/hashed again, but a lot of info which function is executed should be printed

anonymous721 commented 8 months ago

Running that version, it didn't stick on the scanning step at all. Which is good for usability but I'm not sure how useful the log will be. Here it is though:

$ RUST_LOG=debug ./czkawka_gui
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.978: Theme parser error: main-light.css:2050:55-56: The color must be the last parameter
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.978: Theme parser error: main-light.css:2058:55-56: The color must be the last parameter
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.980: Theme parser error: main-light.css:4158:31-32: Expected shadow value to contain a length
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.980: Theme parser error: main-light.css:4299:1-2: Expected a valid selector
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.980: Theme parser error: main-light.css:4859:3-15: Junk at end of value for outline-color
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.981: Theme parser error: main-light.css:5877:1-2: Expected a valid selector
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.981: Theme parser error: main-light.css:5981:10-20: "text_color" is not a valid color name.
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.981: Theme parser error: main-light.css:5993:27-45: "sidebar_text_color" is not a valid color name.
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.981: Theme parser error: main-light.css:5998:10-28: "sidebar_text_color" is not a valid color name.
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.981: Theme parser error: main-light.css:6079:1-2: Expected a valid selector
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:26.981: Theme parser error: main-light.css:6714:1-2: Expected a valid selector
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:27.045: GtkImage 0x56375da78df0 reported baselines of minimum -2147483648 and natural -2147483648, but sizes of minimum 16 and natural 16. Baselines must be inside the widget size.
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:27.045: GtkImage 0x56375da83150 reported baselines of minimum -2147483648 and natural -2147483648, but sizes of minimum 16 and natural 16. Baselines must be inside the widget size.
(czkawka_gui:2109487): Gtk-WARNING **: 12:52:27.045: GtkImage 0x56375da83470 reported baselines of minimum -2147483648 and natural -2147483648, but sizes of minimum 16 and natural 16. Baselines must be inside the widget size.
Set thread number to 16
12:52:32.150 [DEBUG] czkawka_gui::connect_things::connect_button_search: Start clean tree view
12:52:32.150 [DEBUG] czkawka_gui::connect_things::connect_button_search: Cleared tree view
12:52:32.150 [INFO] czkawka_core::similar_images: Starting finding similar images files
12:52:32.151 [DEBUG] czkawka_core::similar_images: check_for_similar_images - start
12:52:32.153 [DEBUG] czkawka_core::common: Sending info to stop all threads
12:52:32.171 [DEBUG] czkawka_core::common: All threads stopped
12:52:32.171 [DEBUG] czkawka_core::similar_images: check_for_similar_images - end
12:52:32.171 [DEBUG] czkawka_core::similar_images: hash_images - start
12:52:32.171 [DEBUG] czkawka_core::similar_images: hash_images_load_cache - start, use cache: true
12:52:32.171 [DEBUG] czkawka_core::common_cache: Loading cache from file cache_similar_images_16_Gradient_Lanczos3_61.bin (or json alternative)
12:52:32.171 [DEBUG] czkawka_core::common_cache: Starting to removing outdated cache entries
12:52:32.172 [DEBUG] czkawka_core::common_cache: Completed removing outdated cache entries, removed 0 out of all 1040 entries
12:52:32.172 [DEBUG] czkawka_core::common_cache: Loaded cache from file cache_similar_images_16_Gradient_Lanczos3_61.bin (or json alternative) - 1040 results
12:52:32.172 [DEBUG] czkawka_core::common_cache: Converting cache Vec<T> into BTreeMap<String, T>
12:52:32.172 [DEBUG] czkawka_core::common_cache: Converted cache Vec<T> into BTreeMap<String, T>
12:52:32.172 [DEBUG] czkawka_core::similar_images: hash_images_load_cache - end
12:52:32.172 [DEBUG] czkawka_core::similar_images: hash_images - start hashing images
12:52:41.971 [DEBUG] czkawka_core::similar_images: hash_images - end hashing images
12:52:41.971 [DEBUG] czkawka_core::common: Sending info to stop all threads
12:52:41.981 [DEBUG] czkawka_core::common: All threads stopped
12:52:41.982 [DEBUG] czkawka_core::similar_images: save_to_cache - start, using cache: true
12:52:41.982 [DEBUG] czkawka_core::common_cache: Saving cache to file cache_similar_images_16_Gradient_Lanczos3_61.bin (or also json alternative) - 1381 results
12:52:41.983 [DEBUG] czkawka_core::common_cache: Saved binary to file "/home/User/.cache/czkawka/cache_similar_images_16_Gradient_Lanczos3_61.bin"
12:52:41.983 [DEBUG] czkawka_core::similar_images: save_to_cache - end
12:52:41.983 [DEBUG] czkawka_core::similar_images: hash_images - end
12:52:41.983 [DEBUG] czkawka_core::similar_images: find_similar_hashes - start
12:52:41.983 [DEBUG] czkawka_core::similar_images: exclude_items_with_same_size - start, exclude: false
12:52:41.983 [DEBUG] czkawka_core::similar_images: exclude_items_with_same_size - end
12:52:41.983 [DEBUG] czkawka_core::similar_images: remove_multiple_records_from_reference_folders - start, use reference: true
12:52:41.983 [DEBUG] czkawka_core::similar_images: remove_multiple_records_from_reference_folders - end
12:52:41.983 [DEBUG] czkawka_core::similar_images: find_similar_hashes - end
12:52:41.983 [INFO] czkawka_core::similar_images: Ended finding similar images which took 9.83243155s