Closed andrew-stevenson-sociomantic closed 4 years ago
@Geod24 FYI
Well its not really that important apart from stopping it looking odd. If other things happen to have depended on the format always using 0 padding then that is really more a bug with them.
The real problem was the un-noticed behavioural change - but that was presumably accidental. A unittest might have caught that but given this method now largely just calls sformat (presumably already tested) we are really only testing no one changes the format string - and that seems unlikely for anyone to do without due consideration. If someone does decide to re-write it again then comparing old a new behaviour can be a task for them.
Oops, good catch!
A unittest might have caught that
There was no unittest in place for those classes at the time. So the first thing I did was to introduce an unittest, but the value I used did not exhibit the issue.
Reverts behavioural change from dcf428aa