[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Steven D'Aprano


Change by Steven D'Aprano :


--
resolution:  -> rejected
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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread Eryk Sun


Eryk Sun  added the comment:

> ImportError: DLL load failed while importing _jpype: 
> A dynamic link library (DLL) initialization routine failed.

With loader snaps enabled for python[_d].exe (i.e. loader debug messages), you 
can attach a debugger to discover which DLL's init routine is failing. For 
example, you'll see a debug message like the following:

: @  - LdrpInitializeNode - ERROR:
Init routine  for DLL "Path\To\DLL"
failed during DLL_PROCESS_ATTACH

The entry point of a DLL is typically _DllMainCRTStartup, which initializes the 
CRT for the DLL and calls DllMain(). In any case, you can find the relative 
address of the entry point in the PE header, via dumpbin.exe or the debugger 
!dh command. Set a breakpoint on it and step through to find where it fails in 
comparison with a working environment.

--
nosy: +eryksun

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

I'm willing to give Irit and Jake opportunity to make their case. 
Particularly if they can demonstrate that I got my facts wrong.

I'm going to close the ticket, but if anyone feels strongly enough to 
respond with a good argument, or better still citations demonstrating 
that the comment is factually wrong, I am open to revising or removing 
the wording.

--

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

Steven, you are the module maintainer.  So if you're sure about the current 
wording, go ahead and close this.

--

___
Python tracker 

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



[issue42195] Inconsistent __args__ between typing.Callable and collections.abc.Callable

2020-12-18 Thread Ken Jin


Change by Ken Jin :


--
pull_requests: +22717
pull_request: https://github.com/python/cpython/pull/23852

___
Python tracker 

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



[issue42675] Document changes made in bpo-42195

2020-12-18 Thread Ken Jin


Change by Ken Jin :


--
pull_requests: +22716
pull_request: https://github.com/python/cpython/pull/23852

___
Python tracker 

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



[issue42470] DeprecationWarning triggers for sequences which happen to be sets as well

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

Given that this is rare and that it is a behavior change, I'm only applying 
this to 3.10.  If you think it is essential for 3.9, feel free to reopen and 
we'll discuss it with the release manager.

--
components: +Library (Lib)
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.10 -Python 3.9

___
Python tracker 

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



[issue42470] DeprecationWarning triggers for sequences which happen to be sets as well

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset 1e27b57dbc8c1b758e37a531487813aef2d111ca by masklinn in branch 
'master':
bpo-42470: Do not warn on sequences which are also sets in random.sample() 
(GH-23665)
https://github.com/python/cpython/commit/1e27b57dbc8c1b758e37a531487813aef2d111ca


--

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread Karl Nelson


Karl Nelson  added the comment:

The last libraries loaded prior to the failure were...

```
20201218192451066 20440 50.60: trclnk64: 
api-ms-win-eventing-provider-l1-1-0.dll [7ffc4c974108 7ffc4c8b7808]
20201218192451066 20440 50.60: trclnk64:   EventUnregister0 7ffc4eab37a0
20201218192451066 20440 50.60: trclnk64:   EventRegister0 7ffc4ea6a640
20201218192451066 20440 50.60: trclnk64:   EventActivityIdControl0 
7ffc4eac6190
20201218192451066 20440 50.60: trclnk64:   EventWriteTransfer0 7ffc4eab2cf0
20201218192451066 20440 50.60: trclnk64:   EventSetInformation0 7ffc4ea6a3e0
20201218192451066 20440 50.60: trclnk64: api-ms-win-core-apiquery-l1-1-0.dll 
[7ffc4c9740e8 7ffc4c8b77e8]
20201218192451066 20440 50.60: trclnk64:   ApiSetQueryApiSetPresence0 
7ffc4ead5030
20201218192451066 20440 50.60: trclnk64: api-ms-win-core-apiquery-l1-1-1.dll 
[7ffc4c9740f8 7ffc4c8b77f8]
20201218192451066 20440 50.60: trclnk64:   ApiSetQueryApiSetPresenceEx0 
7ffc4eb35730
```

And as far as I can tell that was successful.  Perhaps there is another library 
at this point, but my reading of the log is that LoadLibraryExW was called run 
though all required elements to load, got the end section before it started to 
load dependencies of _jpype, started fetching things that have to do with 
locale and then hit a failure point inside of LoadLibrary.   If I look at the 
successful trace then I see the next action is to start linking in C++ symbols. 
  

But perhaps I am misreading...   Looking farther back in the log, the last 
LoadLibrary to get called before the failure is.

```
20201218192451054 20440 50.60: trclnk64: 001   
LoadLibraryExW(api-ms-win-core-fibers-l1-1-1,0,800)
20201218192451054 20440 50.60: trclnk64: 001   LoadLibraryExW(,,) -> 
7ffc4c71
20201218192451054 20440 50.60: trclnk64: ### 4c71: 
C:\WINDOWS\System32\KERNELBASE.dll 002b306b
20201218192451054 20440 50.60: trclnk64: ntdll.dll [7ffc4c974138 7ffc4c8b7838]
```

Fibers?  I have no clue at this point.   Is this a Python bug or a windows bug?

--

___
Python tracker 

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



[issue42665] Should PyLong_AsLongAndOverflow raise exception on overflow?

2020-12-18 Thread Ganesh Kathiresan


Ganesh Kathiresan  added the comment:

Hi All, thanks for the input. Yeah, the current behavior makes sense, if 
overflow exception is needed, we can use PyLong_AsLong. I guess my confusion 
was from the doc: 
> set *overflow to 1 or -1, respectively, and return -1;
> Returns -1 on error. Use PyErr_Occurred() to disambiguate.

It's not particularly clear if overflow is an `error` here, but again a quick 
compile and run will give you the answer. You can take a call if we have to 
have an explicit statement saying: no exception raised on overflow

--

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread William Pickard


William Pickard  added the comment:

I was just expecting only detours for LoadLibraryExW (and variants) to find out 
which dll failed.

--

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread Karl Nelson


Karl Nelson  added the comment:

I used Detours with trclnk64 to get the following log:

```
20201218193836960 4332 50.60: trclnk64: 001   GetProcAddress(,) -> 7ffc4ccebef0
20201218193836960 4332 50.60: trclnk64: 001   
GetProcAddress(7ffc4ccd,LCMapStringEx)
20201218193836960 4332 50.60: trclnk64: 001   GetProcAddress(,) -> 7ffc4cce6640
 <= This is the point where it differs from a clean run.
20201218193838163 4332 50.60: trclnk64: 001   
GetProcAddress(7ffc4c71,FlsFree)
20201218193838163 4332 50.60: trclnk64: 001   GetProcAddress(,) -> 7ffc4c78b000
20201218193838163 4332 50.60: trclnk64: 001   FAIL 
LoadLibraryExW(c:\users\nelson85\documents\devel\open\jpype\_jpype.cp39-win_amd64.pyd,0,1100)
20201218193838164 4332 50.60: trclnk64: 001 LoadLibraryExW(,,) -> 0
```

It really is nothing to go on...  Everything succeeds, then we get an extra 
successful request for FlsFree then it immediately returns with a fail.

In the successful run (without the cache) we get...
```
20201218192451068 20440 50.60: trclnk64: 001   
GetProcAddress(7ffc4ccd,LCMapStringEx)
20201218192451068 20440 50.60: trclnk64: 001   GetProcAddress(,) -> 7ffc4cce6640
20201218192451068 20440 50.60: trclnk64: 001 LoadLibraryExW(,,) -> 7ffc349f
20201218192451068 20440 50.60: trclnk64: ### 349f: 
c:\users\nelson85\documents\devel\open\jpype\_jpype.cp39-win_amd64.pyd 
20201218192451068 20440 50.60: trclnk64: MSVCP140.dll [7ffc34a7af48 
7ffc34a5a0c8]
20201218192451068 20440 50.60: trclnk64:   
?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAAXXZ0 7ffc36f22350
20201218192451068 20440 50.60: trclnk64:   
?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAAXXZ0 
7ffc36f22350
```

So the failure appears to be internal to the call before we load MSVCP140.dll.  
 Unfortunately, I am way outside my element here as a Linux/Java/CPython 
programmer.   My next guess would be to instrument the set system error and if 
we are within LoadLibrary then execute "int *i=0; *i=0;"  and hope the debugger 
would get me the point of failure so that I can examine the stack trace to find 
out where we are.  But if you have another direction I would be happy to hear 
it.   Is there some function I should add to trclnk64 to that may have gone 
wrong?  It must be something that fetched the address of LCMapStringEx, but I 
have no clue what that may be.

This really does not look like a JPype bug.  Yes, two minutes in the future 
from where the car ran over the pedestrian, he was going to run into the bank 
and demand money (monkey patch and other bad things).  But at the point in time 
the car hit, the pedestrian was just minding his own business.

--

___
Python tracker 

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



[issue42559] random.getrandbits: Should it be explicit that it returns unsigned/non-negative integer?

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
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



[issue42559] random.getrandbits: Should it be explicit that it returns unsigned/non-negative integer?

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset d458d8dab0abaf781c923f80f8eb832d0c683e88 by Miss Islington (bot) 
in branch '3.9':
bpo-42559: Not that getrandbits() is non-negative. (GH-23843) (GH-23851)
https://github.com/python/cpython/commit/d458d8dab0abaf781c923f80f8eb832d0c683e88


--

___
Python tracker 

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



[issue18140] urlparse, urlsplit confused when password includes fragment (#), query (?)

2020-12-18 Thread Senthil Kumaran


Change by Senthil Kumaran :


--
versions: +Python 3.10 -Python 2.7, Python 3.5, Python 3.6

___
Python tracker 

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



[issue42677] Support comments in argparse fromfile_prefix_chars files

2020-12-18 Thread paul j3


paul j3  added the comment:

https://docs.python.org/3/library/argparse.html#customizing-file-parsing

in the docs describes how to customize the @file reading.  This particular 
extension handles several strings on a line, but that's not the limit of what 
you could do.

You can also read a file before parsing and construct a custom `argv` list, as 
described in https://docs.python.org/3/library/argparse.html#beyond-sys-argv

--

___
Python tracker 

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



[issue42672] tkinter/__init__.py raises a NameError if NoDefaultRoot()

2020-12-18 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue42042] sphinx3 renders diffrently docs.python.org for 3.10

2020-12-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

https://github.com/python/python-docs-theme/pull/57 is landed. We just need a 
new release of the package to pypi

--

___
Python tracker 

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



[issue42649] RecursionError when parsing unwieldy expression (regression from 2.7 -> 3.x)

2020-12-18 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

One can use sys.setrecursionlimit to increase allowed recursion depth.

But...  When I ran code from 3.10.0a3 IDLE editor, something hung.  Without 
touching recursion limit, when I split statement apart into

ex = compile("""<300 lines>""", '', 'eval')
print(eval(ex))

I got 106994.5 in under a second.  With exec, ditto except that None is 
printed.  Same last result with 3.9.1.

--
nosy: +terry.reedy

___
Python tracker 

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



[issue34805] Explicitly specify `MyClass.__subclasses__()` returns classes in definition order

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
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



[issue34805] Explicitly specify `MyClass.__subclasses__()` returns classes in definition order

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset 782665885c983e88aac12f7e082485cac2df8007 by Miss Islington (bot) 
in branch '3.9':
bpo-34805:  Guarantee that __subclasses__() is in definition order. (GH-23844) 
(GH-23850)
https://github.com/python/cpython/commit/782665885c983e88aac12f7e082485cac2df8007


--

___
Python tracker 

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



[issue42042] sphinx3 renders diffrently docs.python.org for 3.10

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

The code background highlights really do need to be restored.  Readability has 
been significantly impaired in 3.10.

--
nosy: +rhettinger

___
Python tracker 

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



[issue42680] unicode identifiers not accessible or assignable through globals()

2020-12-18 Thread Martin Chase

Martin Chase  added the comment:

Ah! So then the proper code for me would be e.g.:

```
>>> globals()[unicodedata.normalize("NFKC", "µmeow")]
1e-06
```

Yes, it's clear when I read https://www.python.org/dev/peps/pep-3131/ that the 
normalization is going to happen. Is it also worth adding a note in the 
documentation for `globals()` and `locals()`? That's the first place I looked 
to try to find out what was wrong.

--

___
Python tracker 

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



[issue42042] sphinx3 renders diffrently docs.python.org for 3.10

2020-12-18 Thread Dong-hee Na


Dong-hee Na  added the comment:

@mdk

No https://github.com/python/python-docs-theme/pull/57 must be fixed ;)

--

___
Python tracker 

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



[issue42559] random.getrandbits: Should it be explicit that it returns unsigned/non-negative integer?

2020-12-18 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 3.0 -> 4.0
pull_requests: +22715
pull_request: https://github.com/python/cpython/pull/23851

___
Python tracker 

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



[issue42559] random.getrandbits: Should it be explicit that it returns unsigned/non-negative integer?

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset 5646414ae1fce620b919056f7999dfd15da78e9c by Raymond Hettinger in 
branch 'master':
bpo-42559: Not that getrandbits() is non-negative. (GH-23843)
https://github.com/python/cpython/commit/5646414ae1fce620b919056f7999dfd15da78e9c


--

___
Python tracker 

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



[issue17140] Document multiprocessing.pool.ThreadPool

2020-12-18 Thread Tillmann Karras


Change by Tillmann Karras :


--
nosy:  -Tilka

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
Removed message: https://bugs.python.org/msg383343

___
Python tracker 

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



[issue42681] mistake in curses documentation

2020-12-18 Thread Robert T McQuaid


New submission from Robert T McQuaid :

The description of color_pair starts with

curses.color_pair(color_number)

It should be

curses.color_pair(pair_number)

--
assignee: docs@python
components: Documentation
messages: 383344
nosy: arbor, docs@python
priority: normal
severity: normal
status: open
title: mistake in curses documentation
versions: Python 3.10

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
assignee: docs@python -> steven.daprano

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

FWIW, Allen Downey also had concerns about this wording.

--

___
Python tracker 

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



[issue42670] Missing word in itertools.product

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
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



[issue42670] Missing word in itertools.product

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset eef33e6d49d05aad4111da4ad2d9cb34e7a5206c by Miss Islington (bot) 
in branch '3.9':
bpo-42670: Fix a missing word in the itertools.product() docs (GH-23823) 
(GH-23824)
https://github.com/python/cpython/commit/eef33e6d49d05aad4111da4ad2d9cb34e7a5206c


--
nosy: +rhettinger

___
Python tracker 

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



[issue34805] Explicitly specify `MyClass.__subclasses__()` returns classes in definition order

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:


New changeset 51f4688254ebb7b30215de424360ba5c92c63fe8 by Raymond Hettinger in 
branch 'master':
bpo-34805:  Guarantee that __subclasses__() is in definition order. (GH-23844)
https://github.com/python/cpython/commit/51f4688254ebb7b30215de424360ba5c92c63fe8


--

___
Python tracker 

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



[issue34805] Explicitly specify `MyClass.__subclasses__()` returns classes in definition order

2020-12-18 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 7.0 -> 8.0
pull_requests: +22714
pull_request: https://github.com/python/cpython/pull/23850

___
Python tracker 

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



[issue42680] unicode identifiers not accessible or assignable through globals()

2020-12-18 Thread Steven D'Aprano

Steven D'Aprano  added the comment:

I'm pretty sure this is not a bug, but is working as designed.

The interpreter normalises unicode identifiers, but key lookup in the dict does 
not.

Sorry, I don't have time right now to give a more detailed answer, but there 
are two distinct mu characters:

μ U+03BC
µ U+00B5

and my prediction is that the identifier is normalised to the first, the actual 
Greek mu, but you are looking up the second, the micro sign.

(I'll be able to give a longer response in a couple of hours, if still needed.)

--
nosy: +steven.daprano

___
Python tracker 

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



[issue1289136] distutils extension library path bug on cygwin

2020-12-18 Thread Irit Katriel


Change by Irit Katriel :


--
resolution:  -> out of date
stage: needs patch -> resolved
status: pending -> closed

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread William Pickard


William Pickard  added the comment:

https://www.microsoft.com/en-us/research/project/detours/

--

___
Python tracker 

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



[issue42680] unicode identifiers not accessible or assignable through globals()

2020-12-18 Thread Martin Chase

Martin Chase  added the comment:

Oh, I just gave a cursory using `locals()`, and the same misbehavior is present.

A workaround, for anyone needing to assign or access unicode globals, is to use 
`exec`, e.g. `exec("µmeow = 1e-6", globals())`.

--

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread Karl Nelson


Karl Nelson  added the comment:

Can you be so kind as pointing me to a LoadLibraryExW detour example for 
Python?   I have shimmed a DLL before to capture transaction logs in the past, 
but not with a Python or a system library.

--

___
Python tracker 

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



[issue42680] unicode identifiers not accessible or assignable through globals()

2020-12-18 Thread Martin Chase

New submission from Martin Chase :

This behavior is best described by the code below:

```
>>> meow = 1
>>> 'meow' in globals()
True
>>> µmeow = 1e-6
>>> 'µmeow' in globals()
False
>>> globals()['woof'] = 1
>>> woof
1
>>> globals()['µwoof'] = 1e-6
>>> µwoof
Traceback (most recent call last):
  File "", line 1, in 
NameError: name 'μwoof' is not defined
>>> import sys
>>> sys.getdefaultencoding()
'utf-8'
>>> [(k, bytes(k, 'utf-8')) for k in globals()]
..., ('μmeow', b'\xce\xbcmeow'), ('µwoof', b'\xc2\xb5woof')]
>>> 'µ'.encode('utf-8')
b'\xc2\xb5'
```

Testing was done on linux and windows, variously using 3.6.12, 3.7.6, 3.8.6 and 
3.9.0+.

--
components: Unicode
messages: 383336
nosy: ezio.melotti, outofculture, vstinner
priority: normal
severity: normal
status: open
title: unicode identifiers not accessible or assignable through globals()
type: behavior
versions: Python 3.6, Python 3.7, Python 3.8, Python 3.9

___
Python tracker 

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



[issue32112] Should uuid.UUID() accept another UUID() instance?

2020-12-18 Thread Irit Katriel


Change by Irit Katriel :


--
resolution:  -> rejected
stage:  -> resolved
status: open -> closed
type:  -> enhancement

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

I strongly oppose this change, and I dispute the characterisation of 
this as a misleading note. It is not misleading, and I argue that every 
word of it is factually correct. Jake, if you disagree, then please 
provide some citations.

Irit: it is ridiculous to describe a two paragraph (nine line) note as 
"a statistics textbook". That is an exaggerated position that doesn't 
help the discussion. It's not a textbook, it is a short note that helps 
users whose knowledge of statistics is naive to understand which 
statistic is better for them.

"If someone doesn't know whether they need the mean or the median, they 
really need to read a more fundamental text before writing their code."

I totally disagree. This module is not intended only for statisticians 
and experts, and the user who isn't sure which average to use shouldn't 
have to read a textbook on the fundamentals of statistics.

--

___
Python tracker 

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



[issue24792] zipimporter masks import errors

2020-12-18 Thread miss-islington


miss-islington  added the comment:


New changeset fb34096140bbb74c81500dd8bbc3c69c1d24d9ab by Irit Katriel in 
branch 'master':
bpo-24792: Fix zipimporter masking the cause of import errors (GH-22204)
https://github.com/python/cpython/commit/fb34096140bbb74c81500dd8bbc3c69c1d24d9ab


--
nosy: +miss-islington

___
Python tracker 

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



[issue3735] allow multiple threads to efficiently send the same requests to a processing.Pool without incurring duplicate processing

2020-12-18 Thread Irit Katriel


Change by Irit Katriel :


--
stage: needs patch -> resolved
status: pending -> closed

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread William Pickard


William Pickard  added the comment:

You may need to inject a LoadLibraryExW detour into your python runtime before 
_jpype is loaded and output all the library names its requesting.

You may need to detour all Load 
Library functions for maximum coverage.

--
nosy: +WildCard65

___
Python tracker 

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



[issue42633] Wave documentation doesn't mention signed/unsigned requirements

2020-12-18 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

I not sure about 'very useful'.  One has to know a lot more than the sample 
width in bytes, which can be 1 to 4 (according to the code), not just 1 to 2 
(as implied by https://en.wikipedia.org/wiki/WAV), to effectively use the 
module.  Such things as the endianess of multibyte samples and what is 'linear 
pulse code modulation'.  The docs assume that one know all this from another 
source.

--
nosy: +terry.reedy

___
Python tracker 

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



Re: "Worst bugs" and Python?

2020-12-18 Thread Rich Shepard

On Sat, 19 Dec 2020, dn via Python-list wrote:


Companies such as Microsoft and Oracle (plus, plus, ...) do not allow
just-anyone to analyse their source-code - whereas 'open source' is
available for analysis, by definition! An easy 'target' for shallow
analysis?


Looks bass-ackwards to me. That's the same argument made by proprietary
companies (especially Micro$oft) in the early 1990s. What falsifies the
writer's argument is all the malware that's affected Windoze over the past
couple of decades compared to F/OSS OSes and applications.

Sigh. Fake news hits the software industry.

Carpe weekend,

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


[issue42125] linecache cannot get source for the __main__ module with a custom loader

2020-12-18 Thread Eugene Toder


Change by Eugene Toder :


--
nosy: +ncoghlan, vstinner

___
Python tracker 

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



[issue42572] Better path handling with argparse

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

Eric and Paul, I've attached a substantial rewrite of the docs for the *type* 
parameter:

* Document the exceptions that are handled.
* Show a wider range of examples that work with *type*.
* Discuss when *type* shouldn't be used:  bool, JSONDecoder, etc.
* Create a less whimsical example of a user-defined type converter.
* Explain the interaction between *type* and *default*.

Let me know what you think.

--

___
Python tracker 

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



[issue35005] argparse should accept json and yaml argument types

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
pull_requests: +22713
pull_request: https://github.com/python/cpython/pull/23849

___
Python tracker 

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



[issue42572] Better path handling with argparse

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
keywords: +patch
pull_requests: +22711
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23849

___
Python tracker 

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



[issue37572] email lib bug

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
nosy: +rhettinger
nosy_count: 5.0 -> 6.0
pull_requests: +22712
pull_request: https://github.com/python/cpython/pull/23849

___
Python tracker 

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



[issue40866] Use PyModule_AddType() in posix module initialisation

2020-12-18 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
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



[issue42677] Support comments in argparse fromfile_prefix_chars files

2020-12-18 Thread Eric V. Smith


Eric V. Smith  added the comment:

I think you could achieve this by overriding convert_arg_line_to_args.

If this were baked in to argparse, there would need to be an argument to 
argparse.ArgumentParser to turn on this behavior, with the default being to not 
support comments. That's because enabling this by default would be a non 
backward compatible change.

Personally, I think argparse.ArgumentParser is already too complex, and this 
shouldn't be added.

--
nosy: +eric.smith, paul.j3, rhettinger

___
Python tracker 

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



RE: dict.get(key, default) evaluates default even if key exists

2020-12-18 Thread Schachner, Joseph
Yes.  In order to call D.get( ) it needs to pass two arguments.  The first is 
'a', simple.  The second is the result of a call to get_default().   So, that 
is called.  From INSIDE get_default() it prints 'Nobody expects this' but you 
should expect it,  get_default() gets executed.   Following that it prints '1', 
because the default value was NOT USED.   If it was used, you would see 'Nobody 
expects this' followed by 0.

--- Joseph S.

-Original Message-
From: Mark Polesky  
Sent: Tuesday, December 15, 2020 12:07 PM
To: python-list@python.org
Subject: dict.get(key, default) evaluates default even if key exists

Hi.

# Running this script

D = {'a':1}
def get_default():
    print('Nobody expects this')
    return 0
print(D.get('a', get_default()))

# ...generates this output:

Nobody expects this
1

###

Since I'm brand new to this community, I thought I'd ask here first... Is this 
worthy of a bug report?  This behavior is definitely unexpected to me, and I 
accidentally coded an endless loop in a mutual recursion situation because of 
it.  Calling dict.get.__doc__ only gives this short sentence: Return the value 
for key if key is in the dictionary, else default.  Nothing in that docstring 
suggests that the default value is evaluated even if the key exists, and I 
can't think of any good reason to do so.

Am I missing something?

Thanks,
Mark

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


[issue42624] sqlite3 package document mistake

2020-12-18 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

___
Python tracker 

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



[issue24139] Use sqlite3 extended error codes

2020-12-18 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

___
Python tracker 

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



[issue42624] sqlite3 package document mistake

2020-12-18 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

The doc is the same in 3.10.

What OS and exact Python release? Can you post minimal code that verifies your 
claim?  (Someone what have to verify with 3.10 also.)

This would strike me as an error in the code.  We can fix 'wrong Exception' in 
the next release.  I am not sure whether we would do so in a current release.

--
nosy: +terry.reedy

___
Python tracker 

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



"Worst bugs" and Python?

2020-12-18 Thread dn via Python-list
TechRepublic have published a lovely piece of 'click-bait' featuring 
alarmist claims such as "open-source libraries are increasingly 
untrustworthy" whilst trotting-out tired, old, memes and bias.


Don't panic - hold-on to your PyPi!


<<<
The worst bugs in the top programming languages
by Brandon Vigliarolo in Security  on December 17, 2020, 9:32 AM PST
A heatmap shows PHP has the most flaws followed by C++, then Java, .Net, 
JavaScript, and Python in Veracode's annual security report.

>>>
https://www.techrepublic.com/article/the-worst-bugs-in-the-top-programming-languages/

Does anyone think that code is 'bug free'? That's a 'filler topic' for 
any columnist lacking fresh ideas and desperate to fill a publishing 
deadline.


The basis is "State of Software Security v11" 'report' produced by 
Veracode (https://www.veracode.com/state-of-software-security-report). 
You will not be surprised to note that Veracode is in the business of 
marketing test and analysis software.


Any such report is inherently useful. They serve to ensure that we do 
not become complacent in our attitude to security. However, there are 
more "bugs" in software than fit under the heading of 'security'.


Similarly, at times the report appears to lump-together C, C++, and C#; 
whereas at others they may not; which makes it difficult to generalise 
or analyse. In the same vein, infographics look nice, but what does 
"Code Quality" really mean?


Another observation is that many of their 'categories' apply mainly to 
the on-line world. Corporation-only applications are protected by 
network defences rather than by their own devices.


A more interesting figure, which is under-reported both in the article 
and within Veracode's summaries, is the period of vulnerability - how 
long it takes to fix a bug after it has been reported - and preferably 
with the 'danger' of the bug factored-in. Thus a bug which doesn't allow 
the addition of new user-credentials is quite a different matter from 
one which allows existing users to upgrade themselves to 'super-user'. 
Such analysis is possibly available, but not in the summaries (above).


A quick dip into Veracode's 'vulnerability database' yielded the 
following intelligence:


Top three "library artefacts" with Python as [the only] keyword:
- firefox
- thunderbird
- linux-rt

Is Python 'counted' in these cases because it is involved somewhere 
within the package, because it is the majority-language used, because it 
is the only language employed, or because its use contributes to most of 
the faults-found?


Finally, such reports are primarily marketing tools, and thus notorious 
for bias or superficial content. Veracode do not declare the range, or 
limits on the range, of software they've analysed. Companies such as 
Microsoft and Oracle (plus, plus, ...) do not allow just-anyone to 
analyse their source-code - whereas 'open source' is available for 
analysis, by definition! An easy 'target' for shallow analysis?



At this point I gave up, lacking the interest to fill-out the 
contact-form, or to read the entire report.



The good news is, that of the six languages headlined in the summaries, 
Python comes-off 'best' (cf .Net, C++, Java, JavaScript, and PHP).

--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list


[issue42679] Minor improvement in datetime.timestamp() docs

2020-12-18 Thread Olvin


New submission from Olvin :

Answering question on StackOverflow I've found next example in docs of 
datetime.timestamp() ( 
https://docs.python.org/3/library/datetime.html#datetime.datetime.timestamp ) 
which returns UTC timestamp:

timestamp = (dt - datetime(1970, 1, 1)) / timedelta(seconds=1)

While it works I think there's more explicit way using 
timedelta.total_seconds() :

timestamp = (dt - datetime(1970, 1, 1)).total_seconds()

In same article few lines above there's example using total_seconds() so I 
think it will be good to use same method in both examples.

--
assignee: docs@python
components: Documentation
messages: 383328
nosy: docs@python, olvinroght
priority: normal
severity: normal
status: open
title: Minor improvement in datetime.timestamp() docs
type: enhancement

___
Python tracker 

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



[issue39560] PyUnicode_FromKindAndData kind transformation is not documented

2020-12-18 Thread Zackery Spytz


Change by Zackery Spytz :


--
keywords: +patch
nosy: +ZackerySpytz
nosy_count: 3.0 -> 4.0
pull_requests: +22710
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23848

___
Python tracker 

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



[issue31861] add aiter() and anext() functions

2020-12-18 Thread Joshua Bronson


Joshua Bronson  added the comment:

Please see https://github.com/python/cpython/pull/23847 for the C 
implementation of aiter and anext added to builtins, as requested.

--
title: add aiter() and anext() functions to operator module -> add aiter() and 
anext() functions

___
Python tracker 

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



[issue31861] add aiter() and anext() functions to operator module

2020-12-18 Thread Joshua Bronson


Change by Joshua Bronson :


--
pull_requests: +22708
pull_request: https://github.com/python/cpython/pull/23847

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread Karl Nelson


Karl Nelson  added the comment:

Just for reference here are all the dependencies that _jpype has

```
MSVCP140.dll

python39.dll

KERNEL32.dll

VCRUNTIME140_1.dll  

VCRUNTIME140.dll


api-ms-win-crt-runtime-l1-1-0.dll   
  
   api-ms-win-crt-string-l1-1-0.dll 

   api-ms-win-crt-heap-l1-1-0.dll
```

So it isn't like there are a whole lot of things that I am doing that are 
likely to trigger a dependency problem.

As far as I can see the only items that are not already on python39.dll 
dependency list are VCRUNTIME140_1.dll and MSVCP140.dll.  But if that were the 
case then surely other projects would also be hitting this bug.  So this error 
message makes no sense at all.

--

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread Yurii Karabas


Yurii Karabas <1998uri...@gmail.com> added the comment:

Yurii no worries, I am happy that this issue is resolved)

--
nosy: +uriyyo

___
Python tracker 

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



[issue42678] [Enum] _sunder_ methods only looked up in the last Enum class in the mro

2020-12-18 Thread Ethan Furman


Change by Ethan Furman :


--
assignee: ethan.furman
components: Library (Lib)
nosy: ethan.furman
priority: normal
severity: normal
stage: needs patch
status: open
title: [Enum] _sunder_ methods only looked up in the last Enum class in the mro
type: behavior
versions: Python 3.10, Python 3.9

___
Python tracker 

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



[issue36769] doc Document that fnmatch.filter supports any kind of iterable not just lists

2020-12-18 Thread miss-islington


miss-islington  added the comment:


New changeset 4b412e830d0a7d3f30af60b9eb285558511d90af by Miss Islington (bot) 
in branch '3.9':
bpo-36769: Document that fnmatch.filter supports any kind of iterable (GH-13039)
https://github.com/python/cpython/commit/4b412e830d0a7d3f30af60b9eb285558511d90af


--

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread Yury Selivanov


Yury Selivanov  added the comment:


New changeset 82dbfd5a04863d8b6363527e6a34a90c9aa5691b by Miss Islington (bot) 
in branch '3.9':
bpo-41891: ensure asyncio.wait_for waits for task completion (GH-22461) (#23840)
https://github.com/python/cpython/commit/82dbfd5a04863d8b6363527e6a34a90c9aa5691b


--

___
Python tracker 

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



[issue42677] Support comments in argparse fromfile_prefix_chars files

2020-12-18 Thread Thomas Nabelek


New submission from Thomas Nabelek :

For input argument files, specified with the fromfile_prefix_chars argument to 
argparse.ArgumentParser, argparse should ignore lines beginning with '#' so 
that comments can be used in those files.

--
components: Library (Lib)
messages: 383321
nosy: nabelekt
priority: normal
severity: normal
status: open
title: Support comments in argparse fromfile_prefix_chars files
type: enhancement

___
Python tracker 

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



[issue36769] doc Document that fnmatch.filter supports any kind of iterable not just lists

2020-12-18 Thread miss-islington


Change by miss-islington :


--
pull_requests: +22707
pull_request: https://github.com/python/cpython/pull/23846

___
Python tracker 

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



[issue36769] doc Document that fnmatch.filter supports any kind of iterable not just lists

2020-12-18 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 3.0 -> 4.0
pull_requests: +22706
pull_request: https://github.com/python/cpython/pull/23845

___
Python tracker 

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



[issue36769] doc Document that fnmatch.filter supports any kind of iterable not just lists

2020-12-18 Thread Julien Palard


Julien Palard  added the comment:


New changeset e8d22642105d57007ab1242848a8cbadc7f179df by Andre Delfino in 
branch 'master':
bpo-36769: Document that fnmatch.filter supports any kind of iterable (#13039)
https://github.com/python/cpython/commit/e8d22642105d57007ab1242848a8cbadc7f179df


--
nosy: +mdk

___
Python tracker 

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



[issue34398] Docs search should prominently show definitions and glossary items

2020-12-18 Thread Julien Palard


Julien Palard  added the comment:


New changeset 8c5d0347efd16f16dfb9596715e449cd928b89c8 by Ammar Askar in branch 
'master':
bpo-34398: Allow glossary results to show up on search page (GH-8773)
https://github.com/python/cpython/commit/8c5d0347efd16f16dfb9596715e449cd928b89c8


--

___
Python tracker 

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



[issue42042] sphinx3 renders diffrently docs.python.org for 3.10

2020-12-18 Thread Julien Palard


Julien Palard  added the comment:

Is it fixed?

--

___
Python tracker 

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



[issue12800] 'tarfile.StreamError: seeking backwards is not allowed' when extract symlink

2020-12-18 Thread Julien Palard


Change by Julien Palard :


--
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



[issue34805] Explicitly specify `MyClass.__subclasses__()` returns classes in definition order

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
keywords: +patch
pull_requests: +22705
stage: resolved -> patch review
pull_request: https://github.com/python/cpython/pull/23844

___
Python tracker 

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



[issue17140] Document multiprocessing.pool.ThreadPool

2020-12-18 Thread Ned Deily


Ned Deily  added the comment:

Thanks, Matt, for the documentation PR.

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6

___
Python tracker 

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



[issue17140] Document multiprocessing.pool.ThreadPool

2020-12-18 Thread Ned Deily


Ned Deily  added the comment:


New changeset 00278d4e616315e64557bff014574c079e6e96ff by Miss Islington (bot) 
in branch '3.7':
bpo-17140: Document multiprocessing's ThreadPool (GH-23812) (GH-23836)
https://github.com/python/cpython/commit/00278d4e616315e64557bff014574c079e6e96ff


--
nosy: +ned.deily

___
Python tracker 

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



[issue17140] Document multiprocessing.pool.ThreadPool

2020-12-18 Thread miss-islington


miss-islington  added the comment:


New changeset d21d29ab5b8741da056ac09c49c759b6ccbf264a by Miss Islington (bot) 
in branch '3.8':
[3.8] bpo-17140: Document multiprocessing's ThreadPool (GH-23812) (GH-23835)
https://github.com/python/cpython/commit/d21d29ab5b8741da056ac09c49c759b6ccbf264a


--

___
Python tracker 

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



[issue42667] shelve module is not thread-safe during accessing different databases from different threads

2020-12-18 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Loading modules every time without using a cache (sys.modules) can add 
significant overhead.

--

___
Python tracker 

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



[issue34690] Store startup modules as C structures for 20%+ startup speed improvement

2020-12-18 Thread Eric Engeström

Change by Eric Engeström :


--
nosy: +1ace

___
Python tracker 

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



[issue42559] random.getrandbits: Should it be explicit that it returns unsigned/non-negative integer?

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
pull_requests: +22704
pull_request: https://github.com/python/cpython/pull/23843

___
Python tracker 

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



[issue42676] zoneinfo uses locale depending functions for parsing

2020-12-18 Thread Serhiy Storchaka


New submission from Serhiy Storchaka :

zoneinfo uses locale depending functions isalpha(), isdigit(), isalnum() to 
parse data. It may be correct when parse the TZ environment variable (although 
they do not work with multibytes locale encodings like UTF-8), I think that 
parsing the content of data files should not rely on current locale. Later the 
parsed data is decoded implying UTF-8 (for abbr) or ASCII (for numbers).

--
components: Library (Lib)
messages: 383313
nosy: p-ganssle, serhiy.storchaka
priority: normal
severity: normal
status: open
title: zoneinfo uses locale depending functions for parsing
type: behavior
versions: Python 3.10, Python 3.9

___
Python tracker 

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



[issue23522] Misleading note in Statistics module documentation

2020-12-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
keywords: +patch
nosy: +rhettinger
nosy_count: 4.0 -> 5.0
pull_requests: +22703
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23842

___
Python tracker 

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



[issue42667] shelve module is not thread-safe during accessing different databases from different threads

2020-12-18 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

I suggest removing the global state from dbm and just recomputing the 
underlying database for every call to open().

--
nosy: +rhettinger

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread miss-islington


miss-islington  added the comment:


New changeset a3dec9d8ec5ae142946ff6b94947a183d7c48f35 by Miss Islington (bot) 
in branch '3.8':
bpo-41891: ensure asyncio.wait_for waits for task completion (GH-22461)
https://github.com/python/cpython/commit/a3dec9d8ec5ae142946ff6b94947a183d7c48f35


--
nosy: +miss-islington

___
Python tracker 

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



[issue42675] Document changes made in bpo-42195

2020-12-18 Thread Guido van Rossum


Guido van Rossum  added the comment:


New changeset d75f6f78e6ca230d0dacc116dca9d8bf91509b68 by kj in branch 'master':
bpo-42675: Document collections.abc.Callable changes (GH-23839)
https://github.com/python/cpython/commit/d75f6f78e6ca230d0dacc116dca9d8bf91509b68


--

___
Python tracker 

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



[issue42195] Inconsistent __args__ between typing.Callable and collections.abc.Callable

2020-12-18 Thread Ken Jin


Change by Ken Jin :


--
pull_requests: +22702
pull_request: https://github.com/python/cpython/pull/23839

___
Python tracker 

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



[issue42600] Cancelling tasks waiting for asyncio.Conditions crashes w/ RuntimeError: Lock is not acquired.

2020-12-18 Thread Yury Selivanov


Yury Selivanov  added the comment:

This has been actually first fixed in #41891 but somehow wasn't yet merged. 
Yurii, thanks so much for working on this and making a PR, there was just 
another PR to fix the same issue that was there first, so I had to merge that 
one.

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
superseder:  -> asyncio.wait_for does not wait for task/future to be completed 
in all cases

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread Yury Selivanov


Change by Yury Selivanov :


--
nosy:  -miss-islington
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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 3.0 -> 4.0
pull_requests: +22701
pull_request: https://github.com/python/cpython/pull/23841

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread Yury Selivanov


Yury Selivanov  added the comment:

Thanks for the PR, Richard!

--
nosy:  -miss-islington

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 3.0 -> 4.0
pull_requests: +22700
pull_request: https://github.com/python/cpython/pull/23840

___
Python tracker 

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



[issue41891] asyncio.wait_for does not wait for task/future to be completed in all cases

2020-12-18 Thread Yury Selivanov


Yury Selivanov  added the comment:


New changeset 17ef4319a34f5a2f95e7823dfb5f5b8cff11882d by Richard Kojedzinszky 
in branch 'master':
bpo-41891: ensure asyncio.wait_for waits for task completion (#22461)
https://github.com/python/cpython/commit/17ef4319a34f5a2f95e7823dfb5f5b8cff11882d


--

___
Python tracker 

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



[issue42604] EXT_SUFFIX too short on FreeBSD and AIX

2020-12-18 Thread STINNER Victor


STINNER Victor  added the comment:

test_sysconfig still fails:

* POWER6 AIX 3.x: https://buildbot.python.org/all/#/builders/302/builds/563
* PPC64 AIX 3.x: https://buildbot.python.org/all/#/builders/438/builds/593
* AMD64 FreeBSD Shared 3.x: 
https://buildbot.python.org/all/#/builders/483/builds/572

--

___
Python tracker 

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



[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-18 Thread Karl Nelson


Karl Nelson  added the comment:

I attempted another deep dive on this one.

1) Removed manual library add
   platform_specific['libraries'] = ['Advapi32']
No change.

2) Compared symbol wise imports
Two imports changed
PyIndex_Check
PyObject_CheckBuffer
plus one additional "fflush" dependency in api-ms-win-crt-stdio-l1-1-0.dll 

3) Compared symbol wise exports 
No changes detected.

4) Disassembled both binaries
Other than a addressing that is about a 0x1000 change in the relocation tables. 
 Guessing that this is just a change in the number of pages.  There were 
functional changes likely related to Python macros differences.

5) Removed all references to printf and flush to remove 
api-ms-win-crt-stdio-l1-1-0.dll dependency.
No change.

6) Scanned the changelog and Code changes for the past year in  
Python/dynload_win.c.  
Nothing appears likely to trigger this change.

7) Deleted the _jpype module entirely to verify that the error message is 
related to the copy that I am working on and not some other copy on system.
Error message changes to "ModuleNotFoundError: No module named '_jpype'"

8) Scanned the source code for static variables.
None detected thus far.  But it is a many hours long process.  Structurally 
these should not exist based on the module design.

Statics found thus far.
2 jobject and jmethodID pointer types
One C++ class called PLATFORM_ADAPTER which is the required routine determining 
whether to load jvm.dll or jvm.so using LoadLibrary or dlopen or shload.
The global pointer to the context C++ class;
a bunch of statics related to logging when enabled.
Python C style structure definitions.

Everything was a primitive or pointer with the exception of one class.  All 
pointers I found were initialized to constant values.

I rewrote the PLATFORM_ADAPTER to use a pointer rather than be initialized at 
load time.  No joy.

(after scanning through 17k lines of code take break and ponder life)

It is certainly possible I missed something here but it looks pretty unlikely 
this is the source of the error.


9) Verified that the behavior does not occur on Python 3.8.5 with the current 
source code.  
Pass.  This only happens on Python 3.9.0

10) Scanned the linker line for differences.
One major difference.  In Python 3.8 the linker line contains quotes around all 
the arguments while in Python 3.9 the linker line is missing the quotes on all 
/LIBPATH statements.  However this must be a logging difference as the 
statement without the quotes would not work.

11) Manually ran linker command.  
Nothing changed, same behavior.  So link command is a red herring.

12) Profit???

Okay I have once again exhausted everything that I can think of on the JPype 
side.   So that leaves something in the build process that does not appear in 
the logs, a symbol conflict that so how only triggers on one path, or 
Python3.9.0 has a corrupt build in the wild.   

Steve is there anything else that I can try here?

--

___
Python tracker 

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



Re: Lambda in parameters

2020-12-18 Thread Grant Edwards
On 2020-12-18, Barry  wrote:
>> Implement car and cdr.
>  Why car and cdr?
>
> Well obviously car is content of the address register and cdr is content of 
> data register.
> Apparently an artefact of a early implementation of lisp.

While car and cdr are lisp operators, the "content of address
register" and "content of data register" etymology is apparently
apocryphal:

  https://en.wikipedia.org/wiki/CAR_and_CDR#Etymology

--
Grant

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


Re: Review, suggestion etc?

2020-12-18 Thread Grant Edwards
On 2020-12-18, Joe Pfeiffer  wrote:
> Grant Edwards  writes:
>
>> Yep, there are definitly cases where it's pretty much the only right
>> answer. If you try to avoid it, you end up writing what turns into a
>> simulation of recursion -- and doing that correctly isn't easy.
>
> Decades ago I had to write a binary tree search in FORTRAN IV.  It
> wasn't pretty.

I saw somebody try to write a graph search in GW-BASIC once. It was a
huge mess, and wasn't anywhere close to working. Doing the same thing
recursively was trivial -- even in C. In Python it wuld have been
even trivialler.

--
Grant



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


[issue42195] Inconsistent __args__ between typing.Callable and collections.abc.Callable

2020-12-18 Thread Ken Jin


Change by Ken Jin :


--
pull_requests:  -22699

___
Python tracker 

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



  1   2   >