rules_proto icon indicating copy to clipboard operation
rules_proto copied to clipboard

rules_proto overrides some external dependencies with specific versions

Open blasnier opened this issue 7 years ago • 2 comments

Hello,

In deps.bzl, when importing external dependencies, some functions check if the dependency is already registered before importing it and some do not. For example here, we check for an existing reference to boringssl but here we download a specific version of GRPC right away.

Could we generalize the if "xxxxx" not in native.existing_rules(): pattern to every import? That would allow the user to update dependencies sooner and more easily.

There is a similar issue with the nuget packages but I do not know how we could improve this behavior.

blasnier avatar Jun 11 '19 09:06 blasnier

The grpc example uses the github_archive macro that does a check for native.existing_rules. So I think this generalization is already the default behavior. Am I missing something?

https://github.com/stackb/rules_proto/blob/2f4e4f62a3d7a43654d69533faa0652e1c4f5082/deps.bzl#L52

pcj avatar Jun 11 '19 17:06 pcj

No, you are right. We had an issue of Protobuf 3.6.1 being used instead of version 3.7 and when I saw the differences in deps.bzl I thought that was the cause. I will investigate more thoroughly and open another issue if it is truly related to rules_proto. Sorry for the inconvenience.

blasnier avatar Jun 12 '19 15:06 blasnier