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

checkNewNotifications() does not work with more energy-efficient HEAD requests in SSO service #68

Open
0x50f13 opened this issue Nov 18, 2023 · 3 comments
Labels
bug Something isn't working investigate The issue requires investigation and currently can't be labeled as bug or feature request certainly

Comments

@0x50f13
Copy link
Owner

0x50f13 commented Nov 18, 2023

The following error occurs during call to checkNotifications() which is used for traffic-efficient notifications check(see #62)

2023-11-18 18:50:17.575  6793-6793  Services.S...Controller com.polar.nextcloudservices          D  Got status: Updating settings
2023-11-18 18:50:17.575  6793-6793  Services.S...Controller com.polar.nextcloudservices          D  Component id: 3
2023-11-18 18:50:17.575  6793-6793  Services.S...Controller com.polar.nextcloudservices          D  Component prio: 1
2023-11-18 18:50:17.576  6793-6793  com.nextcl...orkRequest com.polar.nextcloudservices          D  [onServiceConnected] called from Thread: [main] with IBinder [ComponentInfo{com.nextcloud.client/com.owncloud.android.services.AccountManagerService}]: android.os.BinderProxy@2162625
2023-11-18 18:50:17.582  6793-10828 com.nextcl...orkRequest com.polar.nextcloudservices          D  copy data from service finished
2023-11-18 18:50:18.670  6793-1628  NextcloudSSOAPI         com.polar.nextcloudservices          D  lastETag="6cdbe52036a68f47ca9eae0a5c153c02"
2023-11-18 18:50:18.670  6793-1628  NextcloudSSOAPI         com.polar.nextcloudservices          D  mETag=
2023-11-18 18:50:18.670  6793-1628  NextcloudSSOAPI         com.polar.nextcloudservices          D  New notifications found
2023-11-18 18:50:18.670  6793-1628  NextcloudSSOAPI         com.polar.nextcloudservices          D  getNotifications
2023-11-18 18:50:18.673  6793-10835 com.nextcl...orkRequest com.polar.nextcloudservices          D  copy data from service finished
2023-11-18 18:50:18.709  6793-6793  SettingsAc...gsFragment com.polar.nextcloudservices          D  onPause called
2023-11-18 18:50:18.875  6793-1628  System.err              com.polar.nextcloudservices          W  android.os.DeadObjectException
2023-11-18 18:50:18.876  6793-1628  System.err              com.polar.nextcloudservices          W  	at android.os.BinderProxy.transactNative(Native Method)
2023-11-18 18:50:18.876  6793-1628  System.err              com.polar.nextcloudservices          W  	at android.os.BinderProxy.transact(BinderProxy.java:584)
2023-11-18 18:50:18.876  6793-6793  com.nextcl...orkRequest com.polar.nextcloudservices          W  [onServiceDisconnected] [ComponentInfo{com.nextcloud.client/com.owncloud.android.services.AccountManagerService}]
2023-11-18 18:50:18.876  6793-6793  com.nextcl...orkRequest com.polar.nextcloudservices          D  [onServiceDisconnected] Reconnecting lost service connection to component: [ComponentInfo{com.nextcloud.client/com.owncloud.android.services.AccountManagerService}]
2023-11-18 18:50:18.876  6793-6793  com.nextcl...orkRequest com.polar.nextcloudservices          D  [reconnect] called
2023-11-18 18:50:18.876  6793-6793  com.nextcl...orkRequest com.polar.nextcloudservices          D  [unbindService] Unbinding AccountManagerService
2023-11-18 18:50:18.876  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.nextcloud.android.sso.aidl.IInputStreamService$Stub$Proxy.performNextcloudRequestV2(IInputStreamService.java:312)
2023-11-18 18:50:18.877  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.nextcloud.android.sso.api.AidlNetworkRequest.performAidlNetworkRequestV2(AidlNetworkRequest.java:313)
2023-11-18 18:50:18.877  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.nextcloud.android.sso.api.AidlNetworkRequest.performNetworkRequestV2(AidlNetworkRequest.java:180)
2023-11-18 18:50:18.878  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.nextcloud.android.sso.api.NextcloudAPI.performNetworkRequestV2(NextcloudAPI.java:199)
2023-11-18 18:50:18.886  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.polar.nextcloudservices.API.NextcloudSSOAPI.getNotifications(NextcloudSSOAPI.java:73)
2023-11-18 18:50:18.886  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.polar.nextcloudservices.Services.PollTask.doInBackground(NotificationService.java:40)
2023-11-18 18:50:18.886  6793-1628  System.err              com.polar.nextcloudservices          W  	at com.polar.nextcloudservices.Services.PollTask.doInBackground(NotificationService.java:31)
2023-11-18 18:50:18.886  6793-1628  System.err              com.polar.nextcloudservices          W  	at android.os.AsyncTask$3.call(AsyncTask.java:394)
2023-11-18 18:50:18.887  6793-1628  System.err              com.polar.nextcloudservices          W  	at java.util.concurrent.FutureTask.run(FutureTask.java:264)
2023-11-18 18:50:18.887  6793-1628  System.err              com.polar.nextcloudservices          W  	at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:305)
2023-11-18 18:50:18.887  6793-1628  System.err              com.polar.nextcloudservices          W  	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
2023-11-18 18:50:18.887  6793-1628  System.err              com.polar.nextcloudservices          W  	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
@0x50f13 0x50f13 added bug Something isn't working investigate The issue requires investigation and currently can't be labeled as bug or feature request certainly labels Nov 18, 2023
@0x50f13 0x50f13 changed the title checkNotification() does not work for SSO service checkNotifications() does not work for SSO service Nov 18, 2023
@0x50f13 0x50f13 changed the title checkNotifications() does not work for SSO service checkNewNotifications() does not work for SSO service Nov 18, 2023
@sleibrock
Copy link

Is there any update on this? I'd love to help out if able to. Trying to get my users onboarded and SSO would be nice to have if it works.

@0x50f13 0x50f13 changed the title checkNewNotifications() does not work for SSO service checkNewNotifications() does not work with more energy-efficient HEAD requests in SSO service Mar 5, 2024
@0x50f13
Copy link
Owner Author

0x50f13 commented Mar 5, 2024

@sleibrock Hello. Sorry, probably, my issue title was quite misleading. The issue is about that currently due to limitations(or bugs?) of Nextcloud SSO API I can not do efficient checks for notifications(i.e. HEAD-requests which reduce data usage)

@sleibrock
Copy link

Thank you, it wasn't clear if this was tied to SSO not functioning, but it appears after a few days of testing that SSO does in fact work for notification polling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working investigate The issue requires investigation and currently can't be labeled as bug or feature request certainly
Projects
None yet
Development

No branches or pull requests

2 participants