Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -780,8 +780,7 @@ jobs:
if-no-files-found: ignore

update-docs-examples:
name: Update examples in doc schemas (disabled temporarily!)
if: false
name: Update examples in doc schemas
runs-on: ubuntu-24.04
timeout-minutes: 30
strategy:
Expand Down Expand Up @@ -938,6 +937,7 @@ jobs:
- check-units
- integration-valgrind
- integration-sanitizers
- update-docs-examples
- min-btc-support
- check-downgrade
- check-compiled-source
Expand Down
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -652,14 +652,18 @@ repeat-doc-examples:
echo "----------------------------------" >> tests/autogenerate-examples-repeat.log; \
echo "Iteration $$i" >> tests/autogenerate-examples-repeat.log; \
echo "----------------------------------" >> tests/autogenerate-examples-repeat.log; \
VALGRIND=0 TIMEOUT=40 TEST_DEBUG=1 GENERATE_EXAMPLES=1 pytest -vvv tests/autogenerate-rpc-examples.py; \
VALGRIND=0 TIMEOUT=40 TEST_DEBUG=1 GENERATE_EXAMPLES=1 CLN_NEXT_VERSION=$(CLN_NEXT_VERSION) pytest -vvv tests/autogenerate-rpc-examples.py; \
git diff >> tests/autogenerate-examples-repeat.log; \
git reset --hard; \
echo "----------------------------------" >> tests/autogenerate-examples-repeat.log; \
done

update-doc-examples:
TEST_DEBUG=1 VALGRIND=0 GENERATE_EXAMPLES=1 $(PYTEST) $(PYTEST_OPTS) --timeout=1200 tests/autogenerate-rpc-examples.py && $(MAKE) $(MSGGEN_GEN_ALL)
TEST_DEBUG=1 VALGRIND=0 GENERATE_EXAMPLES=1 CLN_NEXT_VERSION=$(CLN_NEXT_VERSION) $(PYTEST) $(PYTEST_OPTS) --timeout=1200 tests/autogenerate-rpc-examples.py && $(MAKE) $(MSGGEN_GEN_ALL)

# If you changed tests/autogenerate-rpc-examples.py to require new blocks, you have to run this:
update-doc-examples-newchain:
TEST_DEBUG=1 VALGRIND=0 GENERATE_EXAMPLES=1 CLN_NEXT_VERSION=$(CLN_NEXT_VERSION) REGENERATE_BLOCKCHAIN=1 $(PYTEST) $(PYTEST_OPTS) --timeout=1200 tests/autogenerate-rpc-examples.py && $(MAKE) $(MSGGEN_GEN_ALL)

check-doc-examples: update-doc-examples
git diff --exit-code HEAD
Expand Down
7 changes: 1 addition & 6 deletions cln-grpc/proto/node.proto

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 3 additions & 11 deletions cln-grpc/src/convert.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 3 additions & 12 deletions cln-rpc/src/model.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions common/test/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ common/test/run-json: \
common/lease_rates.o \
common/node_id.o \
common/pseudorand.o \
common/randbytes.o \
common/wireaddr.o \
wire/fromwire.o \
wire/onion_wiregen.o \
Expand All @@ -49,6 +50,7 @@ common/test/run-route common/test/run-route-specific common/test/run-route-inflo
common/gossmap.o \
common/node_id.o \
common/pseudorand.o \
common/randbytes.o \
common/route.o \
common/gossip_store_wiregen.o \
wire/fromwire.o \
Expand Down Expand Up @@ -158,6 +160,7 @@ common/test/run-mkdatastorekey: \
common/pseudorand.o

common/test/run-htable: \
common/randbytes.o \
common/pseudorand.o

common/test/run-shutdown_scriptpubkey: wire/towire.o wire/fromwire.o
Expand Down
1 change: 1 addition & 0 deletions common/test/run-bigsize.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include <common/amount.h>
#include <common/json_parse.c>
#include <common/json_parse_simple.c>
#include <common/randbytes.h>
#include <common/setup.h>

static const char *reason;
Expand Down
1 change: 1 addition & 0 deletions common/test/run-blindedpath_enctlv.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
#include "../blinding.c"
#include "../hmac.c"
#include <common/channel_id.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt11.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#include "../wire/fromwire.c"
#include "../wire/towire.c"
#include <ccan/err/err.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12-encode-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
#include <common/bolt12.c>
#include <common/bolt12_merkle.h>
#include <common/features.c>
#include <common/randbytes.h>
#include <common/sciddir_or_pubkey.c>
#include <common/setup.h>
#include <inttypes.h>
Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12-format-string-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include <common/bolt12.h>
#include <common/bolt12_merkle.h>
#include <common/features.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <common/utils.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12-offer-decode.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
#include <ccan/array_size/array_size.h>
#include <ccan/tal/grab_file/grab_file.h>
#include <ccan/tal/path/path.h>
#include <common/randbytes.h>
#include <common/setup.h>

/* AUTOGENERATED MOCKS START */
Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12_decode.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include <ccan/json_escape/json_escape.h>
#include <ccan/tal/grab_file/grab_file.h>
#include <ccan/tal/path/path.h>
#include <common/randbytes.h>
#include <common/setup.h>

/* AUTOGENERATED MOCKS START */
Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12_merkle-json.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
#include <ccan/tal/grab_file/grab_file.h>
#include <ccan/tal/path/path.h>
#include <common/channel_type.h>
#include <common/randbytes.h>
#include <common/setup.h>

/* AUTOGENERATED MOCKS START */
Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12_merkle.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <ccan/array_size/array_size.h>
#include <common/channel_type.h>
#include <common/features.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <secp256k1_schnorrsig.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-bolt12_period.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <ccan/array_size/array_size.h>
#include <ccan/tal/grab_file/grab_file.h>
#include <ccan/tal/path/path.h>
#include <common/randbytes.h>
#include <common/setup.h>

/* AUTOGENERATED MOCKS START */
Expand Down
1 change: 1 addition & 0 deletions common/test/run-channel_type.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include "../channel_type.c"
#include "../features.c"
#include <ccan/tal/str/str.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>
#include <lightningd/channel_state.h>
Expand Down
1 change: 1 addition & 0 deletions common/test/run-codex32.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include <common/codex32.h>
#include <ccan/tal/grab_file/grab_file.h>
#include <ccan/tal/path/path.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <wire/wire.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-coin_mvt.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "config.h"
#include "../coin_mvt.c"
#include <ccan/tal/str/str.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-cryptomsg.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include "config.h"
#include <ccan/str/hex/hex.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <common/status.h>
#include <common/utils.h>
Expand Down
9 changes: 9 additions & 0 deletions common/test/run-htable.c
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,15 @@ u8 fromwire_u8(const u8 **cursor UNNEEDED, size_t *max UNNEEDED)
/* Generated stub for fromwire_u8_array */
void fromwire_u8_array(const u8 **cursor UNNEEDED, size_t *max UNNEEDED, u8 *arr UNNEEDED, size_t num UNNEEDED)
{ fprintf(stderr, "fromwire_u8_array called!\n"); abort(); }
/* Generated stub for memleak_add_helper_ */
void memleak_add_helper_(const tal_t *p UNNEEDED, void (*cb)(struct htable *memtable UNNEEDED,
const tal_t *)){ }
/* Generated stub for memleak_scan_htable */
void memleak_scan_htable(struct htable *memtable UNNEEDED, const struct htable *ht UNNEEDED)
{ fprintf(stderr, "memleak_scan_htable called!\n"); abort(); }
/* Generated stub for notleak_ */
void *notleak_(void *ptr UNNEEDED, bool plus_children UNNEEDED)
{ fprintf(stderr, "notleak_ called!\n"); abort(); }
/* Generated stub for towire */
void towire(u8 **pptr UNNEEDED, const void *data UNNEEDED, size_t len UNNEEDED)
{ fprintf(stderr, "towire called!\n"); abort(); }
Expand Down
1 change: 1 addition & 0 deletions common/test/run-json_filter.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include "../json_stream.c"
#include <ccan/json_out/json_out.h>
#include <common/json_command.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-json_remove.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include <common/amount.h>
#include <common/json_param.c>
#include <common/json_parse_simple.c>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>
#include <wire/wire.h>
Expand Down
1 change: 1 addition & 0 deletions common/test/run-json_scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include "../json_parse.c"
#include "../json_parse_simple.c"
#include <common/amount.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>
#include <wire/wire.h>
Expand Down
1 change: 1 addition & 0 deletions common/test/run-json_stream-filter.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include <assert.h>
#include <ccan/tal/str/str.h>
#include <common/channel_type.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <inttypes.h>
#include <stdio.h>
Expand Down
1 change: 1 addition & 0 deletions common/test/run-lease_rates.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "config.h"
#include "../amount.c"
#include "../lease_rates.c"
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>

Expand Down
1 change: 1 addition & 0 deletions common/test/run-psbt_diff.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#include "config.h"
#include <common/randbytes.h>
#include <common/setup.h>
#include <stdio.h>
#include "../amount.c"
Expand Down
9 changes: 9 additions & 0 deletions common/test/run-route-infloop.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,15 @@ bool fromwire_tlv(const u8 **cursor UNNEEDED, size_t *max UNNEEDED,
void *record UNNEEDED, struct tlv_field **fields UNNEEDED,
const u64 *extra_types UNNEEDED, size_t *err_off UNNEEDED, u64 *err_type UNNEEDED)
{ fprintf(stderr, "fromwire_tlv called!\n"); abort(); }
/* Generated stub for memleak_add_helper_ */
void memleak_add_helper_(const tal_t *p UNNEEDED, void (*cb)(struct htable *memtable UNNEEDED,
const tal_t *)){ }
/* Generated stub for memleak_scan_htable */
void memleak_scan_htable(struct htable *memtable UNNEEDED, const struct htable *ht UNNEEDED)
{ fprintf(stderr, "memleak_scan_htable called!\n"); abort(); }
/* Generated stub for notleak_ */
void *notleak_(void *ptr UNNEEDED, bool plus_children UNNEEDED)
{ fprintf(stderr, "notleak_ called!\n"); abort(); }
/* Generated stub for sciddir_or_pubkey_from_node_id */
bool sciddir_or_pubkey_from_node_id(struct sciddir_or_pubkey *sciddpk UNNEEDED,
const struct node_id *node_id UNNEEDED)
Expand Down
1 change: 1 addition & 0 deletions common/test/run-route_blinding_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include <common/clock_time.h>
#include <common/json_parse.h>
#include <common/json_stream.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <common/wireaddr.h>
#include <stdio.h>
Expand Down
1 change: 1 addition & 0 deletions common/test/run-splice_script.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include "../json_stream.c"
#include "../json_parse_simple.c"
#include <bitcoin/chainparams.h>
#include <common/randbytes.h>
#include <common/setup.h>
#include <common/splice_script.h>
#include <assert.h>
Expand Down
Loading
Loading