[issue22055] Incomplete sentence in asyncio BaseEventLoop doc

2014-07-24 Thread Saimadhav Heblikar
Changes by Saimadhav Heblikar saimadhavhebli...@gmail.com: -- assignee: docs@python components: Documentation, asyncio files: asyncio-eventloop-doc-incomplete-sent.diff keywords: patch nosy: docs@python, gvanrossum, haypo, sahutd, yselivanov priority: normal severity: normal status:

[issue21580] PhotoImage(data=...) apparently has to be UTF-8 or Base-64 encoded

2014-07-24 Thread Terry J. Reedy
Terry J. Reedy added the comment: I will try test the problem and fix on Windows within a day. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21580 ___

[issue22052] Comparison operators called in reverse order for subclasses with no override.

2014-07-24 Thread Mark Dickinson
Mark Dickinson added the comment: the subclass provides doesn't actually imply anything about overriding, I think. Yes, that was the thrust of one of the SO answers. Unfortunately, that explanation doesn't work for arithmetic operators, though: there an explicit override is necessary.

[issue16733] Solaris ctypes_test failures

2014-07-24 Thread Mark Lawrence
Mark Lawrence added the comment: Only one Solaris box was online when I looked and that had passed ctypes tests, but surely this will have been sorted out by now? -- nosy: +BreamoreBoy versions: +Python 3.5 -Python 3.3 ___ Python tracker

[issue18643] add a fallback socketpair() implementation in test.support

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I don't remember why I added a specific check on the proto parameter. I tested on Windows: socket.socket(proto=1) raises an OSError(WSAEPROTONOSUPPORT): WSAEPROTONOSUPPORT 10043: Protocol not supported. The requested protocol has not been configured into

[issue21591] exec(a, b, c) not the same as exec a in b, c in nested functions

2014-07-24 Thread Dirkjan Ochtman
Dirkjan Ochtman added the comment: I came up with a patch that shifts the compatibility hack we have for the tuple form of exec from run-time (in exec_statement()) to the CST-to-AST transformation (in ast_for_exec_stmt()). It seems to pass the tests (including the ones Robert pasted in here).

[issue21591] exec(a, b, c) not the same as exec a in b, c in nested functions

2014-07-24 Thread Dirkjan Ochtman
Dirkjan Ochtman added the comment: Oh, one specific question: I'm not sure if I should free the old expr1 (the top-level exec value) before overwriting it with the new one. -- ___ Python tracker rep...@bugs.python.org

[issue18643] add a fallback socketpair() implementation in test.support

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: By the way, we should reuse socket.socketpair() in asyncio.windows_utils. The Tulip is written for Python 3.3 and shares exactly the same code base, so you should write Something like: if hasattr(socket, 'socketpair'): socketpair =

[issue19875] test_getsockaddrarg occasional failure

2014-07-24 Thread Mark Lawrence
Mark Lawrence added the comment: Clearly the long term solution is to fix the problems in the cpython code referenced in msg205227, but in the short term is it worth attempting a work around as suggested in msg205131 ? -- nosy: +BreamoreBoy ___

[issue22055] Incomplete sentence in asyncio BaseEventLoop doc

2014-07-24 Thread Andrew Svetlov
New submission from Andrew Svetlov: Fixed in f578e1d717b7 and f578e1d717b7. Thanks. -- nosy: +asvetlov resolution: - fixed stage: - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22055

[issue18643] add a fallback socketpair() implementation in test.support

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: 2014-07-24 10:11 GMT+02:00 Charles-François Natali rep...@bugs.python.org: Please also fix socketpair() in asyncio to add the while/drop unknown connection (well, the function in socket.py and windows_utils.py must be the same). That's a separate issue.

[issue20055] On Windows NT 6 with administrator account, there are two failing tests on test_shutil.py

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset 84f26a437893 by Victor Stinner in branch '3.4': Issue #20055: Fix BaseEventLoop.stop() docstring, incomplete sentence. http://hg.python.org/cpython/rev/84f26a437893 New changeset f657b64c67ab by Victor Stinner in branch 'default': (Merge 3.4) Issue

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I don't understand this. If you're ok with calling fileno() under Linux, why not under Windows? I propose to add set_wakeup_socket() for all platforms. This function doesn't really call the fileno() method, it gets the socket file descriptor/socket handle

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0177d8a4e82a by Victor Stinner in branch '2.7': Issue #19884: readline: Disable the meta modifier key if stdout is not a http://hg.python.org/cpython/rev/0177d8a4e82a New changeset 6303266beb80 by Victor Stinner in branch '3.4': Issue #19884:

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I commited my patch. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19884 ___

[issue21813] Enhance doc of os.stat_result

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset 833325d45113 by Victor Stinner in branch '3.4': Issue #21813: Enhance documentation of the os.stat_result class. http://hg.python.org/cpython/rev/833325d45113 New changeset 5d70ac83d104 by Victor Stinner in branch 'default': Issue #21813: Enhance

[issue21813] Enhance doc of os.stat_result

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: Thanks Zachary Ware for your review. I'm not sure that I addressed all your comments, but I'm not interested to spend too much time on the documentation. Please open an issue if your saw other things that can be improved. -- resolution: - fixed

[issue1191964] add non-blocking read and write methods to subprocess.Popen

2014-07-24 Thread akira
akira added the comment: STINNER Victor rep...@bugs.python.org writes: I have implemented and would continue to lean towards continuing to hide BrokenPipeError on the additional API endpoints. FYI asyncio.Process.communicate() ignores BrokenPipeError and ConnectionResetError, whereas

[issue1191964] add non-blocking read and write methods to subprocess.Popen

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: Do Popen.write_nonblocking() and Popen.read_nonblocking() methods belong to the second category? Should they raise BrokenPipeError? IMO when you write directly to stdin and read from stdout/stderr of a child process, your code should be written to handle

[issue13533] Would like Py_Initialize to play friendly with host app

2014-07-24 Thread Yukihiro Nakadaira
Yukihiro Nakadaira added the comment: This problem easily happen when there is no python installation and there is standalone python application compiled with py2exe or cx_Freeze (e.g. Mercurial). Such application have pythonXX.dll in its directory. But its python library can not be loaded

[issue5718] Problem compiling ffi part of build on AIX 5.3.

2014-07-24 Thread David Edelsohn
David Edelsohn added the comment: ffi_closure_helper_DARWIN should have been declared extern in the assembly file. This has been fixed in more recent versions of libffi and imported into more recent versions of CPython, including 2.7. .extern .ffi_closure_helper_DARWIN Is it worth updating

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le 24/07/2014 06:00, STINNER Victor a écrit : STINNER Victor added the comment: I don't understand this. If you're ok with calling fileno() under Linux, why not under Windows? I propose to add set_wakeup_socket() for all platforms. That's not what I'm

[issue5718] Problem compiling ffi part of build on AIX 5.3.

2014-07-24 Thread Stefan Krah
Stefan Krah added the comment: Thanks, David. If this is fixed in 2.7 we can close the issue. -- nosy: +skrah resolution: - out of date stage: needs patch - resolved status: open - closed ___ Python tracker rep...@bugs.python.org

[issue9770] curses.ascii.isblank() function is broken. It confuses backspace (BS 0x08) with tab (0x09)

2014-07-24 Thread akira
akira added the comment: I've made the title more explicit: curses.isblank function doesn't match ctype.h - curses.ascii.isblank() function is broken. It confuses backspace (BS 0x08) with tab (0x09) If a core developer could review the open questions from the previous message msg221008 then I

[issue21813] Enhance doc of os.stat_result

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: The only comments you didn't address you were right not to (sorry for the noise about path_fd, I completely missed that it was just a link reference); what you committed looks fine to me. Thanks for your work on this, it looks like a big improvement to me!

[issue20055] On Windows NT 6 with administrator account, there are two failing tests on test_shutil.py

2014-07-24 Thread Zachary Ware
Changes by Zachary Ware zachary.w...@gmail.com: -- Removed message: http://bugs.python.org/msg223821 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20055 ___

[issue22055] Incomplete sentence in asyncio BaseEventLoop doc

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: Misposted to #20055: New changeset 84f26a437893 by Victor Stinner in branch '3.4': Issue #20055: Fix BaseEventLoop.stop() docstring, incomplete sentence. http://hg.python.org/cpython/rev/84f26a437893 New changeset f657b64c67ab by Victor Stinner in branch

[issue22057] The doc say all globals are copied on eval(), but only __builtins__ is copied

2014-07-24 Thread Alon Mishne
New submission from Alon Mishne: According to the documentation of eval(): If the globals dictionary is present and lacks '__builtins__', the current globals are copied into globals before expression is parsed. However in practice only the __builtins__ items are copied, see:

[issue22052] Comparison operators called in reverse order for subclasses with no override.

2014-07-24 Thread R. David Murray
R. David Murray added the comment: Ah yes. I remember there being a discussion somewhere about the differences between comparison operator inverses and the arithmetic 'r' methods, but I can't find it at the moment. I *thought* there was a full discussion of the logic involved in these

[issue9882] abspath from directory

2014-07-24 Thread Wolfgang Maier
Changes by Wolfgang Maier wolfgang.ma...@biologie.uni-freiburg.de: -- nosy: +wolma ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9882 ___ ___

[issue22058] datetime.datetime() should accept a datetime.date as constructor

2014-07-24 Thread Facundo Batista
New submission from Facundo Batista: Currently (tested on py3.4): from datetime import datetime, date d = datetime.now() date(d) Traceback (most recent call last): File stdin, line 1, in module TypeError: an integer is required (got type datetime.datetime) IMO, it's like doing int(float),

[issue1730136] tkFont.__eq__ gives type error

2014-07-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The patch was not committed to 2.7 and now this bug causes an error on buildbot. http://buildbot.python.org/all/builders/AMD64%20Debian%20root%202.7/builds/303/steps/test/logs/stdio ==

[issue14534] Add method to mark unittest.TestCases as do not run.

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: Victor: Sorry for the delay in getting back to this. I'm attaching your full patch again; the diff you posted is a diff against your first patch, while what we need to be able to review it properly is a diff against the tip of the 'default' branch. You may be

[issue22059] incorrect type conversion from str to bytes in asynchat module in asynchat.py

2014-07-24 Thread Hoxily
New submission from Hoxily: refer to http://hg.python.org/cpython/file/5d70ac83d104/Lib/asynchat.py#l123 -- components: Library (Lib) hgrepos: 265 messages: 223842 nosy: brett.cannon, hoxily, tim.peters priority: normal severity: normal status: open title: incorrect type conversion

[issue21084] IDLE can't deal with characters above the range (U+0000-U+FFFF)

2014-07-24 Thread wjssz
wjssz added the comment: I wrote this code, but I don't know how to make a patch. Insert these codes in C:\Python34\Lib\idlelib\IOBinding.py Around line 234, before this line: self.text.delete(1.0, end) # check non-bmp characters line_count = 1 position_count = 1

[issue1730136] tkFont.__eq__ gives type error

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset 841cdb6145e9 by Serhiy Storchaka in branch '2.7': Issue #1730136: Fix comparison between a tk Font object and an object of a http://hg.python.org/cpython/rev/841cdb6145e9 -- nosy: +python-dev ___ Python

[issue22059] incorrect type conversion from str to bytes in asynchat module in asynchat.py

2014-07-24 Thread Hoxily
Changes by Hoxily hox...@qq.com: -- hgrepos: -265 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22059 ___ ___ Python-bugs-list mailing list

[issue21084] IDLE can't deal with characters above the range (U+0000-U+FFFF)

2014-07-24 Thread wjssz
wjssz added the comment: Changing the second if to elif is better. I'm sorry, I have never submitted patch. If somebody gives a hand, feel free to modify those codes. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21084

[issue21623] build ssl failed use vs2010 express

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: Mo Jia: are you still having issues with this? -- resolution: - works for me status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21623 ___

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Facundo Batista
Changes by Facundo Batista facu...@taniquetil.com.ar: -- title: datetime.datetime() should accept a datetime.date as constructor - datetime.datetime() should accept a datetime.date as init parameter ___ Python tracker rep...@bugs.python.org

[issue19980] Improve help('non-topic') response

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: Mark, would you like to update your patch to address my review comments? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19980 ___

[issue9882] abspath from directory

2014-07-24 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9882 ___ ___

[issue21084] IDLE can't deal with characters above the range (U+0000-U+FFFF)

2014-07-24 Thread Ezio Melotti
Ezio Melotti added the comment: See https://docs.python.org/devguide/patch.html -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21084 ___ ___

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread R. David Murray
R. David Murray added the comment: There is already a spelling for that operation, and it is d.date(). I'm not sure that there is a strong enough argument for adding a second way to spell it, but I won't close this yet to see what other people think. Personally I don't think it has ever

[issue8110] subprocess.py doesn't correctly detect Windows machines

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: How about this? Should apply equally to 3.4 and default, 2.7 is different but can use the same concept (with s/_winapi/_subprocess/ among other changes). -- nosy: +zach.ware stage: test needed - patch review versions: +Python 3.4, Python 3.5 -Python

[issue22059] incorrect type conversion from str to bytes in asynchat module in asynchat.py

2014-07-24 Thread R. David Murray
R. David Murray added the comment: So you are saying that that if will never trigger and can be deleted? -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22059 ___

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: That's not what I'm answering to, though. See option B above. Again, what's wrong with passing the socket as a fileno? There is nothing wrong, it's just that I prefer option (C) over the option (B). Quick poll in the Python stdlib for functions accepting

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: +1 There is currently no obvious way to convert either date or datetime instance to date. The best solution I can think of is date(*x.timetuple()[:3]): d = date.today() t = datetime.now() date(*d.timetuple()[:3]) datetime.date(2014, 7, 24)

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: Removed file: http://bugs.python.org/file36059/map_chunksize.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11271 ___

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: Added file: http://bugs.python.org/file36064/map_chunksize.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11271 ___

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: Removed file: http://bugs.python.org/file36058/test_mult.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11271 ___

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: Added file: http://bugs.python.org/file36065/test_mult.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11271 ___

[issue22041] http POST request with python 3.3 through web proxy

2014-07-24 Thread Demian Brecht
Demian Brecht added the comment: I've attached a patch that solves the issue I encountered. It would be great if you could confirm whether or not it also resolves the issue as reported. -- keywords: +patch Added file: http://bugs.python.org/file36066/issue22041.patch

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: Removed file: http://bugs.python.org/file36064/map_chunksize.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11271 ___

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: Added file: http://bugs.python.org/file36067/map_chunksize.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11271 ___

[issue11271] concurrent.futures.ProcessPoolExecutor.map() doesn't batch function arguments by chunks

2014-07-24 Thread Dan O'Reilly
Dan O'Reilly added the comment: I've added new versions of the patch/demonstration that ensures we actually submit all the futures before trying to yield from the returned iterator. Previously we were just returning a generator object when map was called, without actually submitting any

[issue17483] Can not tell urlopen not to check the hostname for https connections.

2014-07-24 Thread Alecz
Alecz added the comment: Actually, because of issue 18543, urlopen will not use the custom opener if one was defined, instead, it will create a new opener with check_hostname = True. So it is impossible to skip hostname checking without overriding the urlopen method. I don't understand why

[issue22059] incorrect type conversion from str to bytes in asynchat module in asynchat.py

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: Hoxily: It's best to spell out the bug you have found, preferably with an error/exception message and a way to reproduce it. My best guess at the problem you're reporting (after looking at that line about 4 times) is that bytes(str, self.encoding) should be

[issue22059] incorrect type conversion from str to bytes in asynchat module in asynchat.py

2014-07-24 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22059 ___ ___ Python-bugs-list

[issue11266] asyncore does not handle EINTR in recv, send, connect, accept,

2014-07-24 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- resolution: - duplicate status: open - closed superseder: - handle EINTR in the stdlib ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11266

[issue16133] asyncore.dispatcher.recv doesn't handle EAGAIN / EWOULDBLOCK

2014-07-24 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- Removed message: http://bugs.python.org/msg172160 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16133 ___

[issue21725] RFC 6531 (SMTPUTF8) support in smtpd

2014-07-24 Thread R. David Murray
R. David Murray added the comment: I have updated your patch, changing wording of some of the documentation, and applying style tweaks to the code. I have also done the refactoring of the _set_xxx_state method that I suggested. Seemed easier to show you what I meant in code rather than try

[issue17483] Can not tell urlopen not to check the hostname for https connections.

2014-07-24 Thread R. David Murray
R. David Murray added the comment: This issue was about setting hostname checking to false when the cert was being checked, and we rejected making that even possible in urlopen. If there is an issue with not being able to use a custom opener, that would be a different issue and you should

[issue16133] asyncore.dispatcher.recv doesn't handle EAGAIN / EWOULDBLOCK

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset b7f144d14798 by Victor Stinner in branch '3.4': Issue #16133: The asynchat.async_chat.handle_read() method now ignores http://hg.python.org/cpython/rev/b7f144d14798 New changeset aa150c7a5d24 by Victor Stinner in branch 'default': (Merge 3.4) Issue

[issue16133] asyncore.dispatcher.recv doesn't handle EAGAIN / EWOULDBLOCK

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset d422062d7d36 by Victor Stinner in branch '2.7': Issue #16133: The asynchat.async_chat.handle_read() method now ignores http://hg.python.org/cpython/rev/d422062d7d36 -- ___ Python tracker

[issue16133] asyncore.dispatcher.recv doesn't handle EAGAIN / EWOULDBLOCK

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I modified EWOULDBLOCK.patch to use BlockingIOError on Python 3 and I added a unit test. I also added EALREADY and EINPROGRESS which are used by the BlockingIOError in Python 3, just in case. Thanks Xavier for your patch, sorry for the delay. --

[issue15982] asyncore.dispatcher does not handle windows socket error code correctly (namely WSAEWOULDBLOCK 10035)

2014-07-24 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- resolution: - duplicate status: open - closed superseder: - asyncore.dispatcher.recv doesn't handle EAGAIN / EWOULDBLOCK ___ Python tracker rep...@bugs.python.org

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Tim Peters
Tim Peters added the comment: Was the title of this meant to be datetime.date() should accept a datetime.datetime as init parameter instead? That's what the example appears to be getting at. If so, -1. Datetime objects already have .date(), .time(), and .timetz() methods to extract,

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: The test fails on AMD64 OpenIndiana 2.7: http://buildbot.python.org/all/builders/AMD64%20OpenIndiana%202.7/builds/2354/steps/test/logs/stdio test test_readline failed -- Traceback (most recent call last): File

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread Ned Deily
Ned Deily added the comment: The changes are also causing segfaults when readline is linked with BSD libedit (the default on OS X) rather than GNU readline: == FAIL: test_init (test.test_readline.TestReadline)

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: some_datetime_object.date() is the obvious way to extract a date object from a datetime object. Sorry if I was not clear enough about my use case. I often have to deal with functions that are designed to take either date or datetime object as an

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Another solution is date(2001, 1, 1).__lt__(x), but this is even uglier than the one with timetuple. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22058

[issue19875] test_getsockaddrarg occasional failure

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: Here's a patch. -- keywords: +patch Added file: http://bugs.python.org/file36070/find_unused_race.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19875

[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-07-24 Thread Dan O'Reilly
Dan O'Reilly added the comment: How are you importing JoinableQueue? You'll see this error if you import it from multiprocessing.queues instead of directly from multiprocessing. This is because multiprocessing.JoinableQueue is now a function: def JoinableQueue(self, maxsize=0):

[issue21367] multiprocessing.JoinableQueue requires new kwarg

2014-07-24 Thread Dan O'Reilly
Changes by Dan O'Reilly oreil...@gmail.com: -- components: +Library (Lib) -Interpreter Core type: compile error - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21367 ___

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: As I said offline to Victor, I think it would be better to have a single function, i.e. keep set_wakeup_fd(). It makes the API simpler, less confusing and error prone: some people will wonder which one they should use, might end up using the wrong

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Tim Peters
Tim Peters added the comment: Alexander, I don't see a need to make everything a one-liner. Dealing with a mix of dates and datetimes is easily sorted out with an `if` statement, like def func(thedate): if isinstance(thedate, datetime.datetime): thedate = thedate.date() # and

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread Guido van Rossum
Guido van Rossum added the comment: I find Charles' argument pretty convincing. The whole point of this API is to have another thing you can add to the selector to deal with a race condition. You then pass this thing's fileno() to signal.set_wakeup_fd(). That should be totally portable. I'm

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: The changes are also causing segfaults when readline is linked with BSD libedit (the default on OS X) rather than GNU readline: Oh wow. Do you have an idea of to fix the issue with libedit? Or make the code condition, only use it with native readline?

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

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: The patch looks good. I just think it would be nice to expose _fdcount() in test.support. -- nosy: +neologix ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18174

[issue21035] Python's HTTP server implementations hangs after 16.343 requests on MacOSX

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: I'm closing, since it's amlost certainly an OS-X bug (similar to time-wit socket exhaustion Co). -- resolution: - third party stage: - resolved status: open - closed ___ Python tracker

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: It is not as mush about avoiding a one-liner as it is about duck-typing. IMO, dates and datetime objects are numbers in disguise. Many functions that are nominally numeric, can work with date/datetime/timedelta objects without modification. The fact

[issue12184] socketserver.ForkingMixin collect_children routine needs to collect only it's children

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: Closing as wont't fix, since we now have asyncio which handles this much better. -- resolution: - wont fix stage: needs patch - resolved status: open - closed ___ Python tracker rep...@bugs.python.org

[issue12801] C realpath not used by os.path.realpath

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: Shall we close this, since realpath(3) is fundamentally broken, and pathlib now does The Right Thing? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12801

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread Ned Deily
Ned Deily added the comment: Currently, readline.c uses #ifdef __APPLE__ to guard libedit-specific code (there is another open issue to generalize libedit support to other platforms). -- ___ Python tracker rep...@bugs.python.org

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: Ok, let's go with the option (B): use set_wakeup_fd() on all platforms, but only accept socket handles on Windows. New patch wakeup_fd-7.patch: - signal.set_wakeup_fd() now only accepts socket handles (int) on Windows, it raises TypeError for files. Note: it

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

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: Why not using os.fstat() instead of os.dup() to check if a file descriptor is open or not? It's strange to create a new file descriptor with os.dup() to count the file descriptors. -- ___ Python tracker

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

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: Why not using os.fstat() instead of os.dup() to check if a file descriptor is open or not? I asked myself the same question, but IIRC, fstat() doesn't always work on Windows (of course). -- ___ Python

[issue12801] C realpath not used by os.path.realpath

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I agree, Python should not use the C function realpath() for all the reasons give in the issue. -- resolution: - not a bug status: open - closed ___ Python tracker rep...@bugs.python.org

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread Guido van Rossum
Guido van Rossum added the comment: I think if it's not a socket (or a closed one) it should raise ValueError or perhaps OSError -- TypeError would mean that it's not an int. -- ___ Python tracker rep...@bugs.python.org

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

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I asked myself the same question, but IIRC, fstat() doesn't always work on Windows (of course). Can you please elaborate? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18174

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: I think if it's not a socket (or a closed one) it should raise ValueError or perhaps OSError -- TypeError would mean that it's not an int. Oh, you're right. Updated patch, version 8, now raises a ValueError. -- Added file:

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

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: STINNER Victor added the comment: I asked myself the same question, but IIRC, fstat() doesn't always work on Windows (of course). Can you please elaborate? Not really, since I don't know much about Windows, but that's something I think I heard.

[issue19884] Importing readline produces erroneous output

2014-07-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset f0ab6f9f0603 by Victor Stinner in branch '2.7': Issue #19884, readline: calling rl_variable_bind (enable-meta-key, off) http://hg.python.org/cpython/rev/f0ab6f9f0603 New changeset 3f08c1156050 by Victor Stinner in branch '3.4': Issue #19884,

[issue22058] datetime.datetime() should accept a datetime.date as init parameter

2014-07-24 Thread Facundo Batista
Facundo Batista added the comment: El 24/07/14 a las 15:01, Tim Peters escibió: datetime.date() should accept a datetime.datetime as init parameter instead? That's what the example appears to be getting at. If so, -1. Datetime objects already have .date(), .time(), and .timetz()

[issue20611] socket.create_connection() doesn't handle EINTR properly

2014-07-24 Thread STINNER Victor
STINNER Victor added the comment: The issue is just an example of the main issue #18885 which proposes to retry interrupted syscalls. I hesitate to mark it as duplicate, but it contains an interesting patch. -- ___ Python tracker

[issue22060] Clean up ctypes.test, use unittest test discovery

2014-07-24 Thread Zachary Ware
New submission from Zachary Ware: Attached is a patch that aims to clean up the ctypes tests a bit, namely by removing the custom resource management (which conflicts with regrtest), the custom test discovery (which is better left to unittest), and the custom test running (which is better

[issue22018] Add a new signal.set_wakeup_socket() function

2014-07-24 Thread Charles-François Natali
Charles-François Natali added the comment: Ok, let's go with the option (B): use set_wakeup_fd() on all platforms, but only accept socket handles on Windows. Sorry, why restrict it to sockets on Windows? If someone wants to pass e.g. a pipe, why prevent it? --

[issue21314] Document '/' in signatures

2014-07-24 Thread Zachary Ware
Zachary Ware added the comment: Apologies for the delay in answering, Emily. And, unfortunately, I don't have a good answer. If you would like to write a patch, I would suggest just sticking the documentation wherever you think is best and make sure there is a link to it from the Symbols

[issue18543] urllib.parse.urlopen shouldn't ignore installed opener when called with any ca* argument

2014-07-24 Thread Alecz
Alecz added the comment: I just want to point out that the documentation states that an opener can be used with urlopen: urllib.request.install_opener(opener) Install an OpenerDirector instance as the default global opener. Installing an opener is only necessary if you want urlopen to

  1   2   >