Closed EricdeWaal closed 3 years ago
I see your issue. I suppose it's caused by the fact that after adding your entry the server's default values are skipped what brings up the error.
Generally, we only store new or changed values to the database to avoid unreachable lagacy values in db. The config manager merges these on startup.
The config ui is waiting for volunteers to be improved :smiley:
I hope it can be solved. We are now a bit in between the config screen and the config file. Looking at how a CMS like Joomla, or a remote server control system like Webmin, do this: they edit all elements in config files from the gui, and store the rest (much more) in the database only. IMHO that is an ideal situation.
It can be solved for sure.
Other solutions have different foundations. Gerbera (or mediatomb) started long before and has to run on users systems but we always appreciate ideas and support.
You say it
has to run on users systems
which is obvious and should present no problems, given the fact that Gerbera already entirely depends upon the database.
The gui is just a way to make config more modern and less 'nerdy', more suitable for normal mainstream users who do not want to edit a file with one eye on an extensive manual to figure out what could be in there, why and how. They want checkboxes, dropdowns, or, like in the above issue, a field to enter a directory to include or exclude. Click 'Save' and done. User experience ...
That's the main reason why we started it, but sometimes other things are more urgent - within gerbera and the life that earns our money. It's on the list!
Great, thanks!
I wonder about /import/system-directories/add-path[26]
becaue it means that you have more values in your config than the default ones. In my case it is /import/system-directories/add-path[15]
and it does not break the UI, but it does not work as expected also.
I have experimented with the database config before, and when it did not work I added the directories to config.xml. There are 26 entries, could it be that the number for the new one should have been 27?
If there are exactly 26 the new entry is [26]
because the first is [0]
as i all C
based programming languages!
OK, so that was not the problem, there are exactly 26 entries in config.xml
I added a PR which I hope fixes your issue. Can you clone https://github.com/KarlStraussberger/gerbera/tree/config-dafault-handling and give it a try, please?
@EricdeWaal did you have a glance at the fix?
Hi, no, sorry, I had a hard disk failure on my home server, I am reinstalling everything which might take a couple of days. Wiill report asap
I've been a bit better off. Only a power wire burnt last week and the raid lost two disks which could be recovered.
Hi, I'm more or less up and running again. As a simple user who just gets builds from Deb Multimedia I have no idea how to compile the code in your fix, sorry!
There's a description in the docs
https://docs.gerbera.io/en/stable/compile.html
That's the best way to start your carreer as software developer.
Hi,
Using the GUI config screen, I added a directory: /authentic-theme to hide it in Filesystem. That worked, but it instantly makes the config screen inaccesible.
'systemctl status gerbera' shows: "May 13 08:50:24 NAS gerbera[3571]: 2021-05-13 08:50:24 error: unhandled option /import/system-directories/add-path[26] != /import/system-directories"
The database table grb_config_value shows these 2 records: item | key | item_value | status /import/system-directories/add-path[26] | /import/system-directories | | manual /import/system-directories/add-path[26]/attribute::name | /import/system-directories | /authentic-theme | unchanged
Removing these records restored the previous situation. PLease check!
And it seems that none of the config.xml settings are copied to the database at update or start. Doing so and make the database/config screen leading, except maybe for the database access settings, would help a lot to make configuration easier, offerings dropdown choices for options, etc!