antrea icon indicating copy to clipboard operation
antrea copied to clipboard

wip: Replace bincover with built-in Go coverage profiling tool

Open shikharish opened this issue 2 years ago • 4 comments

This PR makes the shift from the deprecated bincover package to Golang built-in coverage profiling tool.

shikharish avatar Mar 10 '24 13:03 shikharish

@antoninbas Is it fine if I add more commits to a PR or should one PR be only one commit?

shikharish avatar Mar 13 '24 18:03 shikharish

@antoninbas Is it fine if I add more commits to a PR or should one PR be only one commit?

it's better if you add a new commit for each review cycle, then squash all commits at the very end

antoninbas avatar Mar 13 '24 18:03 antoninbas

@antoninbas flow-aggregator images build are failing: https://github.com/antrea-io/antrea/actions/runs/8301256864/job/22720993922?pr=6090#step:3:30

I don't understand why pull access would be denied.

shikharish avatar Mar 15 '24 19:03 shikharish

@antoninbas flow-aggregator images build are failing: https://github.com/antrea-io/antrea/actions/runs/8301256864/job/22720993922?pr=6090#step:3:30

I don't understand why pull access would be denied.

antrea-build is an intermediate build image that doesn't exist outside of the build process. I think you meant to use flow-aggregator-build there.

antoninbas avatar Mar 15 '24 20:03 antoninbas

What is the use of this function? I don't think any coverage files are being written in the control plane Node.

shikharish avatar Mar 18 '24 05:03 shikharish

/test-multicluster-e2e

antoninbas avatar Apr 03 '24 17:04 antoninbas

/test-multicluster-e2e

antoninbas avatar Apr 04 '24 02:04 antoninbas

/test-multicluster-e2e

antoninbas avatar Apr 04 '24 02:04 antoninbas

/test-multicluster-e2e

antoninbas avatar Apr 04 '24 18:04 antoninbas

/test-multicluster-e2e

luolanzone avatar Apr 08 '24 07:04 luolanzone

/test-multicluster-e2e

antoninbas avatar May 03 '24 22:05 antoninbas

@antoninbas I made a fix in the yaml files, can you run the mc test again?

shikharish avatar May 04 '24 10:05 shikharish

/test-multicluster-e2e

antoninbas avatar May 04 '24 19:05 antoninbas

/test-multicluster-e2e

luolanzone avatar May 08 '24 01:05 luolanzone

/test-whole-conformance /skip-conformance /test-networkpolicy /test-e2e /test-flexible-ipam-e2e /test-multicluster-e2e /test-multicast-e2e /test-windows-all /test-kind-ipv6-all /test-kind-ipv6-only-all /test-vm-e2e

luolanzone avatar May 08 '24 08:05 luolanzone

/test-e2e /test-conformance

antoninbas avatar May 08 '24 18:05 antoninbas

/test-kind-ipv6-conformance /test-kind-ipv6-networkpolicy

antoninbas avatar May 09 '24 00:05 antoninbas

/test-kind-ipv6-conformance

antoninbas avatar May 09 '24 02:05 antoninbas

@shikharish There was a failure for test-e2e:

I0509 01:02:38.404207 3997474 framework.go:2650] Sending SIGINT to 'antrea-controller-coverage'
I0509 01:02:38.442389 3997474 framework.go:2656] Copying coverage files from Pod 'antrea-controller-69fcfb59c6-vrmzc'
I0509 01:02:38.480172 3997474 framework.go:2801] Copying file: covmeta.a1399e60736fc7fe1549a02ca9db368d
I0509 01:02:38.517180 3997474 framework.go:2801] Copying file: covcounters.a1399e60736fc7fe1549a02ca9db368d.7.1715216558441681329
I0509 01:02:38.603880 3997474 framework.go:2650] Sending SIGINT to 'antrea-agent-coverage'
I0509 01:02:38.646002 3997474 framework.go:2656] Copying coverage files from Pod 'antrea-agent-dks7w'
I0509 01:02:38.688258 3997474 framework.go:2801] Copying file: covcounters.1f1c9ccedabce8e7cede1b046270cea0.7.1715216558648518891
I0509 01:02:38.733519 3997474 framework.go:2801] Copying file: covmeta.1f1c9ccedabce8e7cede1b046270cea0
I0509 01:02:38.814148 3997474 framework.go:2650] Sending SIGINT to 'antrea-agent-coverage'
I0509 01:02:38.856019 3997474 framework.go:2656] Copying coverage files from Pod 'antrea-agent-p7kv7'
I0509 01:02:38.895236 3997474 framework.go:2801] Copying file: covmeta.1f1c9ccedabce8e7cede1b046270cea0
I0509 01:02:38.939382 3997474 framework.go:2801] Copying file: covcounters.1f1c9ccedabce8e7cede1b046270cea0.7.1715216558853888561
I0509 01:02:39.017115 3997474 framework.go:2650] Sending SIGINT to 'antrea-agent-coverage'
I0509 01:02:39.062101 3997474 framework.go:2656] Copying coverage files from Pod 'antrea-agent-tmgf6'
I0509 01:02:39.101936 3997474 framework.go:2801] Copying file: covcounters.1f1c9ccedabce8e7cede1b046270cea0.7.1715216559068671262
I0509 01:02:39.141413 3997474 framework.go:2801] Copying file: covmeta.1f1c9ccedabce8e7cede1b046270cea0
I0509 01:02:39.181917 3997474 framework.go:2750] Copying coverage files from Node: jenkins-antrea-e2e-for-pull-request-2796-w8n4r
I0509 01:02:39.653446 3997474 framework.go:2835] Copying file: covcounters.3422adf0c3cf821515e34c70b6862df6.63.1715213900486935592
2024/05/09 01:02:39 Error when collecting antctl coverage files from control-plane Node: error when copying coverage files for antctl from Node 'jenkins-antrea-e2e-for-pull-request-2796-w8n4r' to coverage directory '/var/lib/jenkins/workspace/antrea-e2e-for-pull-request/e2e-coverage/jenkins-antrea-e2e-for-pull-request-2796-w8n4r-coverage': cannot retrieve content of file 'covcounters.3422adf0c3cf821515e34c70b6862df6.63.1715213900486935592' from Node 'jenkins-antrea-e2e-for-pull-request-2796-w8n4r', stderr: <cat: covcounters.3422adf0c3cf821515e34c70b6862df6.63.1715213900486935592: No such file or directory
>, err: <<nil>>
FAIL	antrea.io/antrea/test/e2e	2692.437s
FAIL
=== TEST FAILURE !!! ===

@luolanzone would that be related to the changes to ci/jenkins/test-vmc.sh?

antoninbas avatar May 09 '24 02:05 antoninbas

@antoninbas The error is not from the test-vmc.sh script. I have made a small change which I think should fix the issue. Can you run the test again?

shikharish avatar May 09 '24 04:05 shikharish

/test-e2e

luolanzone avatar May 09 '24 05:05 luolanzone

/test-whole-conformance /skip-conformance /test-networkpolicy /test-flexible-ipam-e2e /test-multicluster-e2e /test-multicast-e2e /test-windows-all /test-kind-ipv6-all /test-kind-ipv6-only-all /test-vm-e2e

antoninbas avatar May 09 '24 20:05 antoninbas

/test-kind-ipv6-conformance /test-kind-ipv6-only-e2e /test-vm-e2e

antoninbas avatar May 09 '24 23:05 antoninbas

/test-kind-ipv6-only-e2e

antoninbas avatar May 10 '24 00:05 antoninbas

@luolanzone Is the coverage number (74.24%) as expected?

antoninbas avatar May 10 '24 00:05 antoninbas

@luolanzone Is the coverage number (74.24%) as expected?

Yeah, the result looks good. I checked the coverage trend chart in this page https://app.codecov.io/gh/antrea-io/antrea, it's around 74%.

luolanzone avatar May 10 '24 03:05 luolanzone

@shikharish Things are good on the testing side. Can you push a new commit to fix the merge conflict? After that, we should be good to merge.

antoninbas avatar May 10 '24 04:05 antoninbas

/test-all

antoninbas avatar May 10 '24 18:05 antoninbas

/test-multicluster-e2e

antoninbas avatar May 10 '24 21:05 antoninbas

@luolanzone The coverage on my branch is around 65%, significantly less that that of the main branch. https://app.codecov.io/gh/antrea-io/antrea/tree/remove-bincover

shikharish avatar May 11 '24 12:05 shikharish