Comments (5)
Fixed with #1037
from rules_jvm_external.
Actually, it looks like this error is coming from _http_file_impl
in core bazel, though we probably need to fix both places.
from rules_jvm_external.
Interesting, I'm not surprised that the build
package is creating a conflict.
I realize it's not ideal but I think you could workaround this for now by downloading the jar in your WORKSPACE with something like
http_file(
name = "build_buf_protovalidate_0_1_9",
sha256 = "d9c141bb6172c3a42283bde148f369772014d79bffc0f243a1da73b9da84e213",
url = "https://repo.maven.apache.org/maven2/build/buf/protovalidate/0.1.9/protovalidate-0.1.9.jar",
)
and then set up a jvm_import rule in a BUILD file
load("@rules_jvm_external//private/rules:jvm_import.bzl", "jvm_import")
jvm_import(
name = "build_buf_protovalidate",
jars = ["build/buf/protovalidate/0.1.9/protovalidate-0.1.9.jar"],
tags = [
"maven_coordinates=build.buf:protovalidate:0.1.9",
"maven_repository=https://maven.global.square/artifactory/square-public/",
"maven_sha256=d9c141bb6172c3a42283bde148f369772014d79bffc0f243a1da73b9da84e213",
"maven_url=https://maven.global.square/artifactory/square-public/build/buf/protovalidate/0.1.9/protovalidate-0.1.9.jar",
],
visibility = ["//visibility:public"],
deps = [
"@maven//:com_github_seancfoley_ipaddress",
"@maven//:com_google_guava_guava",
"@maven//:com_google_protobuf_protobuf_java",
"@maven//:jakarta_mail_jakarta_mail_api",
"@maven//:org_projectnessie_cel_cel_core",
],
)
alias(
name = "build_buf_protovalidate_0_1_9",
actual = "build_buf_protovalidate",
visibility = ["//visibility:public"],
)
genrule(
name = "build_buf_protovalidate_0_1_9_extension",
srcs = ["@build_buf_protovalidate_0_1_9//file"],
outs = ["build/buf/protovalidate/0.1.9/protovalidate-0.1.9.jar"],
cmd = "cp $< $@",
visibility = ["@@//visibility:private"],
)
It means you have to declare all of the protovalidate dependencies in your maven_install rule so you can refer to them as deps, but it should let you use the protovalidate jar.
from rules_jvm_external.
Actually, after looking at it, I think we can fix this just by changing the downloaded_file_path used with http_file when it has a build
directory at the top-level #1037
from rules_jvm_external.
Thanks!
from rules_jvm_external.
Related Issues (20)
- rules_jvm_external 6.1 seems to require artifacts or boms list HOT 2
- Maven lockfile generated with bzlmod enabled is missing deps in WORKSPACE mode HOT 1
- [Bazel CI] Build failed with errors: no native function or rule 'aar_import' HOT 1
- [Bazel CI] Error name 'aar_import' is not defined with Bazel@HEAD HOT 1
- Maven Resolver Fails with 'The entity "oslash" was referenced, but not declared' Error HOT 3
- Maven resolver creates redundant resolver folders, consuming excessive disk space HOT 2
- Maven Resolver Ignores BOM Ordering
- Snapshot artifacts are not resolved by the Maven resolver
- Add a bzlmod extension to override default repositories HOT 2
- Occasional NPE thrown with the Maven resolver HOT 5
- Maven resolver seems to be slower than the Coursier resolver HOT 2
- java_export generated pom.xml does not include <classifier> property
- FR: Ability to customize the location of RJE_UNSAFE_CACHE
- FR: Info about the BOM providing the version in the pinned lock file
- FR: Warnings about deviations from the BOM HOT 2
- FR: A way to exclude deps from artifacts that are determining the versions from BOMs HOT 3
- Maven resolver creates diffs in the lock files even when nothing was changed HOT 3
- Stop including extra artifacts on maven.install() HOT 2
- bzlmod doesnot support "Exporting and consuming artifacts from external repositories"
- coursier uses two different concepts of $HOME, then crashes by failing to relativize paths HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rules_jvm_external.