Skip to content

Commit 0689086

Browse files
authored
Merge branch 'master' into guilt/wallet-can-spend-takes-ages
2 parents 99ecd13 + 1820423 commit 0689086

File tree

144 files changed

+4932
-3729
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

144 files changed

+4932
-3729
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
> [!IMPORTANT]
2-
> 24.11 FREEZE NOVEMBER 7TH: Non-bugfix PRs not ready by this date will wait for 25.02.
2+
> 25.02 FREEZE JANUARY 31ST: Non-bugfix PRs not ready by this date will wait for 25.05.
33
44
## Checklist
55
Before submitting the PR, ensure the following tasks are completed. If an item is not applicable to your PR, please mark it as checked:

.github/scripts/setup.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,18 @@ sudo apt-get -qq install --no-install-recommends --allow-unauthenticated -yy \
2020
gcc-arm-none-eabi \
2121
gettext \
2222
git \
23+
gnupg \
2324
jq \
2425
libc6-dev-arm64-cross \
2526
libc6-dev-armhf-cross \
27+
libev-dev \
28+
libevent-dev \
29+
libffi-dev \
30+
libicu-dev \
2631
libpq-dev \
2732
libprotobuf-c-dev \
2833
libsqlite3-dev \
34+
libssl-dev \
2935
libtool \
3036
libxml2-utils \
3137
locales \
@@ -43,6 +49,7 @@ sudo apt-get -qq install --no-install-recommends --allow-unauthenticated -yy \
4349
software-properties-common \
4450
sudo \
4551
tcl \
52+
tclsh \
4653
unzip \
4754
valgrind \
4855
wget \

.github/scripts/sync-rpc-cmds.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ def extract_rpc_commands(rst_content):
7070
commands = re.findall(
7171
r"\b([a-zA-Z0-9_-]+)" r"\s+<([^>]+)>\n", manpages_block.group(1)
7272
)
73-
return commands
73+
return [(re.sub(r"\blightning-", "", rpc_name), file_name) for rpc_name, file_name in commands]
7474
return []
7575

7676

@@ -102,7 +102,6 @@ def main():
102102
if commands_from_local:
103103
order = 0
104104
for name, file in commands_from_local:
105-
# print(f"{name}\t\t{file}")
106105
with open("doc/" + file) as f:
107106
body = f.read()
108107
publishDoc(Action.ADD if name in commands_to_add else Action.UPDATE, name, body, order, headers)

.github/workflows/ci.yaml

Lines changed: 43 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,6 @@ jobs:
8888
- name: Check source
8989
env:
9090
VALGRIND: 0
91-
GENERATE_EXAMPLES: 1
9291
PYTEST_OPTS: --timeout=1200
9392
run: make check-source BASE_REF="origin/${{ github.base_ref }}"
9493
- name: Check Generated Files have been updated
@@ -480,6 +479,48 @@ jobs:
480479
run: |
481480
poetry run pytest tests/ -vvv -n 2 ${PYTEST_OPTS} ${{ matrix.PYTEST_OPTS }}
482481
482+
update-docs-examples:
483+
name: Update examples in doc schemas
484+
runs-on: ubuntu-22.04
485+
timeout-minutes: 30
486+
strategy:
487+
fail-fast: true
488+
env:
489+
VALGRIND: 0
490+
GENERATE_EXAMPLES: 1
491+
PYTEST_OPTS: --timeout=1200
492+
TEST_NETWORK: regtest
493+
needs:
494+
- compile
495+
steps:
496+
- name: Checkout
497+
uses: actions/checkout@v4
498+
- name: Set up Python 3.10
499+
uses: actions/setup-python@v5
500+
with:
501+
python-version: '3.10'
502+
- name: Install dependencies
503+
run: |
504+
bash -x .github/scripts/setup.sh
505+
pip install -U pip wheel poetry
506+
poetry self add poetry-plugin-export
507+
poetry export -o /tmp/requirements.txt --without-hashes --with dev
508+
pip install -r /tmp/requirements.txt
509+
- name: Install bitcoind
510+
env:
511+
TEST_NETWORK: regtest
512+
run: .github/scripts/install-bitcoind.sh
513+
- name: Download build
514+
uses: actions/download-artifact@v4
515+
with:
516+
name: cln-compile-gcc.tar.bz2
517+
- name: Unpack pre-built CLN
518+
run: |
519+
tar -xaf cln-compile-gcc.tar.bz2
520+
- name: Test
521+
run: |
522+
make -j $(nproc) check-doc-examples
523+
483524
min-btc-support:
484525
name: Test minimum supported BTC v${{ matrix.MIN_BTC_VERSION }} with ${{ matrix.NAME }}
485526
runs-on: ubuntu-22.04
@@ -582,6 +623,7 @@ jobs:
582623
- check-units
583624
- integration-valgrind
584625
- integration-sanitizers
626+
- update-docs-examples
585627
- min-btc-support
586628
- check-flake
587629
steps:

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
fail-fast: false # Let each build finish.
6161
matrix:
6262
target:
63-
- 'bin-Fedora-28-amd64'
63+
- 'bin-Fedora'
6464
- 'bin-Ubuntu-focal'
6565
- 'bin-Ubuntu-jammy'
6666
- 'bin-Ubuntu-noble'

