Issue 7847: Remove 'python -U' or document it (original) (raw)

This issue has been migrated to GitHub: https://github.com/python/cpython/issues/52095

classification

Title: Remove 'python -U' or document it
Type: Stage: patch review
Components: Versions: Python 2.7, Python 2.6

process

Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: barry Nosy List: barry, georg.brandl, lemburg, loewis
Priority: normal Keywords: needs review, patch

Created on 2010-02-03 17:35 by barry, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
7847.patch barry,2010-02-04 10:27
7847-2.patch barry,2010-02-05 18:21
Messages (9)
msg98791 - (view) Author: Barry A. Warsaw (barry) * (Python committer) Date: 2010-02-03 17:35
Python 2.x supports a -U flag which has the effect largely the same as 'from __future__ import unicode_literals'. However -U is undocumented anywhere except import.c. We should either remove -U support from Python 2.7 or document it (and indicate in that documentation that the future import is preferred).
msg98792 - (view) Author: Marc-Andre Lemburg (lemburg) * (Python committer) Date: 2010-02-03 17:55
Barry A. Warsaw wrote: > > New submission from Barry A. Warsaw <barry@python.org>: > > Python 2.x supports a -U flag which has the effect largely the same as 'from __future__ import unicode_literals'. However -U is undocumented anywhere except import.c. We should either remove -U support from Python 2.7 or document it (and indicate in that documentation that the future import is preferred). +1 on removing it. It has been deliberately been undocumented since Python 2.2 in order to be able to phase out its use and finally remove it.
msg98795 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2010-02-03 19:47
I fail to see the point. This bug was fixed in Python 3. Why risk breaking something in the last 2.x release?
msg98824 - (view) Author: Barry A. Warsaw (barry) * (Python committer) Date: 2010-02-04 10:27
This is really all I'm thinking about.
msg98856 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2010-02-04 20:58
I'm +0 on such a change - I don't think it makes anything better (it will only cause more users asking what this is, why it was added, and demand that something should be done about it). Feel free to commit it, anyway.
msg98862 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2010-02-05 01:00
If you document -X, you should also document -J.
msg98891 - (view) Author: Barry A. Warsaw (barry) * (Python committer) Date: 2010-02-05 18:21
Good point Georg. See updated patch.
msg98892 - (view) Author: Barry A. Warsaw (barry) * (Python committer) Date: 2010-02-05 18:22
Martin, thanks.
msg98894 - (view) Author: Barry A. Warsaw (barry) * (Python committer) Date: 2010-02-05 18:52
trunk: r77992 py26: r77993
History
Date User Action Args
2022-04-11 14:56:57 admin set github: 52095
2010-02-05 18:52:46 barry set status: open -> closedresolution: fixedmessages: +
2010-02-05 18:22:18 barry set messages: +
2010-02-05 18:21:48 barry set files: + 7847-2.patchmessages: +
2010-02-05 01:00:29 georg.brandl set nosy: + georg.brandlmessages: +
2010-02-04 20:58:55 loewis set assignee: loewis -> barrymessages: +
2010-02-04 10:27:07 barry set files: + 7847.patchversions: + Python 2.6messages: + keywords: + needs review, patchstage: patch review
2010-02-03 19:47:58 loewis set messages: +
2010-02-03 17:55:02 lemburg set nosy: + lemburgmessages: +
2010-02-03 17:45:32 georg.brandl set assignee: loewisnosy: + loewis
2010-02-03 17:35:06 barry create