[issue42434] Library json, file json/encoder.py: Function floatstr should be a class-level function.

2020-11-22 Thread Roundup Robot


Change by Roundup Robot :


--
keywords: +patch
nosy: +python-dev
nosy_count: 1.0 -> 2.0
pull_requests: +22351
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23459

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42434] Library json, file json/encoder.py: Function floatstr should be a class-level function.

2020-11-22 Thread David Salač

New submission from David Salač :

The logic as it is implemented now does not allow to user to override floatstr 
function. That makes things enormously inconvenient for people who need any 
different of behaviour (for example return string values defining Infinity, NaN 
or -Infinity). If it was moved on the class-level, it would easier because it 
makes floatstr to be a class-level function.

--
components: Library (Lib)
files: encoder.py
messages: 381609
nosy: salacdav
priority: normal
severity: normal
status: open
title: Library json, file json/encoder.py: Function floatstr should be a 
class-level function.
type: enhancement
versions: Python 3.10, Python 3.6, Python 3.7, Python 3.8, Python 3.9
Added file: https://bugs.python.org/file49613/encoder.py

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com