-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Delete pending missions with invalid storage #6721
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense and since it seems to work for the issue opener, gogo 🏃
That "app" text is not clickable when not logging in to Github, here is a direct URL in the hopes that it is not login-gated: https://github.com/TeamNewPipe/NewPipe/suites/3292080699/artifacts/76861038 edit: Nope, Github serves users that are not logged in a 404 for some reason. edit2: I extracted the zip and uploaded the apk to http://transfer.sh/19K2hb5/app-debug.apk (no warranties, don't trust a random person (me) giving you an apk, etc etc!) edit3: Nevermind, this will install a new NewPipe app, not upgrade the existing NewPipe on the device. So it is really just useful for testing. Guess I'll have to wait for the next proper release. Cheers! |
You can't just delete a mission if it has invalid storage, you need to handle it differently. |
@esdnm You're most welcome to submit a PR proposing your solution. |
I don't have a solution on my head. But I must say that fixing this issue in a destructive way is utterly insane. |
It's a matter of perspective. Another user could easily claim that leaving incomplete corrupted files lying around in storage causing bloat is what's utterly insane. |
What is it?
Description of the changes in your PR
When loading pending missions from disk, sometimes an invalid mission with
storage == null
would be read (because of a corrupted file or with an outdated file format). This causedNullPointerException
s down the line. So I addedhasInvalidStorage()
to the prelimiary checks on the mission object loaded from file, and if that's the case the related file is deleted. (each pending mission has its own file)Fixes the following issue(s)
APK testing
The APK can be found by going to the "Checks" tab below the title. On the left pane, click on "CI", scroll down to "artifacts" and click "app" to download the zip file which contains the debug APK of this PR.
@timjefferies @bew @castrik does this fix the problem for you?
Due diligence