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

Nextcloud files app api is not responding - same time Deck works flawlessly #1312

Closed
grinapo opened this issue Aug 3, 2021 · 3 comments
Closed
Labels
Upstream :: SSO Single-Sign-On

Comments

@grinapo
Copy link

grinapo commented Aug 3, 2021

Describe the bug
The context is same as #710 and I tried to cast all the magic on it.

Two important difference:

  1. this is a miui 12.5.1 which is a horribly convoluted trashcan of underquality chinese rubbish, what I mean is that it has the nasty habit to kill anyone in dark alleys of the OS
  2. all other NC apps works, including Deck which I suppose use the exact same method to access.

Apart from that there's nothing special, everyone's non-battery-optimised, full permission, etc etc.

To Reproduce

  1. open notes
  2. slide down to refresh
  3. get timeout and error

Expected behavior
Refreshing, no error.

Smartphone (please complete the following information):
App Version: 3.4.11
App Version Code: 3004011
App Flavor: fdroid
Files App Version Code: 30160190
OS Version: 4.19.113-perf-g2816d656bab3(V12.5.1.0.RJDEUXM)
OS API Level: 30
Device: apollo
Manufacturer: Xiaomi
Model (and Product): M2007J3SG (apollopro_eea)

Server

  • Nextcloud version: 21.0.2
  • Nextcloud Notes version (server app): 4.0.4

Stacktrace


java.lang.RuntimeException: com.nextcloud.android.sso.exceptions.NextcloudApiNotRespondingException: Nextcloud files app api is not responding. Please report this issue.
	at io.reactivex.internal.util.ExceptionHelper.wrapOrThrow(ExceptionHelper.java:46)
	at io.reactivex.internal.observers.BlockingMultiObserver.blockingGet(BlockingMultiObserver.java:93)
	at io.reactivex.Maybe.blockingGet(Maybe.java:2321)
	at io.reactivex.Observable.blockingSingle(Observable.java:5381)
	at it.niedermann.owncloud.notes.persistence.NotesServerSyncTask.pullRemoteChanges(NotesServerSyncTask.java:219)
	at it.niedermann.owncloud.notes.persistence.NotesServerSyncTask.run(NotesServerSyncTask.java:96)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:462)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
	at java.lang.Thread.run(Thread.java:923)
Caused by: com.nextcloud.android.sso.exceptions.NextcloudApiNotRespondingException: Nextcloud files app api is not responding. Please report this issue.
	at com.nextcloud.android.sso.api.AidlNetworkRequest.waitForApi(AidlNetworkRequest.java:147)
	at com.nextcloud.android.sso.api.AidlNetworkRequest.performAidlNetworkRequestV2(AidlNetworkRequest.java:278)
	at com.nextcloud.android.sso.api.AidlNetworkRequest.performNetworkRequestV2(AidlNetworkRequest.java:165)
	at com.nextcloud.android.sso.api.NextcloudAPI.performNetworkRequestV2(NextcloudAPI.java:171)
	at com.nextcloud.android.sso.api.NextcloudAPI.lambda$performRequestObservableV2$1$NextcloudAPI(NextcloudAPI.java:110)
	at com.nextcloud.android.sso.api.-$$Lambda$NextcloudAPI$8WS9mapJbOYsPgbhBi25vBNYZqI.subscribe(Unknown Source:6)
	at io.reactivex.internal.operators.observable.ObservableFromPublisher.subscribeActual(ObservableFromPublisher.java:31)
	at io.reactivex.Observable.subscribe(Observable.java:12284)
	at io.reactivex.internal.operators.observable.ObservableSingleMaybe.subscribeActual(ObservableSingleMaybe.java:31)
	at io.reactivex.Maybe.subscribe(Maybe.java:4290)
	at io.reactivex.Maybe.blockingGet(Maybe.java:2320)
	... 8 more

@stefan-niedermann
Copy link
Member

this is a miui 12.5.1 which is a horribly convoluted trashcan of underquality chinese rubbish, what I mean is that it has the nasty habit to kill anyone in dark alleys of the OS

I know your feels... 😞 as a Xiaomi user who is exited about the hardware i can only recommend you to install a clean custom ROM to unfold the true potential of your device and get rid of all this mud.

all other NC apps works, including Deck

Since i am contributing to both apps, i can ensure you that there is not that much difference from a architectural point of view between both apps.
It is also confusing for me that one app is working and the other gets killed by MiUI, though we have had this issue also the other way around in the past where Deck did not work.

everyone's non-battery-optimised, full permission, etc etc.

The fix of the Deck app for the mentioned user was to permit auto start - maybe this is something you haven't done yet?
It is also always worth to try clearing the storage of the Notes Android App and the Nextcloud Android App and reimporting your accounts from scratch.

Unfortunately i can't do much more or give you another advice. Looks like MiUI is killing the bridge between the apps for no reasons.

Since this is really nothing i can fix in the 3rd party app itself, i'd like to point you upstream to the SingleSignOn library by Nextcloud - there is a corresponding issue for the NextcloudApiNotRespondingException - i already added this issue with your device specifics to the table there.

@grinapo
Copy link
Author

grinapo commented Aug 4, 2021

I know exatcly how you feel. 🙂

Results:

  1. autostart doesn't help
  2. force stopping-starting both doesn't, either
  3. clearing the full storage for Notes (only) does help. Indeed: re-selecting the account and re-downloading the data seems to have fixed the issue for now, but I will see whether I get the same as NextcloudApiNotResponding #710 after some weeks.

Danke!

(I was wondering whether it could be somehow pinpointed what have changed in the background. I guess that somehow android controls which app is allowed to send/receive messages (intents?) to which app and this permission seems to have lost/deleted/revoked somewhere somehow. I'll move over to the SSO issue. Thanks again.)

@stefan-niedermann
Copy link
Member

Thank you too and sorry that i can't provide more help. At least you made my day with

the chinese communist party

🤣

Wish you the best and again: You should install a custom ROM. I am watching the other issue too, so if there is some news, i will get notified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Upstream :: SSO Single-Sign-On
Projects
None yet
Development

No branches or pull requests

2 participants