Skip to content

Bazel reports build success when it was not successful #7115

Closed

Description

@meteorcloudy

This bug was filed at bazelbuild/continuous-integration#449, but it should be a Bazel bug

/cc @c-parsons @laurentlb

Activity

  1. added
    P1
    on Jan 14, 2019
  2. added
    team-Core
    and removed on Jan 14, 2019
  3. laurentlb commented on Jan 14, 2019

    @laurentlb
    Contributor

    In the interpreter, we throw an exception for this. It is properly reported one level up: package contains errors: e2e/output_runner. But later, something swallows the error. I don't know what happens, I suspect it's related to --keep_going, so assigning to core team to investigate.

  4. laurentlb commented on Jan 14, 2019

    @laurentlb
    Contributor

    Repro:

    touch WORKSPACE
    mkdir sub
    touch test.sh && chmod +x test.sh
    echo 'sh_test(name = "test", srcs = ["test.sh"])' > BUILD
    echo 'parse error' > sub/BUILD
    bazel test //... -k
    

    If one package cannot be loaded, but all other tests pass, Bazel returns 0.

  5. laurentlb commented on Jan 14, 2019

    @laurentlb
    Contributor

    In the repro above: if sub/BUILD declares at least one target, the exit code is properly set to 1.

    cc @ericfelly who should own this?

  6. ericfelly commented on Jan 14, 2019

    @ericfelly
    Contributor

    Nathan, can you take a look?

  7. haxorz commented on Jan 14, 2019

    @haxorz
    Contributor

    is this really P1?

  8. jin commented on Jan 14, 2019

    @jin
    Member

    @haxorz if it's not a P1 according to the definitions, please reassign the correct priority. thanks!

  9. meteorcloudy commented on Jan 15, 2019

    @meteorcloudy
    MemberAuthor

    If we don't fix this issue, Bazel users (including us) could miss potential failures in the build, I think it's a pretty serious issue (P1).

  10. laurentlb commented on Jan 15, 2019

    @laurentlb
    Contributor

    I had a quick look yesterday. This issue also affects Google (Blaze) and has been around for at least a year. I'm surprised it didn't come up before.

  11. haxorz commented on Jan 15, 2019

    @haxorz
    Contributor

    ok, i will look into this today

  12. meteorcloudy commented on Jan 15, 2019

    @meteorcloudy
    MemberAuthor

    Thank you!

  13. added a commit that references this issue on Jan 31, 2019
    14150b0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P1team-Coretype: bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions