[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:

3 more warnings in test_threading on AMD64 FreeBSD 10.x Shared 3.x:

http://buildbot.python.org/all/builders/AMD64%20FreeBSD%2010.x%20Shared%203.x/builds/886/steps/test/logs/stdio

0:03:45 load avg: 4.05 [246/405/1] test_thread failed (env changed)
(...)
test_nt_and_posix_stack_size (test.test_thread.ThreadRunningTests) ... (...)
task 4 done
task 10 done
all tasks done
Warning -- threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 
1)
Dangling thread: <_MainThread(MainThread, started 34393318400)>
ok
(...)
test_starting_threads (test.test_thread.ThreadRunningTests) ...
(...)
task 9 will run for 55us
task 9 done
all tasks done
Warning -- threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 
1)
Dangling thread: <_MainThread(MainThread, started 34393318400)>
ok


http://buildbot.python.org/all/builders/AMD64%20FreeBSD%2010.x%20Shared%203.x/builds/884/steps/test/logs/stdio

0:05:44 load avg: 3.00 [249/405/1] test_thread failed (env changed) -- running: 
test_concurrent_futures (31 sec), test_multiprocessing_fork (60 sec)
test_barrier (test.test_thread.BarrierTest) ...
(...)
task 5 leaving barrier
task 3 leaving barrier
tasks done
Warning -- threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 
1)
Dangling thread: <_MainThread(MainThread, started 34393318400)>
ok

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:

http://buildbot.python.org/all/builders/AMD64%20FreeBSD%20CURRENT%20Non-Debug%203.x/builds/881/steps/test/logs/stdio

0:08:05 load avg: 1.58 [288/405/1] test_threading failed (env changed) -- 
running: test_multiprocessing_spawn (83 sec)
(...)
test_dummy_thread_after_fork (test.test_threading.ThreadTests) ... ok
test_enumerate_after_join (test.test_threading.ThreadTests) ... ok
test_finalize_runnning_thread (test.test_threading.ThreadTests) ... ok
test_finalize_with_trace (test.test_threading.ThreadTests) ... ok
test_foreign_thread (test.test_threading.ThreadTests) ...

Warning -- threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 
1)
Dangling thread: <_MainThread(MainThread, started 34368585728)>

ok
test_frame_tstate_tracing (test.test_threading.ThreadTests) ... ok
test_ident_of_no_threading_threads (test.test_threading.ThreadTests) ... ok

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31170] Update to expat 2.2.4 (expat: utf8_toUtf8 cannot properly handle exhausting buffer)

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
keywords: +patch
pull_requests: +3559
stage: resolved -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31170] Update to expat 2.2.4 (expat: utf8_toUtf8 cannot properly handle exhausting buffer)

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:

I wrote an non-regression test for the Python master branch using the test case 
attached to https://github.com/libexpat/libexpat/issues/115: PR 3570.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Ravikumar

New submission from Ravikumar:

I have started learning python and I see below snippet fails. I do not 
understand how to fix the issue and assume this might be a bug in 
multiprocessing library.

I use Python 2.7.12


My python snippet

import xml.etree.ElementTree as ET# WORKS
import xml.etree.cElementTree as ET# DOES NOT WORK
import multiprocessing

tree = ET.parse('country_data.xml')
root = tree.getroot()

manager = multiprocessing.Manager()
elems_saved = manager.dict()

elems_saved["1"]=root


/tmp/Python$ cat country_data.xml 



1
2008
141100




/tmp/Python$


OUTPUT

/tmp/Python$ python testxml.py 
Traceback (most recent call last):
  File "testxml.py", line 10, in 
elems_saved["1"]=root
  File "", line 2, in __setitem__
  File "/usr/lib/python2.7/multiprocessing/managers.py", line 758, in 
_callmethod
conn.send((self._id, methodname, args, kwds))
TypeError: expected string or Unicode object, NoneType found

Please let me know if I am wrong

--
components: Library (Lib), XML
messages: 302164
nosy: poojariravi
priority: normal
severity: normal
status: open
title: cElementTree behaves differently compared to ElementTree
type: behavior
versions: Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Ravikumar

Ravikumar added the comment:

Thanks for the quick update. It helped us to understand the issue.

We will check of how to proceed further in our implementation.

/ Ravi

--
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: the core values of the Python "platform"

2017-09-14 Thread Rhodri James

On 14/09/17 03:22, Stefan Ram wrote:

Ben Finney  writes (special characters edited):

As I understand it, "flat is better than nested" is talking about
*hierarchies* in a code base. It's not IIUC referring to anything about
the difference between expressions like you wrote.


   I have read »import this« again, after reading the above,
   but there was no indication whatsoever in it that says that
   it was talking about "*hierarchies* in a code base" only.


In any short, pithy commentary like the Zen, a great deal of what is 
said is implicit.  Given your very literalist interpretations, I would 
suggest that trying to make deductions based on the Zen is a waste of time.


--
Rhodri James *-* Kynesim Ltd
--
https://mail.python.org/mailman/listinfo/python-list


[issue30860] Consolidate stateful C globals under a single struct.

2017-09-14 Thread Eric Snow

Changes by Eric Snow :


--
pull_requests: +3556

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31420] Reference leaks introduced by bpo-30860

2017-09-14 Thread Eric Snow

Changes by Eric Snow :


--
pull_requests: +3557

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31374] expat: warning: "_POSIX_C_SOURCE" redefined

2017-09-14 Thread Christian Heimes

Changes by Christian Heimes :


--
keywords: +patch
pull_requests: +3560
stage: needs patch -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31392] Upgrade installers to OpenSSL 1.1.0f

2017-09-14 Thread Christian Heimes

Christian Heimes added the comment:

Ned, can you take care of macOS? Victor noted that master still builds with 
1.0.2k.

--
assignee: christian.heimes -> ned.deily

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31420] Reference leaks introduced by bpo-30860

2017-09-14 Thread Eric Snow

Eric Snow added the comment:


New changeset dae0276bb6bc7281d59fb0b8f1aab31634ee80dc by Eric Snow in branch 
'master':
bpo-30860: Fix a refleak. (#3567)
https://github.com/python/cpython/commit/dae0276bb6bc7281d59fb0b8f1aab31634ee80dc


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30860] Consolidate stateful C globals under a single struct.

2017-09-14 Thread Eric Snow

Eric Snow added the comment:


New changeset dae0276bb6bc7281d59fb0b8f1aab31634ee80dc by Eric Snow in branch 
'master':
bpo-30860: Fix a refleak. (#3567)
https://github.com/python/cpython/commit/dae0276bb6bc7281d59fb0b8f1aab31634ee80dc


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: "tkinter"

2017-09-14 Thread Steven D'Aprano
On Thu, 14 Sep 2017 17:01:30 +1000, Ben Finney wrote:

> Steven D'Aprano  writes:
> 
>> (1) Separate T K and INTER syllables.
>>
>> But the problem with that is that there's very little (but not none
>> whatsoever) precedence for sounding out letters individually in English
>> words.
> 
> It's not an English word. Yet we are still called upon to pronounce it.

This is the first time I've heard an English language jargon word 
described as "not English". If it is not English, what is it? You 
wouldn't typeset it in italics as a foreign word, would you?

The "tk" part comes from a pair of initialisms:

Tcl ("Tool Command Language") 

Tk ("Tool Kit")


and the "inter" is an abbreviation for "interface".


That makes it as English as any other jargon used by English speakers.



>> Hence that should really be spelled:
>>
>> Teekayinter
>>
>> which looks hideous.
> 
> There is plenty of precedent for pronouncing other initialisms. When
> they don't make a nice word (i.e. when they are not an acronym), we tend
> to spell them out for clear communication.

By definition, if an acronym doesn't make a nice word, its an initialism. 
(In other words, all initialisms are acronyms, but not all acronyms are 
initialisms.)

http://www.quickanddirtytips.com/education/grammar/abbreviations-acronyms-
and-initialisms


On the other hand... there are initialisms which are never, or hardly 
ever, spelled out letter by letter either. I don't know anyone who spells 
out "N S W" for NSW (New South Wales), or "Q L D" for Queensland, for 
example. They always expand the acronym and pronounce the full words.


> That's IMO support for “tee kay inter” pronunciation of “Tkinter”.


I don't mind you saying "tee kay inter" so long as you don't mind me 
saying "N A Sa".

*wink*



-- 
Steven D'Aprano
“You are deluded if you think software engineers who can't write 
operating systems or applications without security holes, can write
virtualization layers without security holes.” —Theo de Raadt
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue21537] functools.lru_cache does not cache exceptions

2017-09-14 Thread Sviatoslav Sydorenko

Sviatoslav Sydorenko added the comment:

Hi,

I've got similar need (caching exceptions). My use case is syscall, which is 
not going to result in something different regardless of the number of times 
it's called. But I'd like to be able to have exception already raised for me by 
lru_cache, so that I won't poke kernel with no need.

I'd suggest adding `cache_exceptions=False` key to the decorator to let user 
control whether it's worth enabling. This might be useful in stdlib.

--
nosy: +webknjaz

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31392] Upgrade installers to OpenSSL 1.1.0f

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:

FYI I wrote a script to get the version of all library copies embedded in 
CPython:
https://github.com/haypo/misc/blob/master/cpython/external_versions.py

This is how I noticed the OpenSSL version inconsistency.

--
nosy: +haypo

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31466] No easy way to change float formatting when subclassing encoder.JSONEncoder

2017-09-14 Thread Quentin Peter

New submission from Quentin Peter:

I want to output floats in ENG format. Working with distance in micrometers, it 
is a bit annoying to see:
2.5e-5
.0003
instead of 
25e-6
300e-6
The solution I found was to redefine `iterencode` but that doesn't feel right.

I would like to see something similar to the "default" function that is easely 
modified.

--
messages: 302162
nosy: qpeter
priority: normal
severity: normal
status: open
title: No easy way to change float formatting when subclassing 
encoder.JSONEncoder
type: enhancement
versions: Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31464] Remove trailing spaces from Python-ast.h

2017-09-14 Thread Serhiy Storchaka

New submission from Serhiy Storchaka:

Proposed PR makes Parser/asdl_c.py not emitting trailing spaces for blank lines 
in Include/Python-ast.h.

--
messages: 302149
nosy: benjamin.peterson, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Remove trailing spaces from Python-ast.h
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31447] proc communicate not exiting on python subprocess timeout using PIPES

2017-09-14 Thread Eryk Sun

Eryk Sun added the comment:

> Now I can read from the "R" pipes with 0 problems (getting the error 
> and output streams)

The pipe handles are inherited by waitfor.exe, just as before. You'll find that 
reading to EOF will block just as it does when using subprocess.PIPE with 
communicate(). For example:

stderr = open(errPipeR, 'r')
err = stderr.read()

The above stderr.read() will return when waitfor.exe either exits or gets 
terminated.

> and proc.communicate exits as soon as the called process exits 
> (4 seconds).

proc.stdout and proc.stderr are None in this case, so all communicate() can do 
is write to proc.stdin, if there's input text, and then wait() for the process 
to exit.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31466] No easy way to change float formatting when subclassing encoder.JSONEncoder

2017-09-14 Thread Quentin Peter

Changes by Quentin Peter :


--
keywords: +patch
pull_requests: +3561
stage:  -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:

Oh, test_concurrent_futures.test_exception_with_success() failed on Travis CI 
:-(

https://ci.appveyor.com/project/python/cpython/build/3.7.0a0.6457

test_exception_with_success (test.test_concurrent_futures.FutureTests) ... 
Warning -- threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 
2)
Dangling thread: 
Dangling thread: <_MainThread(MainThread, started 3656)>
ok

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:

test_threading.test_foreign_thread() failed:

http://buildbot.python.org/all/builders/AMD64%20FreeBSD%20CURRENT%20Debug%203.x/builds/879/steps/test/logs/stdio

0:08:53 load avg: 1.84 [286/405/1] test_threading failed (env changed) -- 
running: test_multiprocessing_spawn (51 sec)
(...)
test_dummy_thread_after_fork (test.test_threading.ThreadTests) ... ok
test_enumerate_after_join (test.test_threading.ThreadTests) ... ok
test_finalize_runnning_thread (test.test_threading.ThreadTests) ... ok
test_finalize_with_trace (test.test_threading.ThreadTests) ... ok
test_foreign_thread (test.test_threading.ThreadTests) ... Warning -- 
threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 1)
Dangling thread: <_MainThread(MainThread, started 34369060864)>
ok
test_frame_tstate_tracing (test.test_threading.ThreadTests) ... ok

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31465] Allow _PyType_Lookup() to raise exceptions

2017-09-14 Thread Stefan Behnel

New submission from Stefan Behnel:

Follow-up to issue 31336:
The fact that _PyType_Lookup() does not propagate exceptions leaves some space 
for ambiguity. If, in a chain of MRO lookups, one would fail and a later one 
would succeed, is it correct to keep trying? What if the first failure actually 
failed to see an otherwise existing attribute in that class? We simply can't 
know because the lookup failed for *some* reason.

I think, the only way to really avoid that ambiguity would be to allow 
_PyType_Lookup() to raise exceptions, and to make it fail on the first error.

--
components: Interpreter Core
messages: 302156
nosy: scoder
priority: normal
severity: normal
status: open
title: Allow _PyType_Lookup() to raise exceptions
type: behavior
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31464] Remove trailing spaces from Python-ast.h

2017-09-14 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
keywords: +patch
pull_requests: +3558

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31336] Speed up _PyType_Lookup() for class creation

2017-09-14 Thread Stefan Behnel

Stefan Behnel added the comment:

One more thing: the fact that the lookup does not propagate exceptions leaves 
some space for ambiguity. If, in a chain of MRO lookups, one would fail and a 
later one would succeed, is it correct to keep trying? What if the first 
failure actually failed to see an otherwise existing attribute in that class? 
We simply can't know because the lookup failed for *some* reason.

I think, the only way to really avoid that ambiguity would be to allow 
_PyType_Lookup() to raise exceptions, and to make it fail on the first error. 
I've created issue 31465 for this.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

This error is from cPickle.

>>> import xml.etree.cElementTree as ET
>>> root = ET.XML('')
>>> import pickle
>>> pickle.dumps(root)
Traceback (most recent call last):
  File "", line 1, in 
  File "/usr/lib/python2.7/pickle.py", line 1380, in dumps
Pickler(file, protocol).dump(obj)
  File "/usr/lib/python2.7/pickle.py", line 224, in dump
self.save(obj)
  File "/usr/lib/python2.7/pickle.py", line 331, in save
self.save_reduce(obj=obj, *rv)
  File "/usr/lib/python2.7/pickle.py", line 400, in save_reduce
save(func)
  File "/usr/lib/python2.7/pickle.py", line 286, in save
f(self, obj) # Call unbound method with explicit self
  File "/usr/lib/python2.7/pickle.py", line 754, in save_global
(obj, module, name))
pickle.PicklingError: Can't pickle : 
it's not found as __main__.copyelement
>>> import cPickle
>>> cPickle.dumps(root)
Traceback (most recent call last):
  File "", line 1, in 
TypeError: expected string or Unicode object, NoneType found

cElementTree.Element is not pickleable in Python 2. And I think it is too later 
to add this feature in 2.7. The obvious solution -- use Python 3.

--
nosy: +eli.bendersky, scoder, serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Use ElementTree. In Python 3 ElementTree is accelerated and cElementTree is a 
deprecated alias of ElementTree.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: The Incredible Growth of Python (stackoverflow.blog)

2017-09-14 Thread Mark Lawrence via Python-list

On 14/09/2017 05:37, Terry Reedy wrote:

On 9/13/2017 2:44 AM, Paul Rubin wrote:


Are there actually Py3 codebases?


Let's think a bit.  There is the Python half of the Python3 codebase, 
perhaps 400K.  But we can discount that.


Then there are all the Py compatible modules on PyPI, which is to say, 
most of the major one.  How could not not notice those?


One of them is a little project call Django.  I believe that this is the 
one slated to be 3.x only in its 2.0 version.


I believe at least one linux distribution uses Py 3 for its system python.

A year ago, a producers of a Unicode-based app sold internationallly 
announce that their next version would be Py 3 only.  When 3.3 came out 
with the new Unicode implementation, they developed a 3.3 version of the 
app.  By 3.5, they realized that 3.3+ unicode made things much easier, 
wile maintaining the 2.7 version was painful by comparison.  They asked 
their (non-programmer) customers if they already used the 3.x version or 
could install 3.x to run the 3.x version.  95% said yes to one of these. 
  So they decided that the next version, early this year, would be 3.x 
only.


Have you ever hear of a little startup called 'Instagram'?  Earlier this 
year, they announce that they had about finished an 18 month process of 
switching most of their Python code to 3.x.  They described in fair 
detail how they did it.  Really impressive.




Not quite there yet but according to this 
https://www.reddit.com/r/Python/comments/6z6wst/twisted_is_93_ported_to_python_3/ 
a little project called Twisted is 93% ported to Python 3.


--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

---
This email has been checked for viruses by AVG.
http://www.avg.com


--
https://mail.python.org/mailman/listinfo/python-list


ANN: NumExpr 2.6.3 release

2017-09-14 Thread Robert McLeod
Hi everyone,

This is primarily a maintenance release that fixes a number of newly
discovered
bugs. The NumPy requirement has increased from 1.6 to 1.7 due to changes
with
`numpy.nditer` flags. Thanks to Caleb P. Burns `ceil` and `floor` functions
are
now supported.

Project documentation is now available at:

http://numexpr.readthedocs.io/

=
 Announcing Numexpr 2.6.3
=

Changes from 2.6.2 to 2.6.3
-

- Documentation now available at numexpr.readthedocs.io
- Support for floor() and ceil() functions added by Caleb P. Burns.
- NumPy requirement increased from 1.6 to 1.7 due to changes in iterator
  flags (#245).
- Sphinx autodocs support added for documentation on readthedocs.org.
- Fixed a bug where complex constants would return an error, fixing
  problems with `sympy` when using NumExpr as a backend.
- Fix for #277 whereby arrays of shape (1,...) would be reduced as
  if they were full reduction. Behavoir now matches that of NumPy.
- String literals are automatically encoded into 'ascii' bytes for
  convience (see #281).

What's Numexpr?
---

Numexpr is a fast numerical expression evaluator for NumPy.  With it,
expressions that operate on arrays (like "3*a+4*b") are accelerated
and use less memory than doing the same calculation in Python.

It has multi-threaded capabilities, as well as support for Intel's
MKL (Math Kernel Library), which allows an extremely fast evaluation
of transcendental functions (sin, cos, tan, exp, log...) while
squeezing the last drop of performance out of your multi-core
processors.  Look here for a some benchmarks of numexpr using MKL:

https://github.com/pydata/numexpr/wiki/NumexprMKL

Its only dependency is NumPy (MKL is optional), so it works well as an
easy-to-deploy, easy-to-use, computational engine for projects that
don't want to adopt other solutions requiring more heavy dependencies.

Where I can find Numexpr?


The project is hosted at GitHub in:

https://github.com/pydata/numexpr

You can get the packages from PyPI as well (but not for RC releases):

http://pypi.python.org/pypi/numexpr

Documentation is hosted at:

http://numexpr.readthedocs.io/en/latest/

Share your experience
--

Let us know of any bugs, suggestions, gripes, kudos, etc. you may
have.


Enjoy data!

-- 
Robert McLeod, Ph.D.
robbmcl...@gmail.com
robbmcl...@protonmail.com
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> wont fix

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Ravikumar

Changes by Ravikumar :


--
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



ANN: Bokeh 0.12.9 Released

2017-09-14 Thread Bryan Van de ven
On behalf of the Bokeh team, I am pleased to announce the release of version 
0.12.9 of Bokeh!

OF SPECIAL NOTE: *** JupyterLab and Fast Array Transport now supported ***

Please see the announcement post at:

https://bokeh.github.io/blog/2017/9/12/release-0-12-9/

which has more information and demonstrations. 

If you are using Anaconda/miniconda, you can install it with conda:

conda install -c bokeh bokeh

Alternatively, you can also install it with pip:

pip install bokeh

Full information including details about how to use and obtain BokehJS are at:

http://bokeh.pydata.org/en/0.12.9/docs/installation.html

Issues, enhancement requests, and pull requests can be made on the Bokeh Github 
page: https://github.com/bokeh/bokeh

Documentation is available at http://bokeh.pydata.org/en/0.12.9

There are over 250 total contributors to Bokeh and their time and effort help 
make Bokeh such an amazing project and community. Thank you again for your 
contributions. 

Finally (as always), for questions, technical assistance or if you're 
interested in contributing, questions can be directed to the Bokeh mailing 
list: bo...@continuum.io or the Gitter Chat room: https://gitter.im/bokeh/bokeh

Thanks,

Bryan Van de Ven
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


Re: The Incredible Growth of Python (stackoverflow.blog)

2017-09-14 Thread Christopher Reimer
> On Sep 13, 2017, at 10:12 PM, Paul Rubin  wrote:
> 
> Ben Finney  writes:
>>> I've never seen one.
>> who has told you... they are working on a Python 3 code base.
> 
> Just because they've told me about it doesn't mean I saw it personally.
> The ones I've seen, including new ones, are Python 2.
> 
> Some people here use Py3 but I haven't heard (or don't remember) enough
> about what they're working on, to know if those are py3 codebases of any
> size.  If they say yes, I'll take their word for it, but this is a
> self-selected group of course.
> 
>> That simply isn't true, unless you think it more likely everyone who
>> discusses their Python 3 code base is lying.
> 
> People discuss Python language issues here a lot, but don't discuss as
> much about code bases.
> 
> I know when I install a new OS (currently Debian 9 which was released
> a month or so ago) and type "python" on the command line, I get Py2.
> -- 
> https://mail.python.org/mailman/listinfo/python-list

FreeNAS 11 (based on FreeBSD) has Python 3.6.1 installed and uses Django for 
the web interface.

Chris R.
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue31471] assertion failure in subprocess.Popen() in case the env arg has a bad keys() method

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
nosy: +haypo, serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31462] Remove trailing whitespaces

2017-09-14 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I plan to backport the idlelib changes.  Do you prefer than I try to include 
other files (by using cherry-pick) or only do idlelib (probably much easier)?

--
nosy: +terry.reedy

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
pull_requests: +3569

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
pull_requests: +3562

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31469] Running inside docker container from non-root user

2017-09-14 Thread Dmitriy

New submission from Dmitriy:

When i try to run youtube-dl inside docker container from non root user i 
recieve this error:

failed to import the site module traceback (most recent call last): file 
"/usr/lib/python3.6/site.py", line 544, in main() file 
"/usr/lib/python3.6/site.py", line 530, in main known_paths = 
addusersitepackages(known_paths) file "/usr/lib/python3.6/site.py", line 282, 
in addusersitepackages user_site = getusersitepackages() file 
"/usr/lib/python3.6/site.py", line 258, in getusersitepackages user_base = 
getuserbase() # this will also set user_base file "/usr/lib/python3.6/site.py", 
line 248, in getuserbase user_base = get_config_var('userbase') file 
"/usr/lib/python3.6/sysconfig.py", line 601, in get_config_var return 
get_config_vars().get(name) file "/usr/lib/python3.6/sysconfig.py", line 558, 
in get_config_vars _config_vars['userbase'] = _getuserbase() file 
"/usr/lib/python3.6/sysconfig.py", line 205, in _getuserbase return 
joinuser("~", ".local") file "/usr/lib/python3.6/sysconfig.py", line 184, in 
joinuser return os.path.expanduser(os.path.join(*args)) file 
"/usr/lib/python3.6/posi
 xpath.py", line 247, in expanduser userhome = pwd.getpwuid(os.getuid()).pw_dir 
keyerror: 'getpwuid(): uid not found: 1000'

I believe this problem is described here:
http://blog.dscpl.com.au/2015/12/unknown-user-when-running-docker.html

this simple fix make it work again

--
components: Library (Lib)
messages: 302172
nosy: cinerar
priority: normal
pull_requests: 3563
severity: normal
status: open
title: Running inside docker container from non-root user
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
pull_requests: +3564

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue10496] Python startup should not require passwd entry

2017-09-14 Thread R. David Murray

R. David Murray added the comment:

Unless I'm mistaken, this has come up again in issue 31469.

--
nosy: +cinerar, r.david.murray

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31457] LoggerAdapter objects cannot be nested

2017-09-14 Thread Łukasz Langa

Łukasz Langa added the comment:


New changeset 1bbd482bcf6ea36bfe488f868810ffe110238ae1 by Łukasz Langa in 
branch 'master':
bpo-31457: Allow for nested LoggerAdapter objects (#3551)
https://github.com/python/cpython/commit/1bbd482bcf6ea36bfe488f868810ffe110238ae1


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31457] LoggerAdapter objects cannot be nested

2017-09-14 Thread Roundup Robot

Changes by Roundup Robot :


--
pull_requests: +3567

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30809] IDLE parenmatch - highlighting options

2017-09-14 Thread Charles Wohlganger

Changes by Charles Wohlganger :


--
pull_requests:  -2554

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30809] IDLE parenmatch - highlighting options

2017-09-14 Thread Charles Wohlganger

Changes by Charles Wohlganger :


--
keywords: +patch
pull_requests: +3565
stage: needs patch -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31469] Running inside docker container from non-root user

2017-09-14 Thread R. David Murray

R. David Murray added the comment:

It sounds like docker is just broken (I would expect unix tools to work in a 
docker container).  That however is beside the point.

I believe this is a duplicate of issue 10496, but I don't know why it hasn't 
been fixed.

--
nosy: +r.david.murray
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
type:  -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31469] Running inside docker container from non-root user

2017-09-14 Thread R. David Murray

Changes by R. David Murray :


--
superseder:  -> Python startup should not require passwd entry

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:


New changeset 18e95b4176256f100429a806d0455406df98f984 by Victor Stinner in 
branch 'master':
bpo-31234: Join threads in tests (#3572)
https://github.com/python/cpython/commit/18e95b4176256f100429a806d0455406df98f984


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:


New changeset 8dcf22f442320e4c1a5408e67b4c9002ad105f17 by Victor Stinner in 
branch 'master':
bpo-31234: Join threads in test_hashlib (#3573)
https://github.com/python/cpython/commit/8dcf22f442320e4c1a5408e67b4c9002ad105f17


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31471] assertion failure in subprocess.Popen() in case the env arg has a bad keys() method

2017-09-14 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
stage:  -> needs patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28411] Eliminate PyInterpreterState.modules.

2017-09-14 Thread Eric Snow

Changes by Eric Snow :


--
pull_requests: +3566
stage: needs patch -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31470] Py_Initialize documentation wrong

2017-09-14 Thread Jim Jewett

New submission from Jim Jewett:

Per 
https://docs.python.org/3/c-api/init.html#initializing-and-finalizing-the-interpreter
 Py_Initialize() "should be called before using any other Python/C API 
functions; with the exception of Py_SetProgramName(), Py_SetPythonHome() and 
Py_SetPath()."


(1)  I suspect that should be either Py_Initialize() or Py_InitializeEx().

(2)  Other functions can also be called first.  The ones I notice are:
(2a)  Py_IsInitialized() wouldn't be useful if you couldn't call it first.
(2b)  Py_SetStandardStreamEncoding explicitly says it *should* be called before 
Py_Initialize, if it is called at all.



(Probably applies to earlier python versions as well.)

--
assignee: docs@python
components: Documentation
messages: 302179
nosy: Jim.Jewett, docs@python
priority: normal
severity: normal
status: open
title: Py_Initialize documentation wrong
versions: Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31462] Remove trailing whitespaces

2017-09-14 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Usually we don't backport such kind of changes. And I afraid that 
cherry-picking would be with many conflicts, because many changes are in new 
code. The idlelib changes are more harmless, since they are in text files.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
pull_requests: +3568

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31471] assertion failure in subprocess.Popen() in case the env arg has a bad keys() method

2017-09-14 Thread Oren Milman

New submission from Oren Milman:

The following code causes an assertion failure on Windows:
class BadEnv(dict):
keys = None

import subprocess

import sys

subprocess.Popen([sys.executable, "-c", "pass"], env=BadEnv())


this is because getenvironment() (in Modules/_winapi.c) calls PyMapping_Values()
immediately after calling PyMapping_Keys().
calling PyMapping_Values() ultimately leads to calling _PyObject_FastCallDict(),
which does 'assert(!PyErr_Occurred());'.
thus, in case of an error in PyMapping_Keys(), the assertion fails.

--
components: Extension Modules
messages: 302181
nosy: Oren Milman
priority: normal
severity: normal
status: open
title: assertion failure in subprocess.Popen() in case the env arg has a bad 
keys() method
type: crash
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: ttk.Notebook Tabs Question

2017-09-14 Thread Abdur-Rahmaan Janhangeer
try
widget["width"] it returns string
then mult by no. of tabs


Abdur-Rahmaan Janhangeer,
Mauritius
abdurrahmaanjanhangeer.wordpress.com

On 12 Sep 2017 06:45, "Wildman via Python-list" 
wrote:

> I am working on a program that has a ttk.Notebook with
> 12 tabs.  Is there a way to determine the total width
> of the tabs in pixels.  Just to be clear I am not talking
> about width of the nb container.  I am talking about
> tabs themselves that contain the text.
>
> I want the program to be resizable but I don't want to
> allow the window width to fall below that of the tabs
> which would hide them.  Since I can find no way to have
> more than one row of tabs, this appears to be my only
> option.  Any suggestions would be appreciated.
>
> --
>  GNU/Linux user #557453
> May the Source be with you.
> --
> https://mail.python.org/mailman/listinfo/python-list
>
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue31464] Remove trailing spaces from Python-ast.h

2017-09-14 Thread Benjamin Peterson

Benjamin Peterson added the comment:


New changeset 5d84cb368c0c3e475c25171c302068c4dfc3e396 by Benjamin Peterson 
(Serhiy Storchaka) in branch 'master':
bpo-31464: asdl_c.py no longer emits trailing spaces in Python-ast.h. (#3568)
https://github.com/python/cpython/commit/5d84cb368c0c3e475c25171c302068c4dfc3e396


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31471] assertion failure in subprocess.Popen() in case the env arg has a bad keys() method

2017-09-14 Thread Oren Milman

Oren Milman added the comment:

in 2.7 getenvironment() is in PC/_subprocess.c, and it also calls 
PyMapping_Values()
immediately after calling PyMapping_Keys().
however, _PyObject_FastCallDict() doesn't exist here.
in case of an error in both PyMapping_Keys() and PyMapping_Values(), the
error in PyMapping_Values() just overwrites the error in PyMapping_Keys().

but I haven't gone over all of the code that could be run as part of
PyMapping_Values(), so I am not sure whether something could go wrong in case 
PyMapping_Keys() failed.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31462] Remove trailing whitespaces

2017-09-14 Thread Terry J. Reedy

Terry J. Reedy added the comment:


New changeset 93d5f91fff5740b463980797a04f3d5f1d5f1a51 by Terry Jan Reedy in 
branch '3.6':
[3.6] bpo-31462: IDLE - remove trailing whitespaces (GH-3564) (#3594)
https://github.com/python/cpython/commit/93d5f91fff5740b463980797a04f3d5f1d5f1a51


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31464] Remove trailing spaces from Python-ast.h

2017-09-14 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31478] assertion failure in random.seed() in case the seed argument has a bad __abs__() method

2017-09-14 Thread Oren Milman

Oren Milman added the comment:

sure.
but what about the TypeError message? should it complain about
the return value of abs(seed)? (the docs of random.seed don't mention abs().)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: version of Python to install Windows 7 professional 64 bit, intel core i5

2017-09-14 Thread Abdur-Rahmaan Janhangeer
i'd recommend 3.4 or 3.6
python version is chosen more for python functionality rather than hardware
type.

Abdur-Rahmaan Janhangeer,
Mauritius
abdurrahmaanjanhangeer.wordpress.com

On 12 Sep 2017 07:38, "Zubair Shaikh"  wrote:

>  What version of Python to install Windows 7 professional 64 bit, intel
> core i5
> --
> https://mail.python.org/mailman/listinfo/python-list
>
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue30096] Update examples in abc documentation to use abc.ABC

2017-09-14 Thread Vedran Čačić

Vedran Čačić added the comment:

Well, actually, Raymond was proposing an alternative to Py2's special 
__metaclass__ attribute assignment syntax, which honestly _is_ an abomination 
(and the big part of reason why that was changed in Py3 to a keyword argument 
in a class definition).

And Guido missed the point that in frameworks such as Django, the inheritance 
is the main thing people want, metaclasses just being a technical 
implementation detail (the easiest proof is that with modern descriptors with 
__set_name__ and ordered class namespaces, it's unnecessary to use metaclasses 
in Django model implementation at all). Here it is exactly the opposite.

As I said in the linked comment, I think we missed the opportunity to make 
Python much more powerful, practically shunning the idea of keyword arguments 
in a class definition totally. But as it is said, Guido's will  be done. :-) 
Thanks for the link.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31338] Use abort() for code we never expect to hit

2017-09-14 Thread Barry A. Warsaw

Changes by Barry A. Warsaw :


--
resolution:  -> fixed
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31338] Use abort() for code we never expect to hit

2017-09-14 Thread Barry A. Warsaw

Barry A. Warsaw added the comment:


New changeset b2e5794870eb4728ddfaafc0f79a40299576434f by Barry Warsaw in 
branch 'master':
bpo-31338 (#3374)
https://github.com/python/cpython/commit/b2e5794870eb4728ddfaafc0f79a40299576434f


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31462] Remove trailing whitespaces

2017-09-14 Thread Terry J. Reedy

Changes by Terry J. Reedy :


--
pull_requests: +3585

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31478] assertion failure in random.seed() in case the seed argument has a bad __abs__() method

2017-09-14 Thread Raymond Hettinger

Raymond Hettinger added the comment:

It would make sense to verify that an actual int was returned and to raise a 
TypeError if it wasn't.  

Do you want to submit a PR (with a test case)?

--
nosy: +rhettinger, serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31467] cElementTree behaves differently compared to ElementTree

2017-09-14 Thread Ravikumar

Ravikumar added the comment:

Just now I have figured out that , in the documentation it was mentioned that 
cElementTree module is deprecated in Python 3.3 version. 

"The xml.etree.ElementTree module implements a simple and efficient API for 
parsing and creating XML data.

Changed in version 3.3: This module will use a fast implementation whenever 
available. The xml.etree.cElementTree module is deprecated."

https://docs.python.org/3/library/xml.etree.elementtree.html


In that case, will your resolution comment still holds valid ??
If so then, how to use cElementTree in my usecase

--
status: closed -> open

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31455] ElementTree.XMLParser() mishandles exceptions

2017-09-14 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I agree. While these issues are not totally independent (they changes the same 
code), my issue needs uncommon use of __new__ and __init__, while your issue 
can be exposed in normal cases.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31468] os.path.samefile fails on windows network drive

2017-09-14 Thread Daniel Sauer

New submission from Daniel Sauer:

On my Windows network drive os.path.samefile() seems to return True regardless 
of input paths. In my case this results in an error trying to save checkpoints 
of jupyter notebooks on this drive.
I am using Windows 7, my working directory is located on a network drive that 
is offline-available (CSC cache).
Tracing this problem back it seems to have something to do with 
nt._getfinalpathname() reporting a wrong result.

--
components: Windows
messages: 302170
nosy: Daniel Sauer, paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: os.path.samefile fails on windows network drive
type: behavior
versions: Python 3.5

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-09-14 Thread Cheryl Sabella

Cheryl Sabella added the comment:

Sorry I don't have any tests yet.  I've added a few, but it's taking me forever 
to figure out the bindings for testing the `Double-Button-1` and `B1-Motion`.  
I actually have a test for `Double-Button-1` now, but still working on 
`B1-Motion`.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue11874] argparse assertion failure with brackets in metavars

2017-09-14 Thread wim glenn

Changes by wim glenn :


--
versions: +Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31478] assertion failure in random.seed() in case the seed argument has a bad __abs__() method

2017-09-14 Thread Oren Milman

New submission from Oren Milman:

The following code causes an assertion failure:
class BadInt(int):
def __abs__(self):
return None

import random

random.seed(BadInt())


this is because random_seed() (in Modules/_randommodule.c) assumes that
PyNumber_Absolute() returned an int, and so it passes it to _PyLong_NumBits(),
which asserts it received an int.


what should we do in such a case?
should we raise an exception? (the docs don't mention abs() in case the seed is
an int - https://docs.python.org/3.7/library/random.html#random.seed)

--
components: Extension Modules
messages: 302208
nosy: Oren Milman
priority: normal
severity: normal
status: open
title: assertion failure in random.seed() in case the seed argument has a bad 
__abs__() method
type: crash
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

Changes by STINNER Victor :


--
pull_requests: +3577

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28556] typing.py upgrades

2017-09-14 Thread Łukasz Langa

Łukasz Langa added the comment:


New changeset 1658ec07577ef9696cea76fcf7fac2da18403ec5 by Łukasz Langa (Miss 
Islington (bot)) in branch '3.6':
[3.6] bpo-28556: typing.get_type_hints: better globalns for classes and modules 
(GH-3582) (#3583)
https://github.com/python/cpython/commit/1658ec07577ef9696cea76fcf7fac2da18403ec5


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: Change project licence?

2017-09-14 Thread Michael Torrie
On 09/14/2017 11:22 AM, Kryptxy via Python-list wrote:
> Hi,
> I have an opensource (python) project under GPL3 licence. I wish
> switch to MIT licence so as to make it more permissive. I know how to
> change the licence, but I want to know is it fine and wise to change
> the licence at this point? (The project already has 19 clones, 250+
> GitHub stars. Here: https://github.com/kryptxy/torrench)

If you are the sole copyright holder on the project, and haven't taken
in any contributions from anyone else, then you can change the license
however you like, regardless of clones/forks, with the caveat below.

If you've integrated pull's from other people, then they now own a piece
of the copyright and you would have to talk to each person and get
permission to relicense their code contribution.  Note that clone of
your repo does not constitute a contribution. I'm talking about a pull
request or patch that was contributed to your mainline repo.

Finally, even if you are the sole copyright holder, while you can change
the license on your code at any time to any terms, you cannot change the
license on code that has already been forked under your original GPLv3
license. In other words, if someone clones your project before the
license change, they can continue under original license, as per its
terms.  You can't retroactively change the license on code that's
already been distributed, at least under the terms of the GPLv3. (I'm
sure there's some license somewhere that expressly states the terms can
be retroactively modified. But not the GPLv3.)
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:


New changeset ff40ecda73178dfcad24e26240d684356ef20793 by Victor Stinner in 
branch 'master':
bpo-31234: Add test.support.wait_threads_exit() (#3578)
https://github.com/python/cpython/commit/ff40ecda73178dfcad24e26240d684356ef20793


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:


New changeset b8c7be2c523b012e57915182543d06657161057f by Victor Stinner in 
branch 'master':
bpo-31234: Join threads in test_threading (#3579)
https://github.com/python/cpython/commit/b8c7be2c523b012e57915182543d06657161057f


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: Change project licence?

2017-09-14 Thread Chris Angelico
On Fri, Sep 15, 2017 at 6:04 AM, Michael Torrie  wrote:
> Finally, even if you are the sole copyright holder, while you can change
> the license on your code at any time to any terms, you cannot change the
> license on code that has already been forked under your original GPLv3
> license. In other words, if someone clones your project before the
> license change, they can continue under original license, as per its
> terms.  You can't retroactively change the license on code that's
> already been distributed, at least under the terms of the GPLv3. (I'm
> sure there's some license somewhere that expressly states the terms can
> be retroactively modified. But not the GPLv3.)

This is true; however the choice of license makes this moot. Code
licensed MIT can be used in anything, so it can be GPL3'd to go into
another project or anything. But yes, the old versions will still be
available under the terms of the GPL3; you can make them *also*
available under another license, but you aren't revoking the previous
one.

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue31234] Make support.threading_cleanup() stricter

2017-09-14 Thread STINNER Victor

STINNER Victor added the comment:


New changeset 167cbde50a88ec2a7d26b2cb9891d5e32bdfbfb5 by Victor Stinner in 
branch 'master':
bpo-31234: Join threads in test_queue (#3586)
https://github.com/python/cpython/commit/167cbde50a88ec2a7d26b2cb9891d5e32bdfbfb5


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31454] Include "import as" in documentation

2017-09-14 Thread Steve Johnson

Steve Johnson added the comment:

In the 2.7 Tutorial, section 6, modules, where it describes the various syntax 
for using import. 

> On Sep 13, 2017, at 10:42 AM, R. David Murray  wrote:
> 
> 
> R. David Murray added the comment:
> 
> Where do you find that it is not documented that you would expect it to be?  
> Because 'import' 'as' is certainly documented.
> 
> --
> nosy: +r.david.murray
> 
> ___
> Python tracker 
> 
> ___

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31452] asyncio.gather does not cancel tasks if one fails

2017-09-14 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Yuri, it looks like a serious bug.

I expected `success_coro(5)` cancelling but see print out.

--
components: +Library (Lib)
stage:  -> needs patch
versions: +Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31474] [2.7] Fix -Wnonnull and -Wint-in-bool-context warnings

2017-09-14 Thread Christian Heimes

Changes by Christian Heimes :


--
versions: +Python 2.7 -Python 3.3

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31452] asyncio.gather does not cancel tasks if one fails

2017-09-14 Thread Yury Selivanov

Yury Selivanov added the comment:

Andrew, looks like it.  You can take a look if you want (I don't have time to 
work on this right now).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31472] "Emulating callable objects" documentation misleading

2017-09-14 Thread Nathan Marrow

New submission from Nathan Marrow:

The documentation for emulating callable objects with __call__ seems to imply 
only positional arguments are supported. For instance, it says __call__ is 
"object.__call__(self[, args…])" and describes:

Called when the instance is “called” as a function; if this method is defined, 
x(arg1, arg2, ...) is a shorthand for x.__call__(arg1, arg2, ...).

When it should be something like (Not sure exactly what the syntax would be 
here):
"object.__call__(self[, args…] [,**kwargs...])"

Called when the instance is “called” as a function; if this method is defined, 
x(arg1, arg2, ..., arg3=arg3) is a shorthand for x.__call__(arg1, arg2, ..., 
arg3=arg3).

--
assignee: docs@python
components: Documentation
messages: 302185
nosy: docs@python, nmarrow
priority: normal
severity: normal
status: open
title: "Emulating callable objects" documentation misleading
versions: Python 2.7, Python 3.3, Python 3.4, Python 3.5, Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31475] Bug in argparse - not supporting utf8

2017-09-14 Thread R. David Murray

R. David Murray added the comment:

As I requested in the PR, please provide a way to reproduce the bug you are 
reporting.

--
nosy: +r.david.murray

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31475] Bug in argparse - not supporting utf8

2017-09-14 Thread R. David Murray

R. David Murray added the comment:

Note that as far as I know without a reproducer, it is confusing to me to talk 
about argparse supporting or not supporting utf8.  It deals only with text 
strings, which are unicode.  Or is this a 2.7 only bug report?  (Although even 
there it would be a question of unicode support, not utf8).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31438] IDLE 3 crashes and quits when caret character typed

2017-09-14 Thread ALPER PAKSOY

ALPER PAKSOY added the comment:

Problem has been solved after installation of ActiveTcl 8.5.18.0 from 
ActiveState's web site as per Terry’s recommendations and, then, reinstallation 
of Python 3.6.2 package from python.org. However, there were many (mis)steps 
per my ignorance and laziness in between. Thank you very much for all the help!

Noteworthy case notes:

1. The previously installed IDLE 3.6.2 as part of the Python 3.6.2 package 
continued crashing whenever I entered the caret character after the 
installation of ActiveTcl 8.5.18.0. I noticed that the IDLE’s Tk version showed 
8.5.9 even after I installed, as recommended, ActiveTcl 8.5.18.0, and rebooted 
my computer. Note that the “info patchlevel” script I executed within tclsh had 
started returning “8.5.18” instead of “8.5.9” after the installation of 
ActiveTcl 8.5.18.0.

2. I could not find a way to make the existing Python / IDLE 3.6.2 installation 
recognise ActiveTcl 8.5.18.0 as the IDLE’s Tk version kept showing 8.5.9. 
Therefore, I  reinstalled the Python 3.6.2 package downloaded from python.org. 
The package made the installation to a new location rather than overwriting the 
existing Python / IDLE 3.6.2 files.

3. The newly installed IDLE 3.6.2 has been working fine without showing any 
signs of instability. There are no crashes when I type the caret character. Its 
Tk version shows 8.5.18 along with the tclsh interpreter. 

4. I removed all the files associated with the “buggy” Python / IDLE 3.6.2 
installation via the terminal window in order to prevent any future confusion 
between the old and new installations.

5. Though I installed ActiveTcl 8.6.6.8606 from ActiveState’s web site in my 
earlier trials, I don’t think I was able to fully test whether this latest Tcl 
really works with Python / IDLE 3.6.2 or not. After installing ActiveTcl 
8.6.6.8606, the “info patchlevel” I executed within tchlsh started returning 
“8.6.6” but the (old) IDLE 3.6.2’s Tk version still showed 8.5.9. I, then, 
installed ActiveTcl 8.5.18.0 after uninstalling ActiveTcl 8.6.6.8606 as a 
precaution. It  occurred to me that I may need to reinstall the Python 3.6.2 
package from python.org only after installing the ActiveTcl 8.5.18.0.

--
assignee:  -> terry.reedy
components: +IDLE -Tkinter, macOS
resolution:  -> fixed
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30096] Update examples in abc documentation to use abc.ABC

2017-09-14 Thread Éric Araujo

Éric Araujo added the comment:

> "Best practices" according to whom?

Well at least two senior core developers :)  See the rationale in #16049 when 
abc.ABC was first added (with Guido approving that inheritance is nicer for 
most people).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31471] assertion failure in subprocess.Popen() in case the env arg has a bad keys() method

2017-09-14 Thread Oren Milman

Changes by Oren Milman :


--
keywords: +patch
pull_requests: +3570
stage: needs patch -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: Change project licence?

2017-09-14 Thread Chris Angelico
On Fri, Sep 15, 2017 at 3:22 AM, Kryptxy via Python-list
 wrote:
> Hi,
> I have an opensource (python) project under GPL3 licence. I wish switch to 
> MIT licence so as to make it more permissive.
> I know how to change the licence, but I want to know is it fine and wise to 
> change the licence at this point?
> (The project already has 19 clones, 250+ GitHub stars. Here: 
> https://github.com/kryptxy/torrench)
>
> Thank you.

Only if every contributor says it's okay. Anything that you create
(and own copyright on), you can license under any terms you like; if
anyone else has contributed anything to the project, you have to get
their permission to relicense it.

For solo projects, that's simple. For huge things like the CPython
interpreter, it's virtually impossible.

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue28556] typing.py upgrades

2017-09-14 Thread Roundup Robot

Changes by Roundup Robot :


--
pull_requests: +3574

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28556] typing.py upgrades

2017-09-14 Thread Łukasz Langa

Łukasz Langa added the comment:


New changeset f350a268a7071ce7d7a5bb86a9b1229782d4963b by Łukasz Langa in 
branch 'master':
bpo-28556: typing.get_type_hints: better globalns for classes and modules 
(#3582)
https://github.com/python/cpython/commit/f350a268a7071ce7d7a5bb86a9b1229782d4963b


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31454] Include "import as" in tutorial

2017-09-14 Thread Steve Johnson

Steve Johnson added the comment:

I don't know what a PR is, so I'll let you guys handle it if it is OK with you.

> On Sep 14, 2017, at 11:47 AM, R. David Murray  wrote:
> 
> 
> R. David Murray added the comment:
> 
> I agree that it would seem reasonable to add this to section 6.1 of the 
> tutorial, since it mentions both import statement variants and the modules 
> "global symbol table", which are the two concepts involved in import as.
> 
> Would you like to propose a PR?
> 
> --
> resolution: not a bug -> 
> stage: resolved -> needs patch
> status: closed -> open
> title: Include "import as" in documentation -> Include "import as" in tutorial
> 
> ___
> Python tracker 
> 
> ___

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31457] LoggerAdapter objects cannot be nested

2017-09-14 Thread Łukasz Langa

Łukasz Langa added the comment:


New changeset 20fa05d0223101b8e0005525b94a2eac892348de by Łukasz Langa (Miss 
Islington (bot)) in branch '3.6':
[3.6] bpo-31457: Allow for nested LoggerAdapter objects (GH-3551) (#3576)
https://github.com/python/cpython/commit/20fa05d0223101b8e0005525b94a2eac892348de


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31454] Include "import as" in tutorial

2017-09-14 Thread R. David Murray

R. David Murray added the comment:

I agree that it would seem reasonable to add this to section 6.1 of the 
tutorial, since it mentions both import statement variants and the modules 
"global symbol table", which are the two concepts involved in import as.

Would you like to propose a PR?

--
resolution: not a bug -> 
stage: resolved -> needs patch
status: closed -> open
title: Include "import as" in documentation -> Include "import as" in tutorial

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31454] Include "import as" in tutorial

2017-09-14 Thread R. David Murray

Changes by R. David Murray :


--
versions: +Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Change project licence?

2017-09-14 Thread Kryptxy via Python-list
Hi,
I have an opensource (python) project under GPL3 licence. I wish switch to MIT 
licence so as to make it more permissive.
I know how to change the licence, but I want to know is it fine and wise to 
change the licence at this point?
(The project already has 19 clones, 250+ GitHub stars. Here: 
https://github.com/kryptxy/torrench)

Thank you.
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue28556] typing.py upgrades

2017-09-14 Thread Łukasz Langa

Changes by Łukasz Langa :


--
pull_requests: +3573

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28411] Eliminate PyInterpreterState.modules.

2017-09-14 Thread Eric Snow

Eric Snow added the comment:


New changeset d393c1b227f22fb9af66040b2b367c99a4d1fa9a by Eric Snow in branch 
'master':
bpo-28411: Isolate PyInterpreterState.modules (#3575)
https://github.com/python/cpython/commit/d393c1b227f22fb9af66040b2b367c99a4d1fa9a


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31454] Include "import as" in documentation

2017-09-14 Thread Steve Johnson

Steve Johnson added the comment:

My suggestion was to include this in the 2.7 tutorial, section 6 (modules) 
where the various syntax is described for import. Most of us don't dig into the 
reference until we are trying to find something specific. The tutorial is an 
excellent place to introduce useful but not obvious features of the language.

> On Sep 13, 2017, at 12:15 PM, Mariatta Wijaya  wrote:
> 
> 
> Mariatta Wijaya added the comment:
> 
> import as is documented, so I'm closing this unless you have other concerns.
> 
> Python 3 docs: https://docs.python.org/3/reference/simple_stmts.html#import
> ```
> If the module name is followed by as, then the name following as is bound 
> directly to the imported module
> ```
> 
> Wording is somewhat different in Python 2.7 docs, but it's there: 
> https://docs.python.org/2.7/reference/simple_stmts.html#the-import-statement
> 
> Thanks.
> 
> --
> nosy: +Mariatta
> resolution:  -> not a bug
> stage:  -> resolved
> status: open -> closed
> 
> ___
> Python tracker 
> 
> ___

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   >