[issue26282] Add support for partial keyword arguments in extension functions

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If there are no objections I'm inclined to commit pyarg_parse_positional_only_and_keywords_2.patch in short time. -- assignee: -> serhiy.storchaka ___ Python tracker

Re: Pylint prefers list comprehension over filter...

2016-05-06 Thread Steven D'Aprano
On Fri, 6 May 2016 12:57 pm, Stephen Hansen wrote: > On Thu, May 5, 2016, at 07:46 PM, Dan Sommers wrote: >> On Thu, 05 May 2016 18:37:11 -0700, Stephen Hansen wrote: >> >> > ''.join(x for x in string if x.isupper()) >> >> > The difference is, both filter and your list comprehension *build

[issue22107] tempfile module misinterprets access denied error on Windows

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Billy, no, the parent directory is tested intentionally. If it isn't a directory, we should fail. May be there is a way to distinguish a failure because the name is already used for a subdirectory from a failure because we don't have permission to create a

[issue17888] docs: more information on documentation team

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

[issue18841] math.isfinite fails with Decimal sNAN

2016-05-06 Thread Berker Peksag
Changes by Berker Peksag : -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker ___

[issue12135] The spawn function should return stderr.

2016-05-06 Thread Berker Peksag
Changes by Berker Peksag : -- status: open -> closed ___ Python tracker ___ ___

[issue20554] Use specific asserts in optparse test

2016-05-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> wont fix stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue25745] Reference leaks in test_curses

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is simple patch that fixes a leak. -- keywords: +patch stage: needs patch -> patch review Added file: http://bugs.python.org/file42754/curses_panel_dealloc_userptr.patch ___ Python tracker

[issue20554] Use specific asserts in optparse test

2016-05-06 Thread Berker Peksag
Berker Peksag added the comment: The patch looks simple, but I don't see much gain to apply it since optparse is a deprecated module. I'm in favor of closing this as 'wont fix'. -- priority: normal -> low ___ Python tracker

[issue26002] make statistics.median_grouped more efficient

2016-05-06 Thread Berker Peksag
Changes by Berker Peksag : -- resolution: -> fixed stage: commit review -> resolved status: open -> closed ___ Python tracker

[issue25974] Fix statistics.py after the Decimal.as_integer_ratio() change

2016-05-06 Thread Berker Peksag
Berker Peksag added the comment: statistics_as_integer_ratio.diff has been committed in 7b2fafd78c1d. -- nosy: +berker.peksag resolution: -> fixed stage: commit review -> resolved status: open -> closed ___ Python tracker

[issue25745] Reference leaks in test_curses

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for the tip Berker. Now I see how to fix the leak. -- assignee: -> serhiy.storchaka ___ Python tracker ___

[issue20971] HTML output of difflib

2016-05-06 Thread Berker Peksag
Changes by Berker Peksag : -- resolution: -> duplicate stage: needs patch -> resolved status: open -> closed superseder: -> Modernize HTML output of difflib.HtmlDiff.make_file() ___ Python tracker

[issue17888] docs: more information on documentation team

2016-05-06 Thread Berker Peksag
Berker Peksag added the comment: issue17888.patch looks good to me. I'd probably remove the "necessary skills" part. -- nosy: +berker.peksag stage: needs patch -> patch review versions: +Python 3.5, Python 3.6 ___ Python tracker

[issue21890] wsgiref.simple_server sends headers on empty bytes

2016-05-06 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag stage: -> patch review versions: +Python 2.7, Python 3.5, Python 3.6 ___ Python tracker

[issue26939] android: test_functools hangs on armv7

2016-05-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Xavier, as a strating point, can you try the following patch? (atomic_explicit.patch) If it solves the issue, can you also measure the performance drop compared to unpatched (on a non-debug build)? `python -m test.pystone` should be sufficient. --

[issue25745] Reference leaks in test_curses

2016-05-06 Thread Berker Peksag
Berker Peksag added the comment: In case someone wants to work on this, the suspicious tests are test_userptr_memory_leak and test_userptr_segfault. See also issue 18113. -- nosy: +berker.peksag stage: -> needs patch versions: +Python 3.5 ___

[issue26939] android: test_functools hangs on armv7

2016-05-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +neologix ___ Python tracker ___ ___ Python-bugs-list

[issue26939] android: test_functools hangs on armv7

2016-05-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: I suspect this bug is caused by memory ordering differences between x86 and ARM (see https://en.wikipedia.org/wiki/Memory_ordering#Runtime_memory_ordering ), which is why it may not reproduce easily (may depend on the particular CPU implementation and/or

[issue15786] IDLE code completion window can hang or misbehave with mouse

2016-05-06 Thread suddha sourav
suddha sourav added the comment: I reported the issue in 2012, and it's not nice to see that in four years the flagship editor of Python in all platforms I know is still something I have to avoid. I am not writing this mail to vent; I'm asking: what can we do, and through which channels we can

[issue26537] ConfigParser has optionxform, but not sectionxform

2016-05-06 Thread Xiang Zhang
Xiang Zhang added the comment: I write a patch to add sectionxform. It wraps necessary section name operation I think. Hope to have some feedback. -- keywords: +patch Added file: http://bugs.python.org/file42752/add_sectionxform.patch ___ Python

[issue26156] Bad name into power operator syntax

2016-05-06 Thread Robert Jordens
Robert Jordens added the comment: Ack to the new patch. It is semantically confusing that the await expression also served as the power base without any await. -- ___ Python tracker

[issue20291] Argument Clinic should understand *args and **kwargs parameters

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think at first step we can support var-positional parameter only when there are no other positional parameters, and var-keyword parameter only when there are no other keyword parameters. So print, max and dict.update will be supported, but

[issue26959] pickle: respect dispatch for functions again

2016-05-06 Thread Vsevolod Velichko
Vsevolod Velichko added the comment: I was trying to avoid additional imports in the test. But your point of view seems more reasonable, so I reupload the fixed patch. -- Added file: http://bugs.python.org/file42751/function_pickle.patch ___ Python

[issue26939] android: test_functools hangs on armv7

2016-05-06 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: FWIW, test_functools passes on ASUS Zenfone 2 Laser ZE500KL with stock ROM (rooted) and my patchset. [1] The CPU is ARM64 and the Python is built as 32-bit ARM binaries. test_threading (#26941) and test_importlib (#26940) pass, too. test_concurrent_futures

Re: Whittle it on down

2016-05-06 Thread alister
On Thu, 05 May 2016 19:31:33 -0400, DFS wrote: > On 5/5/2016 1:39 AM, Stephen Hansen wrote: > >> Given: >> > input = [u'Espa\xf1ol', 'Health & Fitness Clubs (36)', 'Health Clubs > & Gymnasiums (42)', 'Health Fitness Clubs', 'Name', 'Atlanta city > guide', 'edit address', 'Tweet',

[issue13173] Default values for string.Template

2016-05-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker ___

[issue1528167] Tweak to make string.Templates more customizable

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I seconded Raymond. Now the approach is argued against twice. And the patch itself is outdated. I suggest to close this issue. If somebody want to implement Raymond's idea, his can reopen this issue or open new issue. -- nosy: +serhiy.storchaka

[issue26870] Unexpected call to readline's add_history in call_readline

2016-05-06 Thread Tyler Crompton
Tyler Crompton added the comment: I couldn't think of a way to test input() with the unittest module without bypassing readline or requesting the input from the user. With that said, this informal script verifies proper behavior. -- status: open -> pending Added file:

[issue26870] Unexpected call to readline's add_history in call_readline

2016-05-06 Thread Tyler Crompton
Changes by Tyler Crompton : -- status: pending -> open ___ Python tracker ___ ___

[issue26870] Unexpected call to readline's add_history in call_readline

2016-05-06 Thread Tyler Crompton
Changes by Tyler Crompton : -- keywords: +patch Added file: http://bugs.python.org/file42748/set_auto_history.patch ___ Python tracker

[issue17765] weakref.ref ignores a 'callback' keyword argument

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: no_weakref_kwargs_2.patch LGTM. -- components: +Extension Modules nosy: +serhiy.storchaka stage: needs patch -> commit review type: enhancement -> behavior versions: +Python 3.5, Python 3.6 -Python 3.3, Python 3.4

[issue26970] Replace OpenSSL's CPRNG with system entropy source

2016-05-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Then I'd say just keep them private. -- ___ Python tracker ___ ___

[issue26970] Replace OpenSSL's CPRNG with system entropy source

2016-05-06 Thread Christian Heimes
Christian Heimes added the comment: I have used the helper methods during development. They are also used in unit tests. -- ___ Python tracker ___

[issue26970] Replace OpenSSL's CPRNG with system entropy source

2016-05-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: What are the helper methods good for? I don't think we want to expose them for now. -- ___ Python tracker ___

[issue26756] fileinput handling of unicode errors from standard input

2016-05-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker ___

[issue26959] pickle: respect dispatch for functions again

2016-05-06 Thread Hrvoje Nikšić
Hrvoje Nikšić added the comment: You can simplify pickle_lambda in the test by using marshal.dumps(code_obj) and marshal.loads(code_obj) to dump and load the code object without going through its entire guts. It would be a shame to have to change a pickle test just because some detail of the

[issue15071] TLS get keys and randoms

2016-05-06 Thread Christian Heimes
Christian Heimes added the comment: This request is an advanced use case. I'd rather keep the Python _ssl module simple and suggest PyOpenSSL + PyCA/cryptography for advanced features. -- status: open -> languishing versions: +Python 3.6 -Python 3.4

[issue26970] Replace OpenSSL's CPRNG with system entropy source

2016-05-06 Thread Christian Heimes
New submission from Christian Heimes: The patch adds a new RAND engine for OpenSSL. The engine uses the system's entropy source (/dev/urandom, CryptGenRandom(), getentropy() ...). The engine is automatically installed with OpenSSL as default RAND engine. The new engine fixes the fork() bug

[issue26970] Replace OpenSSL's CPRNG with system entropy source

2016-05-06 Thread Cory Benfield
Changes by Cory Benfield : -- nosy: +Lukasa ___ Python tracker ___ ___ Python-bugs-list

Re: After a year using Node.js, the prodigal son returns

2016-05-06 Thread Chris Angelico
On Fri, May 6, 2016 at 6:51 PM, Gregory Ewing wrote: > Chris Angelico wrote: > >> https://www.destroyallsoftware.com/talks/the-birth-and-death-of-javascript > > > This video seems to be broken. It stops about 1/3 of the way > through for me and says "No video with

Re: After a year using Node.js, the prodigal son returns

2016-05-06 Thread Gregory Ewing
Chris Angelico wrote: https://www.destroyallsoftware.com/talks/the-birth-and-death-of-javascript This video seems to be broken. It stops about 1/3 of the way through for me and says "No video with supported format and MIME type found". -- Greg --

[issue15753] No-argument super in method with variable arguments raises SystemError

2016-05-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- status: open -> pending ___ Python tracker ___ ___

[issue18531] Undocumented different between METH_KEYWORDS and **kws

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Proposed patch converts var-keyword arguments to exact dict. Since it changes the behavior of str.format() it can be pushed only in 3.6. -- Added file: http://bugs.python.org/file42746/ceval_kwargs_exact_dict.patch

[issue26931] android: test_distutils fails

2016-05-06 Thread Xavier de Gaye
Xavier de Gaye added the comment: On android, the shell path is /system/bin/sh. The attached patch fixes this, assuming that there is a platform.android_ver() as per issue #26855: add platform.android_ver() for android. This could be changed for a test on sys.platform if there was a specific

[issue26931] android: test_distutils fails

2016-05-06 Thread Xavier de Gaye
Xavier de Gaye added the comment: The attached patch skips some tests when the interpreter was cross-compiled. When the interpreter has been cross-compiled, there is probably no compiler on the host system. -- keywords: +patch Added file:

[issue26931] android: test_distutils fails

2016-05-06 Thread Xavier de Gaye
Xavier de Gaye added the comment: The last two failed tests: test_sysconfig_compiler_vars test_sysconfig_module are caused by LDFLAGS being set in the environment both when configure is run and when make is run. Removing LDFLAGS from the environment when running make fixes these

[issue18531] Undocumented different between METH_KEYWORDS and **kws

2016-05-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : Added file: http://bugs.python.org/file42743/test_args_kwargs_types.patch ___ Python tracker ___

[issue18531] Undocumented different between METH_KEYWORDS and **kws

2016-05-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : Removed file: http://bugs.python.org/file42742/test_args_kwargs_types.patch ___ Python tracker ___

Re: Whittle it on down

2016-05-06 Thread Peter Otten
DFS wrote: > On 5/5/2016 1:39 AM, Stephen Hansen wrote: > >> Given: >> > input = [u'Espa\xf1ol', 'Health & Fitness Clubs (36)', 'Health Clubs & > Gymnasiums (42)', 'Health Fitness Clubs', 'Name', 'Atlanta city > guide', 'edit address', 'Tweet', 'PHYSICAL FITNESS CONSULTANTS & >

[issue18531] Undocumented different between METH_KEYWORDS and **kws

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yet one difference is that kwargs can be NULL in C function if no keyword arguments are supplied. Here is a patch that adds tests for exact types of args and kwargs arguments in C functions. I think that we should keep passing NULL as kwargs for

[issue26959] pickle: respect dispatch for functions again

2016-05-06 Thread SilentGhost
Changes by SilentGhost : -- nosy: +alexandre.vassalotti, pitrou stage: -> patch review ___ Python tracker ___

python - handling HTTP requests asynchronously

2016-05-06 Thread lordluke80
Hi everyone, I need to generate a PDF report for each entry of a django queryset. There'll be between between 30k and 40k entries. The PDF is generated through an external API. Since currently is generated on demand, this is handled synchronously via an HTTP request/response. That will be

[issue25628] Make namedtuple "verbose" and "rename" parameters into keyword only arguments

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ping. If the keyword-only changes can be made without deprecation, I would want to make such changes for json functions (issue18726). json.dump() takes 11 positional parameters! Guido, what you say about this? -- nosy: +gvanrossum

[issue26969] ascynio should provide a policy to address pass-loop-everywhere problem

2016-05-06 Thread Ilya Kulakov
New submission from Ilya Kulakov: Currently if one needs lazily resolve event loop depending on where awaitable is being awaited have to pass loop everywhere explicitly. That quickly becomes an unnecessary noise in interfaces of callables. Consider an example where a coroutine which

[issue26702] A better assert statement

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I'm -1 for changing syntax of assert. But I think that it may be useful to change semantic of assert so that all intermediate results of subexpressions are saved and included in the assert report (or at least their shortened reprs). I'm +0 for this.

[issue26156] Bad name into power operator syntax

2016-05-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The confusion is in the definition of await expression with optional "await". Without "await" the expression doesn't suspend the execution of coroutine. And await expression can only be used inside a coroutine function, but the power operator can be used

<    1   2