gitoxide should be as lenient as git when parsing tags so it can be used on the exotic git objects that one can find.
If the timestamp is garbage or missing, it should set it to zero instead of failing.
Git behavior
git is very lenient when parsing signatures: on any sort of malformed timestamp, it simply sets the timestamp to 0.
See implementation here
Steps to reproduce 🕹
To observe that this behaviour exists in the wild:
Current behavior 😯
In the wild, some tags exist that don't have a timestamp on the tagger line. For instance this one: https://kernel.googlesource.com/pub/scm/network/bridge/bridge-utils/+/refs/tags/ChangeLog
Expected behavior 🤔
gitoxide should be as lenient as git when parsing tags so it can be used on the exotic git objects that one can find. If the timestamp is garbage or missing, it should set it to zero instead of failing.
Git behavior
git is very lenient when parsing signatures: on any sort of malformed timestamp, it simply sets the timestamp to 0. See implementation here
Steps to reproduce 🕹
To observe that this behaviour exists in the wild:
To repro the behaviour with gitoxide
I will share a couple of new unit tests that show that gitoxide fails to parse.