pgbackrest
pgbackrest copied to clipboard
help fails if configuration is faulty
Please provide the following information when submitting an issue (feature requests or general comments can skip this):
-
pgBackRest version: 2.48
-
PostgreSQL version: n/a
-
Operating system/version - if you have more than one server (for example, a database server, a repository host server, one or more standbys), please specify each: Debian stable
-
Did you install pgBackRest from source or from a package?
package
- Describe the issue:
root@host:~# pgbackrest help backup
ERROR: [031]: configuration file contains duplicate options ('repo-path', 'repo1-path') in section '[global]'
I think help should always work, even if the configuration is faulty, but maybe that is too difficult to achieve with how the pgBackRest CLI is implemented.
Well, yeah, that's pretty terrible.
But you are correct that help relies on the configuration module to provide lists of options per command, defaults, current settings, etc.
Even so, there should be some sort of fallback that gives basic help even when the configuration is broken.
This is fixed in #2395 so closing. Feel free to comment on the patch.