From report at bugs.python.org Sun Jan 1 12:18:45 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 01 Jan 2012 11:18:45 +0000 Subject: [docs] [issue13683] Docs in Python 3:raise statement mistake In-Reply-To: <1325259254.7.0.957455919083.issue13683@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 420e01156272 by Sandro Tosi in branch '3.2': Issue #13683: raise with no exception in scope throws a RuntimeError; fix by Ramchandra Apte http://hg.python.org/cpython/rev/420e01156272 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 1 12:19:22 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 01 Jan 2012 11:19:22 +0000 Subject: [docs] [issue13683] Docs in Python 3:raise statement mistake In-Reply-To: <1325259254.7.0.957455919083.issue13683@psf.upfronthosting.co.za> Message-ID: <1325416762.58.0.0504389468304.issue13683@psf.upfronthosting.co.za> Changes by Sandro Tosi : ---------- nosy: +sandro.tosi resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 1 12:58:49 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 01 Jan 2012 11:58:49 +0000 Subject: [docs] [issue13690] Add DEBUG flag to documentation of re.compile In-Reply-To: <1325355977.96.0.0770563449241.issue13690@psf.upfronthosting.co.za> Message-ID: <1325419129.78.0.964962988019.issue13690@psf.upfronthosting.co.za> Changes by Sandro Tosi : ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python, sandro.tosi resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 1 23:43:02 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 01 Jan 2012 22:43:02 +0000 Subject: [docs] [issue13302] Clarification needed in C API arg parsing In-Reply-To: <1320057763.71.0.58387430149.issue13302@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset b2b7104691c9 by Sandro Tosi in branch '2.7': Issue #13302: backport part of 3ed28f28466f http://hg.python.org/cpython/rev/b2b7104691c9 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 1 23:44:21 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 01 Jan 2012 22:44:21 +0000 Subject: [docs] [issue13302] Clarification needed in C API arg parsing In-Reply-To: <1320057763.71.0.58387430149.issue13302@psf.upfronthosting.co.za> Message-ID: <1325457861.61.0.808058917465.issue13302@psf.upfronthosting.co.za> Sandro Tosi added the comment: Thanks Antoine for the pointer. ---------- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed versions: -Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 2 06:48:10 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 02 Jan 2012 05:48:10 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" Message-ID: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> New submission from Bo?tjan Mejak : Please visit the following link and fix the below text: http://docs.python.org/library/unittest.html#unittest.TestCase.assertEqual Changed in version 2.7: Added the automatic calling of >>>type-specific<<< equality function. Just add the hyphen. Thanks. ---------- assignee: docs at python components: Documentation messages: 150451 nosy: Retro, docs at python priority: normal severity: normal status: open title: "type specific" to "type-specific" versions: Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 2 16:39:01 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 02 Jan 2012 15:39:01 +0000 Subject: [docs] [issue13690] Add DEBUG flag to documentation of re.compile In-Reply-To: <1325355977.96.0.0770563449241.issue13690@psf.upfronthosting.co.za> Message-ID: <1325518741.33.0.249266573548.issue13690@psf.upfronthosting.co.za> ?ric Araujo added the comment: > Display debug information about compiled expression. IMO it would be helpful to define ?display? more precisely (e.g. ?Print debugging information on stdout during pattern compilation?). ---------- nosy: +eric.araujo _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 2 16:58:35 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 02 Jan 2012 15:58:35 +0000 Subject: [docs] [issue13402] Document absoluteness of sys.executable In-Reply-To: <1321289437.84.0.982753479785.issue13402@psf.upfronthosting.co.za> Message-ID: <1325519915.46.0.381333680236.issue13402@psf.upfronthosting.co.za> ?ric Araujo added the comment: This discussion seems relevant: http://mail.python.org/pipermail/python-dev/2006-March/062453.html (it talks about the meaning of sys.executable, special cases such as embedded Python and functions that implement it (so we can have a look at that code)). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 2 18:16:55 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 02 Jan 2012 17:16:55 +0000 Subject: [docs] [issue13561] os.listdir documentation should mention surrogateescape In-Reply-To: <1323395400.31.0.796436036954.issue13561@psf.upfronthosting.co.za> Message-ID: <1325524615.2.0.0566884090746.issue13561@psf.upfronthosting.co.za> ?ric Araujo added the comment: Patch looks good, apart from a missing ?the?, but I think it should be expanded: Right now it tells that surrogateescape is used, but IMO it would be more useful if it also mentioned practical implications, i.e. what Michael ?The Beard? Foord says in the first message. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 2 18:34:38 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 02 Jan 2012 17:34:38 +0000 Subject: [docs] [issue13663] pootle.python.org is outdated. In-Reply-To: <1324903809.07.0.39088932351.issue13663@psf.upfronthosting.co.za> Message-ID: <1325525678.83.0.336132749181.issue13663@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- nosy: +ezio.melotti _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 2 23:04:23 2012 From: report at bugs.python.org (Eric V. Smith) Date: Mon, 02 Jan 2012 22:04:23 +0000 Subject: [docs] [issue13685] argparse does not sanitize help strings for % signs In-Reply-To: <1325284167.16.0.584942168313.issue13685@psf.upfronthosting.co.za> Message-ID: <1325541863.16.0.936835857227.issue13685@psf.upfronthosting.co.za> Eric V. Smith added the comment: In case I wasn't clear, I mean that the help string supports %-formatting variable expansion, such as "%(default)s". I think it would be good if a sentence were added to the end of the "help" section, saying something like: Because the help string supports %-formatting, if you want a literal "%" to appear in the help string, you must escape it as "%%". ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 02:19:23 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Tue, 03 Jan 2012 01:19:23 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1325553563.26.0.535848483761.issue13695@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Also http://guide.python-distribute.org/quickstart.html#lay-out-your-project needs to have the first sentence fixed: "python" to "Python" and http://docs.python.org/library/functools.html#functools.cmp_to_key needs to have the word "Py3.x" fixed to "Python 3" (note: not to "Python 3.x" because functools.reduce() function also has the word "Python 3", so be consistent) ---------- nosy: +georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 02:29:30 2012 From: report at bugs.python.org (Ezio Melotti) Date: Tue, 03 Jan 2012 01:29:30 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1325554170.19.0.0368559695718.issue13695@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- nosy: +ezio.melotti stage: -> needs patch type: -> enhancement versions: -Python 3.1, Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 02:59:59 2012 From: report at bugs.python.org (R. David Murray) Date: Tue, 03 Jan 2012 01:59:59 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325555998.99.0.979221409228.issue13700@psf.upfronthosting.co.za> R. David Murray added the comment: The first argument to authenticate must be bytes. This is not well documented. It might also be a bug, since I'm not sure anyone has done a thorough audit of what should be bytes and what should be string in imaplib. 3.1 no longer gets bug fixes, so I'm removing it from versions. Likewise I remove 3.4 since that applies only to changes that will *not* be put in 3.3 for some reason. ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python, r.david.murray versions: -Python 3.1, Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 03:11:10 2012 From: report at bugs.python.org (Erno Tukia) Date: Tue, 03 Jan 2012 02:11:10 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325556670.67.0.027361597351.issue13700@psf.upfronthosting.co.za> Erno Tukia added the comment: The same problems exists even if I use b"PLAIN" as the first argument in authenticate(). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 03:24:24 2012 From: report at bugs.python.org (R. David Murray) Date: Tue, 03 Jan 2012 02:24:24 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325557464.39.0.305235489566.issue13700@psf.upfronthosting.co.za> R. David Murray added the comment: Gah, I was looking at the wrong source code when I wrote that. A string first argument is indeed valid. I'm not sure where the problem is coming from since the internal CRAM_MD5 returns a string and that seems to work... ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 03:59:53 2012 From: report at bugs.python.org (Erno Tukia) Date: Tue, 03 Jan 2012 02:59:53 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325559593.36.0.524552869569.issue13700@psf.upfronthosting.co.za> Erno Tukia added the comment: File "/usr/lib/python3.1/imaplib.py", line 1257, in encode e = binascii.b2a_base64(t) imaplib._Authenticator.encode() calls binascii.b2a_base64() function. In Python 2.6 that function returns a string, and in Python 3.1 it returns bytes. What is returned from b2a_base64() function is later in the encode() function concatenated with a string, with bytes that is not possible. Should binascii.b2a_base64() return a string (2.6) or bytes (3.1)? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 04:18:02 2012 From: report at bugs.python.org (R. David Murray) Date: Tue, 03 Jan 2012 03:18:02 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325560682.04.0.164895039767.issue13700@psf.upfronthosting.co.za> R. David Murray added the comment: Bytes definitely. We hashed that out a while ago. My point is that CRAM_MD5 login calls authenticate, and its authenticator returns a string, just like your example does. So it ought to be going through the same code path. I haven't followed the logic in detail, though, so there must be some difference...I'm pretty sure the MD5 login has a test now (but not 100% sure...) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 16:06:16 2012 From: report at bugs.python.org (Erno Tukia) Date: Tue, 03 Jan 2012 15:06:16 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325603176.26.0.392799478167.issue13700@psf.upfronthosting.co.za> Erno Tukia added the comment: In Python 2.6 PLAIN authentication works, in Python 3.1 not. Lib/test/test_imaplib.py does not test IMAP4.authenticate() or IMAP4.login_cram_md5() functions, only IMAP4.login(). I would still like to go back to imaplib._Authenticator.encode() function. The function is below. # inp = authobject(response) def encode(self, inp): oup = '' while inp: if len(inp) > 48: t = inp[:48] inp = inp[48:] else: t = inp inp = '' e = binascii.b2a_base64(t) if e: oup = oup + e[:-1] return oup binascii.b2a_base64() takes bytes, so inp must therefore be bytes, and returns bytes (Python 3). Then str + bytes (out + e[:-1]) fails. The fix would then be changing oup = oup + e[:-1] to oup = oup + e[:-1].decode() ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 16:41:32 2012 From: report at bugs.python.org (Erno Tukia) Date: Tue, 03 Jan 2012 15:41:32 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325605292.67.0.148395473196.issue13700@psf.upfronthosting.co.za> Erno Tukia added the comment: I tried to fix the problem and the correct fix is to change oup = '' to oup = b'' in imaplib._Authenticator.encode() function, and not what I suggested in my previous post. After changing that PLAIN authentication works. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 17:20:58 2012 From: report at bugs.python.org (R. David Murray) Date: Tue, 03 Jan 2012 16:20:58 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325607658.51.0.851761875258.issue13700@psf.upfronthosting.co.za> R. David Murray added the comment: Would you be interested in providing a patch that includes tests? I think Antoine set up a test framework for testing the login as part of issue 4471. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 17:43:43 2012 From: report at bugs.python.org (Jeff Yurkiw) Date: Tue, 03 Jan 2012 16:43:43 +0000 Subject: [docs] [issue13685] argparse does not sanitize help strings for % signs In-Reply-To: <1325284167.16.0.584942168313.issue13685@psf.upfronthosting.co.za> Message-ID: <1325609023.14.0.716583718235.issue13685@psf.upfronthosting.co.za> Jeff Yurkiw added the comment: That would probably work too. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 18:39:11 2012 From: report at bugs.python.org (Roundup Robot) Date: Tue, 03 Jan 2012 17:39:11 +0000 Subject: [docs] [issue9349] document argparse's help=SUPPRESS In-Reply-To: <1279892796.46.0.177553560445.issue9349@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 572ddf2770bc by Sandro Tosi in branch '3.2': Issue #9349: add argparse.SUPPRESS to help doc http://hg.python.org/cpython/rev/572ddf2770bc New changeset 17b7b856cbe8 by Sandro Tosi in branch '2.7': Issue #9349: add argparse.SUPPRESS to help doc http://hg.python.org/cpython/rev/17b7b856cbe8 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 18:41:39 2012 From: report at bugs.python.org (Sandro Tosi) Date: Tue, 03 Jan 2012 17:41:39 +0000 Subject: [docs] [issue9349] document argparse's help=SUPPRESS In-Reply-To: <1279892796.46.0.177553560445.issue9349@psf.upfronthosting.co.za> Message-ID: <1325612499.29.0.771359298125.issue9349@psf.upfronthosting.co.za> Changes by Sandro Tosi : ---------- nosy: +sandro.tosi resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 21:42:40 2012 From: report at bugs.python.org (Erno Tukia) Date: Tue, 03 Jan 2012 20:42:40 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325623360.44.0.245579357892.issue13700@psf.upfronthosting.co.za> Erno Tukia added the comment: Here's a patch with test. I am not an IMAP guru, so please verify my patch. ---------- keywords: +patch Added file: http://bugs.python.org/file24132/issue13700.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 22:47:15 2012 From: report at bugs.python.org (Erno Tukia) Date: Tue, 03 Jan 2012 21:47:15 +0000 Subject: [docs] [issue13700] imaplib.IMAP4.authenticate authobject fails with PLAIN mechanism In-Reply-To: <1325553089.14.0.504978991098.issue13700@psf.upfronthosting.co.za> Message-ID: <1325627235.83.0.275841447291.issue13700@psf.upfronthosting.co.za> Erno Tukia added the comment: Here's another patch that should fix the CRAM-MD5 authentication. My previous patch is required with this one. The patch includes a test. ---------- Added file: http://bugs.python.org/file24134/cram_md5.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 23:13:08 2012 From: report at bugs.python.org (Sinisa Segvic) Date: Tue, 03 Jan 2012 22:13:08 +0000 Subject: [docs] [issue13705] Raising exceptions from finally works better than advertised in the documentation Message-ID: <1325628788.79.0.655122317093.issue13705@psf.upfronthosting.co.za> New submission from Sinisa Segvic : Hi, The documentation says: """ If the finally clause raises another exception (...) the saved exception is lost. """ This does not appear to be true. In the example below the backtrace shows both exceptions. >>> import math >>> try: ... 1/0 ... finally: ... math.sqrt(-1) ... Traceback (most recent call last): File "", line 2, in ZeroDivisionError: division by zero During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 4, in ValueError: math domain error Cheers, Sini?a ---------- assignee: docs at python components: Documentation messages: 150544 nosy: docs at python, ssegvic priority: normal severity: normal status: open title: Raising exceptions from finally works better than advertised in the documentation type: enhancement versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 23:24:10 2012 From: report at bugs.python.org (Sinisa Segvic) Date: Tue, 03 Jan 2012 22:24:10 +0000 Subject: [docs] [issue13705] Raising exceptions from finally works better than advertised in the documentation In-Reply-To: <1325628788.79.0.655122317093.issue13705@psf.upfronthosting.co.za> Message-ID: <1325629450.42.0.764871693607.issue13705@psf.upfronthosting.co.za> Sinisa Segvic added the comment: Link to the documentation: http://docs.python.org/py3k/reference/compound_stmts.html#id2 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 3 23:31:02 2012 From: report at bugs.python.org (Roundup Robot) Date: Tue, 03 Jan 2012 22:31:02 +0000 Subject: [docs] [issue13705] Raising exceptions from finally works better than advertised in the documentation In-Reply-To: <1325628788.79.0.655122317093.issue13705@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset c39fbb24b3f4 by Benjamin Peterson in branch '3.2': exception support is correct now (closes #13705) http://hg.python.org/cpython/rev/c39fbb24b3f4 ---------- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 01:40:53 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 04 Jan 2012 00:40:53 +0000 Subject: [docs] [issue13707] Clarify hash() lifetime Message-ID: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> New submission from Terry J. Reedy : Current 3.2.2 docs: id(object) Return the ?identity? of an object. This is an integer which is guaranteed to be unique and constant for this object during its lifetime. [model] hash(object) Return the hash value of the object (if it has one). Hash values are integers. They are used to quickly compare dictionary keys Suggestion: change "Hash values are integers. They ..." to "This should be an integer which is constant for this object during its lifetime. Hash values ..." Rationale: For builtin class instances, hash values are guaranteed to be constant that long, and only that long, as the default hash(ob) for object() instances is currently, for my win7, 64 bit, 3.2.2 CPython, id(ob) // 16 (the minimum object size). User class instance hashes (with custom __hash__) *should* have the same lifetime. But since Python cannot enforce that, I did not say 'guaranteed'. User code should *not* depend on a longer lifetime, just as for id() output. It seems worth implying that, as for id(), because (based on recent pydev discussion) people seems to be prone to over-generalize the current longer-term stability of number and string hashes, which itself may disappear in future releases. (see #13703) ---------- assignee: docs at python components: Documentation messages: 150561 nosy: docs at python, terry.reedy priority: normal severity: normal stage: needs patch status: open title: Clarify hash() lifetime type: enhancement versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 01:56:28 2012 From: report at bugs.python.org (Alex Gaynor) Date: Wed, 04 Jan 2012 00:56:28 +0000 Subject: [docs] [issue13707] Clarify hash() lifetime In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325638588.39.0.274342310862.issue13707@psf.upfronthosting.co.za> Changes by Alex Gaynor : ---------- nosy: +alex _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 02:17:18 2012 From: report at bugs.python.org (=?utf-8?q?Martin_v=2E_L=C3=B6wis?=) Date: Wed, 04 Jan 2012 01:17:18 +0000 Subject: [docs] [issue13707] Clarify hash() lifetime In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325639837.32.0.774190850224.issue13707@psf.upfronthosting.co.za> Martin v. L?wis added the comment: -1. The hash has nothing to do with the lifetime, but with the value of an object. ---------- nosy: +loewis _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 03:37:50 2012 From: report at bugs.python.org (Ramchandra Apte) Date: Wed, 04 Jan 2012 02:37:50 +0000 Subject: [docs] [issue13708] Document ctypes.wintypes In-Reply-To: <1325644438.51.0.00118311970114.issue13708@psf.upfronthosting.co.za> Message-ID: <1325644670.25.0.646485556828.issue13708@psf.upfronthosting.co.za> Changes by Ramchandra Apte : ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 03:38:50 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 04 Jan 2012 02:38:50 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325644730.01.0.0342595612945.issue13707@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Martin, I do not understand. The default hash is based on id (as is default equality comparison), not value. Are you OK with hash values changing if the 'value' changes? My understanding is that changing hash values for objects in sets and dicts is bad, which is why mutable builtins with value-based equality do not have hash values. ---------- title: Clarify hash() lifetime -> Clarify hash() constancy period _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 03:40:38 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Wed, 04 Jan 2012 02:40:38 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325644838.03.0.91190374723.issue13707@psf.upfronthosting.co.za> Antoine Pitrou added the comment: You can define a __hash__ that changes if the object changes. It is not recommended, but it's possible. So I agree with Martin that your proposed clarification is wrong. (I also think that it wouldn't bring anything, either) Suggest closing as invalid/rajected. ---------- nosy: +pitrou _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 03:46:44 2012 From: report at bugs.python.org (Ramchandra Apte) Date: Wed, 04 Jan 2012 02:46:44 +0000 Subject: [docs] [issue13709] Capitalization mistakes in the documentation for ctypes Message-ID: <1325645203.91.0.562347938508.issue13709@psf.upfronthosting.co.za> New submission from Ramchandra Apte : In section 15.17.1.17 in the ctypes documentation, the documentation says "It is funny to see that on linux the sort function seems to work much more efficiently, it is doing less comparisons" "It is quite interesting to see that the Windows qsort() function needs more comparisons than the linux version!" "linux" should be capitalized in both these sentences. ---------- assignee: docs at python components: Documentation messages: 150574 nosy: docs at python, ramchandra.apte priority: normal severity: normal status: open title: Capitalization mistakes in the documentation for ctypes _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 04:43:45 2012 From: report at bugs.python.org (Eli Bendersky) Date: Wed, 04 Jan 2012 03:43:45 +0000 Subject: [docs] [issue13709] Capitalization mistakes in the documentation for ctypes In-Reply-To: <1325645203.91.0.562347938508.issue13709@psf.upfronthosting.co.za> Message-ID: <1325648625.55.0.473507705698.issue13709@psf.upfronthosting.co.za> Eli Bendersky added the comment: And while we're at it, I would consider revising both sentences in a more fundamental way, since they're too chatty for the official docs. ---------- nosy: +eli.bendersky _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 05:07:22 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 04 Jan 2012 04:07:22 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325650042.15.0.203440691379.issue13707@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Given that the doc says that use of hash() is to compare dict keys, it does not seem wrong to me to suggest that hash() should be usable to do so. I believe id() and consequently hash() are unique among builtins in being run-dependent. That is currently documented for id() but not for hash(). Given that people seriously asked whether we can randomize hash() with each run, because 'people' 'expect' it to remain rather constant, it does not seem useless to clarify that it can change with each run. I am sure my wording could be improved. An alternative would be 'Hash values for built-in objects are constant for each run but not necessarily thereafter." If you take into account what people can do with special methods, some of the other entries seem more wrong that my suggestion. For instance: "len(s) Return the length (the number of items) of an object." and "str(obj ... When only object is given, this returns its nicely printable representation." These are true only for built-in objects, but the policy is to leave out the qualification. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 05:38:49 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Wed, 04 Jan 2012 04:38:49 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325651929.71.0.602422868047.issue13707@psf.upfronthosting.co.za> Raymond Hettinger added the comment: -1 I concur with Martin. ---------- nosy: +rhettinger _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 06:07:21 2012 From: report at bugs.python.org (=?utf-8?b?SmVzw7pzIENlYSBBdmnDs24=?=) Date: Wed, 04 Jan 2012 05:07:21 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325653640.99.0.606743506706.issue13707@psf.upfronthosting.co.za> Changes by Jes?s Cea Avi?n : ---------- nosy: +jcea _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 09:17:42 2012 From: report at bugs.python.org (=?utf-8?q?Martin_v=2E_L=C3=B6wis?=) Date: Wed, 04 Jan 2012 08:17:42 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325644730.01.0.0342595612945.issue13707@psf.upfronthosting.co.za> Message-ID: <4F040B24.7030403@v.loewis.de> Martin v. L?wis added the comment: > Martin, I do not understand. The default hash is based on id (as is > default equality comparison), not value. In the default implementation, the id *is* the object's value (i.e. objects, by default, only compare equal if they are identical). So the default implementation is just a special case of the more general rule that hashes need to be consistent with equality. > Are you OK with hash values changing if the 'value' changes? An object that can change its value (i.e. a mutable object) should fail to hash. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 10:13:56 2012 From: report at bugs.python.org (Marc-Andre Lemburg) Date: Wed, 04 Jan 2012 09:13:56 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325644730.01.0.0342595612945.issue13707@psf.upfronthosting.co.za> Message-ID: <4F04184E.6020704@egenix.com> Marc-Andre Lemburg added the comment: Terry J. Reedy wrote: > > Terry J. Reedy added the comment: > > Martin, I do not understand. The default hash is based on id (as is default equality comparison), not value. Are you OK with hash values changing if the 'value' changes? My understanding is that changing hash values for objects in sets and dicts is bad, which is why mutable builtins with value-based equality do not have hash values. Hash values are based on the object values, not their id(). See the various type implementations as reference. The id() is only used as hash for objects which don't have a "value" (and thus cannot be compared). Given that we have the invariant "a==b => hash(a)==hash(b)" in Python, it immediately follows that hash values for objects with comparison method cannot have a lifetime - at least not within the same process and, depending how you look at it, also not in multi-process applications. ---------- nosy: +lemburg _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 10:46:44 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Wed, 04 Jan 2012 09:46:44 +0000 Subject: [docs] [issue13707] Clarify hash() constancy period In-Reply-To: <1325637653.51.0.0128051850964.issue13707@psf.upfronthosting.co.za> Message-ID: <1325670404.57.0.870054111372.issue13707@psf.upfronthosting.co.za> Raymond Hettinger added the comment: [Antoine] > Suggest closing as invalid/rajected. [Martin] > -1. The hash has nothing to do with the lifetime, > but with the value of an object. ---------- resolution: -> invalid status: open -> closed _______________________________________ Python tracker _______________________________________ From vs140580 at gmail.com Wed Jan 4 04:51:44 2012 From: vs140580 at gmail.com (sriram vaidyanathan) Date: Wed, 4 Jan 2012 09:21:44 +0530 Subject: [docs] help to get Python 3.2.2 Message-ID: Respected sir, Can u help on how to acquire Python 3.2.2 software what is that i have to download in detail. I would also like to install a package networkx1.6 to it and use it. I also need guidance on how to install python and networkx 1.6 to it. regards V.Sriram From report at bugs.python.org Wed Jan 4 23:14:01 2012 From: report at bugs.python.org (Sandro Tosi) Date: Wed, 04 Jan 2012 22:14:01 +0000 Subject: [docs] [issue11648] openlog()s 'logopt' keyword broken in syslog module In-Reply-To: <1300848156.85.0.89651150439.issue11648@psf.upfronthosting.co.za> Message-ID: <1325715241.3.0.477112999696.issue11648@psf.upfronthosting.co.za> Sandro Tosi added the comment: This has already been fixed with 71f7175e2b34 & friends. ---------- nosy: +sandro.tosi resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: -Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 23:26:42 2012 From: report at bugs.python.org (Roundup Robot) Date: Wed, 04 Jan 2012 22:26:42 +0000 Subject: [docs] [issue10772] Several actions for argparse arguments missing from docs In-Reply-To: <1293327184.11.0.454888760887.issue10772@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 278fbd7b9608 by Sandro Tosi in branch '2.7': Issue #10772: add count and help argparse action; patch by Marc Sibson http://hg.python.org/cpython/rev/278fbd7b9608 New changeset 326f755962e3 by Sandro Tosi in branch '3.2': Issue #10772: add count and help argparse action; patch by Marc Sibson http://hg.python.org/cpython/rev/326f755962e3 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 4 23:27:48 2012 From: report at bugs.python.org (Sandro Tosi) Date: Wed, 04 Jan 2012 22:27:48 +0000 Subject: [docs] [issue10772] Several actions for argparse arguments missing from docs In-Reply-To: <1293327184.11.0.454888760887.issue10772@psf.upfronthosting.co.za> Message-ID: <1325716068.1.0.141298160136.issue10772@psf.upfronthosting.co.za> Sandro Tosi added the comment: Thanks Marc for the patch, I've just committed it. ---------- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Wed Jan 4 23:30:28 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Wed, 4 Jan 2012 23:30:28 +0100 Subject: [docs] help to get Python 3.2.2 In-Reply-To: References: Message-ID: Hello Sriram, this mailing list is about bugfix/enhancement to Python documentation, while what you're looking for is some guidance/help. I suggest to contact http://mail.python.org/mailman/listinfo/python-list about your queries. Regards, Sandro On Wed, Jan 4, 2012 at 04:51, sriram vaidyanathan wrote: > Respected sir, > > Can u help on how to acquire Python 3.2.2 software what is that i have > to download in detail. > > I would also like to install a package networkx1.6 to it and use it. I > also need guidance on how to install python and networkx 1.6 to it. > > regards > V.Sriram > _______________________________________________ > docs mailing list > docs at python.org > http://mail.python.org/mailman/listinfo/docs -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From eliben at gmail.com Thu Jan 5 04:46:58 2012 From: eliben at gmail.com (Eli Bendersky) Date: Thu, 5 Jan 2012 05:46:58 +0200 Subject: [docs] help to get Python 3.2.2 In-Reply-To: References: Message-ID: On Wed, Jan 4, 2012 at 05:51, sriram vaidyanathan wrote: > Respected sir, > > Can u help on how to acquire Python 3.2.2 software what is that i have > to download in detail. > > I would also like to install a package networkx1.6 to it and use it. I > also need guidance on how to install python and networkx 1.6 to it. > > regards > V.Sriram Hello V.Sriram, As Sandro mentioned, this mailing list is not the right place for such questions. However, I'll give you a couple of quick pointers. For Python itself, go to http://python.org/download/releases/3.2.2/, scroll to the bottom ("Download" section) and pick the download you need. For downloading and installing NetworkX, go to http://networkx.lanl.gov/download.html. If you have troubles with the installation, follow the documentation of NetworkX. Eli From report at bugs.python.org Thu Jan 5 17:47:21 2012 From: report at bugs.python.org (Eli Collins) Date: Thu, 05 Jan 2012 16:47:21 +0000 Subject: [docs] [issue13715] typo in unicodedata documentation Message-ID: <1325782041.56.0.783502480563.issue13715@psf.upfronthosting.co.za> New submission from Eli Collins : I noticed a minor typo in the unicodedata.normalize() documentation... The line reading 'U+0327 (COMBINING CEDILLA) U+0043 (LATIN CAPITAL LETTER C)' is not proper unicode, it should be in the reverse order: 'U+0043 (LATIN CAPITAL LETTER C) U+0327 (COMBINING CEDILLA)'. attached is a small patch to fix this. ---------- assignee: docs at python components: Documentation files: docfix.patch keywords: patch messages: 150670 nosy: docs at python, eli.collins priority: normal severity: normal status: open title: typo in unicodedata documentation versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4 Added file: http://bugs.python.org/file24145/docfix.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 18:24:18 2012 From: report at bugs.python.org (Ezio Melotti) Date: Thu, 05 Jan 2012 17:24:18 +0000 Subject: [docs] [issue13715] typo in unicodedata documentation In-Reply-To: <1325782041.56.0.783502480563.issue13715@psf.upfronthosting.co.za> Message-ID: <1325784258.71.0.276718329805.issue13715@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- assignee: docs at python -> ezio.melotti nosy: +ezio.melotti stage: -> patch review type: -> enhancement versions: -Python 2.6, Python 3.1, Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 18:47:47 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Thu, 05 Jan 2012 17:47:47 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1325291864.93.0.942110099636.issue12760@psf.upfronthosting.co.za> Message-ID: Charles-Fran?ois Natali added the comment: I've done a small review. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 19:08:39 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 05 Jan 2012 18:08:39 +0000 Subject: [docs] [issue11984] Wrong "See also" in symbol and token module docs In-Reply-To: <1304405152.56.0.259676009595.issue11984@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset d8102ccc5bf7 by Sandro Tosi in branch '2.7': Issue #11984: remove reference to parser, it's not showing symbol usage anymore http://hg.python.org/cpython/rev/d8102ccc5bf7 New changeset b326d90ce9c9 by Sandro Tosi in branch '3.2': Issue #11984: remove reference to parser, it's not showing symbol usage anymore http://hg.python.org/cpython/rev/b326d90ce9c9 New changeset f375a1be031c by Sandro Tosi in branch 'default': Issue #11984: merge with 3.2 http://hg.python.org/cpython/rev/f375a1be031c ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 19:09:41 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 05 Jan 2012 18:09:41 +0000 Subject: [docs] [issue11984] Wrong "See also" in symbol and token module docs In-Reply-To: <1304405152.56.0.259676009595.issue11984@psf.upfronthosting.co.za> Message-ID: <1325786981.8.0.791494254587.issue11984@psf.upfronthosting.co.za> Sandro Tosi added the comment: Hi Davi, thanks for your report! I've removed the reference from symbol to parser, given this last module doesn't show anymore how to user symbol, and it's encouraging to use ast module instead. ---------- nosy: +sandro.tosi resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 19:51:05 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 05 Jan 2012 18:51:05 +0000 Subject: [docs] [issue12042] What's New multiprocessing example error In-Reply-To: <1304967317.91.0.912225759197.issue12042@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 3353f9747a39 by Sandro Tosi in branch '2.7': Issue #12042: a queue is only used to retrive results; preliminary patch by Jordan Stadler http://hg.python.org/cpython/rev/3353f9747a39 New changeset 0d4bb1356f39 by Sandro Tosi in branch '3.2': Issue #12042: a queue is only used to retrive results; preliminary patch by Jordan Stadler http://hg.python.org/cpython/rev/0d4bb1356f39 New changeset e379617b4c4c by Sandro Tosi in branch 'default': Issue #12042: merge with 3.2 http://hg.python.org/cpython/rev/e379617b4c4c ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 19:55:12 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 05 Jan 2012 18:55:12 +0000 Subject: [docs] [issue12042] What's New multiprocessing example error In-Reply-To: <1304967317.91.0.912225759197.issue12042@psf.upfronthosting.co.za> Message-ID: <1325789712.46.0.442673508827.issue12042@psf.upfronthosting.co.za> Sandro Tosi added the comment: Thanks Davi for the report and Jordan for the patch! Jordan, a tip for your (hopefully) future contributions: for doc patches, please don't re-indent the whole paragraph, since it makes harder to identify the actual changes, just change what is needed, and the committer will take care (if needed) to re indent the paragraph. I've re-edited a bit and committed the fix in the active branches. ---------- nosy: +sandro.tosi resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 20:02:16 2012 From: report at bugs.python.org (Florent Xicluna) Date: Thu, 05 Jan 2012 19:02:16 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX Message-ID: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> New submission from Florent Xicluna : http://docs.python.org/distutils/apiref.html?highlight=XXX#module-distutils.ccompiler We find lots of "XXX" and "XXX see also." which give no information. ---------- assignee: docs at python components: Documentation messages: 150683 nosy: docs at python, flox priority: normal severity: normal stage: needs patch status: open title: distutils doc contains lots of XXX type: behavior versions: Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 20:04:00 2012 From: report at bugs.python.org (Florent Xicluna) Date: Thu, 05 Jan 2012 19:04:00 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX In-Reply-To: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> Message-ID: <1325790240.48.0.65991931179.issue13716@psf.upfronthosting.co.za> Changes by Florent Xicluna : ---------- nosy: +eric.araujo, tarek versions: +Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 5 22:56:01 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 05 Jan 2012 21:56:01 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1325800561.14.0.00685125657639.issue12415@psf.upfronthosting.co.za> Sandro Tosi added the comment: Hi ?ric, did you reconsider the text of the patch or this issue just passed under your radar? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 17:43:12 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 06 Jan 2012 16:43:12 +0000 Subject: [docs] [issue1040439] Missing documentation on how to link with libpython Message-ID: <1325868192.22.0.587437984751.issue1040439@psf.upfronthosting.co.za> ?ric Araujo added the comment: Attached patch adds the useful bits from the review I did; I hope you won?t think it?s pointless nitpicking. ---------- Added file: http://bugs.python.org/file24155/docembed-edits.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 17:44:51 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 06 Jan 2012 16:44:51 +0000 Subject: [docs] [issue13562] Notes about module load path In-Reply-To: <1323397324.61.0.220189805252.issue13562@psf.upfronthosting.co.za> Message-ID: <1325868290.99.0.256887957781.issue13562@psf.upfronthosting.co.za> ?ric Araujo added the comment: I did the markup edits but then found out that the doc for Py_Initialize in c-api/init already mentions the module load path and the module table, so I?m going to make another patch with just a link to that. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 17:51:46 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 06 Jan 2012 16:51:46 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1325868706.26.0.24608303108.issue12415@psf.upfronthosting.co.za> ?ric Araujo added the comment: I merely forgot, thanks for the prod. I?m taking your message as a +1 to the wording and will commit when the server I use for tunnels is back online. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 17:54:13 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 06 Jan 2012 16:54:13 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX In-Reply-To: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> Message-ID: <1325868853.17.0.612749312845.issue13716@psf.upfronthosting.co.za> ?ric Araujo added the comment: Tarek ruled that time spent improving the distutils docs was time lost and better spent on distutils2. Accordingly, I only fix clear bugs in the doc but don?t improve them in any way. I?m inclined to close this as wontfix, or I can remove the XXX if you?re strongly against them. (For the packaging docs, I will fix them properly.) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 17:55:02 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Fri, 06 Jan 2012 16:55:02 +0000 Subject: [docs] [issue1040439] Missing documentation on how to link with libpython In-Reply-To: <1325868192.22.0.587437984751.issue1040439@psf.upfronthosting.co.za> Message-ID: <1325868825.3341.7.camel@localhost.localdomain> Antoine Pitrou added the comment: > Attached patch adds the useful bits from the review I did; I hope you > won?t think it?s pointless nitpicking. Looks good to me. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 18:02:03 2012 From: report at bugs.python.org (Ezio Melotti) Date: Fri, 06 Jan 2012 17:02:03 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1325869323.36.0.156979773145.issue12415@psf.upfronthosting.co.za> Ezio Melotti added the comment: http://docs.python.org/dev/documenting/building.html also needs to be updated (it still mentions Subversion and probably obsolete versions of Sphinx and other packages). If you are going to add the text proposed in your second message, you might want to drop a couple of "p"s from there. ---------- nosy: +ezio.melotti type: -> enhancement _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 18:05:18 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 06 Jan 2012 17:05:18 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1325869518.48.0.0483429952209.issue12415@psf.upfronthosting.co.za> ?ric Araujo added the comment: > http://docs.python.org/dev/documenting/building.html also needs to be updated (it > still mentions Subversion and probably obsolete versions of Sphinx and other > packages). Well, the doc makefile still uses Subversion. As for the versions, if the ones listed in the doc don?t match the ones used in the makefile, I?ll sync them. > If you are going to add the text proposed in your second message, you might want > to drop a couple of "p"s from there. I don?t understand: "p"s? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 18:12:49 2012 From: report at bugs.python.org (Ezio Melotti) Date: Fri, 06 Jan 2012 17:12:49 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1325869969.77.0.557897583364.issue12415@psf.upfronthosting.co.za> Ezio Melotti added the comment: > Well, the doc makefile still uses Subversion. Indeed, I was thinking about getting a CPython checkout with the doc, not about the tools used to built it (maybe it could be clarified). > I don?t understand: "p"s? >From "_Developpers's Guide: http://docs.python.org/devguide" ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 18:16:56 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 06 Jan 2012 17:16:56 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1325870215.95.0.0353341882579.issue12415@psf.upfronthosting.co.za> ?ric Araujo added the comment: > Indeed, I was thinking about getting a CPython checkout with the doc Right. I?ll edit my wording to mention Mercurial. >> I don?t understand: "p"s? >From "_Developpers's Guide: http://docs.python.org/devguide" The curse of being French :) I always want to write ?developpers? guide? when it?s ?developer?s guide?. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 19:27:48 2012 From: report at bugs.python.org (Eric Snow) Date: Fri, 06 Jan 2012 18:27:48 +0000 Subject: [docs] [issue13562] Notes about module load path In-Reply-To: <1323397324.61.0.220189805252.issue13562@psf.upfronthosting.co.za> Message-ID: <1325874468.62.0.120025786822.issue13562@psf.upfronthosting.co.za> Changes by Eric Snow : ---------- nosy: +eric.snow _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 19:55:11 2012 From: report at bugs.python.org (Nam Nguyen) Date: Fri, 06 Jan 2012 18:55:11 +0000 Subject: [docs] [issue13562] Notes about module load path In-Reply-To: <1323397324.61.0.220189805252.issue13562@psf.upfronthosting.co.za> Message-ID: <1325876111.51.0.368815795165.issue13562@psf.upfronthosting.co.za> Nam Nguyen added the comment: Please do keep the warning though. It is best to warn in both Python-C Py_Initialize() document and the Embedding tutorial. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 6 23:13:50 2012 From: report at bugs.python.org (Mads Kiilerich) Date: Fri, 06 Jan 2012 22:13:50 +0000 Subject: [docs] [issue13724] socket.create_connection and multiple IP addresses Message-ID: <1325888030.3.0.0416342115288.issue13724@psf.upfronthosting.co.za> New submission from Mads Kiilerich : Forked from issue13721 where I was too lazy to report it separately: http://docs.python.org/release/2.7.2/library/socket#socket.create_connection doesn't describe how it loops over all IP addresses. That seems to be the functions main advantage (and a gotcha) compared to creating the socket and connecting directly. I propose to warn that it might "hang" up to n*timeout before anything happens with something like this in documentation and docstring: ... and return the socket object. If the host resolves to multiple IP addresses then they will all be tried in turn until one of them succeeds. Passing the optional timeout parameter will set the timeout on the socket instance before each attempt to connect. If no ... ---------- assignee: docs at python components: Documentation messages: 150772 nosy: docs at python, kiilerix, pitrou priority: normal severity: normal status: open title: socket.create_connection and multiple IP addresses type: enhancement versions: Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 01:05:11 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 07 Jan 2012 00:05:11 +0000 Subject: [docs] [issue13685] argparse does not sanitize help strings for % signs In-Reply-To: <1325284167.16.0.584942168313.issue13685@psf.upfronthosting.co.za> Message-ID: <1325894711.97.0.776284350312.issue13685@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- nosy: +bethard _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 01:08:50 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 07 Jan 2012 00:08:50 +0000 Subject: [docs] [issue13686] Some notes on the docs of multiprocessing In-Reply-To: <1325307613.69.0.259805833126.issue13686@psf.upfronthosting.co.za> Message-ID: <1325894930.04.0.88908134492.issue13686@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- nosy: +jnoller _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 01:28:31 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Sat, 07 Jan 2012 00:28:31 +0000 Subject: [docs] [issue13724] socket.create_connection and multiple IP addresses In-Reply-To: <1325888030.3.0.0416342115288.issue13724@psf.upfronthosting.co.za> Message-ID: <1325896033.3341.18.camel@localhost.localdomain> Antoine Pitrou added the comment: > http://docs.python.org/release/2.7.2/library/socket#socket.create_connection doesn't describe how it loops over all IP addresses. That seems to be the functions main advantage (and a gotcha) compared to creating the socket and connecting directly. Well the main advantage is that it makes it much easier to write clients supporting both IPv4 and IPv6. ---------- _______________________________________ Python tracker _______________________________________ From cody at google.com Thu Jan 5 03:02:57 2012 From: cody at google.com (Cody Smith) Date: Wed, 4 Jan 2012 18:02:57 -0800 Subject: [docs] Py_SetPythonHome() before Py_Initialize() Message-ID: Python folks, Your "Initialization, Finalization, and Threads" document* explains that embedded Python applications must call Py_Initialize() before any other Python/C API functions, with a handful of exceptions. It seems like Py_SetPythonHome() should be among the exceptions, but it isn't. Initialization potentially relies on "home", so Py_SetPythonHome() is useful before Py_Initialize(). This situation is similar to Py_SetProgramName(), which _is_ permitted before Py_Initialize(). Also, in practice, the implementation of Py_SetPythonHome() only accesses a single static global variable, "default_home". (This is based on a spot check of 2.0.1, 2.6.7 and 3.2 branches). Clarification would be much appreciated, since it might help me avoid a hack. Thanks, Cody * = http://docs.python.org/c-api/init.html From nnorwitz at google.com Thu Jan 5 05:30:45 2012 From: nnorwitz at google.com (Neal Norwitz) Date: Wed, 4 Jan 2012 20:30:45 -0800 Subject: [docs] Py_SetPythonHome() before Py_Initialize() In-Reply-To: References: Message-ID: +gps & twouters On Wed, Jan 4, 2012 at 6:02 PM, Cody Smith wrote: > Python folks, > > Your "Initialization, Finalization, and Threads" document* explains > that embedded Python applications must call Py_Initialize() before any > other Python/C API functions, with a handful of exceptions. It seems > like Py_SetPythonHome() should be among the exceptions, but it isn't. > > Initialization potentially relies on "home", so Py_SetPythonHome() is > useful before Py_Initialize(). This situation is similar to > Py_SetProgramName(), which _is_ permitted before Py_Initialize(). > Also, in practice, the implementation of Py_SetPythonHome() only > accesses a single static global variable, "default_home". (This is > based on a spot check of 2.0.1, 2.6.7 and 3.2 branches). > > Clarification would be much appreciated, since it might help me avoid > a hack. Thanks, > > Cody > > * = http://docs.python.org/c-api/init.html > -------------- next part -------------- An HTML attachment was scrubbed... URL: From twouters at google.com Thu Jan 5 11:34:06 2012 From: twouters at google.com (Thomas Wouters) Date: Thu, 5 Jan 2012 11:34:06 +0100 Subject: [docs] Py_SetPythonHome() before Py_Initialize() In-Reply-To: References: Message-ID: On Thu, Jan 5, 2012 at 05:30, Neal Norwitz wrote: > +gps & twouters > > On Wed, Jan 4, 2012 at 6:02 PM, Cody Smith wrote: > >> Python folks, >> >> Your "Initialization, Finalization, and Threads" document* explains >> that embedded Python applications must call Py_Initialize() before any >> other Python/C API functions, with a handful of exceptions. It seems >> like Py_SetPythonHome() should be among the exceptions, but it isn't. >> >> Initialization potentially relies on "home", so Py_SetPythonHome() is >> useful before Py_Initialize(). This situation is similar to >> Py_SetProgramName(), which _is_ permitted before Py_Initialize(). >> Also, in practice, the implementation of Py_SetPythonHome() only >> accesses a single static global variable, "default_home". (This is >> based on a spot check of 2.0.1, 2.6.7 and 3.2 branches). >> >> Clarification would be much appreciated, since it might help me avoid >> a hack. Thanks, >> > Not speaking for docs.python.org, but this is a bug in the documentation, yes, and you should feel perfectly safe calling Py_SetPythonHome() before Py_Initialize() -- it only makes sense to call it before Py_Initialize(), after all. If it makes you feel any better I'll always guarantee the safety of calling Py_SetPythonHome() before Py_Initialize() in *Google*'s Python setups :) -- Thomas Wouters Hi! I'm a .signature virus! copy me into your .signature file to help me spread! -------------- next part -------------- An HTML attachment was scrubbed... URL: From report at bugs.python.org Sat Jan 7 12:31:19 2012 From: report at bugs.python.org (Giampaolo Rodola') Date: Sat, 07 Jan 2012 11:31:19 +0000 Subject: [docs] [issue13724] socket.create_connection and multiple IP addresses In-Reply-To: <1325888030.3.0.0416342115288.issue13724@psf.upfronthosting.co.za> Message-ID: <1325935879.57.0.358914020131.issue13724@psf.upfronthosting.co.za> Changes by Giampaolo Rodola' : ---------- nosy: +giampaolo.rodola _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 13:14:48 2012 From: report at bugs.python.org (Erno Tukia) Date: Sat, 07 Jan 2012 12:14:48 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag Message-ID: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> New submission from Erno Tukia : ./python -m test --help -S/--slow -- print the slowest 10 tests -S is used to continue running tests after an aborted run. It will maintain the order a standard run (ie, this assumes -r is not used). This is useful after the tests have prematurely stopped for some external reason and you want to start running from where you left off rather than starting from the beginning. in Lib/test/regrtest.py opts, args = getopt.getopt(sys.argv[1:], '...S...', [..., 'slow', ... , 'start=', ...]) for o, a in opts: elif o in ('-S', '--start'): start = a elif o in ('-S', '--slow'): print_slow = True At the moment -S (no args) and --slow (no args) are the same, not what the documentation says and not how the code executes (-S goes with --start). Help says nothing about --start. --slow or --start needs a new short opt, and corrected documentation. ---------- assignee: docs at python components: Documentation, Tests messages: 150792 nosy: docs at python, etukia priority: normal severity: normal status: open title: regrtest ambiguous -S flag type: behavior versions: Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 13:57:40 2012 From: report at bugs.python.org (Georg Brandl) Date: Sat, 07 Jan 2012 12:57:40 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX In-Reply-To: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> Message-ID: <1325941059.9.0.853319373491.issue13716@psf.upfronthosting.co.za> Georg Brandl added the comment: I would make comments out of the XXX, and if a whole section is just that XXX, remove the section as well. ---------- nosy: +georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 15:47:06 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sat, 07 Jan 2012 14:47:06 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX In-Reply-To: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> Message-ID: <1325947626.08.0.26602034733.issue13716@psf.upfronthosting.co.za> ?ric Araujo added the comment: These are the XXX: XXX true? does ANSI say anything about this? XXX defaults to what? XXX see also. XXX see also. XXX see also. XXX see also. XXX see also. The first two are questions that can be answered, and when I research them for the packaging docs I could also backport the changes to the distutils docs; what to do for the other instances is less clear, so just deleting may be better than turning them into comments that will never get solved. ---------- assignee: docs at python -> eric.araujo _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 15:51:36 2012 From: report at bugs.python.org (Georg Brandl) Date: Sat, 07 Jan 2012 14:51:36 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX In-Reply-To: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> Message-ID: <1325947896.77.0.585739886067.issue13716@psf.upfronthosting.co.za> Georg Brandl added the comment: Agreed. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 16:06:50 2012 From: report at bugs.python.org (Florent Xicluna) Date: Sat, 07 Jan 2012 15:06:50 +0000 Subject: [docs] [issue13716] distutils doc contains lots of XXX In-Reply-To: <1325790136.17.0.881224521536.issue13716@psf.upfronthosting.co.za> Message-ID: <1325948810.43.0.964659516993.issue13716@psf.upfronthosting.co.za> Florent Xicluna added the comment: The proposed solution is ok. It sounds like unfinished documentation when you hit an "XXX". For the "/dev/" documentation, it's OK, but for the released version, we should avoid it. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 16:36:53 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sat, 07 Jan 2012 15:36:53 +0000 Subject: [docs] [issue13728] Description of -m and -c cli options wrong? Message-ID: <1325950613.83.0.912226487635.issue13728@psf.upfronthosting.co.za> New submission from Sandro Tosi : Hi, looking at http://mail.python.org/pipermail/docs/2011-December/006672.html I tried to replicate what the user said, and *it seems* that -c and -m doesn't add the current directory to the start of sys.path: $ echo -e "import sys\nprint (sys.path)" > dummy.py ; ./python -mdummy ['', '/usr/local/lib/python27.zip', '/home/morph/cpython/py27/Lib', '/home/morph/cpython/py27/Lib/plat-linux2', '/home/morph/cpython/py27/Lib/lib-tk', '/home/morph/cpython/py27/Lib/lib-old', '/home/morph/cpython/py27/build/lib.linux-x86_64-2.7-pydebug', '/usr/local/lib/python2.7/site-packages'] and $ ./python -c "import dummy" ['', '/usr/local/lib/python27.zip', '/home/morph/cpython/py27/Lib', '/home/morph/cpython/py27/Lib/plat-linux2', '/home/morph/cpython/py27/Lib/lib-tk', '/home/morph/cpython/py27/Lib/lib-old', '/home/morph/cpython/py27/build/lib.linux-x86_64-2.7-pydebug', '/usr/local/lib/python2.7/site-packages'] the same sys.path as from the interactive shell: $ ./python Python 2.7.2+ (2.7:f0666e56a552, Jan 7 2012, 16:31:06) [GCC 4.6.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import sys [38650 refs] >>> sys.path ['', '/usr/local/lib/python27.zip', '/home/morph/cpython/py27/Lib', '/home/morph/cpython/py27/Lib/plat-linux2', '/home/morph/cpython/py27/Lib/lib-tk', '/home/morph/cpython/py27/Lib/lib-old', '/home/morph/cpython/py27/build/lib.linux-x86_64-2.7-pydebug', '/usr/local/lib/python2.7/site-packages'] [38657 refs] So, is http://docs.python.org/using/cmdline.html#interface-options correct in saying "he current directory will be added to the start of sys.path (allowing modules in that directory to be imported as top level modules)."? (and so forth for -m option?) am I confused? ---------- assignee: docs at python components: Documentation messages: 150802 nosy: docs at python, sandro.tosi priority: normal severity: normal stage: needs patch status: open title: Description of -m and -c cli options wrong? versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Sat Jan 7 16:37:35 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 7 Jan 2012 16:37:35 +0100 Subject: [docs] option -m bug In-Reply-To: <2011120815194324489434@gmail.com> References: <2011120815194324489434@gmail.com> Message-ID: Hello, thanks for your email. On Thu, Dec 8, 2011 at 08:19, skeu.Grass wrote: > Hi, I found that the description of option '-m' is wrong: > In > > Python v2.7.2 documentation ? > Python Setup and Usage ? > > 1.1.1. Interface options > > -m > it says As with the -c option, the current directory will be added to the > start of sys.path. > But I found that using the "python -m" the current directory > won't be added to the start of sys.path. > I tested the v2.6.6 v2.7.2 v3.2.2, they all have the problem. I've reported http://bugs.python.org/issue13728 to track this. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 7 17:05:32 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sat, 07 Jan 2012 16:05:32 +0000 Subject: [docs] [issue13729] Evaluation order for dics key/value Message-ID: <1325952332.37.0.223922022645.issue13729@psf.upfronthosting.co.za> New submission from Sandro Tosi : Hello, following up http://mail.python.org/pipermail/docs/2011-December/006782.html , I'm opening this issue to have others confirmation of what's happening: echo -e "def ev(r):\n print(r)\n return r\n\n{ev(1): ev(2), ev(3): ev(4)}" | ./python 2 1 4 3 (this applies for 2.7/3.2/default) so it seems the value expressions are evaluated before the key expressions, so the {expr1: expr2, expr3: expr4} in http://docs.python.org/reference/expressions.html#evaluation-order has to be updated in {expr2: expr1, expr4: expr3} Is that correct/can someone confirm this is the expected behavior? ---------- assignee: docs at python components: Documentation messages: 150804 nosy: docs at python, sandro.tosi priority: normal severity: normal stage: needs patch status: open title: Evaluation order for dics key/value versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Sat Jan 7 17:06:06 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 7 Jan 2012 17:06:06 +0100 Subject: [docs] documentation error w/ evaluation order In-Reply-To: References: Message-ID: Hello Zach, thanks for your email. On Fri, Dec 16, 2011 at 04:03, Zach Wegner wrote: > In http://docs.python.org/reference/expressions.html#evaluation-order, > there's a table that contains this entry, giving the order of > evaluation for dict literals: > > {expr1: expr2, expr3: expr4} > > However, for each item, the value is evaluated before the key, like so: > > def ev(r): > ? ?print(r) > ? ?return r > > {ev(1): ev(2), ev(3): ev(4)} > > prints (under 3.2.2): > > 2 > 1 > 4 > 3 I've just filed http://bugs.python.org/issue13729 to track this. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 7 17:57:51 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 16:57:51 +0000 Subject: [docs] [issue13666] datetime documentation typos In-Reply-To: <1324936913.94.0.649454454071.issue13666@psf.upfronthosting.co.za> Message-ID: <1325955471.28.0.0936271571621.issue13666@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: This patch fixes the rzinfo typo as well as the GMT2 issue (GMT +2 should behave exactly the same as GMT +1 with regards to DST, it's base offset should simply be +2 hours instead of +1). This does not; however, address the comment about the first line of the tzinfo.utcoffset(). The fact that tzinfo.utcoffset() should return a timedelta or None is addressed later in the same paragraph, as such I'm not sure the proposed change is an improvement. ---------- keywords: +patch nosy: +zacherates Added file: http://bugs.python.org/file24161/issue13666.diff _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Sat Jan 7 17:59:48 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 7 Jan 2012 17:59:48 +0100 Subject: [docs] multiprocessing / Connection In-Reply-To: <4EE59ED8.1030503@gmail.com> References: <4EE59ED8.1030503@gmail.com> Message-ID: Hello Chris, thanks for your email! On Mon, Dec 12, 2011 at 07:27, Chris Kogelnik wrote: > In both the 2.7 an 3.0 docs and online help, in the module multiprocessing > for the Connection object, the 'recv', 'recv_bytes' and 'recv_bytes_into' > methods do not mention that the routines block until data is available. > > I think this would be useful to add. Yes indeed, I've just added they are blocking operations in all the active branches (where doc is updated). Reagards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 7 18:15:09 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 17:15:09 +0000 Subject: [docs] [issue13666] datetime documentation typos In-Reply-To: <1324936913.94.0.649454454071.issue13666@psf.upfronthosting.co.za> Message-ID: <1325956509.43.0.618394244929.issue13666@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: Looks like the issue of the first line of utcoffsect was also raised in issue 8810. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 18:26:39 2012 From: report at bugs.python.org (Stephen Kelly) Date: Sat, 07 Jan 2012 17:26:39 +0000 Subject: [docs] [issue13666] datetime documentation typos In-Reply-To: <1324936913.94.0.649454454071.issue13666@psf.upfronthosting.co.za> Message-ID: <1325957199.78.0.346936826069.issue13666@psf.upfronthosting.co.za> Stephen Kelly added the comment: Patch looks good to me. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 18:27:07 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 07 Jan 2012 17:27:07 +0000 Subject: [docs] [issue13502] Documentation for Event.wait return value is either wrong or incomplete In-Reply-To: <1322599516.14.0.0239672713193.issue13502@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset eb39d862a250 by Charles-Fran?ois Natali in branch '3.2': Issue #13502: threading: Fix a race condition in Event.wait() that made it http://hg.python.org/cpython/rev/eb39d862a250 New changeset 0fe63bb20e74 by Charles-Fran?ois Natali in branch 'default': Issue #13502: threading: Fix a race condition in Event.wait() that made it http://hg.python.org/cpython/rev/0fe63bb20e74 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Sat Jan 7 18:36:59 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 7 Jan 2012 18:36:59 +0100 Subject: [docs] Py_SetPythonHome() before Py_Initialize() In-Reply-To: References: Message-ID: On Thu, Jan 5, 2012 at 11:34, Thomas Wouters wrote: > Not speaking for docs.python.org, but this is a bug in the documentation, > yes, and you should feel perfectly safe calling Py_SetPythonHome() before > Py_Initialize() -- it only makes sense to call it before Py_Initialize(), > after all. i've just fixed in also in the doc for the active branches of cpython. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 7 19:44:11 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 18:44:11 +0000 Subject: [docs] [issue12005] modulo result of Decimal differs from float/int In-Reply-To: <1304584519.64.0.99823949629.issue12005@psf.upfronthosting.co.za> Message-ID: <1325961851.47.0.660888855659.issue12005@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: Here is a patch that adds an explination for the difference in the behaviour to the FAQ section of the Decimal documentation. ---------- keywords: +patch nosy: +zacherates Added file: http://bugs.python.org/file24162/issue12005.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 20:09:30 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 19:09:30 +0000 Subject: [docs] [issue13730] Grammar mistake in Decimal documentation Message-ID: <1325963370.31.0.599534414571.issue13730@psf.upfronthosting.co.za> New submission from Aaron Maenpaa : In the sentance: "In contrast, numbers like 1.1 and 2.2 do not have an exact representations in binary floating point." there is a mismatch in number between "an" and "representations". I suggest removing "an" to make the whole thing plural. A patch is attached. ---------- assignee: docs at python components: Documentation files: plural.diff keywords: patch messages: 150813 nosy: docs at python, zacherates priority: normal severity: normal status: open title: Grammar mistake in Decimal documentation versions: Python 3.3 Added file: http://bugs.python.org/file24164/plural.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 20:16:46 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 19:16:46 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation Message-ID: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> New submission from Aaron Maenpaa : The paragraph: "The exactness carries over into arithmetic. In decimal floating point, 0.1 + 0.1 + 0.1 - 0.3 is exactly equal to zero. In binary floating point, the result is 5.5511151231257827e-017. While near to zero, the differences prevent reliable equality testing and differences can accumulate. For this reason, decimal is preferred in accounting applications which have strict equality invariants." ... has some awkward phrasing to my ear. I've attached a patch with a proposed alternative. ---------- assignee: docs at python components: Documentation files: rephrase.diff keywords: patch messages: 150814 nosy: docs at python, zacherates priority: normal severity: normal status: open title: Awkward phrasing in Decimal documentation versions: Python 3.3 Added file: http://bugs.python.org/file24165/rephrase.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 20:40:56 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sat, 07 Jan 2012 19:40:56 +0000 Subject: [docs] [issue13502] Documentation for Event.wait return value is either wrong or incomplete In-Reply-To: <1322599516.14.0.0239672713193.issue13502@psf.upfronthosting.co.za> Message-ID: <1325965256.51.0.309111815218.issue13502@psf.upfronthosting.co.za> Changes by Charles-Fran?ois Natali : ---------- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 21:07:24 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 20:07:24 +0000 Subject: [docs] [issue13587] Correcting the typos error in Doc/howto/urllib2.rst In-Reply-To: <1323693654.01.0.260479490427.issue13587@psf.upfronthosting.co.za> Message-ID: <1325966844.41.0.859284995677.issue13587@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: Here's a patch that makes the WWW-Authenticate headers in howto/urllib2 agree with rfc2617. ---------- keywords: +patch nosy: +zacherates Added file: http://bugs.python.org/file24166/issue13587.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 22:08:37 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Sat, 07 Jan 2012 21:08:37 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation In-Reply-To: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> Message-ID: <1325970517.2.0.768137929552.issue13731@psf.upfronthosting.co.za> Changes by Raymond Hettinger : ---------- assignee: docs at python -> rhettinger nosy: +rhettinger _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 22:12:22 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Sat, 07 Jan 2012 21:12:22 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation In-Reply-To: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> Message-ID: <1325970742.89.0.731074427481.issue13731@psf.upfronthosting.co.za> Raymond Hettinger added the comment: I'm sorry but I think the current wording is better that your proposed revision. When I get a chance, I'll revisit it to see if I can find another way to improve the text. ---------- priority: normal -> low _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 22:34:39 2012 From: report at bugs.python.org (Eric Snow) Date: Sat, 07 Jan 2012 21:34:39 +0000 Subject: [docs] [issue13728] Description of -m and -c cli options wrong? In-Reply-To: <1325950613.83.0.912226487635.issue13728@psf.upfronthosting.co.za> Message-ID: <1325972079.46.0.745351783397.issue13728@psf.upfronthosting.co.za> Eric Snow added the comment: see http://docs.python.org/library/sys.html#sys.path "As initialized upon program startup, the first item of this list, path[0], is the directory containing the script that was used to invoke the Python interpreter. If the script directory is not available (e.g. if the interpreter is invoked interactively or if the script is read from standard input), path[0] is the empty string, which directs Python to search modules in the current directory first." So the empty string here is the current working directory (at the time the script is run?). ---------- nosy: +eric.snow _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 22:39:13 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 21:39:13 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation In-Reply-To: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> Message-ID: <1325972353.16.0.612346880682.issue13731@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: That's fine. I'm not particularly attached to that phrasing. The one thing I would push for is to add a comma to "... decimal is preferred in accounting applications which have strict equality invariants." ... since, as far as I can tell, "which have strict equality invariants" is supposed to be a parenthetical statement explaining why accounting applications prefer to use decimal arithmetic, rather than a constraints on the preference for decimal arithmetic to only those accounting applications that have "strict equality invariants". ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 23:32:27 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 22:32:27 +0000 Subject: [docs] [issue13050] RLock support the context manager protocol but this is not documented In-Reply-To: <1318172715.77.0.360303466185.issue13050@psf.upfronthosting.co.za> Message-ID: <1325975546.91.0.804213636309.issue13050@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: Here is a patch that adds an note about using Locks, RLocks, Conditions, and Semaphores as context managers to each of their descriptions as well as a link to the "Using locks, conditions, and semaphores in the with statement" section. ---------- keywords: +patch nosy: +zacherates versions: +Python 3.3 Added file: http://bugs.python.org/file24167/issue13050.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 23:42:38 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Sat, 07 Jan 2012 22:42:38 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation In-Reply-To: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> Message-ID: <1325976158.92.0.651444069723.issue13731@psf.upfronthosting.co.za> Raymond Hettinger added the comment: If you can't ascertain the meaning of the sentence, I'll consider making a change. Itherwise, this appears to have degenerated into trivial micro-wordsmithing and I'll close this as not being worth consuming any more of my time. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 23:47:33 2012 From: report at bugs.python.org (Aaron Maenpaa) Date: Sat, 07 Jan 2012 22:47:33 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation In-Reply-To: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> Message-ID: <1325976453.57.0.311234657811.issue13731@psf.upfronthosting.co.za> Aaron Maenpaa added the comment: I can understand what was meant. You're welcome to close the issue. Sorry for the nitpick. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 7 23:48:26 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Sat, 07 Jan 2012 22:48:26 +0000 Subject: [docs] [issue13731] Awkward phrasing in Decimal documentation In-Reply-To: <1325963806.67.0.168164997308.issue13731@psf.upfronthosting.co.za> Message-ID: <1325976506.72.0.468000029578.issue13731@psf.upfronthosting.co.za> Raymond Hettinger added the comment: No problem. Thanks for showing an interest in the quality of the documentation. ---------- resolution: -> rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 00:13:45 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Sat, 07 Jan 2012 23:13:45 +0000 Subject: [docs] [issue13050] RLock support the context manager protocol but this is not documented In-Reply-To: <1318172715.77.0.360303466185.issue13050@psf.upfronthosting.co.za> Message-ID: <1325978025.43.0.76903837517.issue13050@psf.upfronthosting.co.za> Raymond Hettinger added the comment: This edit looks reasonable. ---------- nosy: +rhettinger _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 12:59:59 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sun, 08 Jan 2012 11:59:59 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326023999.1.0.920150282309.issue12760@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: I intend to commit this patch within a couple days (unless anyone objects of course). ---------- stage: -> patch review _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 13:03:20 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 08 Jan 2012 12:03:20 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326024200.39.0.853101399157.issue13122@psf.upfronthosting.co.za> Sandro Tosi added the comment: Hi all, how can we fix it? or better, should we fix it? From a user POV, it is a weird to see 3.1 doc referring to 3.2 doc as "in development" then clicking on that link, being redirect to 3.3a0 doc and see there that 3.2 is stable (with no reference back to 3.1). Maybe we can adjust the sidebar in 3.1 references and do a manual rebuild or just wait for another security release? maybe we can discuss a policy for such things and write it in stone (aka devguide). ---------- nosy: +sandro.tosi _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 15:36:58 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Sun, 08 Jan 2012 14:36:58 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326033418.04.0.645986399942.issue12760@psf.upfronthosting.co.za> Antoine Pitrou added the comment: I don't think the "created()" method has to be exposed. People can inspect the "mode" attribute if they want to have that information. (besides, the semantics are misleading since a new file opened with "w" has also be created, but created() would return False) There's some bogus indentation in the patch (it uses tab characters in some places). Also: + if not (creating + reading or writing or appending): Not sure why the "+". Shouldn't it be "or" instead? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 17:08:42 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 08 Jan 2012 16:08:42 +0000 Subject: [docs] [issue13026] Dis module - documentation of MAKE_FUNCTION In-Reply-To: <1316642558.64.0.601129278503.issue13026@psf.upfronthosting.co.za> Message-ID: <1326038922.48.0.151518607059.issue13026@psf.upfronthosting.co.za> Sandro Tosi added the comment: Hi Arnaud, would you like to provide a patch to update the MAKE_FUNCTION opcode description? That would speed up a bit the fix-up. Also, I don't have that clear what "For each keyword only default, ..." mean: are those the default values for keyword arguments? something else? Thanks in advance, Sandro ---------- nosy: +sandro.tosi stage: -> needs patch versions: +Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 18:25:10 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sun, 08 Jan 2012 17:25:10 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326043508.95.0.025794266015.issue12760@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: Here's a new version of the patch that should address all the comments. ---------- Added file: http://bugs.python.org/file24179/open_create_x-3.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 18:39:12 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Sun, 08 Jan 2012 17:39:12 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1326043508.95.0.025794266015.issue12760@psf.upfronthosting.co.za> Message-ID: <1326044272.3374.24.camel@localhost.localdomain> Antoine Pitrou added the comment: > Here's a new version of the patch that should address all the comments. Just a small note: FileExistsError is raised, not exactly OSError, when the file exists. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 20:44:28 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sun, 08 Jan 2012 19:44:28 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326051867.92.0.677106025512.issue12760@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: > Just a small note: FileExistsError is raised, not exactly OSError, > when the file exists. I've updated the doc accordingly. ---------- stage: patch review -> commit review _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 21:40:38 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 08 Jan 2012 20:40:38 +0000 Subject: [docs] [issue13026] Dis module - documentation of MAKE_FUNCTION In-Reply-To: <1316642558.64.0.601129278503.issue13026@psf.upfronthosting.co.za> Message-ID: <1326055238.02.0.19378700044.issue13026@psf.upfronthosting.co.za> Terry J. Reedy added the comment: "For each keyword only default" is not in my text, but if you are referring to "keyword only name, default parameter object pairs ", yes. Here is a revised suggested wording: MAKE_FUNCTION(argc) Pushes a new function object on the stack. From bottom to top, the consumed stack must have have (argc & 0xFF) default argument objects in positional order, ((argc >> 8) & 0xFF) (name, default argument) pairs, with name just below the object on the stack, for keyword-only parameters, ((argc >> 16) & 0x7FFF) parameter annotation objects, a tuple listing the parameter names for the annotations, and finally a code object as TOS. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 22:12:59 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 08 Jan 2012 21:12:59 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326057179.03.0.679480715571.issue13122@psf.upfronthosting.co.za> Terry J. Reedy added the comment: http://docs.python.org/release/2.6.7/ has the same problem that the 3.x 'in development' version is called 3.2, while there is no link to current stable 3.2.2 except indirectly by going to 'old versions' (which perhaps should be 'other versions'). I do not know enough about frames to know how to future-proof the sidebar better. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 22:15:39 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Sun, 08 Jan 2012 21:15:39 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326057339.71.0.836605649843.issue13122@psf.upfronthosting.co.za> Antoine Pitrou added the comment: > Nobody said 3.2 was not stable... Well, the sidebar says it's in development while 2.7 is stable :) ---------- nosy: +pitrou _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 22:18:46 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 08 Jan 2012 21:18:46 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326057526.33.0.736124726566.issue13122@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Well, actually I do have an idea. When 3.3 comes out, I think docs.python.org should point to that, and another url should point to the most recent 2.7.x release. The url for all versions is already stable. Then the sidebar could have entries for most recent 3.x and 2.x releases (without specifying) and other versions. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 22:29:02 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 08 Jan 2012 21:29:02 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326058142.09.0.395885901793.issue13122@psf.upfronthosting.co.za> Terry J. Reedy added the comment: My specific suggestion is that the sidebar be time-independent (for at least a decade, until Python 4 ;-) and say Docs for other versions Current Python 3 Current Python 2 In development Everything else with stable links for each. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 22:33:48 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 08 Jan 2012 21:33:48 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326058428.01.0.475679882678.issue13122@psf.upfronthosting.co.za> Georg Brandl added the comment: Sounds good. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 8 22:42:51 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 08 Jan 2012 21:42:51 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326058971.11.0.934785873807.issue13122@psf.upfronthosting.co.za> Terry J. Reedy added the comment: To make my idea work both now and after we switch docs.python.org, that url should not be used as either of the first two links. Rather there should be a docs.python.org/py2k (or whatever) that is the permanent 'latest Python 2 release' docs link. ---------- _______________________________________ Python tracker _______________________________________ From rafael.wth at web.de Mon Jan 9 01:38:15 2012 From: rafael.wth at web.de (Rafael W.) Date: Mon, 9 Jan 2012 01:38:15 +0100 Subject: [docs] Typo in chapter 3 In-Reply-To: References: Message-ID: Sorry, of course this is correct. Never mind. Am 9. Januar 2012 01:36 schrieb Rafael W. : > Hello everybody, > in chapter 3 it says as code example: > > hello = r"This is a rather long string containing\n\ > several lines of text much as you would do in C." > > The extra 'r' before the quote should be a typo. > Best, Rafael From rafael.wth at web.de Mon Jan 9 01:36:43 2012 From: rafael.wth at web.de (Rafael W.) Date: Mon, 9 Jan 2012 01:36:43 +0100 Subject: [docs] Typo in chapter 3 Message-ID: Hello everybody, in chapter 3 it says as code example: hello = r"This is a rather long string containing\n\ several lines of text much as you would do in C." The extra 'r' before the quote should be a typo. Best, Rafael From Hoffmann.P at gmx.net Mon Jan 9 11:47:01 2012 From: Hoffmann.P at gmx.net (Peter Hoffmann) Date: Mon, 09 Jan 2012 11:47:01 +0100 Subject: [docs] Missing function createCDATASection Message-ID: <4F0AC5A5.5000207@gmx.net> Hy, is just found a function I was desperately looking for in the documentation and was only informed about its existence through google-search: createCDATASection() It is implemented in xml.dom.minidom but neither appears as part of the xml.dom - API nor the xml.dom.minidom difference-documenation. I assume that others would also be pretty glad to get to know this function. Thank you, Peter Hoffmann From report at bugs.python.org Mon Jan 9 12:45:16 2012 From: report at bugs.python.org (Neil Muller) Date: Mon, 09 Jan 2012 11:45:16 +0000 Subject: [docs] [issue9637] docs do not say that urllib uses HTTP_PROXY In-Reply-To: <1282196669.74.0.629180904202.issue9637@psf.upfronthosting.co.za> Message-ID: <1326109516.38.0.959596347911.issue9637@psf.upfronthosting.co.za> Neil Muller added the comment: This patch is now more than a year old with no comment. What needs to happen to get this bug fixed? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 14:06:18 2012 From: report at bugs.python.org (Sandro Tosi) Date: Mon, 09 Jan 2012 13:06:18 +0000 Subject: [docs] [issue13743] xml.dom.minidom.Document class is not documented Message-ID: <1326114378.06.0.424770823698.issue13743@psf.upfronthosting.co.za> New submission from Sandro Tosi : Hello, following up http://mail.python.org/pipermail/docs/2012-January/007026.html I noticed the whole Document class (and relative methods) is not documented. Maybe it is a choice to not document it, or maybe it's just a missing doc, dunno, the's why I'm opening this :) ---------- assignee: docs at python components: Documentation messages: 150935 nosy: docs at python, sandro.tosi priority: normal severity: normal stage: needs patch status: open title: xml.dom.minidom.Document class is not documented versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Mon Jan 9 14:07:16 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Mon, 9 Jan 2012 14:07:16 +0100 Subject: [docs] Missing function createCDATASection In-Reply-To: <4F0AC5A5.5000207@gmx.net> References: <4F0AC5A5.5000207@gmx.net> Message-ID: Hello Peter, thanks for your email. On Mon, Jan 9, 2012 at 11:47, Peter Hoffmann wrote: > Hy, > > is just found a function I was desperately looking for in the > documentation and was only informed about its existence through > google-search: > createCDATASection() > > It is implemented in xml.dom.minidom but neither appears as part of the > xml.dom - API nor the xml.dom.minidom difference-documenation. > I assume that others would also be pretty glad to get to know this function. I've just opened http://bugs.python.org/issue13743 to track your request (a bit expanded, actually). Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Mon Jan 9 14:34:22 2012 From: report at bugs.python.org (Barry A. Warsaw) Date: Mon, 09 Jan 2012 13:34:22 +0000 Subject: [docs] [issue13744] raw byte strings are described in a confusing way Message-ID: <1326116062.09.0.84789277908.issue13744@psf.upfronthosting.co.za> New submission from Barry A. Warsaw : The lexical analysis documentation says this: http://docs.python.org/py3k/reference/lexical_analysis.html?highlight=raw%20bytes "Bytes literals are always prefixed with 'b' or 'B';..." "Both string and bytes literals may optionally be prefixed with a letter 'r' or 'R';..." But that would lead you to believe that to get raw byte strings you should use rb"foo". In fact, that's a SyntaxError in Python 2.6+ and Python 3. What *does* work though is br"foo". Either Python should accept both spellings (harder) or the documentation should make it clear that the 'b' must preceded the 'r'. ---------- assignee: docs at python components: Documentation messages: 150936 nosy: barry, docs at python priority: normal severity: normal status: open title: raw byte strings are described in a confusing way versions: Python 2.7, Python 3.1, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 16:15:21 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Mon, 09 Jan 2012 15:15:21 +0000 Subject: [docs] [issue13744] raw byte strings are described in a confusing way In-Reply-To: <1326116062.09.0.84789277908.issue13744@psf.upfronthosting.co.za> Message-ID: <1326122121.12.0.749802610433.issue13744@psf.upfronthosting.co.za> Antoine Pitrou added the comment: > Either Python should accept both spellings +1. Been annoyed several times by this. ---------- nosy: +gvanrossum, pitrou _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 16:18:47 2012 From: report at bugs.python.org (Barry A. Warsaw) Date: Mon, 09 Jan 2012 15:18:47 +0000 Subject: [docs] [issue13744] raw byte strings are described in a confusing way In-Reply-To: <1326122121.12.0.749802610433.issue13744@psf.upfronthosting.co.za> Message-ID: <20120109161837.13e4a570@rivendell> Barry A. Warsaw added the comment: On Jan 09, 2012, at 03:15 PM, Antoine Pitrou wrote: > >Antoine Pitrou added the comment: > >> Either Python should accept both spellings > >+1. Been annoyed several times by this. The $64k question: is this a new feature or a bug? :) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 16:35:50 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Mon, 09 Jan 2012 15:35:50 +0000 Subject: [docs] [issue13744] raw byte strings are described in a confusing way In-Reply-To: <1326116062.09.0.84789277908.issue13744@psf.upfronthosting.co.za> Message-ID: <1326123350.78.0.424322163056.issue13744@psf.upfronthosting.co.za> Antoine Pitrou added the comment: > The $64k question: is this a new feature or a bug? :) Most certainly a feature... ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 16:44:35 2012 From: report at bugs.python.org (Barry A. Warsaw) Date: Mon, 09 Jan 2012 15:44:35 +0000 Subject: [docs] [issue13744] raw byte strings are described in a confusing way In-Reply-To: <1326123350.78.0.424322163056.issue13744@psf.upfronthosting.co.za> Message-ID: <20120109164429.43ef6842@rivendell> Barry A. Warsaw added the comment: On Jan 09, 2012, at 03:35 PM, Antoine Pitrou wrote: > >Antoine Pitrou added the comment: > >> The $64k question: is this a new feature or a bug? :) > >Most certainly a feature... In that case, since we can only add the new prefixes to 3.3, I still think we need to fix the documentation to remove the confusion for stable releases. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 17:01:38 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 09 Jan 2012 16:01:38 +0000 Subject: [docs] [issue13682] Documentation of os.fdopen() refers to non-existing bufsize argument of builtin open() In-Reply-To: <1325244968.02.0.142917484563.issue13682@psf.upfronthosting.co.za> Message-ID: <1326124898.83.0.869867801228.issue13682@psf.upfronthosting.co.za> Changes by ?ric Araujo : ---------- nosy: +eric.araujo _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 17:13:23 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 09 Jan 2012 16:13:23 +0000 Subject: [docs] [issue12207] Document ast.PyCF_ONLY_AST In-Reply-To: <1306689830.34.0.885575322408.issue12207@psf.upfronthosting.co.za> Message-ID: <1326125603.57.0.82154058401.issue12207@psf.upfronthosting.co.za> ?ric Araujo added the comment: FWIW this issue was also noted by Terry in #4118, but there was no reply. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 17:13:43 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 09 Jan 2012 16:13:43 +0000 Subject: [docs] [issue1612012] builtin compile() doc needs PyCF_DONT_IMPLY_DEDENT Message-ID: <1326125623.65.0.643362736293.issue1612012@psf.upfronthosting.co.za> Changes by ?ric Araujo : ---------- nosy: +eric.araujo _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 17:22:02 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 09 Jan 2012 16:22:02 +0000 Subject: [docs] [issue13677] correct docstring for builtin compile In-Reply-To: <1325180963.04.0.479072583529.issue13677@psf.upfronthosting.co.za> Message-ID: <1326126122.82.0.96653779604.issue13677@psf.upfronthosting.co.za> ?ric Araujo added the comment: The compiler flags are not really documented in the ast module doc or anywhere: see #12207 and #1612012. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 19:29:09 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Mon, 09 Jan 2012 18:29:09 +0000 Subject: [docs] [issue9637] docs do not say that urllib uses HTTP_PROXY In-Reply-To: <1282196669.74.0.629180904202.issue9637@psf.upfronthosting.co.za> Message-ID: <1326133749.88.0.694456054214.issue9637@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Senthil, any comment on this? ---------- nosy: +orsenthil _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 19:38:40 2012 From: report at bugs.python.org (Senthil Kumaran) Date: Mon, 09 Jan 2012 18:38:40 +0000 Subject: [docs] [issue9637] docs do not say that urllib uses HTTP_PROXY In-Reply-To: <1282196669.74.0.629180904202.issue9637@psf.upfronthosting.co.za> Message-ID: <1326134319.94.0.738113011092.issue9637@psf.upfronthosting.co.za> Senthil Kumaran added the comment: Sorry, this escaped for so long. First thing is, having different values for HTTP_PROXY and HTTP_proxy and http_proxy is plain wrong at the user side. They all should be same and in that case the possible problem which Kirikaza and Neil Muller state is extremely unlikely (and if the user faces any issue, it is due to improper HTTP configuration). The reason that lowering of environ vars is performed is similar to any string match with input from user where we want to ignore the case sensitivity. Having said that, I think, I shall just add teh info on lowering and verification of proxy environment to the docs. I am -1 on changing any behavior for this issue. ---------- assignee: docs at python -> orsenthil _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 20:59:39 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Mon, 09 Jan 2012 19:59:39 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326139179.84.0.49246565533.issue11633@psf.upfronthosting.co.za> Terry J. Reedy added the comment: The current doc says "print([object, ...], *, sep=' ', end='\n', file=sys.stdout) Print object(s) to the stream file, separated by sep and followed by end. sep, end and file, if present, must be given as keyword arguments. All non-keyword arguments are converted to strings like str() does and written to the stream, separated by sep and followed by end. Both sep and end must be strings; they can also be None, which means to use the default values. If no object is given, print() will just write end. The file argument must be an object with a write(string) method; if it is not present or None, sys.stdout will be used." (The bit about None, said twice, could be factored out and said once after the second sentence.) This is exactly what print does and Guido today (Python ideas) said that is what it should do and that "Apps that need flushing should call flush()." So a code change is rejected. The issue title was incorrect. The print function does not do any buffering. The file object it writes to may. Even sys.stdout may or may not. We could add at the end a sentence or two something like "Output buffering is determined by *file*. Call file.flush() to ensure, for instance, immediate appearance on a screen." ---------- assignee: -> docs at python components: +Documentation -Interpreter Core nosy: +docs at python stage: -> needs patch title: Document that print buffers output when end='' -> Document that print may need explicit flushing _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 21:02:43 2012 From: report at bugs.python.org (Amaury Forgeot d'Arc) Date: Mon, 09 Jan 2012 20:02:43 +0000 Subject: [docs] [issue13729] Evaluation order for dics key/value In-Reply-To: <1325952332.37.0.223922022645.issue13729@psf.upfronthosting.co.za> Message-ID: <1326139363.13.0.742830698319.issue13729@psf.upfronthosting.co.za> Amaury Forgeot d'Arc added the comment: This is a duplicate of issue11205. ---------- nosy: +amaury.forgeotdarc resolution: -> duplicate status: open -> closed superseder: -> Evaluation order of dictionary display is different from reference manual. _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 9 22:40:39 2012 From: report at bugs.python.org (Roundup Robot) Date: Mon, 09 Jan 2012 21:40:39 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset bf609baff4d3 by Charles-Fran?ois Natali in branch 'default': Issue #12760: Add a create mode to open(). Patch by David Townshend. http://hg.python.org/cpython/rev/bf609baff4d3 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 01:48:43 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Tue, 10 Jan 2012 00:48:43 +0000 Subject: [docs] [issue11948] Tutorial/Modules - small fix to better clarify the modules search path In-Reply-To: <1304011111.24.0.834772686878.issue11948@psf.upfronthosting.co.za> Message-ID: <1326156523.03.0.112485567014.issue11948@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Sandro, I think you can apply this. ---------- versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 04:12:00 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Tue, 10 Jan 2012 03:12:00 +0000 Subject: [docs] [issue11418] Method's global scope is module containing function definition, not class. In-Reply-To: <1299454101.64.0.841920247259.issue11418@psf.upfronthosting.co.za> Message-ID: <1326165119.96.0.122243773085.issue11418@psf.upfronthosting.co.za> Terry J. Reedy added the comment: This paragraph follows a discussion and example of the fact that methods do *not* have to be defined within a class statement. Any objections to changing "The global scope associated with a method is the module containing the class definition. (The class itself is never used as a global scope.)" to "The global scope associated with a method is the module containing its definition. (A class is never used as a global scope.)" ? ---------- versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 04:52:41 2012 From: report at bugs.python.org (py.user) Date: Tue, 10 Jan 2012 03:52:41 +0000 Subject: [docs] [issue13753] str.join description contains an incorrect reference to argument Message-ID: <1326167561.64.0.37328706988.issue13753@psf.upfronthosting.co.za> New submission from py.user : http://docs.python.org/py3k/library/stdtypes.html#str.join str.join(iterable)? Return a string which is the concatenation of the strings in the iterable iterable. A TypeError will be raised if there are any non-string values in seq, including bytes objects. The separator between elements is the string providing this method. "non-string values in seq" -> "non-string values in iterable" ---------- assignee: docs at python components: Documentation messages: 150999 nosy: docs at python, py.user priority: normal severity: normal status: open title: str.join description contains an incorrect reference to argument versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 04:59:55 2012 From: report at bugs.python.org (py.user) Date: Tue, 10 Jan 2012 03:59:55 +0000 Subject: [docs] [issue13754] str.ljust and str.rjust do not exactly describes original string return Message-ID: <1326167995.85.0.0875969790457.issue13754@psf.upfronthosting.co.za> New submission from py.user : http://docs.python.org/py3k/library/stdtypes.html#str.ljust str.ljust(width[, fillchar])? Return the string left justified in a string of length width. Padding is done using the specified fillchar (default is a space). The original string is returned if width is less than len(s). str.rjust(width[, fillchar])? Return the string right justified in a string of length width. Padding is done using the specified fillchar (default is a space). The original string is returned if width is less than len(s). "less than len(s)" -> "less than or equal to len(s)" ---------- assignee: docs at python components: Documentation messages: 151000 nosy: docs at python, py.user priority: normal severity: normal status: open title: str.ljust and str.rjust do not exactly describes original string return versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 05:04:53 2012 From: report at bugs.python.org (py.user) Date: Tue, 10 Jan 2012 04:04:53 +0000 Subject: [docs] [issue13754] str.ljust and str.rjust do not exactly describes original string return In-Reply-To: <1326167995.85.0.0875969790457.issue13754@psf.upfronthosting.co.za> Message-ID: <1326168293.73.0.739369650668.issue13754@psf.upfronthosting.co.za> py.user added the comment: str.zfill also ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 06:45:11 2012 From: report at bugs.python.org (INADA Naoki) Date: Tue, 10 Jan 2012 05:45:11 +0000 Subject: [docs] [issue11418] Method's global scope is module containing function definition, not class. In-Reply-To: <1326165119.96.0.122243773085.issue11418@psf.upfronthosting.co.za> Message-ID: INADA Naoki added the comment: > Any objections to changing > > "The global scope associated with a method is the module containing the class definition. (The class itself is never used as a global scope.)" > > to > > "The global scope associated with a method is the module containing its definition. (A class is never used as a global scope.)" > > ? +1 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 08:57:39 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Tue, 10 Jan 2012 07:57:39 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326182259.36.0.557156764656.issue12760@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: Committed. David, thanks for the patch! ---------- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 18:30:40 2012 From: report at bugs.python.org (Roundup Robot) Date: Tue, 10 Jan 2012 17:30:40 +0000 Subject: [docs] [issue9637] docs do not say that urllib uses HTTP_PROXY In-Reply-To: <1282196669.74.0.629180904202.issue9637@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 3370fa13ed73 by Senthil Kumaran in branch '3.2': Issue9637 - Explain in getproxies_environment that _proxy environ variable case does not matter. http://hg.python.org/cpython/rev/3370fa13ed73 New changeset eb028b3c62c9 by Senthil Kumaran in branch 'default': Merge from 3.2 - Issue9637 - Explain in getproxies_environment that _proxy environ variable case does not matter. http://hg.python.org/cpython/rev/eb028b3c62c9 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 18:35:22 2012 From: report at bugs.python.org (Roundup Robot) Date: Tue, 10 Jan 2012 17:35:22 +0000 Subject: [docs] [issue9637] docs do not say that urllib uses HTTP_PROXY In-Reply-To: <1282196669.74.0.629180904202.issue9637@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 4a30eae3b945 by Senthil Kumaran in branch '2.7': port to 2.7 - Issue9637 - Details that case of Proxy env var does not matter. http://hg.python.org/cpython/rev/4a30eae3b945 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 18:39:26 2012 From: report at bugs.python.org (Senthil Kumaran) Date: Tue, 10 Jan 2012 17:39:26 +0000 Subject: [docs] [issue9637] docs do not say that urllib uses HTTP_PROXY In-Reply-To: <1282196669.74.0.629180904202.issue9637@psf.upfronthosting.co.za> Message-ID: <1326217166.7.0.980087775753.issue9637@psf.upfronthosting.co.za> Senthil Kumaran added the comment: This is fixed. Thanks for your contribution. ---------- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 20:13:58 2012 From: report at bugs.python.org (Steven Bethard) Date: Tue, 10 Jan 2012 19:13:58 +0000 Subject: [docs] [issue13685] argparse does not sanitize help strings for % signs In-Reply-To: <1325284167.16.0.584942168313.issue13685@psf.upfronthosting.co.za> Message-ID: <1326222838.88.0.836045249714.issue13685@psf.upfronthosting.co.za> Steven Bethard added the comment: Eric's suggested doc fix looks good to me. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 10 20:37:33 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Tue, 10 Jan 2012 19:37:33 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326224253.42.0.267965751848.issue12760@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: Nick suggested to call the new flag "exclusive create" in the doc (and explain in whatsnew that it's based C11 new 'x' flag). Could someone please check the attached patch? My wording sounds really clumsy, so I'd prefer if a native speaker could review it. ---------- nosy: +ncoghlan Added file: http://bugs.python.org/file24195/x_flag.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 09:00:29 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 11 Jan 2012 08:00:29 +0000 Subject: [docs] [issue13754] str.ljust and str.rjust do not exactly describes original string return In-Reply-To: <1326167995.85.0.0875969790457.issue13754@psf.upfronthosting.co.za> Message-ID: <1326268829.46.0.0773778486757.issue13754@psf.upfronthosting.co.za> Terry J. Reedy added the comment: The short doc strings do not mention the issue either way. I think it ok to leave them as they are. While the claim is how the functions *should* operate, I verified that it is how they *do* operate in all three branches. ---------- assignee: docs at python -> terry.reedy keywords: +easy, patch nosy: +terry.reedy stage: -> needs patch versions: +Python 2.7, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 09:00:47 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 11 Jan 2012 08:00:47 +0000 Subject: [docs] [issue13753] str.join description contains an incorrect reference to argument In-Reply-To: <1326167561.64.0.37328706988.issue13753@psf.upfronthosting.co.za> Message-ID: <1326268847.79.0.574353962717.issue13753@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- assignee: docs at python -> terry.reedy keywords: +easy, patch nosy: +terry.reedy versions: +Python 2.7, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 09:08:24 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 11 Jan 2012 08:08:24 +0000 Subject: [docs] [issue13753] str.join description contains an incorrect reference to argument In-Reply-To: <1326167561.64.0.37328706988.issue13753@psf.upfronthosting.co.za> Message-ID: <1326269304.46.0.769816923683.issue13753@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- versions: -Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 09:33:44 2012 From: report at bugs.python.org (Roundup Robot) Date: Wed, 11 Jan 2012 08:33:44 +0000 Subject: [docs] [issue13754] str.ljust and str.rjust do not exactly describes original string return In-Reply-To: <1326167995.85.0.0875969790457.issue13754@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 3aed8787ce5c by Terry Jan Reedy in branch '2.7': Closes #13754 String returned if less than *or equal to* x 3 http://hg.python.org/cpython/rev/3aed8787ce5c New changeset 3f2e5fd17b76 by Terry Jan Reedy in branch '3.2': #13754 String returned if less than *or equal to* x 3 http://hg.python.org/cpython/rev/3f2e5fd17b76 New changeset 0df85a2ebe4d by Terry Jan Reedy in branch 'default': Merge with 3.2 http://hg.python.org/cpython/rev/0df85a2ebe4d ---------- nosy: +python-dev resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 09:42:19 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 11 Jan 2012 08:42:19 +0000 Subject: [docs] [issue13753] str.join description contains an incorrect reference to argument In-Reply-To: <1326167561.64.0.37328706988.issue13753@psf.upfronthosting.co.za> Message-ID: <1326271339.42.0.620718785927.issue13753@psf.upfronthosting.co.za> Terry J. Reedy added the comment: See #13754 for commits (not here because 'close' != 'closes' or closed') ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 11:11:18 2012 From: report at bugs.python.org (Tshepang Lekhonkhobe) Date: Wed, 11 Jan 2012 10:11:18 +0000 Subject: [docs] [issue13124] Add "Running a Build Slave" page to the devguide In-Reply-To: <1318011517.56.0.343886781977.issue13124@psf.upfronthosting.co.za> Message-ID: <1326276678.63.0.580458408814.issue13124@psf.upfronthosting.co.za> Changes by Tshepang Lekhonkhobe : ---------- nosy: +tshepang _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 11:15:46 2012 From: report at bugs.python.org (Tshepang Lekhonkhobe) Date: Wed, 11 Jan 2012 10:15:46 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326276946.69.0.0517237397804.issue12409@psf.upfronthosting.co.za> Changes by Tshepang Lekhonkhobe : ---------- nosy: +tshepang _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 11:26:12 2012 From: report at bugs.python.org (Tshepang Lekhonkhobe) Date: Wed, 11 Jan 2012 10:26:12 +0000 Subject: [docs] [issue13275] Recommend xml.etree for XML processing In-Reply-To: <1319709959.84.0.984784684468.issue13275@psf.upfronthosting.co.za> Message-ID: <1326277572.23.0.823429915717.issue13275@psf.upfronthosting.co.za> Changes by Tshepang Lekhonkhobe : ---------- nosy: +tshepang _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 11:27:24 2012 From: report at bugs.python.org (Tshepang Lekhonkhobe) Date: Wed, 11 Jan 2012 10:27:24 +0000 Subject: [docs] [issue13275] Recommend xml.etree for XML processing In-Reply-To: <1319709959.84.0.984784684468.issue13275@psf.upfronthosting.co.za> Message-ID: <1326277643.83.0.675397721942.issue13275@psf.upfronthosting.co.za> Tshepang Lekhonkhobe added the comment: @Araujo bit offtopic, but which XML library have you found most elegant? Is it available in the stdlib? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 11:59:14 2012 From: report at bugs.python.org (Tshepang Lekhonkhobe) Date: Wed, 11 Jan 2012 10:59:14 +0000 Subject: [docs] [issue13766] explain the relationship between Lib/lib2to3/Grammar.txt and Grammar/Grammar Message-ID: <1326279554.15.0.713951578682.issue13766@psf.upfronthosting.co.za> New submission from Tshepang Lekhonkhobe : Lib/lib2to3/Grammar.txt seems like a modified copy of Grammar/Grammar. Can you state so somewhere, maybe in the beginning of Lib/lib2to3/Grammar.txt (the Note section). One problem with the way it is now, is that there are changes done to Grammar/Grammar that are not put into Lib/lib2to3/Grammar.txt. Maybe they are minor, but I think we don't want them diverging too much. Another problem is that the Note on Lib/lib2to3/Grammar.txt maybe irrelevant, since this is not the authoritative Grammar file. ---------- assignee: docs at python components: Documentation messages: 151055 nosy: docs at python, tshepang priority: normal severity: normal status: open title: explain the relationship between Lib/lib2to3/Grammar.txt and Grammar/Grammar type: enhancement _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 13:29:46 2012 From: report at bugs.python.org (Tshepang Lekhonkhobe) Date: Wed, 11 Jan 2012 12:29:46 +0000 Subject: [docs] [issue12779] Update packaging documentation In-Reply-To: <1313686169.0.0.406072932055.issue12779@psf.upfronthosting.co.za> Message-ID: <1326284986.72.0.0384863612672.issue12779@psf.upfronthosting.co.za> Changes by Tshepang Lekhonkhobe : ---------- nosy: +tshepang _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 17:41:19 2012 From: report at bugs.python.org (=?utf-8?b?0JzQsNGA0Log0JrQvtGA0LXQvdCx0LXRgNCz?=) Date: Wed, 11 Jan 2012 16:41:19 +0000 Subject: [docs] [issue13769] json.dump(ensure_ascii=False) return str instead of unicode Message-ID: <1326300079.82.0.279410736545.issue13769@psf.upfronthosting.co.za> New submission from ???? ????????? : $ ipython In [1]: type(json.dumps({'a':'b'}, ensure_ascii=False)) Out[1]: In [2]: type(json.dumps({'a':u'b'}, ensure_ascii=False)) Out[2]: ----------------------- Documentation: If ensure_ascii is False, then the return value will be a unicode instance. -------------------------------- Not applicable to python3 ---------- assignee: docs at python components: Documentation, Library (Lib) messages: 151066 nosy: docs at python, mmarkk priority: normal severity: normal status: open title: json.dump(ensure_ascii=False) return str instead of unicode type: behavior versions: Python 2.6, Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 17:42:11 2012 From: report at bugs.python.org (=?utf-8?b?0JzQsNGA0Log0JrQvtGA0LXQvdCx0LXRgNCz?=) Date: Wed, 11 Jan 2012 16:42:11 +0000 Subject: [docs] [issue13770] python3 & json: add ensure_ascii documentation Message-ID: <1326300131.17.0.750918490995.issue13770@psf.upfronthosting.co.za> New submission from ???? ????????? : Please fix documentation about ensure_ascii. Does it have any meaning in python3? ---------- assignee: docs at python components: Documentation messages: 151067 nosy: docs at python, mmarkk priority: normal severity: normal status: open title: python3 & json: add ensure_ascii documentation versions: Python 3.1, Python 3.2, Python 3.3, Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 17:42:40 2012 From: report at bugs.python.org (=?utf-8?b?0JzQsNGA0Log0JrQvtGA0LXQvdCx0LXRgNCz?=) Date: Wed, 11 Jan 2012 16:42:40 +0000 Subject: [docs] [issue13770] python3 & json: add ensure_ascii documentation In-Reply-To: <1326300131.17.0.750918490995.issue13770@psf.upfronthosting.co.za> Message-ID: <1326300160.32.0.355328053247.issue13770@psf.upfronthosting.co.za> Changes by ???? ????????? : ---------- type: -> enhancement _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 20:15:16 2012 From: report at bugs.python.org (Roundup Robot) Date: Wed, 11 Jan 2012 19:15:16 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset bc043cef94f2 by Terry Jan Reedy in branch '3.2': Closes #11633 Clarify print buffering. http://hg.python.org/cpython/rev/bc043cef94f2 New changeset fb0d61fd1753 by Terry Jan Reedy in branch 'default': Merge with 3.2 http://hg.python.org/cpython/rev/fb0d61fd1753 ---------- nosy: +python-dev resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 20:16:36 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Wed, 11 Jan 2012 19:16:36 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326309396.58.0.792430967995.issue11633@psf.upfronthosting.co.za> Terry J. Reedy added the comment: #13761 proposes to add flush=False param with option for True. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 20:22:01 2012 From: report at bugs.python.org (=?utf-8?q?Martin_v=2E_L=C3=B6wis?=) Date: Wed, 11 Jan 2012 19:22:01 +0000 Subject: [docs] [issue13769] json.dump(ensure_ascii=False) return str instead of unicode In-Reply-To: <1326300079.82.0.279410736545.issue13769@psf.upfronthosting.co.za> Message-ID: <1326309721.92.0.972644218764.issue13769@psf.upfronthosting.co.za> Changes by Martin v. L?wis : ---------- versions: -Python 2.6 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 20:57:47 2012 From: report at bugs.python.org (Roundup Robot) Date: Wed, 11 Jan 2012 19:57:47 +0000 Subject: [docs] [issue11418] Method's global scope is module containing function definition, not class. In-Reply-To: <1299454101.64.0.841920247259.issue11418@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 10a5165103f9 by Terry Jan Reedy in branch '2.7': Minor correction. Closes #11418 http://hg.python.org/cpython/rev/10a5165103f9 New changeset 32ea3675fba2 by Terry Jan Reedy in branch '3.2': Minor correction. #11418 http://hg.python.org/cpython/rev/32ea3675fba2 ---------- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 11 20:59:16 2012 From: report at bugs.python.org (Sandro Tosi) Date: Wed, 11 Jan 2012 19:59:16 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326311956.18.0.211337489029.issue12409@psf.upfronthosting.co.za> Sandro Tosi added the comment: Hi, i'm at last back with some work to show; I've integrated all the "Documenting python" doc into devguide, and the commits are in this sandbox: http://hg.python.org/sandbox/morph-devguide/shortlog/a92d431ef749 (`documenting` branch). I took the files from default branch and merged all of them in a single page. It might be a bit log, but it has the advantage (at least for me) that there you can find all the info you need for documenting python, a ctrl+f works and you don't need to follow tons of links to find what you're looking for. then I've removed all the info from default branch (here: http://hg.python.org/sandbox/morph/shortlog/e9a4276b19d4 in default-documenting branch) which left only documenting/index.rst as mainly a reference to the devguide. I don't know what would be the best way to handle this transition on the python doc side, maybe converting that to a simple Doc/documenting.rst as it's now index.rst? but what text to left? Comments are very welcome! ---------- stage: needs patch -> patch review _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 02:26:40 2012 From: report at bugs.python.org (Cameron Simpson) Date: Thu, 12 Jan 2012 01:26:40 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326331600.34.0.630580174359.issue11633@psf.upfronthosting.co.za> Changes by Cameron Simpson : ---------- nosy: +cameron _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 07:04:54 2012 From: report at bugs.python.org (David Townshend) Date: Thu, 12 Jan 2012 06:04:54 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: <1326348294.26.0.290797017439.issue12760@psf.upfronthosting.co.za> David Townshend added the comment: I've done a bit or rewording in the io docs, but I honestly don't know if this is any better that what you already had! ---------- Added file: http://bugs.python.org/file24210/x_diff2.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 08:11:24 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 12 Jan 2012 07:11:24 +0000 Subject: [docs] [issue13724] socket.create_connection and multiple IP addresses In-Reply-To: <1325888030.3.0.0416342115288.issue13724@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 5594cd88bfed by Antoine Pitrou in branch '3.2': Issue #13724: improve documentation for socket.create_connection. http://hg.python.org/cpython/rev/5594cd88bfed New changeset 43d08528223c by Antoine Pitrou in branch 'default': Issue #13724: improve documentation for socket.create_connection. http://hg.python.org/cpython/rev/43d08528223c New changeset 60e77810a47e by Antoine Pitrou in branch '2.7': Issue #13724: improve documentation for socket.create_connection. http://hg.python.org/cpython/rev/60e77810a47e ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 08:11:53 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Thu, 12 Jan 2012 07:11:53 +0000 Subject: [docs] [issue13724] socket.create_connection and multiple IP addresses In-Reply-To: <1325888030.3.0.0416342115288.issue13724@psf.upfronthosting.co.za> Message-ID: <1326352313.66.0.148088686141.issue13724@psf.upfronthosting.co.za> Antoine Pitrou added the comment: Wording fixed, thank you. ---------- versions: +Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 08:12:00 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Thu, 12 Jan 2012 07:12:00 +0000 Subject: [docs] [issue13724] socket.create_connection and multiple IP addresses In-Reply-To: <1325888030.3.0.0416342115288.issue13724@psf.upfronthosting.co.za> Message-ID: <1326352320.55.0.390617345271.issue13724@psf.upfronthosting.co.za> Changes by Antoine Pitrou : ---------- resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 14:19:26 2012 From: report at bugs.python.org (Mads Kiilerich) Date: Thu, 12 Jan 2012 13:19:26 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1251103521.34.0.917057608479.issue6774@psf.upfronthosting.co.za> Message-ID: <1326374366.74.0.206883959365.issue6774@psf.upfronthosting.co.za> Mads Kiilerich added the comment: I was scared by the note in the documentation and wondered if the socket Python API was completely incapable of handling half-closed connections cross platform. pitrou helped me on IRC to track the note down to this issue. IMO the bug report should have been rejected and the documentation patch should be removed. It shouldn't be that surprising that shutting something down that already has been shutdown (by the peer) will fail. I don't see any indication that a "shutdown call closes the connection on the other half". It makes it half-closed as it should - and if it did anything else (which the note indicates) then it would be a big violation of BSD TCP API. Ok, it might be slightly surprising that the next shutdown on the other end fails, but that is fully covered by "Note Some behavior may be platform dependent, since calls are made to the operating system socket APIs." It is not specific to Python in any way, AFAICT. If anything it could just say something like "Note that shutdown of a socket that already has been shut down by the peer is platform dependent and might fail." ---------- nosy: +kiilerix, pitrou title: socket.shudown documentation: on some platforms, closing one half closes the other half -> socket.shutdown documentation: on some platforms, closing one half closes the other half _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 14:24:13 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Thu, 12 Jan 2012 13:24:13 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1251103521.34.0.917057608479.issue6774@psf.upfronthosting.co.za> Message-ID: <1326374653.71.0.630431665147.issue6774@psf.upfronthosting.co.za> Changes by Antoine Pitrou : ---------- nosy: +neologix _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 17:35:26 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Thu, 12 Jan 2012 16:35:26 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326386126.16.0.595709523629.issue12409@psf.upfronthosting.co.za> ?ric Araujo added the comment: Could you provide a single patch or publish your version somewhere to help reviews? For the CPython docs, I think just removing the whole of Doc/documenting would be okay, or if we expect that people will go to that URI we may leave a placeholder page with only links. Georg? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 18:10:55 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Thu, 12 Jan 2012 17:10:55 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326388255.6.0.573752741873.issue11633@psf.upfronthosting.co.za> ?ric Araujo added the comment: I agree with the python-ideas message that ``sys.stdout.flush()`` is surprising / possibly misleading and should be ``file.flush()``. If the other bug report about adding a flush argument is rejected, please consider this. Thanks :) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 18:27:27 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 12 Jan 2012 17:27:27 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326389247.43.0.923309309968.issue12409@psf.upfronthosting.co.za> Sandro Tosi added the comment: Sure, sorry I didn't make it before; here attached the 2 patches, one against devguide, the other to default cpython repo. ---------- keywords: +patch Added file: http://bugs.python.org/file24218/doc2devguide-devguide.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 18:27:45 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 12 Jan 2012 17:27:45 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326389263.08.0.457124280458.issue12409@psf.upfronthosting.co.za> Changes by Sandro Tosi : Added file: http://bugs.python.org/file24219/doc2devguide-cpython.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 20:40:43 2012 From: report at bugs.python.org (Meador Inge) Date: Thu, 12 Jan 2012 19:40:43 +0000 Subject: [docs] [issue13709] Capitalization mistakes in the documentation for ctypes In-Reply-To: <1325645203.91.0.562347938508.issue13709@psf.upfronthosting.co.za> Message-ID: <1326397243.33.0.0854750088789.issue13709@psf.upfronthosting.co.za> Changes by Meador Inge : ---------- components: +ctypes nosy: +meador.inge stage: -> needs patch type: -> enhancement _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 20:48:01 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Thu, 12 Jan 2012 19:48:01 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1251103521.34.0.917057608479.issue6774@psf.upfronthosting.co.za> Message-ID: <1326397681.31.0.398313708103.issue6774@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: > I was scared by the note in the documentation and wondered if the > socket Python API was completely incapable of handling half-closed > connections cross platform. [...] > It makes it half-closed as it should Indeed. Calling shutdown(SHUT_WR) doesn't close the other end (which doesn't make much sense), it just sends a FIN (or RST depending on the context). It's the other end which decides to return ENOTCONN upon shutdown(SHUT_RD) on OS X, which is questionable (not sure it's against the BSD socket API, since shutdown(SHUT_RD) doesn't have any counterpart in the TCP layer). I also find this note confusing and scary for no good reason, and since I don't think we should document every OS idiosyncrasies, it would probably be better to revert it. I'll leave this open for a couple days to see if anyone objects, otherwise I'll revert it. ---------- resolution: accepted -> status: closed -> open _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 20:52:07 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 12 Jan 2012 19:52:07 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 4a767054551b by Terry Jan Reedy in branch '3.2': #11633 At least 2 people prefer earlier revision. http://hg.python.org/cpython/rev/4a767054551b New changeset 22688f5f9d0f by Terry Jan Reedy in branch 'default': Merge #11633 At least 2 people prefer earlier revision. http://hg.python.org/cpython/rev/22688f5f9d0f ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 12 22:16:22 2012 From: report at bugs.python.org (Nicolas Dumazet) Date: Thu, 12 Jan 2012 21:16:22 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1251103521.34.0.917057608479.issue6774@psf.upfronthosting.co.za> Message-ID: <1326402982.11.0.0757175288221.issue6774@psf.upfronthosting.co.za> Nicolas Dumazet added the comment: > It's the other end which decides to return ENOTCONN upon shutdown(SHUT_RD) on OS X, which is questionable > (not sure it's against the BSD socket API, since shutdown(SHUT_RD) doesn't have any counterpart in the TCP layer). Exactly. The same code raises a socket.error in one platform (mac os) and not on another (linux). Why not document this questionable behavior? I'm sorry, I realize that my original patch was imprecise. I'm not an expert here, and I simply read http://svn.python.org/view/python/trunk/Lib/test/test_socket.py?r1=64125&r2=68611&pathrev=68611 . Ok, fine -- it doesn't close the other end per se, but shutdown(SH_RD) after a FIN on MacOS raises a socket.error . This is questionable, unexpected, and should be documented. If possible, I'd like to push for a rewording instead of a revert. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 10:08:09 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Fri, 13 Jan 2012 09:08:09 +0000 Subject: [docs] [issue10344] codecs.readline doesn't care buffering=0 In-Reply-To: <1289084418.05.0.231852584468.issue10344@psf.upfronthosting.co.za> Message-ID: <1326445688.11.0.3915279075.issue10344@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Something seems wrong somewhere. First, codecs.open(filename, mode[, encoding[, errors[, buffering]]]) in the doc, should be, to match the code, in the current sytle codecs.open(filename, mode='rb', encoding=None, errors='strict', buffering=1) The other entries below follow this style. The Note says "Files are always opened in binary mode, even if no binary mode was specified.". However, the code is if encoding is not None and \ 'b' not in mode: # Force opening of the file in binary mode mode = mode + 'b' so the forcing only happens when an encoding is given. Since the intent is that codecs.open == open when no encoding is given, I believe the Note should be revised rather than the code. (buffering=1) means line buffered. However, the doc for builtin open() says about buffering "1 to select line buffering (only usable in text mode)" So the default buffering is one that is not usable in the normal forced binary mode. Marc-Andre, can you explain this? (The doc for open() does not specify what happens when the buffering conflicts with the mode.) The doc for StreamReader.readline() says ""size, if given, is passed as size argument to the stream?s readline() method.". If that were true, size would the max bytes to read. However, the docstring for the same in codecs.py says "size, if given, is passed as size argument to the read() method.", and that is what the code does. If not given, 72 is used as the default. (Why not 80?) So, while the doc needs a minor tweak, I do not see what the OP's posted original result has to do with buffering. .readline does not have a fixed internal buffer of 72 chars that I can see. Rather, that is the default number of chars to read. So that is what it read, given that the file is longer than that. I believe this is what Marc-Andre said, in different words, in his first post, in between the distraction of whether to remove open. Santiago, yes, there is a difference between open.readline and codecs.readline. It will be more obvious when the codecs.readline size doc is corrected to specify that it is passed to read(), not readline(), and that it defaults to 72. ---------- versions: +Python 3.3 -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 10:16:55 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Fri, 13 Jan 2012 09:16:55 +0000 Subject: [docs] [issue10344] codecs.StreamReader.readline doc needs fix In-Reply-To: <1289084418.05.0.231852584468.issue10344@psf.upfronthosting.co.za> Message-ID: <1326446215.36.0.890871257557.issue10344@psf.upfronthosting.co.za> Terry J. Reedy added the comment: What I described is the behavior of codecs.StreamReader. However, the streamreader associated with a particular encoding(codec) might do differently. My understanding is that StreamReader is an example that a particular codec can use, derive from, or merely mimic the interface of. ---------- title: codecs.readline doesn't care buffering=0 -> codecs.StreamReader.readline doc needs fix _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 12:03:09 2012 From: report at bugs.python.org (patrick vrijlandt) Date: Fri, 13 Jan 2012 11:03:09 +0000 Subject: [docs] [issue13779] os.walk: bottom-up Message-ID: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> New submission from patrick vrijlandt : PythonWin 3.2 (r32:88445, Feb 20 2011, 21:29:02) [MSC v.1500 32 bit (Intel)] on win32. Portions Copyright 1994-2008 Mark Hammond - see 'Help/About PythonWin' for further copyright information. >>> import os >>> os.makedirs("g:/a/b/c") >>> os.listdir("g:/a") ['b'] >>> for root, dirs, files in os.walk("g:/a", topdown = False): ... print(root, dirs, files, os.listdir(root)) ... os.rmdir(root) ... g:/a\b\c [] [] [] g:/a\b ['c'] [] [] g:/a ['b'] [] [] >>> >From the documentation of os.walk: If topdown is False, the triple for a directory is generated after the triples for all of its subdirectories (directories are generated bottom-up). As the above example shows, the directories are generated in the correct order, "generated" referring to yield from generator os.walk. However, the generated (files? and) dirs do not necessarily reflect the current situation as produced by os.listdir. Therefore, this does not clear the entire directory tree as I would expect. >>> os.makedirs("g:/a/b/c") >>> for root, dirs, files in os.walk("g:/a", topdown = False): ... print(root, dirs, files, os.listdir(root)) ... if not (files + dirs): ... os.rmdir(root) ... g:/a\b\c [] [] [] g:/a\b ['c'] [] [] g:/a ['b'] [] ['b'] I think that at least the documentation should be more clear on this issue. I would like even better, if files + dirs would match os.listdir on the moment they are generated (=yielded). ---------- assignee: docs at python components: Documentation messages: 151169 nosy: docs at python, patrick.vrijlandt priority: normal severity: normal status: open title: os.walk: bottom-up type: behavior versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 15:38:57 2012 From: report at bugs.python.org (Georg Brandl) Date: Fri, 13 Jan 2012 14:38:57 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326465537.33.0.411758780831.issue12409@psf.upfronthosting.co.za> Georg Brandl added the comment: We'll probably have to redirect all /documenting in Apache anyway. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 18:13:20 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 13 Jan 2012 17:13:20 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1326474800.46.0.238164025058.issue12415@psf.upfronthosting.co.za> Changes by ?ric Araujo : ---------- dependencies: +Moving "Documenting Python" to Devguide _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 18:13:37 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Fri, 13 Jan 2012 17:13:37 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326474817.8.0.144200216803.issue12409@psf.upfronthosting.co.za> ?ric Araujo added the comment: About the devguide patch: a) The part about C roles and directives should probably mention version specifics (:cmacro: for 2.7, :c:macro: for 3.x) ? unless you make this bug dependent on updating Sphinx to 1.0 for 2.7 and then all versions use new-style :c:. b) You probably want to use ref:documenting instead of :doc:documenting (we always use ref) Not related to your patch, but it made me think about them so I?m just putting it out there for comments: Not sure we should keep the reST basics or just redirect to docutils and Sphinx docs. Likewise, maybe it?s time to stop mentioning the old Latex-based docs. (A nit: there are a few instances of `markup` that should be :file:`etc` or ``code``.) About the cpython patch: You could just have said ?rm Doc/documenting? :) Georg, will you be the one to set up the docs.python.org redirects? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 18:47:31 2012 From: report at bugs.python.org (Sandro Tosi) Date: Fri, 13 Jan 2012 17:47:31 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1326474817.8.0.144200216803.issue12409@psf.upfronthosting.co.za> Message-ID: Sandro Tosi added the comment: Hi ?ric, thanks for the review. On Fri, Jan 13, 2012 at 18:13, ?ric Araujo wrote: > > ?ric Araujo added the comment: > > About the devguide patch: > > a) The part about C roles and directives should probably mention version specifics (:cmacro: for 2.7, :c:macro: for 3.x) ? unless you make this bug dependent on updating Sphinx to 1.0 for 2.7 and then all versions use new-style :c:. yeah, I'd love to not write both rules/directives formats to later revert this addition, so ok, let's make this bug depending on the migration to sphinx 1.0 of the 2.7 version. I've sent a follow-up of that task to python-dev some days ago, and comments (and help!) would be welcome there too. > b) You probably want to use ref:documenting instead of :doc:documenting (we always use ref) ah ok, I just used the same role that was there; updated to use :ref: - fixed that (just pushed on my repo, not updated patch yet) > Not related to your patch, but it made me think about them so I?m just putting it out there for comments: Not sure we should keep the reST basics or just redirect to docutils and Sphinx docs. as a matter of personal taste, I like small lists of commonly used commands/roles/directives/whatever in the doc, with additional links as needed, this give a quick idea (that's usually enough) on what to do but also the possibility for further digging (if one wants it). >?Likewise, maybe it?s time to stop mentioning the old Latex-based docs. we can do that, but maybe at a later step? so now just put the doc in the canonical place, later let's refactor it, removing dead parts and so on? i'm fine anyhow > ?(A nit: there are a few instances of `markup` that should be :file:`etc` or ``code``.) I'll fix them in the mean time. > About the cpython patch: You could just have said ?rm Doc/documenting? :) eheh, well but a tiny tiny part remains :) if we go for a redirect to the devguide, I'm all for removing all that section from the doc; I left it there in case someone still refers directly to documenting/ or so (but indeed, all the sub-pages are no more reachable). >?Georg, will you be the one to set up the docs.python.org redirects? I can provide the configuration, but I don't have access to the machine, so some admins must be there as well. Cheers, Sandro ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 19:27:24 2012 From: report at bugs.python.org (Sandro Tosi) Date: Fri, 13 Jan 2012 18:27:24 +0000 Subject: [docs] [issue13728] Description of -m and -c cli options wrong? In-Reply-To: <1325950613.83.0.912226487635.issue13728@psf.upfronthosting.co.za> Message-ID: <1326479244.21.0.248950765122.issue13728@psf.upfronthosting.co.za> Sandro Tosi added the comment: Ah indeed, I could have looked at sys.path doc myself after all.. sorry for the noise. ---------- resolution: -> invalid stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 21:45:47 2012 From: report at bugs.python.org (Georg Brandl) Date: Fri, 13 Jan 2012 20:45:47 +0000 Subject: [docs] [issue13753] str.join description contains an incorrect reference to argument In-Reply-To: <1326167561.64.0.37328706988.issue13753@psf.upfronthosting.co.za> Message-ID: <1326487547.39.0.724130323968.issue13753@psf.upfronthosting.co.za> Georg Brandl added the comment: You put '*' instead of '#' in the commit message. Also, I don't think you should close more than one issue in one commit. ---------- nosy: +georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 13 23:19:19 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Fri, 13 Jan 2012 22:19:19 +0000 Subject: [docs] [issue13753] str.join description contains an incorrect reference to argument In-Reply-To: <1326167561.64.0.37328706988.issue13753@psf.upfronthosting.co.za> Message-ID: <1326493159.1.0.146796418507.issue13753@psf.upfronthosting.co.za> Terry J. Reedy added the comment: I see the two as really one issue -- minor corrections to the string section of stdtype.rst -- that py.user happened to have filed as two. But I could have left out the closes and done at least one explicitly. Or I could have closed this and said I was consolidating with #13754. Thanks for pointing out the typo. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 01:54:52 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 14 Jan 2012 00:54:52 +0000 Subject: [docs] [issue1397474] timeit execution enviroment Message-ID: <1326502492.31.0.2079506467.issue1397474@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- stage: needs patch -> patch review versions: +Python 3.3 -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 04:18:42 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sat, 14 Jan 2012 03:18:42 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326511121.84.0.264877709802.issue11633@psf.upfronthosting.co.za> ?ric Araujo added the comment: Thank you sir. Should the doc edit be backported to the 2.7 docs, with a mention that it?s only on unix? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 04:35:00 2012 From: report at bugs.python.org (Cameron Simpson) Date: Sat, 14 Jan 2012 03:35:00 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326512100.05.0.755740049401.issue11633@psf.upfronthosting.co.za> Cameron Simpson added the comment: Putting the wording into 2.7 might be nice, but I thought it was in bugfix only mode. Regarding UNIX only, I'd avoid it; any file may be buffered in almost any way on any platform. Saying an explicit flush call may be necessary for immediate output is _not_ UNIX only and would be very misleading. Remembering that ~UNIX != Windows. Telling users to explicitly call flush to ensure immediate output where that is necessary ensures portable coding (or ought to, user pigheadedness discounted:-) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 04:36:56 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sat, 14 Jan 2012 03:36:56 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326512216.4.0.465598540602.issue12409@psf.upfronthosting.co.za> ?ric Araujo added the comment: I just replied to your python-dev email. I think you can update 2.7 to use Sphinx 1.0 as soon as you?re down to a handful of warnings. When the migration is done, you can add the documenting doc to the devguide and send a message to pydev to tell people to not commit changes to Doc/documenting in CPython clones anymore. In the same email you can ask who to ask for setting up redirects (BTW, will redirecting paths to fragments work? e.g. docs.py.o/documenting/style to devguide/documenting#style-and-blah). When the redirects are up you?ll be able to rm Doc/documenting. Then we?ll open other reports to talk about the unrelated I mentioned and to see how to stop downloading Sphinx from svn once per clone :) ---------- versions: +Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 04:54:20 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sat, 14 Jan 2012 03:54:20 +0000 Subject: [docs] [issue13766] explain the relationship between Lib/lib2to3/Grammar.txt and Grammar/Grammar In-Reply-To: <1326279554.15.0.713951578682.issue13766@psf.upfronthosting.co.za> Message-ID: <1326513260.31.0.147289387318.issue13766@psf.upfronthosting.co.za> Changes by ?ric Araujo : ---------- nosy: +benjamin.peterson, eric.araujo, gvanrossum _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 04:56:25 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sat, 14 Jan 2012 03:56:25 +0000 Subject: [docs] [issue13770] python3 & json: add ensure_ascii documentation In-Reply-To: <1326300131.17.0.750918490995.issue13770@psf.upfronthosting.co.za> Message-ID: <1326513385.53.0.355823398946.issue13770@psf.upfronthosting.co.za> ?ric Araujo added the comment: Most probably. The text model of Python has no bearing on the JSON spec, and 2.x as well as 3.x Pythons may want to output UTF-8 JSON or JavaScript-escaped ASCII-only JSON. What specific wording is an issue? ---------- nosy: +eric.araujo versions: -Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 05:13:41 2012 From: report at bugs.python.org (Ezio Melotti) Date: Sat, 14 Jan 2012 04:13:41 +0000 Subject: [docs] [issue13770] python3 & json: add ensure_ascii documentation In-Reply-To: <1326300131.17.0.750918490995.issue13770@psf.upfronthosting.co.za> Message-ID: <1326514421.83.0.529480442569.issue13770@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- nosy: +ezio.melotti versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 05:35:00 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 14 Jan 2012 04:35:00 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: <1326515700.85.0.144114254051.issue13726@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- nosy: +ezio.melotti, michael.foord stage: -> needs patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 05:36:00 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sat, 14 Jan 2012 04:36:00 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: <1326515760.81.0.121405601427.issue11633@psf.upfronthosting.co.za> ?ric Araujo added the comment: Bug fixes include doc improvements, so 2.7 is fair game. Thanks for your suggestion to not mention specific platforms. Let?s just backport the 3.2 text. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 05:48:28 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 14 Jan 2012 04:48:28 +0000 Subject: [docs] [issue13730] Grammar mistake in Decimal documentation In-Reply-To: <1325963370.31.0.599534414571.issue13730@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 1e65183337ff by Terry Jan Reedy in branch '2.7': closes #13730 http://hg.python.org/cpython/rev/1e65183337ff New changeset bac18092c1dc by Terry Jan Reedy in branch '3.2': #13730 grammar fix http://hg.python.org/cpython/rev/bac18092c1dc New changeset e6b0d9d209f2 by Terry Jan Reedy in branch 'default': Merge with 3.2 #13730 grammar fix http://hg.python.org/cpython/rev/e6b0d9d209f2 ---------- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 05:50:08 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 14 Jan 2012 04:50:08 +0000 Subject: [docs] [issue13730] Grammar mistake in Decimal documentation In-Reply-To: <1325963370.31.0.599534414571.issue13730@psf.upfronthosting.co.za> Message-ID: <1326516608.56.0.0628951746495.issue13730@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Thanks for the report. ---------- nosy: +terry.reedy versions: +Python 2.7, Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 06:07:43 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 14 Jan 2012 05:07:43 +0000 Subject: [docs] [issue11633] Document that print may need explicit flushing In-Reply-To: <1300790242.96.0.630463287349.issue11633@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 8935a33773b9 by Terry Jan Reedy in branch '2.7': #11633 about buffering of print http://hg.python.org/cpython/rev/8935a33773b9 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 06:13:01 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 14 Jan 2012 05:13:01 +0000 Subject: [docs] [issue13744] raw byte strings are described in a confusing way In-Reply-To: <1326116062.09.0.84789277908.issue13744@psf.upfronthosting.co.za> Message-ID: <1326517981.31.0.288803916978.issue13744@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- nosy: +terry.reedy versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 06:25:38 2012 From: report at bugs.python.org (Ross Lagerwall) Date: Sat, 14 Jan 2012 05:25:38 +0000 Subject: [docs] [issue13779] os.walk: bottom-up In-Reply-To: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> Message-ID: <1326518738.36.0.383830902023.issue13779@psf.upfronthosting.co.za> Changes by Ross Lagerwall : ---------- nosy: +rosslagerwall _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 06:28:43 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 14 Jan 2012 05:28:43 +0000 Subject: [docs] [issue13769] json.dump(ensure_ascii=False) return str instead of unicode In-Reply-To: <1326300079.82.0.279410736545.issue13769@psf.upfronthosting.co.za> Message-ID: <1326518923.47.0.567787965131.issue13769@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Ezio, Raymond: is it the doc that is wrong? ---------- nosy: +ezio.melotti, rhettinger, terry.reedy stage: -> needs patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 06:40:22 2012 From: report at bugs.python.org (Ezio Melotti) Date: Sat, 14 Jan 2012 05:40:22 +0000 Subject: [docs] [issue13769] json.dump(ensure_ascii=False) return str instead of unicode In-Reply-To: <1326300079.82.0.279410736545.issue13769@psf.upfronthosting.co.za> Message-ID: <1326519622.35.0.498745272965.issue13769@psf.upfronthosting.co.za> Ezio Melotti added the comment: The docstring says: """ If ``ensure_ascii`` is false, then the return value will be a ``unicode`` instance subject to normal Python ``str`` to ``unicode`` coercion rules instead of being escaped to an ASCII ``str``. """ ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 07:19:47 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sat, 14 Jan 2012 06:19:47 +0000 Subject: [docs] [issue13783] Clean up PEP 380 C API additions Message-ID: <1326521987.14.0.4759346281.issue13783@psf.upfronthosting.co.za> New submission from Nick Coghlan : Georg noted that the PEP 380 patch added a couple of new C interfaces without documenting them. These interfaces need to be either: 1. Documented; 2. Made private; or 3. Removed (if they're completely trivial) PyGen_FetchStopIterationValue: probably document, explicitly noting that it also clears the StopIteration exception from the thread state PyStopIteration_Create: probably remove ---------- assignee: docs at python components: Documentation, Interpreter Core messages: 151235 nosy: docs at python, ncoghlan priority: normal severity: normal status: open title: Clean up PEP 380 C API additions versions: Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 07:23:54 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sat, 14 Jan 2012 06:23:54 +0000 Subject: [docs] [issue13783] Clean up PEP 380 C API additions In-Reply-To: <1326521987.14.0.4759346281.issue13783@psf.upfronthosting.co.za> Message-ID: <1326522234.38.0.356263445228.issue13783@psf.upfronthosting.co.za> Nick Coghlan added the comment: The current use of PyStopIteration_Create in genobject.c can probably be replaced with PyErr_SetObject(PyExc_StopIteration, value) anyway. ---------- _______________________________________ Python tracker _______________________________________ From jan.heidbrink at uni-potsdam.de Thu Jan 12 12:16:09 2012 From: jan.heidbrink at uni-potsdam.de (Jan Heidbrink) Date: Thu, 12 Jan 2012 12:16:09 +0100 Subject: [docs] Typo in faq Message-ID: <4F0EC0F9.9010809@uni-potsdam.de> Hello there, there is a typo in http://docs.python.org/faq/library: "if their code ran at half at the speed" Regards, Jan From robert.sokolowski at hotmail.co.uk Thu Jan 12 20:37:40 2012 From: robert.sokolowski at hotmail.co.uk (Robert Sokolowski) Date: Thu, 12 Jan 2012 19:37:40 +0000 Subject: [docs] support Message-ID: hi if possible i would like to support the project in reward I dare to know, how to bind events in python robert -------------- next part -------------- An HTML attachment was scrubbed... URL: From christopher.howard at frigidcode.com Fri Jan 13 12:54:18 2012 From: christopher.howard at frigidcode.com (Christopher Howard) Date: Fri, 13 Jan 2012 02:54:18 -0900 Subject: [docs] Python Language Reference Message-ID: <4F101B6A.4090802@frigidcode.com> Hi. (I'm not subscribed to this mailing list, so you will need to CC me any replies that you wish me to receive.) I recently started working through the The Python Language Reference (3.2). I don't know whether or not the language reference is something that can be edited, but if so I had two suggestions: 1. The language reference indicates that it is intentionally less formal than typical language references; nevertheless, there should be a section towards the beginning of the reference dealing with language regarding mandatory vs. implementation-dependent requirements. ("Must vs. "should", and such like.) E.g., in section 2.1.5, a paragraph states: "When embedding Python, source code strings should be passed to Python APIs using the standard C conventions for newline characters (the \n character, representing ASCII LF, is the line terminator)." Most people who have read, say, a C standards document will immediately wonder whether "should" means "must" or "is recommended". 2. The is an example given (also in section 2.1.5) illustrating the use of the backslash character for explicit line joining: if 1900 < year < 2100 and 1 <= month <= 12 \ and 1 <= day <= 31 and 0 <= hour < 24 \ and 0 <= minute < 60 and 0 <= second < 60: # Looks like a valid date return 1 However, everyone knows that not all months have 31 days. To avoid making the language reference look silly, it might be better to substitute this with a different example. Anyway, there are my two cents. -- frigidcode.com theologia.indicium.us -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 554 bytes Desc: OpenPGP digital signature URL: From pat.jln at hotmail.fr Fri Jan 13 17:24:34 2012 From: pat.jln at hotmail.fr (Patrice Joulain) Date: Fri, 13 Jan 2012 17:24:34 +0100 Subject: [docs] Python 3 doc update (re) symbolic group: name validity. Message-ID: Hello, I'd like to report a bug dealing with update from Python 2 to Python 3, in the Python 3.x Documentation. Python Standard Library / Chapter 6.2.1 Regular Expression Syntax - says "Group names must be valid Python identifiers" which is not true for 3.x . (?P...) accepts Python 2 valid identifier only (contrary to named fields of collections.namedtuple). I've checked re-HOWTO and tutorial: no specification about valididity of group name, hence no mistake. >>> re.match(r'(?Ptest)','test') <_sre.SRE_Match object at 0x00BF25A0> >>> assert 'D?j?Vu'.isidentifier() >>> re.match(r'(?Ptest)','test') Traceback (most recent call last): File "C:\Python32\lib\functools.py", line 176, in wrapper result = cache[key] KeyError: (, '(?Ptest)', 0) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 1, in File "C:\Python32\lib\re.py", line 153, in match return _compile(pattern, flags).match(string) File "C:\Python32\lib\re.py", line 255, in _compile return _compile_typed(type(pattern), pattern, flags) File "C:\Python32\lib\functools.py", line 180, in wrapper result = user_function(*args, **kwds) File "C:\Python32\lib\re.py", line 267, in _compile_typed return sre_compile.compile(pattern, flags) File "C:\Python32\lib\sre_compile.py", line 491, in compile p = sre_parse.parse(p, flags) File "C:\Python32\lib\sre_parse.py", line 692, in parse p = _parse_sub(source, pattern, 0) File "C:\Python32\lib\sre_parse.py", line 315, in _parse_sub itemsappend(_parse(source, state)) File "C:\Python32\lib\sre_parse.py", line 552, in _parse raise error("bad character in group name") sre_constants.error: bad character in group name >>> => From Lib\sre_parse.py: def isident(char): return "a" <= char <= "z" or "A" <= char <= "Z" or char == "_" def isdigit(char): return "0" <= char <= "9" def isname(name): # check that group name is a valid stringEnvoyer if not isident(name[0]): return False for char in name[1:]: if not isident(char) and not isdigit(char): return False return True Thank you for dealing this report (Sorry for my bad english). Waiting for some response: -------------- next part -------------- An HTML attachment was scrubbed... URL: From sandro.tosi at gmail.com Sat Jan 14 10:24:51 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 14 Jan 2012 10:24:51 +0100 Subject: [docs] Typo in faq In-Reply-To: <4F0EC0F9.9010809@uni-potsdam.de> References: <4F0EC0F9.9010809@uni-potsdam.de> Message-ID: Hello Jan, thanks for your email. On Thu, Jan 12, 2012 at 12:16, Jan Heidbrink wrote: > Hello there, > > there is a typo in http://docs.python.org/faq/library: > > "if their code ran at half at the speed" if I get you correctly, you mean that it should be changed in "if their code rat at half of the speed" - is that correct? (please try to be more verbose next time, you now: explicit is better than implicit :) ). Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From sandro.tosi at gmail.com Sat Jan 14 10:26:58 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 14 Jan 2012 10:26:58 +0100 Subject: [docs] support In-Reply-To: References: Message-ID: Hello Robert, 2012/1/12 Robert Sokolowski : > if possible i would like to support the project that's awesome - what do you have in mind for supporting python? > in reward I dare to know, > how to bind events in python I think this description is a bit too generic to give you the correct answer; additionally this mailing list is about bugs/enhancement to the python doc, which your request doesn't seem to. I suggest you to direct such inquiry to the http://mail.python.org/mailman/listinfo/python-list mailing-list . Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 14 11:29:42 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sat, 14 Jan 2012 10:29:42 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1326402982.11.0.0757175288221.issue6774@psf.upfronthosting.co.za> Message-ID: Charles-Fran?ois Natali added the comment: > This is questionable, unexpected, and should be documented. There's already this note at the top of the socket module documentation: """ Note Some behavior may be platform dependent, since calls are made to the operating system socket APIs. """ There are other such subtleties with the socket API, e.g. SO_REUSEADDR which doesn't have the same semantics on Windows. As I said earlier, I don't think we should document every platform quirks: it will make users worry for no reason, and as time passes, there's a chance that the documentation doesn't match the actual behavior. For example, this specific behavior might very well be a bug, and it's not our responsibility to document this. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 11:39:41 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 14 Jan 2012 10:39:41 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 4fc5dfad766a by Senthil Kumaran in branch '3.2': Issue13726 - Fix the ambiguous -S flag in regrtest. It is -o/--slow for printing the 10 slowest test. http://hg.python.org/cpython/rev/4fc5dfad766a New changeset 9a0efac5bbcb by Senthil Kumaran in branch '3.2': Adding the -o option for Issue13726 http://hg.python.org/cpython/rev/9a0efac5bbcb ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 11:42:21 2012 From: report at bugs.python.org (Senthil Kumaran) Date: Sat, 14 Jan 2012 10:42:21 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: <1326537741.43.0.936880410903.issue13726@psf.upfronthosting.co.za> Senthil Kumaran added the comment: I add -o as a short form for --slow. regrtest was using getopt and this conflicting option was not caught. I see it is a bug than a feature so the change is made in 3.2 and 3.3 default: b84f61fdcb4c and 6797e7458ad0 Thanks for catching this bug, Erno Tukia. ---------- nosy: +orsenthil resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 11:53:46 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 14 Jan 2012 10:53:46 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: <1313502559.06.0.415498401391.issue12760@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 8bcbe2dc3835 by Charles-Fran?ois Natali in branch 'default': Issue #12760: Refer to the new 'x' open mode as "exclusive creation" mode. http://hg.python.org/cpython/rev/8bcbe2dc3835 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 12:36:56 2012 From: report at bugs.python.org (Senthil Kumaran) Date: Sat, 14 Jan 2012 11:36:56 +0000 Subject: [docs] [issue13766] explain the relationship between Lib/lib2to3/Grammar.txt and Grammar/Grammar In-Reply-To: <1326279554.15.0.713951578682.issue13766@psf.upfronthosting.co.za> Message-ID: <1326541016.37.0.364924452066.issue13766@psf.upfronthosting.co.za> Changes by Senthil Kumaran : ---------- nosy: +orsenthil _______________________________________ Python tracker _______________________________________ From senthil at uthcode.com Sat Jan 14 12:49:25 2012 From: senthil at uthcode.com (Senthil Kumaran) Date: Sat, 14 Jan 2012 19:49:25 +0800 Subject: [docs] Python Language Reference In-Reply-To: <4F101B6A.4090802@frigidcode.com> References: <4F101B6A.4090802@frigidcode.com> Message-ID: <20120114114925.GA31527@mathmagic> On Fri, Jan 13, 2012 at 02:54:18AM -0900, Christopher Howard wrote: > regarding mandatory vs. implementation-dependent requirements. ("Must > vs. "should", and such like.) E.g., in section 2.1.5, a paragraph states: I think, that would make it something like an RFC or standard. As you noticed, enough foreword has been given as how to look at the language reference. > "When embedding Python, source code strings should be passed to Python > APIs using the standard C conventions for newline characters (the \n > character, representing ASCII LF, is the line terminator)." > > Most people who have read, say, a C standards document will immediately > wonder whether "should" means "must" or "is recommended". If someone really wants to confuse then yes, but other wise, the person would simply send \n. And I believe the person would look at docs and libraries and would be a user of python before reading that the reference documentation. In that case, would it still confuse? > if 1900 < year < 2100 and 1 <= month <= 12 \ > and 1 <= day <= 31 and 0 <= hour < 24 \ > and 0 <= minute < 60 and 0 <= second < 60: # Looks like a valid date > return 1 > > However, everyone knows that not all months have 31 days. To avoid > making the language reference look silly, it might be better to > substitute this with a different example. Isn't this deviating from what the intention of the statement is? If it were an example in datatime module document, then it would probably may been a change request. > > Anyway, there are my two cents. > Thanks for the suggestions. At the moment -1 from me. ( You could refer to PEPs on voting details :)) Thanks, Senthil From report at bugs.python.org Sat Jan 14 13:02:15 2012 From: report at bugs.python.org (patrick vrijlandt) Date: Sat, 14 Jan 2012 12:02:15 +0000 Subject: [docs] [issue13784] Documentation of xml.sax.xmlreader: Locator.getLineNumber() and Locator.getColumnNumber() Message-ID: <1326542534.95.0.205057982858.issue13784@psf.upfronthosting.co.za> New submission from patrick vrijlandt : Problem: Locator methods return the location where the event starts, not where it ends. Locator line numbers start at 1, Locator column numbers can be 0. Proposal: Adapt documentation. >From the docs: Instances of Locator provide these methods: Locator.getColumnNumber() Return the column number where the current event ends. Locator.getLineNumber() Return the line number where the current event ends My Test: import xml.sax data = b"""
""" class MyHandler(xml.sax.handler.ContentHandler): def startElement(self, name, attrs): if name == "sub": print("open", name, self._locator.getLineNumber(), self._locator.getColumnNumber()) def endElement(self, name): if name == "sub": print("close", name, self._locator.getLineNumber(), self._locator.getColumnNumber()) xml.sax.parseString(data, MyHandler()) Output: open sub 2 4 close sub 7 4 ---------- assignee: docs at python components: Documentation, XML messages: 151247 nosy: docs at python, patrick.vrijlandt priority: normal severity: normal status: open title: Documentation of xml.sax.xmlreader: Locator.getLineNumber() and Locator.getColumnNumber() type: behavior versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 13:30:01 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sat, 14 Jan 2012 12:30:01 +0000 Subject: [docs] [issue12760] Add create mode to open() In-Reply-To: Message-ID: Charles-Fran?ois Natali added the comment: Thanks, I've committed your version. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 13:45:45 2012 From: report at bugs.python.org (Erno Tukia) Date: Sat, 14 Jan 2012 12:45:45 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: <1326545145.45.0.932173694809.issue13726@psf.upfronthosting.co.za> Erno Tukia added the comment: --start requires an argument but short opt -S does not. in Lib/test/regrtest.py opts, args = getopt.getopt(sys.argv[1:], '...S...', [..., 'start=', ...]) Patch included. ---------- keywords: +patch Added file: http://bugs.python.org/file24236/issue13726-2.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 13:53:11 2012 From: report at bugs.python.org (Erno Tukia) Date: Sat, 14 Jan 2012 12:53:11 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: <1326545591.38.0.224466708368.issue13726@psf.upfronthosting.co.za> Changes by Erno Tukia : ---------- resolution: fixed -> status: closed -> open _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 14:08:28 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 14 Jan 2012 13:08:28 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset c4919642fd25 by Senthil Kumaran in branch '3.2': Fix issue13726: -S accepts an argument just as --start. http://hg.python.org/cpython/rev/c4919642fd25 New changeset 347f6305bd26 by Senthil Kumaran in branch 'default': merge from 3.2 - Fix issue13726: -S accepts an argument just as --start. http://hg.python.org/cpython/rev/347f6305bd26 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 14:09:11 2012 From: report at bugs.python.org (Senthil Kumaran) Date: Sat, 14 Jan 2012 13:09:11 +0000 Subject: [docs] [issue13726] regrtest ambiguous -S flag In-Reply-To: <1325938488.7.0.238559424001.issue13726@psf.upfronthosting.co.za> Message-ID: <1326546551.73.0.29429029337.issue13726@psf.upfronthosting.co.za> Senthil Kumaran added the comment: Fixed now. Thanks! ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 15:02:16 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sat, 14 Jan 2012 14:02:16 +0000 Subject: [docs] [issue13783] Clean up PEP 380 C API additions In-Reply-To: <1326521987.14.0.4759346281.issue13783@psf.upfronthosting.co.za> Message-ID: <1326549736.11.0.132360659843.issue13783@psf.upfronthosting.co.za> Nick Coghlan added the comment: Also check any GetAttr and CallMethod operations to see if they should be moved over to the new *Id variants. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 17:41:06 2012 From: report at bugs.python.org (=?utf-8?b?0JzQsNGA0Log0JrQvtGA0LXQvdCx0LXRgNCz?=) Date: Sat, 14 Jan 2012 16:41:06 +0000 Subject: [docs] [issue13770] python3 & json: add ensure_ascii documentation In-Reply-To: <1326300131.17.0.750918490995.issue13770@psf.upfronthosting.co.za> Message-ID: <1326559266.35.0.286584474759.issue13770@psf.upfronthosting.co.za> ???? ????????? added the comment: ensure_ascii is documented only in Jsonencoder class. Other functions like dumps() should refer to this class description for that parameter. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 14 19:13:53 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sat, 14 Jan 2012 18:13:53 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1326512216.4.0.465598540602.issue12409@psf.upfronthosting.co.za> Message-ID: Sandro Tosi added the comment: On Sat, Jan 14, 2012 at 04:36, ?ric Araujo wrote: > > ?ric Araujo added the comment: > > I just replied to your python-dev email. ?I think you can update 2.7 to use Sphinx 1.0 as soon as you?re down to a handful of warnings. thanks! I've just updated 2.7 to sphinx 1.0 - yay > When the migration is done, you can add the documenting doc to the devguide and send a message to pydev to tell people to not commit changes to Doc/documenting in CPython clones anymore. > > In the same email you can ask who to ask for setting up redirects (BTW, will redirecting paths to fragments work? ?e.g. docs.py.o/documenting/style to devguide/documenting#style-and-blah). ?When the redirects are up you?ll be able to rm Doc/documenting. I just did that with: http://mail.python.org/pipermail/python-dev/2012-January/115520.html > Then we?ll open other reports to talk about the unrelated I mentioned and to see how to stop downloading Sphinx from svn once per clone :) Ah yes, sure! Cheers, Sandro ---------- _______________________________________ Python tracker _______________________________________ From christopher.howard at frigidcode.com Sat Jan 14 13:05:35 2012 From: christopher.howard at frigidcode.com (Christopher Howard) Date: Sat, 14 Jan 2012 03:05:35 -0900 Subject: [docs] Python Language Reference In-Reply-To: <20120114114925.GA31527@mathmagic> References: <4F101B6A.4090802@frigidcode.com> <20120114114925.GA31527@mathmagic> Message-ID: <4F116F8F.2070804@frigidcode.com> On 01/14/2012 02:49 AM, Senthil Kumaran wrote: > On Fri, Jan 13, 2012 at 02:54:18AM -0900, Christopher Howard wrote: > >> regarding mandatory vs. implementation-dependent requirements. ("Must >> vs. "should", and such like.) E.g., in section 2.1.5, a paragraph states: > > I think, that would make it something like an RFC or standard. As you > noticed, enough foreword has been given as how to look at the language > reference. > >> "When embedding Python, source code strings should be passed to Python >> APIs using the standard C conventions for newline characters (the \n >> character, representing ASCII LF, is the line terminator)." >> >> Most people who have read, say, a C standards document will immediately >> wonder whether "should" means "must" or "is recommended". > > If someone really wants to confuse then yes, but other wise, the > person would simply send \n. And I believe the person would look at > docs and libraries and would be a user of python before reading that > the reference documentation. In that case, would it still confuse? > >> if 1900 < year < 2100 and 1 <= month <= 12 \ >> and 1 <= day <= 31 and 0 <= hour < 24 \ >> and 0 <= minute < 60 and 0 <= second < 60: # Looks like a valid date >> return 1 >> >> However, everyone knows that not all months have 31 days. To avoid >> making the language reference look silly, it might be better to >> substitute this with a different example. > > Isn't this deviating from what the intention of the statement is? > If it were an example in datatime module document, then it would > probably may been a change request. > >> >> Anyway, there are my two cents. >> > > Thanks for the suggestions. At the moment -1 from me. ( You could > refer to PEPs on voting details :)) > > Thanks, > Senthil Yeah, just forget that I ever sent that e-mail. When I initially approached this document, I thought it was trying to function as a language standard. After getting into it (I'm about half way through now) I see that you would have to rewrite about half the document to approach the precision of a language standard. The terminology is very loose, and distinctions between language and implementation are frequently blurred. -- frigidcode.com theologia.indicium.us -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 554 bytes Desc: OpenPGP digital signature URL: From report at bugs.python.org Sat Jan 14 23:55:51 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sat, 14 Jan 2012 22:55:51 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326581751.26.0.103089673712.issue12409@psf.upfronthosting.co.za> Sandro Tosi added the comment: "Documenting Python" has been: - moved to devguide; http://hg.python.org/devguide/rev/5d4a90e568ed - removed from 2.7, 3.2 and default; http://hg.python.org/cpython/rev/8975f7d0fbf7 http://hg.python.org/cpython/rev/70c46599fb0e http://hg.python.org/cpython/rev/900c01e643a7 Thanks everyone! ---------- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 15 00:47:04 2012 From: report at bugs.python.org (Mahmoud Hashemi) Date: Sat, 14 Jan 2012 23:47:04 +0000 Subject: [docs] [issue12949] Documentation of PyCode_New() lacks kwonlyargcount argument In-Reply-To: <1315592789.75.0.632556595518.issue12949@psf.upfronthosting.co.za> Message-ID: <1326584824.74.0.381662950908.issue12949@psf.upfronthosting.co.za> Changes by Mahmoud Hashemi : ---------- nosy: +mahmoud _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 15 01:41:48 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Sun, 15 Jan 2012 00:41:48 +0000 Subject: [docs] [issue13770] python3 & json: add ensure_ascii documentation In-Reply-To: <1326300131.17.0.750918490995.issue13770@psf.upfronthosting.co.za> Message-ID: <1326588108.36.0.897609302866.issue13770@psf.upfronthosting.co.za> ?ric Araujo added the comment: All right. I?ll do like other parameters (see check_circular for an example) and just duplicate the two-line doc. ---------- assignee: docs at python -> eric.araujo versions: +Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 15 10:06:53 2012 From: report at bugs.python.org (Matt Joiner) Date: Sun, 15 Jan 2012 09:06:53 +0000 Subject: [docs] [issue13791] Other versions Message-ID: <1326618413.55.0.73666208075.issue13791@psf.upfronthosting.co.za> New submission from Matt Joiner : The navigation region at http://docs.python.org/dev/ should list "Other versions" instead of "Old versions" as the in development docs are also available here. Docs for other versions Python 2.7 (stable) Python 3.2 (stable) Old versions Unreleased, development versions of the documentation. This may contain more information than the current released documentation. http://www.python.org/doc/versions/ ---------- assignee: docs at python components: Documentation messages: 151281 nosy: anacrolix, docs at python priority: normal severity: normal status: open title: Other versions type: enhancement versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4 _______________________________________ Python tracker _______________________________________ From w_h_falk at yahoo.de Sun Jan 15 18:09:41 2012 From: w_h_falk at yahoo.de (Wilfried Falk) Date: Sun, 15 Jan 2012 17:09:41 +0000 (GMT) Subject: [docs] "+=" works not correct all the time Message-ID: <1326647381.52523.YahooMailNeo@web29017.mail.ird.yahoo.com> Hello Python's, ? "+="? does not work correct all the time. ? Sometimes (but not allways)? ?? identifier += 1???? works as ??? print(); ?identifier = identifier + 1 ? Another?misoperation of?? "+="??you find?in the code below: ? def conc1(a, alist = []): alist = alist + [a] return alist def conc2(b, blist = []): blist += [b] return blist ? ? Main-Program ? for i in range(4): lista = conc1(i) print(lista) ? print() for k in range(4): listb = conc2(k) print(listb) ? The result of print(lista) is: [0] [1] [2] [3] The result of print(listb) is: [0] [0, 1] [0, 1, 2] [0, 1, 2, 3] ? ? Best regards Wilfried -------------- next part -------------- An HTML attachment was scrubbed... URL: From sandro.tosi at gmail.com Sun Jan 15 18:59:14 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sun, 15 Jan 2012 18:59:14 +0100 Subject: [docs] "+=" works not correct all the time In-Reply-To: <1326647381.52523.YahooMailNeo@web29017.mail.ird.yahoo.com> References: <1326647381.52523.YahooMailNeo@web29017.mail.ird.yahoo.com> Message-ID: Hello Wilfried, On Sun, Jan 15, 2012 at 18:09, Wilfried Falk wrote: > Hello Python's, > > "+="? does not work correct all the time. Please note that this mailing list is about bugs/enhancement to the Python documentation, and your email doesn't fall into such category. I suggest to write to http://mail.python.org/mailman/listinfo/python-list for your problem (try to be more precise, in particular what version of python you're using, if you build it, and how, or if you're using a packaged version; also pay attention your MUA won't remove spaces at the beginning of the lines, since it makes reading python code much harder). Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Mon Jan 16 03:28:55 2012 From: report at bugs.python.org (Roundup Robot) Date: Mon, 16 Jan 2012 02:28:55 +0000 Subject: [docs] [issue13766] explain the relationship between Lib/lib2to3/Grammar.txt and Grammar/Grammar In-Reply-To: <1326279554.15.0.713951578682.issue13766@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 8f7e707ab729 by Benjamin Peterson in branch '3.2': explain why we need this grammar file (closes #13766) http://hg.python.org/cpython/rev/8f7e707ab729 New changeset ecc998ec8c6f by Benjamin Peterson in branch 'default': merge 3.2 (#13766) http://hg.python.org/cpython/rev/ecc998ec8c6f New changeset 5d1c177c585b by Benjamin Peterson in branch '2.7': explain why we need this grammar file (closes #13766) http://hg.python.org/cpython/rev/5d1c177c585b ---------- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 05:39:06 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 04:39:06 +0000 Subject: [docs] =?utf-8?q?=5Bissue13791=5D_Reword_=E2=80=9COld_versions?= =?utf-8?q?=E2=80=9D_in_the_doc_sidebar?= In-Reply-To: <1326618413.55.0.73666208075.issue13791@psf.upfronthosting.co.za> Message-ID: <1326688746.3.0.756838284261.issue13791@psf.upfronthosting.co.za> ?ric Araujo added the comment: To avoid repetition (?Docs for other versions? ? ?Other versions?), I?d propose changing ?Old versions? to ?All versions?. ---------- nosy: +eric.araujo, ezio.melotti, sandro.tosi, terry.reedy title: Other versions -> Reword ?Old versions? in the doc sidebar versions: -Python 2.6, Python 3.1, Python 3.4 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 05:50:43 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Mon, 16 Jan 2012 04:50:43 +0000 Subject: [docs] =?utf-8?q?=5Bissue13791=5D_Reword_=E2=80=9COld_versions?= =?utf-8?q?=E2=80=9D_in_the_doc_sidebar?= In-Reply-To: <1326618413.55.0.73666208075.issue13791@psf.upfronthosting.co.za> Message-ID: <1326689443.14.0.132961932376.issue13791@psf.upfronthosting.co.za> Terry J. Reedy added the comment: I believe this should be closed in favor of #13122. The sidebar needs more change than just this one thing. See my proposal for a version-independent sidebar in msg150907, which Georg B. approved of. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 06:42:46 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 16 Jan 2012 05:42:46 +0000 Subject: [docs] [issue2134] Add new attribute to TokenInfo to report specific token IDs In-Reply-To: <1203289230.78.0.790200923315.issue2134@psf.upfronthosting.co.za> Message-ID: <1326692566.22.0.437145182046.issue2134@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- stage: needs patch -> patch review _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 06:45:51 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 05:45:51 +0000 Subject: [docs] =?utf-8?q?=5Bissue13791=5D_Reword_=E2=80=9COld_versions?= =?utf-8?q?=E2=80=9D_in_the_doc_sidebar?= In-Reply-To: <1326618413.55.0.73666208075.issue13791@psf.upfronthosting.co.za> Message-ID: <1326692751.38.0.0539353364306.issue13791@psf.upfronthosting.co.za> ?ric Araujo added the comment: Agreed (I?d just suggest finding something better than ?Everything else? :-) ---------- resolution: -> duplicate stage: -> committed/rejected status: open -> closed superseder: -> Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:29:52 2012 From: report at bugs.python.org (Roundup Robot) Date: Mon, 16 Jan 2012 06:29:52 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 2dd96cf324ee by Ezio Melotti in branch '2.7': #13695: fix a couple of typos in the doc. http://hg.python.org/cpython/rev/2dd96cf324ee New changeset bff9ab281385 by Ezio Melotti in branch '3.2': #13695: fix a couple of typos in the doc. http://hg.python.org/cpython/rev/bff9ab281385 New changeset 3b097e0892cf by Ezio Melotti in branch 'default': #13695: merge with 3.2. http://hg.python.org/cpython/rev/3b097e0892cf ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:32:04 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 16 Jan 2012 06:32:04 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326695524.24.0.88195008216.issue13695@psf.upfronthosting.co.za> Ezio Melotti added the comment: I fixed both 'type-specific' and 'Python 3'. The python-distribute link is not part of our documentation so I can't fix it. ---------- assignee: docs at python -> ezio.melotti resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:36:29 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 06:36:29 +0000 Subject: [docs] [issue13443] wrong links and examples in the functional HOWTO In-Reply-To: <1321850404.45.0.767133152656.issue13443@psf.upfronthosting.co.za> Message-ID: <1326695789.66.0.245992396207.issue13443@psf.upfronthosting.co.za> Changes by ?ric Araujo : ---------- Removed message: http://bugs.python.org/msg150397 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:37:04 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 06:37:04 +0000 Subject: [docs] [issue13443] wrong links and examples in the functional HOWTO In-Reply-To: <1321850404.45.0.767133152656.issue13443@psf.upfronthosting.co.za> Message-ID: <1326695824.43.0.415552219448.issue13443@psf.upfronthosting.co.za> Changes by ?ric Araujo : ---------- Removed message: http://bugs.python.org/msg150399 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:46:19 2012 From: report at bugs.python.org (Roundup Robot) Date: Mon, 16 Jan 2012 06:46:19 +0000 Subject: [docs] [issue13715] typo in unicodedata documentation In-Reply-To: <1325782041.56.0.783502480563.issue13715@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset b4dac315feef by Ezio Melotti in branch '2.7': #13715: fix typo in unicodedata doc. Patch by Eli Collins. http://hg.python.org/cpython/rev/b4dac315feef New changeset f50ff6dd6b41 by Ezio Melotti in branch '3.2': #13715: fix typo in unicodedata doc. Patch by Eli Collins. http://hg.python.org/cpython/rev/f50ff6dd6b41 New changeset f1408e41e306 by Ezio Melotti in branch 'default': #13715: merge with 3.2. http://hg.python.org/cpython/rev/f1408e41e306 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:47:31 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 16 Jan 2012 06:47:31 +0000 Subject: [docs] [issue13715] typo in unicodedata documentation In-Reply-To: <1325782041.56.0.783502480563.issue13715@psf.upfronthosting.co.za> Message-ID: <1326696451.33.0.561937491971.issue13715@psf.upfronthosting.co.za> Ezio Melotti added the comment: Fixed, thanks for the report and the patch! ---------- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:52:19 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 06:52:19 +0000 Subject: [docs] [issue13443] wrong links and examples in the functional HOWTO In-Reply-To: <1321850404.45.0.767133152656.issue13443@psf.upfronthosting.co.za> Message-ID: <1326696739.78.0.500023966133.issue13443@psf.upfronthosting.co.za> ?ric Araujo added the comment: Sorry, my messages could be confusing. What I meant is: While I think that Antoine?s doc changes were clear improvements, in the specific case of the functional howto there were good arguments in favor of keeping the part about the functional module. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 07:57:20 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 16 Jan 2012 06:57:20 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326697040.72.0.956820988554.issue13695@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: There's also one more typo in the doc for cmp_to_key() function. Fix the first sentence "Transform an old-style comparison function to a key-function." to "Transform an old-style comparison function to a key function." (note the removal of the hyphen between words "key" and "function") http://docs.python.org/library/functools.html#functools.cmp_to_key ---------- resolution: fixed -> remind status: closed -> open _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 08:06:11 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 16 Jan 2012 07:06:11 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326697571.2.0.269907867142.issue13695@psf.upfronthosting.co.za> Changes by Georg Brandl : ---------- assignee: ezio.melotti -> rhettinger nosy: +rhettinger _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 08:52:14 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 07:52:14 +0000 Subject: [docs] [issue13275] Recommend xml.etree for XML processing In-Reply-To: <1319709959.84.0.984784684468.issue13275@psf.upfronthosting.co.za> Message-ID: <1326700334.37.0.0570524650088.issue13275@psf.upfronthosting.co.za> ?ric Araujo added the comment: (I haven?t found an elegant XML lib, and have not yet needed to look for one as I touch very little XML.) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 09:40:06 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 16 Jan 2012 08:40:06 +0000 Subject: [docs] [issue13435] Copybutton does not hide tracebacks In-Reply-To: <1321724543.66.0.854276029391.issue13435@psf.upfronthosting.co.za> Message-ID: <1326703206.15.0.040454295725.issue13435@psf.upfronthosting.co.za> Ezio Melotti added the comment: Now 2.7 uses Sphinx 1.0, but I think a full rebuild should be triggered in order to update all the files. Georg, can you do something about it? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 09:51:44 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 16 Jan 2012 08:51:44 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326703904.22.0.323036366874.issue13695@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Found one little bug again in http://docs.python.org/library/stdtypes.html#sequence-types-str-unicode-list-tuple-bytearray-buffer-xrange Look at the table with the fields Operation, Result, Notes, and fix the fifth record of the Result field from "i'th item of s, origin 0" to "i-th item of s, origin 0". So change only that apostrophe into a hyphen, so "i'th" to "i-th". ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 10:17:54 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Mon, 16 Jan 2012 09:17:54 +0000 Subject: [docs] [issue13122] Out of date links in the sidebar of the documentation index of versions 3.1 and 3.2 In-Reply-To: <1317999740.46.0.922190010194.issue13122@psf.upfronthosting.co.za> Message-ID: <1326705474.75.0.713539920992.issue13122@psf.upfronthosting.co.za> Terry J. Reedy added the comment: 'All Releases' rather than 'Everything else' is both more accurate and to me, more graceful. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 11:38:27 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 16 Jan 2012 10:38:27 +0000 Subject: [docs] [issue13435] Copybutton does not hide tracebacks In-Reply-To: <1321724543.66.0.854276029391.issue13435@psf.upfronthosting.co.za> Message-ID: <1326710306.96.0.368118762257.issue13435@psf.upfronthosting.co.za> Georg Brandl added the comment: A full rebuild should be done anyway next time the script runs. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 11:39:10 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 16 Jan 2012 10:39:10 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326710350.13.0.650175731174.issue13695@psf.upfronthosting.co.za> Georg Brandl added the comment: Would you care to explain why that change needs to be made? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 13:50:46 2012 From: report at bugs.python.org (Ramchandra Apte) Date: Mon, 16 Jan 2012 12:50:46 +0000 Subject: [docs] [issue13799] Base 16 should be hexadecimal in Unicode HOWTO Message-ID: <1326718246.49.0.980962494093.issue13799@psf.upfronthosting.co.za> New submission from Ramchandra Apte : "base 16" should be "hexadecimal" in the Unicode HOWTO in both Python 2 and 3 docs. ---------- assignee: docs at python components: Documentation messages: 151354 nosy: docs at python, ramchandra.apte priority: normal severity: normal status: open title: Base 16 should be hexadecimal in Unicode HOWTO type: enhancement versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 14:28:54 2012 From: report at bugs.python.org (Ramchandra Apte) Date: Mon, 16 Jan 2012 13:28:54 +0000 Subject: [docs] [issue13801] The Python 3 Docs doesn't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326720534.37.0.0406561402074.issue13801@psf.upfronthosting.co.za> Changes by Ramchandra Apte : ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python versions: +Python 3.1, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 14:31:11 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 16 Jan 2012 13:31:11 +0000 Subject: [docs] [issue13801] The Python 3 Docs doesn't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326720671.98.0.245384328411.issue13801@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- nosy: +ezio.melotti, georg.brandl versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 15:31:41 2012 From: report at bugs.python.org (Justin Wehnes) Date: Mon, 16 Jan 2012 14:31:41 +0000 Subject: [docs] [issue13801] The Python 3 Docs doesn't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326724300.95.0.723663719739.issue13801@psf.upfronthosting.co.za> Justin Wehnes added the comment: Nonlocal is highlighted under Language Reference under simple statements section 6.13 (http://docs.python.org/dev/reference/index.html). help("nonlocal") will also bring up the documentation (works for me in 3.3). ---------- nosy: +jwehnes _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 15:34:46 2012 From: report at bugs.python.org (Zbyszek Szmek) Date: Mon, 16 Jan 2012 14:34:46 +0000 Subject: [docs] [issue13779] os.walk: bottom-up In-Reply-To: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> Message-ID: <1326724486.65.0.853796969906.issue13779@psf.upfronthosting.co.za> Zbyszek Szmek added the comment: Hi, I think that the documentation is pretty clear ("[if topdown=False] ... the directories in dirnames have already been generated by the time dirnames itself is generated"). And such behaviour is what one would expect, since it is the result of the simplest implementation (listdir(), yield , yield , yeild , yeild ). I don't think that the implementation will be changed, since it is pretty to do listdir() yourself if needed, and it would make the function slower for the common use case. Improving the documentation is always possible, what sentence would you see added (what would make the behaviour clearer to you?) ? ---------- nosy: +zbysz _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 15:41:29 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 14:41:29 +0000 Subject: [docs] [issue13801] The Python 3 Docs don't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326724889.21.0.094375559507.issue13801@psf.upfronthosting.co.za> ?ric Araujo added the comment: Not really. If you follow the link given in the first message and compare how ?is? and ?nonlocal? are styled, you will see the bug. :) I hope that Sphinx configures Pygments to use a Python3Lexer, not Python. Georg? ---------- nosy: +eric.araujo stage: -> needs patch title: The Python 3 Docs doesn't highlight nonlocal -> The Python 3 Docs don't highlight nonlocal _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 15:48:46 2012 From: report at bugs.python.org (Justin Wehnes) Date: Mon, 16 Jan 2012 14:48:46 +0000 Subject: [docs] [issue13801] The Python 3 Docs don't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326725326.74.0.0941466963721.issue13801@psf.upfronthosting.co.za> Justin Wehnes added the comment: Ahh yes I see it. Sorry about that. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 16:03:22 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Mon, 16 Jan 2012 15:03:22 +0000 Subject: [docs] [issue13779] os.walk: bottom-up In-Reply-To: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> Message-ID: <1326726202.79.0.567652085423.issue13779@psf.upfronthosting.co.za> Antoine Pitrou added the comment: > However, the generated (files? and) dirs do not necessarily reflect the current situation as produced by os.listdir. What do you mean exactly? Another process has re-created "b" in parallel? This race condition is pretty impossible to solve in the general case (unless the filesystem is transactional): even if you call os.listdir() again, a new file or dir could appear just before the following call to os.rmdir(). (just for the record, shutil.rmtree already allows you to delete a filesystem tree) ---------- nosy: +pitrou _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 16:36:08 2012 From: report at bugs.python.org (Benjamin Peterson) Date: Mon, 16 Jan 2012 15:36:08 +0000 Subject: [docs] [issue13801] The Python 3 Docs don't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326728168.03.0.0808217436734.issue13801@psf.upfronthosting.co.za> Benjamin Peterson added the comment: The problem was until very recently, pygments omitted the nonlocal keyword. We probably need to wait for another pygments release. ---------- nosy: +benjamin.peterson _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 16:56:27 2012 From: report at bugs.python.org (patrick vrijlandt) Date: Mon, 16 Jan 2012 15:56:27 +0000 Subject: [docs] [issue13779] os.walk: bottom-up In-Reply-To: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> Message-ID: <1326729387.1.0.786726344314.issue13779@psf.upfronthosting.co.za> patrick vrijlandt added the comment: The documentation of this function is generally ambiguous, because os.walk is a generator. Thus "generate" means (1) yielded from a generator and (2) prepared for later use within the generator. To avoid the ambiguity, "generate" should be avoided if possible. (1) might be replaced by "return" and (2) by "prepare". @zbysz The paragraph you cite is about "Modifying dirnames ". If you are not "Modifying dirnames" (like me) this section easily skips your attention. My problem was, of course, that I had myself changed the directory structure - It's not a race condition with another process but an effect of the loop os.walk was managing. @pitrou shutil.rmtree cannot help me, because I'm only deleting empty dirs. Proposal (very verbose I'm afraid): If you change the directory structure below dirpath while topdown=True, you can modify dirnames in-place so that walk will visit the right directories. If you change the directory structure below dirpath while topdown=False (maybe while you where there), dirnames and filenames can still reflect the old situation and it might be necessary to call os.listdir again. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:16:48 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 16:16:48 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1326730608.44.0.996261336039.issue12415@psf.upfronthosting.co.za> ?ric Araujo added the comment: Please review. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:17:07 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 16:17:07 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1326730627.41.0.459835481706.issue12415@psf.upfronthosting.co.za> Changes by ?ric Araujo : Added file: http://bugs.python.org/file24249/metadoc-where-are-the-sources.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:19:27 2012 From: report at bugs.python.org (Eric V. Smith) Date: Mon, 16 Jan 2012 16:19:27 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1326730767.06.0.750792428598.issue13790@psf.upfronthosting.co.za> Eric V. Smith added the comment: Changing to a documentation issue. ---------- assignee: eric.smith -> docs at python components: +Documentation -Interpreter Core keywords: +easy nosy: +docs at python versions: +Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:27:47 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 16:27:47 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326731267.28.0.130764341966.issue12409@psf.upfronthosting.co.za> ?ric Araujo added the comment: Glad my action plan worked :) There are now obsolete entries in the Doc/tools/sphinxext/susp-ignored.csv file: All lines starting with ?documenting? can be removed. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:34:13 2012 From: report at bugs.python.org (Zbyszek Szmek) Date: Mon, 16 Jan 2012 16:34:13 +0000 Subject: [docs] [issue13779] os.walk: bottom-up In-Reply-To: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> Message-ID: <1326731653.56.0.736520747715.issue13779@psf.upfronthosting.co.za> Zbyszek Szmek added the comment: > The documentation of this function is generally ambiguous, because > os.walk is a generator. Thus "generate" means (1) yielded from a > generator and (2) prepared for later use within the generator. To avoid > the ambiguity, "generate" should be avoided if possible. (1) might be > replaced by "return" and (2) by "prepare". It think that you are wrong here: generate is consistently used in meaning (1) in the docstring. Also "return" means something completely different. "generate" is better than "prepare", because it is more specific, especially from the POV of the user of the function, who only cares about when something is yielded, not when it is prepared. > Proposal (very verbose I'm afraid): > If you change the directory structure below dirpath while topdown=True, > you can modify dirnames in-place so that walk will visit the right > directories. If you change the directory structure below dirpath while > topdown=False (maybe while you where there), dirnames and filenames can > still reflect the old situation and it might be necessary to call > os.listdir again. Hm, I think that the difference in behaviour between topdown=False and topdown=True is smaller then this proposal implies. When topdown=True, the list is not updated after changes on disk. So both removing and adding directories does _not_ cause them to added or removed from the list of subdirectories to visit. Nevertheless, the default behaviour on error is to do nothing, so it _looks_ like they were skipped. So I think that the documentation could only clarify that the list of subdirectories is queried first, before the dir or the subdirectories are "generated". ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:36:40 2012 From: report at bugs.python.org (Zbyszek Szmek) Date: Mon, 16 Jan 2012 16:36:40 +0000 Subject: [docs] [issue13779] os.walk: bottom-up In-Reply-To: <1326452589.73.0.0617213643117.issue13779@psf.upfronthosting.co.za> Message-ID: <1326731799.92.0.876645927.issue13779@psf.upfronthosting.co.za> Zbyszek Szmek added the comment: >>> os.makedirs('/tmp/a/b/c') >>> gen = os.walk('/tmp/a') >>> next(gen) ('/tmp/a', ['b'], []) >>> os.makedirs('/tmp/a/b2') >>> next(gen) ('/tmp/a/b', ['c'], []) >>> next(gen) ('/tmp/a/b/c', [], []) >>> gen = os.walk('/tmp/a', onerror=print) >>> next(gen) ('/tmp/a', ['b2', 'b'], []) >>> os.rmdir('/tmp/a/b2') >>> next(gen) [Errno 2] No such file or directory: '/tmp/a/b2' ('/tmp/a/b', ['c'], []) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 17:39:37 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Mon, 16 Jan 2012 16:39:37 +0000 Subject: [docs] [issue8913] Document that datetime.__format__ is datetime.strftime In-Reply-To: <1275794779.99.0.00462382173098.issue8913@psf.upfronthosting.co.za> Message-ID: <1326731977.01.0.78435634329.issue8913@psf.upfronthosting.co.za> ?ric Araujo added the comment: IMO, now that two official releases of Python 3 have shipped with this behavior (3.1 and 3.2), it is too late to think about changing what datetime.__format__ does, and we should merely document that it is the same as strftime. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 18:06:36 2012 From: report at bugs.python.org (Roundup Robot) Date: Mon, 16 Jan 2012 17:06:36 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 7167c04780ed by Sandro Tosi in branch '2.7': Issue: #12409: remove obsolete susp-entries http://hg.python.org/cpython/rev/7167c04780ed New changeset 153e32333aaa by Sandro Tosi in branch '3.2': Issue: #12409: remove obsolete susp-entries http://hg.python.org/cpython/rev/153e32333aaa New changeset a6bf08666da2 by Sandro Tosi in branch 'default': Issue: #12409: merge with 3.2 http://hg.python.org/cpython/rev/a6bf08666da2 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 18:07:29 2012 From: report at bugs.python.org (Sandro Tosi) Date: Mon, 16 Jan 2012 17:07:29 +0000 Subject: [docs] [issue12409] Moving "Documenting Python" to Devguide In-Reply-To: <1309008968.0.0.644952507743.issue12409@psf.upfronthosting.co.za> Message-ID: <1326733649.74.0.593986908406.issue12409@psf.upfronthosting.co.za> Sandro Tosi added the comment: ?ric, thanks for spotting it: removed. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 19:04:46 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 16 Jan 2012 18:04:46 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326737086.88.0.00137550738699.issue13695@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: I guess you're reffering to the "i'th" --> "i-th" thing. I found numerous occasions on the Internet that say like "n-th element blah blah blah", not "n'th element..." So I guess writting this thing as "i-th" would be correct here, too. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 19:52:09 2012 From: report at bugs.python.org (Sandro Tosi) Date: Mon, 16 Jan 2012 18:52:09 +0000 Subject: [docs] [issue13801] The Python 3 Docs don't highlight nonlocal In-Reply-To: <1326720484.97.0.730349515473.issue13801@psf.upfronthosting.co.za> Message-ID: <1326739929.8.0.7670329294.issue13801@psf.upfronthosting.co.za> Changes by Sandro Tosi : ---------- nosy: +sandro.tosi _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 21:00:26 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 16 Jan 2012 20:00:26 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326744026.8.0.673125966561.issue13695@psf.upfronthosting.co.za> Georg Brandl added the comment: "numerous occasions" is not good enough. Why not let a native speaker decide? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 16 21:19:32 2012 From: report at bugs.python.org (Sandro Tosi) Date: Mon, 16 Jan 2012 20:19:32 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1326745172.05.0.832356161607.issue12415@psf.upfronthosting.co.za> Sandro Tosi added the comment: that looks ok to me. ---------- _______________________________________ Python tracker _______________________________________ From P at draigBrady.com Mon Jan 16 11:26:54 2012 From: P at draigBrady.com (=?UTF-8?B?UMOhZHJhaWcgQnJhZHk=?=) Date: Mon, 16 Jan 2012 10:26:54 +0000 Subject: [docs] python 2.6 does support 'b' prefix on strings Message-ID: <4F13FB6E.7070506@draigBrady.com> In the language reference, there is no mention of the b prefix for string literals. http://docs.python.org/release/2.6/reference/lexical_analysis.html#literals This should be added to be consistent with the info here: http://docs.python.org/release/2.6/whatsnew/2.6.html#pep-3112-byte-literals The top link should also be adjusted for 2.6.[1-7] cheers, P?draig. From hafnersimon at gmail.com Mon Jan 16 12:33:36 2012 From: hafnersimon at gmail.com (Simon Hafner) Date: Mon, 16 Jan 2012 12:33:36 +0100 Subject: [docs] Information reordering Message-ID: Hello [1] does mention None as i in (5), but it should be moved to (4), as the information is relevant in that footnote. Have a nice day Simon [1] http://docs.python.org/library/stdtypes.html#sequence-types-str-unicode-list-tuple-bytearray-buffer-xrange From sandro.tosi at gmail.com Mon Jan 16 21:23:37 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Mon, 16 Jan 2012 21:23:37 +0100 Subject: [docs] python 2.6 does support 'b' prefix on strings In-Reply-To: <4F13FB6E.7070506@draigBrady.com> References: <4F13FB6E.7070506@draigBrady.com> Message-ID: Hello P?draig, thanks for your email. 2012/1/16 P?draig Brady

: > In the language reference, there is no mention of the b prefix for string literals. > http://docs.python.org/release/2.6/reference/lexical_analysis.html#literals > This should be added to be consistent with the info here: > http://docs.python.org/release/2.6/whatsnew/2.6.html#pep-3112-byte-literals > > The top link should also be adjusted for 2.6.[1-7] 2.6 release is in security-only bugfixes, so documentation updates are no longer possible. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Tue Jan 17 10:55:38 2012 From: report at bugs.python.org (Ezio Melotti) Date: Tue, 17 Jan 2012 09:55:38 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1326794138.45.0.157088847775.issue12415@psf.upfronthosting.co.za> Ezio Melotti added the comment: +The documentation sources are part of the main :ref:`CPython Mercurial +repository `. I think "documentation sources" is a bit vague. If the goal is enable people to find those files, IMHO it would be better to state explicitly that there are bunch of rst files in the Doc/ directory that comes with cpython and that they are used to build the online documentation. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 17 11:00:56 2012 From: report at bugs.python.org (Ezio Melotti) Date: Tue, 17 Jan 2012 10:00:56 +0000 Subject: [docs] [issue13799] Base 16 should be hexadecimal in Unicode HOWTO In-Reply-To: <1326718246.49.0.980962494093.issue13799@psf.upfronthosting.co.za> Message-ID: <1326794456.65.0.679062743257.issue13799@psf.upfronthosting.co.za> Ezio Melotti added the comment: Do you mean the "base 16" in this sentence: "A code point is an integer value, usually denoted in base 16."? Why would "hexadecimal" be better than "base 16"? ---------- assignee: docs at python -> ezio.melotti nosy: +ezio.melotti versions: -Python 2.6, Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 17 14:01:28 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 17 Jan 2012 13:01:28 +0000 Subject: [docs] [issue12600] Add example of using load_tests to parameterise Test Cases In-Reply-To: <1311226769.48.0.369455670372.issue12600@psf.upfronthosting.co.za> Message-ID: <1326805288.32.0.965098042065.issue12600@psf.upfronthosting.co.za> Nick Coghlan added the comment: I agree with David, so switching this over to a docs enhancement request. ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python title: Support parameterized TestCases in unittest -> Add example of using load_tests to parameterise Test Cases versions: +Python 2.7, Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 17 15:22:24 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Tue, 17 Jan 2012 14:22:24 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326810144.2.0.698362369605.issue13695@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Well, actually, it's the only correct way to write it (i-th). This is a simple orthographical error that was made. Ezio, please fix those two additional typos. And Georg, stop being such a wise-ass. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 17 17:35:08 2012 From: report at bugs.python.org (=?utf-8?q?=C3=89ric_Araujo?=) Date: Tue, 17 Jan 2012 16:35:08 +0000 Subject: [docs] [issue12415] Missing: How to checkout the Doc sources In-Reply-To: <1309069778.19.0.06342861361.issue12415@psf.upfronthosting.co.za> Message-ID: <1326818108.28.0.770940129847.issue12415@psf.upfronthosting.co.za> ?ric Araujo added the comment: > I think "documentation sources" is a bit vague. I don?t know. I probably wrote it under the assumption that the audience of this doc was developers, who already know that programmers don?t write HTML manually but generate it, and just need to know where to find the sources. To a C programmer wanting to fix a bug, we just say ?the sources for X are in Include and Modules?, and it?s enough. Thinking about it, the assumption is probably bad. Sometimes we have to explain to new contributors where to find a Python module in the repo and how to write a test, so it would probably be better to explain more. Here?s my draft, feel free to improve my patch with it (there may be duplication) and commit the result when you two are in agreement while I?ll be offline. The documentation in HTML, PDF or epub format is generated from text files written using the :ref:`reStructuredText format and contained in the :ref:`CPython Mercurial repository `. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 17 20:14:15 2012 From: report at bugs.python.org (Georg Brandl) Date: Tue, 17 Jan 2012 19:14:15 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326827655.81.0.956506140682.issue13695@psf.upfronthosting.co.za> Georg Brandl added the comment: Once you start contributing anything useful, I will start treating it as such. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 09:31:33 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Wed, 18 Jan 2012 08:31:33 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326875493.14.0.0844277039798.issue13695@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Shut?up,?Georg!?Ezio,?please?fix?this?two?additional?typos?to?close?this?bug?report?for?good. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 16:55:01 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Wed, 18 Jan 2012 15:55:01 +0000 Subject: [docs] [issue13695] "type specific" to "type-specific" In-Reply-To: <1325483290.25.0.872020961031.issue13695@psf.upfronthosting.co.za> Message-ID: <1326902101.26.0.894620630961.issue13695@psf.upfronthosting.co.za> Changes by Bo?tjan Mejak : ---------- nosy: -georg.brandl resolution: remind -> _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 17:23:15 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Wed, 18 Jan 2012 16:23:15 +0000 Subject: [docs] [issue13816] Two typos in the docs Message-ID: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> New submission from Bo?tjan Mejak : There's a typo in the docs for cmp_to_key() function. Fix the first sentence "Transform an old-style comparison function to a key-function." to "Transform an old-style comparison function to a key function." (delete the hyphen between words "key" and "function") http://docs.python.org/library/functools.html#functools.cmp_to_key ------------------------------------------------------------------ There's another typo in the docs lurking in http://docs.python.org/library/stdtypes.html#sequence-types-str-unicode-list-tuple-bytearray-buffer-xrange Look for the table with the columns "Operation", "Result", "Notes" (scroll down and you'll find it), and fix the text of the fifth cell under the "Result" column like this: "i'th item of s, origin 0" --> "i-th item of s, origin 0". Change that apostrophe into a hyphen, so "i'th" to "i-th". Thanks, Ezio. ---------- assignee: docs at python components: Documentation messages: 151547 nosy: Retro, docs at python, ezio.melotti priority: normal severity: normal status: open title: Two typos in the docs type: enhancement versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 17:46:58 2012 From: report at bugs.python.org (Stefan Krah) Date: Wed, 18 Jan 2012 16:46:58 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1326905218.34.0.868958929432.issue13816@psf.upfronthosting.co.za> Stefan Krah added the comment: Just as a note: It is not acceptable to be rude on the tracker or to remove people from the nosy list as you did in #13695. ---------- nosy: +skrah _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 18:14:01 2012 From: report at bugs.python.org (Georg Brandl) Date: Wed, 18 Jan 2012 17:14:01 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1326906841.06.0.293153932321.issue13816@psf.upfronthosting.co.za> Georg Brandl added the comment: And not really working, as I get updates for all assignments to docs at python anyway. ---------- nosy: +georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 18:17:38 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Wed, 18 Jan 2012 17:17:38 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1326907058.27.0.910307887968.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: I?am?deeply?and?truly?sorry.?Can?we?now?fix?this? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 19:28:54 2012 From: report at bugs.python.org (Justin Wehnes) Date: Wed, 18 Jan 2012 18:28:54 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1326911334.2.0.341579982776.issue13816@psf.upfronthosting.co.za> Justin Wehnes added the comment: Removed the hyphen in function keys. Didn't really see a problem with using an apostrophe in 'ith' instead of a hyphen because I have seen it done both ways but changed it anyways. This is my first contribution so i needed the practice. Hope I did everything correctly. ---------- keywords: +patch nosy: +JWEH Added file: http://bugs.python.org/file24273/hyphen_removed_key_function.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 18 19:30:00 2012 From: report at bugs.python.org (Justin Wehnes) Date: Wed, 18 Jan 2012 18:30:00 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1326911400.4.0.782666485133.issue13816@psf.upfronthosting.co.za> Changes by Justin Wehnes : Added file: http://bugs.python.org/file24274/i_th_hyphen.diff _______________________________________ Python tracker _______________________________________ From bardos at ansys.ch Wed Jan 18 16:38:56 2012 From: bardos at ansys.ch (Robert Bardos/ansys) Date: Wed, 18 Jan 2012 16:38:56 +0100 Subject: [docs] Error(s)/omissions on glossary page Message-ID: Page: http://docs.python.org/py3k/glossary.html Item 'key function': paragraph 3: "constructors" is misspelled as "constuctors" Coincidentally a glossary entry for "constructor" itself is sorely being missed. Kind regards Robert Bardos From report at bugs.python.org Thu Jan 19 01:45:57 2012 From: report at bugs.python.org (Jim Jewett) Date: Thu, 19 Jan 2012 00:45:57 +0000 Subject: [docs] [issue13820] 2.6 is no longer in the future Message-ID: <1326933957.4.0.830452813069.issue13820@psf.upfronthosting.co.za> New submission from Jim Jewett : http://docs.python.org/reference/lexical_analysis.html Changed in version 2.5: Both as and with are only recognized when the with_statement future feature has been enabled. It will always be enabled in Python 2.6. See section The with statement for details. Note that using as and with as identifiers will always issue a warning, even when the with_statement future directive is not in effect. That was reasonable wording for 2.5 itself, but at this point, I think it would be simpler to add a Changed in version 2.6 entry. Perhaps: Changed in version 2.5: Using as or with as identifiers triggers a warning. Using them as statements requires the with_statement future feature. Changed in Python 2.6: as and with became full keywords. ---------- assignee: docs at python components: Documentation messages: 151595 nosy: Jim.Jewett, docs at python priority: normal severity: normal status: open title: 2.6 is no longer in the future type: enhancement versions: Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 07:46:57 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 19 Jan 2012 06:46:57 +0000 Subject: [docs] [issue2134] Add new attribute to TokenInfo to report specific token IDs In-Reply-To: <1203289230.78.0.790200923315.issue2134@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 75baef657770 by Meador Inge in branch '2.7': Issue #2134: Clarify token.OP handling rationale in tokenize documentation. http://hg.python.org/cpython/rev/75baef657770 New changeset dfd74d752b0e by Meador Inge in branch '3.2': Issue #2134: Clarify token.OP handling rationale in tokenize documentation. http://hg.python.org/cpython/rev/dfd74d752b0e New changeset f4976fa6e830 by Meador Inge in branch 'default': Issue #2134: Add support for tokenize.TokenInfo.exact_type. http://hg.python.org/cpython/rev/f4976fa6e830 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 07:49:14 2012 From: report at bugs.python.org (Meador Inge) Date: Thu, 19 Jan 2012 06:49:14 +0000 Subject: [docs] [issue2134] Add new attribute to TokenInfo to report specific token IDs In-Reply-To: <1203289230.78.0.790200923315.issue2134@psf.upfronthosting.co.za> Message-ID: <1326955754.57.0.544644383467.issue2134@psf.upfronthosting.co.za> Meador Inge added the comment: Fixed. Thanks for the reviews everyone. ---------- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 09:51:47 2012 From: report at bugs.python.org (patrick vrijlandt) Date: Thu, 19 Jan 2012 08:51:47 +0000 Subject: [docs] [issue13823] xml.etree.ElementTree.ElementTree.write - argument checking Message-ID: <1326963107.43.0.928827185581.issue13823@psf.upfronthosting.co.za> New submission from patrick vrijlandt : (1) The docs say: xml_declaration controls if an XML declaration should be added to the file. Use False for never, True for always, None for only if not US-ASCII or UTF-8 or Unicode (default is None). The method also accepts other values, like xml_declaration = "yes". This behavior should be documented, or raise a ValueError (up to effbot, I think) (2) The docs say (in a note): The encoding string included in XML output should conform to the appropriate standards. For example, ?UTF-8? is valid, but ?UTF8? is not. See http://www.w3.org/ But the method accepts both values, (?UTF-8? and ?UTF8?). Since this will result in invalid xml, (but not invalid python) it should probably raise ValueError too. (3) Open issue 9458 also refers to this method. It might be wise to raise ValueError if the encoding does not match the (mode of the) file target (binary or text). ---------- assignee: docs at python components: Documentation, XML messages: 151612 nosy: docs at python, patrick.vrijlandt priority: normal severity: normal status: open title: xml.etree.ElementTree.ElementTree.write - argument checking versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 11:32:52 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 19 Jan 2012 10:32:52 +0000 Subject: [docs] [issue11948] Tutorial/Modules - small fix to better clarify the modules search path In-Reply-To: <1304011111.24.0.834772686878.issue11948@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset d01208ba482f by Sandro Tosi in branch '2.7': Issue #11948: clarify modules search path http://hg.python.org/cpython/rev/d01208ba482f New changeset 6d663db63705 by Sandro Tosi in branch '3.2': Issue #11948: clarify modules search path http://hg.python.org/cpython/rev/6d663db63705 New changeset 93769b8ff40b by Sandro Tosi in branch 'default': Issue #11948: merge with 3.2 http://hg.python.org/cpython/rev/93769b8ff40b ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 11:34:17 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 19 Jan 2012 10:34:17 +0000 Subject: [docs] [issue11948] Tutorial/Modules - small fix to better clarify the modules search path In-Reply-To: <1304011111.24.0.834772686878.issue11948@psf.upfronthosting.co.za> Message-ID: <1326969257.13.0.120828457766.issue11948@psf.upfronthosting.co.za> Sandro Tosi added the comment: Thanks Terry for the ping, I've just committed it - thanks again to everyone for the help/suggestions. ---------- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 15:25:15 2012 From: report at bugs.python.org (Julian Berman) Date: Thu, 19 Jan 2012 14:25:15 +0000 Subject: [docs] [issue13826] Having a shlex example in the subprocess.Popen docs is confusing Message-ID: <1326983115.48.0.551767400168.issue13826@psf.upfronthosting.co.za> New submission from Julian Berman : The example at http://docs.python.org/dev/library/subprocess.html#popen-constructor seems a bit misplaced, as it seems to suggest that one should use the shlex module. Most of the other examples in the module seem to use a list to provide the args, so if there was a need to just point out that shlex could be used for a corner case perhaps it'd be better suited as a footnote or another subsection somewhere. ---------- assignee: docs at python components: Documentation messages: 151624 nosy: Julian, docs at python priority: normal severity: normal status: open title: Having a shlex example in the subprocess.Popen docs is confusing type: enhancement versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 15:36:48 2012 From: report at bugs.python.org (R. David Murray) Date: Thu, 19 Jan 2012 14:36:48 +0000 Subject: [docs] [issue13826] Having a shlex example in the subprocess.Popen docs is confusing In-Reply-To: <1326983115.48.0.551767400168.issue13826@psf.upfronthosting.co.za> Message-ID: <1326983808.87.0.793563902467.issue13826@psf.upfronthosting.co.za> R. David Murray added the comment: It is not particularly intuitive what goes in to a Popen non-shell argument list, unless you are an experienced programmer. The real purpose of the note is to convey a lot of information about how tokenization works in a short example, and it also demonstrates how to investigate other complex cases the user may have to deal with. Because of the first part of that (showing tokenization quirks) I don't think it should be relegated to a footnote. That said, the example could perhaps be reworded slightly to make its expositional purpose clearer. Suggestions welcome. ---------- nosy: +r.david.murray _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 15:37:14 2012 From: report at bugs.python.org (R. David Murray) Date: Thu, 19 Jan 2012 14:37:14 +0000 Subject: [docs] [issue13826] Having a shlex example in the subprocess.Popen docs is confusing In-Reply-To: <1326983115.48.0.551767400168.issue13826@psf.upfronthosting.co.za> Message-ID: <1326983834.73.0.224722869192.issue13826@psf.upfronthosting.co.za> Changes by R. David Murray : ---------- priority: normal -> low _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 15:45:47 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 19 Jan 2012 14:45:47 +0000 Subject: [docs] [issue13826] Having a shlex example in the subprocess.Popen docs is confusing In-Reply-To: <1326983115.48.0.551767400168.issue13826@psf.upfronthosting.co.za> Message-ID: <1326984347.34.0.658167761064.issue13826@psf.upfronthosting.co.za> Sandro Tosi added the comment: Maybe we can add a very small example before the whole note to show just how to use Popen in simple situation, and so the shlex part below will add more details for more advanced cases. ---------- nosy: +sandro.tosi versions: -Python 2.6, Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 16:32:57 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 19 Jan 2012 15:32:57 +0000 Subject: [docs] [issue13478] No documentation for timeit.default_timer In-Reply-To: <1322208815.17.0.598781679655.issue13478@psf.upfronthosting.co.za> Message-ID: <1326987177.69.0.981004282108.issue13478@psf.upfronthosting.co.za> Sandro Tosi added the comment: I propose these 2 patches: I'm not exactly proud of - 'in a platform specific manner' in the first hunk - the second hunk I know that there should be a better way to express it, but since I can't get to it I'd just ask for suggestions :) ---------- keywords: +patch stage: needs patch -> patch review Added file: http://bugs.python.org/file24276/issue13478-py27.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 16:33:04 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 19 Jan 2012 15:33:04 +0000 Subject: [docs] [issue13478] No documentation for timeit.default_timer In-Reply-To: <1322208815.17.0.598781679655.issue13478@psf.upfronthosting.co.za> Message-ID: <1326987184.02.0.737365722553.issue13478@psf.upfronthosting.co.za> Changes by Sandro Tosi : Added file: http://bugs.python.org/file24277/issue13478-py32.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 17:52:02 2012 From: report at bugs.python.org (Eric Snow) Date: Thu, 19 Jan 2012 16:52:02 +0000 Subject: [docs] [issue11948] Tutorial/Modules - small fix to better clarify the modules search path In-Reply-To: <1304011111.24.0.834772686878.issue11948@psf.upfronthosting.co.za> Message-ID: <1326991922.23.0.177000049641.issue11948@psf.upfronthosting.co.za> Eric Snow added the comment: FYI: unless importlib took undue liberties (unlikely), frozen modules also precede path-based modules. See the implicit additions to sys.meta_path in Lib/importlib/_bootstrap.py. Whether or not to include a mention of frozen modules in the tutorial...I'll leave that to you. :) ---------- nosy: +eric.snow _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 18:06:03 2012 From: report at bugs.python.org (Jim Jewett) Date: Thu, 19 Jan 2012 17:06:03 +0000 Subject: [docs] [issue13828] Further improve casefold documentation Message-ID: <1326992763.46.0.576190503242.issue13828@psf.upfronthosting.co.za> New submission from Jim Jewett : > http://hg.python.org/cpython/rev/0b5ce36a7a24 > changeset: ? 74515:0b5ce36a7a24 > + ? Casefolding is similar to lowercasing but more aggressive because it is > + ? intended to remove all case distinctions in a string. For example, the German > + ? lowercase letter ``'?'`` is equivalent to ``"ss"``. Since it is already > + ? lowercase, :meth:`lower` would do nothing to ``'?'``; :meth:`casefold` > + ? converts it to ``"ss"``. Perhaps add the recommendation to canonicalize as well. A complete, but possibly too long, try is below: Casefolding is similar to lowercasing but more aggressive because it is intended to remove all case distinctions in a string. For example, the German lowercase letter ``'?'`` is equivalent to ``"ss"``. Since it is already lowercase, :meth:`lower` would do nothing to ``'?'``; :meth:`casefold` converts it to ``"ss"``. Note that most case-insensitive matches should also match compatibility equivalent characters. The casefolding algorithm is described in section 3.13 of the Unicode Standard. Per D146, a compatibility caseless match can be achieved by from unicodedata import normalize def caseless_compat(string): nfd_string = normalize("NFD", string) nfkd1_string = normalize("NFKD", nfd_string.casefold()) return normalize("NFKD", nfkd1_string.casefold()) ---------- assignee: docs at python components: Documentation messages: 151644 nosy: Jim.Jewett, benjamin.peterson, docs at python priority: normal severity: normal status: open title: Further improve casefold documentation versions: Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 18:09:52 2012 From: report at bugs.python.org (Jim Jewett) Date: Thu, 19 Jan 2012 17:09:52 +0000 Subject: [docs] [issue13828] Further improve casefold documentation In-Reply-To: <1326992763.46.0.576190503242.issue13828@psf.upfronthosting.co.za> Message-ID: <1326992992.82.0.889737652746.issue13828@psf.upfronthosting.co.za> Jim Jewett added the comment: Frankly, I do think that sample code is too long, but correctness matters ... perhaps a better solution would be to add either a method or a unicodedata function that does the work, then the extra note could just say Note that most case-insensitive matches should also match compatibility equivalent characters; see unicodedata.compatibity_casefold ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 20:41:58 2012 From: report at bugs.python.org (Julian Berman) Date: Thu, 19 Jan 2012 19:41:58 +0000 Subject: [docs] [issue13826] Having a shlex example in the subprocess.Popen docs is confusing In-Reply-To: <1326983115.48.0.551767400168.issue13826@psf.upfronthosting.co.za> Message-ID: <1327002118.25.0.675845405273.issue13826@psf.upfronthosting.co.za> Julian Berman added the comment: Sounds reasonable to me. I'll take a look at adding one unless someone manages to beat me to it. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 22:03:06 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Thu, 19 Jan 2012 21:03:06 +0000 Subject: [docs] [issue11948] Tutorial/Modules - small fix to better clarify the modules search path In-Reply-To: <1304011111.24.0.834772686878.issue11948@psf.upfronthosting.co.za> Message-ID: <1327006986.29.0.238160529646.issue11948@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Definitely out-of-scope for the tutorial. I consider this akin to monkey patching imported modules. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 22:03:39 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 19 Jan 2012 21:03:39 +0000 Subject: [docs] [issue13605] document argparse's nargs=REMAINDER In-Reply-To: <1323955710.42.0.753468095058.issue13605@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 35665f6f3674 by Sandro Tosi in branch '2.7': Issue #13605: add documentation for nargs=argparse.REMAINDER http://hg.python.org/cpython/rev/35665f6f3674 New changeset 6f3d55f5a31e by Sandro Tosi in branch '3.2': Issue #13605: add documentation for nargs=argparse.REMAINDER http://hg.python.org/cpython/rev/6f3d55f5a31e New changeset 6b4cec0719a3 by Sandro Tosi in branch 'default': Issue #13605: merge with 3.2 http://hg.python.org/cpython/rev/6b4cec0719a3 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 22:09:23 2012 From: report at bugs.python.org (Sandro Tosi) Date: Thu, 19 Jan 2012 21:09:23 +0000 Subject: [docs] [issue13605] document argparse's nargs=REMAINDER In-Reply-To: <1323955710.42.0.753468095058.issue13605@psf.upfronthosting.co.za> Message-ID: <1327007363.82.0.572283125324.issue13605@psf.upfronthosting.co.za> Changes by Sandro Tosi : ---------- nosy: +sandro.tosi resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed versions: +Python 2.7, Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 22:26:27 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 19 Jan 2012 21:26:27 +0000 Subject: [docs] [issue13605] document argparse's nargs=REMAINDER In-Reply-To: <1323955710.42.0.753468095058.issue13605@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 1b481e76cd16 by Sandro Tosi in branch '2.7': Issue #13605: more meaningful example + fixes http://hg.python.org/cpython/rev/1b481e76cd16 New changeset d6e53d1f46eb by Sandro Tosi in branch '3.2': Issue #13605: more meaningful example + fixes http://hg.python.org/cpython/rev/d6e53d1f46eb New changeset 4c3271527794 by Sandro Tosi in branch 'default': Issue #13605: merge with 3.2 http://hg.python.org/cpython/rev/4c3271527794 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 19 22:56:14 2012 From: report at bugs.python.org (Torsten Landschoff) Date: Thu, 19 Jan 2012 21:56:14 +0000 Subject: [docs] [issue13833] No documentation for PyStructSequence Message-ID: <1327010174.09.0.407534369688.issue13833@psf.upfronthosting.co.za> New submission from Torsten Landschoff : While writing a C extension I wanted to create a namedtuple like object as os.statvfs and friends do. I was unable to find a simple way to do this from C and was wondering how the posixmodule does it. It turned out that there is a PyStructSequence type for this. It would be nice to have it documented. First draft for the documentation update attached. ---------- assignee: docs at python components: Documentation files: structseq_doc.diff keywords: patch messages: 151657 nosy: docs at python, torsten priority: normal severity: normal status: open title: No documentation for PyStructSequence type: enhancement versions: Python 3.3 Added file: http://bugs.python.org/file24280/structseq_doc.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 20 02:12:45 2012 From: report at bugs.python.org (Benjamin Peterson) Date: Fri, 20 Jan 2012 01:12:45 +0000 Subject: [docs] [issue13828] Further improve casefold documentation In-Reply-To: <1326992763.46.0.576190503242.issue13828@psf.upfronthosting.co.za> Message-ID: <1327021965.02.0.64214478526.issue13828@psf.upfronthosting.co.za> Benjamin Peterson added the comment: It's a bit unfriendly to launch into discussion of "compatiblity caseless matching" when the new reader probably has no idea what "compatibility-equivalence" is. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 20 04:48:26 2012 From: report at bugs.python.org (Meador Inge) Date: Fri, 20 Jan 2012 03:48:26 +0000 Subject: [docs] [issue12949] Documentation of PyCode_New() lacks kwonlyargcount argument In-Reply-To: <1315592789.75.0.632556595518.issue12949@psf.upfronthosting.co.za> Message-ID: <1327031306.86.0.612119571288.issue12949@psf.upfronthosting.co.za> Changes by Meador Inge : ---------- keywords: +easy stage: -> needs patch versions: -Python 3.1 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 20 05:28:48 2012 From: report at bugs.python.org (Roundup Robot) Date: Fri, 20 Jan 2012 04:28:48 +0000 Subject: [docs] [issue12949] Documentation of PyCode_New() lacks kwonlyargcount argument In-Reply-To: <1315592789.75.0.632556595518.issue12949@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset b22a35c14a91 by Meador Inge in branch '3.2': Issue #12949: Document the kwonlyargcount argument for the PyCode_New C API function. http://hg.python.org/cpython/rev/b22a35c14a91 New changeset 218b167ff521 by Meador Inge in branch 'default': Issue #12949: Document the kwonlyargcount argument for the PyCode_New C API function. http://hg.python.org/cpython/rev/218b167ff521 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 20 05:31:38 2012 From: report at bugs.python.org (Meador Inge) Date: Fri, 20 Jan 2012 04:31:38 +0000 Subject: [docs] [issue12949] Documentation of PyCode_New() lacks kwonlyargcount argument In-Reply-To: <1315592789.75.0.632556595518.issue12949@psf.upfronthosting.co.za> Message-ID: <1327033898.54.0.519873177155.issue12949@psf.upfronthosting.co.za> Meador Inge added the comment: Fixed. Thanks for the report Stefan. ---------- nosy: +meador.inge resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 20 20:06:28 2012 From: report at bugs.python.org (Jean-Lou Dupont) Date: Fri, 20 Jan 2012 19:06:28 +0000 Subject: [docs] [issue11076] Iterable argparse Namespace In-Reply-To: <1296461103.49.0.397676179483.issue11076@psf.upfronthosting.co.za> Message-ID: <1327086388.94.0.0910473560568.issue11076@psf.upfronthosting.co.za> Changes by Jean-Lou Dupont : ---------- nosy: +Jean-Lou.Dupont _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 00:44:42 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Fri, 20 Jan 2012 23:44:42 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327103082.72.0.839598267156.issue13790@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Doc patch attached to make sure correct. Should {} be quoted? Eric, do you want to close off the idea of changing :d errors, or switch back after the doc fix? ---------- keywords: +patch nosy: +terry.reedy stage: -> test needed Added file: http://bugs.python.org/file24287/i13790.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 01:16:25 2012 From: report at bugs.python.org (Eric V. Smith) Date: Sat, 21 Jan 2012 00:16:25 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327104985.35.0.90065015845.issue13790@psf.upfronthosting.co.za> Eric V. Smith added the comment: I don't think "{}" is the correct way to document this. These all have an empty format specifier: "{}".format(foo) "{:}".format(foo) "{0}".format(foo) "{0:}".format(foo) "{name}".format(name=foo) format(foo, "") format(foo) That is, they all call foo.__format__(""). If foo.__format__ (well, really type(foo).__format__) doesn't exist, then object.__format__(foo, "") gets called. It's object.__format__ that's checking for the empty format string, and if so it returns str(foo). What would you suggest changing the ':d' error message to, for objects that don't support a format type of 'd'? This makes sense to me: >>> format('', 'd') Traceback (most recent call last): File "", line 1, in ValueError: Unknown format code 'd' for object of type 'str' The problem, if there is one, is: >>> format([], 'd') Traceback (most recent call last): File "", line 1, in ValueError: Unknown format code 'd' for object of type 'str' The problem is that the str that's producing this error doesn't know that it exists because object.__format__ returned str([]). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 03:34:10 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 21 Jan 2012 02:34:10 +0000 Subject: [docs] [issue13799] Base 16 should be hexadecimal in Unicode HOWTO In-Reply-To: <1326718246.49.0.980962494093.issue13799@psf.upfronthosting.co.za> Message-ID: <1327113250.18.0.458033480729.issue13799@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- nosy: +terry.reedy _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 05:17:09 2012 From: report at bugs.python.org (py.user) Date: Sat, 21 Jan 2012 04:17:09 +0000 Subject: [docs] [issue13834] In help(bytes.strip) there is no info about leading ASCII whitespace Message-ID: <1327119429.45.0.897722607985.issue13834@psf.upfronthosting.co.za> New submission from py.user : help(bytes.strip): strip(...) B.strip([bytes]) -> bytes Strip leading and trailing bytes contained in the argument. If the argument is omitted, strip trailing ASCII whitespace. ---------- assignee: docs at python components: Documentation messages: 151718 nosy: docs at python, py.user priority: normal severity: normal status: open title: In help(bytes.strip) there is no info about leading ASCII whitespace versions: Python 3.2 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 05:48:37 2012 From: report at bugs.python.org (R. David Murray) Date: Sat, 21 Jan 2012 04:48:37 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327121317.63.0.157154868056.issue13790@psf.upfronthosting.co.za> R. David Murray added the comment: Oh, I see. Yes, that is a problem. object.__format__ knows the type of the object it was called on, right? Couldn't it catch the error and re-raise it with the correct type? (If the type isn't str, of course, we don't want to get into an infinite recursion.) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 05:50:14 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 21 Jan 2012 04:50:14 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327121414.24.0.905508535086.issue13816@psf.upfronthosting.co.za> Terry J. Reedy added the comment: The Chicago Manual of Style. which is perhaps the mostly widely used general style manual in the US, uses 'th' as a suffix without ' or -. ie, 28th, etc except for 22d ('preferred' to 22nd) and 23d ('preferred' to 23rd). https://en.wiktionary.org/wiki/nth gives nth, which I use, with *n*th (italic n) as alternate form (when italic is available) and n'th and n-th as 'sometimes used'. I think both of the last two are ugly and that we should use either nth or, since we can, *n*th. I see that we already have *i*. ---------- nosy: +terry.reedy _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 05:50:16 2012 From: report at bugs.python.org (R. David Murray) Date: Sat, 21 Jan 2012 04:50:16 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327121416.09.0.67580699625.issue13790@psf.upfronthosting.co.za> R. David Murray added the comment: Oh, never mind that comment about recursion, I wasn't thinking it through. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 06:33:43 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 21 Jan 2012 05:33:43 +0000 Subject: [docs] [issue13820] 2.6 is no longer in the future In-Reply-To: <1326933957.4.0.830452813069.issue13820@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset c84b39c18963 by Terry Jan Reedy in branch '2.7': Issue13820 as and with really became keywords in 2.6. http://hg.python.org/cpython/rev/c84b39c18963 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 06:35:57 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 21 Jan 2012 05:35:57 +0000 Subject: [docs] [issue13820] 2.6 is no longer in the future In-Reply-To: <1326933957.4.0.830452813069.issue13820@psf.upfronthosting.co.za> Message-ID: <1327124157.85.0.503671828907.issue13820@psf.upfronthosting.co.za> Terry J. Reedy added the comment: I verified that 'as' and 'with' are in the 2.6 keyword.kwlist. http://svn.python.org/projects/python/branches/release26-maint/Lib/keyword.py. I verified that they work as keywords in 2.7. http://svn.python.org/projects/python/branches/release26-maint/Doc/reference/compound_stmts.rst says with is always enabled in 2.6. I fixed whitespace error in 74551 (117d58fc6e8d) ---------- assignee: docs at python -> terry.reedy nosy: +terry.reedy resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 06:56:25 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sat, 21 Jan 2012 05:56:25 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327125385.02.0.628755184945.issue13790@psf.upfronthosting.co.za> Terry J. Reedy added the comment: OK, the example of an empty format spec should be dropped. Let people figure it out ;-). >>> format([], 'd') Traceback (most recent call last): File "", line 1, in ValueError: Unknown format code 'd' for object of type 'str' One possibility is to give (str of) the object instead of the type: ValueError: Unknown format code 'd' for object '[]' The downside is a long message for long strings. It would need to be limited (as is done in test error reports). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 10:47:19 2012 From: report at bugs.python.org (Eric V. Smith) Date: Sat, 21 Jan 2012 09:47:19 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327139239.07.0.359898408574.issue13790@psf.upfronthosting.co.za> Eric V. Smith added the comment: While looking at object.__format__, I recall that we've already addressed this, sort of. For a different reason, this is already deprecated in 3.3 and will become an error in 3.4. See issues 9856 and 7994. $ ./python -Wd Python 3.3.0a0 (default:40e1be1e0707, Jan 15 2012, 00:58:51) [GCC 4.6.1] on linux Type "help", "copyright", "credits" or "license" for more information. >>> format([], 'd') __main__:1: DeprecationWarning: object.__format__ with a non-empty format string is deprecated Traceback (most recent call last): File "", line 1, in ValueError: Unknown format code 'd' for object of type 'str' [67288 refs] >>> We could still have object.__format__ catch and re-throw the ValueError with a better message. I'd have to think it through if we could catch all ValueErrors, or if it's possible for another ValueError to be thrown and we'd only catch and rethrow this specific ValueError. But since this is deprecated, I'm not sure it's worth the hassle. I'd advocate closing this issue as "won't fix". ---------- _______________________________________ Python tracker _______________________________________ From justincwatt at gmail.com Thu Jan 19 20:17:21 2012 From: justincwatt at gmail.com (Justin Watt) Date: Thu, 19 Jan 2012 11:17:21 -0800 Subject: [docs] Typo in unittest, under 25.3.4. Organizing test code Message-ID: "Note that in order to test something, we use the one of the assert*()methods" should read: "Note that in order to test something, we use one of the assert*() methods" (remove the extraneous "the") Justin Watt -------------- next part -------------- An HTML attachment was scrubbed... URL: From darren.yin at gmail.com Fri Jan 20 05:40:31 2012 From: darren.yin at gmail.com (Darren Yin) Date: Thu, 19 Jan 2012 20:40:31 -0800 Subject: [docs] classes in csv module example code do not inherit from object Message-ID: http://docs.python.org/library/csv.html at the very bottom, perhaps UTF8Recorder, UnicodeReader, and UnicodeWriter should all inherit from object? --Darren -------------- next part -------------- An HTML attachment was scrubbed... URL: From sandro.tosi at gmail.com Sat Jan 21 11:04:57 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 21 Jan 2012 11:04:57 +0100 Subject: [docs] Typo in unittest, under 25.3.4. Organizing test code In-Reply-To: References: Message-ID: Hello Justin, On Thu, Jan 19, 2012 at 20:17, Justin Watt wrote: > > "Note that in order to test something, we use the one of the assert*() > methods" > > should read: > > "Note that in order to test something, we use one of the assert*() methods" > > (remove the extraneous "the") Thanks for the notice, this has been fixed with this changesets: 686d95691c99 79e7c5841e66 b10e3ec9bf3d Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From sandro.tosi at gmail.com Sat Jan 21 11:33:46 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 21 Jan 2012 11:33:46 +0100 Subject: [docs] classes in csv module example code do not inherit from object In-Reply-To: References: Message-ID: Hello Darren, thanks for your email. On Fri, Jan 20, 2012 at 05:40, Darren Yin wrote: > http://docs.python.org/library/csv.html > > at the very bottom, perhaps UTF8Recorder, UnicodeReader, and UnicodeWriter > should all inherit from object? What you're suggesting is making them new-style classes. In 2.7 the classes are, by default, old-style classes and only with 3.x Python version the new-style classes are the only way to define a class. You can look more at http://docs.python.org/reference/datamodel.html#newstyle . So the syntax used in the example is fine and I think it doesn't need to define a new-style class for an example. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 21 15:20:13 2012 From: report at bugs.python.org (R. David Murray) Date: Sat, 21 Jan 2012 14:20:13 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327155613.9.0.462869428462.issue13790@psf.upfronthosting.co.za> R. David Murray added the comment: So the error is going to be something about the source type not supporting '__format__'? That change will also address the OP's concern about truncated reprs when a fixed string length is specified, so I agree that the title issue can be closed. Terry's patch with the ("{}") removed should be committed, though. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 18:35:19 2012 From: report at bugs.python.org (Eric V. Smith) Date: Sat, 21 Jan 2012 17:35:19 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327167319.61.0.511540551219.issue13790@psf.upfronthosting.co.za> Eric V. Smith added the comment: The error message will be: "non-empty format string passed to object.__format__". I agree with your comment about Terry's patch. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 20:30:16 2012 From: report at bugs.python.org (Roundup Robot) Date: Sat, 21 Jan 2012 19:30:16 +0000 Subject: [docs] [issue12922] StringIO and seek() In-Reply-To: <1315342130.67.0.227650351498.issue12922@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 03e61104f7a2 by Antoine Pitrou in branch '3.2': Issue #12922: fix the TextIOBase documentation to include a description of seek() and tell() methods. http://hg.python.org/cpython/rev/03e61104f7a2 New changeset f7e5abfb31ea by Antoine Pitrou in branch 'default': Issue #12922: fix the TextIOBase documentation to include a description of seek() and tell() methods. http://hg.python.org/cpython/rev/f7e5abfb31ea New changeset fcf4d547bed8 by Antoine Pitrou in branch '2.7': Issue #12922: fix the TextIOBase documentation to include a description of seek() and tell() methods. http://hg.python.org/cpython/rev/fcf4d547bed8 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 20:30:32 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Sat, 21 Jan 2012 19:30:32 +0000 Subject: [docs] [issue12922] StringIO and seek() In-Reply-To: <1315342130.67.0.227650351498.issue12922@psf.upfronthosting.co.za> Message-ID: <1327174232.37.0.742342400769.issue12922@psf.upfronthosting.co.za> Changes by Antoine Pitrou : ---------- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 21 21:35:35 2012 From: report at bugs.python.org (Stefan Krah) Date: Sat, 21 Jan 2012 20:35:35 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327178134.95.0.907115165097.issue13816@psf.upfronthosting.co.za> Stefan Krah added the comment: > ... with *n*th (italic n) as alternate form Knuth uses that in TAOCP, too. I think with or without italics it's the most frequently used form overall. Also the Lisp function is called nth and not n-th, even though in Lisp it is possible to use hyphens in function names. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 03:16:18 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 22 Jan 2012 02:16:18 +0000 Subject: [docs] [issue13790] In str.format an incorrect error message for list, tuple, dict, set In-Reply-To: <1326605478.95.0.601079964751.issue13790@psf.upfronthosting.co.za> Message-ID: <1327198577.87.0.724414001571.issue13790@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Looking further, I noticed that 'string' needed to be changed to 'specification' in the following sentence also. Then I decided that the preceding sentence "Most built-in types implement the following options for format specifications, although some of the formatting options are only supported by the numeric types." should really follow the one about non-empty format specs. This positioning should make it more obvious that most of the options affect the string representation of the object after, not before, the string is produced, and are therefore applicable to all objects and not just string and number objects. I also propose to modify it so it is shorter and no longer contradictory, to read "Most built-in types implement various options for such modifications, although some are only supported by the numeric types." Further on, under "The available string presentation types are:" I think "``'s'`` String format. This is the default type for strings and may be omitted." should have 'and other non-numeric types ' inserted after strings. New patch i13790b.diff attached The point of these additional changes is to make it clearer that the default formatting of non-number, non-string objects is to call str() and then apply the options to the resulting string. That makes something like >>> format(range(5), '-^20s') # same with object.__format__(), 3.3.0a0 '----range(0, 5)-----' predictable and comprehensible. I agree with not making a temporary change (but see below ;-). But it seems that the 3.4 message should at least be "numeric format string passed to object.__format__" or "format string with number-only options passed to object.__format__" or "object.__format__ cannot handle number-only options" as string formats work fine and, I presume, are not deprecated (?). However, if the new ValueError message did not specify object.__format__ (which could still be confusing, even if more accurate), the change could be make now. For instance 'Numeric option 'd' for non-number object'. It would not really matter if it is later raised in object.__format__ instead of str.__format__. I believe *all* of the format codes 'unknown' to str (and by extension, by default, to all other non-number types) *are* number codes. ---------- assignee: docs at python -> terry.reedy Added file: http://bugs.python.org/file24290/i13790b.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 05:09:32 2012 From: report at bugs.python.org (Meador Inge) Date: Sun, 22 Jan 2012 04:09:32 +0000 Subject: [docs] [issue13783] Clean up PEP 380 C API additions In-Reply-To: <1326521987.14.0.4759346281.issue13783@psf.upfronthosting.co.za> Message-ID: <1327205372.09.0.568705477007.issue13783@psf.upfronthosting.co.za> Meador Inge added the comment: 'PyStopIteration_Create' is just a trivial wrapper: PyObject * PyStopIteration_Create(PyObject *value) { return PyObject_CallFunctionObjArgs(PyExc_StopIteration, value, NULL); } It is not needed. As for 'PyGen_FetchStopIterationValue', does it really need to be public? It is trivial to make it private because all calls to it are in 'genobject.c'. However, I am not sure if there is a strong use case for having it public. ---------- nosy: +meador.inge stage: -> needs patch type: -> enhancement _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 07:58:17 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sun, 22 Jan 2012 06:58:17 +0000 Subject: [docs] [issue13814] Document why generators don't support the context management protocol In-Reply-To: <1326883396.25.0.884733470267.issue13814@psf.upfronthosting.co.za> Message-ID: <1327215497.25.0.0529876633689.issue13814@psf.upfronthosting.co.za> Nick Coghlan added the comment: Generators deliberately don't support the context management protocol. This is so that they raise an explicit TypeError or AttributeError (pointing out that __exit__ is missing) if you leave out the @contextmanager decorator when you're using a generator to write an actual context manager. Generators supporting the context management protocol natively would turn that into a far more subtle (and confusing) error: your code would silently fail to invoke the generator body. Ensuring this common error remains easy to detect is far more important than making it easier to invoke close() on a generator object (particularly when contextlib.closing() already makes that very easy). ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python stage: test needed -> needs patch status: pending -> open title: Generators as context managers. -> Document why generators don't support the context management protocol _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 11:03:47 2012 From: report at bugs.python.org (July Tikhonov) Date: Sun, 22 Jan 2012 10:03:47 +0000 Subject: [docs] [issue13835] whatsnew/3.3 misspelling/mislink Message-ID: <1327226626.95.0.153685106815.issue13835@psf.upfronthosting.co.za> New submission from July Tikhonov : 1) Paragraph describing range() comparison links to issue13021. This issue seems unrelated. It should be issue13201. 2) Paragraph describing of unicode_internal codec, mentions "(utf-16-le or utf-16-le)" and "(utf-32-le or utf-32-le)". It should be "(utf-16-le or utf-16-be)" and "(utf-32-le or utf-32-be)" respectively. ---------- assignee: docs at python components: Documentation files: whatsnew-3.3-misspelling.diff keywords: patch messages: 151765 nosy: docs at python, july priority: normal severity: normal status: open title: whatsnew/3.3 misspelling/mislink versions: Python 3.3 Added file: http://bugs.python.org/file24291/whatsnew-3.3-misspelling.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 11:11:42 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Sun, 22 Jan 2012 10:11:42 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327227102.74.0.949739739162.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Terry, I agree with you on having *i*th instead of *i*-th. The fact that "i" is written in italics eliminates the need of a hyphen. Justin, can I ask you to make a new patch which fixes "key-function" to "key function" and *i*'th to *i*th This is the last decision. Also, if anyone of you can, please then just incorporate that final patch that Justin will make. Thanks. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 11:22:01 2012 From: report at bugs.python.org (Stefan Krah) Date: Sun, 22 Jan 2012 10:22:01 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327227721.84.0.231542669654.issue13816@psf.upfronthosting.co.za> Stefan Krah added the comment: > This is the last decision. Also, if anyone of you can, please then just > incorporate that final patch that Justin will make. Thanks. Stop acting like a manager. A while ago a person had his account disabled for constantly bumping up issues and telling other people what to do. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 11:39:21 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Sun, 22 Jan 2012 10:39:21 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327228761.25.0.0102515940117.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Yeah,?I?guess?I?was?kind?of?rude.?Sorry?about?that.?I?think?my?proposal?is?acceptable.?What?do?you?think? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 12:19:23 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 22 Jan 2012 11:19:23 +0000 Subject: [docs] [issue13835] whatsnew/3.3 misspelling/mislink In-Reply-To: <1327226626.95.0.153685106815.issue13835@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 8a38bbf92048 by Sandro Tosi in branch 'default': Issue #13835: fixes to What's new 3.3; patch by July Tikhonov http://hg.python.org/cpython/rev/8a38bbf92048 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 12:19:53 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 22 Jan 2012 11:19:53 +0000 Subject: [docs] [issue13835] whatsnew/3.3 misspelling/mislink In-Reply-To: <1327226626.95.0.153685106815.issue13835@psf.upfronthosting.co.za> Message-ID: <1327231193.39.0.204446472017.issue13835@psf.upfronthosting.co.za> Sandro Tosi added the comment: Thanks July, I've just committed your patches! ---------- nosy: +sandro.tosi resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 14:17:18 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sun, 22 Jan 2012 13:17:18 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327238238.8.0.0314095003203.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: ?ric, are you still planning to work on this? Otherwise I'll make a first pass at doing the split into 3 sections (as per my earlier comment) and implementing some of Terry's suggestions. Linked Hg repo is a 2.7 based feature branch where I'll be publishing my changes as I make them. ---------- hgrepos: +106 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 15:25:39 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Sun, 22 Jan 2012 14:25:39 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327242339.2.0.469844130566.issue13816@psf.upfronthosting.co.za> Terry J. Reedy added the comment: Justin, if you do a new patch, put both changes in one .diff. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 16:33:10 2012 From: report at bugs.python.org (Ezio Melotti) Date: Sun, 22 Jan 2012 15:33:10 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327246390.06.0.421151799401.issue4966@psf.upfronthosting.co.za> Ezio Melotti added the comment: ?ric is without Internet till the end of the month, so I think it's OK if you go ahead and start working on this. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 16:51:35 2012 From: report at bugs.python.org (Meador Inge) Date: Sun, 22 Jan 2012 15:51:35 +0000 Subject: [docs] [issue13814] Document why generators don't support the context management protocol In-Reply-To: <1326883396.25.0.884733470267.issue13814@psf.upfronthosting.co.za> Message-ID: <1327247495.61.0.0391965280308.issue13814@psf.upfronthosting.co.za> Changes by Meador Inge : ---------- nosy: +meador.inge _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 20:49:39 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Sun, 22 Jan 2012 19:49:39 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327261779.79.0.573736404464.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: I fixed Justin's patch. Anyone cares to incorporate it? ---------- Added file: http://bugs.python.org/file24293/fixed patch final.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 21:24:50 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 22 Jan 2012 20:24:50 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327263890.28.0.862699539561.issue13816@psf.upfronthosting.co.za> Georg Brandl added the comment: Sorry, but the patch introduces two markup errors: - *i*th is invalid reST, it needs to be *i*\ th - you broke the table markup (the vertical lines must be aligned) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 21:31:48 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 22 Jan 2012 20:31:48 +0000 Subject: [docs] [issue13834] In help(bytes.strip) there is no info about leading ASCII whitespace In-Reply-To: <1327119429.45.0.897722607985.issue13834@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 960d93deb8c2 by Georg Brandl in branch '3.2': Fix #13834: strip() strips leading and trailing whitespace. http://hg.python.org/cpython/rev/960d93deb8c2 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 22 21:32:03 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 22 Jan 2012 20:32:03 +0000 Subject: [docs] [issue13834] In help(bytes.strip) there is no info about leading ASCII whitespace In-Reply-To: <1327119429.45.0.897722607985.issue13834@psf.upfronthosting.co.za> Message-ID: <1327264323.32.0.547252098153.issue13834@psf.upfronthosting.co.za> Georg Brandl added the comment: Fixed, thanks! ---------- nosy: +georg.brandl resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 08:58:50 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 23 Jan 2012 07:58:50 +0000 Subject: [docs] [issue13840] create_string_buffer rejects str init_or_size parameter In-Reply-To: <1327305188.04.0.956774664708.issue13840@psf.upfronthosting.co.za> Message-ID: <1327305530.67.0.110373507683.issue13840@psf.upfronthosting.co.za> Georg Brandl added the comment: It should only take bytes; "str" is Unicode in 3.x. So the docs and the error message are wrong, the behavior is correct. Reclassifying as a docs issue. ---------- assignee: -> docs at python components: +Documentation -ctypes nosy: +docs at python, georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 09:27:50 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 23 Jan 2012 08:27:50 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327307270.36.0.256054191742.issue4966@psf.upfronthosting.co.za> Georg Brandl added the comment: +1 for splitting. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 10:28:59 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Mon, 23 Jan 2012 09:28:59 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327310939.36.0.175388989146.issue4966@psf.upfronthosting.co.za> Raymond Hettinger added the comment: +1 for Nick's suggested breakout: 4.6 Sequence Types - list, tuple, range 4.7 Text Sequence Type - str 4.8 Binary Data Sequence Types - bytes, bytearray, memoryview ---------- nosy: +rhettinger _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 12:20:09 2012 From: report at bugs.python.org (Vincent Pelletier) Date: Mon, 23 Jan 2012 11:20:09 +0000 Subject: [docs] [issue13840] create_string_buffer rejects str init_or_size parameter In-Reply-To: <1327305188.04.0.956774664708.issue13840@psf.upfronthosting.co.za> Message-ID: <1327317609.57.0.95906574741.issue13840@psf.upfronthosting.co.za> Vincent Pelletier added the comment: Thanks for the quick reply. FWIW, in 2.7 doc ctype.create_string_buffer is said to accept unicode objects as parameter. I don't use this personally, so I don't mind 3.x only working on bytes - and already fixed my code accordingly. It's just that I noticed this after your answer. Also, I didn't try to confirm if it actually works. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 12:38:03 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 11:38:03 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327318683.03.0.00960515143404.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Georg,?thanks?for?the?tip.?Is?there?any?difference?in?reST?between?*i*\ th?and?*i*\th?? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 12:48:35 2012 From: report at bugs.python.org (Ezio Melotti) Date: Mon, 23 Jan 2012 11:48:35 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327319315.65.0.567715535191.issue13816@psf.upfronthosting.co.za> Ezio Melotti added the comment: You can check on the devguide the section about building the doc and see it yourself on the generated HTML. While building you will also see all the warnings caused by invalid markup. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 15:02:12 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 14:02:12 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327327332.28.0.333190653531.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: I?hope?the?patch?is?now?good.?What?do?you?think? ---------- Added file: http://bugs.python.org/file24296/done?deal.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 15:26:53 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 14:26:53 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327328813.16.0.598727660248.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Ah, darn it! My last patch is a total garbage. But then an interesting thing happened: I wanted to delete my last patch set, but I got a "ProgrammingError at /review/13816/patchset/4039/delete schema "datetime" does not exist" and got all the Django nitty-gritty info about your server. This is not good because someone can misuse that information. Please fix this. You have "DEBUG = True" set and so all the details of your server is leaked. Better change that to "DEBUG = False" and let the user get a standard 500 error page instead. It says at the bottom: "You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 500 page." ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 15:36:10 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 14:36:10 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327329369.24.0.206162781663.issue13816@psf.upfronthosting.co.za> Changes by Bo?tjan Mejak : Removed file: http://bugs.python.org/file24296/done?deal.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 15:36:31 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 14:36:31 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327329391.25.0.913079566889.issue13816@psf.upfronthosting.co.za> Changes by Bo?tjan Mejak : Removed file: http://bugs.python.org/file24293/fixed patch final.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 15:46:52 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 14:46:52 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327330012.01.0.382549785739.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: I wasn't able to remove the patch via "Delete Patch Set" but I did it by clicking on the Unlink button. So the "Delete Patch Set" option has a bug. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 16:02:14 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 15:02:14 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327330934.07.0.927447504257.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: Georg, I object to your comment about *i*th needing to be *i*\ th because currently in the source code we have it written as *i*'th which, by your logic, would need to be written as *i*\ 'th which is not so and is compiled/displayed/whatever perfectly as is, so *i*th would be compiled/displayed/whatever, too. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 16:25:16 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 23 Jan 2012 15:25:16 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327332316.9.0.786321425002.issue13816@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: This stupid HG is so cryptic. SVN was so easy, now I can't even create a patch. Can you just fix those two typos as "key function" and "*i*th" please? Thank you. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 16:27:57 2012 From: report at bugs.python.org (Stefan Krah) Date: Mon, 23 Jan 2012 15:27:57 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327332477.02.0.203291569017.issue13816@psf.upfronthosting.co.za> Changes by Stefan Krah : ---------- nosy: -skrah _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 18:23:03 2012 From: report at bugs.python.org (Justin Wehnes) Date: Mon, 23 Jan 2012 17:23:03 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327339383.51.0.965308244556.issue13816@psf.upfronthosting.co.za> Justin Wehnes added the comment: Fixed. ---------- Added file: http://bugs.python.org/file24302/issue13816.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 20:21:49 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 23 Jan 2012 19:21:49 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327346509.32.0.0536309002105.issue13816@psf.upfronthosting.co.za> Georg Brandl added the comment: 1. Please report issues with the tracker to the meta-tracker at http://psf.upfronthosting.co.za/roundup/meta/. 2. You may object all you want, *i*th is invalid reST and a very quick tryout with "rst2html" would have shown you that. 3. Lastly, it is usual to test patches before submitting. Had you tried to build your changed docs instead of complaining here, you might have been enlightened. Justin: thanks for the patch. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 20:21:54 2012 From: report at bugs.python.org (Roundup Robot) Date: Mon, 23 Jan 2012 19:21:54 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset a72ca8b23cdf by Georg Brandl in branch '3.2': #13816: fix two minor style issues. Thanks to Justin Wehnes for the patch. http://hg.python.org/cpython/rev/a72ca8b23cdf New changeset f4f9ab2fd51b by Georg Brandl in branch '2.7': #13816: fix two minor style issues. Thanks to Justin Wehnes for the patch. http://hg.python.org/cpython/rev/f4f9ab2fd51b ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 23 22:12:49 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 23 Jan 2012 21:12:49 +0000 Subject: [docs] [issue13816] Two typos in the docs In-Reply-To: <1326903795.6.0.0593092042228.issue13816@psf.upfronthosting.co.za> Message-ID: <1327353169.01.0.967153876452.issue13816@psf.upfronthosting.co.za> Changes by Georg Brandl : ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 06:54:58 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 24 Jan 2012 05:54:58 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options Message-ID: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> New submission from Nick Coghlan : With the current argparse docs, it's very hard to get a quick reminder of how to spell the various parameters for add_argument, and just what they do. This issue suggests adding a "Quick Reference" section for add_argument, with the following elements: 1. Summary table with a one line description of each parameter 2. Summary table with a one line description of each alternative for the "action" parameter (including noting which other parameters are potentially relevant, such as 'choices' and 'metavar' for 'store' and 'const' for 'store_const') 3. Summary table with a one line description of each alternative for the "nargs" parameter ---------- assignee: docs at python components: Documentation messages: 151880 nosy: bethard, docs at python, ncoghlan priority: normal severity: normal status: open title: Summary tables for argparse add_argument options versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 07:10:00 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 24 Jan 2012 06:10:00 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327385400.21.0.657988483274.issue13850@psf.upfronthosting.co.za> Nick Coghlan added the comment: Looking at the docs, a 4th table in the quick reference section would be useful: the parameters for ArgumentParser itself. Note that the ArgumentParser and add_arguments() parameters are already summarised in their respective entries, but there are currently no summaries at all for the possible "action" and "nargs" values ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 11:00:24 2012 From: report at bugs.python.org (Xavier Morel) Date: Tue, 24 Jan 2012 10:00:24 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327399224.62.0.973812508967.issue13850@psf.upfronthosting.co.za> Xavier Morel added the comment: Creating the tables should not be too hard, especially using e.g. org-mode, but: 1. Where should those tables live? The argparse documentation is pretty big and there's no completely obvious place. I would guess table 1. could just replace the list of arguments in http://docs.python.org/py3k/library/argparse.html#the-add-argument-method but things are harder for `action` (as many actions have examples as well, so the listing can't just be replaced) and for `nargs` 2. If the current lists of `argument: role` (in ArgumentParser and add_argument) are not sufficient, why would a table somehow be considering it would *add* visual clutter (table borders, for instance)? Maybe a good alternative would be to build a table style for info fields lists and to use :param: wherever that belongs? Or the doc could be split into a "quickstart" with just a listing of arguments and a *very simple* example or two, and then the exhaustive documentation, which could even be a separate document? ---------- nosy: +xmorel _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 11:40:13 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 24 Jan 2012 10:40:13 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327401613.65.0.84994526555.issue13850@psf.upfronthosting.co.za> Nick Coghlan added the comment: My specific suggestion is to have a dedicated "Quick Reference" section before the first example. This section would be aimed at two groups of people: - those wanting a quick overview of the features argparse offers them ("This looks complicated, what can it do for me?") - those wanting a reminder of the exact spelling of various items ("I know what I want to do, and I know argparse can do it because I've done it before, but how do I tell argparse exactly what I want?") Since the heart of argparse is the ability to map arguments to actions, I'd suggest the quick reference section actually lead with a table of "actions" that argparse natively supports, along with a final entry pointing to the information on custom actions (i.e. subclasses of argparse.Action). Likely columns for this first table: Action Name, Description, Parameters The "Parameters" column would span multiple lines, with one parameter and a brief description of the parameter on each line. The second table could then just be a short summary of the various 'nargs' values. Repeating the list of parameters to ArgumentParser in the quick reference section probably isn't necessary, and the short parameter descriptions in the actions table should suffice for add_argument(). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 11:40:28 2012 From: report at bugs.python.org (Ezio Melotti) Date: Tue, 24 Jan 2012 10:40:28 +0000 Subject: [docs] [issue13686] Some notes on the docs of multiprocessing In-Reply-To: <1325307613.69.0.259805833126.issue13686@psf.upfronthosting.co.za> Message-ID: <1327401628.97.0.997950967417.issue13686@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- nosy: +ezio.melotti _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 11:40:44 2012 From: report at bugs.python.org (Ezio Melotti) Date: Tue, 24 Jan 2012 10:40:44 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327401644.3.0.613363532527.issue13850@psf.upfronthosting.co.za> Changes by Ezio Melotti : ---------- nosy: +ezio.melotti _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 11:56:28 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 24 Jan 2012 10:56:28 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327402588.29.0.0202685255231.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: I realised that the lack of a clear binary/text distinction would make it messy to do the split docs in 2.7, so I made a new branch based on 3.2 instead (link to repo updated accordingly). ---------- assignee: eric.araujo -> ncoghlan _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 12:42:55 2012 From: report at bugs.python.org (Xavier Morel) Date: Tue, 24 Jan 2012 11:42:55 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327405375.82.0.629987577583.issue13850@psf.upfronthosting.co.za> Xavier Morel added the comment: > My specific suggestion is to have a dedicated "Quick Reference" section before the first example. OK, that looks like a good plan. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 14:14:45 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Tue, 24 Jan 2012 13:14:45 +0000 Subject: [docs] [issue13852] Doc fixes with patch Message-ID: <1327410885.19.0.883089570823.issue13852@psf.upfronthosting.co.za> New submission from Bo?tjan Mejak : I have collected a small amount of documentation fixes in my patch. Please review it and apply it. No pressure. ;) ---------- assignee: docs at python components: Documentation files: changes.diff keywords: patch messages: 151900 nosy: Retro, docs at python priority: normal severity: normal status: open title: Doc fixes with patch type: enhancement versions: Python 2.7, Python 3.2, Python 3.3 Added file: http://bugs.python.org/file24313/changes.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 14:30:23 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 24 Jan 2012 13:30:23 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327411822.65.0.388159491842.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: Pushed an initial cut to my sandbox branch. Built HTML is attached so you can get a general idea of how it looks (links, etc, obviously won't work). So far, I have made the split into 3 sections and updated the new (shorter) Sequence Types section. That section now has 6 subsections: - Common Sequence Operations - Immutable Sequence Operations (very short, just mentions hash support) - Mutable Sequence Operations - Lists - Tuples - Ranges I haven't really touched the Text and Binary sections as yet - the only changes there are things that I copied down before removing them from the updated Sequence Types section. ---------- Added file: http://bugs.python.org/file24314/stdtypes.html _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 15:09:08 2012 From: report at bugs.python.org (Nick Coghlan) Date: Tue, 24 Jan 2012 14:09:08 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327414148.15.0.471726090459.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: Note: without the Python docs CSS to create the sidebar, the internal table of contents appears at the *bottom* of the rendered page. Really, reviewing this sensibly is probably going to require building the docs locally after using hg pull to retrieve the changes from my sandbox. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 18:12:09 2012 From: report at bugs.python.org (Steven Bethard) Date: Tue, 24 Jan 2012 17:12:09 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327425129.11.0.665927340177.issue13850@psf.upfronthosting.co.za> Steven Bethard added the comment: Sounds like an excellent plan to me too. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 19:44:49 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Tue, 24 Jan 2012 18:44:49 +0000 Subject: [docs] [issue13852] Doc fixes with patch In-Reply-To: <1327410885.19.0.883089570823.issue13852@psf.upfronthosting.co.za> Message-ID: <1327430689.25.0.957884340492.issue13852@psf.upfronthosting.co.za> Changes by Bo?tjan Mejak : ---------- nosy: +ezio.melotti _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 20:23:15 2012 From: report at bugs.python.org (Meador Inge) Date: Tue, 24 Jan 2012 19:23:15 +0000 Subject: [docs] [issue13840] create_string_buffer rejects str init_or_size parameter In-Reply-To: <1327305188.04.0.956774664708.issue13840@psf.upfronthosting.co.za> Message-ID: <1327432995.5.0.659801014307.issue13840@psf.upfronthosting.co.za> Changes by Meador Inge : ---------- nosy: +meador.inge _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 24 21:20:57 2012 From: report at bugs.python.org (Xavier Morel) Date: Tue, 24 Jan 2012 20:20:57 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327436456.97.0.540077296119.issue13850@psf.upfronthosting.co.za> Xavier Morel added the comment: > The "Parameters" column would span multiple lines, with one parameter and a brief description of the parameter on each line. I started looking into that, and it turns out that's more annoying than expected: a bunch of parameters are shared by many (to all) actions, leading to lots of duplications in the table. And the full matrix of actions to parameters is not really explained in the doc. In fact, I'm coming around to thinking a matrix of the interaction between actions and arguments could be better and clearer than a table of actions with parameters bunched together at the end. In any case, it would certainly be more maintainable... except for rST not really having support for attributes on data tables, and (as far as I can tell) can't handle horizontal headers. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 25 02:18:35 2012 From: report at bugs.python.org (Nick Coghlan) Date: Wed, 25 Jan 2012 01:18:35 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327454314.95.0.637234082115.issue13850@psf.upfronthosting.co.za> Nick Coghlan added the comment: Having a second table of "Applicable Parameters" could definitely work. I don't think the "no horizontal headers" limitation should be a big problem - the matrix should be readable even if the action names are just listed in an ordinary column. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 25 03:20:04 2012 From: report at bugs.python.org (Raymond Hettinger) Date: Wed, 25 Jan 2012 02:20:04 +0000 Subject: [docs] [issue13850] Summary tables for argparse add_argument options In-Reply-To: <1327384498.23.0.981832544617.issue13850@psf.upfronthosting.co.za> Message-ID: <1327458004.63.0.0268207277581.issue13850@psf.upfronthosting.co.za> Raymond Hettinger added the comment: +1 from me. The docs in their present form are a great tutorial but are a total failure as a quick reference. Besides having table of parameters, it may also be worthwhile to move some of the examples to a HOWTO document (much as was done with the logging package). ---------- nosy: +rhettinger _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 25 04:14:26 2012 From: report at bugs.python.org (Meador Inge) Date: Wed, 25 Jan 2012 03:14:26 +0000 Subject: [docs] [issue13840] create_string_buffer rejects str init_or_size parameter In-Reply-To: <1327305188.04.0.956774664708.issue13840@psf.upfronthosting.co.za> Message-ID: <1327461266.32.0.943331805695.issue13840@psf.upfronthosting.co.za> Meador Inge added the comment: The 'create_unicode_buffer' docs are currently wrong too: """ If the first parameter is a bytes object, it is converted into an unicode string according to ctypes conversion rules. """ >>> ctypes.create_unicode_buffer(b'foo') Traceback (most recent call last): File "", line 1, in File "/home/meadori/src/python/cpython/Lib/ctypes/__init__.py", line 294, in create_unicode_buffer buf.value = init TypeError: unicode string expected instead of bytes instance The attached patch fixes the documentation and exception messages. Although, it might be more friendly to implement things according to the current docs (i.e. do the conversions). ---------- components: +ctypes keywords: +patch stage: -> patch review versions: +Python 3.3 Added file: http://bugs.python.org/file24319/issue13840.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 25 10:27:08 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Wed, 25 Jan 2012 09:27:08 +0000 Subject: [docs] [issue13852] Doc fixes with patch In-Reply-To: <1327410885.19.0.883089570823.issue13852@psf.upfronthosting.co.za> Message-ID: <1327483628.19.0.141176894798.issue13852@psf.upfronthosting.co.za> Changes by Bo?tjan Mejak : ---------- nosy: +terry.reedy _______________________________________ Python tracker _______________________________________ From bill.king at nokia.com Wed Jan 25 15:42:16 2012 From: bill.king at nokia.com (bill.king at nokia.com) Date: Wed, 25 Jan 2012 14:42:16 +0000 Subject: [docs] Bug in platform.system() documentation Message-ID: <611E5C76F442624ABF92C1CBE36A64C3013DC5CA@008-AM1MPN1-051.mgdnok.nokia.com> platform.system() Returns the system/OS name, e.g. 'Linux', 'Windows', or 'Java'. I don't think that's right... -- ??? Bill King ??? Lead Test Engineer ??? Nokia, Qt Creator team ??? http://qt.nokia.com From danielsh at elego.de Tue Jan 24 12:46:51 2012 From: danielsh at elego.de (Daniel Shahaf) Date: Tue, 24 Jan 2012 13:46:51 +0200 Subject: [docs] integer leak in refcount docs? Message-ID: <20120124114633.GA22041@daniel3.local> In , the example code reads: 1 int 2 set_all(PyObject *target, PyObject *item) 3 { 4 int i, n; 5 6 n = PyObject_Length(target); 7 if (n < 0) 8 return -1; 9 for (i = 0; i < n; i++) { 10 PyObject *index = PyInt_FromLong(i); 11 if (!index) 12 return -1; 13 if (PyObject_SetItem(target, index, item) < 0) 14 return -1; 15 Py_DECREF(index); 16 } 17 return 0; 18 } Seems to me that line 14 leaks a reference to 'index'; that is: @@ -13,2 +13,4 @@ - if (PyObject_SetItem(target, index, item) < 0) + if (PyObject_SetItem(target, index, item) < 0) { + Py_DECREF(index); return -1; + } Does that make sense? From eddy at opera.com Wed Jan 25 11:29:16 2012 From: eddy at opera.com (Edward Welbourne) Date: Wed, 25 Jan 2012 11:29:16 +0100 Subject: [docs] String formatting: "%#17.5l%" % () Message-ID: Hi doc folks, I was checking on the format-specifier grammar: http://whorl/doc/python-doc/html/library/stdtypes.html#string-formatting and noticed that it allows flag, field width, precision and length modifier in a %% format specifier. I was about to report this as a bug (as I expected the same rule ANSI C '89 imposed - for the % specifier, the whole format specifier must be just %%, with no extras) but checked in a python session: >>> '%#17.5l%' '%#17.5l%' >>> '%#17.5l% %s' % 'hello' ' % hello' >>> '%#17.5l%' % () ' %' >>> '%#*.*l%' % (17, 5) ' %' I am duly amused. It occurred to me that others might be, too ;-) Eddy. From report at bugs.python.org Wed Jan 25 22:05:12 2012 From: report at bugs.python.org (Miki Tebeka) Date: Wed, 25 Jan 2012 21:05:12 +0000 Subject: [docs] [issue13865] distutils documentation says Extension has "optional" argument In-Reply-To: <1327525493.46.0.373823292504.issue13865@psf.upfronthosting.co.za> Message-ID: <1327525512.89.0.972223788935.issue13865@psf.upfronthosting.co.za> Changes by Miki Tebeka : ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python versions: +Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 25 22:36:54 2012 From: report at bugs.python.org (Roundup Robot) Date: Wed, 25 Jan 2012 21:36:54 +0000 Subject: [docs] [issue13852] Doc fixes with patch In-Reply-To: <1327410885.19.0.883089570823.issue13852@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset e2b98a332070 by Georg Brandl in branch '2.7': #13852: some small doc fixes. http://hg.python.org/cpython/rev/e2b98a332070 New changeset 5b8800012e88 by Georg Brandl in branch '3.2': #13852: some small doc fixes. http://hg.python.org/cpython/rev/5b8800012e88 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Wed Jan 25 22:37:08 2012 From: report at bugs.python.org (Georg Brandl) Date: Wed, 25 Jan 2012 21:37:08 +0000 Subject: [docs] [issue13852] Doc fixes with patch In-Reply-To: <1327410885.19.0.883089570823.issue13852@psf.upfronthosting.co.za> Message-ID: <1327527427.97.0.474186960246.issue13852@psf.upfronthosting.co.za> Georg Brandl added the comment: Done. Thanks! ---------- nosy: +georg.brandl resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 00:01:16 2012 From: report at bugs.python.org (Jim Jewett) Date: Wed, 25 Jan 2012 23:01:16 +0000 Subject: [docs] [issue13867] misleading comment in weakrefobject.h Message-ID: <1327532476.25.0.872465463087.issue13867@psf.upfronthosting.co.za> New submission from Jim Jewett : http://hg.python.org/cpython/file/fec45282dc28/Include/weakrefobject.h#l54 The comment makes sense -- but doesn't appear to be true, so perhaps it is the macro that should change. /* This macro calls PyWeakref_CheckRef() last since that can involve a function call; this makes it more likely that the function call will be avoided. */ #define PyWeakref_Check(op) \ (PyWeakref_CheckRef(op) || PyWeakref_CheckProxy(op)) ---------- assignee: docs at python components: Documentation, Extension Modules messages: 151983 nosy: Jim.Jewett, docs at python priority: normal severity: normal status: open title: misleading comment in weakrefobject.h _______________________________________ Python tracker _______________________________________ From sandro.tosi at gmail.com Thu Jan 26 00:15:02 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Thu, 26 Jan 2012 00:15:02 +0100 Subject: [docs] Bug in platform.system() documentation In-Reply-To: <611E5C76F442624ABF92C1CBE36A64C3013DC5CA@008-AM1MPN1-051.mgdnok.nokia.com> References: <611E5C76F442624ABF92C1CBE36A64C3013DC5CA@008-AM1MPN1-051.mgdnok.nokia.com> Message-ID: Hello Bill, On Wed, Jan 25, 2012 at 15:42, wrote: > platform.system() > Returns the system/OS name, e.g. 'Linux', 'Windows', or 'Java'. > > I don't think that's right... Could you please try to be a bit more verbose and explain what do you think that's wrong, and what's the description you'd expect? Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Thu Jan 26 00:58:11 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Wed, 25 Jan 2012 23:58:11 +0000 Subject: [docs] [issue13868] Add hyphen doc fix Message-ID: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> New submission from Bo?tjan Mejak : When you have time, incorporate this patch. Thanks. ---------- assignee: docs at python components: Documentation files: smallfix.diff keywords: patch messages: 151985 nosy: Retro, docs at python priority: normal severity: normal status: open title: Add hyphen doc fix type: enhancement versions: Python 2.7, Python 3.2, Python 3.3 Added file: http://bugs.python.org/file24325/smallfix.diff _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 13:41:47 2012 From: report at bugs.python.org (Ezio Melotti) Date: Thu, 26 Jan 2012 12:41:47 +0000 Subject: [docs] [issue13435] Copybutton does not hide tracebacks In-Reply-To: <1321724543.66.0.854276029391.issue13435@psf.upfronthosting.co.za> Message-ID: <1327581706.89.0.546150256088.issue13435@psf.upfronthosting.co.za> Ezio Melotti added the comment: This should be fixed now. ---------- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 14:05:18 2012 From: report at bugs.python.org (Nadeem Vawda) Date: Thu, 26 Jan 2012 13:05:18 +0000 Subject: [docs] [issue5784] raw deflate format and zlib module In-Reply-To: <1240006221.86.0.263428051867.issue5784@psf.upfronthosting.co.za> Message-ID: <1327583118.11.0.0218113130929.issue5784@psf.upfronthosting.co.za> Changes by Nadeem Vawda : ---------- nosy: +nadeem.vawda _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 15:27:57 2012 From: report at bugs.python.org (anatoly techtonik) Date: Thu, 26 Jan 2012 14:27:57 +0000 Subject: [docs] [issue13875] cmd: no user documentation Message-ID: <1327588077.77.0.0954132482021.issue13875@psf.upfronthosting.co.za> New submission from anatoly techtonik : http://docs.python.org/library/cmd.html# Documentation for cmd module is poor to explain the value of this module to users. Intro is too abstract - phrase "simple framework for writing line-oriented command interpreters" doesn't mean much. Perhaps word "interactive" is missing? So, there is no part explaining the what cmd does exactly (intro fails) and no part explaining the main principle - How exactly does this framework allows to do this in a simple way? (I guess reference part under 'Cmd objects -> Cmd.cmdloop([intro]) -> p[4]` does that, but it is not the place you'd usually expect this info. At the very least what could be done is a link to Doug's tutorial http://www.doughellmann.com/PyMOTW/cmd/ ---------- assignee: docs at python components: Documentation messages: 152010 nosy: docs at python, techtonik priority: normal severity: normal status: open title: cmd: no user documentation _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 15:37:52 2012 From: report at bugs.python.org (R. David Murray) Date: Thu, 26 Jan 2012 14:37:52 +0000 Subject: [docs] [issue13875] cmd: no user documentation In-Reply-To: <1327588077.77.0.0954132482021.issue13875@psf.upfronthosting.co.za> Message-ID: <1327588672.51.0.23541383654.issue13875@psf.upfronthosting.co.za> R. David Murray added the comment: Well, since it isn't limited to interactive use, I don't think 'interactive' is missing. MOTW links are a more global issue that was discussion on python-dev (I forget the outcome, but I think it was "no"). I don't see anything that needs done here, but if you want to suggest a patch for consideration, feel free. ---------- nosy: +r.david.murray priority: normal -> low resolution: -> works for me status: open -> pending _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 15:40:44 2012 From: report at bugs.python.org (anatoly techtonik) Date: Thu, 26 Jan 2012 14:40:44 +0000 Subject: [docs] [issue13875] cmd: no user documentation In-Reply-To: <1327588077.77.0.0954132482021.issue13875@psf.upfronthosting.co.za> Message-ID: <1327588844.11.0.975778504111.issue13875@psf.upfronthosting.co.za> anatoly techtonik added the comment: What do you mean by saying it is not limited for interactive use? I thought it is used to provide command prompt for typing commands. What other use cases does it support? ---------- status: pending -> open _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 15:49:36 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 26 Jan 2012 14:49:36 +0000 Subject: [docs] [issue13840] create_string_buffer rejects str init_or_size parameter In-Reply-To: <1327305188.04.0.956774664708.issue13840@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset be9d02536a81 by Meador Inge in branch '3.2': - Issue #13840: Fix ctypes.create_string_buffer exception message and docs. http://hg.python.org/cpython/rev/be9d02536a81 New changeset 52f68c95e025 by Meador Inge in branch 'default': - Issue #13840: Fix ctypes.create_string_buffer exception message and docs. http://hg.python.org/cpython/rev/52f68c95e025 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 15:50:55 2012 From: report at bugs.python.org (Meador Inge) Date: Thu, 26 Jan 2012 14:50:55 +0000 Subject: [docs] [issue13840] create_string_buffer rejects str init_or_size parameter In-Reply-To: <1327305188.04.0.956774664708.issue13840@psf.upfronthosting.co.za> Message-ID: <1327589455.45.0.54283163018.issue13840@psf.upfronthosting.co.za> Meador Inge added the comment: I just fixed the docs and error message for now. I might revisit the ASCII decoding later. Thanks for the bug report Vincent. ---------- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 16:15:39 2012 From: report at bugs.python.org (R. David Murray) Date: Thu, 26 Jan 2012 15:15:39 +0000 Subject: [docs] [issue13875] cmd: no user documentation In-Reply-To: <1327588077.77.0.0954132482021.issue13875@psf.upfronthosting.co.za> Message-ID: <1327590939.66.0.234948217955.issue13875@psf.upfronthosting.co.za> R. David Murray added the comment: You can feed a cmd driven interface from stdin or via cmd.onecmd. However, I agree that the intended and primary use case is interactive. There wouldn't be much point in using cmd if the primary intent of your program wasn't interactive. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 22:18:20 2012 From: report at bugs.python.org (Brett Cannon) Date: Thu, 26 Jan 2012 21:18:20 +0000 Subject: [docs] [issue13883] PYTHONCASEOK docs mistakenly says it is limited to Windows Message-ID: <1327612700.31.0.384231885295.issue13883@psf.upfronthosting.co.za> New submission from Brett Cannon : The docs for PYTHONCASEOK say it is limited to Windows, but in actuality in Python 3.x it applies to both Windows (including cygwin) and OS X. On Python 2.7 it applies to those plus RISCOS OS/2. ---------- assignee: docs at python components: Documentation messages: 152034 nosy: brett.cannon, docs at python priority: normal severity: normal stage: needs patch status: open title: PYTHONCASEOK docs mistakenly says it is limited to Windows versions: Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Thu Jan 26 23:17:29 2012 From: report at bugs.python.org (Stephen Kelly) Date: Thu, 26 Jan 2012 22:17:29 +0000 Subject: [docs] [issue13666] datetime documentation typos In-Reply-To: <1324936913.94.0.649454454071.issue13666@psf.upfronthosting.co.za> Message-ID: <1327616249.19.0.408812843319.issue13666@psf.upfronthosting.co.za> Stephen Kelly added the comment: There are actually other bugs in the same code example: ... def __init__(self): # DST starts last Sunday in March ... d = datetime(dt.year, 4, 1) # ends last Sunday in October ... self.dston = d - timedelta(days=d.weekday() + 1) ... d = datetime(dt.year, 11, 1) ... self.dstoff = d - timedelta(days=d.weekday() + 1) where does dt come from? this fragment should be in the implementation of dst (in both the GMT1 and GMT2 classes. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 00:37:21 2012 From: report at bugs.python.org (Roundup Robot) Date: Thu, 26 Jan 2012 23:37:21 +0000 Subject: [docs] [issue13883] PYTHONCASEOK docs mistakenly says it is limited to Windows In-Reply-To: <1327612700.31.0.384231885295.issue13883@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 524795e8abe1 by Brett Cannon in branch '3.2': Issue #13883: Document all platforms PYTHONCASEOK works on. http://hg.python.org/cpython/rev/524795e8abe1 New changeset 0f00010c88f0 by Brett Cannon in branch 'default': Issue #13883: PYTHONCASEOK also works with OS X. http://hg.python.org/cpython/rev/0f00010c88f0 New changeset f18662285248 by Brett Cannon in branch '2.7': Issue #13883: Document all platforms PYTHONCASEOK works on. http://hg.python.org/cpython/rev/f18662285248 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 00:37:55 2012 From: report at bugs.python.org (Brett Cannon) Date: Thu, 26 Jan 2012 23:37:55 +0000 Subject: [docs] [issue13883] PYTHONCASEOK docs mistakenly says it is limited to Windows In-Reply-To: <1327612700.31.0.384231885295.issue13883@psf.upfronthosting.co.za> Message-ID: <1327621075.29.0.962280615318.issue13883@psf.upfronthosting.co.za> Changes by Brett Cannon : ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 13:18:29 2012 From: report at bugs.python.org (Mark Dickinson) Date: Fri, 27 Jan 2012 12:18:29 +0000 Subject: [docs] [issue13887] defaultdict.get does not default to initial default but None In-Reply-To: <1327661403.58.0.135329216168.issue13887@psf.upfronthosting.co.za> Message-ID: <1327666709.51.0.257074064544.issue13887@psf.upfronthosting.co.za> Mark Dickinson added the comment: It's certainly intentional behaviour: all the defaultdict does is provide a __missing__ method. And as explained in http://docs.python.org/library/stdtypes.html#mapping-types-dict "No other operations or methods invoke __missing__()." So it looks to me as though this issue should be either a doc issue, or a feature request for 3.3. Reclassifying as a doc issue. ---------- assignee: -> docs at python components: +Documentation -Extension Modules, Library (Lib) nosy: +docs at python, mark.dickinson versions: +Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 15:14:44 2012 From: report at bugs.python.org (Roundup Robot) Date: Fri, 27 Jan 2012 14:14:44 +0000 Subject: [docs] [issue13887] defaultdict.get does not default to initial default but None In-Reply-To: <1327661403.58.0.135329216168.issue13887@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 089a086252fc by Benjamin Peterson in branch '3.2': note that get() is not affected by default_factory (closes #13887) http://hg.python.org/cpython/rev/089a086252fc New changeset 26612ad451ad by Benjamin Peterson in branch 'default': merge heads (#13887) http://hg.python.org/cpython/rev/26612ad451ad New changeset b2db66bc8e7f by Benjamin Peterson in branch '2.7': note that get() is not affected by default_factory (closes #13887) http://hg.python.org/cpython/rev/b2db66bc8e7f ---------- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 15:20:20 2012 From: report at bugs.python.org (Nick Coghlan) Date: Fri, 27 Jan 2012 14:20:20 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327674020.3.0.0306924515888.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: Branch status update: - Text Sequence Types section updated to reflect the new structure - changed the prose that describes the relationship between printf-style formatting and the str.format method (deliberately removing the implication that the former is any real danger of disappearing - it's simply not practical for us to seriously contemplate killing it off) - in the top level index, I split the old "String Services" section into "Text Processing Services" and "Binary Data Services". The latter contains 'struct' and 'codecs', the former contains everthing else that used to be in String Services. The index pages for the two sections do cross-reference modules in the other section a bit (Text Processing includes a pointer directly to the codecs module, Binary Data includes pointers to both re and difflib). The real driver for this change was that "struct" has no place in a "String Services" section in Py3k. Since "codecs" could really have gone in either section, I mainly moved it to the binary section so that 'struct' wasn't the only module in there. Major remaining update is to the Binary Sequence Types section (since I haven't really reviewed that at all after rearranging things. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 15:33:47 2012 From: report at bugs.python.org (Nick Coghlan) Date: Fri, 27 Jan 2012 14:33:47 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327674827.58.0.530581465007.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: One other things the branch doesn't currently sort out is the official signature of count() and index(). In 3.2, for *all* of str, bytes, bytearray, tuple, list, range, the index() method takes the optional start:stop parameters. collections.Sequence.index(), OTOH, does not. count() splits the field more evenly: str, bytes, bytearray accept the extra parameters, but list, tuple, range and collections.Sequence only support counting values in the whole sequence. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 16:12:22 2012 From: report at bugs.python.org (Ezio Melotti) Date: Fri, 27 Jan 2012 15:12:22 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327677142.77.0.0961228400291.issue4966@psf.upfronthosting.co.za> Ezio Melotti added the comment: Have you considered/planned to rework a bit the beginning of the page too? (Technically the issue is about the Sequence types section, but the whole page could be improved.) IMHO the sections about Truth value testing, Boolean operations, and Comparison are out of place there, and True/False/None should be described instead. The idea is that a developer new to Python should be able to come to this page, take a look at the headers and figure out what the main types are (what you did so far is already a good step in the right direction). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 19:43:29 2012 From: report at bugs.python.org (Sandro Tosi) Date: Fri, 27 Jan 2012 18:43:29 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327689809.09.0.624789490127.issue13868@psf.upfronthosting.co.za> Sandro Tosi added the comment: There are a lot more occurrences of 'floating point' in our doc: are you going to fix them too? ---------- nosy: +sandro.tosi _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Fri Jan 27 20:34:16 2012 From: report at bugs.python.org (Mark Dickinson) Date: Fri, 27 Jan 2012 19:34:16 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327692856.27.0.651341871013.issue13868@psf.upfronthosting.co.za> Changes by Mark Dickinson : ---------- nosy: +mark.dickinson _______________________________________ Python tracker _______________________________________ From andreas.balogh at db.com Thu Jan 26 15:28:45 2012 From: andreas.balogh at db.com (Andreas Balogh) Date: Thu, 26 Jan 2012 15:28:45 +0100 Subject: [docs] documentation bug Message-ID: Classification: Public Hello, in http://docs.python.org/library/functions.html#property class C(object): def __init__(self): self._x = None @property def x(self): """I'm the 'x' property.""" return self._x @x.setter def x(self, value): self._x = value @x.deleter def x(self): del self._x should read correctly class C(object): def __init__(self): self._x = None @x.getter def x(self): """I'm the 'x' property.""" return self._x @x.setter def x(self, value): self._x = value @x.deleter def x(self): del self._x Regards, Andreas -- Informationen (einschlie?lich Pflichtangaben) zu einzelnen, innerhalb der EU t?tigen Gesellschaften und Zweigniederlassungen des Konzerns Deutsche Bank finden Sie unter http://www.deutsche-bank.de/de/content/pflichtangaben.htm. Diese E-Mail enth?lt vertrauliche und/ oder rechtlich gesch?tzte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrt?mlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist nicht gestattet. Please refer to http://www.db.com/en/content/eu_disclosures.htm for information (including mandatory corporate particulars) on selected Deutsche Bank branches and group companies registered or incorporated in the European Union. This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From report at bugs.python.org Sat Jan 28 00:36:27 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Fri, 27 Jan 2012 23:36:27 +0000 Subject: [docs] [issue13867] misleading comment in weakrefobject.h In-Reply-To: <1327532476.25.0.872465463087.issue13867@psf.upfronthosting.co.za> Message-ID: <1327707387.88.0.758482693557.issue13867@psf.upfronthosting.co.za> Changes by Terry J. Reedy : ---------- components: +Library (Lib) -Documentation, Extension Modules nosy: +fdrake, pitrou _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 28 00:39:53 2012 From: report at bugs.python.org (Antoine Pitrou) Date: Fri, 27 Jan 2012 23:39:53 +0000 Subject: [docs] [issue13867] misleading comment in weakrefobject.h In-Reply-To: <1327532476.25.0.872465463087.issue13867@psf.upfronthosting.co.za> Message-ID: <1327707593.12.0.542879376588.issue13867@psf.upfronthosting.co.za> Antoine Pitrou added the comment: Ha, good catch. The macro could be fixed, or the comment simply be dropped. ---------- versions: +Python 2.7, Python 3.2, Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 28 01:22:42 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sat, 28 Jan 2012 00:22:42 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327710162.55.0.177560790713.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: Yeah, the basic layout of this entire section has been in place for a *long* time (http://docs.python.org/release/1.4/lib/node4.html#SECTION00310000000000000000) Some aspects haven't really aged all that well, as people have made minimalist changes to document new features without necessarily stepping back to see if the overall structure still makes sense. However, rather than dumping one massive patch on python-checkins, I think it makes sense to try to tackle it by section (i.e. sequences + related changes for now, then look at mappings, sets, truth values, comparisons and numbers separately). One thing I do plan to do is a quick scan for places that reference into the sequence types section to see if they should be adjusted (e.g. see if there's some duplication in the language reference that could be reduced, or cross-references in the glossary to add or update) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sat Jan 28 11:05:09 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sat, 28 Jan 2012 10:05:09 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327745108.83.0.060515498675.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: One other point... the branch is actually now relative to default, not 3.2. While that was due to a merging mistake on my part, it also means I can legitimately ignore the narrow/wide build distinction in the section on strings. ---------- _______________________________________ Python tracker _______________________________________ From frans at southshield.net Sat Jan 28 04:01:00 2012 From: frans at southshield.net (=?ISO-8859-1?Q?Frans_van_Dunn=E9?=) Date: Fri, 27 Jan 2012 22:01:00 -0500 Subject: [docs] Please release documentation in epub format Message-ID: <4F2364EC.6040708@southshield.net> Hello, Thank you for all the work you have done. Would you consider releasing the documentation in epub format, or perhaps as one long HTML file so that it can be easily converted? I've tried but failed to get the html version as you offer it now converted to epub format because it consists of a myriad individual files. With best wishes, Frans. -- - - - - - - - - - - - - - - - Dr. Frans van Dunn? Tel: +31 70 891 9360 Email: frans at southshield.net http://southshield.net From sandro.tosi at gmail.com Sat Jan 28 11:51:44 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 28 Jan 2012 11:51:44 +0100 Subject: [docs] Please release documentation in epub format In-Reply-To: <4F2364EC.6040708@southshield.net> References: <4F2364EC.6040708@southshield.net> Message-ID: Hello Frans, On Sat, Jan 28, 2012 at 04:01, Frans van Dunn? wrote: > Would you consider releasing the documentation in epub format, We are already providing documentation in EPUB format, but only for the Python 3.2 documentation[1] and onward. This because it's considered a new feature so we didn't backport it to the other versions; it might be a reason for you to start using the Python 3 version :) [1] http://docs.python.org/py3k/download.html Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From report at bugs.python.org Sat Jan 28 13:05:03 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sat, 28 Jan 2012 12:05:03 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327752302.86.0.140716337992.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: I finished off the binary data section, so the first draft of the update is now complete in the bitbucket repo. ---------- _______________________________________ Python tracker _______________________________________ From koenig.yvan at sfr.fr Sat Jan 28 15:15:00 2012 From: koenig.yvan at sfr.fr (KOENIG Yvan) Date: Sat, 28 Jan 2012 15:15:00 +0100 Subject: [docs] Problem with uppercase Message-ID: <69BD6A1C-97E8-42DB-942C-745A35E7B089@sfr.fr> Hello While trying to build a handler to convert text into UPPERCASE, I discovered that Python, the version available in OSX 10.7.2 fail to convert the character ? into its well defined counterpart which is UNICODE $1E9E May we hope for such a simple enhancement ? Thanks in advance. Yvan KOENIG (VALLAURIS, France) samedi 28 janvier 2012 15:14:57 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 2012-01-28T15.13.10.jpg Type: image/jpg Size: 69353 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 2012-01-28T14.55.56.jpg Type: image/jpg Size: 121798 bytes Desc: not available URL: From sandro.tosi at gmail.com Sat Jan 28 18:20:35 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 28 Jan 2012 18:20:35 +0100 Subject: [docs] Problem with uppercase In-Reply-To: <69BD6A1C-97E8-42DB-942C-745A35E7B089@sfr.fr> References: <69BD6A1C-97E8-42DB-942C-745A35E7B089@sfr.fr> Message-ID: Hello Yvan, On Sat, Jan 28, 2012 at 15:15, KOENIG Yvan wrote: > Hello > > While trying to build a handler to convert text into UPPERCASE, I discovered > that Python, the version available in OSX 10.7.2 fail to convert the > character ? > > into its well defined counterpart which is UNICODE $1E9E > > > May we hope for such a simple enhancement ? This mailing list is about enhancement to the Python documentation, and your email doesn't fit into this category. I suggest to contact http://mail.python.org/mailman/listinfo/python-list about your problem. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From sandro.tosi at gmail.com Sat Jan 28 19:44:22 2012 From: sandro.tosi at gmail.com (Sandro Tosi) Date: Sat, 28 Jan 2012 19:44:22 +0100 Subject: [docs] documentation bug In-Reply-To: References: Message-ID: Hello Andreas, thanks for your email. On Thu, Jan 26, 2012 at 15:28, Andreas Balogh wrote: > ? ?@property > ? ?def x(self): > ? ? ? ?"""I'm the 'x' property.""" > ? ? ? ?return self._x ... > should read correctly ... > ? ?@x.getter > ? ?def x(self): > ? ? ? ?"""I'm the 'x' property.""" > ? ? ? ?return self._x I'm not exactly sure that the example is incorrect, the writer might have wanted to recall the property decorator of the example above instead of using the getter decorator. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi From georg at python.org Sat Jan 28 20:03:21 2012 From: georg at python.org (Georg Brandl) Date: Sat, 28 Jan 2012 20:03:21 +0100 Subject: [docs] documentation bug In-Reply-To: References: Message-ID: <4F244679.8040907@python.org> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 26.01.2012 15:28, schrieb Andreas Balogh: > > Classification: Public > > Hello, > > in http://docs.python.org/library/functions.html#property > > class C(object): def __init__(self): self._x = None > > @property def x(self): """I'm the 'x' property.""" return self._x > > @x.setter def x(self, value): self._x = value > > @x.deleter def x(self): del self._x > > should read correctly > > class C(object): def __init__(self): self._x = None > > * @x.getter* def x(self): """I'm the 'x' property.""" return self._x > > @x.setter def x(self, value): self._x = value > > @x.deleter def x(self): del self._x > > Regards, Andreas Hi Andreas, have you tried your suggestion? For me, it raises a NameError. cheers, Georg -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (GNU/Linux) iEYEARECAAYFAk8kRnkACgkQN9GcIYhpnLDibgCfeW8nPj3KONmkuF9R7Q5v/IPZ GBoAoKLRc1q8vwcRdv109gza68kfhwll =FIYB -----END PGP SIGNATURE----- From report at bugs.python.org Sun Jan 29 06:29:06 2012 From: report at bugs.python.org (Parker Phinney) Date: Sun, 29 Jan 2012 05:29:06 +0000 Subject: [docs] [issue13900] http://docs.python.org/library/email.parser.html#email.parser.Parser.parse Message-ID: <1327814946.36.0.63076470288.issue13900@psf.upfronthosting.co.za> Changes by Parker Phinney : ---------- assignee: docs at python components: Documentation nosy: Parker.Phinney, docs at python priority: normal severity: normal status: open title: http://docs.python.org/library/email.parser.html#email.parser.Parser.parse type: behavior _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 06:31:29 2012 From: report at bugs.python.org (Parker Phinney) Date: Sun, 29 Jan 2012 05:31:29 +0000 Subject: [docs] [issue13900] documentation page on email.parser contains self-referential non-definition of headersonly parameter Message-ID: <1327815089.31.0.591392873917.issue13900@psf.upfronthosting.co.za> New submission from Parker Phinney : to recreate: go here: http://docs.python.org/library/email.parser.html#email.parser.Parser.parse notice this line: "Optional headersonly is as with the parse() method." But that doesn't make sense, because this /is/ the parse() method! ---------- title: http://docs.python.org/library/email.parser.html#email.parser.Parser.parse -> documentation page on email.parser contains self-referential non-definition of headersonly parameter type: behavior -> _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 15:35:57 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 29 Jan 2012 14:35:57 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1327847757.59.0.900675021568.issue13899@psf.upfronthosting.co.za> Georg Brandl added the comment: r'[\w]' also matches word chars. I find that a very useful property, since you can easily build classes like '[\w.]' It's also impossible to change this without breaking lots of regexes. It's also explicitly documented, although IMO it's not clear it extends to \A and \Z, since it talks about "character classes". So this is a docs issue. ---------- assignee: -> docs at python components: +Documentation nosy: +docs at python, georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 15:38:59 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 29 Jan 2012 14:38:59 +0000 Subject: [docs] [issue13900] documentation page on email.parser contains self-referential non-definition of headersonly parameter In-Reply-To: <1327815089.31.0.591392873917.issue13900@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 0d5667171356 by Georg Brandl in branch '3.2': Fix #13900: resolve self-referential description of a parameter. http://hg.python.org/cpython/rev/0d5667171356 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 15:39:38 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 29 Jan 2012 14:39:38 +0000 Subject: [docs] [issue13900] documentation page on email.parser contains self-referential non-definition of headersonly parameter In-Reply-To: <1327815089.31.0.591392873917.issue13900@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 690d5978bd21 by Georg Brandl in branch '2.7': Fix #13900: resolve self-referential description of a parameter. http://hg.python.org/cpython/rev/690d5978bd21 ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 15:39:46 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 29 Jan 2012 14:39:46 +0000 Subject: [docs] [issue13900] documentation page on email.parser contains self-referential non-definition of headersonly parameter In-Reply-To: <1327815089.31.0.591392873917.issue13900@psf.upfronthosting.co.za> Message-ID: <1327847986.81.0.680013898777.issue13900@psf.upfronthosting.co.za> Georg Brandl added the comment: Should now be fixed. Thanks for the report. ---------- nosy: +georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 15:39:51 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 29 Jan 2012 14:39:51 +0000 Subject: [docs] [issue13900] documentation page on email.parser contains self-referential non-definition of headersonly parameter In-Reply-To: <1327815089.31.0.591392873917.issue13900@psf.upfronthosting.co.za> Message-ID: <1327847991.89.0.121398791379.issue13900@psf.upfronthosting.co.za> Changes by Georg Brandl : ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 16:32:27 2012 From: report at bugs.python.org (Ezio Melotti) Date: Sun, 29 Jan 2012 15:32:27 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1327851147.32.0.752780075223.issue13899@psf.upfronthosting.co.za> Ezio Melotti added the comment: [\w] should definitely work, but [\B] doesn't seem to match anything useful, and it just fails silently because it's neither equivalent to \B nor to [B]: >>> re.match(r'foo\B', 'foobar') # on a non-word-boundary -- matches fine <_sre.SRE_Match object at 0xb76dd3a0> >>> re.match(r'foo[B]', 'fooBar') # same as r'fooB' <_sre.SRE_Match object at 0xb76dd1e0> >>> re.match(r'foo[\B]', 'foobar') # not equivalent to \B >>> re.match(r'foo[\B]', 'fooBar') # not equivalent to [B] The same is true for \Z and \A: >>> re.match(r'foo\Z', 'foo') # end of the string -- matches fine <_sre.SRE_Match object at 0xb76dd3a0> >>> re.match(r'foo[Z]', 'fooZ') # same as r'fooZ' <_sre.SRE_Match object at 0xb76dd1e0> >>> re.match(r'foo[\Z]', 'foo') # not equivalent to \Z >>> re.match(r'foo[\Z]', 'fooZ') # not equivalent to [Z] >>> >>> re.match(r'\Afoo', 'foo') # beginning of the string -- matches fine <_sre.SRE_Match object at 0xb76dd1e0> >>> re.match(r'[A]foo', 'Afoo') # same as r'Afoo' <_sre.SRE_Match object at 0xb76dd3a0> >>> re.match(r'[\A]foo', 'foo') # not equivalent to \A >>> re.match(r'[\A]foo', 'Afoo') # not equivalent to [A] Inside [], \b switches from word boundary to backspace: >>> re.match(r'foo\b', 'foobar') # not on a word boundary -- no matches >>> re.match(r'foo\b', 'foo bar') # on a word boundary -- matches fine <_sre.SRE_Match object at 0xb74a4ec8> >>> re.match(r'foo[\b]', 'foo bar') # not equivalent to \b >>> re.match(r'foo[\b]', 'foo\bbar') # matches backspace <_sre.SRE_Match object at 0xb76dd3d8> >>> re.match(r'foo([\b])', 'foo\bbar').group(1) '\x08' Given that \b doesn't keep its word boundary meaning inside the [], \B (and \A and \Z) shouldn't keep it either (also because I can't see how having these inside [] would be of any use). On the other hand I'm not sure they should be equivalent to B, A, Z either. There are several escape sequences in the form \X (where X is an upper- or lower-case letter) that are not equivalent to X (\a\b\d\f\s\x\w\D\S\W...). Raising an error that says something like "I don't think [\A] does what you think it does, use [A] instead." might be a better option (and in case anyone is wondering about re.escape, I just checked and it doesn't escape letters). Even if this is technically backward incompatible, any string that has \A, \B, \Z inside [] can be considered buggy IMHO (unless someone can come up with a valid use case where they do something useful). ---------- assignee: docs at python -> _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 16:35:24 2012 From: report at bugs.python.org (Georg Brandl) Date: Sun, 29 Jan 2012 15:35:24 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1327851324.34.0.488004909159.issue13899@psf.upfronthosting.co.za> Georg Brandl added the comment: Interesting. That shifts the issue, since the current behavior is neither of the two that make sense. Then it would indeed make the most sense to raise in these cases. (I wonder what these patterns actually would match, but I have no time to look in the sre sources right now...) ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 16:43:53 2012 From: report at bugs.python.org (Roundup Robot) Date: Sun, 29 Jan 2012 15:43:53 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1251103521.34.0.917057608479.issue6774@psf.upfronthosting.co.za> Message-ID: Roundup Robot added the comment: New changeset 9be82f458b79 by Charles-Fran?ois Natali in branch 'default': Issue #6774: Back out c8b77efe8b56, which only brings confusion. http://hg.python.org/cpython/rev/9be82f458b79 ---------- nosy: +python-dev _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 16:44:56 2012 From: report at bugs.python.org (Ezio Melotti) Date: Sun, 29 Jan 2012 15:44:56 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327851896.51.0.955901588177.issue4966@psf.upfronthosting.co.za> Ezio Melotti added the comment: > One other point... the branch is actually now relative to default, not > 3.2. While that was due to a merging mistake on my part, it also means > I can legitimately ignore the narrow/wide build distinction in the > section on strings. So will this go on 3.3 only or are you planning to push it on 3.2(/2.7) too? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 16:46:01 2012 From: report at bugs.python.org (=?utf-8?q?Charles-Fran=C3=A7ois_Natali?=) Date: Sun, 29 Jan 2012 15:46:01 +0000 Subject: [docs] [issue6774] socket.shutdown documentation: on some platforms, closing one half closes the other half In-Reply-To: <1251103521.34.0.917057608479.issue6774@psf.upfronthosting.co.za> Message-ID: <1327851961.5.0.18746001407.issue6774@psf.upfronthosting.co.za> Charles-Fran?ois Natali added the comment: I've reverted the commit. ---------- resolution: -> rejected stage: -> committed/rejected status: open -> closed versions: +Python 3.3 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 20:58:52 2012 From: report at bugs.python.org (Catalin Iacob) Date: Sun, 29 Jan 2012 19:58:52 +0000 Subject: [docs] [issue13905] Built-in Types Comparisons should mention rich comparison methods Message-ID: <1327867132.3.0.913390477966.issue13905@psf.upfronthosting.co.za> New submission from Catalin Iacob : In 2.7 the Comparisons section of stdtypes.rst only talks about __cmp__ and never mentions the rich comparison methods: "Instances of a class normally compare as non-equal unless the class defines the __cmp__() method. Refer to Basic customization) for information on the use of this method to effect object comparisons." The first sentence is false, instances can also compare as equal if they define __eq__. And since __cmp__ is gone in Python3, I think the rich comparison methods should at least be mentioned, or even emphasized over __cmp__ to help people write more forward compatible code. ---------- assignee: docs at python components: Documentation messages: 152254 nosy: catalin.iacob, docs at python priority: normal severity: normal status: open title: Built-in Types Comparisons should mention rich comparison methods type: enhancement versions: Python 2.7 _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 21:01:57 2012 From: report at bugs.python.org (Catalin Iacob) Date: Sun, 29 Jan 2012 20:01:57 +0000 Subject: [docs] [issue13905] Built-in Types Comparisons should mention rich comparison methods In-Reply-To: <1327867132.3.0.913390477966.issue13905@psf.upfronthosting.co.za> Message-ID: <1327867317.28.0.417722515795.issue13905@psf.upfronthosting.co.za> Catalin Iacob added the comment: Here's my attempt at a patch. It mostly takes the text from the default branch and adds references to __cmp__. ---------- keywords: +patch Added file: http://bugs.python.org/file24361/issue13905v1.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 22:34:38 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Sun, 29 Jan 2012 21:34:38 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327872877.79.0.500263215451.issue13868@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: If "floating point" in a sentence is in a role of an adjective, then it must be written as "floating-point" (with a hyphen), otherwise not. Example: "The number 3.5 is a floating-point number." Please consult some English orthography book and start writing correct English. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 22:41:11 2012 From: report at bugs.python.org (John Machin) Date: Sun, 29 Jan 2012 21:41:11 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1327873271.27.0.428289539817.issue13899@psf.upfronthosting.co.za> John Machin added the comment: @Ezio: Comparison of the behaviour of \letter inside/outside character classes is irrelevant. The rules for inside can be expressed simply as: 1. Letters dDsSwW are special; they represent categories as documented, and do in fact have a similar meaning outside character classes. 2. Otherwise normal Python rules for backslash escapes in string literals should be followed. This means automatically that \a -> \x07, \A -> A, \b -> backspace, \B -> B, \z -> z and \Z -> Z. @Georg: No need to read the source, just read my initial posting: It's compiled as a zero-length matcher ("at") inside a character class ("in") i.e. a nonsense, then at runtime the illegality is deliberately ignored. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 22:50:46 2012 From: report at bugs.python.org (John Machin) Date: Sun, 29 Jan 2012 21:50:46 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1327873846.76.0.0931496471827.issue13899@psf.upfronthosting.co.za> John Machin added the comment: Whoops: "normal Python rules for backslash escapes" should have had a note "but revert to the C behaviour of stripping the \ from unrecognised escapes" which is what re appears to do in its own \ handling. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Sun Jan 29 23:55:28 2012 From: report at bugs.python.org (Nick Coghlan) Date: Sun, 29 Jan 2012 22:55:28 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327877728.01.0.820388568182.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: Trying to make this change in 2.7 would actually be a bit of a nightmare - how do you cleanly split documentation of the binary data and text processing sequence types when "str" is used for both? The change would be *mostly* feasible in 3.2 (that's why I started my branch from there), but there are still some sharp edges that go away in 3.3 (mainly the narrow/wide Unicode split). So unless anyone is really keen to see the update in 3.2, my current plan is to leave the maintenance versions alone and only update it for 3.3. Going that way also provides better opportunities for post-checkin feedback from folks that aren't set up to build the docs themselves (rebuilding the docs is fairly straightforward on *nix, but Terry tells me that using Windows complicates that process quite a bit). ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 00:32:24 2012 From: report at bugs.python.org (Sandro Tosi) Date: Sun, 29 Jan 2012 23:32:24 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327879944.41.0.908548650508.issue13868@psf.upfronthosting.co.za> Sandro Tosi added the comment: Wow.. do you really expect any positive outcome from you reply style? I'll pretend I didn't read your reply and let me rephrase my question like this: there are several occurrences of 'floating point' in python doc, are you going to fix all the ones that are wrong? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 07:44:38 2012 From: report at bugs.python.org (Terry J. Reedy) Date: Mon, 30 Jan 2012 06:44:38 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327905878.57.0.0470063957574.issue4966@psf.upfronthosting.co.za> Terry J. Reedy added the comment: I agree with 3.3 only. This might not be ready for 3.2.3 anyway, depending on how soon hash patch is ready, and if not, it becomes a somewhat moot point as new people should then download 3.3.0 instead of 3.2.4 next August. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 07:51:21 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 30 Jan 2012 06:51:21 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327906281.61.0.730714304485.issue4966@psf.upfronthosting.co.za> Georg Brandl added the comment: ISTM that not doing this will make maintenance harder. For 2.7 I agree that there is no clear boundary to make, but 3.2 should be split up as well to ease merging of updates. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 09:08:01 2012 From: report at bugs.python.org (Nick Coghlan) Date: Mon, 30 Jan 2012 08:08:01 +0000 Subject: [docs] [issue4966] Improving Lib Doc Sequence Types Section In-Reply-To: <1232149418.64.0.0450574767427.issue4966@psf.upfronthosting.co.za> Message-ID: <1327910881.06.0.805173780643.issue4966@psf.upfronthosting.co.za> Nick Coghlan added the comment: Good point, without doing the split in both, any doc merges in this section will be a nightmare. OK, with the caveat that the initial 3.2 version may gloss over some issues that no longer apply in 3.3 (specifically the narrow/wide split), I'll make a new branch in the sandbox so the changes will be once again based on 3.2. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 15:08:09 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 30 Jan 2012 14:08:09 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327932488.93.0.670096021775.issue13868@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: I?know?that?there?are?a?lot?of?non-hyphenated?occurences?of?"floating point"?in?Python?docs,?so?I?just?want to?raise?awareness?about?those occurences. Can?you fix?all?occurences?of?"floating?point"?(when?in a?role?of an?adjective)?to?"floating-point" throughout Python docs? As a matter of fact, everything that is an adjective is hyphenated if there are 2 words that form the adjective. Example: "This is built in." versus "This is a built-in method." ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 15:15:08 2012 From: report at bugs.python.org (Sandro Tosi) Date: Mon, 30 Jan 2012 14:15:08 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327932488.93.0.670096021775.issue13868@psf.upfronthosting.co.za> Message-ID: Sandro Tosi added the comment: On Mon, Jan 30, 2012 at 15:08, Bo?tjan Mejak wrote: > Can?you fix?all?occurences?of?"floating?point"?(when?in a?role?of an?adjective)?to?"floating-point" throughout Python docs? What I was asking is if *you* (since you care about the topic) would provide a patch fixing all that needs fixing. At that point there will be people interesting reviewing your patch, instead of people been told what to do. Regards, Sandro ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 15:24:09 2012 From: report at bugs.python.org (Stefan Krah) Date: Mon, 30 Jan 2012 14:24:09 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327933449.61.0.40436135593.issue13868@psf.upfronthosting.co.za> Stefan Krah added the comment: Congratulations: You (again) have found a fundamental error in TAOCP. Example (Third Edition, page 233): "The following definitions seem to be appropriate for base b, excess q, floating point numbers ..." ---------- nosy: +skrah _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 16:14:26 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Mon, 30 Jan 2012 15:14:26 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327936466.12.0.217400395105.issue13868@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: For the time being I don't find any other "floating point" occurences in Python docs. I found one and made a patch for it. Please apply the patch. Thanks. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Mon Jan 30 22:09:17 2012 From: report at bugs.python.org (Georg Brandl) Date: Mon, 30 Jan 2012 21:09:17 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1327957757.9.0.307948324.issue13868@psf.upfronthosting.co.za> Georg Brandl added the comment: Wow, does that mean he can cash in a Knuth check? ---------- nosy: +georg.brandl _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 31 14:03:32 2012 From: report at bugs.python.org (=?utf-8?q?Bo=C5=A1tjan_Mejak?=) Date: Tue, 31 Jan 2012 13:03:32 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327535890.98.0.936666267948.issue13868@psf.upfronthosting.co.za> Message-ID: <1328015012.57.0.150001332652.issue13868@psf.upfronthosting.co.za> Bo?tjan Mejak added the comment: What's?the?purpose?of?this?tracker?if?the?author?of?an?issue?report?has to?beg?for?something?to?be?fixed,?despite?the?fact?that (s)he?even made?a patch ????? ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 31 14:13:10 2012 From: report at bugs.python.org (Ezio Melotti) Date: Tue, 31 Jan 2012 13:13:10 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1328015590.57.0.567266081962.issue13899@psf.upfronthosting.co.za> Ezio Melotti added the comment: The rule 1 makes sense, but it's not entirely obvious (people might consider bBaAzZ special too). The "normal Python rules for backslash escapes but revert to the C behaviour of stripping the \ from unrecognised escapes" is not obvious either, and from r'[\A]' people might expect: 1) same as \A, (beginning of the string); 2) a letter 'A'; 3) a '\' or a letter 'A' (especially if they write it as '[\\A]'); This is why I suggested to raise an error (and refuse the temptation to guess), but on the other hand, if you consider 'A' a "normal" letter like 'C', having an error for \A would be incoherent. It would have been better if \C raised an error too (I don't see why that would appear in a regex, since re.escape doesn't escape C and the user has no reason to add the \), but now it's too late for that. ---------- _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 31 17:39:18 2012 From: report at bugs.python.org (=?utf-8?b?SmVzw7pzIENlYSBBdmnDs24=?=) Date: Tue, 31 Jan 2012 16:39:18 +0000 Subject: [docs] [issue13899] re pattern r"[\A]" should work like "A" but matches nothing. Ditto B and Z. In-Reply-To: <1327789733.95.0.48339527102.issue13899@psf.upfronthosting.co.za> Message-ID: <1328027958.42.0.137176894596.issue13899@psf.upfronthosting.co.za> Changes by Jes?s Cea Avi?n : ---------- nosy: +jcea _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 31 20:10:37 2012 From: report at bugs.python.org (Petri Lehtinen) Date: Tue, 31 Jan 2012 19:10:37 +0000 Subject: [docs] [issue13402] Document absoluteness of sys.executable In-Reply-To: <1321289437.84.0.982753479785.issue13402@psf.upfronthosting.co.za> Message-ID: <1328037037.3.0.0510637119209.issue13402@psf.upfronthosting.co.za> Petri Lehtinen added the comment: Attached one more patch. The documentation now also mentions None as a possible value. ---------- Added file: http://bugs.python.org/file24380/issue13402_v3.patch _______________________________________ Python tracker _______________________________________ From report at bugs.python.org Tue Jan 31 22:28:45 2012 From: report at bugs.python.org (Stefan Krah) Date: Tue, 31 Jan 2012 21:28:45 +0000 Subject: [docs] [issue13868] Add hyphen doc fix In-Reply-To: <1327957757.9.0.307948324.issue13868@psf.upfronthosting.co.za> Message-ID: <20120131212843.GA8245@sleipnir.bytereef.org> Stefan Krah added the comment: Georg Brandl wrote: > Wow, does that mean he can cash in a Knuth check? Two already: One for the insight that "i-th" is the only true spelling, and now this one. ---------- _______________________________________ Python tracker _______________________________________ From adam.siembida at gmail.com Mon Jan 30 18:38:31 2012 From: adam.siembida at gmail.com (Adam Siembida) Date: Mon, 30 Jan 2012 12:38:31 -0500 Subject: [docs] Error in "Installing Python Modules" Message-ID: On the web page: http://docs.python.org/install/index.html Under: Installing Python Modules > Platform Variations It says: ------------------------------------------------ On Windows, you?d probably download foo-1.0.zip. If you downloaded the archive file to C:\Temp, then it would unpack into C:\Temp\foo-1.0; you can use either a archive manipulator with a graphical user interface (such as WinZip) or a command-line tool (such as unzip or pkunzip) to unpack the archive. Then, open a command prompt window and run: cd c:\Temp\foo-1.0 python setup.py install ------------------------------------------------ It should say: setup.py install instead of: python setup.py install -------------- next part -------------- An HTML attachment was scrubbed... URL: From andreas.balogh at db.com Mon Jan 30 09:01:06 2012 From: andreas.balogh at db.com (Andreas Balogh) Date: Mon, 30 Jan 2012 09:01:06 +0100 Subject: [docs] documentation bug In-Reply-To: Message-ID: Classification: Public Hello, thanks for your feedback. Let me further explain why I think the doc is unclear to me here. Maybe I am missing something. A little bit earlier documentation mentions: "This makes it possible to create read-only properties easily using property() as a decorator: " implying property to be the key to creating a read-only property. In conjunction with: "A property object has getter, setter, and deleter methods usable as decorators that create a copy of the property with the corresponding accessor function set to the decorated function. This is best explained with an example: " The description implies the decorator for a getter to be @x.getter and not @property. I am of the impression that property() would only be used for creating read-only properties while x.getter, x.setter, x.deleter decorators create read-writable properties. It is unclear here when a read-only property is created and when a read-write property is created. Then "This code is exactly equivalent to the first example." is not true. The second example is about a read-write property while the first example is about a read-only property. It contains two additional methods. Just remove the sentence. IMHO what should be explicitely mentioned is 1. why symmetry is broken for @property vs @propertyname.setter and @propertyname.deleter, and 2. how python determines to create a read-only or a read-write property (is it just the existence of setter and deleter decorators/methods?) Regards, Andreas ______________________________________________________________________________ Andreas Balogh Domain Manager Global Technology Capital Markets | Business Solutions | Global Markets Equity Deutsche Bank AG | Gro?e Gallusstra?e 10-14 | 60311 Frankfurt am Main | Germany Tel: +49 69 910 39518 | Fax : +49 69 910 32260 ______________________________________________________________________________ Sandro Tosi Sent by: matrixhasu at gmail.com 28.01.2012 19:44 To Andreas Balogh cc docs at python.org Subject Re: [docs] documentation bug Hello Andreas, thanks for your email. On Thu, Jan 26, 2012 at 15:28, Andreas Balogh wrote: > @property > def x(self): > """I'm the 'x' property.""" > return self._x ... > should read correctly ... > @x.getter > def x(self): > """I'm the 'x' property.""" > return self._x I'm not exactly sure that the example is incorrect, the writer might have wanted to recall the property decorator of the example above instead of using the getter decorator. Regards, -- Sandro Tosi (aka morph, morpheus, matrixhasu) My website: http://matrixhasu.altervista.org/ Me at Debian: http://wiki.debian.org/SandroTosi -- Informationen (einschlie?lich Pflichtangaben) zu einzelnen, innerhalb der EU t?tigen Gesellschaften und Zweigniederlassungen des Konzerns Deutsche Bank finden Sie unter http://www.deutsche-bank.de/de/content/pflichtangaben.htm. Diese E-Mail enth?lt vertrauliche und/ oder rechtlich gesch?tzte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrt?mlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist nicht gestattet. Please refer to http://www.db.com/en/content/eu_disclosures.htm for information (including mandatory corporate particulars) on selected Deutsche Bank branches and group companies registered or incorporated in the European Union. This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From wgrillo at wences.com.ar Mon Jan 30 17:08:23 2012 From: wgrillo at wences.com.ar (Wenceslao Grillo) Date: Mon, 30 Jan 2012 13:08:23 -0300 Subject: [docs] 'Bug' in modules tutorial Message-ID: <4F26C077.7020307@wences.com.ar> Hi, guys, I'm only starting out with Python, and the docs are a great help. Congrats on an excelent work! Found a bug though: in there's a footnote that reads: In fact function definitions are also 'statements' that are 'executed'; the execution of a module-level function enters the function name in the module's global symbol table. It seems to me it should be: In fact function definitions are also 'statements' that are 'executed'; the execution of a module-level function *definition* enters the function name in the module's global symbol table. Congrats again! Regards: Wences -------------- next part -------------- An HTML attachment was scrubbed... URL: