Application crash after a couple of hours
Describe the bug Hi! After using the application for a couple of hours, the application ends unresponsive with high CPU usage. It happened several times, different days(laptop rebooted and all packages updated; that is pacman and flatpak).
To Reproduce Steps to reproduce the behavior:
- Open the application and after 4 hours it becomes unresponsive, you will notice it when the cpu fan increases its work and checking the running processes, you will find python CPU usage is very high. If you search the parent process of such python you will find apostrophe application.
- After it becomes unresponsive you will see the gnome button asking you wheter you want to wait or close the application. None of them work, I had to kill it with a "kill -9 application_PID"
Expected behavior Keep CPU usage low and application responsive
Screenshots
The unresponsive message
The document size/statistics when it become unresponsive
Flatpak debug?
This message appeared a few seconds after I opened the application. No other message appears neither after it becomes unresponsive
[aaaa@laptop ~]$ flatpak run --devel org.gnome.gitlab.somas.Apostrophe
/usr/lib/python3.10/site-packages/gi/overrides/Gio.py:42: Warning: g_atomic_ref_count_dec: assertion 'old_value > 0' failed
return Gio.Application.run(self, *args, **kwargs)
(apostrophe:2): Gdk-WARNING **: 14:56:32.503: Event with type 19 not holding a GdkSeat. It is most likely synthesized outside Gdk/GTK+
Process overview
Here you can see python3 process with PID 137189 is at almost at 200% CPU. Below it, you can see the processes(child and parent) with such PID.
[aaaa@laptop tor-browser]$ top
top - 00:13:29 up 2 days, 2:07, 2 users, load average: 2,64, 2,90, 2,75
Tasks: 304 total, 2 running, 302 sleeping, 0 stopped, 0 zombie
%Cpu(s): 22,3 us, 32,8 sy, 0,0 ni, 44,3 id, 0,3 wa, 0,3 hi, 0,1 si, 0,0 st
MiB Mem : 15955,0 total, 1008,3 free, 11133,7 used, 3813,0 buff/cache
MiB Swap: 0,0 total, 0,0 free, 0,0 used. 3380,0 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
137189 aaaa 20 0 87,5g 1,0g 281388 R 199,0 6,3 147:19.04 python3
177044 aaaa 20 0 23,4g 350372 133428 S 5,0 2,1 4:51.67 editors_helper
1876 aaaa 20 0 4718436 275108 92456 S 4,6 1,7 50:47.91 gnome-shell
.... (removed some lines not related to apostrophe) ....
16 root -2 0 0 0 0 I 0,0 0,0 0:30.38 rcu_preempt
[aaaa@laptop tor-browser]$ ps -fea | grep -i 137189
aaaa 137189 137188 26 abr25 pts/2 02:27:36 python3 /app/bin/apostrophe
aaaa 137200 137189 0 abr25 pts/2 00:00:10 python3 /app/bin/apostrophe
aaaa 137204 137189 0 abr25 pts/2 00:00:28 python3 /app/bin/apostrophe
aaaa 137749 137189 0 abr25 pts/2 00:00:00 /usr/libexec/webkit2gtk-4.1/WebKitNetworkProcess 7 31
aaaa 137750 137189 3 abr25 pts/2 00:18:48 /usr/libexec/webkit2gtk-4.1/WebKitWebProcess 11 36
aaaa 181897 112352 0 00:13 pts/4 00:00:00 grep --color=auto -i 137189
Environment(please complete the following information):
- Linux distribution: ArchLinux 64bits
- Desktop Enviroment: Gnome
- DE version: 43.4
- GTK version: 1:4.10.3-1
- Apostrophe version: 2.6.3 (installed from flatpak)
Additional context Add any other context about the problem here.