Please describe the problem.
Originally blamed datalad but apparently git annex add --json
does not include error message in the json output. In our case it was due to permission issues.
$ git annex add more --json
more: setFileMode: permission denied (Operation not permitted)
{"command":"add","success":false,"file":"more"}
git-annex: add: 1 failed
If you use --json-error-messages it does work, at least in this permissions error case. So nothing more needs to be done. --Joey
From "any program parsing stderr for json would somehow have to deal with this non-json that could be mixed up with it, which seems very hard" at another bug page , it sounds like parsing the output of
--json-error-messages
might not be reliable?