[issue30608] argparse calculates string widths incorrectly

2017-06-08 Thread Vanessa McHale
New submission from Vanessa McHale: Currently, python computes string widths based on number of characters. However, this will not work in general because some languages have e.g. vowel markers: 'བོད' for instance is three characters but its width should be two. I have an example repo here:

[issue30604] co_extra_freefuncs is stored thread locally and can lead to crashes

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: User code shouldn't allocate PyInterpreterState and PyThreadState structures, it only uses structures created by the interpreter. Changing the size of PyInterpreterState should be safe. The only possible breaking compatibility is if user code directly

[issue30303] IDLE: Add _utest to textview and add textview tests

2017-06-08 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- pull_requests: +2084 ___ Python tracker ___ ___

[issue30038] Race condition in how trip_signal writes to wakeup fd

2017-06-08 Thread Nathaniel Smith
Nathaniel Smith added the comment: I guess now would be a good time to decide whether this should be backported to 3.6, with 3.6.2 coming out in a few days :-). (Or if not, then it can probably be closed?) -- ___ Python tracker

[issue29943] PySlice_GetIndicesEx change broke ABI in 3.5 and 3.6 branches

2017-06-08 Thread Nathaniel Smith
Nathaniel Smith added the comment: Looks good to me, thanks Serhiy. -- ___ Python tracker ___ ___

[issue27838] test_os.test_chown() failure on koobs-freebsd-{current, 9}

2017-06-08 Thread Kubilay Kocak
Changes by Kubilay Kocak : Added file: http://bugs.python.org/file46937/python-sudo.txt ___ Python tracker ___

[issue27838] test_os.test_chown() failure on koobs-freebsd-{current, 9}

2017-06-08 Thread Kubilay Kocak
Kubilay Kocak added the comment: as per msg280837, this beings to happen when I restart the buildbot worker via sudo (does not fail on initial startup, executed/invoked using the same script, which does not use sudo) and the environment the worker starts with appears to be relevant. Attached

[issue30597] Show expected input in custom "print" error message

2017-06-08 Thread Nick Coghlan
Nick Coghlan added the comment: It looks like the current right-shift error message is already distinctive enough to get people to answers explaining the culprit:

[issue30597] Show expected input in custom "print" error message

2017-06-08 Thread Nick Coghlan
Nick Coghlan added the comment: Ah, re-reading the comments when reviewing Sanyam's patch, I just remembered the problem with the "print >> sys.stderr, output" case, which is that it isn't a syntax error, it's a runtime type error: ``` >>> print >> sys.stderr, "message" Traceback (most recent

[issue30597] Show expected input in custom "print" error message

2017-06-08 Thread Nick Coghlan
Nick Coghlan added the comment: Eric, right, I left a couple of logical leaps out of my reply as well. My first thought was the same as yours but then I went: - that means we need to split on commas - which means we need to track whether or not we're inside a quoted string or not - which is

[issue30607] Extract documentation theme into a separate package

2017-06-08 Thread Jon Wayne Parrott
Changes by Jon Wayne Parrott : -- pull_requests: +2083 ___ Python tracker ___ ___

[issue30606] Spam

2017-06-08 Thread Berker Peksag
Changes by Berker Peksag : -- Removed message: http://bugs.python.org/msg295480 ___ Python tracker ___

[issue30606] Spam

2017-06-08 Thread Berker Peksag
Changes by Berker Peksag : -- Removed message: http://bugs.python.org/msg295479 ___ Python tracker ___

[issue30606] Spam

2017-06-08 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: -Love resolution: -> not a bug stage: -> resolved status: open -> closed title: The reply's additional 'Re' is ok -> Spam ___ Python tracker

[issue30607] Extract documentation theme into a separate package

2017-06-08 Thread Jon Wayne Parrott
New submission from Jon Wayne Parrott: As part of an effort to align the packaging documentation (packaging.python.org) with the CPython docs, PyPA has extracted the theme used in the CPython documentation into a separate repository and package (https://github.com/python/python-docs-theme).

Re: Psycopg2 pool clarification

2017-06-08 Thread Ian Kelly
On Thu, Jun 8, 2017 at 10:47 AM, Israel Brewster wrote: >> On Jun 7, 2017, at 10:31 PM, dieter wrote: >> >> israel writes: >>> On 2017-06-06 22:53, dieter wrote: >>> ... >>> As such, using psycopg2's pool is essentially >>>

[issue30606] The reply's additional 'Re' is ok

2017-06-08 Thread Lovelyn
New submission from Lovelyn: lovecoli...@gmail.com -- messages: 295479 nosy: Love priority: normal severity: normal status: open title: The reply's additional 'Re' is ok ___ Python tracker

[issue29943] PySlice_GetIndicesEx change broke ABI in 3.5 and 3.6 branches

2017-06-08 Thread Ned Deily
Ned Deily added the comment: As a followup, Nathanial, are you satisfied with the resolution here for the upcoming 3.6.2? -- ___ Python tracker ___

[issue30606] The reply's additional 'Re' is ok

2017-06-08 Thread Lovelyn
Lovelyn added the comment: lovecoli...@gmail.com On Jun 9, 2017 9:19 AM, wrote: lovecoli...@gmail.com -- ___ Python tracker ___

Re: How to run self-contained Python scripts who don't need Python installation?

2017-06-08 Thread Michael Torrie
On 06/08/2017 07:40 PM, Juan C. wrote: > 2. I'd like to create a simple BAT to run my Python script, so there > would be only 2 things (a 'dist' folder with everything and a run.bat > to make it clear what should be run), for example: Sure you can. You just have to do it like this (untested; I

[issue23519] using asyncio.iscoroutinefunction() on a functools.partial object

2017-06-08 Thread Guido van Rossum
Guido van Rossum added the comment: Use a lambda instead of partial. It's more pythonic. -- ___ Python tracker ___

[issue30486] Allow setting cell value

2017-06-08 Thread Guido van Rossum
Changes by Guido van Rossum : -- nosy: -gvanrossum ___ Python tracker ___ ___

How to run self-contained Python scripts who don't need Python installation?

2017-06-08 Thread Juan C.
I need to run some Python 3.6.0 scripts on the users' machines (W7 and W10) in an enterprise environment, but I can't install Python on those machines. I tried looking for those "py to exe", but sadly they don't support Python 3.6.0. Then I found out about "Windows x86/x86-64 embeddable zip file"

[issue30604] co_extra_freefuncs is stored thread locally and can lead to crashes

2017-06-08 Thread Ned Deily
Ned Deily added the comment: See review comments on PR 2015. -- nosy: +ned.deily versions: +Python 3.7 ___ Python tracker ___

[issue30486] Allow setting cell value

2017-06-08 Thread Lisa Roach
Lisa Roach added the comment: Thank you for you guidance, Serhiy! On Thu, Jun 8, 2017 at 4:45 AM, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > Thank you for your contribution Lisa! > > -- > resolution: -> fixed > stage: patch review ->

[issue29943] PySlice_GetIndicesEx change broke ABI in 3.5 and 3.6 branches

2017-06-08 Thread Dino Viehland
Changes by Dino Viehland : -- pull_requests: +2082 ___ Python tracker ___ ___

[issue23519] using asyncio.iscoroutinefunction() on a functools.partial object

2017-06-08 Thread Curt McDowell
Curt McDowell added the comment: There are use cases for this. I hit the problem and eventually wound up here, so I'd like to make a case to re-open. My project has a callback registry of asyncio handler routines. register_callback(condition1, handler1) register_callback(condition2, handler2)

[issue30605] re.compile fails when compiling bytes under `-bb` mode

2017-06-08 Thread Roy Williams
Changes by Roy Williams : -- pull_requests: +2081 ___ Python tracker ___ ___

[issue30605] re.compile fails when compiling bytes under `-bb` mode

2017-06-08 Thread Roy Williams
Roy Williams added the comment: Repro: ``` import re re.compile(br'^(.*?)$(?m)') ``` Results in ``` Traceback (most recent call last): File "test_compile.py", line 2, in re.compile(br'^(.*?)$(?m)') File "/usr/lib/python3.6/re.py", line 233, in compile return _compile(pattern,

[issue30605] re.compile fails when compiling bytes under `-bb` mode

2017-06-08 Thread Roy Williams
New submission from Roy Williams: import re re.compile(br'^(.*?)$(?m)') -- components: Regular Expressions messages: 295473 nosy: Roy Williams, ezio.melotti, mrabarnett priority: normal severity: normal status: open title: re.compile fails when compiling bytes under `-bb` mode versions:

[issue27645] Supporting native backup facility of SQLite

2017-06-08 Thread R. David Murray
R. David Murray added the comment: There's a good chance, yes. You'll have to keep periodically pinging the issue (say once a month :), and if you can specifically talk someone into doing a review your chances go up :) For it to go in we need a review from a core-dev, but one or more

[issue27534] IDLE: Reduce number and time for user process imports

2017-06-08 Thread Cheryl Sabella
Cheryl Sabella added the comment: Yes, I ran test_idle before I submitted the pull request. I wasn't sure if I was missing something based on your comments of the test failing. -- ___ Python tracker

[issue27534] IDLE: Reduce number and time for user process imports

2017-06-08 Thread Terry J. Reedy
Terry J. Reedy added the comment: Yes, I do want to continue this. As I explained in msg270522, I shelved (but not abandoned) the autocomplete patch because it caused a test failure I did not (and do not) understand, and because I found another fix for that issue. The reductions I noted

[issue30604] co_extra_freefuncs is stored thread locally and can lead to crashes

2017-06-08 Thread Dino Viehland
Changes by Dino Viehland : -- pull_requests: +2080 ___ Python tracker ___ ___

[issue30529] Incorrect error messages for invalid whitespaces in f-string subexpressions

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your review Eric. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue30529] Incorrect error messages for invalid whitespaces in f-string subexpressions

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 570b1c971c31cd08dbf060f4e21636c40aa47786 by Serhiy Storchaka in branch '3.6': [3.6] bpo-30529: Fix errors for invalid whitespaces in f-string subexpressions. (GH-1888) (#2013)

[issue30604] co_extra_freefuncs is stored thread locally and can lead to crashes

2017-06-08 Thread Dino Viehland
New submission from Dino Viehland: The co_extra_freefuncs are stored in PyThreadState. When calling _PyEval_RequestCodeExtraIndex you are given a thread specific index. The code object can then lose it's last reference on a different thread, and the wrong free function can be called if

[issue30603] textwrap: declining indent level has no test case

2017-06-08 Thread Jonathan Eunice
Changes by Jonathan Eunice : -- pull_requests: +2079 ___ Python tracker ___ ___

Re: New to Python - Career question

2017-06-08 Thread Fred Stluka
On 6/6/17 5:39 PM, [1]pta...@gmail.com wrote: New to Python and have been at it for about a month now. I'm doing well and like it very much. Considering a career change down the road and have been wondering... What are the job prospects for a middle age entry level programmer. Just trying

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: New changeset b319d09ee4427aac1ee8f298692127d34ef57dc0 by Victor Stinner in branch '3.6': bpo-30418: Popen.communicate() always ignore EINVAL (#2002) (#2004) https://github.com/python/cpython/commit/b319d09ee4427aac1ee8f298692127d34ef57dc0 --

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: New changeset 31b950ab86f5c99a18c16dbf1900b854b94e0659 by Victor Stinner in branch '3.6': bpo-30601: Fix a refleak in WindowsConsoleIO (#2003) (#2008) https://github.com/python/cpython/commit/31b950ab86f5c99a18c16dbf1900b854b94e0659 --

[issue30603] textwrap: declining indent level has no test case

2017-06-08 Thread Jonathan Eunice
New submission from Jonathan Eunice: The case where textwrap.dedent() handles a declining indent level, requiring it to revise its margin estimate downward, remains untested. This issue is opened in support of an imminent PR that adds an appropriate test. -- components: Library (Lib)

[issue30529] Incorrect error messages for invalid whitespaces in f-string subexpressions

2017-06-08 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +2078 ___ Python tracker ___ ___

[issue30529] Incorrect error messages for invalid whitespaces in f-string subexpressions

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 2e9cd5825c5ccdbb6f65a57c0c7941078e003c14 by Serhiy Storchaka in branch 'master': bpo-30529: Fix errors for invalid whitespaces in f-string subexpressions. (#1888)

[issue30602] [Windows] os.spawn*() tests of test_os leak references on Windows

2017-06-08 Thread Eryk Sun
Eryk Sun added the comment: The memory leak is in os_spawnv_impl and os_spawnve_impl in Modules/posixmodule.c. The call fails with a ValueError when the first argument in the argv list is an empty string, in which case these functions both mistakenly pass i (0) to free_string_array() as the

[issue30596] Add close() to multiprocessing.Process

2017-06-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: close() wouldn't terminate the underlying process, so the process would still exist (and wouldn't easily be stoppable from Python anymore) if you were to call close() before terminate() or join(). Perhaps we should instead mandate people call join() before

[issue30596] Add close() to multiprocessing.Process

2017-06-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +asksol ___ Python tracker ___ ___ Python-bugs-list

[issue27534] IDLE: Reduce number and time for user process imports

2017-06-08 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- pull_requests: +2077 ___ Python tracker ___ ___

[issue27534] IDLE: Reduce number and time for user process imports

2017-06-08 Thread Cheryl Sabella
Cheryl Sabella added the comment: Terry, I've applied this patch to 3.7 and made a pull request. This seemed like a fix you wanted to move forward with, so I hope that's helpful. -- nosy: +csabella ___ Python tracker

[issue30596] Add close() to multiprocessing.Process

2017-06-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- pull_requests: +2076 ___ Python tracker ___ ___

[issue29237] Create enum for pstats sorting options

2017-06-08 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Thanks for checking in, Ethan. Sorry, since this was first assigned to me, I got pre-occupied with other issues and projects in the core-workflow. Ratnadeep, if you are still interested, please go ahead with this issue. I've unassigned myself. Thanks.

PyDev 5.8.0: Code Coverage fixes, IronPython debugging

2017-06-08 Thread Fabio Zadrozny
PyDev 5.8.0 Release Highlights - *Important* PyDev now requires Java 8 and Eclipse 4.6 (Neon) onwards. - PyDev 5.2.0 is the last release supporting Eclipse 4.5 (Mars). - *Code Analysis* - Fixed issue getting existing PyLint markers. - There's now an Info and an Ignore

[issue29237] Create enum for pstats sorting options

2017-06-08 Thread Ethan Furman
Ethan Furman added the comment: Marriatta, perhaps it is time to let Ratnadeep work on this issue? -- ___ Python tracker ___

[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-08 Thread Ethan Furman
Ethan Furman added the comment: No test code has been provided, so lacking any evidence of this problem I am closing this issue. Do not reopen without testable code to show the failure. -- resolution: -> not a bug stage: test needed -> resolved status: open -> closed

Re: Reg : Wikipedia 1.4 package

2017-06-08 Thread Ned Batchelder
On Thursday, June 8, 2017 at 11:10:49 AM UTC-4, Siva Kumar S wrote: > Dear members, > > how to install wikipedia 1.4 package in python 2.7 above without PIP. Why don't you want to use pip? You can probably just download the .tar.gz, unpack it, and run: python setup.py install but pip will

[issue30597] Show expected input in custom "print" error message

2017-06-08 Thread Sanyam Khurana
Changes by Sanyam Khurana : -- pull_requests: +2075 ___ Python tracker ___ ___

Re: python certification

2017-06-08 Thread justin walters
On Thu, Jun 8, 2017 at 4:49 AM, Gonzalo V wrote: > hi, > good day. > where can i get a python certification? > > thanks! > -- > https://mail.python.org/mailman/listinfo/python-list > I don't believe there is any official certification. Nor do I believe that a Python

Re: python certification

2017-06-08 Thread Bob Gailer
On Jun 8, 2017 7:58 AM, "Gonzalo V" wrote: > > hi, > good day. > where can i get a python certification? I'm not sure there is such a thing. Try Googling. > thanks! > -- > https://mail.python.org/mailman/listinfo/python-list --

Re: Psycopg2 pool clarification

2017-06-08 Thread Israel Brewster
--- Israel Brewster Systems Analyst II Ravn Alaska 5245 Airport Industrial Rd Fairbanks, AK 99709 (907) 450-7293 --- > On Jun 7, 2017, at 10:31 PM, dieter wrote: > > israel

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread Eryk Sun
Eryk Sun added the comment: Segev included a fix for this leak in PR 1927 for bpo30555, but I suppose it's better to fix it separately. -- nosy: +Segev Finer, eryksun ___ Python tracker

[issue27645] Supporting native backup facility of SQLite

2017-06-08 Thread Lele Gaifax
Lele Gaifax added the comment: Is there any chance this could be accepted for Python 3.7? -- ___ Python tracker ___

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: New changeset e5bdad2201de45c203037e59491e4fea56def56d by Victor Stinner in branch '2.7': bpo-30418: Popen.communicate() always ignore EINVAL (#2002) (#2006) https://github.com/python/cpython/commit/e5bdad2201de45c203037e59491e4fea56def56d --

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: New changeset df04c088493bdbc2defea5e225a94e9bdd8e759f by Victor Stinner in branch '3.5': bpo-30418: Popen.communicate() always ignore EINVAL (#2002) (#2005) https://github.com/python/cpython/commit/df04c088493bdbc2defea5e225a94e9bdd8e759f --

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2074 ___ Python tracker ___ ___

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: New changeset 29adc13bd797d9c9e7fcb893a7c49ce7f7ad388c by Victor Stinner in branch 'master': bpo-30601: Fix a refleak in WindowsConsoleIO (#2003) https://github.com/python/cpython/commit/29adc13bd797d9c9e7fcb893a7c49ce7f7ad388c --

[issue30602] [Windows] os.spawn*() tests of test_os leak references on Windows

2017-06-08 Thread STINNER Victor
New submission from STINNER Victor: The leak can be reproduced with the minimum attached test_os.py: C:\haypo\python>PCbuild\amd64\python_d.exe -m test -R 3:3 test_os Run tests sequentially 0:00:00 [1/1] test_os beginning 6 repetitions 123456 .. test_os leaked [2, 2, 2] memory blocks, sum=6

[issue29512] regrtest refleak: implement bisection feature

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: Oops, I uploaded the wrong version. It should now work. -- Added file: http://bugs.python.org/file46934/bisect_test.py ___ Python tracker

[issue29512] regrtest refleak: implement bisection feature

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: Updated script: support Windows, fix cmdline help. -- Added file: http://bugs.python.org/file46933/bisect_test.py ___ Python tracker

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2073 ___ Python tracker ___ ___

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2072 ___ Python tracker ___ ___

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- versions: +Python 2.7, Python 3.5, Python 3.6 ___ Python tracker ___

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2071 ___ Python tracker ___ ___

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: New changeset d52aa31378ae43e044a300edfe8285954c167216 by Victor Stinner in branch 'master': bpo-30418: Popen.communicate() always ignore EINVAL (#2002) https://github.com/python/cpython/commit/d52aa31378ae43e044a300edfe8285954c167216 --

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: With https://github.com/python/cpython/pull/2003 test_winconsoleio doesn't leak anymore. -- ___ Python tracker ___

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2070 ___ Python tracker ___ ___

Reg : Wikipedia 1.4 package

2017-06-08 Thread Siva Kumar S
Dear members, How to install Wikipedia 1.4 package in python 2.7 above without PIP. from, Sivakumar S -- https://mail.python.org/mailman/listinfo/python-list

Reg : Wikipedia 1.4 package

2017-06-08 Thread Siva Kumar S
Dear members, how to install wikipedia 1.4 package in python 2.7 above without PIP. from, Sivakumar S -- https://mail.python.org/mailman/listinfo/python-list

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: The following code leaks one reference: f = _io._WindowsConsoleIO('CONIO$', 'r') f.close() f = None -- ___ Python tracker

[issue30601] [Windows] test_winconsoleio leaks references

2017-06-08 Thread STINNER Victor
New submission from STINNER Victor: http://buildbot.python.org/all/builders/AMD64%20Windows8.1%20Refleaks%203.x/builds/22/steps/test/logs/stdio 0:00:12 [ 7/405/1] test_winconsoleio failed beginning 6 repetitions 123456 .. test_winconsoleio leaked [43, 43, 43] references, sum=129

[issue30597] Show expected input in custom "print" error message

2017-06-08 Thread Eric V. Smith
Eric V. Smith added the comment: That sounds good to me. Just to elaborate on my earlier message, since it might have been too terse: I think it would be misleading to give in error at: print >>sys.stderr, "message" and say: Did you mean 'print("message")'? since they're not equivalent. If

[issue30418] test_communicate_epipe() of test_subprocess fails randomly on AMD64 Windows7 SP1 3.x

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2069 ___ Python tracker ___ ___

[issue27321] Email parser creates a message object that can't be flattened

2017-06-08 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: ok, I have tested on 3.6 and 3.5, just with the test. and in this case, we get the errors on both. if we apply the patch of Johannes, the test passes and there is no issues. +1 the backports for 3.5 and 3.6 is just a git cherry-picking. --

[issue27321] Email parser creates a message object that can't be flattened

2017-06-08 Thread R. David Murray
R. David Murray added the comment: I'm going to try to review this this weekend. -- ___ Python tracker ___

[issue30599] os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: With https://github.com/python/cpython/pull/2001 test_threaded_import doesn't leak anymore. -- ___ Python tracker ___

[issue30599] os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2068 ___ Python tracker ___ ___

[issue30599] os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references

2017-06-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Agreed with Serhiy. test_threaded_import should just re-import a module which has less side effects. -- ___ Python tracker

[issue30597] Show expected input in custom "print" error message

2017-06-08 Thread Nick Coghlan
Nick Coghlan added the comment: Those are easy enough to check with strncmp() even in C, so we could make them manageable by just including "" in the error message, rather than the full text of the original statement. That is: Did you mean 'print()'? # Default Did

[issue30592] Bad error message 'bool()() takes no keyword arguments'

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: We don't have such code currently. The function name containing "()" looks silly. But funcname is not always a constant string, you can set it to arbitrary string when create a BaseException subclass. -- ___

[issue30600] Error message incorrect when index is called with keyword argument ("[].index(x=2)")

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, pleas do this. -- ___ Python tracker ___ ___ Python-bugs-list

[issue30599] os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This make the API and implementation more complex. I prefer making tests not creating several instances of the random module. Or do this in a short-living subprocess. -- nosy: +rhettinger ___ Python tracker

[issue30592] Bad error message 'bool()() takes no keyword arguments'

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: > If add an assertion, the user code could provoke a crash by creating an > exception type with a name containing "()": type('E()', (BaseException,), {}). Right. Do we have such code currently? If not, we can remove the assertion later if we want to use such

Re: Hello from a super noob!

2017-06-08 Thread Andre Müller
Hello, you can refactor your code a little bit and learn more about exceptions: def get_numbers(): first = None second = None while True: try: if first is None: first = int(input('Enter your first number: ')) if second is None:

[issue30600] Error message incorrect when index is called with keyword argument ("[].index(x=2)")

2017-06-08 Thread SylvainDe
SylvainDe added the comment: Can I give this a try or is anyone working on this already ? -- ___ Python tracker ___

[issue30584] test_os fails on non-English (Russian) Windows

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: Thanks Denis Osipov for the fix and backports! -- ___ Python tracker ___

[issue30600] Error message incorrect when index is called with keyword argument ("[].index(x=2)")

2017-06-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Good catch! This issue is similar to issue30534, but caused by generated code. The solution is easy: make Argument Clinic (Tools/clinic/clinic.py) generating _PyArg_NoStackKeywords() before _PyArg_ParseStack() and regenerate all generated by Argument Clinic

[issue30599] test_threaded_import leaks references

2017-06-08 Thread STINNER Victor
STINNER Victor added the comment: > The leak was introduced by the commit > 346cbd351ee0dd3ab9cb9f0e4cb625556707877e. This commit "bpo-16500: Allow registering at-fork handlers" adds the following code to Lib/random.py: +if hasattr(_os, "fork"): +_os.register_at_fork(_inst.seed,

[issue27321] Email parser creates a message object that can't be flattened

2017-06-08 Thread Stéphane Wirtel
Changes by Stéphane Wirtel : -- stage: needs patch -> patch review ___ Python tracker ___

[issue27321] Email parser creates a message object that can't be flattened

2017-06-08 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: maybe we could merge the PR, and I could propose a backport for 3.5 and 3.6. 2.7 is affected ? -- nosy: +matrixise ___ Python tracker

[issue30599] os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references

2017-06-08 Thread Stéphane Wirtel
Changes by Stéphane Wirtel : -- nosy: +matrixise ___ Python tracker ___ ___

[issue30599] os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references

2017-06-08 Thread STINNER Victor
Changes by STINNER Victor : -- title: test_threaded_import leaks references -> os.register_at_fork(): allow to unregister callbacks -- test_threaded_import leaks references ___ Python tracker

  1   2   >