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

return an error if transaction history futures initialization fails #1986

Open
shamardy opened this issue Oct 9, 2023 · 0 comments
Open
Labels
bug Something isn't working

Comments

@shamardy
Copy link
Collaborator

shamardy commented Oct 9, 2023

As explained by @onur-ozkan

Just checked the source code, activation and deactivation operations are relying on the CoinsContext Mutex.

e.g.,:

activation requested -> TendermintCoin initialized -> spawning tx/history / balance streaming futures -> locked(no parallel execution allowed here) coins context and added TendermintCoin in there -> success result

However, spawned futures can end up unexpectedly because there is no guarantee that they will be successfully executed/initialized before we add their coin into CoinsContext. This means that a spawned future could encounter errors or panics after we add the coin to the context and return a success result.

ref. #1978 (comment), #1978 (comment), #1978 (comment)

@shamardy shamardy added the bug Something isn't working label Oct 9, 2023
@shamardy shamardy changed the title Return error if transaction history futures initialization fails return an error if transaction history futures initialization fails Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant