Hi,
I have (another) sporadically appearing stack trace for Deck on Android 10 Q, Google Pixel 4, which seems to appear after returning to the app left open in the background. I can, however, not reproduce it reliably - sorry for that...
Let me know if there is anything else I can provide to help you track this down.
Stacktrace
App Version: 1.5.6
App Version Code: 1005006
App Flavor: play
Deck Server Version: 1.0.4
Files App Version Code: 30120090
---
OS Version: 4.14.170-g666300e62136-ab6386400(6392402)
OS API Level: 29
Device: flame
Manufacturer: Google
Model (and Product): Pixel 4 (flame)
---
java.lang.NullPointerException: Attempt to invoke interface method 'void it.niedermann.nextcloud.deck.model.interfaces.IRemoteEntity.setAccountId(long)' on a null object reference
at it.niedermann.nextcloud.deck.persistence.sync.helpers.SyncHelper$1.onResponse(SyncHelper.java:40)
at it.niedermann.nextcloud.deck.persistence.sync.helpers.SyncHelper$1.onResponse(SyncHelper.java:34)
at it.niedermann.nextcloud.deck.persistence.sync.helpers.providers.CardDataProvider$1.onResponse(CardDataProvider.java:53)
at it.niedermann.nextcloud.deck.persistence.sync.helpers.providers.CardDataProvider$1.onResponse(CardDataProvider.java:48)
at it.niedermann.nextcloud.deck.api.RequestHelper$ResponseConsumer.accept(RequestHelper.java:64)
at io.reactivex.internal.observers.LambdaObserver.onNext(LambdaObserver.java:63)
at io.reactivex.internal.operators.observable.ObservableSubscribeOn$SubscribeOnObserver.onNext(ObservableSubscribeOn.java:58)
at io.reactivex.internal.operators.observable.ObservableFromPublisher$PublisherSubscriber.onNext(ObservableFromPublisher.java:56)
at com.nextcloud.android.sso.api.NextcloudAPI.lambda$performRequestObservable$0$NextcloudAPI(NextcloudAPI.java:86)
at com.nextcloud.android.sso.api.-$$Lambda$NextcloudAPI$yhhE-DMCe81fXF-bhjup5Tra-6o.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.ObservableSubscribeOn$SubscribeTask.run(ObservableSubscribeOn.java:96)
at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:578)
at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66)
at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:301)
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:919)
which seems to appear after returning to the app left open in the background.
Do you know which activity you had open before leaving the app? A board or a card in edit mode?
I remember relatively well that I had a board open but was not editing anything.
I don't see any UI-fails here, this seems to be a very strange background-sync behavior or something. I included a check here, just skipping things that are null, which doesn't make sense at all. This particular one shouldn't occur again after the commit above. If something else fails, please tell us, since I wasn't able to reproduce it in any way.
@stefan-niedermann please have a look at the commit. If I'm not just fully dumb, this should work, right? The next line is the setter-call, which would fail in any case, if the server returns null.
I suspect concurrent syncs (#554). The fix should do it, though. Please add a comment with a link to this issue and a Decklog.error() entry though.
@simonspa Please reopen if this happens again with version 1.8.0 or later. As always: Thanks for the report.
@stefan-niedermann done.