-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
Issues with push messages (service hanging until reboot / messages not processed) #31
Comments
@mar-v-in Here you go, the bug report I promised ;-) |
I assume a log is needed here. |
I just received some messages while the phone was in standby, so this is not entirely reproducible either. The bug above happened while being on a highway, so maybe it is related to unreliable data connection. Still, once the device re-gains connectivity, it should get the messages and notify me. Now, with other TextSecure messages having the same problem, maybe TextSecure is doing something suboptimal (I have no idea what they could do wrong), or maybe the Google implementation has its troubles as well. |
Textsecure uses the push message for a wakeup event and notification. Getting the message only when textsecure is in foreground could mean that microg has disconnected from the gms server, I experience the same issue. You should check your logcat if the heartbeat still occurs:
You can also check push functionality with a small app from play store called push notification tester |
I can try that; is there a way to get the logs from the time when adb is
I don't have play store. (Otherwise, why would I even be interested in |
Great, that seems to work. Next time I get delayed TextSecure messages, I'll check the logs. After some more days of experience I have to say though that often, messages do arrive on time, so I'm no longer sure this issue is actually in GMS rather than in TextSecure. EDIT: On the other hand, I haven't been in the same situation again that I was in when I experienced the bug: Driving over the highway at high speed, probably losing the connection to the mobile network every now and then. |
I have the same problem with the newest TextSecure version released. I tried to build the newest version of android_packages_apps_GmsCore because I have hoped to fix this, but now I'm reading this issue and am not sure... |
Ok, I used the Xposed-Module "FakeGapps" but I realized that I don't need it, because I have OmniRom installed. So I uninstalled FakeGapps and restarted, know everything works fine...
And I could not test Redphone jet. |
Can you try to use https://github.com/microg/android_packages_apps_GsfProxy ? |
Ok, now I get no error or warning at all. Thank you! |
After a few days (1.5 - 2) I have this problem again. The gcm haertbeat masseges in the logcat are not present then, too. After I restart the phone, everything gets back to normal. |
Can you provide a full log (maybe including the period where it was still working until it failed)? |
It was gone, but now it came back:
|
is it possible that at this point the internet connection was lost? Were you connected via mobile internet or WiFi? |
I think it could be a problem with my DNS. I was connected via wifi. But it did not reconnect when the DNS was working again. |
Hey there, |
I can confirm the issue with flight mode. I guess my wish concerning "reconnect on connectivity change" would solve this problem as well. |
This issue should be mostly done with 766a6a1. For nightly/git users: if problems persist, please report back here. |
After the installation of GsfProxy, Threema crashes when it receives a c2dm.intent.RECEIVE, i.e. a notification by GmsCore. The main difference after the installation of GsfProxy seems that Threema is no longer permanently running in the background: its messaging service is inactive, and the app simply waits to be waked up by GCM.
Reading the logcat, I am not sure whether GMS core is really responsible for the problem. It may be a Threema bug? It should also be noted that I have restricted parts of Threema with XPrivacy, so this may be the reason for the crash. (On the other hand, the only activity XPrivacy has listed when Threema received the c2dm.intent.RECEIVE was in fact c2dm.intent.RECEIVE.) |
Did you reinstall Threema after installing GsfProxy? |
I did a re-install without deinstalling it. I will try a proper re-install. |
Unfortunately, it still crashes. As far as I can tell, the logcat is still the same as above. |
Looking through the exception stack trace, this seems not to be related to GmsCore, however, as Threema is obfuscated non-free software, one can't say for sure. Can you try to disable XPrivacy for Threema? |
I have deactivated XPrivacy for Threema, and the crash still occurs. Since the installation of GsfProxy coincided with the release of a new Threema sub-version, this may be a bug of Threema that happens in my constellation. I will also take a look at the internal Threema log. |
Thanks for the note on the Threema update. Threema 2.52 does not work with GmsCore right now, as they use some undocumented feature of the deprecated C2DM API. Threema 2.51 should still work. I will provide a fix for the problem soon. |
Excellent, @mar-v-in . 2.51 worked without problems, but I also had not GsfProxy installed. I will see how Threema 2.51 behaves with GsfProxy and GmsCore both installed. |
Until the new version (v0.02 I guess – any estimate when it's due?) is released: what are known actions to revive GCM?
Apart from that: is there a way for non-devs (like me) to get hold of the "current dev APK" – something like a "nightly/weekly build"? That way we might help confirming whether a certain bug/misbehavior/other_strange_thing (count me in with this one, happens to me about once per week) was fixed or is having other side-effects. |
@SWW13 provides automated builds here: http://files.brnmod.rocks/apps/GmsCore/Latest/ |
v0.02 will be published soon (maybe next week) and I will start to provide "official" signed builds on a regular base afterwards (including updates through a f-droid repository) |
Thanks @julienschmidt – and of course @mar-v-in ! With that announcement, I guess I'll wait that little time and go with the official builds (they'll be more frequent then I take it?) due to signature and automatic updates (F-Droid). Looking forward to that announcement :) @mar-v-in might be useful to link those automated builds from the |
Since the upgrade to Threema 2.6, there seems to be again an issue with GCM. I am not sure whether this is (again) related to some undocumented command of GCM/C2DM that Threema uses or to a bug in Threema itself. (In the latter, maybe a version 2.61 will fix this. Note that I have indeed seen some reports about Push problems with Threema 2.6 and the official Google Play Services, but they may or may not be related to my problem. The general userbase does not seem to have any major problems.) The problem: Threema no longer seems to be able to register at the GCM service (com.google.android.c2dm.intent.REGISTRATION) nor does it receive any messages (com.google.android.c2dm.intent.RECEIVE - this is probably related to the failed registration). Threema offers the possibility to force a new REGISTRATION action ("Reset push token", see https://threema.ch/en/faq/push_andr ). The Threema log of Version 2.53 then reports:
XPrivacy shows that a REGISTRATION was executed, and the logcat (captured with catlog) shows that GMS Core connected to the Google push server. Receiving messages works as expected. This does not happen with version 2.6. The Threema log only shows
XPrivacy does not show a REGISTRATION action, and the logcat does not show anything either (not even an error). The only REGISTRATION that seems to happen is after the installation of Threema 2.6 (which is also intercepted - and allowed - by XPrivacy). It does not seem to have any effect because push messages do not arrive. (As mentioned, resetting the push token should again lead to a new REGISTRATION, which does not happen.) I am aware that this description (with a logcat that does not show anything special...) does not really help. To begin, I therefore can only ask: Should a developer want to look into this and not have a Threema licence, just send me a message, I will gladly sponsor one. To conclude, my system: EDIT: I have (finally) installed the tools to capture logcats via USB. As I am a noob, I will have to find out how I can capture more or useful information. Or does anyone know how to capture the information specifically of GMS Core? 2nd EDIT: I must do something wrong, the logcat does not show any information with entries like "GmsGcmMcsSvc." Have I to set GMS Core to a "verbose" mode or something similar? |
Just a little feedback: Heartbeat was just dead again here (still with the 0.01 of GmsCore installed). Did an |
Threema has been updated to 2.61. The good news is that the app now gets a com.google.android.c2dm.intent.RECEIVE if a new message has been sent to me. Unfortunately, Threema does not seem to process this, i.e. the app does nothing. Moreover, the manual renewal of the push registration token (i.e. the triggering of a com.google.android.c2dm.intent.REGISTER action) still does not seem to work (with the possible exception once after the installation of the update). |
Using 6.0.1 and the current nightlies installed as system apps. This time the heartbeat wasn't issued for several hours until I opened WhatsApp. This issue might be connected to #100. |
@xsmile answered in #100. This is very likely related. Everyone having issues with push notifications on Android 6.0: Please ensure that "Battery optimization" is disabled for microG Services Core in System Settings -> Battery -> Menu -> Battery optimization. Note that this is the case for original Play Services as it is required to keep a stable background connection. As far as I can tell from now, problems with GCM do not occur widely and/or are specific to certain apps and custom ROMs. I am closing this issue now. If you encounter a similar issue, please create a separate issue with all details. |
I have the following behavior with TextSecure, using the push messaging implementation from this project: TextSecure only seems to "notice" new messages when it is in foreground, on the screen.
For example, I had my phone in stand-by for a while, and I now know that I did receive some messages during that time. I then turned on the screen and unlocked the phone. I waited for ~10-20sec, nothing happened. I started TextSecure, and now I got all the notifications about the messages that I received.
The text was updated successfully, but these errors were encountered: