Skip to content
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

For goveralls fix races in unit tests #5262

Closed

Conversation

dhiller
Copy link
Contributor

@dhiller dhiller commented Mar 18, 2021

What this PR does / why we need it:

This PR picks up the original fixes for data races from @rmohr .

Furthermore it addresses the data races that are getting visible for kubevirt_test.go when the tests are run in parallel, i.e. when using bazel options like this: --runs_per_test=4 --cache_test_results=no In that case i.e. several data races got visible. This was addressed by isolating the test data (mocks, recording data structures etc.) into a separate struct that is created per test, in order to isolate data access of each test. Also the function lambdas were attached to the struct to use the data from the test data struct.

Finally this PR makes available some of the bazel options so that they can be used when calling make test

Example:

KUBEVIRT_FOCUS="On valid KubeVirt object" \
KUBEVIRT_EXTRA_ARGS="--runs_per_test=4 --test_output=all --cache_test_results=no" \
KUBEVIRT_TARGETS="//pkg/virt-operator:*" \
make test

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #5313

Special notes for your reviewer:

I think we can improve the readability and interface of the created struct in a fluent interface way in order to improve reading the test code. But the changes here are required to enable the goveralls lane, so I would prefer to do this in a second PR.

Example:

// code as of now
kvTestData.addKubeVirt(kv)
kvTestData.addInstallStrategy(kvTestData.defaultConfig)
kvTestData.addAll(kvTestData.defaultConfig, kv)
numResources := kvTestData.generateRandomResources()
kvTestData.addPodsAndPodDisruptionBudgets(kvTestData.defaultConfig)

kvTestData.makeApiAndControllerReady()
kvTestData.makeHandlerReady()

kvTestData.shouldExpectDeletions()
kvTestData.fakeNamespaceModificationEvent()
kvTestData.shouldExpectNamespacePatch()

  ||
  \/
// proposed change example
kvTestData.addKubeVirt(kv).addInstallStrategy(kvTestData.defaultConfig).addAll(kvTestData.defaultConfig, kv)
numResources := kvTestData.generateRandomResources()
kvTestData.addPodsAndPodDisruptionBudgets(kvTestData.defaultConfig)

kvTestData.makeApiAndControllerReady().makeHandlerReady()

kvTestData.shouldExpectDeletions().fakeNamespaceModificationEvent().shouldExpectNamespacePatch()

Release note:

Fix data races in unit tests

@kubevirt-bot
Copy link
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@kubevirt-bot kubevirt-bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. size/L labels Mar 18, 2021
@dhiller
Copy link
Contributor Author

dhiller commented Mar 18, 2021

/test pull-kubevirt-goveralls

@kubevirt-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
To complete the pull request process, please assign dhiller
You can assign the PR to them by writing /assign @dhiller in a comment when ready.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@dhiller
Copy link
Contributor Author

dhiller commented Mar 18, 2021

/test pull-kubevirt-unit-test

@dhiller
Copy link
Contributor Author

dhiller commented Mar 19, 2021

/test pull-kubevirt-goveralls

@dhiller
Copy link
Contributor Author

dhiller commented Mar 19, 2021

This seems like a hard nut to crack. I've done several test runs, and seen sometimes several data races in one run (especially regarding kubevirt_test.go. Seems like using the fake clients creates concurrency issues. Not sure how to fix that though.

@dhiller
Copy link
Contributor Author

dhiller commented Mar 19, 2021

KUBEVIRT_FOCUS="On valid KubeVirt object" KUBEVIRT_EXTRA_ARGS="--runs_per_test=5 --test_output=all --cache_test_results=no" KUBEVIRT_TARGETS="//pkg/virt-operator:*" make test > /tmp/make_test.log
produced several data races:
make_test.log

@kubevirt-bot kubevirt-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 20, 2021
@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from 85e9cfb to 7957088 Compare March 26, 2021 16:01
@kubevirt-bot kubevirt-bot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Mar 26, 2021
@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from 7957088 to 252af94 Compare March 31, 2021 08:20
@dhiller
Copy link
Contributor Author

dhiller commented Mar 31, 2021

/test pull-kubevirt-unit-test

@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from 80c5b2f to b541dbe Compare March 31, 2021 11:24
@kubevirt-bot kubevirt-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 31, 2021
@dhiller
Copy link
Contributor Author

dhiller commented Mar 31, 2021

/test pull-kubevirt-unit-test

@dhiller
Copy link
Contributor Author

dhiller commented Apr 1, 2021

kubevirt_test.go data races seem to have gone with the changes.

@dhiller
Copy link
Contributor Author

dhiller commented Apr 1, 2021

/test pull-kubevirt-unit-test

@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from 8e7c8d7 to f37f65e Compare April 1, 2021 07:34
@dhiller
Copy link
Contributor Author

dhiller commented Apr 1, 2021

/test pull-kubevirt-unit-test

@dhiller
Copy link
Contributor Author

dhiller commented Apr 1, 2021

$ KUBEVIRT_EXTRA_ARGS="--runs_per_test=4 --test_output=all --cache_test_results=no" make test
...
//tests/framework/matcher:go_default_test                                PASSED in 1.6s
  Stats over 4 runs: max = 1.6s, min = 1.4s, avg = 1.5s, dev = 0.1s
//pkg/virt-operator:go_default_test                                     TIMEOUT in 4 out of 4 in 300.1s
  Stats over 4 runs: max = 300.1s, min = 300.1s, avg = 300.1s, dev = 0.0s
  /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/execroot/__main__/bazel-out/k8-fastbuild/testlogs/pkg/virt-operator/go_default_test/run_3_of_4/test.log
  /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/execroot/__main__/bazel-out/k8-fastbuild/testlogs/pkg/virt-operator/go_default_test/run_4_of_4/test.log
  /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/execroot/__main__/bazel-out/k8-fastbuild/testlogs/pkg/virt-operator/go_default_test/run_2_of_4/test.log
  /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/execroot/__main__/bazel-out/k8-fastbuild/testlogs/pkg/virt-operator/go_default_test/run_1_of_4/test.log
//pkg/virt-controller/watch/snapshot:go_default_test                     FAILED in 1 out of 4 in 7.5s
  Stats over 4 runs: max = 7.5s, min = 6.6s, avg = 7.2s, dev = 0.4s
  /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/execroot/__main__/bazel-out/k8-fastbuild/testlogs/pkg/virt-controller/watch/snapshot/go_default_test/run_4_of_4/test.log
//pkg/virt-operator/resource/generate/components:go_default_test         FAILED in 1 out of 4 in 92.3s
  Stats over 4 runs: max = 92.3s, min = 91.7s, avg = 92.0s, dev = 0.3s
  /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/execroot/__main__/bazel-out/k8-fastbuild/testlogs/pkg/virt-operator/resource/generate/components/go_default_test/run_1_of_4/test.log

Executed 84 out of 84 tests: 81 tests pass and 3 fail locally.

@kubevirt-bot kubevirt-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 15, 2021
rmohr and others added 8 commits April 15, 2021 14:51
Signed-off-by: Roman Mohr <rmohr@redhat.com>
Signed-off-by: Roman Mohr <rmohr@redhat.com>
Signed-off-by: Roman Mohr <rmohr@redhat.com>
Signed-off-by: Daniel Hiller <dhiller@redhat.com>
Example:

KUBEVIRT_FOCUS="On valid KubeVirt object" \
    KUBEVIRT_EXTRA_ARGS="--runs_per_test=5 --test_output=all --cache_test_results=no" \
    KUBEVIRT_TARGETS="//pkg/virt-operator:*" make test

Signed-off-by: Daniel Hiller <dhiller@redhat.com>
Create a test data struct in order to separate the required test state
(mocks, recording structures etc) from the actual run, so we do not
share state between tests anymore. This eliminates the data races.
Also add the behavior to the struct so that it uses the test state and
not the shared state.
Increase timeouts for tests that regularly fail on parallel execution.

Signed-off-by: Daniel Hiller <dhiller@redhat.com>
See https://docs.bazel.build/versions/master/test-encyclopedia.html#role-of-the-test-runner

Also add the test.log output to the artifacts for having more
information.

Signed-off-by: Daniel Hiller <dhiller@redhat.com>
Also add ctrl.Finish() and do expect call before changing the mock
handler.

Signed-off-by: kubevirt-bot <kubevirtbot@redhat.com>
@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from e5cfa24 to c4e7df3 Compare April 15, 2021 12:59
@kubevirt-bot kubevirt-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 15, 2021
@dhiller
Copy link
Contributor Author

dhiller commented Apr 15, 2021

/test pull-kubevirt-unit-test

@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from c4e7df3 to e9e0f43 Compare April 15, 2021 14:06
@dhiller
Copy link
Contributor Author

dhiller commented Apr 15, 2021

/test pull-kubevirt-unit-test

Also increase go_default_test timeout to "long" for virt-handler tests.

Signed-off-by: Daniel Hiller <dhiller@redhat.com>
@dhiller dhiller force-pushed the for-goveralls-fix-races-in-unit-tests branch from e9e0f43 to 19756a4 Compare April 16, 2021 08:19
@sonarcloud
Copy link

sonarcloud bot commented Apr 16, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@dhiller
Copy link
Contributor Author

dhiller commented Apr 16, 2021

/test pull-kubevirt-unit-test

@dhiller
Copy link
Contributor Author

dhiller commented Apr 16, 2021

/test pull-kubevirt-goveralls

@dhiller
Copy link
Contributor Author

dhiller commented Apr 16, 2021

testing pull-kubevirt-goveralls has failed: https://prow.apps.ovirt.org/view/gcs/kubevirt-prow/pr-logs/pull/kubevirt_kubevirt/5262/pull-kubevirt-goveralls/1382981895888834560

When investigating I found some strange error compiling pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:

...
pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:83: could not determine kind of name for C.CapHyperv
...

Here's the test patch file: https://gist.github.com/dhiller/b51bca27d96b35f27b9fdad8dc30396d

Complete error:

 exec env - \                                                                                                                                                                                                                                                                   
    CC=/usr/bin/gcc \                                                                                                                                                                                                                                                            
    CGO_ENABLED=1 \                                                                                                                                                                                                                                                              
    GOARCH=amd64 \                                                                                                                                                                                                                                                               
    GOOS=linux \                                                                                                                                                                                                                                                                 
    GOPATH='' \                                                                                                                                                                                                                                                                  
    GOROOT=bazel-out/k8-fastbuild/bin/external/io_bazel_rules_go/stdlib_ \                                                                                                                                                                                                       
    GOROOT_FINAL=GOROOT \                                                                                                                                                                                                                                                        
    PATH=/usr/bin:/bin \                                                                                                                                                                                                                                                         
    TMPDIR=/tmp \                                                                                                                                                                                                                                                                
  /root/.cache/bazel/_bazel_root/install/46850c2a96e4b4b07623822a03209f74/process-wrapper '--timeout=0' '--kill_delay=15' bazel-out/host/bin/external/go_sdk/builder compilepkg -sdk external/go_sdk -installsuffix linux_amd64_race -tags selinux,selinux,race -src pkg/virt-han
dler/node-labeller/cpu_plugin.go -src pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go -src pkg/virt-handler/node-labeller/kvm-caps-info-plugin_arm64.go -src pkg/virt-handler/node-labeller/model.go -src pkg/virt-handler/node-labeller/node_labeller.go -src pkg/v
irt-handler/node-labeller/test-util.go -src pkg/virt-handler/node-labeller/cpu_plugin_test.go -src pkg/virt-handler/node-labeller/node_labeller_suite_test.go -src pkg/virt-handler/node-labeller/node_labeller_test.go -arc 'github.com/bazelbuild/rules_go/go/tools/coverdata=g
ithub.com/bazelbuild/rules_go/go/tools/coverdata=bazel-out/k8-fastbuild/bin/external/io_bazel_rules_go/go/tools/coverdata/coverdata.x' -cover_mode atomic -cover pkg/virt-handler/node-labeller/cpu_plugin.go -cover pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go
 -cover pkg/virt-handler/node-labeller/kvm-caps-info-plugin_arm64.go -cover pkg/virt-handler/node-labeller/model.go -cover pkg/virt-handler/node-labeller/node_labeller.go -cover pkg/virt-handler/node-labeller/test-util.go -arc 'kubevirt.io/kubevirt/pkg/testutils=kubevirt.i
o/kubevirt/pkg/testutils=bazel-out/k8-fastbuild/bin/pkg/testutils/go_default_library.x' -arc 'kubevirt.io/kubevirt/pkg/virt-config=kubevirt.io/kubevirt/pkg/virt-config=bazel-out/k8-fastbuild/bin/pkg/virt-config/go_default_library.x' -arc 'kubevirt.io/kubevirt/pkg/virt-hand
ler/node-labeller/util=kubevirt.io/kubevirt/pkg/virt-handler/node-labeller/util=bazel-out/k8-fastbuild/bin/pkg/virt-handler/node-labeller/util/go_default_library.x' -arc 'kubevirt.io/client-go/api/v1=kubevirt.io/client-go/api/v1=bazel-out/k8-fastbuild/bin/staging/src/kubev
irt.io/client-go/api/v1/go_default_library.x' -arc 'kubevirt.io/client-go/kubecli=kubevirt.io/client-go/kubecli=bazel-out/k8-fastbuild/bin/staging/src/kubevirt.io/client-go/kubecli/go_default_library.x' -arc 'kubevirt.io/client-go/log=kubevirt.io/client-go/log=bazel-out/k8
-fastbuild/bin/staging/src/kubevirt.io/client-go/log/go_default_library.x' -arc 'github.com/golang/mock/gomock=kubevirt.io/kubevirt/vendor/github.com/golang/mock/gomock=bazel-out/k8-fastbuild/bin/vendor/github.com/golang/mock/gomock/go_default_library.x' -arc 'github.com/o
nsi/ginkgo=kubevirt.io/kubevirt/vendor/github.com/onsi/ginkgo=bazel-out/k8-fastbuild/bin/vendor/github.com/onsi/ginkgo/go_default_library.x' -arc 'github.com/onsi/gomega=kubevirt.io/kubevirt/vendor/github.com/onsi/gomega=bazel-out/k8-fastbuild/bin/vendor/github.com/onsi/go
mega/go_default_library.x' -arc 'k8s.io/api/core/v1=kubevirt.io/kubevirt/vendor/k8s.io/api/core/v1=bazel-out/k8-fastbuild/bin/vendor/k8s.io/api/core/v1/go_default_library.x' -arc 'k8s.io/apimachinery/pkg/apis/meta/v1=kubevirt.io/kubevirt/vendor/k8s.io/apimachinery/pkg/apis
/meta/v1=bazel-out/k8-fastbuild/bin/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/go_default_library.x' -arc 'k8s.io/apimachinery/pkg/runtime=kubevirt.io/kubevirt/vendor/k8s.io/apimachinery/pkg/runtime=bazel-out/k8-fastbuild/bin/vendor/k8s.io/apimachinery/pkg/runtime/go_defa
ult_library.x' -arc 'k8s.io/client-go/kubernetes/fake=kubevirt.io/kubevirt/vendor/k8s.io/client-go/kubernetes/fake=bazel-out/k8-fastbuild/bin/vendor/k8s.io/client-go/kubernetes/fake/go_default_library.x' -arc 'k8s.io/client-go/testing=kubevirt.io/kubevirt/vendor/k8s.io/cli
ent-go/testing=bazel-out/k8-fastbuild/bin/vendor/k8s.io/client-go/testing/go_default_library.x' -arc 'k8s.io/apimachinery/pkg/types=kubevirt.io/kubevirt/vendor/k8s.io/apimachinery/pkg/types=bazel-out/k8-fastbuild/bin/vendor/k8s.io/apimachinery/pkg/types/go_default_library.
x' -arc 'k8s.io/apimachinery/pkg/util/wait=kubevirt.io/kubevirt/vendor/k8s.io/apimachinery/pkg/util/wait=bazel-out/k8-fastbuild/bin/vendor/k8s.io/apimachinery/pkg/util/wait/go_default_library.x' -arc 'k8s.io/client-go/util/workqueue=kubevirt.io/kubevirt/vendor/k8s.io/clien
t-go/util/workqueue=bazel-out/k8-fastbuild/bin/vendor/k8s.io/client-go/util/workqueue/go_default_library.x' -importpath kubevirt.io/kubevirt/pkg/virt-handler/node-labeller -p kubevirt.io/kubevirt/pkg/virt-handler/node-labeller -package_list bazel-out/host/bin/external/go_s
dk/packages.txt -o bazel-out/k8-fastbuild/bin/pkg/virt-handler/node-labeller/go_default_test.internal.a -x bazel-out/k8-fastbuild/bin/pkg/virt-handler/node-labeller/go_default_test.internal.x -nogo bazel-out/k8-opt-exec-2B5CBBC6/bin/nogo_vet_/nogo_vet -testfilter exclude -
gcflags -race -asmflags '' -cppflags '-I pkg/virt-handler/node-labeller -iquote .' -cflags '-U_FORTIFY_SOURCE -fstack-protector -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__
="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC' -cxxflags '-U_FORTIFY_SOURCE -fstack-protector -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -std=c++0x -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="
redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC' -objcflags '-U_FORTIFY_SOURCE -fstack-protector -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D
__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC' -objcxxflags '-U_FORTIFY_SOURCE -fstack-protector -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -std=c++0x -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -
D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC' -ldflags '--coverage -fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lstdc++ -lm')
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:83: could not determine kind of name for C.CapHyperv
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:100: could not determine kind of name for C.CapHypervSendIPI
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:104: could not determine kind of name for C.CapHypervSynic
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:109: could not determine kind of name for C.CapHypervSynic2
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:87: could not determine kind of name for C.CapHypervTime
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:96: could not determine kind of name for C.CapHypervTlbflush
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:91: could not determine kind of name for C.CapHypervVpIndex
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:185: could not determine kind of name for C.IoctlCheckExtension
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:141: could not determine kind of name for C.IoctlGetMsrIndexList
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:155: could not determine kind of name for C.msr_list_copy_nmsrs
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:172: could not determine kind of name for C.msr_list_get
/root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/sandbox/processwrapper-sandbox/4798/execroot/__main__/pkg/virt-handler/node-labeller/kvm-caps-info-plugin_amd64.go:149: could not determine kind of name for C.msr_list_length
compilepkg: error running the following subcommand: exit status 2                                                                       
PATH=/usr/bin:/bin \                                                                                                                    
CC=/usr/bin/gcc \                                                                                                                       
GOPATH= \                                                                                                                               
GOOS=linux \                                                                                                                            
GOROOT=bazel-out/k8-fastbuild/bin/external/io_bazel_rules_go/stdlib_ \         
CGO_ENABLED=1 \                                                                                                                         
TMPDIR=/tmp \                                                                                                                           
GOROOT_FINAL=GOROOT \                                                                                                                   
GOARCH=amd64 \
CGO_LDFLAGS="--coverage -fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lm -pthread" \
external/go_sdk/pkg/tool/linux_amd64/cgo -srcdir /tmp/rules_go_work-747622126 -objdir /tmp/rules_go_work-747622126 -importpath kubevirt.io/kubevirt/pkg/virt-handler/node-labeller -- -I pkg/virt-handler/node-labeller -iquote . -iquote /tmp/rules_go_work-747622126 -U_FORTIFY
_SOURCE -fstack-protector -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__=redacted -D__TIMESTAMP__=redacted -D__TIME__=redacted -fPIC cover_6.go

@rmohr any ideas?

Signed-off-by: Daniel Hiller <dhiller@redhat.com>
unsafeptr fails in vendored dependencies.

Signed-off-by: Daniel Hiller <dhiller@redhat.com>
@dhiller
Copy link
Contributor Author

dhiller commented Apr 20, 2021

/test pull-kubevirt-unit-test
/test pull-kubevirt-goveralls

@kubevirt-bot
Copy link
Contributor

@dhiller: The following test failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
pull-kubevirt-unit-test f917e17 link /test pull-kubevirt-unit-test

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@kubevirt-bot kubevirt-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 23, 2021
@kubevirt-bot
Copy link
Contributor

@dhiller: PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

This was referenced May 3, 2021
@dhiller
Copy link
Contributor Author

dhiller commented May 3, 2021

Superseded by #5582 and #5583

@dhiller dhiller closed this May 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dco-signoff: yes Indicates the PR's author has DCO signed all their commits. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Several unit tests are flaky and need to get fixed
3 participants