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

Resizing the app goes back to Trending #10777

Open
natebragg opened this issue Jan 22, 2024 · 14 comments
Open

Resizing the app goes back to Trending #10777

natebragg opened this issue Jan 22, 2024 · 14 comments
Labels
bug Issue is related to a bug device/software specific Issues that only happen on some devices or with some specific hardware/software GUI Issue is related to the graphical user interface

Comments

@natebragg
Copy link

I am using NewPipe on a Meta Quest 3 (unorthodox, I know). When using the curved, far away distance layout, you can resize the app both horizontally and vertically.

Whenever I have a different screen open (search, a video, etc.), resizing reopens the trending page. This will also stop video playback.

Since this is an unorthodox platform, and it's unlikely you have a meta quest 3 lying around, I am happy to work with you to resolve this. I am more than happy to act as a tester, or pair program, etc. If you can point me to a likely root cause, I'm even happy to try to work on the issue myself.

@opusforlife2 opusforlife2 added bug Issue is related to a bug GUI Issue is related to the graphical user interface device/software specific Issues that only happen on some devices or with some specific hardware/software labels Jan 25, 2024
@natebragg
Copy link
Author

Is there any hope of addressing this issue? It is quite irritating. I don't know if its the same root cause, but the same issue occurs in the ticket for the following comment suggesting a potential fix: connectbot/connectbot#1356 (comment)

@opusforlife2
Copy link
Collaborator

@DevanWolf Are you able to reproduce this?

@natebragg
Copy link
Author

@opusforlife2 @DevanWolf Any hope in getting some attention to this? It would be a huge quality of life improvement. Not only is this a problem normally, when launched via Lightning Launcher resizing NewPipe causes it to be completely black. The LL dev confirmed this was a bug in NewPipe, not LL.

@Velek
Copy link

Velek commented Aug 9, 2024

I just came here to report this issue myself. Trying to resize the window on my Quest 3 nearly completely crashed it.
I'm interested in investigating, but I could use some pointers.
Nothing on LogCat and the Android Studio debugger doesn't show anything either.

@opusforlife2
Copy link
Collaborator

The rewrite might fix this automatically, but that's an assumption on my part. Exoplayer was written a decade ago. Media3 belongs to the age of VR, so might have support for it.

@natebragg
Copy link
Author

@opusforlife2 forgive my ignorance, but what do you mean by the rewrite? I see the announcement in the 0.26 release notes Is there a way to keep up with the status? How's that coming along? Any idea how it could affect this issue?

@opusforlife2
Copy link
Collaborator

It's a pinned discussion. Check the tab.

There's no way to keep track of the process yet.

@natebragg
Copy link
Author

natebragg commented Aug 19, 2024

According to this comment, "this issue has to do with the android:configChanges manifest value". Given that, I think it's unlikely that the rewrite will fix it. It seems like it might be a relatively easy fix, though, would you be willing to take a look, @opusforlife2 ?

@natebragg
Copy link
Author

natebragg commented Aug 20, 2024

That mostly worked! I tested with and without videos playing, as well as from the subscriptions page. I both launched from lightning launcher and the stock Quest launcher, and both were fine. I wound up getting some App/UI crashed messages, though (resizing that activity worked as well).

One I got when resizing a playing video:

Exception

  • User Action: ui error
  • Request: ACRA report
  • Content Country: US
  • Content Language: en-US
  • App Language: en_US
  • Service: none
  • Version: 0.27.2
  • OS: Linux Android 12 - 32
    Crash log
android.view.InflateException: Binary XML file line #11 in org.schabi.newpipe:layout/chip: Binary XML file line #11 in org.schabi.newpipe:layout/chip: Error inflating class com.google.android.material.chip.Chip
Caused by: android.view.InflateException: Binary XML file line #11 in org.schabi.newpipe:layout/chip: Error inflating class com.google.android.material.chip.Chip
Caused by: java.lang.reflect.InvocationTargetException
	at java.lang.reflect.Constructor.newInstance0(Native Method)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
	at android.view.LayoutInflater.createView(LayoutInflater.java:858)
	at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:1010)
	at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:965)
	at android.view.LayoutInflater.inflate(LayoutInflater.java:663)
	at android.view.LayoutInflater.inflate(LayoutInflater.java:538)
	at org.schabi.newpipe.fragments.detail.BaseDescriptionFragment.lambda$addTagsMetadataItem$2(BaseDescriptionFragment.java:258)
	at org.schabi.newpipe.fragments.detail.BaseDescriptionFragment.$r8$lambda$6RhFoFd1bq2PAUteLa9HmwSd7eU(BaseDescriptionFragment.java:0)
	at org.schabi.newpipe.fragments.detail.BaseDescriptionFragment$$ExternalSyntheticLambda2.accept(R8$$SyntheticClass:0)
	at j$.util.stream.ForEachOps$ForEachOp$OfRef.accept(Unknown Source:2)
	at j$.util.stream.SortedOps$SizedRefSortingSink.end(Unknown Source:32)
	at j$.util.stream.AbstractPipeline.copyInto(Unknown Source:25)
	at j$.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source:10)
	at j$.util.stream.ForEachOps$ForEachOp.evaluateSequential(Unknown Source:0)
	at j$.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(Unknown Source:0)
	at j$.util.stream.AbstractPipeline.evaluate(Unknown Source:34)
	at j$.util.stream.ReferencePipeline.forEach(Unknown Source:5)
	at org.schabi.newpipe.fragments.detail.BaseDescriptionFragment.addTagsMetadataItem(BaseDescriptionFragment.java:257)
	at org.schabi.newpipe.fragments.detail.BaseDescriptionFragment.onCreateView(BaseDescriptionFragment.java:55)
	at androidx.fragment.app.Fragment.performCreateView(Fragment.java:3114)
	at androidx.fragment.app.FragmentStateManager.createView(FragmentStateManager.java:557)
	at androidx.fragment.app.FragmentStateManager.moveToExpectedState(FragmentStateManager.java:272)
	at androidx.fragment.app.FragmentManager.executeOpsTogether(FragmentManager.java:1943)
	at androidx.fragment.app.FragmentManager.removeRedundantOperationsAndExecute(FragmentManager.java:1839)
	at androidx.fragment.app.FragmentManager.execSingleAction(FragmentManager.java:1751)
	at androidx.fragment.app.BackStackRecord.commitNowAllowingStateLoss(BackStackRecord.java:323)
	at androidx.fragment.app.FragmentPagerAdapter.finishUpdate(FragmentPagerAdapter.java:249)
	at androidx.viewpager.widget.ViewPager.populate(ViewPager.java:1244)
	at androidx.viewpager.widget.ViewPager.setCurrentItemInternal(ViewPager.java:669)
	at androidx.viewpager.widget.ViewPager.setCurrentItemInternal(ViewPager.java:631)
	at androidx.viewpager.widget.ViewPager.dataSetChanged(ViewPager.java:1086)
	at androidx.viewpager.widget.ViewPager$PagerObserver.onChanged(ViewPager.java:3097)
	at androidx.viewpager.widget.PagerAdapter.notifyDataSetChanged(PagerAdapter.java:291)
	at org.schabi.newpipe.fragments.detail.TabAdapter.notifyDataSetUpdate(TabAdapter.java:86)
	at org.schabi.newpipe.fragments.detail.VideoDetailFragment.updateTabs(VideoDetailFragment.java:956)
	at org.schabi.newpipe.fragments.detail.VideoDetailFragment.handleResult(VideoDetailFragment.java:1486)
	at org.schabi.newpipe.fragments.detail.VideoDetailFragment.prepareAndHandleInfo(VideoDetailFragment.java:805)
	at org.schabi.newpipe.fragments.detail.VideoDetailFragment.lambda$prepareAndHandleInfoIfNeededAfterDelay$31(VideoDetailFragment.java:789)
	at org.schabi.newpipe.fragments.detail.VideoDetailFragment.$r8$lambda$XBVgQe9x2Lg_-6IUe5xCPF53bys(VideoDetailFragment.java:0)
	at org.schabi.newpipe.fragments.detail.VideoDetailFragment$$ExternalSyntheticLambda12.run(R8$$SyntheticClass:0)
	at android.os.Handler.handleCallback(Handler.java:938)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:214)
	at android.os.Looper.loop(Looper.java:304)
	at android.app.ActivityThread.main(ActivityThread.java:7960)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1010)
Caused by: android.content.res.Resources$NotFoundException: Can't find ColorStateList from drawable resource ID #0x7f06030c
	at android.content.res.ResourcesImpl.loadColorStateList(ResourcesImpl.java:1066)
	at android.content.res.Resources.loadColorStateList(Resources.java:1139)
	at android.content.res.TypedArray.getColorStateList(TypedArray.java:601)
	at android.widget.TextView.readTextAppearance(TextView.java:4056)
	at android.widget.TextView.<init>(TextView.java:1125)
	at android.widget.Button.<init>(Button.java:166)
	at android.widget.CompoundButton.<init>(CompoundButton.java:104)
	at android.widget.CheckBox.<init>(CheckBox.java:71)
	at android.widget.CheckBox.<init>(CheckBox.java:67)
	at androidx.appcompat.widget.AppCompatCheckBox.<init>(AppCompatCheckBox.java:79)
	at com.google.android.material.chip.Chip.<init>(Chip.java:207)
	at com.google.android.material.chip.Chip.<init>(Chip.java:203)
	... 49 more

Another one (ocurred when playing this video from Trending after launching the app) was:

Exception

  • User Action: ui error
  • Request: ACRA report
  • Content Country: US
  • Content Language: en-US
  • App Language: en_US
  • Service: none
  • Version: 0.27.2
  • OS: Linux Android 12 - 32

Crash Log

