`watchtower-plugin` compile fails on arm64 (RaspiOS)
Closed this issue · 3 comments
steepdawn974 commented
I'm working on integrating the watchtower-plugin
in the Raspiblitz Node project, but the compile fails (raspiblitz/raspiblitz#3404 (comment))
Commit: d212aae
Install steps taken:
See --> https://github.com/steepdawn974/raspiblitz/blob/teos-watchtower-install/home.admin/config.scripts/cl-plugin.watchtower-client.sh
The Error:
Compiling watchtower-plugin v0.1.2 (/home/bitcoin/cl-plugins-available/rust-teos/watchtower-plugin)
error[E0277]: the trait bound `Arc<std::sync::Mutex<WTClient>>: AsyncRead` is not satisfied
--> watchtower-plugin/src/main.rs:527:32
|
527 | let builder = Builder::new(state, stdin(), stdout())
| ------------ ^^^^^ the trait `AsyncRead` is not implemented for `Arc<std::sync::Mutex<WTClient>>`
| |
| required by a bound introduced by this call
|
= help: the following other types implement trait `AsyncRead`:
&[u8]
&mut T
Box<T>
BufStream<RW>
DuplexStream
Pin<P>
h2::codec::framed_write::FramedWrite<T, B>
hyper::server::tcp::addr_stream::AddrStream
and 27 others
note: required by a bound in `cln_plugin::Builder::<S, I, O>::new`
--> /home/bitcoin/.cargo/registry/src/github.com-1ecc6299db9ec823/cln-plugin-0.1.1/src/lib.rs:107:8
|
107 | I: AsyncRead + Send + Unpin + 'static,
| ^^^^^^^^^ required by this bound in `cln_plugin::Builder::<S, I, O>::new`
error[E0277]: the trait bound `tokio::io::Stdin: AsyncWrite` is not satisfied
--> watchtower-plugin/src/main.rs:527:39
|
527 | let builder = Builder::new(state, stdin(), stdout())
| ------------ ^^^^^^^ the trait `AsyncWrite` is not implemented for `tokio::io::Stdin`
| |
| required by a bound introduced by this call
|
= help: the following other types implement trait `AsyncWrite`:
&mut T
Box<T>
BufStream<RW>
DuplexStream
Pin<P>
Vec<u8>
hyper::server::tcp::addr_stream::AddrStream
hyper::upgrade::Upgraded
and 27 others
note: required by a bound in `cln_plugin::Builder::<S, I, O>::new`
--> /home/bitcoin/.cargo/registry/src/github.com-1ecc6299db9ec823/cln-plugin-0.1.1/src/lib.rs:105:15
|
105 | O: Send + AsyncWrite + Unpin + 'static,
| ^^^^^^^^^^ required by this bound in `cln_plugin::Builder::<S, I, O>::new`
error[E0061]: this function takes 2 arguments but 3 arguments were supplied
--> watchtower-plugin/src/main.rs:527:19
|
527 | let builder = Builder::new(state, stdin(), stdout())
| ^^^^^^^^^^^^ -------- argument of type `tokio::io::Stdout` unexpected
|
note: associated function defined here
--> /home/bitcoin/.cargo/registry/src/github.com-1ecc6299db9ec823/cln-plugin-0.1.1/src/lib.rs:109:12
|
109 | pub fn new(input: I, output: O) -> Self {
| ^^^
help: remove the extra argument
|
527 | let builder = Builder::new(state, stdin())
| ~~~~~~~~~~~~~~~~
error[E0277]: the trait bound `Arc<std::sync::Mutex<WTClient>>: AsyncRead` is not satisfied
--> watchtower-plugin/src/main.rs:527:19
|
527 | let builder = Builder::new(state, stdin(), stdout())
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncRead` is not implemented for `Arc<std::sync::Mutex<WTClient>>`
|
= help: the following other types implement trait `AsyncRead`:
&[u8]
&mut T
Box<T>
BufStream<RW>
DuplexStream
Pin<P>
h2::codec::framed_write::FramedWrite<T, B>
hyper::server::tcp::addr_stream::AddrStream
and 27 others
note: required by a bound in `cln_plugin::Builder`
--> /home/bitcoin/.cargo/registry/src/github.com-1ecc6299db9ec823/cln-plugin-0.1.1/src/lib.rs:37:8
|
37 | I: AsyncRead + Unpin,
| ^^^^^^^^^ required by this bound in `cln_plugin::Builder`
error[E0277]: the trait bound `tokio::io::Stdin: AsyncWrite` is not satisfied
--> watchtower-plugin/src/main.rs:527:19
|
527 | let builder = Builder::new(state, stdin(), stdout())
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncWrite` is not implemented for `tokio::io::Stdin`
|
= help: the following other types implement trait `AsyncWrite`:
&mut T
Box<T>
BufStream<RW>
DuplexStream
Pin<P>
Vec<u8>
hyper::server::tcp::addr_stream::AddrStream
hyper::upgrade::Upgraded
and 27 others
note: required by a bound in `cln_plugin::Builder`
--> /home/bitcoin/.cargo/registry/src/github.com-1ecc6299db9ec823/cln-plugin-0.1.1/src/lib.rs:38:15
|
38 | O: Send + AsyncWrite + Unpin,
| ^^^^^^^^^^ required by this bound in `cln_plugin::Builder`
error[E0599]: the method `option` exists for struct `cln_plugin::Builder<_, Arc<std::sync::Mutex<WTClient>>, tokio::io::Stdin>`, but its trait bounds were not satisfied
--> watchtower-plugin/src/main.rs:528:10
|
528 | .option(ConfigOption::new(
| ^^^^^^ method cannot be called on `cln_plugin::Builder<_, Arc<std::sync::Mutex<WTClient>>, tokio::io::Stdin>` due to unsatisfied trait bounds
|
::: /home/bitcoin/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.22.0/src/io/stdin.rs:29:5
|
29 | pub struct Stdin {
| ---------------- doesn't satisfy `tokio::io::Stdin: AsyncWrite`
|
= note: the following trait bounds were not satisfied:
`tokio::io::Stdin: AsyncWrite`
`Arc<std::sync::Mutex<WTClient>>: AsyncRead`
Some errors have detailed explanations: E0061, E0277, E0599.
For more information about an error, try `rustc --explain E0061`.
error: could not compile `watchtower-plugin` due to 6 previous errors
error: failed to compile `watchtower-plugin v0.1.2 (/home/bitcoin/cl-plugins-available/rust-teos/watchtower-plugin)`, intermediate artifacts can be found at `/home/bitcoin/cl-plugins-available/watchtower-client`
Running: sudo -u bitcoin ln -s /home/bitcoin/cl-plugins-available/watchtower-client/release/watchtower-client /home/bitcoin/cl-plugins-enabled/watchtower-client
watchtower-proxy=127.0.0.1:9050
# Restart the lightningd.service to activate watchtower-client
sr-gi commented
steepdawn974 commented
Tested fe33e127253ac75b434690ef52b522c12baa2313
and can confirm it fixes the issue.
sr-gi commented
@steepdawn974 this should have been resolved.
Closed by #153