Date/Time serialization uses current culture
filipnavara opened this issue · 6 comments
There are multiple calls to DateTime.TryParse
, DateTimeOffset.TryParse
and the respective ToString
counterparts without a specified culture parameter. This implies a current culture is used instead of CultureInfo.InvariantCulture
which would be an obvious choice for data interchange format.
Notably, the culture can use a non-Gregorian calendar, such as Persian one, which will likely result in incorrectly parsed/serialized data.
Thanks for raising this @filipnavara
Any chance you'd be willing to submit a PR to resolve this?
Any chance you'd be willing to submit a PR to resolve this?
Not planning to do so any time soon. I still have other pressing issues on my backlog.
Transferring issue as part of #238
@andrueastman Can I take it? The issue with current culture is also for numbers. So I can fix datetime and numbers and prepare some unit tests. Once you decide how to resolve #283, it can be implemented in this ticket.
As a general rule of thumb, if issues are not assigned to anyone, nobody from our team is working on them (as in writing code to fix it, we might still be talking about it, etc...). We'll be more than happy to see a PR coming to address that.
Please go ahead. @MartinM85