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 crashes immediately after opening #1753

Closed
wout opened this issue Jul 14, 2021 · 21 comments · Fixed by #2303
Closed

Files crashes immediately after opening #1753

wout opened this issue Jul 14, 2021 · 21 comments · Fixed by #2303

Comments

@wout
Copy link

wout commented Jul 14, 2021

What Happened

After opening files, it immediately closes again.

Expected Behavior

Should stay open.

Logs

From syslog:

Jul 14 15:44:03 Rossy io.elementary.f[6445]: Application.vala:133: Report any issues/bugs you might find to https://github.com/elementary/files/issues
Jul 14 15:44:03 Rossy gala[1843]: clutter_actor_remove_child: assertion 'CLUTTER_IS_ACTOR (child)' failed
Jul 14 15:44:03 Rossy gala[1843]: invalid (NULL) pointer instance
Jul 14 15:44:03 Rossy gala[1843]: g_signal_connect_data: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
Jul 14 15:44:03 Rossy io.elementary.f[6445]: Window.vala:472: Cannot restore file:///home/wout/Tresors/Bookkeeping/Documents, ignoring
Jul 14 15:44:04 Rossy io.elementary.f[6445]: Source ID 53 was not found when attempting to remove it
Jul 14 15:44:04 Rossy io.elementary.f[6445]: invalid (NULL) pointer instance
Jul 14 15:44:04 Rossy io.elementary.f[6445]: g_signal_handlers_disconnect_matched: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
Jul 14 15:44:04 Rossy kernel: [  547.866104] io.elementary.f[6445]: segfault at 1 ip 0000000000000001 sp 00007ffcc632d8c8 error 14 in io.elementary.files[555d9ae2c000+25000]
Jul 14 15:44:04 Rossy kernel: [  547.866113] Code: Unable to access opcode bytes at RIP 0xffffffffffffffd7.

Platform Information

image

@wout
Copy link
Author

wout commented Jul 14, 2021

Small update. Opening files as an administrator is still possible, probably because that's from another directory. I managed to work around the issue by opening files from a terminal window in a different directory than it was crashing on. Nevertheless, it would be nice not to have it crash because it locks out the user.

@jeremypw
Copy link
Collaborator

jeremypw commented Jul 14, 2021

Are you able to install the pantheon-files-core-dev and pantheon-files-widgets-dev packages and gdb then get a backtrace of the crash by running gdb io.elementary.files and post it here?

@wout
Copy link
Author

wout commented Jul 15, 2021

I am able to install them, but unable to reproduce the issue now. I've tried creating a directory in Files, closing Files, renaming the directory in the Terminal, re-opening Files, but that's not it. I'll keep an eye on it and report back in case it happens again.

@wout
Copy link
Author

wout commented Jul 15, 2021

Ok, I've got this going on again. I've installed pantheon-files-core-dev and pantheon-files-widgets-dev, but gdb io.elementary.files gives me nothing except the initial output:

$ gdb io.elementary.files
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from io.elementary.files...
(No debugging symbols found in io.elementary.files)
(gdb)

From /var/log/syslog:

Jul 15 09:45:39 Rossy io.elementary.f[1041531]: Application.vala:133: Report any issues/bugs you might find to https://github.com/elementary/files/issues
Jul 15 09:45:39 Rossy systemd[1]: run-docker-runtime\x2drunc-moby-dc4c781daf2cbf142473ccca33d91acba6cf215b54ed3712b2c850655652047d-runc.LRuaNm.mount: Succeeded.
Jul 15 09:45:39 Rossy systemd[1572]: run-docker-runtime\x2drunc-moby-dc4c781daf2cbf142473ccca33d91acba6cf215b54ed3712b2c850655652047d-runc.LRuaNm.mount: Succeeded.
Jul 15 09:45:39 Rossy systemd[1572]: run-docker-runtime\x2drunc-moby-70f11463bc29e5d05b71cce2360b5c85cf1f488ddb09e070b5b0e4ce5cc50099-runc.m8yc9C.mount: Succeeded.
Jul 15 09:45:39 Rossy systemd[1]: run-docker-runtime\x2drunc-moby-70f11463bc29e5d05b71cce2360b5c85cf1f488ddb09e070b5b0e4ce5cc50099-runc.m8yc9C.mount: Succeeded.
Jul 15 09:45:39 Rossy gala[231521]: clutter_actor_remove_child: assertion 'CLUTTER_IS_ACTOR (child)' failed
Jul 15 09:45:39 Rossy gala[231521]: invalid (NULL) pointer instance
Jul 15 09:45:39 Rossy gala[231521]: g_signal_connect_data: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
Jul 15 09:45:39 Rossy io.elementary.f[1041531]: Window.vala:472: Cannot restore file:///home/wout/Tresors/Bookkeeping/BlaBla, ignoring
Jul 15 09:45:39 Rossy io.elementary.f[1041531]: Source ID 47 was not found when attempting to remove it
Jul 15 09:45:39 Rossy io.elementary.f[1041531]: invalid (NULL) pointer instance
Jul 15 09:45:39 Rossy io.elementary.f[1041531]: g_signal_handlers_disconnect_matched: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
Jul 15 09:45:39 Rossy kernel: [65442.763825] io.elementary.f[1041531]: segfault at 0 ip 0000000000000000 sp 00007fff712361b8 error 14 in io.elementary.files[55efa4d02000+25000]
Jul 15 09:45:39 Rossy kernel: [65442.763838] Code: Unable to access opcode bytes at RIP 0xffffffffffffffd6.
Jul 15 09:45:39 Rossy gala[231521]: Error in map accounting.

