Re: [Python-Dev] socketserver ForkingMixin waiting for child processes

2017-08-11 Thread Ryan Smith-Roberts
I agree that blocking shutdown by default isn't a good idea. A child will eventually get indefinitely stuck on a nonresponsive connection and hang the whole server. This behavior change is surprising and should be reverted in master, and definitely not backported. As for block-timeout or block-tim

Re: [Python-Dev] Tunning binary insertion sort algorithm in Timsort.

2015-03-09 Thread Ryan Smith-Roberts
I suspect that you will find the Python community extremely conservative about any changes to its sorting algorithm, given that it took thirteen years and some really impressive automated verification software to find this bug: http://envisage-project.eu/proving-android-java-and-python-sorting-alg

Re: [Python-Dev] Working on issue 23496: should I use a macro test or an edit to configure.ac?

2015-02-26 Thread Ryan Smith-Roberts
On Thu, Feb 26, 2015 at 5:13 PM, Ryan Smith-Roberts wrote: > I'm not an official cpython developer but ifdef __ANDROID__ is quite in line > with other per-platform support (__FreeBSD__, __linux__, etc), as well as > already being in use in Modules/_posixsubprocess.c. Is __ANDRO

Re: [Python-Dev] Working on issue 23496: should I use a macro test or an edit to configure.ac?

2015-02-26 Thread Ryan Smith-Roberts
I'm not an official cpython developer but ifdef __ANDROID__ is quite in line with other per-platform support (__FreeBSD__, __linux__, etc), as well as already being in use in Modules/_posixsubprocess.c. Is __ANDROID__ not being defined when it should be? On Thu, Feb 26, 2015 at 4:20 PM, Ryan Gonza

Re: [Python-Dev] Using argument clinic to replace timemodule.c:parse_time_t_args()

2014-01-20 Thread Ryan Smith-Roberts
: > Larry Hastings writes: > > On 01/18/2014 09:52 PM, Ryan Smith-Roberts wrote: > >> > >> I still advise you not to use this solution. time() is a system call > >> on many operating systems, and so it can be a heavier operation than > >> you'd think.

Re: [Python-Dev] Using argument clinic to replace timemodule.c:parse_time_t_args()

2014-01-19 Thread Ryan Smith-Roberts
On Sun, Jan 19, 2014 at 2:38 AM, Larry Hastings wrote: > According to the issue tracker, " rmsr" has only ever filed one issue. > I just fixed (and closed) it. > The two issues were "custom converter with converter and default raises exception" and "custom converter with py_default and c_defaul

Re: [Python-Dev] Using argument clinic to replace timemodule.c:parse_time_t_args()

2014-01-18 Thread Ryan Smith-Roberts
was looking for this one, so I've opened bugs on both issues, and put you on the nosy list for them. On Sat, Jan 18, 2014 at 7:42 PM, Nikolaus Rath wrote: > Hi Ryan, > > > Ryan Smith-Roberts writes: > > Hi Nikolaus. I also started a conversion of timemodule, but dropp

Re: [Python-Dev] Using argument clinic to replace timemodule.c:parse_time_t_args()

2014-01-18 Thread Ryan Smith-Roberts
Hi Nikolaus. I also started a conversion of timemodule, but dropped it when I saw in the issue that you had taken over that conversion. I also tried to turn parse_time_t_args into a converter. However, it won't work. The problem is that parse_time_t_args must be called whether or not the user suppl

Re: [Python-Dev] AC Derby and accepting None for optional positional arguments

2014-01-16 Thread Ryan Smith-Roberts
Let me expand on the issue, and address some of the replies. The goal of Argument Clinic is to create new docstring signatures for builtins, with the following properties: 1) Useful. While one can create a signature of func(*args) and then document complex and arbitrary restrictions on what args

Re: [Python-Dev] AC Derby and accepting None for optional positional arguments

2014-01-15 Thread Ryan Smith-Roberts
On Wed, Jan 15, 2014 at 7:57 PM, Ryan Smith-Roberts wrote: > socket.getservbyname(servicename[, protocolname]) > -> > socket.getservbyname(servicename, protocolname=None) > Here is a more complicated example, since the above does technically have an alternative fix: sockobj.

[Python-Dev] AC Derby and accepting None for optional positional arguments

2014-01-15 Thread Ryan Smith-Roberts
One of the downsides of converting positional-only functions to Argument Clinic is that it can result in misleading docstring signatures. Example: socket.getservbyname(servicename[, protocolname]) -> socket.getservbyname(servicename, protocolname=None) The problem with the new signature is that i

Re: [Python-Dev] Changing Clinic's output

2014-01-14 Thread Ryan Smith-Roberts
On Tue, Jan 14, 2014 at 5:32 PM, Ryan Smith-Roberts wrote: > NaN _pickle.using-sidefile.c /* not enough experience with it */ > I hate to weasel like that. Intellectually I think I favor the sidefile over all other approaches for its cleanliness. But I'd have to actively use it in a

Re: [Python-Dev] Changing Clinic's output

2014-01-14 Thread Ryan Smith-Roberts
I favor a dual-mode approach. I think the existing behavior is best for the conversion of existing modules, because it's easy to interactively verify the generated code. Once that's done, long-term maintenance definitely favors a more centralized format. +1 _pickle.original.c /* used only during c