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

internal: add go.mod and go.sum file #111

Merged
merged 2 commits into from
Nov 9, 2018
Merged

Conversation

jeanbza
Copy link
Member

@jeanbza jeanbza commented Nov 6, 2018

This commit was generated by go mod init && go mod tidy

This commit was generated by go mod init && go mod tidy
@jeanbza jeanbza requested a review from enocom as a code owner November 6, 2018 18:59
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Nov 6, 2018
@jeanbza jeanbza requested review from jba and pongad November 6, 2018 19:00
Copy link
Member

@enocom enocom left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I'd appreciate a second pair of eyes from either @jba or @pongad.

@broady
Copy link
Contributor

broady commented Nov 6, 2018

CL description: "internal" doesn't sound right. maybe "all" or just no prefix?

@@ -0,0 +1,26 @@
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this will cause circular imports? Do we need to split the cloud repo first...?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does genproto need cloud.google.com/go?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yikes. Yeah. I'll go make the relevant mod files. The path is:

genproto -> grpc -> oauth2 -> cloud.google.com/go/compute/metadata

Copy link
Member Author

@jeanbza jeanbza Nov 7, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've come to the conclusion that this cyclic dependency must be allowed if we want to add a go.mod file in the near future:

  • Cyclic module dependencies are OK [1]. Cyclic package dependencies are not OK and enforced by the compiler.
  • x/oauth2/google must get a mod file that specifically requires cloud.google.com/go/compute/metadata instead of cloud.google.com/go to resolve this circular dependency.
  • x/ repos are quite a ways out from getting modules [2] [3].

We could wait for the x/ changes, but I think given the first point it's OK to go ahead now. WDYT?

1: https://groups.google.com/forum/#!searchin/golang-nuts/import$20cycle%7Csort:date/golang-nuts/h2r8ktgOOZI/Pm6uyj5BCQAJ
2: golang/go#28136
3: golang/go#27858

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is slightly unfortunate but sounds fine with me.

@jba
Copy link
Contributor

jba commented Nov 7, 2018 via email

@jeanbza jeanbza mentioned this pull request Nov 8, 2018
Copy link
Contributor

@pongad pongad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove "internal" from description as @broady suggested, but LGTM.

@jeanbza jeanbza merged commit b5d4398 into googleapis:master Nov 9, 2018
@jeanbza jeanbza deleted the modules_add branch June 26, 2019 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants