-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Desktop Suspend/Resume Decouples Mobile Synchronization #6103
Comments
I have same issue on Debian 11 with Xfce. Screen lock will also cause same issue. Can provide debug log if required. |
@apiziali So, at a high level I can say that when Desktop is not staying up to date with incoming messages after resume, it is in fact unable to access its database at all (we timeout after two minutes waiting to talk to our database). It makes me think that on your machine, inter-process communication (IPC, a core part of our Electron foundations) is broken. This is 100% reproducible for you? Can you tell us more about your linux install, window manager, etc.? @timp34 Can we get a log from you? |
Scott,
I am not familiar with the implementation of Signal, so I cannot answer
your question about its database. However, I can say that sometimes,
but not always, messages that have been delivered to Signal Android on
my phone are not delivered to Signal Desktop on my workstation after a
resume.
These are the details of my Linux desktop:
OS : Ubuntu 18.04.6 LTS
uname -a : Linux elijah 5.4.0-124-generic #140~18.04.1-Ubuntu
SMP Fri Aug 5 11:43:34 UTC 2022 x86_64 x86_64
x86_64 GNU/Linux
Window Mgr : Stock Gnome 3
Workstation : Dell Precision 3630 Tower Workstation
CPU : Intel Core i5-8500 CPU (6 core, 3.00GHz)
Memory : 32 GB
I posted the following log files at the time I posted the bug report
(September 1):
https://debuglogs.org/desktop/5.56.0/33574877e6a4c8cdbd74fec3f7f09269a6c0281d6bb5a25e0a0db48626841da5.gz
https://debuglogs.org/android/5.47.3/83a1078f72b089d5d0f5996e170a937b768ab035e7ab9456d2141516ce61d8a4
debuglog.txt : https://github.com/signalapp/Signal-Desktop/files/9474416/debuglog.txt
How else may I assist?
Thanks!
…-----------------
On 9/14/22 9:28 AM, Scott Nonnenberg wrote:
@apiziali <https://github.com/apiziali> So, at a high level I can say
that when Desktop is not staying up to date with incoming messages
after resume, it is in fact unable to access its database at all (we
timeout after two minutes waiting to talk to our database). It makes
me think that on your machine, inter-process communication (IPC, a
core part of our Electron foundations) is broken. This is 100%
reproducible for you? Can you tell us more about your linux install,
window manager, etc.?
@timp34 <https://github.com/timp34> Can we get a log from you?
—
Reply to this email directly, view it on GitHub
<#6103 (comment)>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGLF2LR4KKGUZFCZQCRXOI3V6H4LNANCNFSM6AAAAAAQC4E76I>.
You are receiving this because you were mentioned.Message ID:
***@***.***>
--
|
***@***.*** ________------+------________
/ \
*---*
PGP Key: h t t p s : / / b i t . l y / A n d y P G P K e y
"Computers in the future may weigh no more than 1.5 tons." -- Popular
Mechanics, forecasting the relentless march of science, 1949.
|
Here is my log. This is whilst signal appears to be working ok. Will add another shortly when it is "not" working correctly... :) |
Rather than habitually restarting Signal Desktop each time I resume the workstation, I just resumed without restarting it. After sending a "Note to Self" from my phone, it did not appear on the desktop. I immediately captured a debug log from the desktop: |
here is debug log for desktop that is now not sending or receiving after computer has been "suspended". Linked phone has new messages which are not on desktop version, |
I just noticed another clue. When Signal Desktop does not reflect recent messages delivered to Signal Android, the Ubuntu notification system still displays the first line or two of new messages. If one of those summaries is clicked, a GSConnect window, "Messaging: Andy's Phone," opens. Its left pane displays "No Conversations" which its right pane displays "No conversation selected. Select or start a conversation." GSConnect notifications are enabled in the Gnome notification settings. However, in Tweaks, GSConnect is turned off. This may just reflect that GSConnect is reporting new messages received by Signal Android, so I could disable the GSConnect notifications on the Ubuntu workstation. |
I've disabled GSConnect notifications on my workstation until we resolve this Signal Desktop synchronization failure. |
FYI, GSConnect (https://bit.ly/3BrRUIg) is a re-implementation of KDE Connect for Gnome, which provides phone/desktop communication and control. |
Very interesting! Thank you for investigating it. I'll file a bug internally, but would you care to submit this to Electron as well? It sounds like they might be interested in it too! |
It looks to me as though GSConnect reporting new Signal Android messages, even though GSConnect is disabled in Gnome, is a red herring with regard to Signal Desktop and Signal Android losing synchronization. We need to understand why synchronization is lost. |
@apiziali @timp34 Hey there! We now have an Electron Fiddle ready for you to test.
You can try lots of different versions of Electron really easily within Electron Fiddle, and you can also create packaged versions to see if that makes a difference too ( Please let us know what you find! This is the kind of thing that will give us really useful information to pass to Electron so they can get things fixed! |
Fantastic! Unfortunately, I am tied up for about ten days so I will pick this up around October 3.
Thank you!
…On September 23, 2022 4:58:05 PM MST, Scott Nonnenberg ***@***.***> wrote:
@apiziali @timp34 Hey there! We now have an Electron Fiddle ready for you to test.
1. First, download Electron Fiddle here: https://www.electronjs.org/fiddle
2. Then load up this Gist inside Electron Fiddle: https://gist.github.com/scottnonnenberg-signal/fc5174e6015c61fdae49ffe767d441bc
3. Then start it up on a recent version of Electron. Currently Signal Desktop is on 20.1.4.
4. Open the dev tools with `View -> Toggle Developer Tools` and watch the IPC `ping`/`pong` events go by.
5. Suspend your linux machine, then resume it. See if the `ping`/`pong` events continue, or just `ping` with no `pong`. If just `ping` then IPC has broken, just like it has with your Signal Desktop.
You can try lots of different versions of Electron really easily within Electron Fiddle, and you can also create packaged versions to see if that makes a difference too (`Tasks -> Package Fiddle`).
Please let us know what you find! This is the kind of thing that will give us really useful information to pass to Electron so they can get things fixed!
--
Andrew Piziali ***@***.***>
h t t p s : / / b i t . l y / A n d y P G P K e y
"The Great Reset represents the development of the Chinese system in the West, but in reverse. Whereas the Chinese political class began with a socialist political system and then introduced privately held for-profit production, the West began with capitalism and is now implementing a Chinese-style political system." -- Michael Rectenwald, "What Is The Great Reset?," "Imprimis," December 2021
|
Scott, following your instructions, I ran the test using Electron 20.1.4 and annotated the results in your message below. As you can see, without even introducing suspend/resume, no "pong" event are reported in the console: =============== First, download Electron Fiddle here: https://www.electronjs.org/fiddle Then load up this Gist inside Electron Fiddle: Then start it up on a recent version of Electron. Currently Signal Open the dev tools with View -> Toggle Developer Tools and watch the IPC
... |
@apiziali Your pasted log output is from the main process, which isn't where you'll see the 'pong' result. You need to start up the app, and open the dev tools with |
I think you need to run the Electron Fiddle and enable the dev tools in the running application, not the Electron Fiddle editor application. |
I have never used Electron Fiddle before, so I do not know how to enable the developer tools in the running application. |
Open the |
Okay. I now realize that you are referring to View > Toggle Developer Tools in the application (Chrome?) menus, not in the Electron Fiddle menus. I've run four suspend/resume cycles, at 1-, 2-, 4- and 8-minute intervals between the suspend and resume. In each case, the ping/pong continues. What log files do you want me to capture, and how do I do so? Thanks! |
@apiziali The best thing to do would be to do whatever seemed to cause the problem with Signal Desktop. We're looking to replicate that suspend/resume problem, which we believe would mean that the ping/pong would become just ping. |
Curiously, while running these tests, without restarting Signal, it continued to remain synchronized with Signal Android, as indicated by "Message to self" and a message sent from another user. |
Alright, I will just leave this application running as we use the workstation normally, suspending and resuming it throughout the day. Shall I just copy-and-paste the application console log when Signal Desktop loses synchronization with Signal Android? |
@apiziali Certainly we're interested in whether this behavior still happens for you on Signal Desktop. The key bit of data we're looking for is whether, when it happens on Signal Desktop, it also happens on Electron Fiddle. We're looking for the minimum bit of code that can cause the weirdness on your system to trigger. |
Signal Desktop has not lost synchronization with Signal Android since I started running your Gist. I then stopped the Gist in Electron Fiddle, but continued using the workstation and Signal as usual. Still, Signal Desktop remains synchronized. I quit the Electron Fiddle application and will monitor the behavior of Signal Desktop during the next few days of multiple suspend/resume cycles. This is a classic problem, right? You begin to investigate and diagnose an issue and it ceases to exist. Causal? Who knows? |
@apiziali It would be preferable to us if you kept the electron fiddle app running in the background all the time along with Signal Desktop, just to gather as much data as possible. |
Okay. I'll start it up again and we'll see if Signal loses synchronization. If it does, we'll have the fiddle app log. BTW, where will I find this log file? |
@apiziali When Signa Desktop stops working, all we need is the Signal Desktop log and the yes/no of whether Electron Fiddle is doing the full ping/pong in its dev tools, or just ping. |
I can confirm this still being an issue on Ubuntu 23.04 with:
I've attached the relevant parts of the log. The log starts while signal is still running normally. Then after hibernating the computer and waking it up the next day, Signal stops receiving or sending messages. |
To be double checked, but maybe this was fixed in v7.1.1 -> v7.2.1 ? |
Awesome, I'll close this then and if people experience it again they can let us know |
Nope, bug's still there.. |
@jamiebuilds-signal, can you please reopen? This bug isn't fixed. |
@obadz would you be willing to try the beta version to see if that helps? |
Hi @trevor-signal, I tried 7.4.0-beta.2 and it's not any better. |
I am not adding anything new; just to note this annoying bug has been with me for years. Each day, after the over-the-night suspension, I routinely begin my session by killing Signal and restarting it. Currently Ubuntu 22.04. While on another (office, never hybernating) computer with the same OS, it never happens. |
@fnevgeny are you using light-locker as noted above? |
No, just manually selecting "Power off->Suspend" (which I suppose does something like |
@fnevgeny can you share debug logs after this happens? And when you resume, does the app show that it's in a disconnected state? Do any messages arrive? Can any messages be sent? Thanks! |
No, there is no indication that it's in a disconnected state. I can neither send (there is a single circle, rotating forever, see below) nor receive new messages. Attaching the logs. In fact, this time, Signal survived over three nights. But the last suspend was fatal; the logs starting at 2024-05-15T06:45:02.048Z are from the limbo state. |
BTW, in this "limbo" state, File->Quit doesn't really quit the application, it only closes the GUI. So running the app again says
and the GUI reappears (but again, it can neither send nor receive messages). So I have to really |
Thanks, @fnevgeny , this info is useful. From the logs it looks like one of our worker threads is not responding after resume. We'll continue to investigate. |
I am experiencing this as well with Debian 12.5 and Signal Desktop. The machine is never suspended but I am using Xfce and lock my screen when I'm away from the computer. I'm going to be away from home for a few days but am happy to help debug this issue when I get back. |
Not sure about the OP or other people affected, but for me, at least one reason that reliably causes this "limbo" state is when I |
Still not working. |
As the author of the original bug report on September 1, 2022, I am following up because I recently updated my Linux workstation. After upgrading to Ubuntu 24.04 LTS and installing the latest Signal Desktop (currently 7.36.0), it now remains synchronized with my other Signal device, a Samsung Galaxy A21 phone running Android 12. Also, I should note that the Signal Desktop instance of a second user on the same Ubuntu 24.04 workstation also sees no issues. These two users are typically logged in simultaneously, using Switch User to change desktop sessions. |
Well, I did the 24.04 upgrade a month ago, and if anything has changed, it's the problem has become more severe - now, it happens every suspend. |
@fnevgeny , I used a clean 24.04 install because I've had poor experiences with using "apt upgrade" to migrate from an older Ubuntu version to a newer one. |
Just to be sure, is there everyone here experiencing this issue not using light-locker? We have multiple instances in the thread of people reporting a link with light-locker.
Below is a new bug report from the information I got from the thread. If something does not match your experience, feel free to comment below. Bug DescriptionWhen locking the computer for several minutes (either by suspending or manually locking), Signal Desktop becomes unresponsive upon unlocking. The behavior is as follows: Once Signal Desktop is restarted: Possible CauseThis issue may be related to how light-locker interacts with Signal Desktop during lock/unlock events. If this is indeed the case, it may be a niche problem, which could explain why it hasn’t received much attention. Suggested FixSignal Desktop should be able to detect this “frozen” state (e.g., when the application loses proper connectivity during a lock/suspend event) and reset itself automatically to restore normal functionality. |
I've upgraded to 7.36 on NixOS 25.11 (cherry picking NixOS/nixpkgs#364691) and I'm still experiencing the issue, so it's likely that what fixed yours is a change in different sleep settings in your fresh Ubuntu install vs what you had before rather than the new version of signal. |
@nigiord Correct. I am NOT using Light Locker. Rather, I am using the stock Gnome Display Manager's built-in screen lock. That screen lock does, by default, lock the screen on suspend. Although Signal works fine with this setting, I am turning it off because it is of no use in my environment. |
For me, locking never triggers the bug, only suspending.
I wouldn't call it "getting stuck" in the normal meaning. The GUI remains fully responsive; it just (apparently) loses network connectivity - or perhaps it loses connectivity to another thread in charge for the actual functionality.
It's different here. The GUI disappears immediately, but the process still runs in the background. Running the app again (without killing the process) pops the GUI instantly but in the same "frozen" state. |
With about a month into using Signal Desktop (now version 7.36.1), I can report that it still loses synchronization with Signal Android after a number of suspend/resumes, interspersed with switching back and forth between two users. I just received a chat from a friend on the phone, but it was never reported on the desktop. Furthermore, when Signal Desktop gets into this state, a File > Quit does nothing, other than close the open window and remove the "Show" option from the tray icon menu. This is the debug log I created: |
The recently closed bug report "[Linux: Signal doesn't reconnect after sleep or lock screen] #6027" looks quite similar to the issue I am seeing.
Bug Description
When I suspend and subsequently resume my Ubuntu 18.04 PC, the message queue of Signal Desktop no longer remains synchronized with my Signal Android. Every time I resume the PC, I need to restart Signal to see the latest messages already delivered to the mobile phone.
One other environment consideration is that this is a multi-user PC, with each of the two users logged in and running Signal. However, I believe I have seen the synchronization failure with only one active user session.
Steps to Reproduce
Actual Result:
Chats that were delivered to the mobile app are not delivered to the desktop application, as described in "Steps to Reproduce."
Expected Result:
When the workstation is resumed, Signal Desktop ought to reflect the chats that were delivered while the workstation was suspended.
Screenshots
Platform Info
Signal Version:
5.56.0 ... Production.
Operating System:
Ubuntu 18.04.6 LTS (uname -a : "Linux elijah 5.4.0-124-generic #140~18.04.1-Ubuntu SMP Fri Aug 5 11:43:34 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux")
Linked Device Version:
Samsung Galaxy A21, Android 11, One UI Core 3.1.
Link to Debug Log
https://debuglogs.org/desktop/5.56.0/33574877e6a4c8cdbd74fec3f7f09269a6c0281d6bb5a25e0a0db48626841da5.gz
https://debuglogs.org/android/5.47.3/83a1078f72b089d5d0f5996e170a937b768ab035e7ab9456d2141516ce61d8a4
debuglog.txt
The text was updated successfully, but these errors were encountered: