TeamNewPipe / NewPipe

A libre lightweight streaming front-end for Android.
https://newpipe.net
GNU General Public License v3.0
31.07k stars 3.02k forks source link

Release 0.20.0 #4332

Closed TobiGr closed 3 years ago

TobiGr commented 3 years ago

Changelogs

App

New

Improved

Fixed

Development

Extractor

Improved

APK for testing

NewPipe_v0.20.0RC7.zip Corresponding PR: #4333

opusforlife2 commented 3 years ago

No problem. It was noted in #3178, but we were getting too late with the release so we decided to postpone this bug fix to the next release.

Pentaphon commented 3 years ago

No problem. It was noted in #3178, but we were getting too late with the release so we decided to postpone this bug fix to the next release.

So, what's the last bug blocking this release?

opusforlife2 commented 3 years ago

None so far, unless someone finds one in this RC.

avently commented 3 years ago

@Pentaphon #4347 contains some fixes. As I know nothing important should be fixed afterwards

opusforlife2 commented 3 years ago

Should we consider the second bug here https://github.com/TeamNewPipe/NewPipe/issues/4332#issuecomment-699863945 a release blocker?

Pentaphon commented 3 years ago

4347 contains some fixes. As I know nothing important should be fixed afterwards

I think your fixes are worth including in this release. I hope the devs merge them before releasing .20

Should we consider the second bug here #4332 (comment) a release blocker?

Looking at it now, I would say no. That's something that can wait for 0.20.1

avently commented 3 years ago

@opusforlife2 I even not considering it as a bug. You have to do unusual things in order to reproduce it. It doesn't cost a minute of developer time. However it can be fixed with one line of code in player.xml

opusforlife2 commented 3 years ago

What is that line and where should it be written? I'll open a PR. :3

avently commented 3 years ago

What is that line and where should it be written? I'll open a PR. :3

after this line: https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/res/layout/player.xml#L464 add:

android:clickable="true"
android:focusable="true"

even clickable is enough but IDEA asks the second line too.

If you add the same code to Android TV https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/res/layout-large-land/player.xml it will not work with D-pad since in this case Android don't care about these attributes and still allows to select views under queue. And we can't disallow showing controls while queue is visible because it will break focusability of the whole player. So only work for mouse/taps but not for D-pad.

Stypox commented 3 years ago

@RickyM7 could you provide me with the newpipe.settings file you had to delete in order to get NewPipe to work? This way I would be able to fix the issue. If you don't have that file anymore or you are not comfortable sharing it, could you provide the crash report?

In case someone's wondering why I deleted two comments, I squashed some comments into one, thus deleting the now-squashed parts

ghost commented 3 years ago

All age restricted videos cause the app to crash for me with a ui error. For example this video: https://www.youtube.com/watch?v=4Veqe0-8k9U I have restricted content enabled and this doesn't happen in 19.8

Exception

java.lang.IndexOutOfBoundsException: Index: 0
    at java.util.Collections$EmptyList.get(Collections.java:4511)
    at org.schabi.newpipe.player.helper.PlayerHelper.autoQueueOf(PlayerHelper.java:178)
    at org.schabi.newpipe.player.BasePlayer.maybeAutoQueueNextStream(BasePlayer.java:1396)
    at org.schabi.newpipe.player.BasePlayer.maybeUpdateCurrentMetadata(BasePlayer.java:1380)
    at org.schabi.newpipe.player.BasePlayer.onTimelineChanged(BasePlayer.java:731)
    at org.schabi.newpipe.player.VideoPlayerImpl.onTimelineChanged(VideoPlayerImpl.java:619)
    at com.google.android.exoplayer2.ExoPlayerImpl$PlaybackInfoUpdate.lambda$run$0$ExoPlayerImpl$PlaybackInfoUpdate(ExoPlayerImpl.java:804)
    at com.google.android.exoplayer2.-$$Lambda$ExoPlayerImpl$PlaybackInfoUpdate$N_S5kRfhaRTAkH28P5luFgKnFjQ.invokeListener(Unknown Source:2)
    at com.google.android.exoplayer2.BasePlayer$ListenerHolder.invoke(BasePlayer.java:182)
    at com.google.android.exoplayer2.ExoPlayerImpl.invokeAll(ExoPlayerImpl.java:845)
    at com.google.android.exoplayer2.ExoPlayerImpl.access$000(ExoPlayerImpl.java:43)
    at com.google.android.exoplayer2.ExoPlayerImpl$PlaybackInfoUpdate.run(ExoPlayerImpl.java:802)
    at com.google.android.exoplayer2.ExoPlayerImpl.notifyListeners(ExoPlayerImpl.java:736)
    at com.google.android.exoplayer2.ExoPlayerImpl.updatePlaybackInfo(ExoPlayerImpl.java:710)
    at com.google.android.exoplayer2.ExoPlayerImpl.handlePlaybackInfo(ExoPlayerImpl.java:652)
    at com.google.android.exoplayer2.ExoPlayerImpl.handleEvent(ExoPlayerImpl.java:595)
    at com.google.android.exoplayer2.ExoPlayerImpl$1.handleMessage(ExoPlayerImpl.java:127)
    at android.os.Handler.dispatchMessage(Handler.java:107)
    at android.os.Looper.loop(Looper.java:237)
    at android.app.ActivityThread.main(ActivityThread.java:8107)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:496)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1100)


RickyM7 commented 3 years ago

@Stypox I'm sorry but I don't have the file anymore, however, to have the same file just do a backup of version v0.19.8, if you want I can do that. Regarding the crash report, there is no one, the app closes before even presenting a report.

Stypox commented 3 years ago

if you want I can do that.

@RickyM7 yes, please do that (with your old settings, if you haven't deleted them already), as I can't reproduce with my settings.

All age restricted videos cause the app to crash for me with a ui error.

@TheProgrammingDog see #4112, will be fixed in the next RC apk thanks to #4349

TobiGr commented 3 years ago

RC3: Fix crash when there are no streams to queue for auto-play #4349 NewPipe_v0.20.0RC3.zip

RickyM7 commented 3 years ago

@Stypox I'm sorry, I couldn't reproduce the bug, unfortunately I no longer have my old settings, but I imagine it is something related to age restriction too, but I'm not sure.

ghost commented 3 years ago

This is kinda hard to describe but if you open and then minimise a video in landscape, when you go to close it if you mis-click to the right of the X you can end up tapping a video in the next up list.

It happens more on my table probably because there's a bigger gap between the X and the edge of the screen.

avently commented 3 years ago

@test2a

i have had this glitch when switching to and back from fullscreen video, the screen flashes black for a second

did you try the newest apk? What do you say about performance and this glitch?

Only release apk in the archive can show the real performance. Debug apk adds additional costs so it's not good as a measuring method

vkay94 commented 3 years ago

Out of curiosity: Is it intended that you can add the same stream multiple times to a single playlist? For example this flow/loop: A -> B -> C -> A -> B -> ...

Stypox commented 3 years ago

@Redirion did you see my comments above? https://github.com/TeamNewPipe/NewPipe/issues/4332#issuecomment-700134989

TobiGr commented 3 years ago

@vkay94: Out of curiosity: Is it intended that you can add the same stream multiple times to a single playlist? For example this flow/loop: A -> B -> C -> A -> B -> ...

Yes

opusforlife2 commented 3 years ago

If you add the same code to Android TV https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/res/layout-large-land/player.xml it will not work with D-pad since in this case Android don't care about these attributes and still allows to select views under queue. And we can't disallow showing controls while queue is visible because it will break focusability of the whole player. So only work for mouse/taps but not for D-pad.

@avently So I won't touch the Android TV file, then. I'll just edit the player layout file and add those two lines.

TobiGr commented 3 years ago

RC4 fixes endless loading specific streams. NewPipe_v0.20.0RC4.zip

Flam3z commented 3 years ago

Are there any possible dates on the table of when this version may be released?

Redirion commented 3 years ago

@Redirion did you see my comments above? #4332 (comment)

I have yet to reproduce the issue. Did only happen once and I didn't want to waste the stacktrace, so I did directly comment it here while I was on the road. I think it can for now be marked as resolved.

ghost commented 3 years ago

0.20.0 RC4 behave smoothly, there are few memory leaks (and stack and dumps) I've collected from few cases, first is on the very first search after the program starts cold (always returns no results, until you search again I don't think there is a bug for that yet), second is memory leak when trying to refresh an empty subscription list.

