[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-19 Thread Dong-hee Na
Dong-hee Na added the comment: Oh, I read the Serhiy Storchaka 's comment just right now. -- ___ Python tracker ___ ___ Python-bugs-li

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-19 Thread Dong-hee Na
Dong-hee Na added the comment: I would like to solve this issue. Is there any other way than casting specifically for the bool object? (e.g For general ways?) -- nosy: +corona10 ___ Python tracker

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-19 Thread Dong-hee Na
Changes by Dong-hee Na : -- pull_requests: -1305 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-19 Thread Dong-hee Na
Changes by Dong-hee Na : -- pull_requests: -1303 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-18 Thread Dong-hee Na
Changes by Dong-hee Na : -- pull_requests: +1305 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This issue is not easy, it needs a thoughtful design before starting coding. I agree with Xiang's analysis and proposed solutions. But if just convert numbers to float we can get an overflow for large integers or lost precision in case of Decimal. The consum

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-18 Thread Dong-hee Na
Changes by Dong-hee Na : -- pull_requests: +1303 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-13 Thread Xiang Zhang
Xiang Zhang added the comment: boolean is not quoted since in Python it's a subclass of int so True and False are numeric. This is also the case with numeric objects defining __int__ or __float__ but doesn't get a corresponding string representation. Since QUOTE_NONNUMERIC will converts data t

[issue30046] csv: Inconsistency re QUOTE_NONNUMERIC

2017-04-11 Thread Thomas Lotze
New submission from Thomas Lotze: A csv.writer with quoting=csv.QUOTE_NONNUMERIC does not quote boolean values, which makes a csv.reader with the same quoting behaviour fail on that value: csv.py -- import csv import io f = io.StringIO() writer = csv.writer(f, quoting=csv.Q