.github/workflows/repro.yml

Lines changed: 50 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,42 +19,48 @@ jobs:
1919
- name: Git checkout
2020
uses: actions/checkout@v4
2121

22-
- name: Build environment setup
22+
- name: Build environment setup - ${{ matrix.version }}
2323
run: |
2424
echo "Building base image for ${{ matrix.version }}"
25+
echo "STEP=Build environment setup" >> "$GITHUB_ENV"
2526
sudo docker run --rm -v $(pwd):/build ubuntu:${{ matrix.version }} bash -c "\
26-
apt-get update && \
27-
apt-get install -y debootstrap && \
28-
debootstrap ${{ matrix.version }} /build/${{ matrix.version }}"
27+
apt-get update && \
28+
apt-get install -y debootstrap && \
29+
debootstrap ${{ matrix.version }} /build/${{ matrix.version }}"
2930
sudo tar -C ${{ matrix.version }} -c . | docker import - ${{ matrix.version }}
3031
31-
- name: Builder image setup
32-
run: docker build -t cl-repro-${{ matrix.version }} - < contrib/reprobuild/Dockerfile.${{ matrix.version }}
32+
- name: Builder image setup - ${{ matrix.version }}
33+
run: |
34+
echo "STEP=Builder image setup" >> "$GITHUB_ENV"
35+
docker build -t cl-repro-${{ matrix.version }} - < contrib/reprobuild/Dockerfile.${{ matrix.version }}
3336
34-
- name: Build using the builder image and store Git state
37+
- name: Build reproducible image and store Git state - ${{ matrix.version }}
3538
run: |
39+
echo "STEP=Build reproducible image and store Git state" >> "$GITHUB_ENV"
40+
3641
# Create release directory.
3742
mkdir $GITHUB_WORKSPACE/release
3843
3944
# Perform the repro build.
4045
docker run --name cl-build -v $GITHUB_WORKSPACE:/repo -e FORCE_MTIME=$(date +%F) -t cl-repro-${{ matrix.version }}
4146
4247
# Commit the image in order to inspect the build later.
43-
docker commit cl-build cl-release
48+
docker commit cl-build cl-repro
4449
4550
# Inspect the version.
46-
docker run --rm -v $GITHUB_WORKSPACE:/repo -t cl-release bash -c "make version > /repo/release/version.txt"
51+
docker run --rm -v $GITHUB_WORKSPACE:/repo -t cl-repro bash -c "make version > /repo/release/version.txt"
4752
4853
# Inspect the Git tree state.
49-
docker run --rm -v $GITHUB_WORKSPACE:/repo -t cl-release bash -c "\
54+
docker run --rm -v $GITHUB_WORKSPACE:/repo -t cl-repro bash -c "\
5055
git --no-pager status > /repo/release/git.log && \
5156
git --no-pager diff >> /repo/release/git.log"
5257
5358
# Change permissions on the release files for access by the runner environment.
5459
sudo chown -R runner $GITHUB_WORKSPACE/release
5560
56-
- name: Assert clean version and release
61+
- name: Assert clean version - ${{ matrix.version }}
5762
run: |
63+
echo "STEP=Assert clean version" >> "$GITHUB_ENV"
5864
echo 'Version:'
5965
cat release/version.txt
6066
echo -e
@@ -63,16 +69,45 @@ jobs:
6369
echo 'Release file:'
6470
ls -al release/clightning-*
6571
echo -e
66-
6772
if [ -n "$(cat release/version.txt | sed -n '/-modded/p')" ] || \
68-
[ -n "$(echo $releasefile | sed -n '/-modded/p')" ]
69-
then
73+
[ -n "$(echo $releasefile | sed -n '/-modded/p')" ]; then
7074
echo "Git Status and Diff:"
7175
cat release/git.log
7276
echo -e
73-
7477
echo 'Error: release modded / dirty tree.'
7578
exit 1
7679
else
7780
echo 'Success! Clean release.'
7881
fi
82+
83+
- name: Upload release artifact - ${{ matrix.version }}
84+
uses: actions/upload-artifact@v4
85+
with:
86+
name: release-${{ matrix.version }}
87+
path: release
88+
retention-days: 3 # Automatically delete after 3 days
89+
90+
- name: Send email on failure
91+
if: ${{ failure() }}
92+
uses: dawidd6/action-send-mail@v3
93+
with:
94+
server_address: smtp.gmail.com
95+
server_port: 587
96+
username: ${{ secrets.EMAIL_USERNAME }}
97+
password: ${{ secrets.EMAIL_PASSWORD }}
98+
from: ${{ secrets.EMAIL_USERNAME }}
99+
to: ${{ vars.DISTRIBUTION_LIST }}
100+
subject: "CI Failure: Step ${{ env.STEP }} failed for distro ${{ matrix.version }}"
101+
convert_markdown: true
102+
html_body: |
103+
<html>
104+
<body>
105+
<p>GitHub Workflow ${{ github.workflow }} Failed! For more details, click on the action below.</p>
106+
<strong>Failure Details:</strong><br/>
107+
<strong>Event: </strong>${{ github.event_name }}<br/>
108+
<strong>Job: </strong>${{ github.job }}<br/>
109+
<strong>Distro: </strong>${{ matrix.version }}<br/>
110+
<strong>Step: </strong>${{ env.STEP }}<br/>
111+
<strong>Action: </strong><a href="${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}">${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}</a><br/>
112+
</body>
113+
</html>

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ compile_commands.json
8282
# Rust targets
8383
target
8484
plugins/cln-grpc
85+
plugins/clnrest
8586

