Skip to content

#903: added vet flag to resolve race issue #2595

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

Closed
wants to merge 2 commits into from

Conversation

vanshaj
Copy link
Contributor

@vanshaj vanshaj commented Jul 11, 2022

As per the last comment in issue : golang/go#27089
I have turned off the vet flag and "make tests" worked fine on my windows machine.

Kindly review

@github-actions github-actions bot requested review from na-- and oleiade July 11, 2022 13:28
@na-- na-- requested review from olegbespalov and removed request for na-- July 11, 2022 14:35
@olegbespalov
Copy link
Contributor

Hi @vanshaj !

Thanks for your PR.

Could you please provide more details about the race issue? Maybe an output? 🤔

Cheers!

@vanshaj
Copy link
Contributor Author

vanshaj commented Jul 14, 2022

Hi @vanshaj !

Thanks for your PR.

Could you please provide more details about the race issue? Maybe an output? 🤔

Cheers!

yess, Kindly have a look at below image

image

@olegbespalov
Copy link
Contributor

In #903, I believe @mstoykov meant, first of all, the CI, but we don't run make test there. And it seems like in one of the last CI refactorings. We fixed it with the workaroubnd.

However, I believe it's also essential to have a make test target fixed too (maybe at some point, both the local & CI will run the same command). So let's try to finalize this PR 👍

@@ -1,30 +1,30 @@
GOLANGCI_LINT_VERSION = $(shell head -n 1 .golangci.yml | tr -d '\# ')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see that, for some reason, the change affected whole formatting. Is it possible to keep only the actual change(s)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure I will make the formatting correct.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @vanshaj

It seems like the whole file formatting is still affected. It shows that 30 lines were removed and 30 added:
image

golangci-lint run --out-format=tab --new-from-rev master ./...

tests :
go test -race -timeout 210s ./... -vet=off
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a small note here that this affects runs for all operation systems which isn't good, but I guess in that case it's fine as long as we have the linter altogether (make check)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@olegbespalov Do you want me to add some check related to underlying OS?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, I guess in the current case, it will be over. Just share the opinion that in some cases we can do that.

@mstoykov mstoykov added this to the v0.40.0 milestone Jul 21, 2022
@vanshaj vanshaj requested a review from olegbespalov July 22, 2022 09:54
@codecov-commenter
Copy link

codecov-commenter commented Jul 22, 2022

Codecov Report

Merging #2595 (cbad21c) into master (7f823f0) will decrease coverage by 0.23%.
The diff coverage is 66.83%.

@@            Coverage Diff             @@
##           master    #2595      +/-   ##
==========================================
- Coverage   75.59%   75.36%   -0.24%     
==========================================
  Files         202      205       +3     
  Lines       15992    16287     +295     
==========================================
+ Hits        12089    12274     +185     
- Misses       3151     3248      +97     
- Partials      752      765      +13     
Flag Coverage Δ
ubuntu 75.20% <66.83%> (-0.19%) ⬇️
windows 75.05% <66.83%> (-0.24%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
errext/exit_code.go 100.00% <ø> (ø)
js/common/interrupt_error.go 100.00% <ø> (+18.18%) ⬆️
js/compiler/compiler.go 63.52% <ø> (-0.63%) ⬇️
js/modules/k6/grpc/client.go 78.39% <0.00%> (ø)
js/timeout_error.go 56.25% <ø> (ø)
lib/consts/consts.go 78.57% <ø> (ø)
metrics/metric.go 92.40% <0.00%> (+3.38%) ⬆️
output/csv/time_format_gen.go 20.00% <20.00%> (ø)
metrics/thresholds.go 88.54% <33.33%> (-0.18%) ⬇️
...utils/httpmultibin/grpc_any_testing/any_test.pb.go 37.97% <37.97%> (ø)
... and 49 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bfa415c...cbad21c. Read the comment docs.

@olegbespalov
Copy link
Contributor

Hey @oleiade. Could you please share your thoughts about the PR? Thanks.

@na-- na-- removed this from the v0.40.0 milestone Aug 15, 2022
@oleiade
Copy link
Contributor

oleiade commented Aug 15, 2022

Once again, thanks for your contribution @vanshaj, we really appreciate and value that you took the time and put in the effort to propose an improvement to k6.

Unfortunately, we discussed it internally, and experimented around this issue internally, and came to the conclusion we would not merge this PR in master. The main reason being, we cannot reproduce the issue you reported, and as a result, we can't risk introducing a change that might harm other users (including ourselves) in ways we cannot foresee for a potential benefit we cannot observe.

I hope this makes sense, and that you understand. Please don't hesitate to contribute again in the future 🙇🏻

@oleiade oleiade closed this Aug 15, 2022
@vanshaj vanshaj deleted the k6-903 branch August 15, 2022 09:06
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

Successfully merging this pull request may close these issues.

6 participants