Make date parsing cleaner (with more specific error handling)