Build issue on Debian bookworm
Following the instructions in README.md:
$ lektor build
Updating packages in /home/james/.cache/lektor/packages/75ac3fa2d44bb5f50f55be732f38c9fe for project
error: externally-managed-environment
× This environment is externally managed
╰─> To install Python packages system-wide, try apt install
python3-xyz, where xyz is the package you are trying to
install.
If you wish to install a non-Debian-packaged Python package,
create a virtual environment using python3 -m venv path/to/venv.
Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
sure you have python3-full installed.
If you wish to install a non-Debian packaged Python application,
it may be easiest to use pipx install xyz, which will manage a
virtual environment for you. Make sure you have pipx installed.
See /usr/share/doc/python3.11/README.venv for more information.
note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
hint: See PEP 668 for the detailed specification.
Traceback (most recent call last):
File "/usr/bin/lektor", line 8, in <module>
sys.exit(main())
^^^^^^
File "/usr/lib/python3/dist-packages/lektor/cli.py", line 621, in main
cli.main(args=args, prog_name=name)
File "/usr/lib/python3/dist-packages/click/core.py", line 1055, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/click/core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/click/core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/click/decorators.py", line 84, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/lektor/cli.py", line 127, in build_cmd
ctx.load_plugins(extra_flags=extra_flags)
File "/usr/lib/python3/dist-packages/lektor/cli_utils.py", line 135, in load_plugins
load_packages(self.get_env(extra_flags=extra_flags), reinstall=reinstall)
File "/usr/lib/python3/dist-packages/lektor/packages.py", line 323, in load_packages
update_cache(
File "/usr/lib/python3/dist-packages/lektor/packages.py", line 291, in update_cache
install_local_package(
File "/usr/lib/python3/dist-packages/lektor/packages.py", line 125, in install_local_package
raise RuntimeError("Failed to install local package")
RuntimeError: Failed to install local package