Skip to content
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

bazel-watcher: 0.13.1 -> 0.14.0 #105669

Merged
merged 3 commits into from Dec 7, 2020
Merged

Conversation

avdv
Copy link
Member

@avdv avdv commented Dec 2, 2020

Motivation for this change

Using the bazel-watcher from nixpgks-20.09 did not work for some reason (it did not detect file changes and thus did not trigger rebuilds).

There's a new upstream release, and using that instead of the nixpkgs-20.09 version worked fine for me.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@SuperSandro2000
Copy link
Member

Tests fail on darwin:

INFO: Reading 'startup' options from /nix/store/949g749gp5p1n2m3a05mjc0dm87xnpzl-bazel-rc: --server_javabase=/nix/store/s7kbpn3q0fwnihxk8006xzdjx3psgz0n-zulu11.2.3-jdk11.0.1
Server crashed during startup. Now printing /private/tmp/nix-build-bazel-watcher-0.13.1.drv-0/output/server/jvm.out
gRPC server failed to bind to IPv4 and IPv6 localhosts on port 0: [IPv4] Failed to bind
[IPv6] Failed to bind
com.google.devtools.build.lib.util.AbruptExitException: gRPC server failed to bind to IPv4 and IPv6 localhosts on port 0: [IPv4] Failed to bind
[IPv6] Failed to bind
        at com.google.devtools.build.lib.server.GrpcServerImpl.serve(GrpcServerImpl.java:467)
        at com.google.devtools.build.lib.runtime.BlazeRuntime.serverMain(BlazeRuntime.java:1077)
        at com.google.devtools.build.lib.runtime.BlazeRuntime.main(BlazeRuntime.java:769)
        at com.google.devtools.build.lib.bazel.Bazel.main(Bazel.java:84)
Caused by: java.io.IOException: Failed to bind
        at io.grpc.netty.NettyServer.start(NettyServer.java:251)
        at io.grpc.internal.ServerImpl.start(ServerImpl.java:177)
        at io.grpc.internal.ServerImpl.start(ServerImpl.java:85)
        at com.google.devtools.build.lib.server.GrpcServerImpl.serve(GrpcServerImpl.java:464)
        ... 3 more
Caused by: java.net.SocketException: Operation not permitted
        at java.base/sun.nio.ch.Net.bind0(Native Method)
        at java.base/sun.nio.ch.Net.bind(Net.java:461)
        at java.base/sun.nio.ch.Net.bind(Net.java:453)
        at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:227)
        at io.netty.channel.socket.nio.NioServerSocketChannel.doBind(NioServerSocketChannel.java:130)
        at io.netty.channel.AbstractChannel$AbstractUnsafe.bind(AbstractChannel.java:563)
        at io.netty.channel.DefaultChannelPipeline$HeadContext.bind(DefaultChannelPipeline.java:1332)
        at io.netty.channel.AbstractChannelHandlerContext.invokeBind(AbstractChannelHandlerContext.java:488)
        at io.netty.channel.AbstractChannelHandlerContext.bind(AbstractChannelHandlerContext.java:473)
        at io.netty.channel.DefaultChannelPipeline.bind(DefaultChannelPipeline.java:984)
        at io.netty.channel.AbstractChannel.bind(AbstractChannel.java:259)
        at io.netty.bootstrap.AbstractBootstrap$2.run(AbstractBootstrap.java:366)
        at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163)
        at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404)
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:495)
        at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:905)
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        at java.base/java.lang.Thread.run(Thread.java:834)
builder for '/nix/store/xkhij3fl3ica5i391c413jagc0lwwnh8-bazel-watcher-0.13.1.drv' failed with exit code 37
error: build of '/nix/store/xkhij3fl3ica5i391c413jagc0lwwnh8-bazel-watcher-0.13.1.drv' failed

@avdv
Copy link
Member Author

avdv commented Dec 2, 2020

@SuperSandro2000 it seems you still build bazel-watcher 1.13.1?!

The error is just caused by bazel being unable to bind to some port...

@SuperSandro2000
Copy link
Member

Result of nixpkgs-review pr 105669 run on x86_64-linux 1

1 package built:
  • bazel-watcher

@SuperSandro2000
Copy link
Member

The error is just caused by bazel being unable to bind to some port...

That won't work in darwin sandbox.

Now I got:

nix/store/1q4kvvbhxvk4ifgvj46j6y8qvah14phx-compiler-rt-6.0.1/lib -Wl,-F/nix/store/nzq9n9sm12l4fbj72pplbf9973mi32s1-apple-framework-CoreFoundation/Library/Frameworks -Wl,-F/nix/store/cw1mgrsnsf9hkyjgw93sbh54vf3wyfis-apple-framework-CoreServices/Library/Frameworks -Wl,-F/nix/store/ywz5rrvzsvzb0w9d4xficnlbdys9wwd6-apple-framework-Foundation/Library/Frameworks -Wl,-S -undefined dynamic_lookup -headerpad_max_install_names -lstdc++ -lm)                                                                                                                                  Execution platform: //:default_host_platform                                                                                                                                                [396 / 456] 3 actions, 2 running                                                                                                                                                                @com_google_protobuf//:protobuf; 10s local                                                                                                                                                  Linking external/com_google_protobuf/protoc [for host]; 0s local                                                                                                                            [Sched] Linking third_party/nanopb/libnanopb.a                                                                                                                                          0  0x10d868a51  __assert_rtn + 129                                                                                                                                                          1  0x10da41444  ld::passes::stubs::x86_64::classic::LazyPointerAtom::LazyPointerAtom(ld::passes::stubs::Pass&, ld::Atom const&, bool, bool) + 420                                           2  0x10da3ec6a  ld::passes::stubs::Pass::makeStub(ld::Atom const&, bool) + 2762                                                                                                             3  0x10da3fc5f  ld::passes::stubs::Pass::process(ld::Internal&) + 2511                                                                                                                      4  0x10da402c0  ld::passes::stubs::doPass(Options const&, ld::Internal&) + 128                                                                                                              5  0x10d869ff4  main + 1860                                                                                                                                                                 6  0x7fff6c28fcc9  start + 1                                                                                                                                                                A linker snapshot was created at:                                                                                                                                                                   /tmp/cpp_plugin-2020-11-02-181954.ld-snapshot
ld: Assertion failed: (targetAtom != NULL), function Fixup, file ../../../../ld64/src/ld/ld.hpp, line 776.
clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation)
[396 / 456] 3 actions, 2 running
    @com_google_protobuf//:protobuf; 10s local
    Linking external/com_google_protobuf/protoc [for host]; 0s local
    [Sched] Linking third_party/nanopb/libnanopb.a
Target //src:bazel_nojdk failed to build
[399 / 456] checking cached actions
ERROR: /private/tmp/nix-build-bazel-3.3.1.drv-0/bazel_src/src/main/protobuf/BUILD:202:16 Linking of rule '//third_party/grpc:cpp_plugin' failed (Exit 1): cc_wrapper.sh failed: error executing command

We should probably just mark it broken on darwin.

@avdv
Copy link
Member Author

avdv commented Dec 2, 2020

We should probably just mark it broken on darwin.

Yes, seems like all the bazel packages are broken on darwin for quite some time already. bazel-watcher's last successful build was on 2020-07-02... 😮 according to https://hydra.nixos.org/build/131796200 (from 2020-11-30 19:44:26)-- it constantly fails with:

[22 / 430] checking cached actions
In file included from external/com_google_protobuf/src/google/protobuf/compiler/main.cc:33:
external/com_google_protobuf/src/google/protobuf/compiler/cpp/cpp_generator.h:40:10: fatal error: 'string' file not found
#include <string>
         ^~~~~~~~
1 error generated.

(https://nix-cache.s3.amazonaws.com/log/2hacd90axczfv73119l8mardnwqbgw30-bazel-watcher-0.13.1.drv)

@avdv
Copy link
Member Author

avdv commented Dec 2, 2020

Do we still want to let ofborg try to build this PR?

@SuperSandro2000
Copy link
Member

@ofborg build bazel-watcher

@avdv
Copy link
Member Author

avdv commented Dec 3, 2020

Seems to look good:

@ofborg bazel-watcher on aarch64-linux — Success
@ofborg bazel-watcher on x86_64-linux — Success
@ofborg bazel-watcher, bazel-watcher.passthru.tests on aarch64-linux — Success
@ofborg bazel-watcher, bazel-watcher.passthru.tests on x86_64-linux — Success

No builds seem to be pending for darwin? Is this right?

@SuperSandro2000
Copy link
Member

SuperSandro2000 commented Dec 7, 2020

Seems to look good:

@ofborg bazel-watcher on aarch64-linux — Success
@ofborg bazel-watcher on x86_64-linux — Success
@ofborg bazel-watcher, bazel-watcher.passthru.tests on aarch64-linux — Success
@ofborg bazel-watcher, bazel-watcher.passthru.tests on x86_64-linux — Success

No builds seem to be pending for darwin? Is this right?

yeah, darwin was not build. Not sure why. Please mark it broken on darwin then it can be merged.

@avdv
Copy link
Member Author

avdv commented Dec 7, 2020

Please mark it broken on darwin then it can be merged.

Done.

@SuperSandro2000
Copy link
Member

Result of nixpkgs-review pr 105669 run on x86_64-darwin 1

1 package marked as broken and skipped:
  • bazel-watcher

@SuperSandro2000
Copy link
Member

Result of nixpkgs-review pr 105669 run on x86_64-linux 1

1 package built:
  • bazel-watcher

@SuperSandro2000 SuperSandro2000 merged commit d4de077 into NixOS:master Dec 7, 2020
@avdv avdv deleted the bazel-watcher-0.14.0 branch December 7, 2020 19:25
@avdv avdv mentioned this pull request Feb 3, 2021
10 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants