-
Notifications
You must be signed in to change notification settings - Fork 403
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
Fix race conditions and add -race flag to test.sh #546
Comments
Yeah , it races at |
/assign |
Hey, @cbuto |
hey 👋 @nerdeveloper, yep! Just add the https://github.com/helm/chartmuseum/blob/main/scripts/test.sh#L11 |
@scbizu sync.Map will likely work, it might be worth seeing if a RWMutex offers better performance as well! |
Ah yep, you can set it before the command |
this is the PR to this fix: #549 |
Why |
@scbizu Please refer to this if we don't set the CGO, it does not run with the race flag |
While running unit tests locally, I noticed a race condition (without the
-race
flag set). After setting the-race
flag while running unit tests, they fail with a few race conditions that we should look to resolve.We should first fix the race conditions and set the
-race
flag intest.sh
to avoid any new races.One example of a race condition caught:
The text was updated successfully, but these errors were encountered: