[issue23951] Update devguide style to use a similar theme as Docs

2016-06-29 Thread Lisa Roach
Lisa Roach added the comment: I have updated the conf.py and added a "tools" folder that contains the themes, templates, etc. to make the devguide match more closely with the pydoctheme. I altered the theme a little bit to keep the colors more consistent with the original devguide, hopefully

[issue1732367] Document the constants in the socket module

2016-06-29 Thread Mark Lawrence
Changes by Mark Lawrence : -- nosy: -BreamoreBoy ___ Python tracker ___ ___

[issue27413] Add an option to json.tool to bypass non-ASCII characters.

2016-06-29 Thread Wei-Cheng Pan
Wei-Cheng Pan added the comment: If the arguments should be aligned with those in dump/load, then maybe "--no-ensure-ascii" is an option? -- ___ Python tracker

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Mark Hammond
Mark Hammond added the comment: I've a few reservations here: * CoInitialize will load a number of COM DLLs into the process, which isn't free and will have some memory and performance costs for programs that don't use COM. I see around 10 such DLLs loaded. * pythoncom uses sys.coinit_flags

[issue27418] Tools/importbench/importbench.py is broken

2016-06-29 Thread Brett Cannon
Brett Cannon added the comment: I don't see anything obviously wrong with it. -- ___ Python tracker ___ ___

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Steve Dower
Steve Dower added the comment: > pythoncom and comtypes use the value of sys.coinit_flags when imported Good to know. Assume we'll add that as well. Also, with respect to threading, we'd want to initialize on all new threads too. That will require a way to specify that a new thread should be

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Steve Dower
Steve Dower added the comment: I'm also okay to discuss whether MTA or STA should be the default, but I'll also be seeking advice from work colleagues on this who know COM really well. -- ___ Python tracker

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Steve Dower
Steve Dower added the comment: > But do I understand correctly that, if you implement this, there's no way for > me to select MTA? MTA would be the default, with no -X argument. But we could support a no-op "-X:MTA" as well. Because of the potential for use in security features, I don't want

[issue27418] Tools/importbench/importbench.py is broken

2016-06-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Following patch seems fixes importbench. -- keywords: +patch stage: -> patch review Added file: http://bugs.python.org/file43583/importbench.patch ___ Python tracker

[issue27418] Tools/importbench/importbench.py is broken

2016-06-29 Thread Brett Cannon
Brett Cannon added the comment: Feel free to do whatever you need/want to with the benchmark. I originally created it when switching __import__ to importlib to prove that it didn't impact performance. -- ___ Python tracker

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Eryk Sun
Eryk Sun added the comment: pythoncom and comtypes use the value of sys.coinit_flags when imported, and otherwise default to calling CoInitializeEx(NULL, COINIT_APARTMENTTHREADED). Setting this value should ease problems, but something like -X:STA is still necessary. Note that the launcher

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Tim Golden
Tim Golden added the comment: As it happens, all the code I use which calls CoInitialise[Ex] does so with STA. But do I understand correctly that, if you implement this, there's no way for me to select MTA? If so I would consider that a major drawback. --

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Steve Dower
Steve Dower added the comment: > If it allowed user code to access COM without needing a 3rd party dependency, > I'd be +1, but I don't think that's being proposed here. It's a prerequisite to adding features to the stdlib that access COM (whether or not COM is directly exposed to the user).

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Paul Moore
Paul Moore added the comment: Things I know that call CoInitialize - pywin32/pythoncom and comtypes. I assume the proposal is to call CoInitializeEx in a way that won't break those? I'm not sure I see how this would affect the user (i.e. Python code). Brett mentions detecting the user's

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: :) I'm not a fan of monkey patching code in production, unless the code I'm monkey patching is code I control. (And since releasing code now is a lot easier than it used to be, I have much less occasion to monkey-patch code I control.) (I'm a big fan of and am

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Yury Selivanov
Yury Selivanov added the comment: > Rather tham monkey-patching, in general I recommend just copying some code from the asyncio library and calling that. In this case you'd be copying a tiny bit of code from create_connection(). You'd still be calling an internal API, _make_ssl_transport(), but

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Guido van Rossum
Guido van Rossum added the comment: Rather tham monkey-patching, in general I recommend just copying some code from the asyncio library and calling that. In this case you'd be copying a tiny bit of code from create_connection(). You'd still be calling an internal API, _make_ssl_transport(), but

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Brett Cannon
Changes by Brett Cannon : -- nosy: +brett.cannon ___ Python tracker ___ ___

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Steve Dower
Steve Dower added the comment: It would enable wrapping up anything from this list too, and more: https://msdn.microsoft.com/en-us/library/windows/desktop/bb774328(v=vs.85).aspx Plenty of cool potential features in there :) -- ___ Python tracker

[issue27418] Tools/importbench/importbench.py is broken

2016-06-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Just now I'm writing a patch for optimizing __import__. Maybe importbench would be helpful. -- ___ Python tracker

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Brett Cannon
Brett Cannon added the comment: Steve has also told me this would enable querying the OS for what the default web browser is. -- ___ Python tracker ___

[issue27418] Tools/importbench/importbench.py is broken

2016-06-29 Thread Brett Cannon
Brett Cannon added the comment: If you don't have any use for it I say just delete the benchmark. -- ___ Python tracker ___

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: With SSL, the protocol is a little different clients and servers, although that may just be in the handshake. I'm no SSL expert by any means. When you call wrap_socket on an SSLContext, you can pass server_side, which defaults to False. If you get this wrong,

[issue27418] Tools/importbench/importbench.py is broken

2016-06-29 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: $ ./python Tools/importbench/importbench.py Traceback (most recent call last): File "Tools/importbench/importbench.py", line 8, in from test.test_importlib.source import util as source_util ImportError: cannot import name 'util' --

[issue26137] [idea] use the Microsoft Antimalware Scan Interface

2016-06-29 Thread Steve Dower
Steve Dower added the comment: This now depends on issue27417, since we can't enable AMSI without enabling COM, and doing that has a number of back-compat implications. -- dependencies: +Call CoInitializeEx on startup ___ Python tracker

[issue27417] Call CoInitializeEx on startup

2016-06-29 Thread Steve Dower
New submission from Steve Dower: I'd like to enable calling CoInitializeEx on Python startup for 3.6 (and into the future). See https://msdn.microsoft.com/en-us/library/windows/desktop/ms695279.aspx This would enable us to use more advanced Windows features within Python that require COM,

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Guido van Rossum
Guido van Rossum added the comment: Hm. The docs in PEP 3156 do mention that create_connection() is for clients (though it weakens this with "typically"): https://www.python.org/dev/peps/pep-3156/#internet-connections I always think of TCP connections (which is what create_connection() is

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Yury Selivanov
Yury Selivanov added the comment: > It also doesn't occur with uvloop, which I assume still uses sockets. No, uvloop doesn't use python sockets or select for IO at all. All IO is done in libuv. > WRT CPython/sockets this problem doesn't happen if I use asyncore to accept > connections and

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Guido van Rossum
Changes by Guido van Rossum : -- Removed message: http://bugs.python.org/msg269529 ___ Python tracker ___

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Guido van Rossum
Changes by Guido van Rossum : -- Removed message: http://bugs.python.org/msg269525 ___ Python tracker ___

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: WRT CPython/sockets this problem doesn't happen if I use asyncore to accept connections and hand them off to create_connection. :) It also doesn't occur with uvloop, which I assume still uses sockets. Also, FWIW, the relevant ZEO test passes if I use SSL, which

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Guido van Rossum
Guido van Rossum added the comment: No, I just don't have a computer right now, only a phone. --Guido (mobile) -- ___ Python tracker ___

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Yury Selivanov
Yury Selivanov added the comment: Running out of time to debug this today. I think this is a bug in CPython, in either socket or select module. When I inject some debug code in selectors.py and replace KQueue with select(), I can see that the server thread's selector stops working at some

[issue27416] typo / missing word in docs.python.org/2/library/copy.html

2016-06-29 Thread Paul Killey
Paul Killey added the comment: Ah, I see now -- your comment clarified it for me. Thanks. -- ___ Python tracker ___

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Yuri, right you are. Thanks. Марк, see https://bugs.launchpad.net/zodb/+bug/135108/comments/9 -- ___ Python tracker ___

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Sorry, ignore my last message -- ___ Python tracker ___ ___ Python-bugs-list

[issue27363] Complex numbers with negative zero imaginary parts do not roundtrip properly

2016-06-29 Thread ppperry
Changes by ppperry : -- title: Complex with negative zero imaginary part -> Complex numbers with negative zero imaginary parts do not roundtrip properly ___ Python tracker

[issue27410] DLL hijacking vulnerability in Python 3.5.2 installer

2016-06-29 Thread Jeremy Kloth
Changes by Jeremy Kloth : -- nosy: +jkloth ___ Python tracker ___ ___

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Yury Selivanov
Yury Selivanov added the comment: Jim, I think you wanted to post this link in this issue: https://bugs.launchpad.net/zodb/+bug/135108/comments/9 instead of in #27392. I can reproduce this on my mac, but so far I've no idea what's going on. -- ___

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: See: https://bugs.launchpad.net/zodb/+bug/135108/comments/9 Sorry, I should have sent that link sooner. In my flailing to come up with a simple case, I forgot the importance of that setting. -- ___ Python tracker

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: >> Yury, I'm curious what you think the socket argument to create_connection is >> about. > > :) The current intended purpose of create_connection is to create a client > connection. You're proposing to add a new argument -- server_side -- which I > think will

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Here's a version sans prints -- Added file: http://bugs.python.org/file43581/echo-no-print.py ___ Python tracker ___

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Марк Коренберг
Марк Коренберг added the comment: One more thing. Why you set socket.SO_LINGER ? and why lingering timeout is 0 seconds ? Removing that eliminate problem completely. -- ___ Python tracker

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Yury Selivanov
Yury Selivanov added the comment: > Yury, I'm curious what you think the socket argument to create_connection is > about. :) The current intended purpose of create_connection is to create a client connection. You're proposing to add a new argument -- server_side -- which I think will

[issue27416] typo / missing word in docs.python.org/2/library/copy.html

2016-06-29 Thread R. David Murray
R. David Murray added the comment: No, the text is correct. Perhaps it would be clearer if the 'even' were moved to the front of the phrase? "...it may copy too much, even data structures that should be shared between copies." -- nosy: +r.david.murray

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Jim Fulton
Changes by Jim Fulton : Removed file: http://bugs.python.org/file43540/echo.py ___ Python tracker ___

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Марк Коренберг
Марк Коренберг added the comment: Also I recommend you to use asyncio streams, instead of reinventing wheels. So, reading your command will look like: data = await stream.read_exactly(4) (len,) = unpack(">I", data) command = await stream.read_exactly(len) --

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: BTW, a problem with this proposal that I realized after submitting it is that it changes an API that has multiple implementations, including implementations outside of the Python codebase. Arguably, this would require a PEP, at which point the change is

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Yury, I'm curious what you think the socket argument to create_connection is about. -- ___ Python tracker ___

[issue27416] typo / missing word in docs.python.org/2/library/copy.html

2016-06-29 Thread Paul Killey
Paul Killey added the comment: I'm sorry, 'not' could be missing between 'should' and 'be' --- 'should not be shared' -- ___ Python tracker ___

[issue27416] typo / missing word in docs.python.org/2/library/copy.html

2016-06-29 Thread Paul Killey
New submission from Paul Killey: I wonder if the word 'not' is missing between 'that' and 'should' in this sentence in https://docs.python.org/2/library/copy.html? Because deep copy copies everything it may copy too much, e.g., administrative data structures that should be shared even between

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: OK, sure, I'll make a PR. -- ___ Python tracker ___ ___ Python-bugs-list

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: No need to apologize! My capitulation was just due to the fact that this isn't a big deal. (My tone probably came across as cranky; sorry) WRT backward compatibility, I suspect that there's a bit of wiggle here between loop implementations and I doubt this would

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread Yury Selivanov
Yury Selivanov added the comment: > SSL contexts, https://docs.python.org/3/library/ssl.html#ssl-contexts, have an attribute, check_hostname, which controls whether hostname checking is required. If set to false in a context passed to create_connection, then it makes no sense to require

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread R. David Murray
R. David Murray added the comment: Sorry, I've been having trouble communicating on this ticket. I thought I'd posetd an apology but I don't see it...I wonder where I did post it? Bad morning :(. Anyway, create_connection was what I was asking for. Reading the docs, I, at least, agree with

[issue27415] BaseEventLoop.create_server does not accept port=None

2016-06-29 Thread Marcus Cobden
New submission from Marcus Cobden: With the most recent 3.4 bugfix, calling create_server with port=None stopped working. This also affects 3.5, and I would imagine also 3.6, but haven't checked that. Test case: import asyncio; l = asyncio.get_event_loop();

[issue26686] email.parser stops parsing headers too soon when given a defective message.

2016-06-29 Thread ppperry
Changes by ppperry : -- title: email.parser stops parsing headers too soon. -> email.parser stops parsing headers too soon when given a defective message. ___ Python tracker

[issue27363] Complex with negative zero imaginary part

2016-06-29 Thread R. David Murray
R. David Murray added the comment: Ah, I haven't used Fractions and Decimal much, so I hadn't noticed. Those postdate complex, I think, but do follow the model Mark is suggesting. Seems like it would be reasonble to make complex do the same...the concern of course is backward compatibilty.

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Consider this a suggestion. Do with it what you will. I'm closing this as I don't want to spend more time on it other than creating a PR if requested. -- status: open -> closed ___ Python tracker

[issue27412] float('∞') returns 8.0

2016-06-29 Thread David Howlett
David Howlett added the comment: I am sorry about misattributing this bug and wasting your time. I have opened two new bugs against Komodo: https://github.com/Komodo/KomodoEdit/issues/1760 https://github.com/Komodo/KomodoEdit/issues/1759 They are looking into it. --

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: I'm not sure I understand your question. The documentation for create_connection, https://docs.python.org/3/library/asyncio-eventloop.html#creating-connections states that server_hostname is required if the host is empty. (I'm generalizing "empty" to include

[issue27414] http.server.BaseHTTPRequestHandler inconsistence with Content-Length value

2016-06-29 Thread R. David Murray
R. David Murray added the comment: Sorry once again for the infelicitous phrasing. I meant to say "sorry, what I was unclearly asking for was what you were calling that..." Too bad I don't drink coffee or I could blame it on not having had any yet today... --

[issue27414] http.server.BaseHTTPRequestHandler inconsistence with Content-Length value

2016-06-29 Thread R. David Murray
R. David Murray added the comment: For reference, the changeset that introduced that was ee34cb049a10. An interesting feature of that changset is the trace command in the test...I guess the wrong patch was comitted and no one noticed. The trace was obvious fixed but no one appears to have

[issue27363] Complex with negative zero imaginary part

2016-06-29 Thread Vedran Čačić
Vedran Čačić added the comment: ...but hopefully not the last. People are playing (with BDFL's blessing) with the idea of types having just (qual)name as str. By "first stdlib case" you mean "first builtin case", right? fractions.Fraction and decimal.Decimal are in stdlib. :-) Yes, not all

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread R. David Murray
R. David Murray added the comment: You still haven't told me what you are passing the context to that objects to not having server_hostname. I suppose the asyncio experts would know immediately, so I should probably just leave it to them...or wait for your PR. --

[issue27414] http.server.BaseHTTPRequestHandler inconsistence with Content-Length value

2016-06-29 Thread Xiang Zhang
Changes by Xiang Zhang : -- nosy: +ezio.melotti, pitrou, rhettinger ___ Python tracker ___

[issue27413] Add an option to json.tool to bypass non-ASCII characters.

2016-06-29 Thread R. David Murray
R. David Murray added the comment: Maybe name it --no-insure-ascii? Or --insure-ascii=no/yes. (or true/false). -- nosy: +r.david.murray ___ Python tracker

[issue12319] [http.client] HTTPConnection.request not support "chunked" Transfer-Encoding to send data

2016-06-29 Thread Rolf Krahl
Rolf Krahl added the comment: Here comes a new version of the patch. I believe, I addressed all review comments made on issue12319_7.patch, with the exception of the EncodingError mentioned in the last post. Most relevant changes compared to last patch: * Do not try to dertermine the

[issue27363] Complex with negative zero imaginary part

2016-06-29 Thread R. David Murray
R. David Murray added the comment: Right, that isn't the invariant. Eval is the normal invariant, but not all classes *can* meet it, in which case if they can provide a repr that *can* be turned back into the value losslessly somehow, that's better than not doing so at all. Still, changing

[issue27285] Document the deprecation of pyvenv in favor of `python3 -m venv`

2016-06-29 Thread R. David Murray
R. David Murray added the comment: In this case I think one patch is good. The deprecation should mention pyvenv in the main venv docs (and maybe installing), but probably nowhere else. See the deprecated-removed sphinx tag. -- nosy: +r.david.murray

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: I agree that if create_server (or asyncio.Server) is buggy, it should be fixed! However, IMO, it's useful to be able to accept a connection outside of an asyncio event loop and then hand the loop the connected socket. --

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Guido, IMO, there's value in having the ability to accept connections independently of handling them. It wasn't clear to me from reading the documentation that create_connection is only meant for making client connections, especially given that it can take an

[issue27392] Add a server_side keyword parameter to create_connection

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: Tests are also unstable with uvloop. (Although uvloop doesn't have http://bugs.python.org/issue27386 at least.) I was eventually able to wrestle the test into submission using asyncio.Server. I suspect that some of this had to do with issues closing connections

[issue27414] http.server.BaseHTTPRequestHandler inconsistence with Content-Length value

2016-06-29 Thread Mathieu Xhonneux
Mathieu Xhonneux added the comment: It's line 469 in the latest Lib/http/server.py (and not 473). -- ___ Python tracker ___

[issue27410] DLL hijacking vulnerability in Python 3.5.2 installer

2016-06-29 Thread Steve Dower
Steve Dower added the comment: Unless you can show that it's loaded after the installer elevates, I'm not concerned. "User can run arbitrary code as themselves" is not a security vulnerability. (Hint: when the bundle elevates, it copies the exe to a new directory and runs it from there to

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Марк Коренберг
Марк Коренберг added the comment: Plese reduce even more. I mean remove debugging, specifi commands, and all extra code, that is not related to original problem. -- ___ Python tracker

[issue27414] http.server.BaseHTTPRequestHandler inconsistence with Content-Length value

2016-06-29 Thread Mathieu Xhonneux
New submission from Mathieu Xhonneux: With Python 3.5, when I subclass SimpleHTTPRequestHandler, which itself subclasses BaseHTTPRequestHandler, and I try to access a non-existing file, the server responds with a 404 code, but send_error (see Lib/http/server.py, line 473) adds the

[issue27386] Asyncio server hang when clients connect and immediately disconnect

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: This is already pretty minimal. There are no external dependencies. -- ___ Python tracker ___

[issue27391] server_hostname should only be required when checking host names

2016-06-29 Thread Jim Fulton
Jim Fulton added the comment: It's not bug, it's a misfeature, IMO. If you pass an SSL context and either don't pass a hostname or pass an empty string, then server_hostname is required, even if check_hostname is false for the context. The fix is trivial. I'd be happy to provide a PR.

[issue27412] float('∞') returns 8.0

2016-06-29 Thread STINNER Victor
STINNER Victor added the comment: """ In the Komodo REPL I see the following behaviour: >>> '∞' '8' """ Ok, it's now obvious that the issue comes from Komodo REPL, not from Python. -- ___ Python tracker

[issue27412] float('∞') returns 8.0

2016-06-29 Thread Eryk Sun
Changes by Eryk Sun : -- resolution: -> third party stage: -> resolved status: open -> closed ___ Python tracker ___

[issue27412] float('∞') returns 8.0

2016-06-29 Thread David Howlett
David Howlett added the comment: I am using python 3.5 in a REPL in an IDE called Komodo running on Windows. After reading your comments I wrote the following python file: try: x = float('∞') except ValueError: print('Value error was correctly thrown') This throws a ValueError as you

[issue26844] Wrong error message during import

2016-06-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: __qualname__ itself is not much more informative than __name__. You should use it together with __module__ to get the full qualified name. But 1) it is never used in error messages, 2) the code becomes more verbose, 3) the output becomes more verbose, and

[issue27410] DLL hijacking vulnerability in Python 3.5.2 installer

2016-06-29 Thread Eryk Sun
Eryk Sun added the comment: > installer attempts to load DLLs from the current directory It's actually the application directory that's the culprit, not the current directory. All supported versions of Windows default to SafeDllSearchMode, which moves the current directory after system

[issue27412] float('∞') returns 8.0

2016-06-29 Thread STINNER Victor
STINNER Victor added the comment: On Windows, the ∞ character (U+221E) is replaced with the letter 8 (U+0038) by the WideCharToMultiByte() function for most code pages: http://unicodebook.readthedocs.io/operating_systems.html#encode-and-decode-functions Can you please describe how and where

[issue26721] Avoid socketserver.StreamRequestHandler.wfile doing partial writes

2016-06-29 Thread Martin Panter
Martin Panter added the comment: Committed for 3.6. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue27413] Add an option to json.tool to bypass non-ASCII characters.

2016-06-29 Thread Wei-Cheng Pan
New submission from Wei-Cheng Pan: This patch adds a command line option "--no-escape" that allows json.tool to display non-ASCII characters. e.g.: $ echo '"測試"' | python -m json.tool "\u6e2c\u8a66" $ echo '"測試"' | python -m json.tool --no-escape "測試" -- components: Library (Lib)

[issue27412] float('∞') returns 8.0

2016-06-29 Thread Eryk Sun
Eryk Sun added the comment: There's something wrong with however you're testing this. >>> s = '\N{infinity}' >>> s == '∞' == '\u221e' True '∞' isn't numeric. It's a math symbol (Sm): >>> unicodedata.category(s) 'Sm' >>> s.isdecimal() False >>> s.isdigit()

[issue27412] float('∞') returns 8.0

2016-06-29 Thread Ashwini Chaudhary
Ashwini Chaudhary added the comment: float('∞') raised ValueError as expected: ValueError: could not convert string to float: '∞' I am not sure how you ended up with 8.0. -- nosy: +ashwch ___ Python tracker

[issue26988] Add AutoNumberedEnum to stdlib

2016-06-29 Thread John Hagen
John Hagen added the comment: @Ethan/Barry what needs to be done now to accept or reject this for Python 3.6? Should I propose it onto python-dev? If accepted, would be nice to get it in before alpha 3 (~2 weeks). What's nice about this proposal is Ethan has already written the code, so

[issue27412] float('∞') returns 8.0

2016-06-29 Thread David Howlett
New submission from David Howlett: float('inf') returns a float with a value of inf float('∞') returns a float with a value of 8.0 I can't think of any justification for returning 8.0 other then ∞ looks like an 8 turned sideways. I believe float('∞') should return inf. -- components:

[issue26721] Avoid socketserver.StreamRequestHandler.wfile doing partial writes

2016-06-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4ea79767ff75 by Martin Panter in branch 'default': Issue #26721: Change StreamRequestHandler.wfile to BufferedIOBase https://hg.python.org/cpython/rev/4ea79767ff75 -- nosy: +python-dev ___ Python tracker

[issue27348] traceback (and threading) drops exception message

2016-06-29 Thread Martin Panter
Martin Panter added the comment: Yeah sure I can give you a chance to consider this (I assume you meant “chance” :). But neither of the tests I mentioned were added by you as far as I know. Maybe you are thinking of some other test. -- ___ Python

[issue27348] traceback (and threading) drops exception message

2016-06-29 Thread STINNER Victor
STINNER Victor added the comment: I agree that ignoring the exception message if str(exc) == 'None' is wrong. -- nosy: +haypo ___ Python tracker ___

[issue27348] traceback (and threading) drops exception message

2016-06-29 Thread Robert Collins
Robert Collins added the comment: hmm, can you give me a change to page this in? I'm pretty sure I saw breakage in external libraries prompting me to add the test and fix. I'd rather not recause that. -- ___ Python tracker

[issue27411] Possible different behaviour of explicit and implicit __dict__ accessing when involving builtin types' __dict__ descriptors

2016-06-29 Thread Xiang Zhang
New submission from Xiang Zhang: Usually when we access an object's __dict__, it will finally reach subtype_dict[0]. When involving builtin base, it may delegates to the base's __dict__ descriptor. In such a case, it is possible for the __dict__ descriptor to initialize the dict object if

[issue27348] traceback (and threading) drops exception message

2016-06-29 Thread Martin Panter
Martin Panter added the comment: If I remove the value == 'None' check, there are two failures in the test suite: 1. test_decimal fails, but only because the test was changed in revision 5f3dd0a2b1ab to accommodate the very bug I am complaining about. IMO this was a case of “fixing” the test

[issue27363] Complex with negative zero imaginary part

2016-06-29 Thread Vedran Čačić
Vedran Čačić added the comment: And of course, the most important argument that preserving type(x)(repr(x))==x is futile: try it with x=False. (Yes, bools are numbers too.:) On the other hand, of course, literal_eval treats 'False' completely fine. --

[issue26844] Wrong error message during import

2016-06-29 Thread Lev Maximov
Lev Maximov added the comment: Nevermind. It's not urgent but should definitely be fixed some day. Yes, __qualname__ might be a good idea. -- ___ Python tracker

[issue27410] DLL hijacking vulnerability in Python 3.5.2 installer

2016-06-29 Thread Christian Ullrich
Changes by Christian Ullrich : -- nosy: +Christian.Ullrich ___ Python tracker ___ ___

  1   2   >