Particularly this line is interesting:

Window.vala:472: Cannot restore file:///home/wout/Tresors/Bookkeeping/BlaBla, ignoring

That's the folder I created and renamed. At first, I called it Bla Bla, then renamed it to BlaBla, but that didn't reproduce the error. Then I deleted it and now Files seems to be crashing on it.

@jeremypw
Copy link
Collaborator

Thanks for trying! After running gdb io.elementary.files you need to type run to start the program (this is to give you the opportunity to set breakpoints and environment variables if necessary - not needed for basic debugging). After the program crashes enter bt and this will give you the backtrace. Sorry for not fully explaining before. You can get further more detailed info e.g. here: https://wiki.debian.org/HowToGetABacktrace

@jeremypw
Copy link
Collaborator

jeremypw commented Jul 15, 2021

You are right it does look like Files is crashing when restoring that file but the gdb backtrace should give clearer information. Files should be designed to tolerate problems restoring particular files. You can stop Files restoring previously opened tabs by temporarily turning off "History" under "System Settings/Privacy & Security".

@wout
Copy link
Author

wout commented Jul 15, 2021

After running gdb io.elementary.files you need to type run to start the program

Right, that makes sense, I've never used gdb before. :)
Here you go:

Starting program: /usr/bin/io.elementary.files 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff29fd700 (LWP 1413364)]
[New Thread 0x7ffff21fc700 (LWP 1413368)]
[New Thread 0x7ffff19fb700 (LWP 1413371)]
[New Thread 0x7ffff1136700 (LWP 1413387)]
** Message: 12:33:21.058: Application.vala:133: Report any issues/bugs you might find to https://github.com/elementary/files/issues
[New Thread 0x7fffe1328700 (LWP 1413390)]

** (io.elementary.files:1413341): WARNING **: 12:33:21.214: Window.vala:472: Cannot restore file:///home/wout/Tresors/Bookkeeping/BlaBla, ignoring
[New Thread 0x7fffe0b27700 (LWP 1413392)]
[New Thread 0x7fffd7fff700 (LWP 1413393)]
[New Thread 0x7fffd77fe700 (LWP 1413394)]
[New Thread 0x7fffd6ffd700 (LWP 1413396)]
[New Thread 0x7fffd67fc700 (LWP 1413397)]
[New Thread 0x7fffd5ffb700 (LWP 1413398)]
[New Thread 0x7fffd57fa700 (LWP 1413399)]
[New Thread 0x7fffd4ff9700 (LWP 1413400)]
[New Thread 0x7fffbbfff700 (LWP 1413401)]
[New Thread 0x7fffbb7fe700 (LWP 1413402)]
[New Thread 0x7fffbaffd700 (LWP 1413403)]
[New Thread 0x7fffba7fc700 (LWP 1413404)]
[New Thread 0x7fffb9ffb700 (LWP 1413405)]
[New Thread 0x7fffb97fa700 (LWP 1413406)]
[New Thread 0x7fffb8ff9700 (LWP 1413407)]
[New Thread 0x7fff97fff700 (LWP 1413408)]
[New Thread 0x7fff977fe700 (LWP 1413409)]
[New Thread 0x7fff96ffd700 (LWP 1413410)]
[New Thread 0x7fff967fc700 (LWP 1413411)]

(io.elementary.files:1413341): GLib-CRITICAL **: 12:33:21.399: Source ID 47 was not found when attempting to remove it

(io.elementary.files:1413341): GLib-GObject-WARNING **: 12:33:21.406: invalid (NULL) pointer instance

(io.elementary.files:1413341): GLib-GObject-CRITICAL **: 12:33:21.406: g_signal_handlers_disconnect_matched: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed

Thread 1 "io.elementary.f" received signal SIGSEGV, Segmentation fault.
0x00007ffff7f10fdc in files_abstract_slot_get_current_slot ()
   from /lib/x86_64-linux-gnu/libpantheon-files-core.so.4

And here's the backtrace:

0x00007ffff7f10fdc in files_abstract_slot_get_current_slot ()
   from /lib/x86_64-linux-gnu/libpantheon-files-core.so.4
(gdb) bt
#0  0x00007ffff7f10fdc in files_abstract_slot_get_current_slot ()
    at /lib/x86_64-linux-gnu/libpantheon-files-core.so.4
#1  0x00007ffff7f11390 in files_abstract_slot_get_directory ()
    at /lib/x86_64-linux-gnu/libpantheon-files-core.so.4
#2  0x00005555555a0661 in  ()
#3  0x00005555555a05cc in  ()
#4  0x00005555555a054f in  ()
#5  0x00005555555ad5c4 in  ()
#6  0x00007ffff7e1b04e in g_main_context_dispatch ()
    at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#7  0x00007ffff7e1b400 in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#8  0x00007ffff7e1b4a3 in g_main_context_iteration ()
    at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#9  0x00007ffff7c6afe5 in g_application_run () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#10 0x0000555555582e1a in main ()

You can stop Files restoring previously opened tabs by temporarily turning off "History" under "System Settings/Privacy & Security".

Good to know, thanks!

@jeremypw
Copy link
Collaborator

I am not getting a crash when restoring a folder that has been deleted by another application. I get the Cannot restore file: warning but Files does not crash. Can you get a crash restoring just this folder? There seems to be some debugging symbols missing but there doesn't seem to be a pantheon-files-dbg package for some reason. Probably need to build and install from source to get all the symbols :{ I suspect a signal race where a signal handler tries to access a directory object that has been destroyed.

@jeremypw
Copy link
Collaborator

jeremypw commented Jul 15, 2021

In case it matters, could you indicate which view mode you are using and whether there is a bookmark to the problem folder?

@wout
Copy link
Author

wout commented Jul 15, 2021

In case it matters, could you indicate which view mode you are using and whether there is a bookmark to the problem folder?

I'm almost always using the Columns view mode.

file:///home/wout/Tresors/Bookkeeping is a bookmark, but we're dealing with a folder inside the bookmarked folder so that's not what you're after I think, right?

Inside the parent folder, I re-created a folder with the same name from the terminal, and Files is no longer crashing. Then I closed Files, deleted the folder again, opened Files and still no crash. But Files is also no longer opening that particular directory, while it did before.

It's hard to reproduce, but still, it happened twice to me. So something is not right. I'll have to keep watching it.

@jeremypw
Copy link
Collaborator

OK, thanks. So, if you are using ColumnView, there are two folders that are specified for restoring each tab - the leftmost (root) folder and the rightmost (tip) folder. Is the problematic folder the root, the tip or one of the intermediate folders?

@jeremypw
Copy link
Collaborator

Deleting either the root or the the tip folder resulted in an additional warning Source ID XX was not found when attempting to remove it - which you also reported - but no crash.

`

@wout
Copy link
Author

wout commented Jul 15, 2021

OK, thanks. So, if you are using ColumnView, there are two folders that are specified for restoring each tab - the leftmost (root) folder and the rightmost (tip) folder. Is the problematic folder the root, the tip or one of the intermediate folders?

Good point. I could only see the files window for a fraction of a second, because it opened and immediately closed again. But during the fade-in and fade-out I could see the deleted folder was selected. So somehow Files thought the folder was still present while in fact, it wasn't. It's frustrating that I can't reproduce this.

@wout
Copy link
Author

wout commented Aug 25, 2023

This is still going on. Here's the trace:

Aug 25 18:46:24 Framey io.elementary.f[1931119]: Window.vala:594: Cannot restore file:///home/wout/Tresors/Projects/Zeroone/Sliding%20Doors, ignoring
Aug 25 18:46:25 Framey io.elementary.f[1931119]: Source ID 49 was not found when attempting to remove it
Aug 25 18:46:25 Framey io.elementary.f[1931119]: invalid (NULL) pointer instance
Aug 25 18:46:25 Framey io.elementary.f[1931119]: g_signal_handlers_disconnect_matched: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
Aug 25 18:46:25 Framey kernel: [265096.874685] io.elementary.f[1931119]: segfault at a0 ip 00007f375b449eec sp 00007ffd0fad5348 error 4 in libpantheon-files-core.so.6.5.0[7f375b441000+5e000] likely on CPU 4 (core 8, socket 0)
Aug 25 18:46:25 Framey kernel: [265096.874696] Code: 1f 80 00 00 00 00 48 8d 15 c1 5c 05 00 48 8d 35 8a 76 05 00 31 ff e9 93 a9 ff ff 0f 1f 00 f3 0f 1e fa 48 85 ff 74 17 48 8b 07 <48> 8b 80 a0 00 00 00 48 85 c0 74 28 ff e0 66 0f 1f 44 00 00 48 83
Aug 25 18:46:25 Framey gala[2489]: Error in map accounting.

This is a brand new elementary OS 7 installation:

         eeeeeeeeeeeeeeeee            wout@Framey 
      eeeeeeeeeeeeeeeeeeeeeee         ----------- 
    eeeee  eeeeeeeeeeee   eeeee       OS: elementary OS 7 Horus x86_64 
  eeee   eeeee       eee     eeee     Host: Laptop (12th Gen Intel Core) A8 
 eeee   eeee          eee     eeee    Kernel: 6.2.0-26-generic 
eee    eee            eee       eee   Uptime: 3 days, 1 hour, 41 mins 
eee   eee            eee        eee   Packages: 1895 (dpkg), 58 (flatpak) 
ee    eee           eeee       eeee   Shell: bash 5.1.16 
ee    eee         eeeee      eeeeee   Resolution: 3000x2000, 3840x2160 
ee    eee       eeeee      eeeee ee   DE: Pantheon 
eee   eeee   eeeeee      eeeee  eee   WM: Mutter(Gala) 
eee    eeeeeeeeee     eeeeee    eee   Theme: io.elementary.stylesheet.mint [GTK3] 
 eeeeeeeeeeeeeeeeeeeeeeee    eeeee    Icons: elementary [GTK3] 
  eeeeeeee eeeeeeeeeeee      eeee     Terminal: io.elementary.t 
    eeeee                 eeeee       CPU: 12th Gen Intel i7-1280P (20) @ 4.700GHz 
      eeeeeee         eeeeeee         GPU: Intel Alder Lake-P 
         eeeeeeeeeeeeeeeee            Memory: 16336MiB / 64003MiB 

Turning off the Restore tabs option in Tweaks fixes the issue:

image

@jeremypw
Copy link
Collaborator

@thanks for the update. Could you confirm that you are restoring a Column View? Could you check which folders are being restored and whether they exist and whether they are connected/mounted? You can see which tabs are stored by inspecting the key tab-info-list in the scheme io.elementary.files.preferences. You either use dconf-editor or the commandline gsettings get io.elementary.files.preferences tab-info-list. Each tab is stored as (<mode>, <root-path>, <tip-path>).

Do the relevant directories restore OK in Icon or List View? Does Column View restore a single folder OK?

@jeremypw
Copy link
Collaborator

If you could install gdb and launch files from the commandline with gdb io.elementary.files then run, you can get a backtrace for the crash by typing bt at the gdb prompt after the crash.

@wout
Copy link
Author

wout commented Aug 26, 2023

I'm almost exclusively using Column View, so that's definitely the case.

Here's the content of the files settings:

$ gsettings get io.elementary.files.preferences tab-info-list
[(uint32 2, 'file:///home/wout/Tresors/Projects', 'file:///home/wout/Tresors/Projects/Zeroone/Sliding%20Doors'), (1, 'file:///home/wout/Pictures/2023/08/25', ''), (2, 'file:///home/wout/Code/typescript/punt.js/play/.vite', 'file:///home/wout/Code/typescript/punt.js/play/.vite'), (2, 'file:///home/wout/Code/typescript/punt.js/play/.vite', 'file:///home/wout/Code/typescript/punt.js/play/.vite')]

There are a bunch of duplicates at the end

What I'm getting with gdb right now after running files with Restore Tabs enabled:

$ gdb io.elementary.files
GNU gdb (Ubuntu 12.1-0ubuntu1~22.04) 12.1
Copyright (C) 2022 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from io.elementary.files...
(No debugging symbols found in io.elementary.files)
(gdb) run
Starting program: /usr/bin/io.elementary.files 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff2dff640 (LWP 2345389)]
[New Thread 0x7ffff25fe640 (LWP 2345390)]
[New Thread 0x7ffff1dfd640 (LWP 2345391)]
[New Thread 0x7ffff15bb640 (LWP 2345392)]
[New Thread 0x7fffe3fff640 (LWP 2345395)]
[Thread 0x7fffe3fff640 (LWP 2345395) exited]
[New Thread 0x7fffe3fff640 (LWP 2345396)]
[New Thread 0x7fffe33ff640 (LWP 2345397)]
[Thread 0x7fffe3fff640 (LWP 2345396) exited]
[Thread 0x7fffe33ff640 (LWP 2345397) exited]
[New Thread 0x7fffe33ff640 (LWP 2345398)]
[New Thread 0x7fffe3fff640 (LWP 2345399)]
[Thread 0x7fffe33ff640 (LWP 2345398) exited]
[Thread 0x7fffe3fff640 (LWP 2345399) exited]
[New Thread 0x7fffe3fff640 (LWP 2345400)]
[New Thread 0x7fffe33ff640 (LWP 2345401)]
[Thread 0x7fffe3fff640 (LWP 2345400) exited]
[Thread 0x7fffe33ff640 (LWP 2345401) exited]
[New Thread 0x7fffe33ff640 (LWP 2345402)]
[New Thread 0x7fffe3fff640 (LWP 2345403)]
[New Thread 0x7fffe15ff640 (LWP 2345406)]
[New Thread 0x7fffe0dfe640 (LWP 2345407)]
[New Thread 0x7fffd61ff640 (LWP 2345408)]
[New Thread 0x7fffd59fe640 (LWP 2345409)]
[New Thread 0x7fffd51fd640 (LWP 2345410)]
[Thread 0x7fffd59fe640 (LWP 2345409) exited]
[Thread 0x7ffff15bb640 (LWP 2345392) exited]
[Thread 0x7fffe15ff640 (LWP 2345406) exited]
[Thread 0x7fffe33ff640 (LWP 2345402) exited]
[Thread 0x7fffe0dfe640 (LWP 2345407) exited]
[Thread 0x7fffe3fff640 (LWP 2345403) exited]
[Thread 0x7fffd61ff640 (LWP 2345408) exited]
[Thread 0x7fffd51fd640 (LWP 2345410) exited]
[Thread 0x7ffff1dfd640 (LWP 2345391) exited]
[Thread 0x7ffff2dff640 (LWP 2345389) exited]
[Thread 0x7ffff59cba80 (LWP 2345386) exited]
[Thread 0x7ffff25fe640 (LWP 2345390) exited]
[New process 2345386]
[Inferior 1 (process 2345386) exited normally]
(gdb) run
Starting program: /usr/bin/io.elementary.files 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff2dff640 (LWP 2345716)]
[New Thread 0x7ffff25fe640 (LWP 2345717)]
[New Thread 0x7ffff1dfd640 (LWP 2345718)]
[New Thread 0x7ffff15bb640 (LWP 2345719)]
[New Thread 0x7fffe3fff640 (LWP 2345720)]
[Thread 0x7fffe3fff640 (LWP 2345720) exited]
[New Thread 0x7fffe3fff640 (LWP 2345721)]
[New Thread 0x7fffe33ff640 (LWP 2345722)]
[Thread 0x7fffe3fff640 (LWP 2345721) exited]
[Thread 0x7fffe33ff640 (LWP 2345722) exited]
[New Thread 0x7fffe33ff640 (LWP 2345723)]
[New Thread 0x7fffe3fff640 (LWP 2345724)]
[Thread 0x7fffe33ff640 (LWP 2345723) exited]
[Thread 0x7fffe3fff640 (LWP 2345724) exited]
[New Thread 0x7fffe3fff640 (LWP 2345725)]
[New Thread 0x7fffe33ff640 (LWP 2345726)]
[Thread 0x7fffe3fff640 (LWP 2345725) exited]
[Thread 0x7fffe33ff640 (LWP 2345726) exited]
[New Thread 0x7fffe33ff640 (LWP 2345727)]
[New Thread 0x7fffe3fff640 (LWP 2345728)]

** (io.elementary.files:2345699): WARNING **: 10:59:37.916: Window.vala:594: Cannot restore file:///home/wout/Tresors/Projects/Zeroone/Sliding%20Doors, ignoring

** (io.elementary.files:2345699): WARNING **: 10:59:37.918: Window.vala:594: Cannot restore file:///home/wout/Code/typescript/punt.js/play/.vite, ignoring

** (io.elementary.files:2345699): WARNING **: 10:59:37.919: Window.vala:594: Cannot restore file:///home/wout/Code/typescript/punt.js/play/.vite, ignoring
[New Thread 0x7fffe15ff640 (LWP 2345729)]
[New Thread 0x7fffe0dfe640 (LWP 2345730)]
[New Thread 0x7fffd61ff640 (LWP 2345731)]
[New Thread 0x7fffd59fe640 (LWP 2345732)]
[New Thread 0x7fffd51fd640 (LWP 2345733)]
[New Thread 0x7fffd49fc640 (LWP 2345734)]
[New Thread 0x7fffbbfff640 (LWP 2345735)]
[Thread 0x7fffd49fc640 (LWP 2345734) exited]
[New Thread 0x7fffd49fc640 (LWP 2345736)]
[New Thread 0x7fffbb7fe640 (LWP 2345737)]
[Thread 0x7fffbbfff640 (LWP 2345735) exited]
[Thread 0x7fffd49fc640 (LWP 2345736) exited]
[New Thread 0x7fffd49fc640 (LWP 2345738)]
[New Thread 0x7fffbbfff640 (LWP 2345739)]
[Thread 0x7fffbb7fe640 (LWP 2345737) exited]
[Thread 0x7fffd49fc640 (LWP 2345738) exited]
[Thread 0x7fffbbfff640 (LWP 2345739) exited]
[New Thread 0x7fffbbfff640 (LWP 2345740)]
[New Thread 0x7fffd49fc640 (LWP 2345741)]
[New Thread 0x7fffbb7fe640 (LWP 2345742)]
[New Thread 0x7fffbaffd640 (LWP 2345743)]
[New Thread 0x7fffba7fc640 (LWP 2345744)]
[New Thread 0x7fffb9ffb640 (LWP 2345745)]
[New Thread 0x7fffb97fa640 (LWP 2345746)]
[New Thread 0x7fffb8ff9640 (LWP 2345747)]
[New Thread 0x7fff9ffff640 (LWP 2345748)]
[New Thread 0x7fff9f7fe640 (LWP 2345749)]
[New Thread 0x7fff9effd640 (LWP 2345750)]
[New Thread 0x7fff9e7fc640 (LWP 2345751)]
[New Thread 0x7fff9dffb640 (LWP 2345752)]
[New Thread 0x7fff9d7fa640 (LWP 2345753)]
[New Thread 0x7fff9cff9640 (LWP 2345754)]
[New Thread 0x7fff73fff640 (LWP 2345755)]
[New Thread 0x7fff737fe640 (LWP 2345756)]
[New Thread 0x7fff6affd640 (LWP 2345757)]
[New Thread 0x7fff72ffd640 (LWP 2345758)]
[New Thread 0x7fff727fc640 (LWP 2345759)]
[New Thread 0x7fff71ffb640 (LWP 2345760)]
[New Thread 0x7fff717fa640 (LWP 2345761)]
[New Thread 0x7fff70ff9640 (LWP 2345762)]
[New Thread 0x7fff6bfff640 (LWP 2345763)]
[New Thread 0x7fff6b7fe640 (LWP 2345764)]
[New Thread 0x7fff6a7fc640 (LWP 2345765)]
[New Thread 0x7fff69ffb640 (LWP 2345766)]
[New Thread 0x7fff697fa640 (LWP 2345767)]
[New Thread 0x7fff68ff9640 (LWP 2345768)]
[New Thread 0x7fff33fff640 (LWP 2345769)]
[New Thread 0x7fff337fe640 (LWP 2345770)]
[New Thread 0x7fff2affd640 (LWP 2345771)]
[New Thread 0x7fff32ffd640 (LWP 2345772)]
[New Thread 0x7fff327fc640 (LWP 2345773)]
[New Thread 0x7fff31ffb640 (LWP 2345774)]
[New Thread 0x7fff317fa640 (LWP 2345775)]
[New Thread 0x7fff30ff9640 (LWP 2345776)]
[New Thread 0x7fff2bfff640 (LWP 2345777)]
[New Thread 0x7fff2b7fe640 (LWP 2345778)]
[New Thread 0x7fff2a7fc640 (LWP 2345779)]
[New Thread 0x7fff29ffb640 (LWP 2345780)]
[New Thread 0x7fff297fa640 (LWP 2345781)]

(io.elementary.files:2345699): GLib-CRITICAL **: 10:59:38.037: Source ID 49 was not found when attempting to remove it

(io.elementary.files:2345699): GLib-CRITICAL **: 10:59:38.039: Source ID 55 was not found when attempting to remove it

(io.elementary.files:2345699): GLib-CRITICAL **: 10:59:38.039: Source ID 60 was not found when attempting to remove it

(io.elementary.files:2345699): GLib-GObject-WARNING **: 10:59:38.039: invalid (NULL) pointer instance

(io.elementary.files:2345699): GLib-GObject-CRITICAL **: 10:59:38.039: g_signal_handlers_disconnect_matched: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed

Thread 1 "io.elementary.f" received signal SIGSEGV, Segmentation fault.
0x00007ffff7f22eec in files_abstract_slot_get_current_slot () from /lib/x86_64-linux-gnu/libpantheon-files-core.so.6

UPDATE
FWIW, Files has crashed now. The window is stuck so I guess this is there error we're looking for.

@wout wout changed the title FIles crashes immediately after opening Files crashes immediately after opening Aug 26, 2023
@wout
Copy link
Author

wout commented Aug 26, 2023

Tested another view by disabling Restore Tabs, opening Files to enable Icon View, then close Files, re-enable Restore Tabs and it also crashes. This is what it looks like:

image

It seems to be stuck in a transition.

Did the same with List view and something similar is happening there with the Column View icon pressed but the List View icon highlighted:

image

@jeremypw
Copy link
Collaborator

Thanks that is helpful. It seems a couple of folders file:///home/wout/Code/typescript/punt.js/play/.vite and file:///home/wout/Tresors/Projects/Zeroone/Sliding%20Doors cannot be restored for some reason but that should not cause Files to crash - that tab should just be omitted. Are you able to navigate to these folders successfully if you open Files without restoring tabs?

When running under gdb, after you get the "segmentation fault" message and Files freezes, could you type bt at the terminal prompt and post the output? This will give more information of what happened before the crash.

The pathbar glitch is not relevant I think - I get that occasionally on startup but have never got round to investigating it as it causes no problems.

@wout
Copy link
Author

wout commented Aug 27, 2023

Are you able to navigate to these folders successfully if you open Files without restoring tabs?

Both folders no longer exist, so I can't navigate to them. The former is removed, the latter renamed.

could you type bt at the terminal prompt and post the output?

#0  0x00007ffff7f22eec in files_abstract_slot_get_current_slot ()
    at /lib/x86_64-linux-gnu/libpantheon-files-core.so.6
#1  0x00007ffff7f233b0 in files_abstract_slot_get_directory ()
    at /lib/x86_64-linux-gnu/libpantheon-files-core.so.6
#2  0x00005555555b4841 in  ()
#3  0x00005555555b48f7 in  ()
#4  0x00005555555b41f6 in  ()
#5  0x00005555555a8911 in  ()
#6  0x00007ffff7e13c44 in g_main_context_dispatch ()
    at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#7  0x00007ffff7e69258 in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#8  0x00007ffff7e113e3 in g_main_context_iteration ()
    at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#9  0x00007ffff7c65fb5 in g_application_run ()
    at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#10 0x0000555555589943 in main ()

Recreating file:///home/wout/Tresors/Projects/Zeroone/Sliding%20Doors fixes the issue. With Restore Tabs on, Files no longer crashes. But quitting files, removing the folder and re-opening Files makes it crash again. So it's definitely related to that particular folder it's trying to restore.

@jeremypw
Copy link
Collaborator

Thanks. I tried restoring deleted folders and while I got a lot of terminal errors Files did not crash - however there could be timing differences between different systems. There is clearly some mishandling of this situation which I will look into.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants