clean up _reconstitute_dates and fix very rare bug where datetime formatting was incorrect