8687
# Build directories
8788
bionic/

.msggen.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -997,6 +997,7 @@
997997
},
998998
"BlacklistruneRequest": {
999999
"BlacklistRune.end": 2,
1000+
"BlacklistRune.relist": 3,
10001001
"BlacklistRune.start": 1
10011002
},
10021003
"BlacklistruneResponse": {
@@ -1772,6 +1773,7 @@
17721773
"GetRoutes.final_cltv": 7,
17731774
"GetRoutes.finalcltv": 6,
17741775
"GetRoutes.layers[]": 4,
1776+
"GetRoutes.maxdelay": 8,
17751777
"GetRoutes.maxfee_msat": 5,
17761778
"GetRoutes.source": 1
17771779
},
@@ -3728,6 +3730,7 @@
37283730
"Xpay.amount_msat": 2,
37293731
"Xpay.invstring": 1,
37303732
"Xpay.layers[]": 4,
3733+
"Xpay.maxdelay": 7,
37313734
"Xpay.maxfee": 3,
37323735
"Xpay.partial_msat": 6,
37333736
"Xpay.retry_for": 5
@@ -5125,6 +5128,10 @@
51255128
"added": "pre-v0.10.1",
51265129
"deprecated": null
51275130
},
5131+
"BlacklistRune.relist": {
5132+
"added": "v25.02",
5133+
"deprecated": null
5134+
},
51285135
"BlacklistRune.start": {
51295136
"added": "pre-v0.10.1",
51305137
"deprecated": null
@@ -7317,6 +7324,10 @@
73177324
"added": "v24.08",
73187325
"deprecated": null
73197326
},
7327+
"GetRoutes.maxdelay": {
7328+
"added": "v25.02",
7329+
"deprecated": null
7330+
},
73207331
"GetRoutes.maxfee_msat": {
73217332
"added": "v24.08",
73227333
"deprecated": null
@@ -12969,6 +12980,10 @@
1296912980
"added": "v24.11",
1297012981
"deprecated": null
1297112982
},
12983+
"Xpay.maxdelay": {
12984+
"added": "v25.02",
12985+
"deprecated": null
12986+
},
1297212987
"Xpay.maxfee": {
1297312988
"added": "v24.11",
1297412989
"deprecated": null

0 commit comments

Comments
 (0)