Why can't sample python scripts open from the official page?

There is a page on the official website that shows examples of Python scripts for solving problems in libreOffice, but they do not work.
https://api.libreoffice.org/examples/examples.html#python_examples
Where can I see these scripts?

Tools>Macros>Organize>>Python shows several examples shipped with your office suite.

The first 5 links seem to work.
.
The following give a 404 error. It seems the folder is missing on the server.

https://api.libreoffice.org/examples/python/Text/

Same for
https://api.libreoffice.org/examples/python/Spreadsheet/

Help seems to have completly different examples
https://help.libreoffice.org/latest/en-US/text/sbasic/python/python_examples.html?&DbPAR=SHARED&System=UNIX
.
A quick check on archive.org gives no match in any snapshot…

Looks like there is a number of dead links there. Also some seem to be extensions.
Another resource for python is Live LibreOffice Python UNO Examples.
It is even possible to run all the examples right in your web browser (via GitHub and Code Spaces).

If I had more time I would port some of the example over there.

1 Like