moin icon indicating copy to clipboard operation
moin copied to clipboard

FileNotFoundError with new namespace

Open sebix opened this issue 3 months ago • 1 comments

After adding a new namespace to the wikiconfig:

    In namespaces=
             # define custom namespaces using the default backend
    +        "dev": "internal",
    In backends=
    +        "internal": uri,

We're unable to create a page in the namespace. Creating dev/Home results in an Internal Server Error. The server log shows:

FileNotFoundError: [Errno 2] No such file or directory: '/home/moin/instance/wiki/data/internal/data/489b1636d3fe46239950ff466eaf105b'

I searched for instructions in the docs how to initialize the backend:

  • https://moin-20.readthedocs.io/en/latest/intro/features.html#storage-backend-types
  • https://moin-20.readthedocs.io/en/latest/admin/configure.html#stores-backend
  • https://moin-20.readthedocs.io/en/latest/man/moin.html#moin-interface

But haven't found anything yet.

The command moin index-create returns

2025-09-29 17:43:08,640 ERROR moin.cli.maint.index:49 Error: wiki index exists. Please check and destroy index before running index-create

Manually creating the directories

  • /home/moin/instance/wiki/data/internal/
  • /home/moin/instance/wiki/data/internal/data/
  • /home/moin/instance/wiki/data/internal/meta/

worked around the problem.

sebix avatar Sep 29 '25 16:09 sebix

We can check and create the directory structure each time the server is started. Are there any recommendations?

UlrichB22 avatar Oct 30 '25 10:10 UlrichB22