java.lang.IllegalStateException: Fragment already added: DescriptionFragment{4668245} (afa7e90c-af04-4177-b3db-44debbf9f66c id=0x7f0a040e tag=android:switcher:2131362830:1)
	at androidx.fragment.app.FragmentStore.addFragment(FragmentStore.java:93)
	at androidx.fragment.app.FragmentManager.addFragment(FragmentManager.java:1503)
	at androidx.fragment.app.BackStackRecord.executeOps(BackStackRecord.java:387)
	at androidx.fragment.app.FragmentManager.executeOps(FragmentManager.java:2009)
	at androidx.fragment.app.FragmentManager.executeOpsTogether(FragmentManager.java:1895)
	at androidx.fragment.app.FragmentManager.removeRedundantOperationsAndExecute(FragmentManager.java:1839)
	at androidx.fragment.app.FragmentManager.execSingleAction(FragmentManager.java:1751)
	at androidx.fragment.app.BackStackRecord.commitNowAllowingStateLoss(BackStackRecord.java:323)
	at androidx.fragment.app.FragmentPagerAdapter.finishUpdate(FragmentPagerAdapter.java:249)
	at androidx.viewpager.widget.ViewPager.populate(ViewPager.java:1244)
	at androidx.viewpager.widget.ViewPager.populate(ViewPager.java:1092)
	at androidx.viewpager.widget.ViewPager.onMeasure(ViewPager.java:1622)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at androidx.coordinatorlayout.widget.CoordinatorLayout.onMeasureChild(CoordinatorLayout.java:760)
	at com.google.android.material.appbar.HeaderScrollingViewBehavior.onMeasureChild(HeaderScrollingViewBehavior.java:100)
	at com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior.onMeasureChild(AppBarLayout.java:2381)
	at androidx.coordinatorlayout.widget.CoordinatorLayout.onMeasure(CoordinatorLayout.java:831)
	at android.view.View.measure(View.java:25833)
	at android.widget.LinearLayout.measureHorizontal(LinearLayout.java:1383)
	at android.widget.LinearLayout.onMeasure(LinearLayout.java:723)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.FrameLayout.onMeasure(FrameLayout.java:194)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.FrameLayout.onMeasure(FrameLayout.java:194)
	at android.view.View.measure(View.java:25833)
	at com.google.android.material.bottomsheet.BottomSheetBehavior.onMeasureChild(BottomSheetBehavior.java:515)
	at androidx.coordinatorlayout.widget.CoordinatorLayout.onMeasure(CoordinatorLayout.java:831)
	at android.view.View.measure(View.java:25833)
	at androidx.drawerlayout.widget.DrawerLayout.onMeasure(DrawerLayout.java:1156)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.FrameLayout.onMeasure(FrameLayout.java:194)
	at androidx.appcompat.widget.ContentFrameLayout.onMeasure(ContentFrameLayout.java:145)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1552)
	at android.widget.LinearLayout.measureVertical(LinearLayout.java:842)
	at android.widget.LinearLayout.onMeasure(LinearLayout.java:721)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.FrameLayout.onMeasure(FrameLayout.java:194)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1552)
	at android.widget.LinearLayout.measureVertical(LinearLayout.java:842)
	at android.widget.LinearLayout.onMeasure(LinearLayout.java:721)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6980)
	at android.widget.FrameLayout.onMeasure(FrameLayout.java:194)
	at com.android.internal.policy.DecorView.onMeasure(DecorView.java:758)
	at android.view.View.measure(View.java:25833)
	at android.view.ViewRootImpl.performMeasure(ViewRootImpl.java:3718)
	at android.view.ViewRootImpl.measureHierarchy(ViewRootImpl.java:2487)
	at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2775)
	at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:2206)
	at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:8875)
	at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1037)
	at android.view.Choreographer.doCallbacks(Choreographer.java:845)
	at android.view.Choreographer.doFrame(Choreographer.java:780)
	at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1022)
	at android.os.Handler.handleCallback(Handler.java:938)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:214)
	at android.os.Looper.loop(Looper.java:304)
	at android.app.ActivityThread.main(ActivityThread.java:7960)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1010)

@natebragg
Copy link
Author

To further clarify, after uninstalling this and reinstalling the current 0.27.2 release, I did not see these two errors. So, I'm not sure if you based this directly off of that release and this is due to your change, or if you modified HEAD and this is someone else's bug.

@DevanWolf
Copy link

That mostly worked! I tested with and without videos playing, as well as from the subscriptions page. I both launched from lightning launcher and the stock Quest launcher, and both were fine. I wound up getting some App/UI crashed messages, though (resizing that activity worked as well).

Due to that, I reverted that by removing the configChanges from the main activity.

@natebragg
Copy link
Author

Unfortunately, the same errors occurred on this new build, and now resizing no longer works again.

@opusforlife2
Copy link
Collaborator

would you be willing to take a look

I'm not a dev, so I can't help you there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue is related to a bug device/software specific Issues that only happen on some devices or with some specific hardware/software GUI Issue is related to the graphical user interface
Projects
None yet
Development

No branches or pull requests

4 participants