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

Switching to WAV/PCM format causes the app to crash and then keeps crashing on every launch. #240

Closed
bagarwa opened this issue Feb 12, 2023 · 2 comments · Fixed by #241
Closed
Assignees
Labels
bug Bug in BCR itself

Comments

@bagarwa
Copy link

bagarwa commented Feb 12, 2023

I was previously using the OGG format. I was tapping the different format options, for no reason. When I tapped on WAV/PCM, the app crashed. From then on, whenever I try to launch BCR, the app immediately crashes. Cleared the app's data to manually reset it, and then am able to launch it and set it like I want.

Pixel 7 Pro, running Android 14 DP1, Magisk Canary 25206.

BCR 1.32

(Sidenote - "Disable battery optimization" option is greyed out at "on" position! i.e. it is turned on and I can't disable it. But I checked in BCR app's app info page that "Battery" is set to "Unrestricted".)
(Should I create separate issues for these sidenotes.)

@chenxiaolong
Copy link
Owner

Oh, nice catch. I'm able to reproduce this. I'll investigate it and make a new release with the fix.

(Sidenote - "Disable battery optimization" option is greyed out at "on" position! i.e. it is turned on and I can't disable it. But I checked in BCR app's app info page that "Battery" is set to "Unrestricted".)

This is because Android's API for this is kind of bad. An app can only request it to be turned on (which is the same as Unrestricted), but not to turn it off. I made the setting grayed out because there's nothing BCR can do to turn it off. I'm open to suggestions for better ways to handle the UI for this.

(Should I create separate issues for these sidenotes.)

No worries, I don't mind it either way :)

@chenxiaolong chenxiaolong self-assigned this Feb 12, 2023
@chenxiaolong chenxiaolong added the bug Bug in BCR itself label Feb 12, 2023
@chenxiaolong
Copy link
Owner

chenxiaolong commented Feb 12, 2023

This is a bug in the material design 3 library. I'll see if I can work around it. If not, I'll downgrade to the previous version (before #238).

EDIT: It might be caused by a workaround for a bug that no longer exists.

EDIT 2: Huh... I know why I didn't catch this. The crash doesn't happen on debug builds, only release builds.

chenxiaolong added a commit that referenced this issue Feb 12, 2023
This fixes a crash due to NoSuchMethodException when switching to an
output format that does not specify a parameter (bitrate or compression
level). The workaround is no longer necessary now that the material3 bug
has been fixed and we've upgraded to a release containing the fix in
commit 3b0999a.

Fixes: #240

Signed-off-by: Andrew Gunnerson <accounts+github@chiller3.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug in BCR itself
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants