colon is not allowed inside message strings in hooks #708
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What I'm trying to do and why
Display progress on console using the provided hooks.
Steps to reproduce (if a bug)
This cause the error when parsing the config file:
but this does not (apparently the colon in the message string is not escaped by the parser
Actual behavior (if a bug)
Expected behavior (if a bug)
Using a colon in a string should be ok.
Other notes / implementation ideas
Environment
borgmatic version: borgmatic-1.7.10-1.1.noarch
Use
sudo borgmatic --versionorsudo pip show borgmatic | grep ^Versionborgmatic installation method: opensuse rpm package
Borg version: borgbackup-1.2.4-1.1.x86_64
Use
sudo borg --versionPython version: NA
Use
python3 --versionDatabase version (if applicable): NA
Use
psql --versionormysql --versionon client and server.operating system and version: Opensuse tumbleweed 20230601
Thanks for reporting this! I've confirmed the behavior locally, but I'll have to dig in to see what's going on.
Unfortunately, it looks like this is simply a YAML limitation; it's parsing the string with a colon as a mapping type. Here are two work-arounds though:
What I'll do is change all the examples to quote the entire line and also document this issue. But beyond that, I don't think there's much I can do. Thanks!