File tree Expand file tree Collapse file tree 18 files changed +99
-36
lines changed
lightning-background-processor/src
lightning-transaction-sync/src Expand file tree Collapse file tree 18 files changed +99
-36
lines changed Original file line number Diff line number Diff line change @@ -208,6 +208,24 @@ jobs:
208208 RUSTFLAGS : ' --cfg=taproot'
209209 RUSTDOCFLAGS : ' --cfg=taproot'
210210
211+ check_docs :
212+ runs-on : self-hosted
213+ env :
214+ # While docs.rs builds using a nightly compiler (and we use some nightly features),
215+ # nightly ends up randomly breaking builds occasionally, so we instead use beta
216+ # and set RUSTC_BOOTSTRAP in check-docsrs.sh
217+ TOOLCHAIN : beta
218+ steps :
219+ - name : Checkout source code
220+ uses : actions/checkout@v4
221+ with :
222+ fetch-depth : 0
223+ - name : Install Rust ${{ env.TOOLCHAIN }} toolchain
224+ run : |
225+ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile=minimal --default-toolchain ${{ env.TOOLCHAIN }}
226+ - name : Simulate docs.rs build
227+ run : ci/check-docsrs.sh
228+
211229 fuzz :
212230 runs-on : ubuntu-latest
213231 env :
Original file line number Diff line number Diff line change 1+ # 0.1.7 - Oct 21, 2025 - "Unstable Release CI"
2+
3+ ## Bug Fixes
4+ * Builds with the ` docsrs ` cfg flag (set automatically for builds on docs.rs
5+ but otherwise not used) were fixed.
6+
7+
18# 0.1.6 - Oct 10, 2025 - "Async Preimage Claims"
29
310## Performance Improvements
3643 it. This allows a peer which opens channels without funding them to bloat our
3744 memory and disk space, eventually leading to denial-of-service (#4081 ).
3845
46+
3947# 0.1.5 - Jul 16, 2025 - "Async Path Reduction"
4048
4149## Performance Improvements
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ # shellcheck disable=SC2002,SC2086,SC2207
3+
4+ set -ex
5+
6+ # Attempt to simulate the docsrs builds. Sadly its not entirely trivial as
7+ # docs.rs reads metadata out of Cargo.toml which we don't want to have a whole
8+ # parser for.
9+
10+ WORKSPACE_MEMBERS=( $( cat Cargo.toml | tr ' \n' ' \r' | sed ' s/\r //g' | tr ' \r' ' \n' | grep ' ^members =' | sed ' s/members.*=.*\[//' | tr -d ' "' | tr ' ,' ' \n' ) )
11+ echo " ${WORKSPACE_MEMBERS[@]} "
12+ for CRATE in " ${WORKSPACE_MEMBERS[@]} " ; do
13+ pushd " $CRATE "
14+ CARGO_ARGS=" "
15+ RUSTDOC_ARGS=" "
16+ cat Cargo.toml | grep -A 100 ' \[package.metadata.docs.rs\]' | tail -n +2 > /tmp/ldk-docsrs-rustdoc-config.txt
17+ while read -r LINE; do
18+ case " $LINE " in
19+ " [" * ) break ;;
20+ " features" * )
21+ OG_IFS=" $IFS "
22+ IFS=' ,'
23+ for FEATURE in $( echo " $LINE " | sed ' s/features.*=.*\[//g' | tr -d ' "] ' ) ; do
24+ export CARGO_ARGS=" $CARGO_ARGS --features $FEATURE "
25+ done
26+ IFS=" $OG_IFS "
27+ ;;
28+ " all-features = true" )
29+ export CARGO_ARGS=" $CARGO_ARGS --all-features"
30+ ;;
31+ " rustdoc-args" * )
32+ RUSTDOC_ARGS=" $( echo " $LINE " | sed ' s/rustdoc-args.*=.*\[//g' | tr -d ' "],' ) "
33+ ;;
34+ esac
35+ done < /tmp/ldk-docsrs-rustdoc-config.txt
36+ rm /tmp/ldk-docsrs-rustdoc-config.txt
37+ echo " Building $CRATE with args $CARGO_ARGS and flags $RUSTDOC_ARGS "
38+ # We rely on nightly features but want to use a stable release in CI to avoid
39+ # spurous breakage, thus we set RUSTC_BOOTSTRAP=1 here.
40+ RUSTC_BOOTSTRAP=1 cargo rustdoc $CARGO_ARGS -- $RUSTDOC_ARGS
41+ popd
42+ done
Original file line number Diff line number Diff line change 11#! /bin/bash
2+ # shellcheck disable=SC2002,SC2207
23set -eox pipefail
34
45RUSTC_MINOR_VERSION=$( rustc --version | awk ' { split($2,a,"."); print a[2] }' )
@@ -41,23 +42,7 @@ export RUST_BACKTRACE=1
4142echo -e " \n\nChecking the workspace, except lightning-transaction-sync."
4243cargo check --verbose --color always
4344
44- # When the workspace members change, make sure to update the list here as well
45- # as in `Cargo.toml`.
46- WORKSPACE_MEMBERS=(
47- lightning
48- lightning-types
49- lightning-block-sync
50- lightning-invoice
51- lightning-net-tokio
52- lightning-persister
53- lightning-background-processor
54- lightning-rapid-gossip-sync
55- lightning-custom-message
56- lightning-macros
57- lightning-dns-resolver
58- lightning-liquidity
59- possiblyrandom
60- )
45+ WORKSPACE_MEMBERS=( $( cat Cargo.toml | tr ' \n' ' \r' | sed ' s/\r //g' | tr ' \r' ' \n' | grep ' ^members =' | sed ' s/members.*=.*\[//' | tr -d ' "' | tr ' ,' ' ' ) )
6146
6247echo -e " \n\nChecking, testing, and building docs for all workspace members individually..."
6348for DIR in " ${WORKSPACE_MEMBERS[@]} " ; do
Original file line number Diff line number Diff line change 55#![ deny( rustdoc:: private_intra_doc_links) ]
66#![ deny( missing_docs) ]
77#![ cfg_attr( not( feature = "futures" ) , deny( unsafe_code) ) ]
8- #![ cfg_attr( docsrs, feature( doc_auto_cfg ) ) ]
8+ #![ cfg_attr( docsrs, feature( doc_cfg ) ) ]
99#![ cfg_attr( all( not( feature = "std" ) , not( test) ) , no_std) ]
1010
1111#[ cfg( any( test, feature = "std" ) ) ]
Original file line number Diff line number Diff line change 1717#![ deny( rustdoc:: private_intra_doc_links) ]
1818#![ deny( missing_docs) ]
1919#![ deny( unsafe_code) ]
20- #![ cfg_attr( docsrs, feature( doc_auto_cfg ) ) ]
20+ #![ cfg_attr( docsrs, feature( doc_cfg ) ) ]
2121
2222#[ cfg( any( feature = "rest-client" , feature = "rpc-client" ) ) ]
2323pub mod http;
Original file line number Diff line number Diff line change 55#![ deny( non_camel_case_types) ]
66#![ deny( non_snake_case) ]
77#![ deny( unused_mut) ]
8- #![ cfg_attr( docsrs, feature( doc_auto_cfg ) ) ]
8+ #![ cfg_attr( docsrs, feature( doc_cfg ) ) ]
99#![ cfg_attr( all( not( feature = "std" ) , not( test) ) , no_std) ]
1010
1111//! This crate provides data structures to represent
Original file line number Diff line number Diff line change 4444#![ allow( bare_trait_objects) ]
4545#![ allow( ellipsis_inclusive_range_patterns) ]
4646#![ allow( clippy:: drop_non_drop) ]
47- #![ cfg_attr( docsrs, feature( doc_auto_cfg ) ) ]
47+ #![ cfg_attr( docsrs, feature( doc_cfg ) ) ]
4848#![ cfg_attr( not( feature = "std" ) , no_std) ]
4949
5050#[ macro_use]
Original file line number Diff line number Diff line change 1616#![ forbid( unsafe_code) ]
1717#![ deny( rustdoc:: broken_intra_doc_links) ]
1818#![ deny( rustdoc:: private_intra_doc_links) ]
19- #![ cfg_attr( docsrs, feature( doc_auto_cfg ) ) ]
19+ #![ cfg_attr( docsrs, feature( doc_cfg ) ) ]
2020
2121use proc_macro:: TokenStream ;
2222use quote:: quote;
Original file line number Diff line number Diff line change 2525#![ deny( rustdoc:: broken_intra_doc_links) ]
2626#![ deny( rustdoc:: private_intra_doc_links) ]
2727#![ deny( missing_docs) ]
28- #![ cfg_attr( docsrs, feature( doc_auto_cfg ) ) ]
28+ #![ cfg_attr( docsrs, feature( doc_cfg ) ) ]
2929
3030use bitcoin:: secp256k1:: PublicKey ;
3131
You can’t perform that action at this time.
0 commit comments