Skip to content

Add CI jobs and fix clang-tidy and iwyu errors - #184

Merged
ryanofsky merged 16 commits into
bitcoin-core:masterfrom
ryanofsky:pr/ci
Jun 26, 2025
Merged

Add CI jobs and fix clang-tidy and iwyu errors#184
ryanofsky merged 16 commits into
bitcoin-core:masterfrom
ryanofsky:pr/ci

Conversation

@ryanofsky

@ryanofsky ryanofsky commented Jun 20, 2025

Copy link
Copy Markdown
Collaborator

The main thing this change does is add a simple github actions CI job to build the project, run tests, and do checks with iwyu and clang-tidy.

It also fixes bitcoin CI warnings reported by fanquake in bitcoin/bitcoin#31802 (comment) that show up in the logs but do not cause errors, as well as a number of other warnings that do not seem to show up in bitcoin CI. Individual commit messages describe the fixes in detail.

ryanofsky added 12 commits June 19, 2025 22:17
src/mp/gen.cpp:82:13: error: function 'ForEachMethod' is within a recursive call chain [misc-no-recursion,-warnings-as-errors]
   82 | static void ForEachMethod(const capnp::InterfaceSchema& interface, const std::function<void(const capnp::InterfaceSchema& interface, const capnp::InterfaceSchema::Method)>& callback)
include/mp/proxy-types.h:203:98: error: 'values' used after it was forwarded [bugprone-use-after-move,-warnings-as-errors]
  203 |         CustomBuildField(TypeList<LocalTypes...>(), Priority<3>(), context, std::forward<Values>(values)...,
      |                                                                                                  ^
include/mp/proxy-types.h:202:9: note: forward occurred here
  202 |     if (CustomHasValue(context, std::forward<Values>(values)...)) {
      |         ^
include/mp/proxy-types.h:333:74: error: 'arg2' used after it was forwarded [bugprone-use-after-move,-warnings-as-errors]
  333 |         next_fn.handleChain(std::forward<Arg1>(arg1), std::forward<Arg2>(arg2), typename S::Second(),
      |                                                                          ^
include/mp/proxy-types.h:332:9: note: forward occurred here
  332 |         handleChain(std::forward<Arg1>(arg1), std::forward<Arg2>(arg2), typename S::First());
include/mp/proxy-types.h:399:70: error: 'values' used after it was forwarded [bugprone-use-after-move,-warnings-as-errors]
  399 |                     ParamList(), Priority<1>(), std::forward<Values>(values)..., Make<StructField, Accessor>(params));
      |                                                                      ^
include/mp/proxy-types.h:396:17: note: forward occurred here
  396 |                 MaybeBuildField(std::integral_constant<bool, Accessor::in>(), ParamList(), invoke_context,
include/mp/type-number.h:53:77: error: use nullptr [modernize-use-nullptr,-warnings-as-errors]
   53 |     typename std::enable_if<std::is_enum<LocalType>::value>::type* enable = 0)
      |                                                                             ^
      |                                                                             nullptr
mp/include/mp/util.h:173:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors]
  173 |     ~Lock() MP_RELEASE() {}
      |     ^                    ~~
      |                          = default;
This error should not be a real problem because code is taking an invalid
reference to an empty object that has no state and could never be used. But
taking the reference could technically be undefined behavior.

Reported by fanquake <fanquake@gmail.com>
bitcoin/bitcoin#31802 (comment)
https://cirrus-ci.com/task/6552721135763456
https://api.cirrus-ci.com/v1/task/6552721135763456/logs/ci.log

include/mp/proxy-types.h:134:5: error: Address of stack memory associated with temporary object of type '(lambda at include/mp/proxy-types.h:134:51)' is still referred to by a temporary object on the stack upon returning to the caller.  This will be a dangling reference [clang-analyzer-core.StackAddressEscape,-warnings-as-errors]
  134 |     return ReadDestEmplace{TypeList<LocalType>(), [&](auto&&... args) -> decltype(auto) {
      |     ^
build/test/mp/test/foo.capnp.proxy-server.c++:51:12: note: Calling 'serverInvoke<mp::ProxyServer<mp::test::messages::FooInterface>, capnp::CallContext<mp::test::messages::FooInterface::PassCustomParams, mp::test::messages::FooInterface::PassCustomResults>, mp::ServerField<1, mp::Accessor<mp::foo_fields::Arg, 17>, mp::ServerRet<mp::Accessor<mp::foo_fields::Result, 18>, mp::ServerCall>>>'
   51 |     return serverInvoke(*this, call_context, MakeServerField<1, Accessor<foo_fields::Arg, FIELD_IN | FIELD_BOXED>>(Make<ServerRet, Accessor<foo_fields::Result, FIELD_OUT | FIELD_BOXED>>(ServerCall())));
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:739:16: note: Calling 'ReplaceVoid<(lambda at include/mp/proxy-types.h:739:28), (lambda at include/mp/proxy-types.h:740:13)>'
  739 |         return ReplaceVoid([&]() { return fn.invoke(server_context, ArgList()); },
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  740 |             [&]() { return kj::Promise<CallContext>(kj::mv(call_context)); })
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:700:19: note: 'is_same_v' is true
  700 |     if constexpr (std::is_same_v<decltype(fn()), void>) {
      |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:700:5: note: Taking true branch
  700 |     if constexpr (std::is_same_v<decltype(fn()), void>) {
      |     ^
include/mp/proxy-types.h:701:9: note: Calling 'operator()'
  701 |         fn();
      |         ^~~~
include/mp/proxy-types.h:739:43: note: Calling 'ServerField::invoke'
  739 |         return ReplaceVoid([&]() { return fn.invoke(server_context, ArgList()); },
      |                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:563:16: note: Calling 'PassField<mp::Accessor<mp::foo_fields::Arg, 17>, mp::test::FooCustom, mp::ServerInvokeContext<mp::ProxyServer<mp::test::messages::FooInterface>, capnp::CallContext<mp::test::messages::FooInterface::PassCustomParams, mp::test::messages::FooInterface::PassCustomResults>>, const mp::ServerRet<mp::Accessor<mp::foo_fields::Result, 18>, mp::ServerCall> &, mp::TypeList<>>'
  563 |         return PassField<Accessor>(Priority<2>(),
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  564 |             typename Split<argc, ArgTypes>::First(),
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  565 |             server_context,
      |             ~~~~~~~~~~~~~~~
  566 |             this->parent(),
      |             ~~~~~~~~~~~~~~~
  567 |             typename Split<argc, ArgTypes>::Second(),
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  568 |             std::forward<Args>(args)...);
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:304:5: note: Calling 'MaybeReadField<mp::TypeList<mp::test::FooCustom>, mp::InvokeContext &, mp::StructField<mp::Accessor<mp::foo_fields::Arg, 17>, const mp::test::messages::FooInterface::PassCustomParams::Reader>, mp::ReadDestEmplace<mp::test::FooCustom, (lambda at include/mp/proxy-types.h:305:83)>>'
  304 |     MaybeReadField(std::integral_constant<bool, Accessor::in>(), TypeList<ArgType>(), invoke_context,
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  305 |         Make<StructField, Accessor>(params), ReadDestEmplace(TypeList<ArgType>(), [&](auto&&... args) -> auto& {
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  306 |             param.emplace(std::forward<decltype(args)>(args)...);
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  307 |             return *param;
      |             ~~~~~~~~~~~~~~
  308 |         }));
      |         ~~~
include/mp/proxy-types.h:276:5: note: Calling 'ReadField<mp::test::FooCustom, mp::InvokeContext &, mp::StructField<mp::Accessor<mp::foo_fields::Arg, 17>, const mp::test::messages::FooInterface::PassCustomParams::Reader>, mp::ReadDestEmplace<mp::test::FooCustom, (lambda at include/mp/proxy-types.h:305:83)>>'
  276 |     ReadField(std::forward<Args>(args)...);
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:175:12: note: Calling 'CustomReadField<mp::StructField<mp::Accessor<mp::foo_fields::Arg, 17>, const mp::test::messages::FooInterface::PassCustomParams::Reader>, mp::ReadDestEmplace<mp::test::FooCustom, (lambda at include/mp/proxy-types.h:305:83)>>'
  175 |     return CustomReadField(TypeList<RemoveCvRef<LocalTypes>...>(), Priority<2>(), std::forward<Args>(args)...);
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
test/mp/test/foo-types.h:51:12: note: Calling 'ReadDestEmplace::update'
   51 |     return read_dest.update([&](FooCustom& value) {
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   52 |         value.v1 = ReadField(TypeList<std::string>(), invoke_context, mp::Make<mp::ValueField>(custom.getV1()), ReadDestTemp<std::string>());
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   53 |         value.v2 = custom.getV2();
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~
   54 |     });
      |     ~~
include/mp/proxy-types.h:112:23: note: 'is_const_v' is false
  112 |         if constexpr (std::is_const_v<std::remove_reference_t<std::invoke_result_t<EmplaceFn>>>) {
      |                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:112:9: note: Taking false branch
  112 |         if constexpr (std::is_const_v<std::remove_reference_t<std::invoke_result_t<EmplaceFn>>>) {
      |         ^
include/mp/proxy-types.h:122:13: note: Calling 'operator()'
  122 |             update_fn(temp);
      |             ^~~~~~~~~~~~~~~
test/mp/test/foo-types.h:52:113: note: Calling 'ReadDestTemp<std::basic_string<char>>'
   52 |         value.v1 = ReadField(TypeList<std::string>(), invoke_context, mp::Make<mp::ValueField>(custom.getV1()), ReadDestTemp<std::string>());
      |                                                                                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:134:5: note: Address of stack memory associated with temporary object of type '(lambda at include/mp/proxy-types.h:134:51)' is still referred to by a temporary object on the stack upon returning to the caller.  This will be a dangling reference
  134 |     return ReadDestEmplace{TypeList<LocalType>(), [&](auto&&... args) -> decltype(auto) {
      |     ^                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  135 |         return LocalType{std::forward<decltype(args)>(args)...};
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  136 |     }};
      |     ~
Reported by fanquake <fanquake@gmail.com>
bitcoin/bitcoin#31802 (comment)
https://cirrus-ci.com/task/6552721135763456
https://api.cirrus-ci.com/v1/task/6552721135763456/logs/ci.log

include/mp/type-number.h:55:32: error: The value '0' provided to the cast expression is not in the valid range of values for 'FooEnum' [clang-analyzer-optin.core.EnumCastOutOfRange,-warnings-as-errors]
   55 |     return read_dest.construct(static_cast<LocalType>(input.get()));
      |                                ^
test/mp/test/foo.h:26:12: note: enum declared here
   26 | enum class FooEnum : uint8_t { ONE = 1, TWO = 2, };
      | ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
build/test/mp/test/foo.capnp.proxy-server.c++:63:12: note: Calling 'serverInvoke<mp::ProxyServer<mp::test::messages::FooInterface>, capnp::CallContext<mp::test::messages::FooInterface::PassEnumParams, mp::test::messages::FooInterface::PassEnumResults>, mp::ServerField<1, mp::Accessor<mp::foo_fields::Arg, 1>, mp::ServerRet<mp::Accessor<mp::foo_fields::Result, 2>, mp::ServerCall>>>'
   63 |     return serverInvoke(*this, call_context, MakeServerField<1, Accessor<foo_fields::Arg, FIELD_IN>>(Make<ServerRet, Accessor<foo_fields::Result, FIELD_OUT>>(ServerCall())));
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:739:16: note: Calling 'ReplaceVoid<(lambda at include/mp/proxy-types.h:739:28), (lambda at include/mp/proxy-types.h:740:13)>'
  739 |         return ReplaceVoid([&]() { return fn.invoke(server_context, ArgList()); },
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  740 |             [&]() { return kj::Promise<CallContext>(kj::mv(call_context)); })
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:700:19: note: 'is_same_v' is true
  700 |     if constexpr (std::is_same_v<decltype(fn()), void>) {
      |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:700:5: note: Taking true branch
  700 |     if constexpr (std::is_same_v<decltype(fn()), void>) {
      |     ^
include/mp/proxy-types.h:701:9: note: Calling 'operator()'
  701 |         fn();
      |         ^~~~
include/mp/proxy-types.h:739:43: note: Calling 'ServerField::invoke'
  739 |         return ReplaceVoid([&]() { return fn.invoke(server_context, ArgList()); },
      |                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:563:16: note: Calling 'PassField<mp::Accessor<mp::foo_fields::Arg, 1>, mp::test::FooEnum, mp::ServerInvokeContext<mp::ProxyServer<mp::test::messages::FooInterface>, capnp::CallContext<mp::test::messages::FooInterface::PassEnumParams, mp::test::messages::FooInterface::PassEnumResults>>, const mp::ServerRet<mp::Accessor<mp::foo_fields::Result, 2>, mp::ServerCall> &, mp::TypeList<>>'
  563 |         return PassField<Accessor>(Priority<2>(),
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  564 |             typename Split<argc, ArgTypes>::First(),
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  565 |             server_context,
      |             ~~~~~~~~~~~~~~~
  566 |             this->parent(),
      |             ~~~~~~~~~~~~~~~
  567 |             typename Split<argc, ArgTypes>::Second(),
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  568 |             std::forward<Args>(args)...);
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:304:5: note: Calling 'MaybeReadField<mp::TypeList<mp::test::FooEnum>, mp::InvokeContext &, mp::StructField<mp::Accessor<mp::foo_fields::Arg, 1>, const mp::test::messages::FooInterface::PassEnumParams::Reader>, mp::ReadDestEmplace<mp::test::FooEnum, (lambda at include/mp/proxy-types.h:305:83)>>'
  304 |     MaybeReadField(std::integral_constant<bool, Accessor::in>(), TypeList<ArgType>(), invoke_context,
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  305 |         Make<StructField, Accessor>(params), ReadDestEmplace(TypeList<ArgType>(), [&](auto&&... args) -> auto& {
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  306 |             param.emplace(std::forward<decltype(args)>(args)...);
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  307 |             return *param;
      |             ~~~~~~~~~~~~~~
  308 |         }));
      |         ~~~
include/mp/proxy-types.h:276:5: note: Calling 'ReadField<mp::test::FooEnum, mp::InvokeContext &, mp::StructField<mp::Accessor<mp::foo_fields::Arg, 1>, const mp::test::messages::FooInterface::PassEnumParams::Reader>, mp::ReadDestEmplace<mp::test::FooEnum, (lambda at include/mp/proxy-types.h:305:83)>>'
  276 |     ReadField(std::forward<Args>(args)...);
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:175:12: note: Calling 'CustomReadField<mp::test::FooEnum, mp::StructField<mp::Accessor<mp::foo_fields::Arg, 1>, const mp::test::messages::FooInterface::PassEnumParams::Reader>, mp::ReadDestEmplace<mp::test::FooEnum, (lambda at include/mp/proxy-types.h:305:83)>>'
  175 |     return CustomReadField(TypeList<RemoveCvRef<LocalTypes>...>(), Priority<2>(), std::forward<Args>(args)...);
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/type-number.h:55:55: note: Calling 'StructField::get'
   55 |     return read_dest.construct(static_cast<LocalType>(input.get()));
      |                                                       ^~~~~~~~~~~
include/mp/proxy-types.h:40:41: note: Calling 'Arg::get'
   40 |     decltype(auto) get() const { return Accessor::get(this->m_struct); }
      |                                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
build/test/mp/test/foo.capnp.proxy.h:198:82: note: Calling 'Reader::getArg'
  198 |     template<typename S> static auto get(S&& s) -> decltype(s.getArg()) { return s.getArg(); }
      |                                                                                  ^~~~~~~~~~
build/test/mp/test/foo.capnp.h:7042:10: note: Calling 'StructReader::getDataField'
 7042 |   return _reader.getDataField< ::int32_t>(
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 7043 |       ::capnp::bounded<0>() * ::capnp::ELEMENTS);
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/capnp/layout.h:1099:7: note: Assuming the condition is false
 1099 |   if ((offset + ONE * ELEMENTS) * capnp::bitsPerElement<T>() <= dataSize) {
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/capnp/layout.h:1099:3: note: Taking false branch
 1099 |   if ((offset + ONE * ELEMENTS) * capnp::bitsPerElement<T>() <= dataSize) {
      |   ^
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/capnp/layout.h:1102:5: note: Returning zero
 1102 |     return static_cast<T>(0);
      |     ^~~~~~~~~~~~~~~~~~~~~~~~
build/test/mp/test/foo.capnp.h:7042:10: note: Returning from 'StructReader::getDataField'
 7042 |   return _reader.getDataField< ::int32_t>(
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 7043 |       ::capnp::bounded<0>() * ::capnp::ELEMENTS);
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
build/test/mp/test/foo.capnp.h:7042:3: note: Returning zero
 7042 |   return _reader.getDataField< ::int32_t>(
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 7043 |       ::capnp::bounded<0>() * ::capnp::ELEMENTS);
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
build/test/mp/test/foo.capnp.proxy.h:198:82: note: Returning from 'Reader::getArg'
  198 |     template<typename S> static auto get(S&& s) -> decltype(s.getArg()) { return s.getArg(); }
      |                                                                                  ^~~~~~~~~~
build/test/mp/test/foo.capnp.proxy.h:198:75: note: Returning zero
  198 |     template<typename S> static auto get(S&& s) -> decltype(s.getArg()) { return s.getArg(); }
      |                                                                           ^~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:40:41: note: Returning from 'Arg::get'
   40 |     decltype(auto) get() const { return Accessor::get(this->m_struct); }
      |                                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:40:34: note: Returning zero
   40 |     decltype(auto) get() const { return Accessor::get(this->m_struct); }
      |                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/type-number.h:55:55: note: Returning from 'StructField::get'
   55 |     return read_dest.construct(static_cast<LocalType>(input.get()));
      |                                                       ^~~~~~~~~~~
include/mp/type-number.h:55:32: note: The value '0' provided to the cast expression is not in the valid range of values for 'FooEnum'
   55 |     return read_dest.construct(static_cast<LocalType>(input.get()));
      |                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Reported by fanquake <fanquake@gmail.com>
bitcoin/bitcoin#31802 (comment)
https://cirrus-ci.com/task/6552721135763456
https://api.cirrus-ci.com/v1/task/6552721135763456/logs/ci.log

Error is spurious and comes from kj/async-inl.h and should be suppressed in the
next version of capnproto capnproto/capnproto#2334

The error is a clang-analyzer false positive that comes from ABI-specific code
in Cap'n Proto that gets the starting function address (that can be passed to
addr2line) from a lambda or function object. This code calls a helper to get
the starting function address from a pointer-to-member-function, which in this
case is the the operator() member function. That code handles pointers to
virtual member functions, so it checks if the pointer is virtual by testing its
low-order bit, and if set, assumes the first bytes of the object are a vtable
pointer, and does pointer arithmetic with the vtable address. Clang-tidy
complains about this because it does not know the vtable address is valid,
assuming incorrectly it is a "garbage value".

This change turns off the UndefinedBinaryOperatorResult altogether instead of
suppressing this one instance because clang-tidy incorrectly considers this
error to come from "main file" of the translation unit (see
https://clang.llvm.org/extra/clang-tidy/, https://stackoverflow.com/a/47611238,
https://reviews.llvm.org/D26418). So it is not suppressed even though the
header is included via -isystem and clang-tidy --dump-config shows
"SystemHeaders: false". It is also not suppressed when exclude patterns are
added to the .clang-tidy configuration like:

  HeaderFilterRegex: '.*'
  ExcludeHeaderFilterRegex: '.*/include/kj/async-inl\.h$'

This has no effect because ExcludeHeaderFilterRegex does not override the
isInMainFile condition (https://github.com/llvm/llvm-project/pull/91400/files).

Adding NOLINT to the getLocalServer() line in types-context.h at the boundary
between libmultiprocess and Cap'n Proto code also does not suppress the error.
It does suppress clang-tidy "note:" lines below the NOLINT point in the call
stack, making the error messages shorter, but the only way of suppressing the
error completely seems to be either adding NOLINT inside the Cap'n Proto
header, which requires a patch, or adding it to all top-level callers of the
getLocalServer() function in .cpp files, which seems impractical and overbroad,
and I didn't attempt.

Complete error output is:

/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/kj/async-inl.h:609:37: error: The left operand of '+' is a garbage value [clang-analyzer-core.UndefinedBinaryOperatorResult,-warnings-as-errors]
  609 |       return *(void**)(*(char**)obj + voff);
      |                                     ^
build/test/mp/test/foo.capnp.proxy-server.c++:93:12: note: Calling 'serverInvoke<mp::ProxyServer<mp::test::messages::FooFn>, capnp::CallContext<mp::test::messages::FooFn::CallParams, mp::test::messages::FooFn::CallResults>, mp::ServerField<0, mp::Accessor<mp::foo_fields::Context, 17>, mp::ServerRet<mp::Accessor<mp::foo_fields::Result, 2>, mp::ServerCall>>>'
   93 |     return serverInvoke(*this, call_context, MakeServerField<0, Accessor<foo_fields::Context, FIELD_IN | FIELD_BOXED>>(Make<ServerRet, Accessor<foo_fields::Result, FIELD_OUT>>(ServerCall())));
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:739:16: note: Calling 'ReplaceVoid<(lambda at include/mp/proxy-types.h:739:28), (lambda at include/mp/proxy-types.h:740:13)>'
  739 |         return ReplaceVoid([&]() { return fn.invoke(server_context, ArgList()); },
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  740 |             [&]() { return kj::Promise<CallContext>(kj::mv(call_context)); })
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:700:19: note: 'is_same_v' is false
  700 |     if constexpr (std::is_same_v<decltype(fn()), void>) {
      |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:700:5: note: Taking false branch
  700 |     if constexpr (std::is_same_v<decltype(fn()), void>) {
      |     ^
include/mp/proxy-types.h:704:16: note: Calling 'operator()'
  704 |         return fn();
      |                ^~~~
include/mp/proxy-types.h:739:43: note: Calling 'ServerField::invoke'
  739 |         return ReplaceVoid([&]() { return fn.invoke(server_context, ArgList()); },
      |                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/proxy-types.h:563:16: note: Calling 'PassField<mp::Accessor<mp::foo_fields::Context, 17>, mp::ServerInvokeContext<mp::ProxyServer<mp::test::messages::FooFn>, capnp::CallContext<mp::test::messages::FooFn::CallParams, mp::test::messages::FooFn::CallResults>>, mp::ServerRet<mp::Accessor<mp::foo_fields::Result, 2>, mp::ServerCall>, mp::TypeList<>>'
  563 |         return PassField<Accessor>(Priority<2>(),
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  564 |             typename Split<argc, ArgTypes>::First(),
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  565 |             server_context,
      |             ~~~~~~~~~~~~~~~
  566 |             this->parent(),
      |             ~~~~~~~~~~~~~~~
  567 |             typename Split<argc, ArgTypes>::Second(),
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  568 |             std::forward<Args>(args)...);
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/mp/type-context.h:151:12: note: Calling 'CapabilityServerSet::getLocalServer'
  151 |     return server.m_context.connection->m_threads.getLocalServer(thread_client)
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/capnp/capability.h:1274:10: note: Calling 'Promise::then'
 1274 |   return getLocalServerInternal(client)
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 1275 |       .then([](void* server) -> kj::Maybe<typename T::Server&> {
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 1276 |     if (server == nullptr) {
      |     ~~~~~~~~~~~~~~~~~~~~~~~~
 1277 |       return nullptr;
      |       ~~~~~~~~~~~~~~~
 1278 |     } else {
      |     ~~~~~~~~
 1279 |       return *reinterpret_cast<typename T::Server*>(server);
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 1280 |     }
      |     ~
 1281 |   });
      |   ~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/kj/async-inl.h:1295:32: note: Calling 'GetFunctorStartAddress::apply'
 1295 |   void* continuationTracePtr = _::GetFunctorStartAddress<_::FixVoid<T>&&>::apply(func);
      |                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/kj/async-inl.h:677:12: note: Calling 'PtmfHelper::apply'
  677 |     return PtmfHelper::from<ReturnType, Decay<Func>, ParamTypes...>(
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  678 |         &Decay<Func>::operator()).apply(&func);
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/kj/async-inl.h:606:9: note: Assuming the condition is true
  606 |     if (voff & 1) {
      |         ^~~~~~~~
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/kj/async-inl.h:606:5: note: Taking true branch
  606 |     if (voff & 1) {
      |     ^
/nix/store/46kiq9naswgbqfc14kc9nxcbgd0rv0m2-capnproto-1.1.0/include/kj/async-inl.h:609:37: note: The left operand of '+' is a garbage value
  609 |       return *(void**)(*(char**)obj + voff);
      |                        ~~~~~~~~~~~~ ^
@ryanofsky

Copy link
Copy Markdown
Collaborator Author

Not sure why CI does not seem to run as part of this PR, but CI was successful in the branch behind the PR:

Maybe this PR has to be merged first before CI will run on any PRs.

@ryanofsky

Copy link
Copy Markdown
Collaborator Author

I'll submit a patch to cap'n proto to avoid the clang-analyzer-core.UndefinedBinaryOperatorResult error that's disabled in the last commit of this PR 48ecb5f. Commit cb94a43 tests a patch that seems to work.

Ideally we'd never see this error because cap'n proto headers are included with -isystem and we disable warnings from system headers, but clang seems to have quirks which cause this error to be associated with the "main file" of our translation unit and shows this error anyway without a way of filtering it out: https://reviews.llvm.org/D26418

@maflcko

maflcko commented Jun 20, 2025

Copy link
Copy Markdown
Contributor

Maybe this PR has to be merged first before CI will run on any PRs.

maybe the "actions" has to be enabled? At least on https://github.com/bitcoin/bitcoin/actions I see the tab, but https://github.com/bitcoin-core/libmultiprocess/actions is a 404 right now. See https://github.com/bitcoin-core/libmultiprocess/settings/actions

@ryanofsky

Copy link
Copy Markdown
Collaborator Author

See https://github.com/bitcoin-core/libmultiprocess/settings/actions

Thanks! That seems right. I can't change the setting there since I see "This setting has been disabled by organization administrators" but I assume if gets changed from "Disable actions" to one of the other settings this should start to work.

@ryanofsky

ryanofsky commented Jun 20, 2025

Copy link
Copy Markdown
Collaborator Author

re: #184 (comment)

I'll submit a patch to cap'n proto to avoid the clang-analyzer-core.UndefinedBinaryOperatorResult error that's disabled in the last commit of this PR

Opened capnproto/capnproto#2334 with this


Updated 48ecb5f -> 80f1c2e (pr/ci.1 -> pr/ci.2, compare, CI) just updating the last commit message to mention the patch

@fanquake

Copy link
Copy Markdown
Member

Actions should be available in this repository now.

Comment thread .clang-tidy Outdated
Comment thread ci/scripts/build.sh Outdated
@Sjors

Sjors commented Jun 23, 2025

Copy link
Copy Markdown
Member

When I update the subtree to use this in bitcoin/bitcoin#31802 my macOS build fails:

/Users/sjors/dev/bitcoin/src/ipc/capnp/protocol.cpp:45:42: error: no matching constructor for initialization of 'std::unique_lock<std::mutex>'
   45 |             std::unique_lock<std::mutex> lock(m_loop->m_mutex);

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.5.sdk/usr/include/c++/v1/__mutex/unique_lock.h:40:52: note: candidate constructor not viable: no known conversion from 'Mutex' to 'mutex_type &' (aka 'std::mutex &') for 1st argument
   40 |   _LIBCPP_NODISCARD _LIBCPP_HIDE_FROM_ABI explicit unique_lock(mutex_type& __m)

...

Is this expected?


Other than that the code changes in 80f1c2e seem fine, with a combination of pleasing tidy and skipping some checks. I'd like to test it on top of #31802 to make sure we caught all the Pokemons though.

@DrahtBot

DrahtBot commented Jun 23, 2025

Copy link
Copy Markdown

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Reviews

See the guideline for information on the review process.

Type Reviewers
ACK Sjors
Stale ACK hebasto

If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

Conflicts

Reviewers, this pull request conflicts with the following ones:

  • #171 (cmake: Show error instead of invoking cross-compiled mpgen binary by ryanofsky)

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

Also add IWYU to the default job, since using libc++ instead of libstdc++
causes IWYU to give slightly different recommendations. Better to comply with
both sets of recommendations so IWYU is usable on more platforms.
Bitcoin tidy plugin isn't currently enabled here so they don't do anything.

Suggested by maflcko <6399679+maflcko@users.noreply.github.com>
bitcoin-core#184 (comment)
ryanofsky added a commit to ryanofsky/libmultiprocess that referenced this pull request Jun 23, 2025
Bitcoin tidy plugin isn't currently enabled here so they don't do anything.

Suggested by maflcko <6399679+maflcko@users.noreply.github.com>
bitcoin-core#184 (comment)

@ryanofsky ryanofsky left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated 80f1c2e -> f15724a (pr/ci.2 -> pr/ci.3, compare, CI) expanding ci job to cover libc++ and gcc, rewriting a commit message, and making a few other tweaks.


re: #184 (comment)

When I update the subtree to use this in bitcoin/bitcoin#31802 my macOS build fails:

I misread this error and didn't realize it was coming from the bitcoin build not the libmultiprocess build, and assumed it might be caused a libc++ / libstdc++ difference (which is why I added libstdc++ ci job).

But I think this error is just caused by #160 and should be fixed by bitcoin/bitcoin@d234efe from bitcoin/bitcoin#32345


re: #184 (comment)

Actions should be available in this repository now.

Thanks I saw the setting on https://github.com/bitcoin-core/libmultiprocess/settings/actions was changed from "Disable actions" to "Allow bitcoin-core actions and reusable workflows." Though after another push it still seems like PR actions don't run here, but not sure if that is because of settings, or because no actions are defined on the master branch right now.

To experiment I did change "Allow bitcoin-core, and select non-bitcoin-core, actions and reusable workflows" and filled in "Allow specified actions and reusable workflows" list with:

  • actions/checkout@*
  • cachix/install-nix-action@*,

So maybe that will have an effect if there is another push.

Comment thread .clang-tidy Outdated
Comment thread ci/scripts/build.sh Outdated
@ryanofsky

Copy link
Copy Markdown
Collaborator Author

Should probably add documentation about this, but with latest push it should be possible to run the two CI jobs locally on linux if nix is installed with:

CI_CONFIG=ci/configs/gcc-libstdc++.sh ci/run.sh
CI_CONFIG=ci/configs/clang-libc++.sh ci/run.sh

ryanofsky added a commit to ryanofsky/libmultiprocess that referenced this pull request Jun 25, 2025
Suggested by maflcko <6399679+maflcko@users.noreply.github.com>
bitcoin-core#184 (comment)

@ryanofsky ryanofsky left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated aaf1db6 -> 1bfed25 (pr/ci.6 -> pr/ci.7, compare, CI) implementing suggestion use environment variables instead of command line arguments for compiler settings and earlier suggestion to drop -DCMAKE_EXPORT_COMPILE_COMMANDS=ON

Comment thread ci/configs/llvm.sh Outdated

@hebasto hebasto left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 1bfed25.

@ryanofsky

Copy link
Copy Markdown
Collaborator Author

Thanks for the review! I pushed another update since the CI_CLEAN option was not implemented correctly. (It was always wiping the build directory when running locally.) There is also a new commit adding a cross-compiled 32-bit job (in an attempt to reproduce mptest segfaults reported bitcoin/bitcoin#32345 (comment) and Sjors/bitcoin#90 (comment).

I'll try to avoid making more changes here and add new jobs (sanitizers) in future PRs.

Updated 1bfed25 -> 757e13a (pr/ci.7 -> pr/ci.8, compare, CI) with CI_CLEAN fix and new gnu32 CI job.

@Sjors

Sjors commented Jun 26, 2025

Copy link
Copy Markdown
Member

ACK 757e13a

I ran the three ci scripts on Ubuntu.

We'll need to be careful when updating the subtree in bitcoin/bitcoin#32345. But debugging that should be easier with the new CI coverage added in this PR.

@DrahtBot
DrahtBot requested a review from hebasto June 26, 2025 06:55
@ryanofsky
ryanofsky merged commit 8954cc0 into bitcoin-core:master Jun 26, 2025
@maflcko

maflcko commented Jun 26, 2025

Copy link
Copy Markdown
Contributor

for reference the error is:

actions/checkout@v4 and cachix/install-nix-action@v31 are not allowed to be used in bitcoin-core/libmultiprocess. Actions in this workflow must be: within a repository owned by bitcoin-core or matching the following: actions/checkout@*
cachix/install-nix-action@*.

https://github.com/bitcoin-core/libmultiprocess/actions/runs/15907709886

@ryanofsky

Copy link
Copy Markdown
Collaborator Author

Thanks, as mentioned #184 (review) I did try to allow these actions but probably didn't do it right. The current setting looks like:

Screenshot_20250626_175549

@ryanofsky

ryanofsky commented Jun 27, 2025

Copy link
Copy Markdown
Collaborator Author

Problem with github actions seems to be fixed. CI jobs appear at the bottom of a PR I just opened #186. I updated the list of allowed actions in settings to actions/checkout@*,cachix/install-nix-action@* separated by a comma instead of a newline, and that might have helped.

ryanofsky added a commit to ryanofsky/bitcoin that referenced this pull request Jul 1, 2025
725beeadc9ae doc: fix DrahtBot LLM Linter error
7455fc0e3781 type-context: revert client disconnect workaround
47f052c3ed94 proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
f6bd4385c057 mptest: fix MemorySanitizer: use-of-uninitialized-value
8218a1d8760d proxy-io: fix race conditions in disconnect callback code
88695fc05303 proxy-io: fix race conditions in ProxyClientBase cleanup handler
63bd2a201dc2 doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
81d58f5 refactor: Rename ProxyClient cleanup_it variable
07230f2 refactor: rename ProxyClient<Thread>::m_cleanup_it
0d986ff mptest: fix race condition in TestSetup constructor
d2f6aa2 ci: add thread sanitizer job
c0efaa5 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
3a6db38 ci: rename configs to .bash
401e0ce ci: add copyright to bash scripts
e956467 ci: export LC_ALL
8954cc0 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
757e13a ci: add gnu32 cross-compiled 32-bit build
15bf349 doc: fix typo found by DrahtBot
1a598d5 clang-tidy: drop 'bitcoin-*' check
cbb1e43 ci: test libc++ instead of libstdc++ in one job
7631345 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
4896e7f proxy-types: fix clang-tidy EnumCastOutOfRange error
060a739 proxy-types: fix clang-tidy StackAddressEscape error
977d721 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
0d5f1fa iwyu: fix add/remove include errors
753d2b1 util: fix clang-tidy modernize-use-equals-default error
ae4f1dc type-number: fix clang-tidy modernize-use-nullptr error
07a741b proxy-types: fix clang-tidy bugprone-use-after-move error
3673114 proxy-types: fix clang-tidy bugprone-use-after-move error
422923f proxy-types: fix clang-tidy bugprone-use-after-move error
c6784c6 mpgen: disable clang-tidy misc-no-recursion error
c5498aa tidy: copy clang-tidy file from bitcoin core
258a617 Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
84cf56a test: Test disconnects during IPC calls
949573d Prevent IPC server crash if disconnected during IPC call
0198397 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
ea38392 Prevent EventLoop async cleanup thread early exit during shutdown
616d9a7 doc: Document ProxyClientBase destroy_connection option
56fff76 Improve IPC client disconnected exceptions
9b8ed3d refactor: Add clang thread safety annotations to EventLoop
52256e7 refactor: Remove DestructorCatcher and AsyncCallable
f248947 refactor: Drop addClient/removeClient methods
2b830e5 refactor: Use EventLoopRef instead of addClient/removeClient
315ff53 refactor: Add ProxyContext EventLoop* member
9aaeec3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
f58c8d8 proxy-io.h: Add more detailed EventLoop comment
5108445 test: Add test coverage for client & server disconnections
59030c6 Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
688140b test: Add coverage for type-function.h
8b96229 type-function.h: Fix CustomBuildField overload
fa2ff9a scripted-diff: Remove copyright year (ranges)

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: 725beeadc9ae30664aa3ed12a9ac2b77a9d8d4e0
ryanofsky added a commit to ryanofsky/bitcoin that referenced this pull request Jul 1, 2025
6f340a5 doc: fix DrahtBot LLM Linter error
c6f7fdf type-context: revert client disconnect workaround
e09143d proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
84b292f mptest: fix MemorySanitizer: use-of-uninitialized-value
fe4a188 proxy-io: fix race conditions in disconnect callback code
d8011c8 proxy-io: fix race conditions in ProxyClientBase cleanup handler
97e82ce doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
81d58f5 refactor: Rename ProxyClient cleanup_it variable
07230f2 refactor: rename ProxyClient<Thread>::m_cleanup_it
0d986ff mptest: fix race condition in TestSetup constructor
d2f6aa2 ci: add thread sanitizer job
c0efaa5 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
3a6db38 ci: rename configs to .bash
401e0ce ci: add copyright to bash scripts
e956467 ci: export LC_ALL
8954cc0 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
757e13a ci: add gnu32 cross-compiled 32-bit build
15bf349 doc: fix typo found by DrahtBot
1a598d5 clang-tidy: drop 'bitcoin-*' check
cbb1e43 ci: test libc++ instead of libstdc++ in one job
7631345 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
4896e7f proxy-types: fix clang-tidy EnumCastOutOfRange error
060a739 proxy-types: fix clang-tidy StackAddressEscape error
977d721 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
0d5f1fa iwyu: fix add/remove include errors
753d2b1 util: fix clang-tidy modernize-use-equals-default error
ae4f1dc type-number: fix clang-tidy modernize-use-nullptr error
07a741b proxy-types: fix clang-tidy bugprone-use-after-move error
3673114 proxy-types: fix clang-tidy bugprone-use-after-move error
422923f proxy-types: fix clang-tidy bugprone-use-after-move error
c6784c6 mpgen: disable clang-tidy misc-no-recursion error
c5498aa tidy: copy clang-tidy file from bitcoin core
258a617 Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
84cf56a test: Test disconnects during IPC calls
949573d Prevent IPC server crash if disconnected during IPC call
0198397 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
ea38392 Prevent EventLoop async cleanup thread early exit during shutdown
616d9a7 doc: Document ProxyClientBase destroy_connection option
56fff76 Improve IPC client disconnected exceptions
9b8ed3d refactor: Add clang thread safety annotations to EventLoop
52256e7 refactor: Remove DestructorCatcher and AsyncCallable
f248947 refactor: Drop addClient/removeClient methods
2b830e5 refactor: Use EventLoopRef instead of addClient/removeClient
315ff53 refactor: Add ProxyContext EventLoop* member
9aaeec3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
f58c8d8 proxy-io.h: Add more detailed EventLoop comment
5108445 test: Add test coverage for client & server disconnections
59030c6 Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
688140b test: Add coverage for type-function.h
8b96229 type-function.h: Fix CustomBuildField overload
fa2ff9a scripted-diff: Remove copyright year (ranges)

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: 6f340a5
ryanofsky added a commit to ryanofsky/bitcoin that referenced this pull request Jul 1, 2025
a11e690 Merge bitcoin-core/libmultiprocess#186: Fix mptest failures in bitcoin CI
6f340a5 doc: fix DrahtBot LLM Linter error
c6f7fdf type-context: revert client disconnect workaround
e09143d proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
84b292f mptest: fix MemorySanitizer: use-of-uninitialized-value
fe4a188 proxy-io: fix race conditions in disconnect callback code
d8011c8 proxy-io: fix race conditions in ProxyClientBase cleanup handler
97e82ce doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
81d58f5 refactor: Rename ProxyClient cleanup_it variable
07230f2 refactor: rename ProxyClient<Thread>::m_cleanup_it
c0efaa5 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
0d986ff mptest: fix race condition in TestSetup constructor
d2f6aa2 ci: add thread sanitizer job
3a6db38 ci: rename configs to .bash
401e0ce ci: add copyright to bash scripts
e956467 ci: export LC_ALL
8954cc0 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
757e13a ci: add gnu32 cross-compiled 32-bit build
15bf349 doc: fix typo found by DrahtBot
1a598d5 clang-tidy: drop 'bitcoin-*' check
cbb1e43 ci: test libc++ instead of libstdc++ in one job
7631345 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
4896e7f proxy-types: fix clang-tidy EnumCastOutOfRange error
060a739 proxy-types: fix clang-tidy StackAddressEscape error
977d721 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
0d5f1fa iwyu: fix add/remove include errors
753d2b1 util: fix clang-tidy modernize-use-equals-default error
ae4f1dc type-number: fix clang-tidy modernize-use-nullptr error
07a741b proxy-types: fix clang-tidy bugprone-use-after-move error
3673114 proxy-types: fix clang-tidy bugprone-use-after-move error
422923f proxy-types: fix clang-tidy bugprone-use-after-move error
c6784c6 mpgen: disable clang-tidy misc-no-recursion error
c5498aa tidy: copy clang-tidy file from bitcoin core
258a617 Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
84cf56a test: Test disconnects during IPC calls
949573d Prevent IPC server crash if disconnected during IPC call
0198397 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
ea38392 Prevent EventLoop async cleanup thread early exit during shutdown
616d9a7 doc: Document ProxyClientBase destroy_connection option
56fff76 Improve IPC client disconnected exceptions
9b8ed3d refactor: Add clang thread safety annotations to EventLoop
52256e7 refactor: Remove DestructorCatcher and AsyncCallable
f248947 refactor: Drop addClient/removeClient methods
2b830e5 refactor: Use EventLoopRef instead of addClient/removeClient
315ff53 refactor: Add ProxyContext EventLoop* member
9aaeec3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
f58c8d8 proxy-io.h: Add more detailed EventLoop comment
5108445 test: Add test coverage for client & server disconnections
59030c6 Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
688140b test: Add coverage for type-function.h
8b96229 type-function.h: Fix CustomBuildField overload
fa2ff9a scripted-diff: Remove copyright year (ranges)

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: a11e690
ryanofsky added a commit to ryanofsky/bitcoin that referenced this pull request Aug 8, 2025
b4120d3 Merge bitcoin-core/libmultiprocess#192: doc: fix typos
6ecbdcd doc: fix typos
a11e690 Merge bitcoin-core/libmultiprocess#186: Fix mptest failures in bitcoin CI
6f340a5 doc: fix DrahtBot LLM Linter error
c6f7fdf type-context: revert client disconnect workaround
e09143d proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
84b292f mptest: fix MemorySanitizer: use-of-uninitialized-value
fe4a188 proxy-io: fix race conditions in disconnect callback code
d8011c8 proxy-io: fix race conditions in ProxyClientBase cleanup handler
97e82ce doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
81d58f5 refactor: Rename ProxyClient cleanup_it variable
07230f2 refactor: rename ProxyClient<Thread>::m_cleanup_it
c0efaa5 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
0d986ff mptest: fix race condition in TestSetup constructor
d2f6aa2 ci: add thread sanitizer job
3a6db38 ci: rename configs to .bash
401e0ce ci: add copyright to bash scripts
e956467 ci: export LC_ALL
8954cc0 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
757e13a ci: add gnu32 cross-compiled 32-bit build
15bf349 doc: fix typo found by DrahtBot
1a598d5 clang-tidy: drop 'bitcoin-*' check
cbb1e43 ci: test libc++ instead of libstdc++ in one job
7631345 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
4896e7f proxy-types: fix clang-tidy EnumCastOutOfRange error
060a739 proxy-types: fix clang-tidy StackAddressEscape error
977d721 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
0d5f1fa iwyu: fix add/remove include errors
753d2b1 util: fix clang-tidy modernize-use-equals-default error
ae4f1dc type-number: fix clang-tidy modernize-use-nullptr error
07a741b proxy-types: fix clang-tidy bugprone-use-after-move error
3673114 proxy-types: fix clang-tidy bugprone-use-after-move error
422923f proxy-types: fix clang-tidy bugprone-use-after-move error
c6784c6 mpgen: disable clang-tidy misc-no-recursion error
c5498aa tidy: copy clang-tidy file from bitcoin core
258a617 Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
84cf56a test: Test disconnects during IPC calls
949573d Prevent IPC server crash if disconnected during IPC call
0198397 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
ea38392 Prevent EventLoop async cleanup thread early exit during shutdown
616d9a7 doc: Document ProxyClientBase destroy_connection option
56fff76 Improve IPC client disconnected exceptions
9b8ed3d refactor: Add clang thread safety annotations to EventLoop
52256e7 refactor: Remove DestructorCatcher and AsyncCallable
f248947 refactor: Drop addClient/removeClient methods
2b830e5 refactor: Use EventLoopRef instead of addClient/removeClient
315ff53 refactor: Add ProxyContext EventLoop* member
9aaeec3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
f58c8d8 proxy-io.h: Add more detailed EventLoop comment
5108445 test: Add test coverage for client & server disconnections
59030c6 Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
688140b test: Add coverage for type-function.h
8b96229 type-function.h: Fix CustomBuildField overload
fa2ff9a scripted-diff: Remove copyright year (ranges)

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: b4120d3
Sjors added a commit to Sjors/bitcoin that referenced this pull request Aug 12, 2025
c090cc8619 build: require CapnProto 1.0.1 or better
b4120d3 Merge bitcoin-core/libmultiprocess#192: doc: fix typos
6ecbdcd doc: fix typos
a11e690 Merge bitcoin-core/libmultiprocess#186: Fix mptest failures in bitcoin CI
6f340a5 doc: fix DrahtBot LLM Linter error
c6f7fdf type-context: revert client disconnect workaround
e09143d proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
84b292f mptest: fix MemorySanitizer: use-of-uninitialized-value
fe4a188 proxy-io: fix race conditions in disconnect callback code
d8011c8 proxy-io: fix race conditions in ProxyClientBase cleanup handler
97e82ce doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
81d58f5 refactor: Rename ProxyClient cleanup_it variable
07230f2 refactor: rename ProxyClient<Thread>::m_cleanup_it
c0efaa5 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
0d986ff mptest: fix race condition in TestSetup constructor
d2f6aa2 ci: add thread sanitizer job
3a6db38 ci: rename configs to .bash
401e0ce ci: add copyright to bash scripts
e956467 ci: export LC_ALL
8954cc0 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
757e13a ci: add gnu32 cross-compiled 32-bit build
15bf349 doc: fix typo found by DrahtBot
1a598d5 clang-tidy: drop 'bitcoin-*' check
cbb1e43 ci: test libc++ instead of libstdc++ in one job
7631345 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
4896e7f proxy-types: fix clang-tidy EnumCastOutOfRange error
060a739 proxy-types: fix clang-tidy StackAddressEscape error
977d721 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
0d5f1fa iwyu: fix add/remove include errors
753d2b1 util: fix clang-tidy modernize-use-equals-default error
ae4f1dc type-number: fix clang-tidy modernize-use-nullptr error
07a741b proxy-types: fix clang-tidy bugprone-use-after-move error
3673114 proxy-types: fix clang-tidy bugprone-use-after-move error
422923f proxy-types: fix clang-tidy bugprone-use-after-move error
c6784c6 mpgen: disable clang-tidy misc-no-recursion error
c5498aa tidy: copy clang-tidy file from bitcoin core
258a617 Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
84cf56a test: Test disconnects during IPC calls
949573d Prevent IPC server crash if disconnected during IPC call
0198397 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
ea38392 Prevent EventLoop async cleanup thread early exit during shutdown
616d9a7 doc: Document ProxyClientBase destroy_connection option
56fff76 Improve IPC client disconnected exceptions
9b8ed3d refactor: Add clang thread safety annotations to EventLoop
52256e7 refactor: Remove DestructorCatcher and AsyncCallable
f248947 refactor: Drop addClient/removeClient methods
2b830e5 refactor: Use EventLoopRef instead of addClient/removeClient
315ff53 refactor: Add ProxyContext EventLoop* member
9aaeec3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
f58c8d8 proxy-io.h: Add more detailed EventLoop comment
5108445 test: Add test coverage for client & server disconnections
59030c6 Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
688140b test: Add coverage for type-function.h
8b96229 type-function.h: Fix CustomBuildField overload
fa2ff9a scripted-diff: Remove copyright year (ranges)

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: c090cc8619d6c003b86cbf63c1d43e64ff167d78
fanquake added a commit to bitcoin/bitcoin that referenced this pull request Aug 18, 2025
2581258 ipc: Handle bitcoin-wallet disconnections (Ryan Ofsky)
2160995 ipc: Add Ctrl-C handler for spawned subprocesses (Ryan Ofsky)
0c28068 doc: Improve IPC interface comments (Ryan Ofsky)
7f65aac ipc: Avoid waiting for clients to disconnect when shutting down (Ryan Ofsky)
6eb09fd test: Add unit test coverage for Init and Shutdown code (Ryan Ofsky)
9a9fb19 ipc: Use EventLoopRef instead of addClient/removeClient (Ryan Ofsky)
e886c65 Squashed 'src/ipc/libmultiprocess/' changes from 27c7e8e..b4120d3 (Ryan Ofsky)

Pull request description:

  This PR fixes various problems when IPC connections are broken or hang which were reported in bitcoin-core/libmultiprocess#123, bitcoin-core/libmultiprocess#176, and bitcoin-core/libmultiprocess#182. The different fixes are described in commit messages.

  ---

  The first two commits of this PR update the libmultiprocess subtree including the following PRs:

  - bitcoin-core/libmultiprocess#181
  - bitcoin-core/libmultiprocess#179
  - bitcoin-core/libmultiprocess#160
  - bitcoin-core/libmultiprocess#184
  - bitcoin-core/libmultiprocess#187
  - bitcoin-core/libmultiprocess#186
  - bitcoin-core/libmultiprocess#192

  The subtree changes can be verified by running `test/lint/git-subtree-check.sh src/ipc/libmultiprocess` as described in [developer notes](https://github.com/bitcoin/bitcoin/blob/master/doc/developer-notes.md#subtrees) and [lint instructions](https://github.com/bitcoin/bitcoin/tree/master/test/lint#git-subtree-checksh).

  The remaining commits are:

  - [`9a9fb19536fa` ipc: Use EventLoopRef instead of addClient/removeClient](9a9fb19)
  - [`6eb09fd6141f` test: Add unit test coverage for Init and Shutdown code](6eb09fd)
  - [`7f65aac78b95` ipc: Avoid waiting for clients to disconnect when shutting down](7f65aac)
  - [`0c28068ceb7b` doc: Improve IPC interface comments](0c28068)
  - [`216099591632` ipc: Add Ctrl-C handler for spawned subprocesses](2160995)
  - [`2581258ec200` ipc: Handle bitcoin-wallet disconnections](2581258)

  The new commits depend on the subtree update, and because the subtree update includes an incompatible API change, the "Use EventLoopRef" commit needs to be part of the same PR to avoid breaking the build. The other commits also make sense to merge at the same time because the bitcoin & libmultiprocess changes were written and tested together.

  ---

  This PR is part of the [process separation project](#28722).

ACKs for top commit:
  Sjors:
    re-utACK 2581258
  josibake:
    code review ACK 2581258
  pinheadmz:
    re-ACK 2581258

Tree-SHA512: 0095aa22d507803e2a2d46eff51fb6caf965cc0c97ccfa615bd97805d5d51e66a5b4b040640deb92896438b1fb9f6879847124c9d0e120283287bfce37b8d748
@maflcko maflcko mentioned this pull request Aug 20, 2025
@ryanofsky ryanofsky mentioned this pull request Aug 23, 2025
4 tasks
janus pushed a commit to BitgesellOfficial/bitgesell that referenced this pull request Sep 15, 2025
…34bad2

b4120d34bad2 Merge bitcoin-core/libmultiprocess#192: doc: fix typos
6ecbdcd35a93 doc: fix typos
a11e6905c238 Merge bitcoin-core/libmultiprocess#186: Fix mptest failures in bitcoin CI
6f340a583f2b doc: fix DrahtBot LLM Linter error
c6f7fdf17350 type-context: revert client disconnect workaround
e09143d2ea2f proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
84b292fcc4db mptest: fix MemorySanitizer: use-of-uninitialized-value
fe4a188803c6 proxy-io: fix race conditions in disconnect callback code
d8011c83608e proxy-io: fix race conditions in ProxyClientBase cleanup handler
97e82ce19c47 doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
81d58f5580e8 refactor: Rename ProxyClient cleanup_it variable
07230f259f55 refactor: rename ProxyClient<Thread>::m_cleanup_it
c0efaa5e8cb1 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
0d986ff144cd mptest: fix race condition in TestSetup constructor
d2f6aa2e84ef ci: add thread sanitizer job
3a6db38e561f ci: rename configs to .bash
401e0ce1d9c3 ci: add copyright to bash scripts
e956467ae464 ci: export LC_ALL
8954cc0377d8 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
757e13a75546 ci: add gnu32 cross-compiled 32-bit build
15bf349000eb doc: fix typo found by DrahtBot
1a598d5905f7 clang-tidy: drop 'bitcoin-*' check
cbb1e43fdc6e ci: test libc++ instead of libstdc++ in one job
76313450c2c4 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
4896e7fe51ba proxy-types: fix clang-tidy EnumCastOutOfRange error
060a73926956 proxy-types: fix clang-tidy StackAddressEscape error
977d721020f6 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
0d5f1faae5da iwyu: fix add/remove include errors
753d2b10cc27 util: fix clang-tidy modernize-use-equals-default error
ae4f1dc2bb1a type-number: fix clang-tidy modernize-use-nullptr error
07a741bf6946 proxy-types: fix clang-tidy bugprone-use-after-move error
3673114bc9d9 proxy-types: fix clang-tidy bugprone-use-after-move error
422923f38485 proxy-types: fix clang-tidy bugprone-use-after-move error
c6784c6adefa mpgen: disable clang-tidy misc-no-recursion error
c5498aa11ba6 tidy: copy clang-tidy file from bitcoin core
258a617c1eec Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
84cf56a0b5f4 test: Test disconnects during IPC calls
949573da8411 Prevent IPC server crash if disconnected during IPC call
019839758085 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
ea38392960e1 Prevent EventLoop async cleanup thread early exit during shutdown
616d9a75d20a doc: Document ProxyClientBase destroy_connection option
56fff76f940b Improve IPC client disconnected exceptions
9b8ed3dc5f87 refactor: Add clang thread safety annotations to EventLoop
52256e730f51 refactor: Remove DestructorCatcher and AsyncCallable
f24894794adf refactor: Drop addClient/removeClient methods
2b830e558e61 refactor: Use EventLoopRef instead of addClient/removeClient
315ff537fb65 refactor: Add ProxyContext EventLoop* member
9aaeec3678d3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
f58c8d8ba2f0 proxy-io.h: Add more detailed EventLoop comment
5108445e5d16 test: Add test coverage for client & server disconnections
59030c68cb5f Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
688140b1dffc test: Add coverage for type-function.h
8b96229da58e type-function.h: Fix CustomBuildField overload
fa2ff9a66842 scripted-diff: Remove copyright year (ranges)

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: b4120d34bad2de28141c5770f6e8df8e54898987
Sjors added a commit to Sjors/bitcoin that referenced this pull request May 12, 2026
27ada40809 build: move library sources under lib/ for subtree split
REVERT: 3c69d12 Merge bitcoin-core/libmultiprocess#260: event loop: tolerate unexpected exceptions in `post()` callbacks
REVERT: b8a48c6 event loop: tolerate unexpected exceptions in `post()` callbacks
REVERT: f787863 Merge bitcoin-core/libmultiprocess#270: doc: Bump version 10 > 11
REVERT: a22f602 doc: Bump version 10 > 11
REVERT: 3edbe8f Merge bitcoin-core/libmultiprocess#268: Use throwRecoverableException instead of raw throw for stored exceptions
REVERT: 23be44b Use throwRecoverableException instead of raw throw for stored exceptions
REVERT: 75c2a27 Merge bitcoin-core/libmultiprocess#266: test: increase spawn test child timeout to 30 seconds
REVERT: 8b5f805 Merge bitcoin-core/libmultiprocess#267: doc: Bump version 9 > 10
REVERT: cc0b23f test: increase spawn test child timeout to 30 seconds
REVERT: 050f878 doc: Improve versions.md descriptions and formatting
REVERT: c6a288a doc: Bump version 9 > 10
REVERT: 70f632b Merge bitcoin-core/libmultiprocess#265: ci: set LC_ALL in shell scripts
REVERT: 8e8e564 Merge bitcoin-core/libmultiprocess#249: fixes for race conditions on disconnects
REVERT: 05d34cc ci: set LC_ALL in shell scripts
REVERT: e606fd8 Merge bitcoin-core/libmultiprocess#264: ci: reduce nproc multipliers
REVERT: ff0eed1 refactor: Use loop variable in type-context.h
REVERT: ff1d8ba refactor: Move type-context.h getParams() call closer to use
REVERT: 1dbc59a race fix: m_on_cancel called after request finishes
REVERT: 1643d05 test: m_on_cancel called after request finishes
REVERT: f5509a3 race fix: getParams() called after request cancel
REVERT: 4a60c39 test: getParams() called after request cancel
REVERT: f11ec29 race fix: worker thread destroyed before it is initialized
REVERT: a1d6433 test: worker thread destroyed before it is initialized
REVERT: 3360233 ci: reduce nproc multipliers
REVERT: b090beb Merge bitcoin-core/libmultiprocess#256: ci: cache gnu32 nix store
REVERT: be86228 ci: cache gnu32 nix store
REVERT: 975270b Merge bitcoin-core/libmultiprocess#263: ci: bump timeout factor to 40
REVERT: 09f10e5 ci: bump timeout factor to 40
REVERT: db8f76a Merge bitcoin-core/libmultiprocess#253: ci: run some Bitcoin Core CI jobs
REVERT: 55a9b55 ci: set Bitcoin Core CI test repetition
REVERT: fb0fc84 ci: add TSan job with instrumented libc++
REVERT: 0f29c38 ci: add Bitcoin Core IPC tests (ASan + macOS)
REVERT: 3f64320 Merge bitcoin-core/libmultiprocess#262: ci: enable clang-tidy in macOS job, use nullptr
REVERT: cd9f8bd Merge bitcoin-core/libmultiprocess#258: log: add socket connected info message and demote destroy logs to debug
REVERT: b5d6258 Merge bitcoin-core/libmultiprocess#255: fix: use unsigned char cast and sizeof in LogEscape escape sequence
REVERT: d94688e Merge bitcoin-core/libmultiprocess#251: Improved CustomBuildField for std::optional in IPC/libmultiprocess
REVERT: a9499fa mp: use nullptr with pthread_threadid_np
REVERT: f499e37 ci: enable clang-tidy in macOS job
REVERT: 98f1352 log: add socket connected info message and demote destroy logs to debug
REVERT: 554a481 fix: use unsigned char cast and sizeof in LogEscape escape sequence
REVERT: 1977b9f Use std::forward in CustomBuildField for std::optional to allow move semantics, resolves FIXME
REVERT: 22bec91 Merge bitcoin-core/libmultiprocess#247: type-map: Work around LLVM 22 "out of bounds index" error
REVERT: 8a5e3ae Merge bitcoin-core/libmultiprocess#242: proxy-types: add CustomHasField hook to map Cap'n Proto values to null C++ values
REVERT: e8d3524 Merge bitcoin-core/libmultiprocess#246: doc: Bump version 8 > 9
REVERT: 97d8770 proxy-types: add CustomHasField hook for nullable decode paths
REVERT: 8c2f102 refactor: add missing includes to mp/type-data.h
REVERT: b1638ac doc: Bump version 8 > 9
REVERT: f61af48 type-map: Work around LLVM 22 "out of bounds index" error
REVERT: 1868a84 Merge bitcoin-core/libmultiprocess#245: type-context.h: Extent cancel_mutex lock to prevent theoretical race
REVERT: fd4a90d Merge bitcoin-core/libmultiprocess#244: ci: suppress two tidy lint issues
REVERT: 16dfc36 ci: avoid bugprone-unused-return-value lint in test
REVERT: dacd5ed ci: suppress nontrivial-threadlocal lint in proxy.cpp
REVERT: ef96a5b doc: Comment cleanups after bitcoin#240
REVERT: e0f1cd7 type-context.h: Extent cancel_mutex lock to prevent theoretical race
REVERT: 290702c Merge bitcoin-core/libmultiprocess#240: Avoid errors from asynchronous (non-c++) clients
REVERT: 3a69d47 Merge bitcoin-core/libmultiprocess#241: doc: Bump version number v7 -> v8
REVERT: 0174450 Prevent crash on unclean disconnect if abandoned IPC call returns interface pointer
REVERT: ddb5f74 Allow simultaneous calls on same Context.thread
REVERT: c4762c7 refactor: Add ProxyServer<Thread>::post() method
REVERT: 0ade1b4 doc: Bump version number
REVERT: 1fc6500 Merge bitcoin-core/libmultiprocess#237: Made SpawnProcess() behavior safe post fork()
REVERT: 5205a87 test: check SpawnProcess post-fork safety
REVERT: 69652f0 Precompute argv before fork in SpawnProcess
REVERT: 30a8681 SpawnProcess: avoid fd leak on close failure
REVERT: d0fc108 Merge bitcoin-core/libmultiprocess#196: ci: Add NetBSD job
REVERT: 7b171f4 Merge bitcoin-core/libmultiprocess#234: doc: Fix typos and grammar in documentation and comments
REVERT: 861da39 ci: Add NetBSD job
REVERT: 458745e Fix various typos, spelling mistakes, and grammatical errors in design.md and source code comments.
REVERT: 585decc Merge bitcoin-core/libmultiprocess#236: ci: Install binary package `capnproto` on OpenBSD instead of building it
REVERT: 14e926a refactor: extract MakeArgv helper
REVERT: 1ee9093 ci: Install binary package `capnproto` on OpenBSD instead of building it
REVERT: 470fc51 Merge bitcoin-core/libmultiprocess#230: cmake: add ONLY_CAPNP target_capnp_sources option
REVERT: 2d8886f Merge bitcoin-core/libmultiprocess#228: Add versions.md and version.h files describing version branches and tags
REVERT: c1838be Merge bitcoin-core/libmultiprocess#225: Improve and document act support
REVERT: a173f17 Merge bitcoin-core/libmultiprocess#223: ci: Replace nix-shell with equivalent nix develop command
REVERT: 625eaca Merge bitcoin-core/libmultiprocess#229: Design Documentation Update
REVERT: cc234be Design doc update
REVERT: 81c6526 cmake: add ONLY_CAPNP target_capnp_sources option
REVERT: 6e01d2d Add versions.md and version.h files describing version branches and tags
REVERT: a4f9296 Merge bitcoin-core/libmultiprocess#224: doc: fix typos
REVERT: f4344ae Merge bitcoin-core/libmultiprocess#222: test, ci: Fix threadsanitizer errors in mptest
REVERT: 4e3f8fa doc: add instructions for using act
REVERT: 81712ff ci: disable KVM and sandbox inside act containers
REVERT: 1434642 doc: fix typos
REVERT: 73d22ba test: Fix tsan race in thread busy test
REVERT: b74e1bb ci: Use tsan-instrumented cap'n proto in sanitizers job
REVERT: c332774 test: Fix failing exception check in new thread busy test
REVERT: ca3c05d test: Use KJ_LOG instead of std::cout for logging
REVERT: 7eb1da1 ci: Use tsan-instrumented libcxx in sanitizers job
REVERT: 18a2237 ci: Replace nix-shell with equivalent nix develop command
REVERT: ec86e43 Merge bitcoin-core/libmultiprocess#220: Add log levels and advertise them to users via logging callback
REVERT: 515ce93 Logging: Pass LogData struct to logging callback
REVERT: 213574c Logging: reclassify remaining log messages
REVERT: e4de041 Logging: Break out expensive log messages and classify them as Trace
REVERT: 408874a Logging: Use new logging macros
REVERT: 67b092d Logging: Disable logging if messsage level is less than the requested level
REVERT: d0a1ba7 Logging: add log levels to mirror Core's
REVERT: 463a829 Logging: Disable moving or copying Logger
REVERT: 83a2e10 Logging: Add an EventLoop constructor to allow for user-specified log options
REVERT: 58cf47a Merge bitcoin-core/libmultiprocess#221: test default PassField impl handles output parameters
REVERT: db03a66 Merge bitcoin-core/libmultiprocess#214: Fix crash on simultaneous IPC calls using the same thread
REVERT: afcc40b Merge bitcoin-core/libmultiprocess#213: util+doc: Clearer errors when attempting to run examples + polished docs
REVERT: 6db6696 test In|Out parameter
REVERT: 29cf2ad test default PassField impl handles output parameters
REVERT: 1238170 test: simultaneous IPC calls using same thread
REVERT: eb069ab Fix crash on simultaneous IPC calls using the same thread
REVERT: ec03a96 doc: Precision and typos
REVERT: 2b43481 doc: Where possible, remove links to ryanofsky/bitcoin/
REVERT: 286fe46 util: Add helpful error message when failing to execute file
REVERT: 47d79db Merge bitcoin-core/libmultiprocess#201: bug: fix mptest hang, ProxyClient<Thread> deadlock in disconnect handler
REVERT: f15ae9c Merge bitcoin-core/libmultiprocess#211: Add .gitignore
REVERT: 4a269b2 bug: fix ProxyClient<Thread> deadlock if disconnected as IPC call is returning
REVERT: 85df964 Use try_emplace in SetThread instead of threads.find
REVERT: ca9b380 Use std::optional in ConnThreads to allow shortening locks
REVERT: 9b07991 doc: describe ThreadContext struct and synchronization requirements
REVERT: d60db60 proxy-io.h: add Waiter::m_mutex thread safety annotations
REVERT: 4e365b0 ci: Use -Wthread-safety not -Wthread-safety-analysis
REVERT: 15d7baf Add .gitignore
REVERT: fe1cd8c Merge bitcoin-core/libmultiprocess#208: ci: Test minimum cmake version in olddeps job
REVERT: b713a0b Merge bitcoin-core/libmultiprocess#207: ci: output CMake version in CI script
REVERT: 0f58039 ci: Test minimum cmake version in olddeps job
REVERT: d603dcc ci: output CMake version in CI script
REVERT: 13424cf Merge bitcoin-core/libmultiprocess#205: cmake: check for Cap'n Proto / Clang / C++20 incompatibility
REVERT: 72dce11 Merge bitcoin-core/libmultiprocess#200: event loop: add LogOptions struct and reduce the log size
REVERT: 8500340 eventloop: add `LogOptions` struct
REVERT: 657d806 cmake: capnproto pkg missing helpful error
REVERT: d314057 cmake: check for Cap'n Proto / Clang / C++20 incompatibility
REVERT: 878e84d Merge bitcoin-core/libmultiprocess#203: cmake: search capnproto in package mode only
REVERT: 1a85da5 Merge bitcoin-core/libmultiprocess#202: doc: correct the build instructions for the example
REVERT: df01873 Merge bitcoin-core/libmultiprocess#197: ci: Add freebsd and macos build
REVERT: 3bee07a cmake: search capnproto in package mode only
REVERT: b6d3dc4 doc: correct the build instructions for example
REVERT: fa1ac30 ci: Add macos and freebsd task
REVERT: 1b8d4a6 Merge bitcoin-core/libmultiprocess#194: mpgen: Work around c++20 / capnproto 0.8 incompatibility
REVERT: f1fad39 Merge bitcoin-core/libmultiprocess#195: ci: Add openbsd
REVERT: eed42f2 ci: Bump all tasks to actions/checkout@v5
REVERT: 486a510 ci: Remove ancient and problematic -lstdc++fs in mpexample
REVERT: dd40897 Add missing thread include
REVERT: 98414e7 ci: Add openbsd
REVERT: dc3ba22 cmake, doc: Add check for CVE-2022-46149
REVERT: cb170d4 Merge bitcoin-core/libmultiprocess#193: build: require CapnProto 0.7.0 or better
REVERT: 8ceeaa6 ci: Add olddeps job to test old dependencies versions
REVERT: c4cb758 mpgen: Work around c++20 / capnproto 0.8 incompatibility
REVERT: 30930df build: require CapnProto 0.7.0 or better
REVERT: b4120d3 Merge bitcoin-core/libmultiprocess#192: doc: fix typos
REVERT: 6ecbdcd doc: fix typos
REVERT: a11e690 Merge bitcoin-core/libmultiprocess#186: Fix mptest failures in bitcoin CI
REVERT: 6f340a5 doc: fix DrahtBot LLM Linter error
REVERT: c6f7fdf type-context: revert client disconnect workaround
REVERT: e09143d proxy-types: fix UndefinedBehaviorSanitizer: null-pointer-use
REVERT: 84b292f mptest: fix MemorySanitizer: use-of-uninitialized-value
REVERT: fe4a188 proxy-io: fix race conditions in disconnect callback code
REVERT: d8011c8 proxy-io: fix race conditions in ProxyClientBase cleanup handler
REVERT: 97e82ce doc: Add note about Waiter::m_mutex and interaction with the EventLoop::m_mutex
REVERT: 81d58f5 refactor: Rename ProxyClient cleanup_it variable
REVERT: 07230f2 refactor: rename ProxyClient<Thread>::m_cleanup_it
REVERT: c0efaa5 Merge bitcoin-core/libmultiprocess#187: ci: have bash scripts explicitly opt out of locale dependence.
REVERT: 0d986ff mptest: fix race condition in TestSetup constructor
REVERT: d2f6aa2 ci: add thread sanitizer job
REVERT: 3a6db38 ci: rename configs to .bash
REVERT: 401e0ce ci: add copyright to bash scripts
REVERT: e956467 ci: export LC_ALL
REVERT: 8954cc0 Merge bitcoin-core/libmultiprocess#184: Add CI jobs and fix clang-tidy and iwyu errors
REVERT: 757e13a ci: add gnu32 cross-compiled 32-bit build
REVERT: 15bf349 doc: fix typo found by DrahtBot
REVERT: 1a598d5 clang-tidy: drop 'bitcoin-*' check
REVERT: cbb1e43 ci: test libc++ instead of libstdc++ in one job
REVERT: 7631345 type-context: disable clang-tidy UndefinedBinaryOperatorResult error
REVERT: 4896e7f proxy-types: fix clang-tidy EnumCastOutOfRange error
REVERT: 060a739 proxy-types: fix clang-tidy StackAddressEscape error
REVERT: 977d721 ci: add github actions jobs testing gcc, clang-20, clang-tidy, and iwyu
REVERT: 0d5f1fa iwyu: fix add/remove include errors
REVERT: 753d2b1 util: fix clang-tidy modernize-use-equals-default error
REVERT: ae4f1dc type-number: fix clang-tidy modernize-use-nullptr error
REVERT: 07a741b proxy-types: fix clang-tidy bugprone-use-after-move error
REVERT: 3673114 proxy-types: fix clang-tidy bugprone-use-after-move error
REVERT: 422923f proxy-types: fix clang-tidy bugprone-use-after-move error
REVERT: c6784c6 mpgen: disable clang-tidy misc-no-recursion error
REVERT: c5498aa tidy: copy clang-tidy file from bitcoin core
REVERT: 258a617 Merge bitcoin-core/libmultiprocess#160: refactor: EventLoop locking cleanups + client disconnect exception
REVERT: 84cf56a test: Test disconnects during IPC calls
REVERT: 949573d Prevent IPC server crash if disconnected during IPC call
REVERT: 0198397 Merge bitcoin-core/libmultiprocess#179: scripted-diff: Remove copyright year (ranges)
REVERT: ea38392 Prevent EventLoop async cleanup thread early exit during shutdown
REVERT: 616d9a7 doc: Document ProxyClientBase destroy_connection option
REVERT: 56fff76 Improve IPC client disconnected exceptions
REVERT: 9b8ed3d refactor: Add clang thread safety annotations to EventLoop
REVERT: 52256e7 refactor: Remove DestructorCatcher and AsyncCallable
REVERT: f248947 refactor: Drop addClient/removeClient methods
REVERT: 2b830e5 refactor: Use EventLoopRef instead of addClient/removeClient
REVERT: 315ff53 refactor: Add ProxyContext EventLoop* member
REVERT: 9aaeec3 proxy-io.h: Add EventLoopRef RAII class handle addClient/removeClient refcounting
REVERT: f58c8d8 proxy-io.h: Add more detailed EventLoop comment
REVERT: 5108445 test: Add test coverage for client & server disconnections
REVERT: 59030c6 Merge bitcoin-core/libmultiprocess#181: type-function.h: Fix CustomBuildField overload
REVERT: 688140b test: Add coverage for type-function.h
REVERT: 8b96229 type-function.h: Fix CustomBuildField overload
REVERT: fa2ff9a scripted-diff: Remove copyright year (ranges)
REVERT: 27c7e8e Merge bitcoin-core/libmultiprocess#172: refactor: fix warnings from clang-tidy-20 and bitcoin-tidy
REVERT: 2fe87d0 Merge bitcoin-core/libmultiprocess#173: doc: Fix error string typo
REVERT: 57a65b8 clang-tidy: Suppress bitcoin-nontrivial-threadlocal error
REVERT: 0d8012f Merge bitcoin-core/libmultiprocess#165: clang-tidy: fix warnings introduced in version 19
REVERT: 3a96cdc clang-tidy: Fix bugprone-move-forwarding-reference error
REVERT: c1e8c1a clang-tidy: Fix bugprone-move-forwarding-reference errors
REVERT: aa19285 use ranges transform
REVERT: a78137c make member function const
REVERT: ca3226e replace custom tuple unpacking code with `std::apply`
REVERT: 949fe85 replace SFINAE trick with `if constexpr`
REVERT: 44ee4b4 doc: Fix error string typo
REVERT: 35944ff Merge bitcoin-core/libmultiprocess#168: Switch `MP_INCLUDE_DIR` to global property
REVERT: a77c8e1 Switch `MP_INCLUDE_DIR` to global property
REVERT: f35df6b Merge bitcoin-core/libmultiprocess#166: doc: rename from chaincodelabs to bitcoin-core
REVERT: 2e11997 doc: rename from chaincodelabs to bitcoin-core
REVERT: 1954f7f Merge bitcoin-core/libmultiprocess#164: Bump minimum required cmake to 3.12
REVERT: 729ff16 Bump minimum required cmake to 3.12
REVERT: 011fc53 Merge bitcoin-core/libmultiprocess#161: cmake: Avoid including CTest if not top level project
REVERT: 26b9f3d Merge bitcoin-core/libmultiprocess#159: bugfix: Do not lock EventLoop::mutex after EventLoop is done
REVERT: a7f0669 cmake: Avoid including CTest if not top level project
REVERT: 48d01bc bugfix: Do not lock EventLoop::mutex after EventLoop is done
REVERT: 4089907 Merge bitcoin-core/libmultiprocess#157: refactor: Avoid using std::format
REVERT: eca8fd3 refactor: Avoid using std::format
REVERT: 9ba88dc Merge bitcoin-core/libmultiprocess#156: refactor: Remove locale-dependent function calls
REVERT: 9119300 Merge bitcoin-core/libmultiprocess#155: scripted-diff: s/Libmultiprocess_EXTERNAL_MPGEN/MPGEN_EXECUTABLE/g
REVERT: c8351c5 refactor: Remove locale-dependent function calls
REVERT: 250c2ea scripted-diff: s/Libmultiprocess_EXTERNAL_MPGEN/MPGEN_EXECUTABLE/g
REVERT: 9558ceb Merge bitcoin-core/libmultiprocess#152: refactor: Fix compiler and clang-tidy warnings
REVERT: c6a61d8 Merge bitcoin-core/libmultiprocess#149: Avoid `-Wundef` compiler warnings
REVERT: 0b8b7f9 refactor: Fix `-Wsign-compare` compiler warning
REVERT: a02c079 clang-tidy: Suppress `performance-enum-size` check warning
REVERT: 593807a clang-tidy: Fix `readability-container-size-empty` check
REVERT: 68c1c6c clang-tidy: Fix `readability-avoid-return-with-void-value` check
REVERT: 4abaa98 clang-tidy: Fix `readability-avoid-nested-conditional-operator` check
REVERT: 01ef094 clang-tidy: Fix `performance-unnecessary-value-param` check
REVERT: c665a43 clang-tidy: Fix `misc-use-internal-linkage` check
REVERT: 15c77e9 clang-tidy: Fix `misc-include-cleaner` check
REVERT: 848c902 clang-tidy: Fix `misc-const-correctness` check
REVERT: 4a2508c clang-tidy: Fix `modernize-type-traits` check
REVERT: 8170d3d clang-tidy: Suppress `bugprone-empty-catch` check warning
REVERT: c068596 clang-tidy: Fix `bugprone-crtp-constructor-accessibility` check
REVERT: 00036c0 clang-tidy: Disable `performance-avoid-endl` check
REVERT: 359a615 clang-tidy: Disable `misc-use-anonymous-namespace` check
REVERT: c978878 Merge bitcoin-core/libmultiprocess#145: CTest: Module must be included at the top level
REVERT: 63ac092 CTest: Module must be included at the top level
REVERT: d450fbf Avoid `-Wundef` compiler warnings
REVERT: 477405e Merge bitcoin-core/libmultiprocess#148: util: fix -Wpessimizing-move warning
REVERT: 3bce9d0 util: fix -Wpessimizing-move warning
REVERT: f09c501 Merge bitcoin-core/libmultiprocess#147: cmake: EXTERNAL_MPGEN cleanups
REVERT: 3d83c7a Merge bitcoin-core/libmultiprocess#146: cmake: Suppress compiler warnings from capnproto headers
REVERT: 21b92b6 cmake: EXTERNAL_MPGEN cleanups
REVERT: 2fdd920 Merge bitcoin-core/libmultiprocess#143: cleanup: initialize vars in the EventLoop constructor in the correct order
REVERT: 0c2ac4d Merge bitcoin-core/libmultiprocess#142: build: add option for external mpgen binary
REVERT: f52d08c cleanup: initialize vars in the EventLoop constructor in the correct order
REVERT: 75cf04a build: add option for external mpgen binary
REVERT: 72326b5 cmake: Simplify capnp include handling
REVERT: 1e06ff0 Merge bitcoin-core/libmultiprocess#140: build: don't clobber user/superproject c++ version
REVERT: 65c7048 cmake: Suppress compiler warnings from capnproto headers
REVERT: df21535 build: don't clobber user/superproject c++ version
REVERT: 07c917f Merge bitcoin-core/libmultiprocess#137: doc: Fix broken markdown links
REVERT: e15816a doc: Fix broken markdown links
REVERT: e89b2c6 Merge bitcoin-core/libmultiprocess#136: cmake: Support being included with add_subdirectory
REVERT: 3dea1d5 Merge bitcoin-core/libmultiprocess#135: refactor: proxy-types.h API cleanup
REVERT: 6adbb1d cmake: Support being included with add_subdirectory
REVERT: 10bb7e4 Merge bitcoin-core/libmultiprocess#94: c++ 20 cleanups
REVERT: 7d59b8d move: add mp/type-data.h
REVERT: 1103f86 cmake: Define and use MP_INCLUDE_DIR variable
REVERT: 798f4b5 moveonly: add mp/type-chrono.h
REVERT: a595a0b moveonly: add mp/type-threadmap.h
REVERT: e834ebd moveonly: add mp/type-decay.h
REVERT: 5ee6cd4 moveonly: add mp/type-exception.h
REVERT: 3946512 moveonly: add mp/type-void.h
REVERT: 8969d5a moveonly: add mp/type-message.h
REVERT: 11b418f moveonly: add mp/type-struct.h
REVERT: 5df55a3 moveonly: add mp/type-function.h
REVERT: 0d2f939 moveonly: add mp/type-interface.h
REVERT: 5417716 moveonly: add mp/type-char.h
REVERT: 83c444d moveonly: add mp/type-string.h
REVERT: df1375b moveonly: add mp/type-number.h
REVERT: 6d831eb moveonly: add mp/type-tuple.h
REVERT: c999100 moveonly: add mp/type-pair.h
REVERT: 079277f moveonly: add mp/type-map.h
REVERT: 6a68472 moveonly: add mp/type-set.h
REVERT: c6246c9 moveonly: add mp/type-vector.h
REVERT: 619d2c7 moveonly: add mp/type-pointer.h
REVERT: 3cb9d9f moveonly: add mp/type-optional.h
REVERT: b32e2b0 moveonly: add mp/type-context.h
REVERT: f18a1cc refactor: Rename ReadDestValue to ReadDestUpdate
REVERT: 3dc1d42 Merge bitcoin-core/libmultiprocess#133: Fix debian "libatomic not found" error in downstream builds
REVERT: eb27f59 Merge bitcoin-core/libmultiprocess#131: doc: fix startAsyncThread comment
REVERT: caf01fa Merge bitcoin-core/libmultiprocess#130: refactor: Add CleanupRun function to dedup clean list code
REVERT: 72f6669 Merge bitcoin-core/libmultiprocess#129: Fix "disconnected: write(m_post_fd, &buffer, 1): Broken pipe" EventLoop shutdown races.
REVERT: 67afc23 Fix debian "libatomic not found" error in downstream builds
REVERT: 0e4f88d Fix "disconnected: write(m_post_fd, &buffer, 1): Broken pipe" EventLoop shutdown races.
REVERT: 063ff18 fix startAsyncThread comment
REVERT: 3b2617b Merge bitcoin-core/libmultiprocess#127: ProxyClientBase: avoid static_cast to partially destructed object
REVERT: 63a39d4 ProxyClientBase: avoid static_cast to partially destructed object
REVERT: 700085f refactor: Add CleanupRun function to dedup clean list code
REVERT: 621a04a Merge bitcoin-core/libmultiprocess#120: proxy-types.h: add static_assert to detect int/enum size mismatch
REVERT: 110349f test: Add coverage for enum/int conversions
REVERT: 350067f Merge bitcoin-core/libmultiprocess#121: ProxyClientBase: avoid static_cast to partially constructed object
REVERT: 5b81192 ProxyClientBase: avoid static_cast to partially constructed object
REVERT: bbc80ab proxy-types.h: add static_assert to detect when an int fields is too small to hold an enum value
REVERT: abe254b Merge bitcoin-core/libmultiprocess#119: cmake: avoid libatomic not found error on debian
REVERT: 245581d Merge bitcoin-core/libmultiprocess#118: shutdown bugfix: Prevent segfault in server if connection is broken during long function call
REVERT: 196e6fc bugfix: prevent null pointer dereference in server if client disconnects during method call
REVERT: 296c380 cmake: avoid libatomic not found error on debian
REVERT: 9d11042 bugfix: prevent double delete segfault in server if client disconnects during method call
REVERT: 181837b Merge bitcoin-core/libmultiprocess#116: shutdown bugfix: destroy RPC system before running cleanup callbacks
REVERT: 2350843 shutdown bugfix: destroy RPC system before running cleanup callbacks
REVERT: a4ac424 Merge bitcoin-core/libmultiprocess#113: Add missing include to util.h
REVERT: 6929c40 Add missing include to util.h
REVERT: f5a4957 Merge bitcoin-core/libmultiprocess#111: doc: Add internal design section
REVERT: 1fa2ca7 doc: Add internal design section
REVERT: 015e95f Merge bitcoin-core/libmultiprocess#110: cmake: add target_capnp_sources headers target
REVERT: 66e12f1 cmake: add target_capnp_sources headers target
REVERT: f67cae8 Merge bitcoin-core/libmultiprocess#109: example: Add missing thread.join() call so example can exit cleanly
REVERT: 70b2d87 example: Add missing thread.join() call so example can exit cleanly
REVERT: 8bb6eab Merge bitcoin-core/libmultiprocess#108: doc: Add comments for socket descriptor handling when forking
REVERT: 17a2399 Merge bitcoin-core/libmultiprocess#107: example: Remove manual client adding
REVERT: b56bf21 doc: Add comments for socket descriptor handling when forking
REVERT: 3499810 example: Remove manual client adding
REVERT: c1b4ab4 Merge bitcoin-core/libmultiprocess#106: Bugfix: Clean up ThreadContext pointers when Connection is destroyed
REVERT: 8ba0d03 Bugfix: Clean up ThreadContext pointers when Connection is destroyed
REVERT: a9e16da Merge bitcoin-core/libmultiprocess#105: types: Add Custom{Build,Read,Pass}Message hooks
REVERT: ca2cfed types: Add Custom{Build,Read,Pass}Message hooks
REVERT: 6aca5f3 Merge bitcoin-core/libmultiprocess#104: Fix $Proxy.wrap mapping for empty structs with no fields
REVERT: e454072 Merge bitcoin-core/libmultiprocess#103: cmake: Fix package configuration file
REVERT: 90f8b37 Fix $Proxy.wrap mapping for empty structs with no fields
REVERT: c373a94 cmake: Fix package configuration file
REVERT: 8b8a476 Merge bitcoin-core/libmultiprocess#102: doc: Document shutdown sequences better
REVERT: 2c66dd5 doc: Document shutdown sequences better
REVERT: 6cbe56e refactor, moveonly: order lambda move captures first
REVERT: 8da0524 Merge bitcoin-core/libmultiprocess#101: connection: run async cleanups in LIFO not FIFO order
REVERT: 1f76880 util: Get rid of unused Discard struct
REVERT: c92e90c proxy-types Drop JoinPromises function
REVERT: 53ee9fa Merge bitcoin-core/libmultiprocess#100: doc: Add various code comments and documentation
REVERT: e45c482 Merge bitcoin-core/libmultiprocess#99: proxy-types: Fix missing space in server destroy log print
REVERT: 6825523 connection: run async cleanups in LIFO not FIFO order
REVERT: 537c645 doc: Improve ProxyServerCustom class documentation
REVERT: 0c70a0f proxy-types: Fix missing space in server destroy log print
REVERT: e29f74e Merge bitcoin-core/libmultiprocess#98: cmake: Combine installed packages
REVERT: d4d9f93 doc: Document FunctionTraits/ProxyMethodTraits classes
REVERT: 78c7dd0 doc: Document ProxyClient construct/destroy methods
REVERT: e99c0b7 doc: Document clientInvoke/serverInvoke functions
REVERT: 2098ae1 doc: Add comment on serverInvoke ReplaceVoid usage
REVERT: a1dfb0b doc: Add comments to mp.Context PassField function on updating g_thread_context
REVERT: e49a925 doc: Add comments to mp.Context PassField function on mp.Context.thread lookup
REVERT: dc9b4e6 cmake: Combine installed packages
REVERT: 2ed1e9a cmake: CMakeLists.txt cleanup
REVERT: 3f8483b Merge bitcoin-core/libmultiprocess#97: cmake: rename new packages and module introduced in #95 and #96
REVERT: c6a1d7f cmake: rename new packages and module introduced in #95 and #96
REVERT: 003eb04 Merge bitcoin-core/libmultiprocess#96: cmake: Introduce packages
REVERT: 19dea85 Merge bitcoin-core/libmultiprocess#95: cmake: Introduce `LibmultiprocessMacros` module
REVERT: 4e70ad4 cmake, refactor: Rename target export files
REVERT: 694b6b1 cmake: Configure `LibmultiprocessGen` package
REVERT: 3b20e35 cmake: Configure `Libmultiprocess` package
REVERT: 66643d8 cmake, refactor: Use `target_capnp_sources` for examples
REVERT: bd2dfe2 cmake, refactor: Use `target_capnp_sources` for `mptest` target
REVERT: d9ec22f cmake: Add `LibmultiprocessMacros` module
REVERT: 8da797c Merge bitcoin-core/libmultiprocess#93: Fix support for vector<bool> serialization with libc++
REVERT: 10fc3ed Fix support for vector<bool> serialization with libc++
REVERT: 7d1fee0 Merge bitcoin-core/libmultiprocess#91: util: Drop Bind, BindTuple, ComposeFn, GetFn, and ThrowFn helpers
REVERT: 65260d1 util: Drop Bind, BindTuple, ComposeFn, GetFn, and ThrowFn helpers
REVERT: 2cbbd09 Merge bitcoin-core/libmultiprocess#90: pkgconfig: Use @CMAKE_INSTALL_LIBDIR@ variable
REVERT: 0271195 Merge bitcoin-core/libmultiprocess#89: pkgconfig: Drop -std=c++17 compile flag
REVERT: 0f9605b pkgconfig: Use @CMAKE_INSTALL_LIBDIR@ variable
REVERT: 590d1e7 pkgconfig: Drop -std=c++17 compile flag
REVERT: 414542f Merge bitcoin-core/libmultiprocess#88: Fix current deprecation warnings as of capnproto-1.0.1
REVERT: 962e681 mpgen: Avoid deprecated SchemaParser::parseDiskFile call
REVERT: e8e89df Remove deprecated kj::mvCapture calls to avoid warnings
REVERT: 61d5a0e Merge bitcoin-core/libmultiprocess#86: Add support for vector<bool> serialization
REVERT: 1c6fb04 Add support for vector<bool> serialization
REVERT: aea56f0 Merge bitcoin-core/libmultiprocess#85: Remove naming requirement for std::pair/std::tuple
REVERT: 3df4974 Remove naming requirement for std::pair/std::tuple
REVERT: fc28a48 Merge #83: Introduce `clang-tidy` and optimize code
REVERT: 594466a clang-tidy: Fix `readability-make-member-function-const` check
REVERT: 037fec4 clang-tidy: Fix `performance-unnecessary-value-param` check
REVERT: 463bead clang-tidy: Fix `performance-inefficient-vector-operation` check
REVERT: a435b24 clang-tidy: Fix `performance-faster-string-find` check
REVERT: ae416f9 clang-tidy: Fix `modernize-use-nullptr` check
REVERT: 9f86c9a clang-tidy: Fix `modernize-use-equals-default` check
REVERT: 18b52c1 clang-tidy: Fix `modernize-use-emplace` check
REVERT: 1a33c35 clang-tidy: Fix `modernize-return-braced-init-list` check
REVERT: 8dd83bb clang-tidy: Suppress `bugprone-suspicious-semicolon` check warning
REVERT: 5e787bf Add option to run `clang-tidy` with compiler
REVERT: 74e25d2 Merge #84: Avoid passing some function arguments by value
REVERT: 8ef94d2 Avoid passing some function arguments by value
REVERT: 917877a Merge #79: Install Exports for custom `install-{lib,bin}` targets
REVERT: 2dda753 Install Exports for custom `install-{lib,bin}` targets
REVERT: 54bd57f Use `GNUInstallDirs` module
REVERT: 1af83d1 Merge #81: Add ReadDestTemp function to make it easier to call ReadField with less boilerplate
REVERT: e66e6e8 Merge #82: build: Fix missing Cap'n Proto include directories
REVERT: c753623 build: Fix missing Cap'n Proto include directories
REVERT: 70d108b Add ReadDestTemp function to make it easier to call ReadField with less boilerplate
REVERT: 7441069 Merge #80: doc: Fix mpgen usage string
REVERT: fcad5fb doc: Fix mpgen usage string
REVERT: ddd2cee Merge #78: refactor: Do not shadow `InvokeContext::connection` member
REVERT: f999694 refactor: Do not shadow `InvokeContext::connection` member
REVERT: 4992b52 Merge #74: Add `install-lib` and `install-bin` build targets
REVERT: fa130db Add `install-bin` target
REVERT: c4d26d2 Add `install-lib` target
REVERT: bc3d166 Install `proxy.capnp` with `mpgen` target
REVERT: f85feff Merge #73: Drop unneeded include directory
REVERT: 80dc922 Merge #72: Make `mpgen` target independent from `multiprocess` one
REVERT: d321ef8 Merge #71: Use defined `CXX_STANDARD` for environment introspection
REVERT: 331b5a6 Merge #70: Fix check for `pthread_threadid_np`
REVERT: d36ebb9 Drop unneeded include directory
REVERT: 665d1fd Make `mpgen` target independent from `multiprocess` one
REVERT: 2eff5da Use defined `CXX_STANDARD` for environment introspection
REVERT: 373d0d7 Fix check for `pthread_threadid_np`
REVERT: c6849de Merge #69: Fix CMake minimum required version
REVERT: 6902bfd Fix CMake minimum required version
REVERT: 49dc279 Merge bitcoin-core/libmultiprocess#66: Fix typos
REVERT: 9f4dac6 Fix typos
REVERT: 7d10f3b Merge bitcoin-core/libmultiprocess#65: Fix clang "unknown warning group" errors
REVERT: 680776f Fix clang "unknown warning group" errors
REVERT: bc6624a Merge bitcoin-core/libmultiprocess#64: cleanup: Remove AUTORET macro and clean up PassField overrides
REVERT: d2a9db9 Merge bitcoin-core/libmultiprocess#63: Fix mptest link error caused by missing kj-async dependency
REVERT: cf7ebfe Replace ThreadMap Passfield override with generic count(0) override
REVERT: 3f388cf Inline last AUTO_RETURN uses and remove macro
REVERT: 41db49c Consolidate PassField function to remove AUTO_RETURN uses
REVERT: 1d00505 Replace output.init AUTO_RETURN uses with decltype(auto)
REVERT: ea1a77b Replace AUTO_RETURN uses with decltype(auto)
REVERT: 029d84f Fix mptest link error caused by missing kj-async dependency
REVERT: 306c8b1 Merge bitcoin-core/libmultiprocess#62: Fix clang compiler warnings
REVERT: 1b638d6 Avoid delete-non-abstract-non-virtual-dtor warnings for mp::ProxyCallbackImpl
REVERT: 5738b8a Avoid delete-non-abstract-non-virtual-dtor warnings
REVERT: 921e23e Disable clang suggest-override warnings for proxy clients
REVERT: 34ce921 Merge bitcoin-core/libmultiprocess#58: Fix std::move compiler warning
REVERT: 49004c8 Merge bitcoin-core/libmultiprocess#57: doc/install.md: add cmake to brew install command
REVERT: e386cfa Fix std::move compiler warning
REVERT: 424d635 doc/install.md: add cmake to brew install command
REVERT: 8abd3da Merge #55: Add doc/ folder, split up readme and add more usage documentation
REVERT: 1a3dc8d Add documentation about interface definitions
REVERT: 5539208 Split up README.md
REVERT: 805eb73 Merge #49: Add standalone example with 3 processes
REVERT: 4b45e14 Add standalone example with 3 processes
REVERT: 17bfda9 Merge #48: Move test/src/ files one level up
REVERT: b648f2a Merge #47: gen.cpp: Check local includes before install includes
REVERT: 8b5259c Move test/src/ files one level up
REVERT: c2f866f Merge #45: Comments and LogEscape
REVERT: 1007bd7 gen.cpp: Check local includes before install includes
REVERT: 22afe27 util: fix LogEscape bug
REVERT: 89ababd doc: add note on vats
REVERT: 6e36f0f doc: fix various typos
REVERT: b6e060a README: add kj explainer
REVERT: d576d97 Merge #43: Drop hardcoded #include lines in generated files
REVERT: 35d2091 Merge #42: Support attaching custom cleanup functions to proxy client and server classes
REVERT: 2ccc479 Drop hardcoded #include lines in generated files
REVERT: ce8e8b6 Add ProxyTypeRegister typeid map
REVERT: fbdaaa7 Add cleanup callbacks to ProxyContext
REVERT: 34e9b78 refactor: Move connection field to ProxyContext struct
REVERT: 39ad0f5 Generate ProxyType traits for interface types
REVERT: 1b4012c Merge #41: Avoid depending on argument default constructors
REVERT: 0e97be3 Avoid depending on argument default constructors
REVERT: 4dcd807 Merge #40: Disable GCC suggest-override warnings for proxy clients
REVERT: 05f9817 Disable GCC suggest-override warnings for proxy clients
REVERT: 4c59977 Merge #38: Add "extends" inherited method support
REVERT: de748be Add "extends" inherited method support
REVERT: 9f5b835 Merge #37: Add "make check" target to build and run tests
REVERT: 0378353 Add "make check" target to build and run tests
REVERT: 9d23fdd Merge #35: Fix README.md markdown
REVERT: 4d946aa Fix README.md markdown
REVERT: 5741d75 Merge #34: Add shared_ptr callback support
REVERT: 9ce0335 Add comment saying how to fix clientInvoke missing Proxy.Context assert
REVERT: 31b4f1b Add shared_ptr ownership and lifetime support
REVERT: 27f8a35 Add saveCallback / callbackSaved test setup
REVERT: 5390a1b Add support for passing shared_ptrs without extending lifetime
REVERT: 39bbf74 Add CustomReadField priority param for more flexibility and consistency with CustomBuildField
REVERT: da489be Fix bugs in PassField overload for callback objects passed by reference
REVERT: ab4568b Add test coverage for thread map and callbacks
REVERT: 1d630f5 Merge #33: Fix empty exception values from bad ThrowFn declaration
REVERT: c3efcae Fix empty exception values from bad ThrowFn declaration
REVERT: 78f2f75 Merge #31: Unify ReadFieldNew / ReadFieldUpdate
REVERT: 112f364 Unify ReadFieldNew / ReadFieldUpdate
REVERT: c0e3a50 Merge #25: Obliterate Boost
REVERT: 10b5c69 Obliterate Boost
REVERT: f4112b7 Switch from C++14 to C++17
REVERT: f2ea4b9 Merge #30: proxy-io.h: fix missing assert.h include
REVERT: e2ad13a Merge #29: Update make test command in readme
REVERT: fad36ab proxy-io.h: fix missing assert.h include
REVERT: 4d78645 Merge #28: CMake workarounds for ubuntu capnproto 0.6.1 compatibility
REVERT: c8923eb Update make test command in readme
REVERT: 097bce2 Merge #24: Don't print a dash if thread name is not known
REVERT: a440eda Merge #23: Tell std::system_error() which function failed
REVERT: b09973b CMake workarounds for ubuntu capnproto 0.6.1 compatibility
REVERT: 570db83 Don't print a dash if thread name is not known
REVERT: d6dac63 Tell std::system_error() which function failed
REVERT: 49a9637 Merge #22: Handle fork(2) failures
REVERT: 50b6a7f Merge #21: Refactor ThreadName() to improve its portability
REVERT: 16ebae8 Handle fork(2) failures
REVERT: f1857e3 Refactor ThreadName() to improve its portability
REVERT: fe76b28 Merge #19: Fix compilation of foo.h: include <string>
REVERT: 829741c Merge #18: A followup to a616312: remove unnecessary call
REVERT: c92112a Fix compilation of foo.h: include <string>
REVERT: 3b5da8f A followup to a616312: remove unnecessary call
REVERT: d3388da Merge #17: Avoid using boost::optional in PassField()
REVERT: a616312 Avoid using boost::optional in PassField()
REVERT: abb3ae9 Merge #16: Reduce boost usage
REVERT: fb73b81 Change EventLoop::m_task_set to not use boost
REVERT: 138ad67 Change Field::(param and result) to not use boost
REVERT: 5724a2c Remove boost usage from GetAnnotation()
REVERT: cab9c51 Remove unnecessary boost include
REVERT: e0319f4 Merge #15: Add ListenConnections function
REVERT: d519e18 Add ListenConnections function
REVERT: d24cae6 Merge #14: Add simpler ServeStream function
REVERT: 710238c Add simpler ServeStream function
REVERT: 5f42547 Merge #13: Add mpgen.mk makefile rules
REVERT: b72ec47 Add mpgen.mk makefile rules
REVERT: 86d5a45 Merge #12: Add Eventloop void* context pointer
REVERT: 2a2549c Merge #11: Replace ProxyServer connection pointer with reference
REVERT: 4907c5d Add Eventloop void* context pointer
REVERT: e7687db Replace ProxyServer connection pointer with reference
REVERT: bd8ee26 Merge #10: Remove #include <syscall.h> to avoid mac os build error
REVERT: 4e452e9 Remove #include <syscall.h> to avoid mac os build error
REVERT: 9cd1a5a Merge #9: Invoke capnp compile from mpgen
REVERT: f89e4b3 Invoke capnp compile from mpgen
REVERT: dee0711 Merge #8: Add Connnect/Serve/Spawn/Wait functions
REVERT: 8125688 Merge #7: Add ProxyClientBase destroy_connection option
REVERT: f324c66 Add Connnect/Serve/Spawn/Wait functions
REVERT: da73a67 Merge #6: Explicitly request C++14 compiler
REVERT: c685fa9 Add ProxyClientBase destroy_connection option
REVERT: 409fe97 Explicitly request C++14 compiler
REVERT: 45785e7 Merge #3: Limit LogEscape string size
REVERT: 99bc4c5 Merge #2: Set mpgen rpath
REVERT: 724d2f7 Limit LogEscape string size
REVERT: 4dcf39f Set mpgen rpath
REVERT: cf5afd6 Merge #1: Fix libmultiprocess.pc install path
REVERT: 1bc076f Fix libmultiprocess.pc install path
REVERT: 06e1045 libmultiprocess initial commit

git-subtree-dir: src/ipc/libmultiprocess
git-subtree-split: 27ada4080964d26fed43d1c7329ba54b4c86199f
Kino1994 pushed a commit to Kino1994/bitcoin-full-history that referenced this pull request Jun 28, 2026
f4ce099 ipc: Handle bitcoin-wallet disconnections (Ryan Ofsky)
37b4d79 ipc: Add Ctrl-C handler for spawned subprocesses (Ryan Ofsky)
971244e doc: Improve IPC interface comments (Ryan Ofsky)
1dc6a0e ipc: Avoid waiting for clients to disconnect when shutting down (Ryan Ofsky)
8faa9ca test: Add unit test coverage for Init and Shutdown code (Ryan Ofsky)
7044815 ipc: Use EventLoopRef instead of addClient/removeClient (Ryan Ofsky)
e886c65 Squashed 'src/ipc/libmultiprocess/' changes from 27c7e8e5a581..b4120d34bad2 (Ryan Ofsky)

Pull request description:

  This PR fixes various problems when IPC connections are broken or hang which were reported in bitcoin-core/libmultiprocess#123, bitcoin-core/libmultiprocess#176, and bitcoin-core/libmultiprocess#182. The different fixes are described in commit messages.

  ---

  The first two commits of this PR update the libmultiprocess subtree including the following PRs:

  - bitcoin-core/libmultiprocess#181
  - bitcoin-core/libmultiprocess#179
  - bitcoin-core/libmultiprocess#160
  - bitcoin-core/libmultiprocess#184
  - bitcoin-core/libmultiprocess#187
  - bitcoin-core/libmultiprocess#186
  - bitcoin-core/libmultiprocess#192

  The subtree changes can be verified by running `test/lint/git-subtree-check.sh src/ipc/libmultiprocess` as described in [developer notes](https://github.com/bitcoin/bitcoin/blob/master/doc/developer-notes.md#subtrees) and [lint instructions](https://github.com/bitcoin/bitcoin/tree/master/test/lint#git-subtree-checksh).

  The remaining commits are:

  - [`7044815ad7e9` ipc: Use EventLoopRef instead of addClient/removeClient](bitcoin/bitcoin@7044815)
  - [`8faa9caf754f` test: Add unit test coverage for Init and Shutdown code](bitcoin/bitcoin@8faa9ca)
  - [`1dc6a0ea01b6` ipc: Avoid waiting for clients to disconnect when shutting down](bitcoin/bitcoin@1dc6a0e)
  - [`971244ed91da` doc: Improve IPC interface comments](bitcoin/bitcoin@971244e)
  - [`37b4d793c203` ipc: Add Ctrl-C handler for spawned subprocesses](bitcoin/bitcoin@37b4d79)
  - [`f4ce09962e60` ipc: Handle bitcoin-wallet disconnections](bitcoin/bitcoin@f4ce099)

  The new commits depend on the subtree update, and because the subtree update includes an incompatible API change, the "Use EventLoopRef" commit needs to be part of the same PR to avoid breaking the build. The other commits also make sense to merge at the same time because the bitcoin & libmultiprocess changes were written and tested together.

  ---

  This PR is part of the [process separation project](bitcoin/bitcoin#28722).

ACKs for top commit:
  Sjors:
    re-utACK f4ce099
  josibake:
    code review ACK bitcoin/bitcoin@f4ce099
  pinheadmz:
    re-ACK f4ce099

Tree-SHA512: 0095aa22d507803e2a2d46eff51fb6caf965cc0c97ccfa615bd97805d5d51e66a5b4b040640deb92896438b1fb9f6879847124c9d0e120283287bfce37b8d748
BigcoinBGC pushed a commit to BigcoinBGC/bigcoin that referenced this pull request Jun 30, 2026
b54c081 ipc: Handle bitcoin-wallet disconnections (Ryan Ofsky)
03df1d4 ipc: Add Ctrl-C handler for spawned subprocesses (Ryan Ofsky)
08cf8ae doc: Improve IPC interface comments (Ryan Ofsky)
c8d082e ipc: Avoid waiting for clients to disconnect when shutting down (Ryan Ofsky)
f85be14 test: Add unit test coverage for Init and Shutdown code (Ryan Ofsky)
bb3b7a7 ipc: Use EventLoopRef instead of addClient/removeClient (Ryan Ofsky)
e886c65 Squashed 'src/ipc/libmultiprocess/' changes from 27c7e8e5a581..b4120d34bad2 (Ryan Ofsky)

Pull request description:

  This PR fixes various problems when IPC connections are broken or hang which were reported in bitcoin-core/libmultiprocess#123, bitcoin-core/libmultiprocess#176, and bitcoin-core/libmultiprocess#182. The different fixes are described in commit messages.

  ---

  The first two commits of this PR update the libmultiprocess subtree including the following PRs:

  - bitcoin-core/libmultiprocess#181
  - bitcoin-core/libmultiprocess#179
  - bitcoin-core/libmultiprocess#160
  - bitcoin-core/libmultiprocess#184
  - bitcoin-core/libmultiprocess#187
  - bitcoin-core/libmultiprocess#186
  - bitcoin-core/libmultiprocess#192

  The subtree changes can be verified by running `test/lint/git-subtree-check.sh src/ipc/libmultiprocess` as described in [developer notes](https://github.com/bitcoin/bitcoin/blob/master/doc/developer-notes.md#subtrees) and [lint instructions](https://github.com/bitcoin/bitcoin/tree/master/test/lint#git-subtree-checksh).

  The remaining commits are:

  - [`bb3b7a77281d` ipc: Use EventLoopRef instead of addClient/removeClient](bitcoin/bitcoin@bb3b7a7)
  - [`f85be148ad5d` test: Add unit test coverage for Init and Shutdown code](bitcoin/bitcoin@f85be14)
  - [`c8d082e1e569` ipc: Avoid waiting for clients to disconnect when shutting down](bitcoin/bitcoin@c8d082e)
  - [`08cf8ae41c66` doc: Improve IPC interface comments](bitcoin/bitcoin@08cf8ae)
  - [`03df1d4bf7db` ipc: Add Ctrl-C handler for spawned subprocesses](bitcoin/bitcoin@03df1d4)
  - [`b54c081a9f65` ipc: Handle bitcoin-wallet disconnections](bitcoin/bitcoin@b54c081)

  The new commits depend on the subtree update, and because the subtree update includes an incompatible API change, the "Use EventLoopRef" commit needs to be part of the same PR to avoid breaking the build. The other commits also make sense to merge at the same time because the bitcoin & libmultiprocess changes were written and tested together.

  ---

  This PR is part of the [process separation project](bitcoin/bitcoin#28722).

ACKs for top commit:
  Sjors:
    re-utACK b54c081
  josibake:
    code review ACK bitcoin/bitcoin@b54c081
  pinheadmz:
    re-ACK b54c081

Tree-SHA512: 0095aa22d507803e2a2d46eff51fb6caf965cc0c97ccfa615bd97805d5d51e66a5b4b040640deb92896438b1fb9f6879847124c9d0e120283287bfce37b8d748
@bitcoin-core bitcoin-core locked and limited conversation to collaborators Jul 9, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants