[issue13386] Document documentation conventions for optional args

2011-11-12 Thread Eric V. Smith
Eric V. Smith e...@trueblade.com added the comment: To your last point, I think it's important to specify the default value placeholder (basically a sentinel) in the documentation. For example, if a function takes -1 to mean all occurrences, then the caller needs to know how what value to

[issue13294] http.server - HEAD request when no resource is defined.

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Hi Karl, I’m not clear about what problem or need this report describes. Is it a proposition to add a new method for SimpleHTTPRequestHandler to handle HEAD requests? -- nosy: +eric.araujo versions: +Python 3.3 -Python 3.1, Python 3.2

[issue13297] xmlrpc.client could accept bytes for input and output

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I made comments on Rietveld but there was a glitch, I’m not sure the email was sent. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13297

[issue13298] Result type depends on order of operands for bytes and bytearray

2011-11-12 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13298 ___ ___ Python-bugs-list

[issue13299] namedtuple row factory for sqlite3

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: collections.namedtuple provides a much nicer interface than sqlite3.Row Definitely! -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13299

[issue13329] Runs normal as console script but falls as CGI

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: The contents are valid UTF-8; the problem does not seem related to PYTHONIOENCODING (run “python3.2 Test.py | cat” so that stdout is not a tty; this used to be buggy in 2.x, hence PYTHONIOENCODING, but in 3.x the encoding of stdout is UTF-8

[issue13336] packaging.command.Command.copy_file doesn't implement preserve_mode and preserve_times

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks for the report. Have you found the bug with a real setup.cfg or hook, or were you just reading the code? I’m not sure how hard to fix this will be. The copy_file method delegates to shutil.copyfile, but this does not have the arguments

[issue13282] the table of contents in epub file is too long

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks for the report. I do not know if this something that we can fix in the CPython repository by editing some template or config file or if it requires a patch to Sphinx first. Georg? -- nosy: +eric.araujo, georg.brandl

[issue13281] Make robotparser.RobotFileParser ignore blank lines

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: First, I’d like to remind that the robots spec is not an official Internet spec backed up by an official body. It’s also not as important as (say) HTTP parsing. For this bug, IMO the guiding principle should be Postel’s Law. What harm is

[issue13294] http.server - HEAD request when no resource is defined.

2011-11-12 Thread karl
karl karl+pythonb...@la-grange.net added the comment: Eric, Two possible solutions to explore: Either the HEAD reports exactly the same thing than a GET without the body, because it is the role of the GET, but that means indeed adding support for the HEAD. or creating a catch-all answer

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Florent Xicluna
New submission from Florent Xicluna florent.xicl...@gmail.com: Sometimes we want to check the exact type of an object. The method assertIsInstance could be misleading in such case. The current workaround is: assertIs(type(obj), some_class) However we can add an argument to the method to keep

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks, I’ve made some comments on Rietveld. Added a recommendation to only use keywords, which seems sane given the number of arguments. I looked for that but couldn’t find it. -- nosy: +eric.araujo

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: I'm not sure this is common enough to justify a new arg. The status quo has the advantage that is quite close with what we would use in an 'if' statement (i.e. either if isinstance(obj, some_class): or if type(obj) is some_class:).

[issue12103] Document how to use open with os.O_CLOEXEC

2011-11-12 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- keywords: +easy nosy: +eric.araujo title: Documentation of open() does not claim 'e' support in mode string - Document how to use open with os.O_CLOEXEC versions: +Python 3.3 -Python 2.7 ___ Python

[issue13264] Monkeypatching using metaclass

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: It seems to me this is not a bug. Closing? -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13264 ___

[issue13286] PEP 3151 breaks backward compatibility: it should be documented

2011-11-12 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13286 ___ ___ Python-bugs-list

[issue13386] Document documentation conventions for optional args

2011-11-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: The problem is when the default placeholder is some unique object() or some _internal value (we had something similar with a socket timeout once). Also for something like str.strip(), would you document chars=None or chars= \n\r\t\v\f?

[issue13193] test_packaging and test_distutils failures

2011-11-12 Thread Nadeem Vawda
Nadeem Vawda nadeem.va...@gmail.com added the comment: I'm no longer getting the failures on either Ubuntu or Windows (and the Windows buildbots are now green), so tentatively marking this as fixed. Feel free to reopen if something is still broken. -- resolution: - fixed stage: needs

[issue12344] Add **kwargs to reinitialize_command

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I’ve spent some time on this. First, I decided that the former name (reinitialize_command) of the method was better. The get_* name could create the impression that the returned object was independent from the internal caches (command_obj,

[issue12344] Add **kwargs to reinitialize_command

2011-11-12 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: Added file: http://bugs.python.org/file23659/fix-reinitialize-command.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12344 ___

[issue12344] Add **kwargs to reinitialize_command

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: BTW, here’s the changeset to rename get_reinit_etc. -- Added file: http://bugs.python.org/file23660/rename-grc.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12344

[issue12119] distutils and python -B

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: A 1999 comment in build_py from Greg Ward agrees with me: # XXX hey! we can't control whether we optimize or not; that's up # to the invocation of the current Python interpreter (at least # according to the py_compile docs). That

[issue13193] test_packaging and test_distutils failures

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: This problem was not trivial to find, because it appears that test execution order may not be entirely deterministic: I couldn't see any other reason why the flag would have different values on different machines. On my machine, it looks

[issue13204] sys.flags.__new__ crashes

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: You are right. Even if it’s an undocumented internal type, there is no reason not to fix it. There are plenty of similar crash fixes committed in the repo. -- ___ Python tracker

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Florent Xicluna
Changes by Florent Xicluna florent.xicl...@gmail.com: Added file: http://bugs.python.org/file23661/grep_test_is_instance.log ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13387 ___

[issue13294] http.server: HEAD request should not return a body

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Right now the HEAD returns something :) Ah, so this is a bug. I still need to propose a patch. A patch to add a test (for 2.7 or 3.2, see devguide) would be a great first step. -- title: http.server - HEAD request when no resource is

[issue13193] test_packaging and test_distutils failures

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Antoine, I appreciate that you took time to fix this bug while I was without Internet and without Windows, but unfortunately I will have to backout your commit. Postel’s Law doesn’t win here: It is documented that the MANIFEST template only

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Florent Xicluna
Changes by Florent Xicluna florent.xicl...@gmail.com: Added file: http://bugs.python.org/file23662/grep_test_exact_type.log ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13387 ___

[issue13180] pysetup silently ignores invalid entries in setup.cfg

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I want to explore ideas about a schema/type system, so I’m removing the easy keyword. -- keywords: -easy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13180

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Florent Xicluna
Florent Xicluna florent.xicl...@gmail.com added the comment: At least in the standard library test suite, it should be useful. When the test is stricter, it catches errors earlier. I remember when assertIsInstance was made available (issue #7031), we started to rewrite some expressions

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I find that assertIs(type(x), someclass) is very clear, whereas an assertIsInstance that would not behave like isinstance depending on one argument would be non-obvious to me. -- nosy: +eric.araujo

[issue1011113] Make “install” find the build_base directory

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I’ve found a distutils commit that shows that this option was removed on purpose, because people might except that using “install -b foo” would affect the build command, but it does not. I don’t think it’s a problem. For people who run build

[issue13193] test_packaging and test_distutils failures

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: That's should, not must. I read that “should” as a polite “must”. Also, I thought people did undocumented things with distutils, and we had to support these undocumented uses? People rely on undocumented features and sometimes on bugs. Thus,

[issue9831] test_distutils should honor PYTHONDONTWRITEBYTECODE

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I now think the change I did was wrong. See #12119. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9831 ___

[issue13193] test_packaging and test_distutils failures

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: A commit adding problem should be fixed or reverted The point is that fixing it may take tome. Reverting is fine by me. But we have no way of knowing you will be taking tome to do it. Ideally, you should have reverted it yourself (or applied

[issue12246] Support installation when running from an uninstalled Python

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Paul Moore reported that a Python built in its checkout on Windows has no problem installing, so I’d like to revisit this. The patch was also incomplete: The install module was changed, but people could still call “pysetup run install_dist”,

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Florent Xicluna
Florent Xicluna florent.xicl...@gmail.com added the comment: I would say that this one is clear too: aelf.assertTrue(isinstance(obj, cls)) except that the failure message is not very friendly: AssertionError: False is not true If we keep assertIsInstance, more people will continue to

[issue13170] distutils2 test failures

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: All three issues fixed, thanks! I can’t push today but I will as soon as possible, probably Monday. I will open another report for the change I reverted in config; it was done on purpose by another developer to fix a bug with distutils2’s own

[issue12659] Add tests for packaging.tests.support

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I ported the patch to distutils2, but it fails because of some unittest internal problem. Help welcome. -- Added file: http://bugs.python.org/file23664/test_support.py ___ Python tracker

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I would say that this one is clear too: aelf.assertTrue(isinstance(obj, cls)) except that the failure message is not very friendly: AssertionError: False is not true Yeah, you have to give something as third argument to ease debugging. If

[issue1677872] Efficient reverse line iterator

2011-11-12 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1677872 ___ ___ Python-bugs-list

[issue13385] Add an explicit re.NOFLAGS flag value to the re module

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I had too the need to find out the value to pass when there are no flags, so a mention of 0 in the doc would have been enough for me. -0 on a new constant. -- ___ Python tracker

[issue13336] packaging.command.Command.copy_file doesn't implement preserve_mode and preserve_times

2011-11-12 Thread Vinay Sajip
Vinay Sajip vinay_sa...@yahoo.co.uk added the comment: Éric Araujo mer...@netwok.org added the comment: Thanks for the report.  Have you found the bug with a real setup.cfg or hook, or were you just reading the code? I found the bug with a real setup.cfg (executable permission

[issue13297] xmlrpc.client could accept bytes for input and output

2011-11-12 Thread Florent Xicluna
Florent Xicluna florent.xicl...@gmail.com added the comment: Thank you for your comments. Uploaded a new version. -- Added file: http://bugs.python.org/file23665/issue13297_xmlrpc_bytes_v4.diff ___ Python tracker rep...@bugs.python.org

[issue13198] Remove duplicate definition of write_record_file

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Here’s the patch produced by Mike and I so far. -- keywords: +patch Added file: http://bugs.python.org/file23666/remove-duplicate-write_record_file.diff ___ Python tracker rep...@bugs.python.org

[issue13239] Remove operator from Grammar/Grammar

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: +1 for a comment too. I’d even make it shorter: # don't look at , it's not a real operator (see PEP 401) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13239

[issue11638] python setup.py sdist --formats tar* crashes if version is unicode

2011-11-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: since the issue only applies when sdist --format gztar, I mention that here. bztar will probably have the same issue. Also, issue8396 suggests encoding using sys.getfilesystemencoding(). Good one! -- title: python setup.py sdist

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-11-12 Thread Roy Smith
Roy Smith r...@panix.com added the comment: New patch uploaded. The added recommendation is around line 161 (look for 'Recommended usage is to only use keyword arguments') -- Added file: http://bugs.python.org/file23667/Issue13249-2.patch ___

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Michael Foord
Michael Foord mich...@voidspace.org.uk added the comment: I think your proposed workaround is good enough and no extra effort to type than the suggested change to assertIsInstance. -1 on a new method I think the behaviour of isinstance is clear enough that people who misunderstand what

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I don't think there's a point in adding such an extra argument. Why don't you just write self.assertIs(type(myobj), sometype) ? How is the error message not good enough? -- nosy: +pitrou ___

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: @msg147513 Why don't you just write self.assertIs(type(myobj), sometype) +1 -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13387

[issue13385] Add an explicit re.NOFLAGS flag value to the re module

2011-11-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: I think we have enough 0 to reject the issue. Closing. -- resolution: - rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13385

[issue13329] Runs normal as console script but falls as CGI

2011-11-12 Thread Petri Lehtinen
Changes by Petri Lehtinen pe...@digip.org: -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13329 ___ ___ Python-bugs-list

[issue12875] backport re.compile flags default value documentation

2011-11-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: I have converted the Doc/library/re.rst doc of 2.7 to follow the new convention of 3.x, patch attached. -- keywords: +patch Added file: http://bugs.python.org/file23668/issue12875.1.patch ___ Python

[issue12767] document threading.Condition.notify

2011-11-12 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 63a24bff6f36 by Eli Bendersky in branch '3.2': Issue #12767: documenting threading.Condition.notify http://hg.python.org/cpython/rev/63a24bff6f36 New changeset ac12dcea69e1 by Eli Bendersky in branch 'default':

[issue12767] document threading.Condition.notify

2011-11-12 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 63a00d019bb2 by Eli Bendersky in branch '2.7': Closes issue 12767: document the argument of threading.Condition.notify http://hg.python.org/cpython/rev/63a00d019bb2 -- resolution: - fixed stage: patch

[issue13239] Remove operator from Grammar/Grammar

2011-11-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Éric, do you feel strongly about the wording, or can I just go ahead and commit my version if I like it more :) ? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13239

[issue13388] document hg commit hooks in the devguide

2011-11-12 Thread Eli Bendersky
New submission from Eli Bendersky eli...@gmail.com: Our Hg repo has some useful hooks on commit messages that allow to specify which issue to notify for commits, and which issue to close. AFAIU, it's currently documented only in the code of the hook

[issue13386] Document documentation conventions for optional args

2011-11-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: You should also explicitly specify what happens in several optional but not keyword args are needed. AFAIU the convention is: func(arg1, arg2[, opt1, opt2]) -- ___ Python tracker

[issue13388] document hg commit hooks in the devguide

2011-11-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Attaching a patch with the suggested change. Based on the doc-string in the implementation of the hook. -- keywords: +patch Added file: http://bugs.python.org/file23669/issue13388.1.patch ___ Python

[issue13387] suggest assertIs(type(obj), cls) for exact type checking

2011-11-12 Thread Florent Xicluna
Florent Xicluna florent.xicl...@gmail.com added the comment: +1 on a doc addition (I can even volunteer a patch) I agree we can highlight the difference between assertIs(type(obj), cls) and assertIsInstance(obj, cls) in the documentation. Let's forget this patch and keep it simple.

[issue13388] document hg commit hooks in the devguide

2011-11-12 Thread Petri Lehtinen
Petri Lehtinen pe...@digip.org added the comment: I'm not sure if it matters, but Sphinx documentation suggests using ^ as the underlining character for subsubsections. Otherwise, looks good. -- nosy: +petri.lehtinen ___ Python tracker

[issue13388] document hg commit hooks in the devguide

2011-11-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Petri, I have actually tried to stay consistent within the same document, and it uses ' for this level of heading. Perhaps it's just not following the Sphinx guide? IIRC the restructured text parser will also shout at you if these are

[issue13388] document hg commit hooks in the devguide

2011-11-12 Thread Petri Lehtinen
Petri Lehtinen pe...@digip.org added the comment: Ah, sorry. I didn't check other files in the devguide. The ReST parser is OK with any underline character, as long as it's consistent within a single file. -- ___ Python tracker

[issue11999] sporadic failure in test_mailbox

2011-11-12 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset d2b0751174f6 by Petri Lehtinen in branch '2.7': Update mailbox.Maildir tests http://hg.python.org/cpython/rev/d2b0751174f6 New changeset b3c5e1c62839 by Petri Lehtinen in branch '3.2': Update mailbox.Maildir tests

[issue13264] Monkeypatching using metaclass

2011-11-12 Thread Daniel Urban
Daniel Urban urban.dani...@gmail.com added the comment: It seems to me this is not a bug. +1 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13264 ___

[issue13374] Deprecate usage of the Windows ANSI API in the nt module

2011-11-12 Thread sbt
sbt shibt...@gmail.com added the comment: I notice that the patch changes rename() and link() to use win32_decode_filename() to coerce the filename to unicode before using the wide win32 api. (Previously, rename() first tried the wide api, falling back to narrow if that failed; link() used wide

[issue13389] Clear lists freelist in gc.collect()

2011-11-12 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: Complete gc collections currently clear all freelists, except for the freelist of list objects. Attached patch fixes the omission. -- components: Interpreter Core files: listfreelist.patch keywords: patch messages: 147530 nosy: pitrou

[issue13390] Hunt memory allocations in addition to reference leaks

2011-11-12 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: This patch adds a counting of the number of allocated memory blocks (through the PyObject_Malloc API). Together with -R, it can help chase those memory leaks which aren't reference leaks (see c6dafa2e2594). The sys.getallocedblocks() function

[issue7732] imp.find_module crashes Python if there exists a directory named __init__.py

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Victor, can you fix the test failures on Windows and 2.7? Otherwise the commit should be reverted. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7732

[issue13389] Clear lists freelist in gc.collect()

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Dicts also have a freelist which isn't freed either. New patch attached. -- Added file: http://bugs.python.org/file23672/listdictfreelist.patch ___ Python tracker rep...@bugs.python.org

[issue13390] Hunt memory allocations in addition to reference leaks

2011-11-12 Thread Andreas Stührk
Changes by Andreas Stührk andy-pyt...@hammerhartes.de: -- nosy: +Trundle ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13390 ___ ___

[issue13380] ctypes: add an internal function for reseting the ctypes caches

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Two things: - you duplicated the part with CFUNCTYPE(c_int)(lambda: None) without removing the original chunk of code - some platforms can't compile ctypes, you must handle that case in regrtest Otherwise, good idea. -- nosy: +pitrou

[issue13389] Clear lists freelist in gc.collect()

2011-11-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Fix the return values and add documentation. -- Added file: http://bugs.python.org/file23673/listdictfreelist.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13389

[issue13389] Clear lists and dicts freelist in gc.collect()

2011-11-12 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- title: Clear lists freelist in gc.collect() - Clear lists and dicts freelist in gc.collect() ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13389

[issue13389] Clear lists and dicts freelist in gc.collect()

2011-11-12 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: Removed file: http://bugs.python.org/file23672/listdictfreelist.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13389 ___

[issue13385] Add an explicit re.NOFLAGS flag value to the re module

2011-11-12 Thread Raymond Hettinger
Raymond Hettinger raymond.hettin...@gmail.com added the comment: Thank you for closing this. I think it would only add clutter to a module that is already puts readers into information overload. -- nosy: +rhettinger ___ Python tracker

[issue13374] Deprecate usage of the Windows ANSI API in the nt module

2011-11-12 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Is this approach of coercing to unicode and only using the wide api blessed? It's not. If people use byte strings, they specifically ask for what they get; Python shouldn't second-guess the data types. I certainly think it should be. If

[issue13391] string.strip Does Not Remove Zero-Width-Space (ZWSP)

2011-11-12 Thread Dave Mankoff
New submission from Dave Mankoff man...@gmail.com: Title pretty much says it all. Simple test case: len(u' \t\r\n\u200B'.strip()) 1 Should be zero. Same problem in Python3: len(' \t\r\n\u200B'.strip()) 1 -- components: Unicode messages: 147538 nosy: ezio.melotti, mankyd priority:

[issue13390] Hunt memory allocations in addition to reference leaks

2011-11-12 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: I added some review comments to the patch, but I'm not sure how usable this is going to be in practice. References generally stay fairly stable while using the interactive interpreter, but the new block accounting jumps around all over the

[issue13392] Writing a pyc file is not atomic under Windows

2011-11-12 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: #13146 solved the issue of writing pyc files under POSIX. Under Windows, the problem still exists, as the following buildbot failure shows: [317/360] test_multiprocessing Traceback (most recent call last): File string, line 1, in module

[issue13391] string.strip Does Not Remove Zero-Width-Space (ZWSP)

2011-11-12 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13391 ___ ___ Python-bugs-list

[issue13281] Make robotparser.RobotFileParser ignore blank lines

2011-11-12 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: My suggested doc change is how to change the doc along with the patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13281 ___

[issue13346] re.split() should behave like string.split() for maxsplit=0 and maxsplit=-1

2011-11-12 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: The two methods are defined differently, and act as defined, so this is a feature request, not a bug report. str.split([sep[, maxsplit]]) ... If maxsplit is given, at most maxsplit splits are done (thus, the list will have at most maxsplit+1

[issue12875] backport re.compile flags default value documentation

2011-11-12 Thread Raymond Hettinger
Raymond Hettinger raymond.hettin...@gmail.com added the comment: This patch looks fine. -- nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12875 ___

[issue12875] backport re.compile flags default value documentation

2011-11-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: LGTM -- stage: - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12875 ___ ___

[issue13346] re.split() should behave like string.split() for maxsplit=0 and maxsplit=-1

2011-11-12 Thread Raymond Hettinger
Raymond Hettinger raymond.hettin...@gmail.com added the comment: Terry, thanks for closing this. The API for str.split() has been set in stone for a very long time. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13346

[issue13349] Uninformal error message in index() and remove() functions

2011-11-12 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: Improving error messages has been a long, slow process as people are irritated enough to make a change. Please go ahead. Guido has explicitly excluded exception detail from the language spec multiple times. Test that depend on details are

[issue13391] string.strip Does Not Remove Zero-Width-Space (ZWSP)

2011-11-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: str.strip uses Py_UNICODE_ISSPACE that in turn uses _PyUnicode_IsWhitespace (see Objects/unicodetype_db.h#l3347), and according to the comment there it Returns 1 for Unicode characters having the bidirectional type 'WS', 'B' or 'S' or the

[issue13355] random.triangular error when low = high=mode

2011-11-12 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: 3.2 doc entry: random.triangular(low, high, mode) Return a random floating point number N such that low = N = high and with the specified mode between those bounds. The low and high bounds default to zero and one. The mode argument defaults

[issue13393] Improve BufferedReader.read1()

2011-11-12 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: The main current user of BufferedReader.read1() is TextIOWrapper. In this context, read1() is used to signal that we want to bypass binary buffering as much as possible, since TextIOWrapper does its own buffering. The current read1()

[issue13393] Improve BufferedReader.read1()

2011-11-12 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: Added file: http://bugs.python.org/file23676/textioread.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13393 ___

[issue13394] Patch to increase aifc lib test coverage with couple of minor fixes

2011-11-12 Thread Oleg Plakhotnyuk
New submission from Oleg Plakhotnyuk oleg...@gmail.com: I've increased coverage of aifc.py by test_aifc.py: before: [1/1] test_aifc lines cov% module (path) 56063% aifc (/Users/family/Documents/code/python/repo/Lib/aifc.py) ... after: [1/1] test_aifc lines cov% module

[issue13394] Patch to increase aifc lib test coverage with couple of minor fixes

2011-11-12 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +r.david.murray stage: - patch review versions: +Python 3.2, Python 3.3 -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13394