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

How to properly implement retry #163

Open
whereswaldon opened this issue May 6, 2022 · 3 comments
Open

How to properly implement retry #163

whereswaldon opened this issue May 6, 2022 · 3 comments

Comments

@whereswaldon
Copy link
Contributor

Hi there! Thanks for such an awesome library. :D

I have an application that was just bitten by this panic. I'd like to implement the missing retry logic, but I'm not really sure that I understand the approach that I should take in doing so. Do you have any guidance about how I should approach adding this feature?

@hajimehoshi
Copy link
Collaborator

Hi. Unfortunately there is no good way to retry this so far. Is the issue reproducible?

@whereswaldon
Copy link
Contributor Author

Not currently. It has only happened once, but it crashed the entire application. Given that this panic originates on a goroutine that isn't started by application code directly, it's difficult to recover from, and it isn't clear if oto can still be used after recovering.

I will keep an eye out for it happening again and try to narrow down the cause. In the meantime though, is there anything that can be done to contain this failure so that the panic doesn't bring down the entire app? We are specifically hitting this case that is marked TODO, though the panic is a little later.

@hajimehoshi
Copy link
Collaborator

Yeah, as the TODO says, we should keep an error instead of panicking. However, as I am not so familiar with the audio API, I am not sure if we really can recover from this state or not. I'd like to know when this error happens. Thank you for investigating!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants