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

Fix search crash: adapter array index out of bounds #3759

Merged
merged 1 commit into from
Jun 11, 2020

Conversation

Stypox
Copy link
Member

@Stypox Stypox commented Jun 7, 2020

What is it?

  • Bug fix (user facing)
  • Feature (user facing)
  • Code base improvement (dev facing)
  • Meta improvement to the project (dev facing)

Description of the changes in your PR

I don't know the cause of the IndexOutOfBounds exception, it could have something to do with the adapter not having finished to update itself after the last call to notifyDataSetChanged(). Anyway, a simple check should fix it.

Fixes the following issue(s)

Fixes #3575

Testing apk

@ltomes @test2a could you test this apk and see if it fixes the issue?
app-debug.zip

Agreement

@TobiGr TobiGr added the Android TV Issue is related to Android TV label Jun 7, 2020
@ltomes
Copy link

ltomes commented Jun 7, 2020

Sure, I'll try to report back in the next hour or so.

I was not able to run the APK on my Nvidia shield. I received a "There was a problem parsing the package" error trying to install it.

@test2a
Copy link

test2a commented Jun 10, 2020

Nope. I wrote on the original issue. It did not work.

I have like 5 phones running newpipe latest and only two have this problem.

I have the leaks canary app. How to get data from it?

@Stypox
Copy link
Member Author

Stypox commented Jun 10, 2020

I'm closing this since it apparently does not fix anything but only moves the crash elsewhere

@test2a LeakCanary can provide leak information if enabled via "Settings → Debug", but in this case that information wouldn't be useful

@Stypox Stypox closed this Jun 10, 2020
@Stypox
Copy link
Member Author

Stypox commented Jun 10, 2020

Reopening since this fixes #3575. I just tested and the fix works, even though a strange (unpreventable) behaviour arises when swiping too fast.

@Stypox Stypox reopened this Jun 10, 2020
@wb9688 wb9688 merged commit caa000f into TeamNewPipe:dev Jun 11, 2020
@TobiGr TobiGr added this to the 0.19.6 milestone Jun 12, 2020
This was referenced Jul 8, 2020
@Stypox Stypox deleted the fix-search branch August 4, 2022 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Android TV Issue is related to Android TV
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Crash when quickly swiping away search suggestions
5 participants