If several branches/tags point to the same repo catkin_generate_changelog fails because it interprets the first-line of the output of the command
> /usr/bin/git log <refname> --format=format:%H
warning: refname '<refnam>' is ambiguous
987a9953e3ce3279a40f81a1a4039310bd08761b
as a valid sha and fails on the next command:
> /usr/bin/git log warning: refname '3.0.1' is ambiguous. -n 1 --format=format:%B
ERROR: Could not fetch commit message:
fatal: invalid object name 'warning'.
To fix this, the warning warning: refname '<refnam>' is ambiguous should not be part of the output but of stderr of the executed command.
Suggested PR: #348