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

Adding AWS API and other build updates #6086

Closed
wants to merge 1 commit into from

Conversation

chrislovecnm
Copy link
Contributor

Vendored aws-sdk-go, and other general updates. These updates have been
pulled in with a dep ensure command.

I am running into build issue on my mac. Will file and issue.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Dec 23, 2017
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: chrislovecnm
We suggest the following additional approver: q-lee

Assign the PR to them by writing /assign @q-lee 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 OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Dec 23, 2017
@chrislovecnm
Copy link
Contributor Author

chrislovecnm commented Dec 23, 2017

Could use some help on this

$ planter/planter.sh bazel build //...
0.8.1: Pulling from k8s-testimages/planter
Digest: sha256:856c7de085db55aaf2d62d818c3bdbd103ddcf7c135619b274b1abb9091395df
Status: Image is up to date for gcr.io/k8s-testimages/planter:0.8.1
.
Loading:
Loading: 0 packages loaded
Loading: 0 packages loaded
    currently loading: kubetest ... (3 packages)
Loading: 4 packages loaded
    currently loading: kubetest ... (80 packages)
Loading: 83 packages loaded
    currently loading: vendor ... (2 packages)
Loading: 132 packages loaded
Loading: 183 packages loaded
    currently loading: vendor/k8s.io/apimachinery/pkg/runtime
Loading: 230 packages loaded
    currently loading: vendor/k8s.io/contrib/ingress/controllers/gce/storage
Loading: 574 packages loaded
    currently loading: vendor/golang.org/x/text/internal/triegen ... (5 packages)
Loading: 813 packages loaded
Loading: 1246 packages loaded
    currently loading: mungegithub/mungers/approvers ... (4 packages)
Analyzing: 4214 targets (1268 packages loaded)
Analyzing: 4214 targets (1279 packages loaded)
Analyzing: 4214 targets (1289 packages loaded)
ERROR: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/k8s.io/apiserver/pkg/server/BUILD:8:1: no such package 'vendor/github.com/emicklei/go-restful': BUILD file not found on package path and referenced by '//vendor/k8s.io/apiserver/pkg/server:go_default_library'
ERROR: Analysis of target '//vendor/k8s.io/apiserver/pkg/server:go_default_library' failed; build aborted: no such package 'vendor/github.com/emicklei/go-restful': BUILD file not found on package path
INFO: Elapsed time: 25.479s
FAILED: Build did NOT complete successfully (1289 packages loaded)

Not sure why gazelle is not fixing this :(

@chrislovecnm
Copy link
Contributor Author

going through the bazel files and generally hacking them into submission. YAY

@chrislovecnm
Copy link
Contributor Author

Well this is not working :(

This is what I am doing:

  1. create new branch
  2. dep ensure -v -add github.com/aws/aws-sdk-go
  3. hack/update-bazel.sh
  4. run planter to build planter/planter.sh bazel build //...

Getting error:

$ planter/planter.sh bazel build //...
0.8.1: Pulling from k8s-testimages/planter
Digest: sha256:856c7de085db55aaf2d62d818c3bdbd103ddcf7c135619b274b1abb9091395df
Status: Image is up to date for gcr.io/k8s-testimages/planter:0.8.1
.
Loading:
Loading: 0 packages loaded
Loading: 0 packages loaded
    currently loading: kubetest ... (2 packages)
Loading: 156 packages loaded
    currently loading: vendor/k8s.io/contrib/service-loadbalancer ... (5 packages)
Loading: 166 packages loaded
    currently loading: vendor/golang.org/x/crypto/openpgp/elgamal
Loading: 293 packages loaded
Loading: 312 packages loaded
Loading: 354 packages loaded
Loading: 531 packages loaded
    currently loading: vendor/golang.org/x/tools/cmd/stringer ... (4 packages)
Loading: 701 packages loaded
    currently loading: vendor ... (5 packages)
Loading: 714 packages loaded
    currently loading: vendor ... (5 packages)
Loading: 1002 packages loaded
    currently loading: vendor/github.com/aws/aws-sdk-go/service/iotdataplane
Loading: 1243 packages loaded
    currently loading: mungegithub ... (3 packages)
Analyzing: 4214 targets (1268 packages loaded)
Analyzing: 4214 targets (1286 packages loaded)
ERROR: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/github.com/golang/protobuf/protoc-gen-go/testdata/my_test/BUILD:9:1: no such package 'vendor/github.com/golang/protobuf/protoc-gen-go/testdata/multi': BUILD file not found on package path and referenced by '//vendor/github.com/golang/protobuf/protoc-gen-go/testdata/my_test:go_default_library'
ERROR: Analysis of target '//vendor/github.com/golang/protobuf/protoc-gen-go/testdata/my_test:go_default_library' failed; build aborted: no such package 'vendor/github.com/golang/protobuf/protoc-gen-go/testdata/multi': BUILD file not found on package path
INFO: Elapsed time: 23.175s
FAILED: Build did NOT complete successfully (1286 packages loaded)

@chrislovecnm
Copy link
Contributor Author

bazel is NOT happy

hack/verify-bazel.sh
gazelle: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/tools/cmd/fiximports/testdata/src/old.com/bad/bad.go: error reading go file: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/tools/cmd/fiximports/testdata/src/old.com/bad/bad.go:2:43: expected 'package', found 'EOF'
gazelle: found packages a (a.go) and b (b.go) in /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/tools/go/gcimporter15/testdata
gazelle: found packages pointer (pointer.go) and complexnums (complexnums.go) in /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/tools/go/internal/gccgoimporter/testdata
gazelle: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/tools/go/loader/testdata/badpkgdecl.go: error reading go file: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/tools/go/loader/testdata/badpkgdecl.go:1:34: expected 'package', found 'EOF'
diff: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/golang.org/x/text/collate/BUILD/BUILD592358970: No such file or directory
diff: /Users/clove/Workspace/src/k8s.io/test-infra/vendor/k8s.io/contrib/keepalived-vip/BUILD/BUILD386233203: No such file or directory

ideas?

@chrislovecnm
Copy link
Contributor Author

Master is not even building #6088

@geojaz
Copy link
Member

geojaz commented Dec 24, 2017

Funny I'm working on the exact same thing right now @chrislovecnm .

@chrislovecnm
Copy link
Contributor Author

Well did it work any better for you?

@BenTheElder
Copy link
Member

bazel build -- //... -//vendor/..., it's easy to get random non-building junk pulled into vendor, //... says "every target in the repo" when really we only want to build vendor targets that other targets depend on, not just everything. I'll update the readme.

Vendored aws-sdk-go, and other general updates. These updates have been
pulled in with a dep ensure command.
@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Dec 27, 2017

@chrislovecnm: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-test-infra-bazel 5cdd6e2 link /test pull-test-infra-bazel
pull-test-infra-verify-bazel 5cdd6e2 link /test pull-test-infra-verify-bazel

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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.

@BenTheElder
Copy link
Member

+4,964,891 −16

Is the Go AWS SDK actually dependent on roughly five million lines of code !? :(
/hold

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 27, 2017
@BenTheElder
Copy link
Member

I have a feeling this vendors a lot more than is needed (tentatively pointing the finger at dep...), we should see if we can reduce this. If not we should update hack/update-bazel.sh to remove vendor/*/testdata/*.go below the vendor/*_test.go removal until dep sorts this out better :/

The vendor directory at https://github.com/aws/aws-sdk-go/tree/master is much smaller...

xref: #5488

@chrislovecnm
Copy link
Contributor Author

@BenTheElder what is the workflow that I need to follow to add a new dependency?

@BenTheElder
Copy link
Member

@chrislovecnm I'm taking a stab at this actually, but it's:

  • edit Gopkg.toml
  • dep ensure
  • dep prune
  • hack/update-bazel.sh

@BenTheElder BenTheElder mentioned this pull request Dec 27, 2017
@chrislovecnm
Copy link
Contributor Author

closing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants