[issue23624] str.center inconsistent with format "^"

R. David Murray report at bugs.python.org
Mon Mar 16 16:41:15 CET 2015


R. David Murray added the comment:

Backward compatibility does not mean "matches the docs", it means "if we change this, someone's existing code is likely to break".  That does not prevent us from making at-the-margin changes in a feature release, but it is still a bar to be overcome in making such a change, and the consensus here is that it doesn't meet that bar.

Your primary argument seems to be the desire to make it easy to switch to center if the width of the field becomes a variable.  But you note yourself that you do not need to do this; format is quite capable of handing a variable width field.

So, there also does not seem to be sufficient motivation to add this feature.  If you wish to pursue this further, posting your proposal for a keyword for center and the motivation to python-ideas would be the way to proceed.  If you gather a consensus of support there, you can propose a new enhancement request issue with a link to the python-ideas discussion.  (Or, in the unlikely case that the consensus is that center's algorithm should change, we can reopen this issue.)

----------
nosy: +r.david.murray

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue23624>
_______________________________________


More information about the Python-bugs-list mailing list