-
Notifications
You must be signed in to change notification settings - Fork 121
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
tarogarden: caretaker data race #296
Comments
Have reproduced in a separate run, curious as to why this doesn't appear in CI. |
Parsing the logs: The 'main' goroutine for the caretaker, 966 here, is advancing the state machine via A secondary goroutine, 1067 here, is started while in the The secondary goroutine will call So if a cancellation signal is received before the main goroutine finishes writing Not sure what the best way to mitigate this would be, but wrapping the state in a Mutex feels excessive. One option is making the logic that handles watching for a transcation confirmation blocking, which is already suggested via TODO by @Roasbeef . I think that shouldn't change other planter & caretaker behavior much, since after we reach the terminal state |
What I was thinking of for mitigation: -Add a |
Looking at the latest code, I see |
Nice find! That would work well, though added for golang 1.19 and we're still at 1.18 for the project (but we build with 1.20?). |
One drawback of using the atomic is that now the list of constants can't be the same type as the actual variable, but that seems acceptable. |
Found while trying to emulate CI tasks locally.
The text was updated successfully, but these errors were encountered: