-
Notifications
You must be signed in to change notification settings - Fork 120
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
Fixing various security issues and updating null_types to handle over… #407
Conversation
087b6c6
to
396f988
Compare
8a4348e
to
63cb493
Compare
@go-jet do you have any insights on this? I'm not very familiar with circleCI, but it seems like all the tests are passing, the tests tab is all clear, the report has no failures I can find. Though it seems something is still breaking. |
63cb493
to
5ae17a1
Compare
Hmm, it is weird. Indeed, all tests pass. A wield guess would be that after all the tests have finished, Maybe add some log lines and panic catcher in |
15d8323
to
eb92fb7
Compare
The issue is with go-junit-report. I replaced with a very similar tool that I think is a bit easier to use. It also, actually gives you a break down as the tests are running without having to navigate to the tests tab. Let me know if you have any objections to using this instead, otherwise I'll try to figure out how to make it go-junit-report work. Also, how would you feel about moving the circle CI tests into a github action ? |
@@ -33,7 +30,6 @@ func sourceIsMariaDB() bool { | |||
} | |||
|
|||
func TestMain(m *testing.M) { | |||
rand.Seed(time.Now().Unix()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's deprecated and no longer needed, from go docs.
// Deprecated: As of Go 1.20 there is no reason to call Seed with
// a random value. Programs that call Seed with a known value to get
// a specific sequence of results should use New(NewSource(seed)) to
// obtain a local random generator.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aha, I see.
What was the issue with go-junit-report? I'm fine with gotestsum, but I don't see codecoverage on codecov now. I'm fine with github actions as well, if they provide the same as circle.ci. |
Okay, let me see if I can get the junit report to work, or fix gotestsum. They should be compatible... let me see what I can do with that. Not 100% sure of the issue, but it required an update to V2 and it still didn't work for me. I can't replicate it locally so need to use the CICD to test the behavior. |
Okay, I'll do another MR without any other changes being added for that later on if I can manage something that's comparable. |
f7fe40d
to
d3c2123
Compare
Okay, done. Fixed the code coverage issue. I created a token for my own project and verified the upload. https://app.codecov.io/gh/safaci2000/jet/tree/feature%2Fscanners |
Something ain't right. Code coverage should be above 90%. Also the last two steps |
Noted, I'll look at it when i have a chance. |
08ff59a
to
7516e8b
Compare
ChangeLog: - Adding gosec linting - Adding static type to enum - fixing nulltype overflow - Trying out gotestsum as an alternative to go-junit-report.xml
7516e8b
to
f7082ed
Compare
I had to bump the go version used for testing a bit further than go.mod due to a change in behavior. golang/go#65653. Code coverage should be resolved |
Interesting, now it makes sense. |
f16c7cd
to
dbd23ed
Compare
Thanks. Looks good. 👍 |
Adding gosec and lint scanning to project