[issue40971] Documentation still mentions 'u' string formatting option
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
New submission from Gordon P. Hemsley <gphemsley@gphemsley.org>: https://docs.python.org/3/library/stdtypes.html#old-string-formatting still lists the 'u' string formatting option, described as "Obsolete type – it is identical to 'd'." and linking to PEP 237. However, testing indicates that Python 3 does not support a 'u' option and my archaeology suggests that such support was removed in Python 2.4. It seems this has flown under the radar for quite some time. ---------- assignee: docs@python components: Documentation messages: 371474 nosy: alexandre.vassalotti, benjamin.peterson, berker.peksag, christian.heimes, docs@python, eli.bendersky, ezio.melotti, georg.brandl, gphemsley, martin.panter, ncoghlan, rhettinger priority: normal severity: normal status: open title: Documentation still mentions 'u' string formatting option type: behavior versions: Python 3.10, Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue40971> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Change by Benjamin Peterson <benjamin@python.org>: ---------- keywords: +easy stage: -> needs patch _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue40971> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Shubham Upreti <shubham.upreti@gmail.com> added the comment: Should i take this issue? ---------- nosy: +shubh07 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue40971> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Petr Viktorin <encukou@gmail.com> added the comment: AFAICS, Python 3 suports '%u' for printf-style formatting: Python 3.8.3 (default, May 29 2020, 00:00:00) [GCC 10.1.1 20200507 (Red Hat 10.1.1-1)] on linux Type "help", "copyright", "credits" or "license" for more information.
'%u' % 6 '6'
What am I missing? ---------- nosy: +petr.viktorin _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue40971> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Petr Viktorin <encukou@gmail.com> added the comment: I'm closing the issue. Please comment or reopen if I missed something. ---------- resolution: -> not a bug stage: needs patch -> resolved status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue40971> _______________________________________
participants (4)
-
Benjamin Peterson
-
Gordon P. Hemsley
-
Petr Viktorin
-
Shubham Upreti