[issue17010] Windows launcher ignores active virtual environment

2013-06-12 Thread Vinay Sajip
Changes by Vinay Sajip : -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue17010] Windows launcher ignores active virtual environment

2013-06-12 Thread Vinay Sajip
Vinay Sajip added the comment: Recent changes to the launcher mean that for a shebang line of "#!/usr/bin/env python", the path is searched for a Python executable. This will include the Python executable in an activated venv, so I am closing this issue. The change is already available for tes

[issue17860] subprocess docs lack info how to use output result

2013-06-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. -- nosy: +serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscr

[issue18149] filecmp.cmp() incorrect results when previously compared file is modified within modification time resolution

2013-06-12 Thread Ned Deily
Ned Deily added the comment: Looks good to me, other than that the doc change should include a version added directive (which can be added by the committer): .. function:: clear_cache() + .. versionadded:: 3.4 + Clear the filecmp cache. This may be useful if a file is compared so quickl

[issue17860] subprocess docs lack info how to use output result

2013-06-12 Thread Ezio Melotti
Ezio Melotti added the comment: Also in the Python 3 docs we don't compare the current behavior with Python 2. Ronald patch LGTM. -- ___ Python tracker ___

[issue17860] subprocess docs lack info how to use output result

2013-06-12 Thread Ronald Oussoren
Ronald Oussoren added the comment: I don't agree that adding a table/picture is the only thing that can be done, or even that it is a good idea. IMHO the subprocess documentation is clear enough about the distinction between bytes and string, especially in the section about convenience functio

[issue18201] distutils write into symlinks instead of replacing them

2013-06-12 Thread Michał Górny
Changes by Michał Górny : -- type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue18201] distutils write into symlinks instead of replacing them

2013-06-12 Thread Michał Górny
New submission from Michał Górny: We're doing heavy wrapping of Python scripts on Gentoo in order to efficiently support having multiple versions of Python installed. For that reason, every Python script installed using the package manager is renamed, and a symlink to a common wrapper binary i

[issue18200] Update stdlib to use ModuleNotFoundError

2013-06-12 Thread Brett Cannon
Brett Cannon added the comment: Here is a patch that uses ModuleNotFoundError in the stdlib sans test modules. -- keywords: +patch Added file: http://bugs.python.org/file30568/use_ModuleNotFoundError.diff ___ Python tracker

[issue18200] Update stdlib to use ModuleNotFoundError

2013-06-12 Thread Brett Cannon
Changes by Brett Cannon : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15767] add ModuleNotFoundError

2013-06-12 Thread Roundup Robot
Roundup Robot added the comment: New changeset c6c0faaf65d7 by Brett Cannon in branch 'default': Issue #15767: Add an explicit test for raising ModuleNotFoundError http://hg.python.org/cpython/rev/c6c0faaf65d7 -- ___ Python tracker

[issue15767] add ModuleNotFoundError

2013-06-12 Thread Roundup Robot
Roundup Robot added the comment: New changeset 3a50025f1900 by Brett Cannon in branch 'default': Issue #15767: Touch up ModuleNotFoundError usage by import. http://hg.python.org/cpython/rev/3a50025f1900 -- ___ Python tracker

[issue18200] Update stdlib to use ModuleNotFoundError

2013-06-12 Thread Brett Cannon
Brett Cannon added the comment: Changeset 84105:281857369a78 and 84106:c4d7228421df have some updates to use ModuleNotFoundError. -- ___ Python tracker ___ _

[issue18164] Embedding Python doc incorrectly refers to LINKFORSHARED

2013-06-12 Thread Ned Deily
Ned Deily added the comment: On further review, I think the 3.x documentation is pretty good as is. I propose one change to it: getting another config var to help emphasize "the configuration values that you will want to combine together". The proposed 2.7 patch backports the whole 3.x secti

[issue18200] Update stdlib to use ModuleNotFoundError

2013-06-12 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue18164] Embedding Python doc incorrectly refers to LINKFORSHARED

2013-06-12 Thread Ned Deily
Changes by Ned Deily : Added file: http://bugs.python.org/file30567/issue18164-27.patch ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue11957] re.sub confusion between count and flags args

2013-06-12 Thread STINNER Victor
Changes by STINNER Victor : -- components: -Unicode ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue18149] filecmp.cmp() incorrect results when previously compared file is modified within modification time resolution

2013-06-12 Thread Mark Levitt
Mark Levitt added the comment: Ned, Thanks for taking the time to review. I've updated the docs, added a unit test, signed the contributor form, and made the changes/corrections from your review. Updated patch attached. -- Added file: http://bugs.python.org/file30565/18149-2.patch __

[issue3329] API for setting the memory allocator used by Python

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: py_setallocators-4.patch: - Oh, I forgot another change: Py*_Get/SetAllocators() cannot fail anymore (because of an unknown API identifier), so the return type is now void I just saw that I forgot ".. versionadded:: 3.4" in the doc. -- ___

[issue3329] API for setting the memory allocator used by Python

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: New version (4) of the patch: - move the opaque pointer (now called "void *ctx", "context") as the first parameter instead of the last parameter, as done in zlib, lzma and Oracle's OCI APIs; ctx is also the first parameter of Py*_GetFunctions() and Py*_SetFu

[issue18149] filecmp.cmp() incorrect results when previously compared file is modified within modification time resolution

2013-06-12 Thread Ned Deily
Ned Deily added the comment: Thanks for the patch, Mark. I've left some review comments via Rietveld (the review link next to the patch). Also, if you haven't already, please fill out the contributor form as described in the Developer's Guide (http://docs.python.org/devguide/patch.html#licens

[issue18200] Update stdlib to use ModuleNotFoundError

2013-06-12 Thread Brett Cannon
Changes by Brett Cannon : -- dependencies: +add ModuleNotFoundError ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue18200] Update stdlib to use ModuleNotFoundError

2013-06-12 Thread Brett Cannon
New submission from Brett Cannon: The common idiom:: try: import something except ImportError: pass should be updated to use ModuleNotFoundError instead to not accidentally swallow ImportError exceptions which signal actual errors. -- components: Library (Lib) keywords: easy mes

[issue15767] add ModuleNotFoundError

2013-06-12 Thread Brett Cannon
Changes by Brett Cannon : -- resolution: -> fixed stage: test needed -> committed/rejected status: open -> closed ___ Python tracker ___

[issue15767] add ModuleNotFoundError

2013-06-12 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8a0ed9f63c6e by Brett Cannon in branch 'default': Issue #15767: Introduce ModuleNotFoundError, a subclass of http://hg.python.org/cpython/rev/8a0ed9f63c6e -- nosy: +python-dev ___ Python tracker

[issue15767] add ModuleNotFoundError

2013-06-12 Thread Brett Cannon
Changes by Brett Cannon : -- title: add ImportNotFoundError -> add ModuleNotFoundError ___ Python tracker ___ ___ Python-bugs-list mai

[issue17860] subprocess docs lack info how to use output result

2013-06-12 Thread anatoly techtonik
anatoly techtonik added the comment: The only thing that can save the docs is pictures. Or tables. +-+---+ | | universal_newlines = True | +--+-+---+ |Py.2 | str | str

[issue18164] Embedding Python doc incorrectly refers to LINKFORSHARED

2013-06-12 Thread Éric Araujo
Éric Araujo added the comment: I think it was Antoine who committed the patch originally. -- nosy: +eric.araujo, pitrou ___ Python tracker ___ ___

[issue18199] No long filename support for Windows

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: > it'd be nice if we could fix it at the source Yes, it is what we are trying to do. But it's not so simple. That's why the issue is splitted into more specific issues. > If I provide unit tests for all the involved file system > functions and fix the issues (

[issue18191] urllib2/urllib.parse.splitport does not handle IPv6 correctly

2013-06-12 Thread Berker Peksag
Berker Peksag added the comment: FTR, urllib.parse.splitport is undocumented and it is only used by urllib.request in the stdlib. -- nosy: +berker.peksag versions: -Python 3.1, Python 3.2 ___ Python tracker _

[issue18191] urllib2/urllib.parse.splitport does not handle IPv6 correctly

2013-06-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I see only tests. It is more common to use arguments for assertEqual() in the reverse order, first actual value, and than expected value. -- nosy: +serhiy.storchaka ___ Python tracker

[issue18191] urllib2/urllib.parse.splitport does not handle IPv6 correctly

2013-06-12 Thread Doug Hellmann
Doug Hellmann added the comment: LGTM -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue18192] Move imp.get_magic() to importlib

2013-06-12 Thread Brett Cannon
Brett Cannon added the comment: So what are your arguments to making it more accessible? The typical user won't need to use it so I don't know if it really requires being off of importlib directly like find_loader, import_module, or (eventually) reload (which for convenience-sake while at the

[issue18163] Add a 'key' attribute to KeyError

2013-06-12 Thread Brett Cannon
Brett Cannon added the comment: What David said. =) The fact that the key is the first value from args is almost happenstance as the exception message is customized in __str__() and not in what is passed to the exception. But what if I had defined __getattr__ or __getattribute__ and had some

[issue18191] urllib2/urllib.parse.splitport does not handle IPv6 correctly

2013-06-12 Thread Doug Hellmann
Changes by Doug Hellmann : -- nosy: +doughellmann ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue18199] No long filename support for Windows

2013-06-12 Thread Daniel Sturm
Daniel Sturm added the comment: > In my opinion, it is a bug in Windows I don't think calling every complicated API a "bug" is useful. Is the Win32 API exceedingly annoying? I think everybody agrees on that, but imo it's better to fix this once in python itself and don't force all developers t

[issue18174] Make regrtest with --huntrleaks check for fd leaks

2013-06-12 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue18199] No long filename support for Windows

2013-06-12 Thread STINNER Victor
Changes by STINNER Victor : -- versions: +Python 3.4 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue18199] No long filename support for Windows

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: > The problem is that we never prepend "\\?\" to the pathname hence getting the > old MAX_PATH limit. I would not call this a "problem". In my opinion, it is a bug in Windows: I don't understand why we should preprend something to support longer path. I'm not

[issue18199] No long filename support for Windows

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: Using extended path ("\\?\" prefix) causes new issues. * #13234: issue in os.listdir() * #13772: issue with os.symlink() * #9949: issue in os.path.realpath() -- nosy: +brian.curtin, haypo, loewis, pitrou, serhiy.storchaka, tim.golden ___

[issue18164] Embedding Python doc incorrectly refers to LINKFORSHARED

2013-06-12 Thread egallager
egallager added the comment: For reference, this originally came from the following MacPorts ticket: https://trac.macports.org/ticket/39223#comment:14 -- nosy: +E.Money ___ Python tracker _

[issue18199] No long filename support for Windows

2013-06-12 Thread Daniel Sturm
Changes by Daniel Sturm : -- components: +IO type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue18199] No long filename support for Windows

2013-06-12 Thread Daniel Sturm
New submission from Daniel Sturm: Python at the moment does not handle paths with more than MAX_PATH characters well under Windows. With Windows 7 x64, Python 3.3 32bit, the attached file fails with: Traceback (most recent call last): File ".\filename_bug.py", line 4, in os.makedirs(dir)

[issue17860] subprocess docs lack info how to use output result

2013-06-12 Thread Ronald Oussoren
Ronald Oussoren added the comment: The attached patch explicitly mentions that stdin/stdout/stderr are opened as binary streams when universal_newlines is False. I'm not convinced that adding this text will solve the confusion, subprocess has fairly complex documentation due to the rich API a

[issue18174] Make regrtest with --huntrleaks check for fd leaks

2013-06-12 Thread Richard Oudkerk
Richard Oudkerk added the comment: Updated version which adds checks for handle leaks on Windows. -- Added file: http://bugs.python.org/file30561/fdleak.patch ___ Python tracker

[issue3329] API for setting the memory allocator used by Python

2013-06-12 Thread STINNER Victor
Changes by STINNER Victor : Added file: http://bugs.python.org/file30559/pybench.txt ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue3329] API for setting the memory allocator used by Python

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: > If I understood correctly, the overhead is really really low (near zero). See attached output pybench.txt and benchmarks.txt. -- ___ Python tracker __

[issue3329] API for setting the memory allocator used by Python

2013-06-12 Thread STINNER Victor
STINNER Victor added the comment: Benchmark of py_setallocators-3.patch: - benchmarks suite (-b 2n3): some tests are 1.04x faster, some tests are 1.04 slower, significant is between 115 and -191. I don't understand these output, but I guess that the overhead cannot be seen with such test. -

[issue3329] API for setting the memory allocator used by Python

2013-06-12 Thread STINNER Victor
Changes by STINNER Victor : Added file: http://bugs.python.org/file30560/benchmarks.txt ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue7559] TestLoader.loadTestsFromName swallows import errors

2013-06-12 Thread vila
Changes by vila : -- nosy: +vila ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/

[issue16662] load_tests not invoked in package/__init__.py

2013-06-12 Thread Michael Foord
Michael Foord added the comment: I agree that load_tests *should* be used in packages and that not doing this from the start was a mistake. -- ___ Python tracker ___ ___

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread Michael Foord
Michael Foord added the comment: The load_tests protocol is already the intended way for test writers to customize discovery. The problem, as issue 16662 states, is that load_tests is not invoked for packages by default. Fixing that is the right fix. I'm rejecting this issue in favour of 16662

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread R. David Murray
R. David Murray added the comment: The linked code does something different. I believe the title of this issue is incorrect for the implicitly suggested enhancement. I also suspect the suggested enhancement (to the extent that I understand it) is not ripe for stdlib inclusion, but I'll leave

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread vila
vila added the comment: > The linked code does something different. Right, it addressed other issues encountered in that project: 1 - the need for different paterns for files and directories (http://bugs.python.org/issue16662), 2 - handling import errors at load time (http://bugs.python.org/iss

[issue18191] urllib2/urllib.parse.splitport does not handle IPv6 correctly

2013-06-12 Thread Julien Danjou
Julien Danjou added the comment: Attached is a patch inspired by a function written for OpenStack Oslo library. -- keywords: +patch Added file: http://bugs.python.org/file30558/0001-Make-urllib.parse.splitport-handle-IPv6-correctly.patch ___ Python t

[issue18149] filecmp.cmp() incorrect results when previously compared file is modified within modification time resolution

2013-06-12 Thread Mark Levitt
Mark Levitt added the comment: I've added a "clear_cache()" method to filecmp.py. Patch attached. I had thought about implementing an optional parameter to only invalidate the cache of a specific file object, but figured I'd keep it simple for now. First time submitting a patch, so apologies

[issue16662] load_tests not invoked in package/__init__.py

2013-06-12 Thread Michael Foord
Changes by Michael Foord : -- assignee: -> michael.foord nosy: +michael.foord ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue515074] Extended storage in new-style classes

2013-06-12 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Most concrete variable-sized types don't use tp_basicsize to know where the data lives. For example, PyBytesObject has a "char ob_sval[1];" member, and PyBytes_AsString() looks at this fixed offset. For this reason, additional data cannot be stored before

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread Barry A. Warsaw
Changes by Barry A. Warsaw : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue18181] super vs. someclass.__getattribute__

2013-06-12 Thread Ronald Oussoren
Ronald Oussoren added the comment: Slightly updated patch (different names, added some documentation) -- Added file: http://bugs.python.org/file30555/issue-18181-poc-v3.txt ___ Python tracker __

[issue18181] super vs. someclass.__getattribute__

2013-06-12 Thread Ronald Oussoren
Ronald Oussoren added the comment: added draft of a pep-style proposal -- Added file: http://bugs.python.org/file30556/super-hook-proposal.rst ___ Python tracker ___

[issue18167] cgi.FieldStorage fails to handle multipart/form-data when \r\n appears at end of 65535 bytes without other newlines

2013-06-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your report, but your patch looks overcomplicated, it fails on 'x'*65535+'\r'+'y'*65535 and hangs on 'x'*65535+'\r'. Here is a simpler patch with tests. -- assignee: -> serhiy.storchaka nosy: +serhiy.storchaka Added file: http://bugs.p

[issue18167] cgi.FieldStorage fails to handle multipart/form-data when \r\n appears at end of 65535 bytes without other newlines

2013-06-12 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- versions: +Python 3.3, Python 3.4 Added file: http://bugs.python.org/file30554/issue18167-3.3.patch ___ Python tracker ___ __

[issue18054] Add more exception related assertions to unittest

2013-06-12 Thread vila
Changes by vila : -- nosy: +vila ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman

[issue16487] Allow ssl certificates to be specified from memory rather than files.

2013-06-12 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Hi there. Thanks for your comments. This is the kind of discussion I was hoping to have about my draft patch. I too have reservations about adding arguments. In the version of this that we have in house, we actually don't use a "certdata" argument, b

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread Robert Collins
Robert Collins added the comment: Well, spoke with vila on IRC. I content it's a duplicate because if load_tests in __init__ kicks in and supercedes discovery, I believe this bug would not be needed. -- ___ Python tracker

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread Robert Collins
Robert Collins added the comment: This is a duplicate of 16662 -- nosy: +rbcollins ___ Python tracker ___ ___ Python-bugs-list mailing

[issue18198] unittest discover should provide a way to define discovery at package level

2013-06-12 Thread vila
New submission from vila: While most test suites are a tree with test_*.py files, there are cases where being able to define the discovery for a subtree in the package __init__.py file comes handy. A poc implementation is available at http://bazaar.launchpad.net/~canonical-isd-qa/selenium-sim

[issue10581] Review and document string format accepted in numeric data type constructors

2013-06-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 12.06.2013 07:32, Alexander Belopolsky wrote: > > Alexander Belopolsky added the comment: > > It looks like we a approaching consensus on some points: > > 1. Mixed script numerals should be disallowed. > 2. '\N{MINUS SIGN}' should be accepted as an alte