JSON spec explicitly states which characters can be used to denote numbers; Chargify also uses culture-independent settings when outputting JSON and XML. However, chargify-dot-net uses the current thread culture to parse numbers and dates/times both in JSON and XML, and sometimes fails silently when failing to parse JSON or XML.
Tests can be used to enforce 3 conditions:
Any method that parses JSON or XML values to numbers or dates/times MUST use invariant culture to do so (or otherwise explicitly specified culture settings).
Any method that parses JSON or XML values to numbers or dates/times MUST NOT fail silently (e.g. MUST NOT return 0 when input is invalid).
Any method that parses JSON or XML values to numbers or dates/times MUST succeed with any thread culture.
JSON spec explicitly states which characters can be used to denote numbers; Chargify also uses culture-independent settings when outputting JSON and XML. However, chargify-dot-net uses the current thread culture to parse numbers and dates/times both in JSON and XML, and sometimes fails silently when failing to parse JSON or XML.
Tests can be used to enforce 3 conditions:
Incomplete list of affected methods: