You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The journal reports:
Invalid escape sequences in line, correcting: "..."
and then prints the line exactly as it was written in the service file!
At least printing the corrected line would allow a diff to discover what text triggered the error message!
More than that, if the "invalid escape sequence" can be "corrected", then, in what way is the line "invalid"? That's crazy talk.
man systemd.service has a Table 2 of "C escapes supported in command lines and environment variables", but is pretty vague about how the quote escapes should be applied, or whether they need to be applied at all. Generally, they are not needed, making the quoting rules rather "opaque".
Trial and error shows that systemd is a bit more particular about escaping the backslash.
The text was updated successfully, but these errors were encountered:
well, we try to fix the borked strings for you, to be nice (in particular as the precise semantics originally were quite broken) but we do log about them, as there are some ambiguities left, and we'd prefer if the users would write the correct strings in the first place.
But yeah, we should probably log the fixed version, indeed.
Can you provide the exact setting that caused this warning for you?
This is the corrected version: ... |sed -n "s/.*$$i@\\(.*\\)\\.service/\\1/p" ...
The parser was complaining about the backslashes. Really, it is not a big deal to escape backslashes, it's just that this should be documented.
And it is still unclear why the parser would both complain about and also "fix" the escaped backslashes. That doesn't seem to make any sense. If it was "fixed", then why complain?
The journal reports:
Invalid escape sequences in line, correcting: "..."
and then prints the line exactly as it was written in the service file!
At least printing the corrected line would allow a diff to discover what text triggered the error message!
More than that, if the "invalid escape sequence" can be "corrected", then, in what way is the line "invalid"? That's crazy talk.
man systemd.service has a Table 2 of "C escapes supported in command lines and environment variables", but is pretty vague about how the quote escapes should be applied, or whether they need to be applied at all. Generally, they are not needed, making the quoting rules rather "opaque".
Trial and error shows that systemd is a bit more particular about escaping the backslash.
The text was updated successfully, but these errors were encountered: