Skip to content
This repository has been archived by the owner on Jan 21, 2024. It is now read-only.

App Crash when Screen Auto rotation is off #297

Closed
7 tasks done
aldrinjenson opened this issue Jan 23, 2023 · 1 comment
Closed
7 tasks done

App Crash when Screen Auto rotation is off #297

aldrinjenson opened this issue Jan 23, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@aldrinjenson
Copy link

Checklist

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

Affected version

0.24.1

Steps to reproduce the bug

  1. Make sure Auto rotation is turned off in device
  2. Play any video
  3. App crashes with the whole UI being rotated to landscape mode
  4. Open app again and play any video
  5. The UI changes automatically to landscape mode and App crashes again
  6. Turn auto rotation on
  7. Open app again and play a video
  8. Now video plays

Expected behavior

  • The app shouldn't crash when screen rotation is off
  • The app shouldn't erratically adjust rotation UI without the device actually being rotated physically
  • The app should automatically adjust layouts based on auto rotation

Actual behavior

  • App crashes when video is played with auto rotation
  • If the auto rotation was turned on initially and then turned off after loading newPipe, the UI automatically turns to landscape mode (even if the phone is held in portrait mode only) and then video plays fine
  • If the auto rotation is turned off before the app was loaded, the app crashes when a video is played

Screenshots/Screen recordings

NewPipeSponsorblock_Error.Recording.mp4

Logs

Exception

  • User Action: ui error
  • Request: ACRA report
  • Content Country: IN
  • Content Language: en-IN
  • App Language: en_IN
  • Service: none
  • Version: 0.24.1
  • OS: Linux Nokia/Phoenix_00WW/PNX_sprout:11/RKQ1.200906.002/00WW_6_210:user/release-keys 11 - 30
Crash log

java.lang.NullPointerException: Attempt to invoke virtual method 'void android.app.Activity.runOnUiThread(java.lang.Runnable)' on a null object reference
at org.schabi.newpipe.fragments.detail.VideoDetailFragment.lambda$handleResult$23(VideoDetailFragment.java:1626)
at org.schabi.newpipe.fragments.detail.VideoDetailFragment.$r8$lambda$kvbSCZYpk1eZXvjw0VQVcbHCIUo(Unknown Source:0)
at org.schabi.newpipe.fragments.detail.VideoDetailFragment$$ExternalSyntheticLambda38.run(Unknown Source:4)
at java.lang.Thread.run(Thread.java:923)


Affected Android/Custom ROM version

Android 11

Affected device model

Nokia 8.1

Additional information

Please note that in the whole of screen recording, the phone was held in portrait mode only in my hand. The whole UI shifting to landscape mode was solely due to the software (Newpipe sponsorblock).
This occurs only with Newpipe sponsorblock.

I found #216 issue. But it's not exactly the same, so I'm creating this new one here.
Feel free to close this if you think this belongs under that one.
Thanks.

@aldrinjenson aldrinjenson added the bug Something isn't working label Jan 23, 2023
@aldrinjenson aldrinjenson changed the title App Crash when Screen rotation is off App Crash when Screen Auto rotation is off Jan 23, 2023
@polymorphicshade
Copy link
Owner

I believe this is now fixed.

I will re-open this issue if you can reproduce this issue with the latest version.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants