lightning icon indicating copy to clipboard operation
lightning copied to clipboard

Error with mako missing when updating to v25.09

Open ElucGeek opened this issue 2 months ago • 4 comments

I'm running CLN on ubuntu. I just did update to 25.05 without issue but then I wanted to update to 25.09 and I get this error during poetry run make: ModuleNotFoundError: No module named 'mako' make: *** [Makefile:328: common/status_wiregen.h] Error 1

Here is the complete output from when it's start the make:

make[1]: Entering directory '/home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace-build' make all-am make[2]: Entering directory '/home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace-build' /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=atomic.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o atomic.lo ../../libbacktrace/atomic.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=atomic.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/atomic.c -o atomic.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=dwarf.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o dwarf.lo ../../libbacktrace/dwarf.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=dwarf.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/dwarf.c -o dwarf.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=fileline.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o fileline.lo ../../libbacktrace/fileline.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=fileline.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/fileline.c -o fileline.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=posix.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o posix.lo ../../libbacktrace/posix.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=posix.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/posix.c -o posix.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=print.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o print.lo ../../libbacktrace/print.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=print.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/print.c -o print.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=sort.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o sort.lo ../../libbacktrace/sort.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=sort.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/sort.c -o sort.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=state.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o state.lo ../../libbacktrace/state.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=state.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/state.c -o state.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=backtrace.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o backtrace.lo ../../libbacktrace/backtrace.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=backtrace.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/backtrace.c -o backtrace.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=simple.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o simple.lo ../../libbacktrace/simple.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=simple.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/simple.c -o simple.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=elf.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o elf.lo ../../libbacktrace/elf.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=elf.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/elf.c -o elf.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=mmapio.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o mmapio.lo ../../libbacktrace/mmapio.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=mmapio.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/mmapio.c -o mmapio.o /bin/bash ./libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=mmap.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c -o mmap.lo ../../libbacktrace/mmap.c libtool: compile: cc -DHAVE_CONFIG_H -I. -I../../libbacktrace -funwind-tables -frandom-seed=mmap.lo -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -c ../../libbacktrace/mmap.c -o mmap.o /bin/bash ./libtool --tag=CC --mode=link cc -funwind-tables -frandom-seed=libbacktrace.la -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wmissing-format-attribute -Wcast-qual -Wno-attributes -Wpointer-arith -g -O2 -o libbacktrace.la -rpath / atomic.lo dwarf.lo fileline.lo posix.lo print.lo sort.lo state.lo backtrace.lo simple.lo elf.lo mmapio.lo mmap.lo libtool: link: rm -fr .libs/libbacktrace.a .libs/libbacktrace.la .libs/libbacktrace.lai libtool: link: ar --plugin /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so cru .libs/libbacktrace.a atomic.o dwarf.o fileline.o posix.o print.o sort.o state.o backtrace.o simple.o elf.o mmapio.o mmap.o ar: u' modifier ignored since D' is the default (see U') libtool: link: ranlib --plugin /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so .libs/libbacktrace.a libtool: link: ( cd ".libs" && rm -f "libbacktrace.la" && ln -s "../libbacktrace.la" "libbacktrace.la" ) make[2]: Leaving directory '/home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace-build' make[1]: Leaving directory '/home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace-build' make -C external/build-x86_64-linux-gnu/libbacktrace-build DESTDIR=$(pwd)/external/build-x86_64-linux-gnu install-exec make[1]: Entering directory '/home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace-build' /usr/bin/mkdir -p '/home/lightning/lightning/external/build-x86_64-linux-gnu/' /bin/bash ./libtool --mode=install /usr/bin/install -c libbacktrace.la '/home/lightning/lightning/external/build-x86_64-linux-gnu/' libtool: install: /usr/bin/install -c .libs/libbacktrace.lai /home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace.la libtool: install: /usr/bin/install -c .libs/libbacktrace.a /home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace.a libtool: install: chmod 644 /home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace.a libtool: install: ranlib --plugin /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so /home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace.a libtool: install: warning: remember to run libtool --finish /' make[1]: Leaving directory '/home/lightning/lightning/external/build-x86_64-linux-gnu/libbacktrace-build' ar libccan.a ld ccan/ccan/cdump/tools/cdump-enumstr ccan/ccan/cdump/tools/cdump-enumstr common/htlc_state.h > common/htlc_state_names_gen.h wiregen common/status_wiregen.h Traceback (most recent call last): File "/home/lightning/lightning/tools/generate-wire.py", line 27, in <module> from mako.template import Template ModuleNotFoundError: No module named 'mako' make: *** [Makefile:328: common/status_wiregen.h] Error 1 rm external/build-x86_64-linux-gnu/libwally-core-build/src/secp256k1/libsecp256k1.la

Any idea where it's coming from?

ElucGeek avatar Oct 06 '25 09:10 ElucGeek

25.9 no longer uses poetry but uv instead, check the updated install instructions https://github.com/ElementsProject/lightning/blob/v25.09/doc/getting-started/getting-started/installation.md

daywalker90 avatar Oct 06 '25 11:10 daywalker90

I followed the new instructions but still have the error with mako on RUST_PROFILE=release make install

mkdir -p /usr/local/libexec/c-lightning
mkdir -p /usr/local/libexec/c-lightning/plugins
mkdir -p /usr/local/share/man/man1
mkdir -p /usr/local/share/man/man5
mkdir -p /usr/local/share/man/man7
mkdir -p /usr/local/share/man/man8
mkdir -p /usr/local/share/doc/c-lightning
wiregen common/status_wiregen.h
Traceback (most recent call last):
  File "/home/lightning/lightning/tools/generate-wire.py", line 27, in <module>
    from mako.template import Template
ModuleNotFoundError: No module named 'mako'
make: *** [Makefile:328: common/status_wiregen.h] Error 1

ElucGeek avatar Oct 08 '25 19:10 ElucGeek

That should not happen. I think this comes from not having a clean git tree and make install trying to compile again instead of just installing. Before and after RUST_PROFILE=release uv run make check that git status doesnt show anything red and try sudo RUST_PROFILE=release make install.

If there is something red run git restore . then RUST_PROFILE=release uv run make check again and then sudo RUST_PROFILE=release make install should work.

daywalker90 avatar Oct 08 '25 19:10 daywalker90

@ElucGeek hi! have you had a chance to try daywalker's advice here?

madelinevibes avatar Dec 02 '25 03:12 madelinevibes