-
Notifications
You must be signed in to change notification settings - Fork 9.7k
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
Regresion: newest version requiring Bazaar to compile #21080
Comments
Hi @bltavares, I think we will need to admit defeat here. If our dependencies are distributed via a Bazaar repository then we can't avoid needing The usual answer to this is to make use of the
If you are changing the dependencies for another repository (such as a Terraform provider) then you will need to have the tools necessary to access those dependencies. I don't think we can really avoid that. The longer-term goal here is for the Terraform provider SDK to not be in this repository at all, at instead to move out into its own repository. At that point, the dependencies of Terraform itself will not become transitive dependencies of the providers. In the mean time, perhaps I can help you out by creating a branch in the |
I pushed up a branch It looks like a transitive dependency here has also required moving to a new major release of the |
@apparentlymart that is unfortunate. It seems that it is completely avoidable if all the dependencies included use I've tried again applying the same strategy of removing the failing dependencies, and after running I've quickly came up with a test strategy to avoid including bazaar dependencies, which could also expand to avoid What do you think of this strategy? I do understand if that is not the way to Go, but requiring |
Regarding I've already build two other features on top of it (https://github.com/terraform-providers/terraform-provider-github/pull/211 and https://github.com/terraform-providers/terraform-provider-github/pull/212) and I've been using it internally. so far so good. My next step was going to try to bump it to the beta release, to use HCL2 syntax, but then I've found the bazaar bug again. |
I have updated my I was then able to build it without any external dependencies:
Looking again at this issue with Bazaar on Windows: from the stack trace, it looks like this error is actually coming from the Bazaar git plugin. I don't know Bazaar well at all, but from a quick read of the source code involved it seems like this plugin is probing I assume the idea here is that you can use <meta name="go-import" content="launchpad.net/mgo/v2 bzr https://launchpad.net/~niemeyer/mgo/v2" /> With all of that said, I wonder if it would work to just disable the Git plugin entirely by setting
Over in |
That is a really thorough writup, thank you so much. I would be able to test disabling the When testing it last time, I've just used the regular Bazaar install on Windows, and I was not even aware of such integration. Disabling it seems like an extra hoop to jump when writing providers, and very likely, vendoring would need to be documented due the pitfall. I think it would be better to track down which dependency is bringing the What do you think of updating the dependencies which bring in the |
For
We can see from here that the However, I noticed that we were pinned to an older version of I'm not going to promise that there will never be a dependency from |
Meanwhile, I was trying out the suggestion of disabling bzr-git. I've installed the I've tried using depth, but the dependency tree output don't even show up for those dependencies. It is very likely to be one of the issues of managing dev tools on (Sharing those for the sake of documentation.) #21082 looks like a good solution, and I understand it is impossible to promise no new Thank you so much for how thorough your comments were. Landing the update version would help a lot when Terraform 0.12 is announced and providers need to upgrade. It will save a lot of frustration for those coding on Mac and Windows (and some Linux users), which often don't even have Bazaar installed. |
Fixed by #21082 |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
On a previous PR (#20870), we've removed the dependency on
mgo
andgocheck
hosted onbzr
repositories to avoid downstream libraries to also depend on this extra build tool.A recent commit reintroduced those dependencies: 8a43011
Now, compiling providers with the latest beta does require
bzr
on the system to download the libs, even tho it's used onterraform
.Terraform Version
master
v0.12.0-beta2
Expected Behavior
Actual Behavior
v0.12.0-beta2
to compile a provider to match the compatible plugin version crashes whenbzr
is not present, when it didn't crash before.Steps to Reproduce
go.mod
to point toterraform v0.12.0-beta2
go mod tidy
on a computer withoutbzr
Additional Context
How could we avoid reintroducing the error? Removing
bzr
from the PR CI would be an alternative?References
The text was updated successfully, but these errors were encountered: