Re: Bool variable with json.dumps

2019-09-15 Thread Hongyi Zhao
On Sun, 15 Sep 2019 19:36:20 +1000, Cameron Simpson wrote: > Because that's how the true value is spelt in JavaScript. You _are_ > aware that JSON is "JavaScript Object Notation", are you not? So > json.dumps translates Python values into JavaScript syntax. > > This is likely to be the same reaso

Re: Bool variable with json.dumps

2019-09-15 Thread Cameron Simpson
On 15Sep2019 09:15, Hongyi Zhao wrote: var = True when json.dumps on it, it will become the form `true' Why? Because that's how the true value is spelt in JavaScript. You _are_ aware that JSON is "JavaScript Object Notation", are you not? So json.dumps translates Python values into JavaScr

Bool variable with json.dumps

2019-09-15 Thread Hongyi Zhao
Hi, var = True when json.dumps on it, it will become the form `true' Why? -- https://mail.python.org/mailman/listinfo/python-list