Skip to content

jvm_import_external not failing properly for wrong artifact_sha256 #10353

@guw

Description

@guw

Description of the problem / feature request:

    jvm_maven_import_external(
        name = "info_picocli",
        artifact = "info.picocli:picocli:4.0.4",
        artifact_sha256 = "",
        licenses = ["notice"],
        server_urls = maven_servers,
    )

If artifact_sha256 is empty and maven_servers is a non-secure service Bazel is complaining about the missing artifact_sha256.

However, if I specify a wrong artifact_sha256 (copy and paste error on my end), Bazel build is not failing with a "wrong sha error" but with a weird: Extracting interface @info_picocli//:info_picocli failed (Aborted): ijar failed: error executing command because of Unable to open Zip file external/info_picocli/....jar: Input/output error

Feature requests: what underlying problem are you trying to solve with this feature?

Bazel should fail with a message explaining that the SHA is wrong.

What's the output of bazel info release?

1.2.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3We're not considering working on this, but happy to review a PR. (No assignee)team-ExternalDepsExternal dependency handling, remote repositiories, WORKSPACE file.type: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions