[issue23566] RFE: faulthandler.register() should support file descriptors

2015-03-10 Thread Wei Wu
Wei Wu added the comment: Attached a patch to this issue. Made some changes to faulthandler_get_fileno to accept integer as fd. If a fd is provided, the file member of fatal_error struct is set NULL. An new test case is added and some common testing code is also changed in order to be

[issue23624] str.center inconsistent with format ^

2015-03-10 Thread Vedran Čačić
Vedran Čačić added the comment: We can make a poll, I think it is quite obvious. But that's not really the point. I would accept the solution enabling _both_ methods of rounding with _both_ methods of formatting (it isn't even very hard to do: .center can take additional argument, mandatory

[issue16200] Setting .posix=True for shlex object causes infinite loop in __next__

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: There are 18 public writable attributes in shlex object, and unthinking setting some of them can make shlex to produce incorrect results or create an infinite loop. For example there is nothing to prevent your from setting the eof attribute. Only 14 of 18

[issue23624] str.center inconsistent with format ^

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The behavior of Python 2.7 is the same as Python 3.x. str.center() is very old method and changing it will change formatted reports generated by third-party software in all world. At least this will break many tests. And this will add yet one

[issue23624] str.center inconsistent with format ^

2015-03-10 Thread Vedran Čačić
Vedran Čačić added the comment: By that line of reasoning, we would probably never change anything. :-( I searched the documentation, and the exact behaviour isn't documented anywhere. In fact all examples are of the kind where there is an even number of fill chars. I thought it was ok to

[issue23088] Document that PyUnicode_AsUTF8() returns a null-terminated string

2015-03-10 Thread Martin Panter
Martin Panter added the comment: Posting a new patch that says that the NUL is always appended for both Unicode and Bytes, and explicitly says that internal NULs are allowed. -- Added file: http://bugs.python.org/file38420/utf8-null.v2.patch ___

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset f805fdacdfe0 by Victor Stinner in branch 'default': Issue #23605: os.walk() now calls os.scandir() instead of os.listdir(). https://hg.python.org/cpython/rev/f805fdacdfe0 -- nosy: +python-dev ___ Python

[issue23088] Document that PyUnicode_AsUTF8() returns a null-terminated string

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: There are other functions that returns null terminated data: PyByteArray_AsString(), PyBytes_AsStringAndSize(), PyUnicode_AS_UNICODE(), PyUnicode_AsUCS4Copy() PyUnicode_AsUnicode(), PyUnicode_AsUnicodeAndSize(), PyUnicode_AsWideCharString() and may be more.

[issue9731] Add ABCMeta.has_methods and tests that use it

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What if abstract class contains not only abstract methods, but default implementation of some methods? Should the predicate test if tested class contain these methods? For example, the Sequence ABC contains default implementation of __iter__. Should the

[issue23625] load_module() docs: zipped eggs are not loaded.

2015-03-10 Thread Thomas Güttler
New submission from Thomas Güttler: Please update the docs of imp.find_module() https://docs.python.org/2/library/imp.html#imp.find_module zipped egg files in sys.path are not found. Please provide a link how to find modules in sys.path like the interpreter does (with support of zipped egg

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2015-03-10 Thread Ben Hoyt
Ben Hoyt added the comment: Hi Victor. I'm attaching a patch to the What's New doc. I know it's a minor thing, but I really read the What's New in Python x.y page whenever it comes out, so making this as specific as possible is good. The changes are: 1. Be more specific and flesh it out

[issue23491] PEP 441 - Improving Python Zip Application Support

2015-03-10 Thread Paul Moore
Paul Moore added the comment: Steve Dower - could you please review the updated patch here. The WiX changes specifically are intended to register the .pyz extension with the launcher, but I can see no code that does this for a per-user install. I've copied the same code for the .py extension

[issue23187] Segmentation fault, possibly asyncio related

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: I'm not sure where to post this as the issue is closed: Please open a new issue. I've encountered the same problem. Why do you consider that it's the same issue? The crash seems to occur at random, with anything between 1 and 20 days separating

[issue23624] str.center inconsistent with format ^

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The problem is that it is not *obvious* what method is more correct. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23624 ___

[issue23566] RFE: faulthandler.register() should support file descriptors

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: @kilowu: Thanks, I reviewed your patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23566 ___ ___

[issue20659] Want to make a class method a property by combining decorators

2015-03-10 Thread Nick Coghlan
Nick Coghlan added the comment: To get the behaviour you're requesting, you need to use a custom metaclass and define the property there. The reason is that the descriptor machinery is bypassed entirely when setting or deleting an attribute on the class itself: class Example: ...

[issue23624] str.center inconsistent with format ^

2015-03-10 Thread Eric V. Smith
Eric V. Smith added the comment: I agree it would be nice to be consistent, and that str.__format__'s approach is likely the desirable one. But is it worth the breakage? Surely someone cares about the current behavior. Does this cause any practical, real-world problem? --

[issue23491] PEP 441 - Improving Python Zip Application Support

2015-03-10 Thread Paul Moore
Paul Moore added the comment: There's a problem with the latest patch, it's lost the MSI updates somehow. I'll add them back in this evening, please don't commit before a v6 patch is available, -- ___ Python tracker rep...@bugs.python.org

[issue23088] Document that PyUnicode_AsUTF8() returns a null-terminated string

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, and for agreement with Victor. ;-) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23088 ___ ___

[issue23088] Document that PyUnicode_AsUTF8() returns a null-terminated string

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: Serhiy Storchaka added the comment: And for consistency with all other documentation this should be written as null byte/character, not NUL. Agreed! -- ___ Python tracker rep...@bugs.python.org

[issue23187] Segmentation fault, possibly asyncio related

2015-03-10 Thread Michael Goldish
Michael Goldish added the comment: I'm not sure where to post this as the issue is closed: I've encountered the same problem. I don't have a stack trace to share at the moment but I know it's almost (or entirely) identical. My context: - Windows - Happens with Python 3.4.2 and 3.4.3 (and

[issue23432] Duplicate content in SystemExit documentation

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 64c0b4aead0f by Berker Peksag in branch '3.4': Issue #23432: Remove duplicate content from SystemExit docs. https://hg.python.org/cpython/rev/64c0b4aead0f New changeset 5163fb8dc61f by Berker Peksag in branch 'default': Issue #23432: Remove

[issue23432] Duplicate content in SystemExit documentation

2015-03-10 Thread Berker Peksag
Berker Peksag added the comment: Thanks for the review, Martin. -- resolution: - fixed stage: patch review - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23432

[issue20613] Wrong line information in bytecode generated by compiler module

2015-03-10 Thread Mark Lawrence
Changes by Mark Lawrence breamore...@yahoo.co.uk: -- nosy: +benjamin.peterson, brett.cannon, georg.brandl, ncoghlan ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20613 ___

[issue21574] Port image types detections from PIL to the imghdr module

2015-03-10 Thread Andriy Sokolovskiy
Andriy Sokolovskiy added the comment: @Claudiu Popa, IIRC I did not add 1-2 test images because I not found how to make image or how to convert image to this format. So, if there will no chance to add them, should we remove these formats from the patch? --

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8d76dabd40f6 by Victor Stinner in branch 'default': Issue #22524: Rephrase scandir addition in What's New in Python 3.5 https://hg.python.org/cpython/rev/8d76dabd40f6 -- ___ Python tracker

[issue15582] Enhance inspect.getdoc to follow inheritance chains

2015-03-10 Thread Nick Coghlan
Nick Coghlan added the comment: Serhiy's patch looks good to me. I'd completely missed that __qualname__ could be used to avoid needing a second argument even when handling objects other than bound methods. That's very cool, and I can see why you figured it was easier to just write the patch

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2015-03-10 Thread Ben Hoyt
Ben Hoyt added the comment: Thanks. Will do! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22524 ___ ___ Python-bugs-list mailing list

[issue23626] Windows per-user install of 3.5a2 doesn't associate .py files with the new launcher

2015-03-10 Thread Paul Moore
New submission from Paul Moore: Installing Python 3.5a2 with the 64-bit Windows installer using a user-level install doesn't associate .py files with the new (3.5) version of the launcher. I encountered this when there was an existing system install of Python 3.4, so .py files remained

[issue23138] cookiejar parses cookie value as int with empty name-value pair and Expires

2015-03-10 Thread Demian Brecht
Changes by Demian Brecht demianbre...@gmail.com: -- stage: patch review - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23138 ___

[issue23628] See if os.scandir() could help speed up importlib

2015-03-10 Thread Brett Cannon
New submission from Brett Cannon: With os.scandir() now committed and implemented in C, it would be interesting to see if os.scandir() could provide any performance benefit to importlib. If finders can pass the DirEntry to loaders then some stat calls could potentially be saved at the expense

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: My suggestion to add a new walk_dirs list is wrong: os.walk() documentation explicitly says that the dirs list can be modified to delete some directories: https://docs.python.org/dev/library/os.html#os.walk When topdown is True, the caller can modify the

[issue23491] PEP 441 - Improving Python Zip Application Support

2015-03-10 Thread Steve Dower
Steve Dower added the comment: The whole installer is run with a different global flag depending on the type of install. So it's automatic, though sometimes you can't do both per-user and all-user changes at the same time (not that you should anyway). --

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 50e32059a404 by Victor Stinner in branch '3.4': Issue #23605: os.walk() doc now mentions shutil.rmtree() in the last example https://hg.python.org/cpython/rev/50e32059a404 -- ___ Python tracker

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: 2015-03-10 12:36 GMT+01:00 Ben Hoyt rep...@bugs.python.org: I intend to do some review of the scandir/DirEntry docs as well. I'll send those in the next few days. Open maybe a new issue if you want to enhance the doc. --

[issue23491] PEP 441 - Improving Python Zip Application Support

2015-03-10 Thread Paul Moore
Paul Moore added the comment: OK, so if the installer changes look good to you, then this PR is once again ready to go. Sorry to anyone watching for the glitch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23491

[issue23627] Incorrect string formatting of float values in Python 2.7

2015-03-10 Thread pushpendre rastogi
New submission from pushpendre rastogi: Hi, The string formatting module in python 2.7 incorrectly formats floating point values. The following code shows the problem print %.10s%(-7.7176718e-05) -7.7176718 print %.10s%(-0.771767) -7.71767e- Ideally the code should have thrown an

[issue23571] Raise SystemError if a function returns a result with an exception set

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 52c7017fdcdd by Victor Stinner in branch 'default': Issue #23571: Oops, fix #ifdef assert() https://hg.python.org/cpython/rev/52c7017fdcdd -- ___ Python tracker rep...@bugs.python.org

[issue7803] setup hangs on disk space requirements

2015-03-10 Thread Mark Lawrence
Mark Lawrence added the comment: @Steve can you close this please. -- nosy: +BreamoreBoy, steve.dower type: - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7803 ___

[issue14285] Traceback wrong on ImportError while executing a package

2015-03-10 Thread Martin Panter
Martin Panter added the comment: Closely related: Issue 19771, which seems to be complaining about a the error message when __main__.py generates an ImportError. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14285

[issue23631] 3.5 (a2) traceback regression snarls Idle

2015-03-10 Thread Guido van Rossum
Guido van Rossum added the comment: Yeah, the stack track makes me suspect http://bugs.python.org/issue17911 -- nosy: +gvanrossum ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23631 ___

[issue23633] Improve py launcher help, index, and doc

2015-03-10 Thread Steve Dower
Steve Dower added the comment: For point 4, there's no code in either the 3.5 or the 3.4 (AFAIK) installer that would remove a py.ini file. From 3.5 onwards the py(w).exe files will be properly refcounted so the latest version is always installed regardless of order (i.e. 3.6 will update

[issue17911] traceback: add a new thin class storing a traceback without storing local variables

2015-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: Idle is partially disabled in a2 (#23633), with symptoms similar to that of the first example in msg237230. Trivial test: open Idle Shell, enter '1/0'. If this is not fixed before .a3, I think it should be reverted until it is. -- nosy: +terry.reedy

[issue23633] Improve py launcher help, index, and doc

2015-03-10 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- Removed message: http://bugs.python.org/msg237839 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23633 ___

[issue23635] Python won't install correctly.

2015-03-10 Thread Steve Dower
Steve Dower added the comment: (This doesn't affect 3.5) My guess is the missing ensurepip module is the problem. See if you can Repair the original install and then remove it. -- versions: -Python 3.5 ___ Python tracker rep...@bugs.python.org

[issue23623] Python 3.5 docs need to clarify how to set PATH, etc

2015-03-10 Thread Steve Dower
Steve Dower added the comment: Planned is a bit strong - in need of some simultaneous time and motivation :) Thanks for the upvote. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23623

[issue23633] Improve py launcher help, index, and doc

2015-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: The faulty patch for #17911 is a possible, perhaps probably cause (Guido, email). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23633 ___

[issue23486] Enum member lookup is 20x slower than normal class attribute lookup

2015-03-10 Thread Larry Hastings
Larry Hastings added the comment: My inclination is 3.5 only. Barry, do you want to argue for this going into 3.4? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23486 ___

[issue23636] Add scgi to urllib.parse.uses_netloc

2015-03-10 Thread Anthony Ryan
New submission from Anthony Ryan: The scgi protocol is not included in urllib.parse.uses_netloc list, while other less common protocols are (such as gopher). I would like to see scgi get added to this list. -- components: Library (Lib) files: py3bug messages: 237831 nosy: Anthony Ryan

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: My first note was about efficiency of the implementation. When followlinks is true, you can avoid testing entry.is_link() and creating the symlinks set. The new implementation of os.walk() changes a behavior. The problem is that a symlink to a directory can

[issue23606] ctypes.util.find_library(c) no longer makes sense

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 86c9ef950288 by Steve Dower in branch 'default': Issue #23606: Disable ctypes.util.find_library(c) on Windows so tests are skipped while we figure out how best to approach the CRT change https://hg.python.org/cpython/rev/86c9ef950288 --

[issue23615] Reloading tokenize breaks tokenize.open()

2015-03-10 Thread Thomas Kluyver
Thomas Kluyver added the comment: Patch attached to fix this. -- keywords: +patch Added file: http://bugs.python.org/file38423/tokenize-reloadable.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23615

[issue23496] Steps for Android Native Build of Python 3.4.2

2015-03-10 Thread Stefan Krah
Changes by Stefan Krah ste...@bytereef.org: -- nosy: -skrah ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23496 ___ ___ Python-bugs-list mailing

[issue11726] clarify that linecache only works on files that can be decoded successfully

2015-03-10 Thread Thomas Kluyver
Thomas Kluyver added the comment: First attempt at describing this attached. -- keywords: +patch Added file: http://bugs.python.org/file38424/linecache-encoding-doc.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11726

[issue23615] Reloading tokenize breaks tokenize.open()

2015-03-10 Thread Thomas Kluyver
Thomas Kluyver added the comment: -B.patch as Serhiy suggests, for tokenize only for the time being. -- Added file: http://bugs.python.org/file38425/tokenize-reloadable-B.patch ___ Python tracker rep...@bugs.python.org

[issue19610] setup.py does not allow a tuple for classifiers

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think it should include other list fields if we don't want to open separate issues for every list field. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19610

[issue23595] Split the math module into _math (C) + math (py)

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: Ok, fair enough, I abandon my change. I agree that a partial implementation of math.py (only a few functions) is not useful. To implement more math functions, struct and ctypes modules are probably needed. But it sounds overkill, since CPython already has a

[issue23629] Default __sizeof__ is wrong for var-sized objects

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Good catch! How it worked before? Now we can remove __sizeof__ implementations for tuples and bytes. Could you please add sizeof test for PyStructSequence types? -- ___ Python tracker rep...@bugs.python.org

[issue23496] Steps for Android Native Build of Python 3.4.2

2015-03-10 Thread Cyd Haselton
Cyd Haselton added the comment: Dog just died unexpectedly, behind on photograph project, need to start on Python tutorial, have a chat in a different language on Sunday I need to prep for and its patch day tomorrow. So yeah. Completely understand. --

[issue15443] datetime module has no support for nanoseconds

2015-03-10 Thread Anand B Pillai
Changes by Anand B Pillai abpil...@gmail.com: -- nosy: +pythonhacker ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15443 ___ ___ Python-bugs-list

[issue23496] Steps for Android Native Build of Python 3.4.2

2015-03-10 Thread Ryan Gonzalez
Ryan Gonzalez added the comment: Ok, please bear with me. I'm going to be REALLY busy for a bit; I have a BIG test/exam coming up next week, a music recital shortly afterwards, and lots of stuff/studying in between. Sorry for any delays! -- ___

[issue7803] setup hangs on disk space requirements

2015-03-10 Thread Steve Dower
Changes by Steve Dower steve.do...@microsoft.com: -- resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7803 ___

[issue23606] ctypes.util.find_library(c) no longer makes sense

2015-03-10 Thread Steve Dower
Steve Dower added the comment: That change should get the buildbots passing again, as it will now skip those tests. The appcrt%d return value was blatantly incorrect anyway. -- ___ Python tracker rep...@bugs.python.org

[issue23629] Default __sizeof__ is wrong for var-sized objects

2015-03-10 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- versions: +Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23629 ___ ___ Python-bugs-list

[issue23636] Add scgi to urllib.parse.uses_netloc

2015-03-10 Thread Martin Panter
Martin Panter added the comment: See also Issue 16134 for adding RTMP schemes to the registry. However, I wonder if it is time for a more general fix, rather than having an arms race with whatever URL scheme someone dreams up next. According to Issue 7904, urlsplit() etc intentially support

[issue1722348] urlparse.urlunparse forms file urls incorrectly

2015-03-10 Thread Martin Panter
Martin Panter added the comment: I believe this was closed incorrectly. The original test case includes four slashes, not three, and still fails in 3.5. However Issue 23505 has been opened in the mean time which should cover this. -- nosy: +vadmium resolution: works for me - duplicate

[issue23636] Add scgi to urllib.parse.uses_netloc

2015-03-10 Thread Anthony Ryan
Changes by Anthony Ryan anthonyry...@gmail.com: Added file: http://bugs.python.org/file38435/py2bug ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23636 ___

[issue17911] traceback: add a new thin class storing a traceback without storing local variables

2015-03-10 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- Removed message: http://bugs.python.org/msg237840 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17911 ___

[issue23633] Improve py launcher help, index, and doc

2015-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: (Whoops, unlinked misplaced message.) I will add py.ini *again* and watch more carefully before and after further installs. The problem with the doc is that it does not say where the py.ini file should go, and it inherently cannot because the locations are

[issue23636] Add scgi to urllib.parse.uses_netloc

2015-03-10 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- nosy: +orsenthil ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23636 ___ ___ Python-bugs-list mailing list

[issue22928] HTTP header injection in urrlib2/urllib/httplib/http.client

2015-03-10 Thread Martin Panter
Martin Panter added the comment: I much prefer the new patch with better compatibility and flexibility :) If you want to strengthen the tests to reflect some of the decisions made here you could add the following tests: Positive tests: * putheader('C1-Control', b'next\x85line') *

[issue17911] traceback: add a new thin class storing a traceback without storing local variables

2015-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: (correct new issue #) Idle is partially disabled in a2 (#23631), with symptoms similar to that of the first example in msg237230. Trivial test: open Idle Shell, enter '1/0'. If this is not fixed before .a3, I think it should be reverted until it is.

[issue23566] RFE: faulthandler.register() should support file descriptors

2015-03-10 Thread Wei Wu
Wei Wu added the comment: @haypo: Thank you for your review. I attached an updated patch addressing the review comments. In addition, I also added a change note in Misc/NEWS. -- Added file: http://bugs.python.org/file38436/issue23566_update.patch

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-10 Thread STINNER Victor
STINNER Victor added the comment: Serhiy Storchaka added the comment: When followlinks is true, symlinks is not needed. Hum, it's not easy to understand your code. I guess that the problem is that a symlink to a directory can become something else (not a directory or a symlink to a directory).

[issue23627] Incorrect string formatting of float values in Python 2.7

2015-03-10 Thread Eric V. Smith
Eric V. Smith added the comment: By using %s, you're asking the formatting code to first convert the parameter to a string. Then, by using .10, you're asking it to truncate the value. It's essentially equivalent to: str(-7.7176718e-05) '-7.7176718e-05' str(-7.7176718e-05)[:10] '-7.7176718'

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: When followlinks is true, symlinks is not needed. But I this commit breaks a code like following: def unsymlink(top): for root, dirs, files in os.walk(top): for name in dirs: path = os.path.join(root, name) if

[issue23606] ctypes.util.find_library(c) no longer makes sense

2015-03-10 Thread Steve Dower
Steve Dower added the comment: Good question, I'm not sure. Right now, the api-* DLLs use forwarding rather than apisetschema, but that could change. Since they support back to XP though, I suspect it probably won't the api-* DLLs will stay as they are with ucrtbase exporting ordinals rather

[issue23629] Default __sizeof__ is wrong for var-sized objects

2015-03-10 Thread Antoine Pitrou
New submission from Antoine Pitrou: In the stdlib, this only appears with the memoryview object, but third-party types can be affected. Attaching patch. -- components: Interpreter Core messages: 237776 nosy: pitrou, serhiy.storchaka, skrah priority: normal severity: normal stage: patch

[issue23629] Default __sizeof__ is wrong for var-sized objects

2015-03-10 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- keywords: +patch Added file: http://bugs.python.org/file38422/sizeof_var_obj.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23629 ___

[issue22028] Python 3.4.1 Installer ended prematurely (Windows msi)

2015-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 7c4c4e43c452 by Steve Dower in branch '2.7': Issue #22028: Ensure mimetypes will not open registry keys with embedded nulls https://hg.python.org/cpython/rev/7c4c4e43c452 -- nosy: +python-dev ___ Python

[issue19909] Best practice docs for new SSL features

2015-03-10 Thread Christian Heimes
Christian Heimes added the comment: I'm closing the reminder ticket. Thanks! -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19909 ___

[issue18620] multiprocessing page leaves out important part of Pool example

2015-03-10 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +jnoller, sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18620 ___ ___

[issue15443] datetime module has no support for nanoseconds

2015-03-10 Thread mdcb
mdcb added the comment: Intention of the patch was to keep it simple and limited to nanoseconds (per the report). Throwing in Decimal would work (and possibly bring further precision) but consider: datetime.fromnanoseconds(ns) vs datetime.fromtimestamp(Decimal(ts)) I find the former

[issue15443] datetime module has no support for nanoseconds

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Pickling is not backward compatible. I.e. older versions of Python couldn't unpickle datetime pickled in new Python. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15443

[issue21574] Port image types detections from PIL to the imghdr module

2015-03-10 Thread Anand B Pillai
Changes by Anand B Pillai abpil...@gmail.com: -- nosy: +pythonhacker ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21574 ___ ___ Python-bugs-list

[issue23607] Inconsistency in datetime.utcfromtimestamp(Decimal)

2015-03-10 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- stage: needs patch - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23607 ___ ___

[issue23630] support multiple hosts in create_server/start_server

2015-03-10 Thread Guido van Rossum
Guido van Rossum added the comment: This makes some sense, but it's easy to work around -- just call create_server() multiple times, once for each host. Why does that not work for you? -- ___ Python tracker rep...@bugs.python.org

[issue23630] support multiple hosts in create_server/start_server

2015-03-10 Thread Sebastien Bourdeauducq
Sebastien Bourdeauducq added the comment: That could work, but I would have to manually resolve and filter the lists of hostnames so that the program does not attempt to bind the same address twice - something that is better implemented in create_server, which already does the hostname

[issue23630] support multiple hosts in create_server/start_server

2015-03-10 Thread Guido van Rossum
Guido van Rossum added the comment: So it sounds like you already have a patch in mind... Can you work on it and upload it? (It's open source -- you get to make it yourself. :-) -- ___ Python tracker rep...@bugs.python.org

[issue23615] Reloading tokenize breaks tokenize.open()

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. -- stage: - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23615 ___ ___ Python-bugs-list

[issue23630] support multiple hosts in create_server/start_server

2015-03-10 Thread Sebastien Bourdeauducq
Sebastien Bourdeauducq added the comment: See attached. -- keywords: +patch Added file: http://bugs.python.org/file38428/asyncio_multibind.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23630

[issue23607] Inconsistency in datetime.utcfromtimestamp(Decimal)

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The fix for Python implementation LGTM, but a fix for C implementation is needed too. -- stage: patch review - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23607

[issue23615] Reloading tokenize breaks tokenize.open()

2015-03-10 Thread Thomas Kluyver
Thomas Kluyver added the comment: Fixed the other three cases you pointed out (-B2.patch). -- Added file: http://bugs.python.org/file38426/tokenize-reloadable-B2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23615

[issue21779] test_multiprocessing_spawn fails when ran with -Werror

2015-03-10 Thread Davin Potts
Davin Potts added the comment: Attaching patch for both 3.4 and default/3.5 (single file works for both) which fixes the test to properly adjust for running under -Werror. Whether -Werror is set or otherwise the equivalent of 'warnings.simplefilter(error, Warning)' has been set, any warnings

[issue21779] test_multiprocessing_spawn fails when ran with -Werror

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Wouldn't the test fail with -Werror::ResourceWarning or like? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21779 ___

[issue21779] test_multiprocessing_spawn fails when ran with -Werror

2015-03-10 Thread Davin Potts
Davin Potts added the comment: Yes, setting -Werror::ResourceWarning would indeed cause the test to fail again. A couple of options we could potentially adopt: 1. Decide to ignore anything extra in the file anytime any kind of error filterwarning is present. 2. Decide to ignore anything extra

[issue23192] Generator return value ignored in lambda function

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Could you please add a test based on Chris's example? And it would be good to add a test for a lambda with yield from. -- assignee: - serhiy.storchaka stage: - test needed ___ Python tracker

[issue21779] test_multiprocessing_spawn fails when ran with -Werror

2015-03-10 Thread Davin Potts
Changes by Davin Potts pyt...@discontinuity.net: -- stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21779 ___ ___

[issue23629] Default __sizeof__ is wrong for var-sized objects

2015-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ah, tests for PyStructSequence types already exist (tests for sys.flags and sys.float_info). The patch LGTM. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23629

[issue23606] ctypes.util.find_library(c) no longer makes sense

2015-03-10 Thread eryksun
eryksun added the comment: Will manual forwarding eventually be replaced by the loader's ApiSetMap (in the process PEB), i.e. will ucrtbase join ntdll, sechost, kernelbase, and kernel32 in apisetschema.dll? In this case will the CRT API sets only exist in winsxs, i.e. will they no longer be

  1   2   >