NewPipe icon indicating copy to clipboard operation
NewPipe copied to clipboard

UI Crash When Navigating to Channel from Download Prompt

Open dragnev-dev opened this issue 1 year ago • 12 comments

Checklist

  • [X] I am able to reproduce the bug with the latest version given here: CLICK THIS LINK.
  • [X] I made sure that there are no existing issues - open or closed - which I could contribute my information to.
  • [X] I have read the FAQ and my problem isn't listed.
  • [X] I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • [X] This issue contains only one bug.
  • [X] I have read and understood the contribution guidelines.

Affected version

0.27.2

Steps to reproduce the bug

  1. Search for any keyword. Make sure you get videos and at least one channel as results
  2. Request a download for a video
  3. Before the prompt with video quality shows up, tap on a channel. The time interval for this on my device is around 2-3 secs

Expected behavior

Download prompt and opening a channel should work

Actual behavior

UI crash

Screenshots/Screen recordings

https://github.com/user-attachments/assets/6ad1eb14-e27d-4dc9-9b4d-ff3202ef461c

Logs

Exception

  • User Action: ui error
  • Request: ACRA report
  • Content Country: DE
  • Content Language: en-DE
  • App Language: en_DE_#u-fw-mon-mu-celsius
  • Service: none
  • Version: 0.27.2
  • OS: Linux Android 14 - 34
Crash log

java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
	at androidx.fragment.app.FragmentManager.checkStateLoss(FragmentManager.java:1632)
	at androidx.fragment.app.FragmentManager.enqueueAction(FragmentManager.java:1672)
	at androidx.fragment.app.BackStackRecord.commitInternal(BackStackRecord.java:341)
	at androidx.fragment.app.BackStackRecord.commit(BackStackRecord.java:306)
	at androidx.fragment.app.DialogFragment.show(DialogFragment.java:507)
	at org.schabi.newpipe.info_list.dialog.StreamDialogDefaultEntry.lambda$static$16(StreamDialogDefaultEntry.java:119)
	at org.schabi.newpipe.info_list.dialog.StreamDialogDefaultEntry.$r8$lambda$E-BGm7Z2EfgISHn-yX4TCRIhxak(StreamDialogDefaultEntry.java:0)
	at org.schabi.newpipe.info_list.dialog.StreamDialogDefaultEntry$$ExternalSyntheticLambda20.accept(R8$$SyntheticClass:0)
	at org.schabi.newpipe.util.SparseItemUtil.lambda$fetchStreamInfoAndSaveToDatabase$4(SparseItemUtil.java:121)
	at org.schabi.newpipe.util.SparseItemUtil.$r8$lambda$cfmnXoy0qdCzt8EeO-smvalxWsM(SparseItemUtil.java:0)
	at org.schabi.newpipe.util.SparseItemUtil$$ExternalSyntheticLambda0.accept(R8$$SyntheticClass:0)
	at io.reactivex.rxjava3.internal.observers.ConsumerSingleObserver.onSuccess(ConsumerSingleObserver.java:62)
	at io.reactivex.rxjava3.internal.operators.single.SingleObserveOn$ObserveOnSingleObserver.run(SingleObserveOn.java:81)
	at io.reactivex.rxjava3.android.schedulers.HandlerScheduler$ScheduledRunnable.run(HandlerScheduler.java:123)
	at android.os.Handler.handleCallback(Handler.java:959)
	at android.os.Handler.dispatchMessage(Handler.java:100)
	at android.os.Looper.loopOnce(Looper.java:232)
	at android.os.Looper.loop(Looper.java:317)
	at android.app.ActivityThread.main(ActivityThread.java:8501)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:554)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)


Affected Android/Custom ROM version

Android 14 / SuperiorOS fourteen

Affected device model

Redmi Note 5 AI

Additional information

Window Animation Scale 0.0x Transition Animation Scale 0.0x Animator Duration Scale 0.0x

dragnev-dev avatar Aug 23 '24 14:08 dragnev-dev

i just updated the app and issue is gone.see for updates in your app.

Debzoti avatar Aug 24 '24 06:08 Debzoti

i just updated the app and issue is gone.see for updates in your app.

  • [x] checked for updates in app
  • [x] checked for updates in GitHub releases
  • [x] checked for pinned issues with new versions

No updates found

dragnev-dev avatar Aug 24 '24 07:08 dragnev-dev

What happened? Did the bug go away?

opusforlife2 avatar Sep 19 '24 14:09 opusforlife2

No, I was on mobile. I'm not familiar with the GitHub UI so I mistakenly thought what would be a button to be a drop-down.

dragnev-dev avatar Sep 19 '24 14:09 dragnev-dev

Okay. Please post a screen record of the crash.

opusforlife2 avatar Sep 25 '24 12:09 opusforlife2

Added

dragnev-dev avatar Sep 25 '24 17:09 dragnev-dev

Thanks! Does this happen only with channels? Or also feeds, playlists, etc.?

opusforlife2 avatar Oct 03 '24 13:10 opusforlife2

Does this happen only with channels? Or also feeds, playlists, etc.?

Ok so which scenarios also trigger the bug. The OP scenario is you long press a video, tap download, then you navigate to a channel before the prompt for the download appears on the screen. Furthermore, cases which trigger the crash after requesting a download are:

  • [x] crashes when navigating to a playlist;
  • [x] crashes when navigating to a different screen through the burger button side menu (feeds, settings...);
  • [x] crashes when navigating to a channel through long-press on a video "Show channel details";
  • [x] if you request a download on a video from trending feed (no search applied), then calling a search and navigating to search, it crashes;
  • [ ] doesn't crash when navigating to a feed through the tabs in the top navigation;
  • [ ] doesn't crash when requesting video long-press actions "Start playing in a popup", "Add to playlist", "Share";
  • [ ] doesn't crash when navigating to a different service (SoundCloud, BandCamp...).

dragnev-dev avatar Oct 07 '24 14:10 dragnev-dev

Ok, so it happens when Newpipe opens an entirely new fragment. Thanks for testing!

opusforlife2 avatar Oct 07 '24 16:10 opusforlife2

Ok, so it happens when Newpipe opens an entirely new fragment.

Yes, it is related to downloader see #3163 & it is old one https://github.com/TeamNewPipe/NewPipe/issues?q=is%3Aissue+Can+not+perform+this+action+after+onSaveInstanceState+

ShareASmile avatar Oct 08 '24 17:10 ShareASmile

May I have this issue assigned to me? I can try to fix it.

letenger avatar Oct 19 '24 06:10 letenger

@elvakang You can do so, but there's a low probability of them being reviewed any time soon. If you're still okay with that, please go ahead!

ShareASmile avatar Oct 19 '24 10:10 ShareASmile