please make the 'report bug' persistence and do not make its container disappear so fast, I've missed it twice already.

┬───
│ GC Root: System class
│
├─ leakcanary.internal.InternalLeakCanary class
│    Leaking: NO (MainActivity↓ is not leaking and a class is never leaking)
│    ↓ static InternalLeakCanary.resumedActivity
├─ org.schabi.newpipe.MainActivity instance
│    Leaking: NO (MainFragment↓ is not leaking and Activity#mDestroyed is false)
│    ↓ MainActivity.mFragments
├─ androidx.fragment.app.FragmentController instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentController.mHost
├─ androidx.fragment.app.FragmentActivity$HostCallbacks instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentActivity$HostCallbacks.mFragmentManager
├─ androidx.fragment.app.FragmentManagerImpl instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentManagerImpl.mBackStack
├─ java.util.ArrayList instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ Object[].[0]
├─ androidx.fragment.app.BackStackRecord instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ BackStackRecord.mOps
├─ java.util.ArrayList instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ Object[].[0]
├─ androidx.fragment.app.FragmentTransaction$Op instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentTransaction$Op.mFragment
├─ org.schabi.newpipe.fragments.MainFragment instance
│    Leaking: NO (Fragment#mFragmentManager is not null)
│    ↓ MainFragment.viewPager
│                   ~~~~~~~~~
├─ androidx.viewpager.widget.ViewPager instance
│    Leaking: YES (View detached and has parent)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View#mParent is set
│    View#mAttachInfo is null (view detached)
│    View.mID = R.id.pager
│    View.mWindowAttachCount = 1
│    ↓ ViewPager.mChildren
├─ android.view.View[] array
│    Leaking: YES (ViewPager↑ is leaking)
│    ↓ View[].[0]
╰→ android.widget.RelativeLayout instance
​     Leaking: YES (ObjectWatcher was watching this because org.schabi.newpipe.fragments.list.kiosk.DefaultKioskFragment received Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks) and View detached and has parent)
​     key = f8c136bb-6f97-4fc3-a880-d65cd45a51a5
​     watchDurationMillis = 10334
​     retainedDurationMillis = 330
​     key = b2b720c0-0582-48a8-bdd1-35e6372e925b
​     watchDurationMillis = 10331
​     retainedDurationMillis = 326
​     mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
​     View#mParent is set
​     View#mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1

METADATA

Build.VERSION.SDK_INT: 21
Build.MANUFACTURER: samsung
LeakCanary version: 2.2
App process name: org.schabi.newpipe.debug.release0200
Analysis duration: 83184 ms 
┬───
│ GC Root: System class
│
├─ org.schabi.newpipe.player.helper.PlayerHolder class
│    Leaking: NO (VideoDetailFragment↓ is not leaking and a class is never leaking)
│    ↓ static PlayerHolder.listener
├─ org.schabi.newpipe.fragments.detail.VideoDetailFragment instance
│    Leaking: NO (MainFragment↓ is not leaking and Fragment#mFragmentManager is not null)
│    ↓ VideoDetailFragment.mFragmentManager
├─ androidx.fragment.app.FragmentManagerImpl instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentManagerImpl.mCreatedMenus
├─ java.util.ArrayList instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ Object[].[1]
├─ org.schabi.newpipe.fragments.MainFragment instance
│    Leaking: NO (Fragment#mFragmentManager is not null)
│    ↓ MainFragment.pagerAdapter
│                   ~~~~~~~~~~~~
├─ org.schabi.newpipe.fragments.MainFragment$SelectedTabsPagerAdapter instance
│    Leaking: UNKNOWN
│    ↓ MainFragment$SelectedTabsPagerAdapter.mObservable
│                                            ~~~~~~~~~~~
├─ android.database.DataSetObservable instance
│    Leaking: UNKNOWN
│    ↓ DataSetObservable.mObservers
│                        ~~~~~~~~~~
├─ java.util.ArrayList instance
│    Leaking: UNKNOWN
│    ↓ ArrayList.array
│                ~~~~~
├─ java.lang.Object[] array
│    Leaking: UNKNOWN
│    ↓ Object[].[1]
│               ~~~
├─ com.google.android.material.tabs.TabLayout$PagerAdapterObserver instance
│    Leaking: UNKNOWN
│    ↓ TabLayout$PagerAdapterObserver.this$0
│                                     ~~~~~~
├─ org.schabi.newpipe.views.ScrollableTabLayout instance
│    Leaking: YES (View detached and has parent)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View#mParent is set
│    View#mAttachInfo is null (view detached)
│    View.mID = R.id.main_tab_layout
│    View.mWindowAttachCount = 1
│    ↓ ScrollableTabLayout.mParent
╰→ android.widget.RelativeLayout instance
​     Leaking: YES (ObjectWatcher was watching this because org.schabi.newpipe.fragments.MainFragment received Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks))
​     key = 09e644f6-5db6-429a-a111-382403b925c9
​     watchDurationMillis = 10315
​     retainedDurationMillis = 314
​     key = e41ed238-587d-43a2-95ae-9ff7e707ce88
​     watchDurationMillis = 10314
​     retainedDurationMillis = 304
​     mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
​     View#mParent is null
​     View#mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1

METADATA

Build.VERSION.SDK_INT: 21
Build.MANUFACTURER: samsung
LeakCanary version: 2.2
App process name: org.schabi.newpipe.debug.release0200
Analysis duration: 81132 ms 
┬───
│ GC Root: System class
│
├─ leakcanary.internal.InternalLeakCanary class
│    Leaking: NO (MainActivity↓ is not leaking and a class is never leaking)
│    ↓ static InternalLeakCanary.resumedActivity
├─ org.schabi.newpipe.MainActivity instance
│    Leaking: NO (FocusAwareDrawerLayout↓ is not leaking and Activity#mDestroyed is false)
│    ↓ MainActivity.drawer
├─ org.schabi.newpipe.views.FocusAwareDrawerLayout instance
│    Leaking: NO (NewPipeRecyclerView↓ is not leaking and View attached)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View.parent androidx.appcompat.widget.ContentFrameLayout attached as well
│    View#mParent is set
│    View#mAttachInfo is not null (view attached)
│    View.mID = R.id.drawer_layout
│    View.mWindowAttachCount = 1
│    ↓ FocusAwareDrawerLayout.mAttachInfo
├─ android.view.View$AttachInfo instance
│    Leaking: NO (NewPipeRecyclerView↓ is not leaking)
│    ↓ View$AttachInfo.mScrollContainers
├─ java.util.ArrayList instance
│    Leaking: NO (NewPipeRecyclerView↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (NewPipeRecyclerView↓ is not leaking)
│    ↓ Object[].[3]
├─ org.schabi.newpipe.views.NewPipeRecyclerView instance
│    Leaking: NO (View attached)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View.parent android.widget.RelativeLayout attached as well
│    View#mParent is set
│    View#mAttachInfo is not null (view attached)
│    View.mID = R.id.items_list
│    View.mWindowAttachCount = 1
│    ↓ NewPipeRecyclerView.mAdapter
│                          ~~~~~~~~
├─ org.schabi.newpipe.info_list.InfoListAdapter instance
│    Leaking: UNKNOWN
│    ↓ InfoListAdapter.mObservable
│                      ~~~~~~~~~~~
├─ androidx.recyclerview.widget.RecyclerView$AdapterDataObservable instance
│    Leaking: UNKNOWN
│    ↓ RecyclerView$AdapterDataObservable.mObservers
│                                         ~~~~~~~~~~
├─ java.util.ArrayList instance
│    Leaking: UNKNOWN
│    ↓ ArrayList.array
│                ~~~~~
├─ java.lang.Object[] array
│    Leaking: UNKNOWN
│    ↓ Object[].[1]
│               ~~~
├─ androidx.recyclerview.widget.RecyclerView$RecyclerViewDataObserver instance
│    Leaking: UNKNOWN
│    ↓ RecyclerView$RecyclerViewDataObserver.this$0
│                                            ~~~~~~
├─ org.schabi.newpipe.views.NewPipeRecyclerView instance
│    Leaking: YES (View detached and has parent)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View#mParent is set
│    View#mAttachInfo is null (view detached)
│    View.mID = R.id.items_list
│    View.mWindowAttachCount = 1
│    ↓ NewPipeRecyclerView.mParent
╰→ android.widget.RelativeLayout instance
​     Leaking: YES (ObjectWatcher was watching this because org.schabi.newpipe.fragments.list.kiosk.DefaultKioskFragment received Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks) and View detached and has parent)
​     key = 0cb93c97-3d08-41c1-8b87-bff07681b7d1
​     watchDurationMillis = 10323
​     retainedDurationMillis = 320
​     key = 746cfdd0-b6b0-416b-829f-85d12f1011e4
​     watchDurationMillis = 10322
​     retainedDurationMillis = 319
​     mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
​     View#mParent is set
​     View#mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1

METADATA

Build.VERSION.SDK_INT: 21
Build.MANUFACTURER: samsung
LeakCanary version: 2.2
App process name: org.schabi.newpipe.debug.release0200
Analysis duration: 81132 ms 
┬───
│ GC Root: System class
│
├─ leakcanary.internal.InternalLeakCanary class
│    Leaking: NO (MainActivity↓ is not leaking and a class is never leaking)
│    ↓ static InternalLeakCanary.resumedActivity
├─ org.schabi.newpipe.MainActivity instance
│    Leaking: NO (FocusAwareDrawerLayout↓ is not leaking and Activity#mDestroyed is false)
│    ↓ MainActivity.drawer
├─ org.schabi.newpipe.views.FocusAwareDrawerLayout instance
│    Leaking: NO (RecyclerView↓ is not leaking and View attached)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View.parent androidx.appcompat.widget.ContentFrameLayout attached as well
│    View#mParent is set
│    View#mAttachInfo is not null (view attached)
│    View.mID = R.id.drawer_layout
│    View.mWindowAttachCount = 1
│    ↓ FocusAwareDrawerLayout.mAttachInfo
├─ android.view.View$AttachInfo instance
│    Leaking: NO (RecyclerView↓ is not leaking)
│    ↓ View$AttachInfo.mScrollContainers
├─ java.util.ArrayList instance
│    Leaking: NO (RecyclerView↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (RecyclerView↓ is not leaking)
│    ↓ Object[].[4]
├─ androidx.recyclerview.widget.RecyclerView instance
│    Leaking: NO (View attached)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View.parent android.widget.RelativeLayout attached as well
│    View#mParent is set
│    View#mAttachInfo is not null (view attached)
│    View.mID = R.id.items_list
│    View.mWindowAttachCount = 1
│    ↓ RecyclerView.mAdapter
│                   ~~~~~~~~
├─ com.xwray.groupie.GroupAdapter instance
│    Leaking: UNKNOWN
│    ↓ GroupAdapter.mObservable
│                   ~~~~~~~~~~~
├─ androidx.recyclerview.widget.RecyclerView$AdapterDataObservable instance
│    Leaking: UNKNOWN
│    ↓ RecyclerView$AdapterDataObservable.mObservers
│                                         ~~~~~~~~~~
├─ java.util.ArrayList instance
│    Leaking: UNKNOWN
│    ↓ ArrayList.array
│                ~~~~~
├─ java.lang.Object[] array
│    Leaking: UNKNOWN
│    ↓ Object[].[1]
│               ~~~
├─ androidx.recyclerview.widget.RecyclerView$RecyclerViewDataObserver instance
│    Leaking: UNKNOWN
│    ↓ RecyclerView$RecyclerViewDataObserver.this$0
│                                            ~~~~~~
├─ androidx.recyclerview.widget.RecyclerView instance
│    Leaking: YES (View detached and has parent)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View#mParent is set
│    View#mAttachInfo is null (view detached)
│    View.mID = R.id.items_list
│    View.mWindowAttachCount = 1
│    ↓ RecyclerView.mParent
╰→ android.widget.RelativeLayout instance
​     Leaking: YES (ObjectWatcher was watching this because org.schabi.newpipe.local.subscription.SubscriptionFragment received Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks) and View detached and has parent)
​     key = aa1b8692-53dd-4528-9599-8b01db110679
​     watchDurationMillis = 10319
​     retainedDurationMillis = 318
​     key = 175f471b-34eb-44d8-be34-a1d9e367e3c4
​     mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
​     View#mParent is set
​     View#mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1

METADATA

Build.VERSION.SDK_INT: 21
Build.MANUFACTURER: samsung
LeakCanary version: 2.2
App process name: org.schabi.newpipe.debug.release0200
Analysis duration: 81132 ms 
┬───
│ GC Root: System class
│
├─ org.schabi.newpipe.player.helper.PlayerHolder class
│    Leaking: NO (VideoDetailFragment↓ is not leaking and a class is never leaking)
│    ↓ static PlayerHolder.listener
├─ org.schabi.newpipe.fragments.detail.VideoDetailFragment instance
│    Leaking: NO (SearchFragment↓ is not leaking and Fragment#mFragmentManager is not null)
│    ↓ VideoDetailFragment.mFragmentManager
├─ androidx.fragment.app.FragmentManagerImpl instance
│    Leaking: NO (SearchFragment↓ is not leaking)
│    ↓ FragmentManagerImpl.mFragmentStore
├─ androidx.fragment.app.FragmentStore instance
│    Leaking: NO (SearchFragment↓ is not leaking)
│    ↓ FragmentStore.mActive
├─ java.util.HashMap instance
│    Leaking: NO (SearchFragment↓ is not leaking)
│    ↓ HashMap.table
├─ java.util.HashMap$HashMapEntry[] array
│    Leaking: NO (SearchFragment↓ is not leaking)
│    ↓ HashMap$HashMapEntry[].[0]
├─ java.util.HashMap$HashMapEntry instance
│    Leaking: NO (SearchFragment↓ is not leaking)
│    ↓ HashMap$HashMapEntry.value
├─ androidx.fragment.app.FragmentStateManager instance
│    Leaking: NO (SearchFragment↓ is not leaking)
│    ↓ FragmentStateManager.mFragment
├─ org.schabi.newpipe.fragments.list.search.SearchFragment instance
│    Leaking: NO (Fragment#mFragmentManager is not null)
│    ↓ SearchFragment.correctSuggestion
│                     ~~~~~~~~~~~~~~~~~
├─ androidx.appcompat.widget.AppCompatTextView instance
│    Leaking: YES (View detached and has parent)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View#mParent is set
│    View#mAttachInfo is null (view detached)
│    View.mID = R.id.correct_suggestion
│    View.mWindowAttachCount = 1
│    ↓ AppCompatTextView.mParent
╰→ android.widget.RelativeLayout instance
​     Leaking: YES (ObjectWatcher was watching this because org.schabi.newpipe.fragments.list.search.SearchFragment received Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks))
​     key = 7030c99e-61e8-4592-a444-0d0df028f8cc
​     watchDurationMillis = 132065
​     retainedDurationMillis = 122063
​     key = 5735c68c-e1ca-44e1-a03c-e5f8861eb90e
​     retainedDurationMillis = 122062
​     mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
​     View#mParent is null
​     View#mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1

METADATA

Build.VERSION.SDK_INT: 21
Build.MANUFACTURER: samsung
LeakCanary version: 2.2
App process name: org.schabi.newpipe.debug.release0200
Analysis duration: 138403 ms 
┬───
│ GC Root: System class
│
├─ leakcanary.internal.InternalLeakCanary class
│    Leaking: NO (MainActivity↓ is not leaking and a class is never leaking)
│    ↓ static InternalLeakCanary.resumedActivity
├─ org.schabi.newpipe.MainActivity instance
│    Leaking: NO (MainFragment↓ is not leaking and Activity#mDestroyed is false)
│    ↓ MainActivity.mFragments
├─ androidx.fragment.app.FragmentController instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentController.mHost
├─ androidx.fragment.app.FragmentActivity$HostCallbacks instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentActivity$HostCallbacks.mFragmentManager
├─ androidx.fragment.app.FragmentManagerImpl instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentManagerImpl.mBackStack
├─ java.util.ArrayList instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ Object[].[0]
├─ androidx.fragment.app.BackStackRecord instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ BackStackRecord.mOps
├─ java.util.ArrayList instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ ArrayList.array
├─ java.lang.Object[] array
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ Object[].[0]
├─ androidx.fragment.app.FragmentTransaction$Op instance
│    Leaking: NO (MainFragment↓ is not leaking)
│    ↓ FragmentTransaction$Op.mFragment
├─ org.schabi.newpipe.fragments.MainFragment instance
│    Leaking: NO (Fragment#mFragmentManager is not null)
│    ↓ MainFragment.tabLayout
│                   ~~~~~~~~~
├─ org.schabi.newpipe.views.ScrollableTabLayout instance
│    Leaking: YES (View detached and has parent)
│    mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
│    View#mParent is set
│    View#mAttachInfo is null (view detached)
│    View.mID = R.id.main_tab_layout
│    View.mWindowAttachCount = 1
│    ↓ ScrollableTabLayout.mParent
╰→ android.widget.RelativeLayout instance
​     Leaking: YES (ObjectWatcher was watching this because org.schabi.newpipe.fragments.MainFragment received Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks))
​     key = 051d83b3-c1ba-4b43-b4d4-109e817b8806
​     watchDurationMillis = 10323
​     retainedDurationMillis = 323
​     key = d631f182-9aba-445e-aa63-6513198ade38
​     watchDurationMillis = 10322
​     retainedDurationMillis = 322
​     mContext instance of org.schabi.newpipe.MainActivity with mDestroyed = false
​     View#mParent is null
​     View#mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1

METADATA

Build.VERSION.SDK_INT: 21
Build.MANUFACTURER: samsung
LeakCanary version: 2.2
App process name: org.schabi.newpipe.debug.release0200
Analysis duration: 83184 ms 

settings (new not imported) NewPipeData-20200930_142911.zip

2020-09-30_14-10-01_859.hprof.zip

2020-09-30_14-13-07_635.hprof.zip

2020-09-30_14-29-31_266.hprof.zip

TobiGr commented 3 years ago

Modifying play queue while watching not possible, because drag & drop icons are not displayed. it is not possible to reorder the streams, only to remove them from the queue. Screenshot_1601470925 Screenshot_1601471014

avently commented 3 years ago

@TobiGr why it happens? Is this caused by me?

opusforlife2 commented 3 years ago

Well, 0.19.8 has handles on the right of every entry to drag it. These seem to have disappeared here.

avently commented 3 years ago

@opusforlife2 they are still there but invisible
ImageView should be replaced with appcompatimageview

opusforlife2 commented 3 years ago

Ah, Like the close button Stypox fixed in the video queue.

Is this another thing you would help me make a PR for? 😏

TobiGr commented 3 years ago

Found another bug: when the video controls are shown, using gestures can trigger swipe actions when starting the swipes at the position of a button. See the screencast for more info. For some reason, Android Studio messed up while recording the screencasts (i don't know why :( I am not able to capture good screencasts anymore)

avently commented 3 years ago

@TobiGr yeah, you can use this method to go to description :)

opusforlife2 commented 3 years ago

Issa feature, not a bug. ᕕ( ᐛ )ᕗ

It's also mentioned in the change log.

Swipe up on full screen button in landscape mode to scroll down the video details

TobiGr commented 3 years ago

Uh. Nice feature. I didn't know this was intended. however, this felt very buggy to me, because I did not expect the player to do this. I'd suggest to split tablet screens to accept three gestures like this: gsetures (I don't think that the scroll gestures is handy on phones, because phones are just too small / when in landscape only one or two comments can be viewed)

avently commented 3 years ago

@TobiGr no one will stop you if you implement such feature:)

avently commented 3 years ago

Also I think such gestures should be available on phones too because it's useful. Center is not used in swipes so it's free place

opusforlife2 commented 3 years ago

See the screencast for more info.

Wait I just saw the screencast properly again. @avently I thought only swiping down in the title region was supposed to minimize the player? Why do the track buttons (pause/next/previous) respond to the gesture?

In fact, remember that video jump glitch where swiping up on the seekbar/fullscreen buttom would cause the video to jump down and make space for a red status bar? It happens with the track buttons as well.

I don't think the track buttons should accept swipe gestures at all.

avently commented 3 years ago

I don't think the track buttons should accept swipe gestures at all.

Cool. Waiting your PR:)

opusforlife2 commented 3 years ago

I'm in. B) Tell me what to do.

avently commented 3 years ago

@opusforlife2 I've no idea. I already told you that this isn't what I implemented but it's how it works without special code. So someone needs to find how to skip interception of such gestures on elements inside the player. Easy way is to add them to the list of blacklisted elements inside custombottomsheet (such list is already exist on top of the file, you can just add more elements in it, like R.id.someOfTheButtonToIgnore but with id of all buttons to ignore like play/prev/next). It's an easy way. Hard way... I don't know.

opusforlife2 commented 3 years ago

Why do we need the hard way? Is the easy way not good?

avently commented 3 years ago

@opusforlife2 try this method, it's ok now

360fun commented 3 years ago

Uh. Nice feature. I didn't know this was intended. however, this felt very buggy to me, because I did not expect the player to do this. I'd suggest to split tablet screens to accept three gestures like this: gsetures (I don't think that the scroll gestures is handy on phones, because phones are just too small / when in landscape only one or two comments can be viewed)

SUGGESTION the first time the user opens the player should see a scheme like that, so the way gestures work is clear! ;)

opusforlife2 commented 3 years ago

Easy way is to add them to the list of blacklisted elements inside custombottomsheet

@avently The only search result for 'custombottomsheet' is this very issue.

avently commented 3 years ago

@opusforlife2 https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/java/org/schabi/newpipe/player/event/CustomBottomSheetBehavior.java

skipInterceptionOfElements

opusforlife2 commented 3 years ago

https://github.com/TeamNewPipe/NewPipe/blob/3a3ecc7775e1e5672ac7e958c0b42833e8ad10a5/app/src/main/java/org/schabi/newpipe/player/event/CustomBottomSheetBehavior.java#L27-L29

to

 private final List<Integer> skipInterceptionOfElements = Arrays.asList(
            R.id.detail_content_root_layout, R.id.relatedStreamsLayout,
            R.id.playQueuePanel, R.id.viewpager, R.id.bottomControls,
            R.id.playPreviousButton, R.id.playPauseButton, R.id.playNextButton);

?

Ref: https://github.com/TeamNewPipe/NewPipe/blob/3a3ecc7775e1e5672ac7e958c0b42833e8ad10a5/app/src/main/res/layout/player.xml#L406 https://github.com/TeamNewPipe/NewPipe/blob/3a3ecc7775e1e5672ac7e958c0b42833e8ad10a5/app/src/main/res/layout-large-land/player.xml#L409

avently commented 3 years ago

@opusforlife2 if this is working and fixes the problem, then yes. Is this working?

opusforlife2 commented 3 years ago

I haven't tried it in Android Studio yet. Just showed it to you in case I was doing something wrong.

avently commented 3 years ago

@opusforlife2 I think it's incomplete solution and you also have to add a block of code:

From this line: https://github.com/TeamNewPipe/NewPipe/blob/3a3ecc7775e1e5672ac7e958c0b42833e8ad10a5/app/src/main/java/com/google/android/material/appbar/FlingBehavior.java#L63

To this line: https://github.com/TeamNewPipe/NewPipe/blob/3a3ecc7775e1e5672ac7e958c0b42833e8ad10a5/app/src/main/java/com/google/android/material/appbar/FlingBehavior.java#L70

So you'll get one block per one id. In your case you should add three blocks in total. Each block with an id of the button you want to skip interception of. Like this:

final View playPauseButton = child.findViewById(R.id.playPauseButton); 
if (playPauseButton != null) { 
final boolean visible = playPauseButton.getGlobalVisibleRect(globalRect);
 if (visible && globalRect.contains((int) ev.getRawX(), (int) ev.getRawY())) { 
allowScroll = false; 
return false; 
} 
}

I'm out of computer so formatting is messed up. Make sure you use final View instead of final ViewGroup.

This code denies interception for collapsing view that holds the player. Since you're adding this code you can also fix invisible button here https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/res/layout/play_queue_item.xml#L15 and here https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/res/layout/play_queue_item.xml#L41 Just replace ImageView with AppCompatImageView (android studio will show the whole path from the support library when you enter this)

opusforlife2 commented 3 years ago

In your case you should add three blocks in total.

@avently Where? FlingBehavior.java or CustomBottomSheetBehavior.java?