-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Wrong update version for go module in subdirectory #4589
Comments
It's basing this on the raw hashicorp/consul releases: But actually it should be following the api/* releases: @hairyhenderson I don't suppose you already know where this Go behaviour is specified? I want to make sure there's nothing else we're missing. |
@viceice I'm thinking we might need to try to leverage our "compatibility" versioning concept here, like we do with Docker suffixes |
What about to have prefix and suffix options? |
I'm trying to locate some Go specs on this first before making a decision. For example I want to see if this is always how the versions work, if there is any fallback to non-prefixed releases, and if there is possibility to nest more than one deep. I don't suppose @bcmills can point us in the right direction documentation/specification-wise? Thanks |
There is some mention here in the Go Modules wiki: https://github.com/golang/go/wiki/Modules#faqs--multi-module-repositories: With some somewhat-cryptic statements like:
I haven't found anything more "official" than that though... |
Thanks for that. Sounds like we need to support arbitrary depth then. |
You're specifically referring to |
dummy example:
Get all deps:
Get all updates:
Get one update at a time:
Try to get an update for a module not in the go.mod:
Attempting to look up versions from a random directory:
In conclusion: if we have a "dummy" modules project to run the child process from, it seems we can indeed shell out to The main thing I'd been worried about was that we wouldn't get back the full list of versions, but it appears that's not a problem here. So I think this approach is indeed compatible with Renovate's logic. One more concern: Can this |
You can set |
|
For example:
|
It just occurred to me that the list all command is including indirect dependencies, which I don’t think Renovate should be updating. Is there any lost command that lists all direct dependencies but no indirect? |
There isn't a simple one at the moment, no. |
What about iterating through the |
Yes, you could do that — just be sure to check the |
another examples https://github.com/googleapis/google-cloud-go/releases |
Hi @rarkins,
|
Yes, we only use those binaries for artifacts updating (performance) |
Then we are left with only the first option 😃 |
@rarkins is there any reason to not implement the first suggested solution ? |
No reason. We should try to mimic Go's logic (including if it falls back to using plain tags) |
@rarkins @nabeelsaabna i cant reproduce the issue, i tried debugging apparently @zharinov already fixed it in his refactor of go back in 27 October 2021 : #12359 here: renovate/lib/modules/datasource/go/releases-direct.ts Lines 96 to 105 in fd00fd5
|
What Renovate type are you using?
Hosted
Describe the bug
See hairyhenderson/gomplate#603 (comment) for the error.
Looks like renovate picked up the
github.com/hashicorp/consul
v1.6.1
tag, however thegithub.com/hashicorp/consul/api
module is atv1.2.0
still. This is reflected by the presence of anapi/v1.2.0
tag.Did you see anything helpful in debug logs?
Nope!
To Reproduce
Steps to reproduce the behavior:
github.com/hashicorp/consul/api
packagev1.2.0
!Expected behavior
Renovate should understand the
api/v1.2.0
tag.Screenshots
See hairyhenderson/gomplate#603
The text was updated successfully, but these errors were encountered: