Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Files Crash on Opening Deleted Folder #2438

Closed
Ppamungkas opened this issue May 29, 2024 · 6 comments · Fixed by #2440
Closed

Files Crash on Opening Deleted Folder #2438

Ppamungkas opened this issue May 29, 2024 · 6 comments · Fixed by #2440
Labels
Status: Confirmed The occurrence and circumstances of the issue have been verified

Comments

@Ppamungkas
Copy link

Ppamungkas commented May 29, 2024

What Happened?

Files is crashed on opening a deleted folder. I got segmentation fault.

Steps to Reproduce

  1. Open Files in column view mode and then create a new folder recursively
  2. Go to the new folder by single click it.
  3. Close Files
  4. Delete the new folder using terminal
  5. Files will crash when you open it.

Expected Behavior

Files should open fine when opening a deleted folder by opening the home directory or parent existed folder.

OS Version

7.x (Horus)

Software Version

Latest release (I have run all updates)

Log Output

~$ io.elementary.files

** (io.elementary.files:735162): WARNING **: 10:12:57.448: Window.vala:623: Cannot restore file:///home/ppamungkas/temporary/untitled%20folder, ignoring

(io.elementary.files:735162): GLib-CRITICAL **: 10:12:57.566: Source ID 70 was not found when attempting to remove it

** (io.elementary.files:735162): CRITICAL **: 10:12:57.566: files_view_view_container_get_uri: assertion 'self != NULL' failed

** (io.elementary.files:735162): CRITICAL **: 10:12:57.566: files_view_window_update_labels: assertion 'uri != NULL' failed

** (io.elementary.files:735162): CRITICAL **: 10:12:57.566: files_view_view_container_set_active_state: assertion 'self != NULL' failed

** (io.elementary.files:735162): CRITICAL **: 10:12:57.566: files_view_view_container_get_uri: assertion 'self != NULL' failed

** (io.elementary.files:735162): CRITICAL **: 10:12:57.566: sidebar_sidebar_window_real_sync_uri: assertion 'location != NULL' failed

** (io.elementary.files:735162): CRITICAL **: 10:12:57.566: files_view_view_container_get_is_frozen: assertion 'self != NULL' failed

(io.elementary.files:735162): Handy-CRITICAL **: 10:12:57.566: hdy_tab_view_get_page_position: assertion 'HDY_IS_TAB_PAGE (page)' failed

(io.elementary.files:735162): GLib-GObject-WARNING **: 10:12:57.566: invalid (NULL) pointer instance

(io.elementary.files:735162): GLib-GObject-CRITICAL **: 10:12:57.566: g_signal_handlers_disconnect_matched: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
Segmentation fault

Hardware Info

No response

@ryonakano
Copy link
Contributor

I couldn't reproduce this issue on the latest elementary OS 7.1. In the step 5, Files shows up the parent directory of the deleted directory without any warnings/errors on the terminal.

@Ppamungkas
Copy link
Author

Ppamungkas commented Jun 6, 2024

I might forget to add in the step 1 that you need to add several folders recursively. It also happen in early access elementary OS 8.0.

2024-06-06.09-38-08.mp4

@ryonakano
Copy link
Contributor

@Ppamungkas Thanks for your info and the screencast! I can now confirm this issue happens.

@ryonakano ryonakano added the Status: Confirmed The occurrence and circumstances of the issue have been verified label Jun 8, 2024
@ryonakano
Copy link
Contributor

Backtrace with gdb:

Thread 1 "io.elementary.f" received signal SIGSEGV, Segmentation fault.
0x00007ffff7ed97e9 in files_abstract_slot_get_current_slot (self=0x555556074cd0)
    at ../libcore/AbstractSlot.vala:106
106	        public abstract unowned AbstractSlot? get_current_slot ();
(gdb) bt
#0  0x00007ffff7ed97e9 in files_abstract_slot_get_current_slot (self=0x555556074cd0) at ../libcore/AbstractSlot.vala:106
#1  0x00007ffff7eda327 in files_abstract_slot_get_directory (self=0x555556074cd0) at ../libcore/AbstractSlot.vala:25
#2  0x00005555555e27fa in files_abstract_directory_view_real_scroll_to_cell (self=0x5555560af880, path=0x555555bc1510, scroll_to_top=1) at ../src/View/AbstractDirectoryView.vala:3943
#3  0x00005555555e2932 in files_abstract_directory_view_scroll_to_cell (self=0x5555560af880, path=0x555555bc1510, scroll_to_top=1) at ../src/View/AbstractDirectoryView.vala:3942
#4  0x00005555555e9e75 in files_abstract_tree_view_real_set_cursor_on_cell (base=0x5555560af880, path=0x555555bc1510, renderer=0x5555560c4010, start_editing=0, scroll_to_top=1) at ../src/View/AbstractTreeView.vala:270
#5  0x00005555555e3e4a in files_abstract_directory_view_set_cursor_on_cell (self=0x5555560af880, path=0x555555bc1510, renderer=0x5555560c4010, start_editing=0, scroll_to_top=1) at ../src/View/AbstractDirectoryView.vala:4055
#6  0x00005555555ea001 in files_abstract_tree_view_real_set_cursor (base=0x5555560af880, path=0x555555bc1510, start_editing=0, select=0, scroll_to_top=1) at ../src/View/AbstractTreeView.vala:291
#7  0x00005555555e3744 in files_abstract_directory_view_set_cursor (self=0x5555560af880, path=0x555555bc1510, start_editing=0, select=0, scroll_to_top=1) at ../src/View/AbstractDirectoryView.vala:4017
#8  0x00005555555c4b0b in ___lambda66_ (_data18_=0x5555560772a0) at ../src/View/AbstractDirectoryView.vala:470
#9  0x00005555555c4b5a in ____lambda66__gsource_func (self=0x5555560772a0) at /home/user/work/files/builddir/AbstractDirectoryView.c:3165
#10 0x00007ffff7dbd48e in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#11 0x00007ffff7e1c717 in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#12 0x00007ffff7dbdf77 in g_main_loop_run () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#13 0x00007ffff6d55444 in zeitgeist_log_construct () at /lib/x86_64-linux-gnu/libzeitgeist-2.0.so.0
#14 0x00007ffff6d554e5 in zeitgeist_log_get_default () at /lib/x86_64-linux-gnu/libzeitgeist-2.0.so.0
#15 0x000055555559c61a in __lambda71_ (_data7_=0x5555561888d0, obj=0x555556189460, res=0x5555561894b0) at ../src/ZeitgeistManager.vala:36
#16 0x000055555559cba6 in ___lambda71__gasync_ready_callback (source_object=0x555556189460, res=0x5555561894b0, self=0x5555561888d0) at ../src/ZeitgeistManager.vala:28
#17 0x00007ffff7bde7ab in ??? () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#18 0x00007ffff7bde7e5 in ??? () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#19 0x00007ffff7dbd48e in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#20 0x00007ffff7e1c717 in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#21 0x00007ffff7dbdf77 in g_main_loop_run () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#22 0x00007ffff6d55444 in zeitgeist_log_construct () at /lib/x86_64-linux-gnu/libzeitgeist-2.0.so.0
#23 0x00007ffff6d554e5 in zeitgeist_log_get_default () at /lib/x86_64-linux-gnu/libzeitgeist-2.0.so.0
#24 0x000055555559c61a in __lambda71_ (_data7_=0x55555617d660, obj=0x5555561892f0, res=0x555556189340) at ../src/ZeitgeistManager.vala:36
#25 0x000055555559cba6 in ___lambda71__gasync_ready_callback (source_object=0x5555561892f0, res=0x555556189340, self=0x55555617d660) at ../src/ZeitgeistManager.vala:28
#26 0x00007ffff7bde7ab in ??? () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#27 0x00007ffff7bde7e5 in ??? () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#28 0x00007ffff7dbd48e in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#29 0x00007ffff7e1c717 in ??? () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#30 0x00007ffff7dbca53 in g_main_context_iteration () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#31 0x00007ffff7c1488d in g_application_run () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#32 0x0000555555596300 in _vala_main (args=0x7fffffffdb78, args_length1=1) at ../src/main.vala:28
#33 0x0000555555596347 in main (argc=1, argv=0x7fffffffdb78) at ../src/main.vala:16
(gdb) 

@jeremypw
Copy link
Collaborator

Am I right in assuming this only happens with Column View?

@jeremypw
Copy link
Collaborator

Column View copes with deletion of the root folder (the tab is not shown at all) but if an open subfolder is deleted Files crashes as described.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Confirmed The occurrence and circumstances of the issue have been verified
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants