etcd icon indicating copy to clipboard operation
etcd copied to clipboard

Error when running sample robustness tests in a pristine developer machine

Open karuppiah7890 opened this issue 1 year ago • 2 comments

Bug report criteria

  • [X] This bug report is not security related, security issues should be disclosed privately via etcd maintainers.
  • [X] This is not a support request or question, support requests or questions should be raised in the etcd discussion forums.
  • [X] You have read the etcd bug reporting guidelines.
  • [X] Existing open issues along with etcd frequently asked questions have been checked and this is not a duplicate.

What happened?

I'm a developer trying to contribute to etcd repo for the first time. I setup my machine for the first time for contributing to etcd, so it's a new 🆕 setup / pristine setup. I was trying to run make test-robustness-issue14370 in the latest main, but I got an error -

% env GO111MODULE=off go get github.com/myitcv/gobin
stderr: go: modules disabled by GO111MODULE=off; see 'go help modules'
FAIL: (code:1):
  % env GO111MODULE=off go get github.com/myitcv/gobin

Full Logs -

$ make test-robustness-issue14370
go install go.etcd.io/[email protected]
rm -rf /tmp/etcd-v3.5.4-failpoints/
mkdir -p /tmp/etcd-v3.5.4-failpoints/
cd /tmp/etcd-v3.5.4-failpoints/; \
	  git clone --depth 1 --branch v3.5.4 https://github.com/etcd-io/etcd.git .; \
	  go get go.etcd.io/[email protected]; \
	  (cd server; go get go.etcd.io/[email protected]); \
	  (cd etcdctl; go get go.etcd.io/[email protected]); \
	  (cd etcdutl; go get go.etcd.io/[email protected]); \
	  FAILPOINTS=true ./build;
Cloning into '.'...
remote: Enumerating objects: 1603, done.
remote: Counting objects: 100% (1603/1603), done.
remote: Compressing objects: 100% (1428/1428), done.
remote: Total 1603 (delta 351), reused 577 (delta 139), pack-reused 0
Receiving objects: 100% (1603/1603), 4.16 MiB | 6.09 MiB/s, done.
Resolving deltas: 100% (351/351), done.
Note: switching to '08407ff7600eb16c4445d5f21c4fafaf19412e24'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

go: added go.etcd.io/gofail v0.1.0
go: upgraded github.com/stretchr/testify v1.7.0 => v1.8.1
go: added go.etcd.io/gofail v0.1.0
\e[91mDEPRECATED!!! Use build.sh script instead.\e[0m

% env GO111MODULE=off go get github.com/myitcv/gobin
stderr: go: modules disabled by GO111MODULE=off; see 'go help modules'
FAIL: (code:1):
  % env GO111MODULE=off go get github.com/myitcv/gobin

What did you expect to happen?

No errors to occur as I followed the development guide properly and didn't miss any steps

How can we reproduce it (as minimally and precisely as possible)?

Just ensure you have a pristine developer machine / environment (say a pristine docker container), have golang installed in it, say version 1.22.2 that's mentioned by latest main branch, clone the latest main and run make test-robustness-issue14370

Anything else we need to know?

I know a fix, which is to install gobin before hand in this case

There might be similar issues in running other robustness test targets in make / Makefile, where some tool installation is required - and the tool is not present and some old version's branch is checked out and that branch's code assumes an older golang version and tries to run go commands assuming older golang version

Etcd version (please run commands below)

$ etcd --version
# paste output here

$ etcdctl version
# paste output here

Etcd configuration (command line flags or environment variables)

paste your configuration here

Etcd debug information (please run commands below, feel free to obfuscate the IP address or FQDN in the output)

$ etcdctl member list -w table
# paste output here

$ etcdctl --endpoints=<member list> endpoint status -w table
# paste output here

Relevant log output

$ make test-robustness-issue14370
go install go.etcd.io/[email protected]
rm -rf /tmp/etcd-v3.5.4-failpoints/
mkdir -p /tmp/etcd-v3.5.4-failpoints/
cd /tmp/etcd-v3.5.4-failpoints/; \
	  git clone --depth 1 --branch v3.5.4 https://github.com/etcd-io/etcd.git .; \
	  go get go.etcd.io/[email protected]; \
	  (cd server; go get go.etcd.io/[email protected]); \
	  (cd etcdctl; go get go.etcd.io/[email protected]); \
	  (cd etcdutl; go get go.etcd.io/[email protected]); \
	  FAILPOINTS=true ./build;
Cloning into '.'...
remote: Enumerating objects: 1603, done.
remote: Counting objects: 100% (1603/1603), done.
remote: Compressing objects: 100% (1428/1428), done.
remote: Total 1603 (delta 351), reused 577 (delta 139), pack-reused 0
Receiving objects: 100% (1603/1603), 4.16 MiB | 6.09 MiB/s, done.
Resolving deltas: 100% (351/351), done.
Note: switching to '08407ff7600eb16c4445d5f21c4fafaf19412e24'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

go: added go.etcd.io/gofail v0.1.0
go: upgraded github.com/stretchr/testify v1.7.0 => v1.8.1
go: added go.etcd.io/gofail v0.1.0
\e[91mDEPRECATED!!! Use build.sh script instead.\e[0m

% env GO111MODULE=off go get github.com/myitcv/gobin
stderr: go: modules disabled by GO111MODULE=off; see 'go help modules'
FAIL: (code:1):
  % env GO111MODULE=off go get github.com/myitcv/gobin

karuppiah7890 avatar Apr 25 '24 16:04 karuppiah7890

I would love to look into this, if possible. :)

schristoff avatar May 09 '24 18:05 schristoff

Thanks @schristoff please let us know if you can recreate this.

/assign @schristoff

jmhbnz avatar May 09 '24 18:05 jmhbnz

Discussed during sig-etcd triage meeting. This was reproduced by @ivanvc and has been discussed in slack. Ivan to link slack thread for context.

jmhbnz avatar May 23 '24 18:05 jmhbnz

Link to Slack #sig-etcd thread: https://kubernetes.slack.com/archives/C3HD8ARJ5/p1713974097419449

ivanvc avatar May 23 '24 18:05 ivanvc