[issue41154] test_pkgutil:test_name_resolution fails on some platforms

2020-06-29 Thread Ned Deily


Ned Deily  added the comment:

This same failure is observed with the most recent 3.9beta (3.9.0b3) when 
running on macOS 10.9 with the binaries from the python.org macOS installer.  
However, no failure is seen when running the same Python on macOS 10.15. I have 
not investigated further with other releases.  This test failure should be 
addressed prior t0 3.9.0rc1.

--
nosy: +ned.deily, vstinner
priority: normal -> deferred blocker
title: test_pkgutil:test_name_resolution fails on master -> 
test_pkgutil:test_name_resolution fails on some platforms
versions: +Python 3.9

___
Python tracker 

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



[issue41154] test_pkgutil:test_name_resolution fails on some platforms

2020-06-29 Thread Ned Deily


Ned Deily  added the comment:

PS, the problem may have been introduced by the changes for bpo-12915.

--

___
Python tracker 

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



[issue12915] Add inspect.locate and inspect.resolve

2020-06-29 Thread Ned Deily


Ned Deily  added the comment:

See bpo-41154 for possible regression introduced by these changes.

--
nosy: +ned.deily

___
Python tracker 

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



[issue41154] test_pkgutil:test_name_resolution fails on some platforms

2020-06-29 Thread Florian Bruhin


Change by Florian Bruhin :


--
nosy: +The Compiler

___
Python tracker 

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



[issue41155] Tkinter -postoffset not working for TCombobox

2020-06-29 Thread Svetoslav Inkolov


New submission from Svetoslav Inkolov :

Doing a configuration of the tkinter combobox for the dropdown list with:

style = ttk.Style()
style.configure('TCombobox', postoffset=(0,0,width,0))

results in no changing of the combobox.

In Python 2.7.16 or generally in python 2 this functionality works well.

Please see the sample source-code attached.

--
components: Tkinter
files: test_variable_dropdown-width_of_combobox.py
messages: 372553
nosy: Sveti007
priority: normal
severity: normal
status: open
title: Tkinter -postoffset not working for TCombobox
type: behavior
versions: Python 3.8
Added file: 
https://bugs.python.org/file49272/test_variable_dropdown-width_of_combobox.py

___
Python tracker 

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



[issue41048] read_mime_types() should read the rule file using UTF-8, not the locale encoding

2020-06-29 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:


New changeset 7f569c9bc0079906012b3034d30fe8abc742e7fc by Srinivas Reddy 
Thatiparthy (శ్రీనివాస్  రెడ్డి తాటిపర్తి) in branch 'master':
bpo-41048: mimetypes should read the rule file using UTF-8, not the locale 
encoding (GH-20998)
https://github.com/python/cpython/commit/7f569c9bc0079906012b3034d30fe8abc742e7fc


--

___
Python tracker 

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



[issue41048] read_mime_types() should read the rule file using UTF-8, not the locale encoding

2020-06-29 Thread miss-islington


Change by miss-islington :


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

___
Python tracker 

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



[issue41048] read_mime_types() should read the rule file using UTF-8, not the locale encoding

2020-06-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +20365
pull_request: https://github.com/python/cpython/pull/21211

___
Python tracker 

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



[issue29778] _Py_CheckPython3 uses uninitialized dllpath when embedder sets module path with Py_SetPath

2020-06-29 Thread STINNER Victor


STINNER Victor  added the comment:

_Py_CheckPython3() tries to load "python3.dll" from two directories:

* first one based on _Py_dll_path
* second one based on Py_GetPrefix()

I understand that LoadLibraryExW() must not be attempted if _Py_dll_path is 
empty, or if Py_GetPrefix() is empty. Am I right?

--

___
Python tracker 

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



[issue29778] _Py_CheckPython3 uses uninitialized dllpath when embedder sets module path with Py_SetPath

2020-06-29 Thread STINNER Victor


STINNER Victor  added the comment:

I understand that Python 3.5, 3.6 and 3.7 are also affected. It's not a 
regression.

On Python 3.5, 3.6 and 3.7, when Py_SetPath(path) is called, Py_GetPrefix() 
also returns an empty path. So at least the directory based on Py_GetPrefix() 
should also be skipped on Python 3.5-3.7 if Py_GetPrefix() is empty, right?

--
type: behavior -> security
versions: +Python 3.10, 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



[issue41156] Remove Task.all_tasks and Task.current_task

2020-06-29 Thread Inada Naoki


New submission from Inada Naoki :

They are documented as "will be removed in version 3.9", but they are not 
removed in 3.9 beta.

* Remove them in 3.10.
* Update ~3.9 documents to "will be removed in version 3.10"

--
components: asyncio
messages: 372557
nosy: asvetlov, inada.naoki, yselivanov
priority: normal
severity: normal
status: open
title: Remove Task.all_tasks and Task.current_task
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



[issue41023] smtplib does not handle Unicode characters

2020-06-29 Thread Jay Patel


Change by Jay Patel :


Removed file: 
https://bugs.python.org/file49250/providing_only_ascii_characters.png

___
Python tracker 

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



[issue41156] Remove Task.all_tasks and Task.current_task

2020-06-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

See also https://bugs.python.org/issue40967

--
nosy: +aeros, xtreak

___
Python tracker 

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



[issue41156] Remove Task.all_tasks and Task.current_task

2020-06-29 Thread Inada Naoki


Change by Inada Naoki :


--
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> asyncio.Task.all_tasks() and asyncio.Task.current_task() must 
be removed in 3.9

___
Python tracker 

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



[issue41073] [C API] PyType_GetSlot() should accept static types

2020-06-29 Thread STINNER Victor


STINNER Victor  added the comment:

> historical discuss: bpo17162

bpo-17162 added PyType_GetSlot(), but static types were not discussed there.

--

___
Python tracker 

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



[issue12915] Add inspect.locate and inspect.resolve

2020-06-29 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

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



[issue34206] Move and clarify Py_Main documentation

2020-06-29 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

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



[issue30672] PEP 538: Unexpected locale behaviour on *BSD (including Mac OS X)

2020-06-29 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

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



[issue41154] test_pkgutil:test_name_resolution fails on some platforms

2020-06-29 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

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



[issue35975] Put back the ability to parse files where async/await aren't keywords

2020-06-29 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

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



[issue41157] email.message_from_string() is unable to find the headers for the .msg files

2020-06-29 Thread Jay Patel


New submission from Jay Patel :

I need to extract the email data from an MSG file on Python v2.7. But as Python 
v2.7 has been deprecated, I tried to replicate this scenario on Python v3.8 and 
faced the same issue.
I am trying to extract the message using the "Message" class of the 
"extract_msg" module. After extracting the text from the "Message" object, I am 
using email.message_from_string() method to separate the headers and the body 
(or payload). The same workflow can be observed in the "extract_mail.py" file.
The issue with the attached file, "msgfile_not_working_correctly.msg", is that 
the headers of this file begin with "Microsoft Mail Internet Headers Version 
2.0" which is interpreted as body and not as headers (as it is not in the 
standard email headers format like "To": "recei...@gmail.com").
According to this 
(https://support.microsoft.com/en-us/office/view-internet-message-headers-in-outlook-cd039382-dc6e-4264-ac74-c048563d212c)
 link the message headers in Outlook will begin with "Microsoft Mail Internet 
Headers Version 2.0" which is added by Outlook (mentioned in the "Interpreting 
email headers" section of the mentioned link). 
The email data can be observed in the "email_data.txt" file.

I have tried omitting the first line, when there are no headers and it works as 
per the expectation. Can this scenario be handled at the modular level (email 
module) or is there any other way to extract headers for the .msg files.

--
files: extract_mail.py
messages: 372560
nosy: jpatel
priority: normal
severity: normal
status: open
title: email.message_from_string() is unable to find the headers for the .msg 
files
type: enhancement
versions: Python 3.8
Added file: https://bugs.python.org/file49273/extract_mail.py

___
Python tracker 

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



[issue41157] email.message_from_string() is unable to find the headers for the .msg files

2020-06-29 Thread Jay Patel


Change by Jay Patel :


Added file: https://bugs.python.org/file49274/msgfile_not_working_correctly.msg

___
Python tracker 

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



[issue37224] [subinterpreters] test__xxsubinterpreters fails randomly

2020-06-29 Thread STINNER Victor


STINNER Victor  added the comment:

AMD64 Windows8.1 Refleaks 3.x:
https://buildbot.python.org/all/#/builders/157/builds/218

2:51:27 load avg: 3.54 [275/423/2] test__xxsubinterpreters crashed (Exit code 
3221225477) -- running: test_regrtest (2 hour 49 min), test_distutils (1 min 56 
sec), test_pydoc (1 min 36 sec)
beginning 6 repetitions
123456
...Windows fatal exception: access violation

Thread 0x04dc (most recent call first):
  File 
"D:\buildarea\3.x.ware-win81-release.refleak\build\lib\test\test__xxsubinterpreters.py",
 line 766 in setUp
  File 
"D:\buildarea\3.x.ware-win81-release.refleak\build\lib\unittest\case.py", line 
547 in _callSetUp
  File 
"D:\buildarea\3.x.ware-win81-release.refleak\build\lib\unittest\case.py", line 
589 in run
  File 
"D:\buildarea\3.x.ware-win81-release.refleak\build\lib\unittest\case.py", line 
653 in __call__
  (...)

--
nosy: +vstinner

___
Python tracker 

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



[issue41084] Signify that a SyntaxError comes from an fstring in the error message

2020-06-29 Thread STINNER Victor


STINNER Victor  added the comment:

The change broke the old parser in Python 3.9, I reopen the issue:

AMD64 Arch Linux VintageParser 3.9:
https://buildbot.python.org/all/#/builders/765/builds/129

FAIL: test_format_specifier_expressions (test.test_fstring.TestCase) 
(str="f'{4:{/5}}'")
FAIL: test_invalid_syntax_error_message (test.test_fstring.TestCase)
FAIL: test_lambda (test.test_fstring.TestCase) (str="f'{lambda x:x}'")
FAIL: test_parens_in_expressions (test.test_fstring.TestCase) (str="f'{,}'")
FAIL: test_parens_in_expressions (test.test_fstring.TestCase) (str="f'{,}'")

--
nosy: +vstinner
resolution: fixed -> 
status: closed -> open

___
Python tracker 

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



[issue41084] Signify that a SyntaxError comes from an fstring in the error message

2020-06-29 Thread Lysandros Nikolaou


Change by Lysandros Nikolaou :


--
pull_requests: +20366
stage: resolved -> patch review
pull_request: https://github.com/python/cpython/pull/21212

___
Python tracker 

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



[issue41158] IDLE: rewrite the code for handling file encoding

2020-06-29 Thread Serhiy Storchaka


New submission from Serhiy Storchaka :

The proposed patch rewrites the code in IDLE for detecting Python file encoding 
and decoding and encoding Python sources by using the tokenize module instead 
of handmade implementation of PEP 263.

--
assignee: terry.reedy
components: IDLE
messages: 372563
nosy: serhiy.storchaka, terry.reedy
priority: normal
severity: normal
status: open
title: IDLE: rewrite the code for handling file encoding
type: enhancement
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



[issue36468] Treeview: wrong color change

2020-06-29 Thread PySimpleGUI


PySimpleGUI  added the comment:

The tk project fixed this problem in release 8.6.10.

I don't see where this version of tk is being picked up.  The release notes of 
3.9.0 Beta3 show tk version 8.6.9 is being used for Windows.

https://docs.python.org/3.9/whatsnew/changelog.html#python-3-9-0-beta-3

Is there a planned release vehicle for 8.6.10?  How does tk integration get 
into a Python release?

It would be nice to know what version of Python users should be on the lookout 
for in order to get this fix.

--
nosy: +PySimpleGUI

___
Python tracker 

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



[issue41152] IDLE: revise setting of iomenu.encoding and .errors

2020-06-29 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
pull_requests: +20367
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/21214

___
Python tracker 

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



[issue41158] IDLE: rewrite the code for handling file encoding

2020-06-29 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


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

___
Python tracker 

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



[issue41048] read_mime_types() should read the rule file using UTF-8, not the locale encoding

2020-06-29 Thread miss-islington


miss-islington  added the comment:


New changeset 9e36b6e6c8fc8925c6a5e7b57aff527bc4b862a8 by Miss Islington (bot) 
in branch '3.9':
bpo-41048: mimetypes should read the rule file using UTF-8, not the locale 
encoding (GH-20998)
https://github.com/python/cpython/commit/9e36b6e6c8fc8925c6a5e7b57aff527bc4b862a8


--

___
Python tracker 

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



[issue41048] read_mime_types() should read the rule file using UTF-8, not the locale encoding

2020-06-29 Thread miss-islington


miss-islington  added the comment:


New changeset 7731139b7af655b9f5df6d1b5493f8dfdf41d569 by Miss Islington (bot) 
in branch '3.8':
bpo-41048: mimetypes should read the rule file using UTF-8, not the locale 
encoding (GH-20998)
https://github.com/python/cpython/commit/7731139b7af655b9f5df6d1b5493f8dfdf41d569


--

___
Python tracker 

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



[issue41152] IDLE: revise setting of iomenu.encoding and .errors

2020-06-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

PR 21214 sets the encoding of stdin/stdout/stderr to 'utf-8'. Error handler is 
set to 'surrogatepass' or 'surrogateescape' because these error handlers are 
used when convert strings between Python and Tcl. It guarantees that reading 
from stdin and writing back to stdout will never fail, even if you paste 
garbage from clipboard. Printing file paths will never fail too.

--

___
Python tracker 

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



[issue19335] codeop misclassifies incomplete code with 'nonlocal'

2020-06-29 Thread Lysandros Nikolaou

Lysandros Nikolaou  added the comment:

> What do either of you think?  Can the new parser handle it better?

Pablo, correct me if I'm wrong, but I think that the parser has nothing to do 
with this. It's not the parser that produces this SyntaxError, it's some later 
compilation phase (I guess symtable creation phase?), which I know very very 
little about, so I can't really offer an opinion on what can be done.

In any case, this should actually indicate that this is not a parser issue:

(venv) ➜  cpython git:(master) ./python.exe
Python 3.10.0a0 (heads/master:7f569c9bc0, Jun 29 2020, 14:48:39)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> a = '''\
... def a():
... def b():
... nonlocal c
... '''
>>> a
'def a():\ndef b():\nnonlocal c\n'
>>> compile(a, '?', 'single')
Traceback (most recent call last):
  File "", line 1, in 
  File "?", line 3
SyntaxError: no binding for nonlocal 'c' found
>>> import ast
>>> ast.dump(ast.parse(a, mode='single'))
"Interactive(body=[FunctionDef(name='a', args=arguments(posonlyargs=[], 
args=[], kwonlyargs=[], kw_defaults=[], defaults=[]), 
body=[FunctionDef(name='b', args=arguments(posonlyargs=[], args=[], 
kwonlyargs=[], kw_defaults=[], defaults=[]), body=[Nonlocal(names=['c'])], 
decorator_list=[])], decorator_list=[])])"

All in all, I think that Nick's hack is the way to go here, since it's comc's 
responsibility to correctly check if a statement is incomplete, right?


> When the new parser compiles a function, does it know or could it know 
> whether it is nested?

It currently doesn't, but the tokenizer holds a stack of indent tokens, which 
can be accessed by the parser. This way we could indeed check if there are two 
or more pending indent tokens, before generating an AST for nonlocal. However, 
I don't think that this is generally a good idea. Parsing should not care about 
statement semantics, in that a nonlocal statement should be like any other 
statement in the parser's point of view.

--

___
Python tracker 

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



[issue19335] codeop misclassifies incomplete code with 'nonlocal'

2020-06-29 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

> Pablo, correct me if I'm wrong, but I think that the parser has nothing to do 
> with this. It's not the parser that produces this SyntaxError, it's some 
> later compilation phase (I guess symtable creation phase?), which I know very 
> very little about, so I can't really offer an opinion on what can be done.

Yeah, this is correct the parser has nothing to be done with this, what is 
involved in this is the compiler, as the generated AST looks correct.

>  When the new parser compiles a function, does it know or could it know 
> whether it is nested?

Nop, the parser does not even know what a 'function' is while it parses, as 
that is only determined in the product of the parser itself: the AST. The piece 
that understands semantically what a function is and if is nested or not is the 
compiler.

> Parsing should not care about statement semantics, in that a nonlocal 
> statement should be like any other statement in the parser's point of view.

Yup, I very much agree with this. The parser must not know about the semantics 
of the AST elements (forcing it to do so will be not only very complex but also 
will make maintenance much more difficult as the parser will be coupled with 
the semantics of the language is parsing as opposed to only having to know 
about the grammar).

> All in all, I think that Nick's hack is the way to go here, since it's comc's 
> responsibility to correctly check if a statement is incomplete, right?

If I understand correctly, Nick is talking about modifying the different 
iterations for different errors in codeop no?

--

___
Python tracker 

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



[issue41084] Signify that a SyntaxError comes from an fstring in the error message

2020-06-29 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 990efe0fff749773887a50cb1ecb2c5d09263cf8 by Lysandros Nikolaou in 
branch '3.9':
[3.9] bpo-41084: Fix test_fstring failure when using the old parser (GH-21212)
https://github.com/python/cpython/commit/990efe0fff749773887a50cb1ecb2c5d09263cf8


--

___
Python tracker 

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



[issue19335] codeop misclassifies incomplete code with 'nonlocal'

2020-06-29 Thread Lysandros Nikolaou


Lysandros Nikolaou  added the comment:

> If I understand correctly, Nick is talking about modifying the different 
> iterations for different errors in codeop no?

I was talking about msg200936, where Nick proposed to just hardcode a check for 
nonlocal SyntaxErrors in codeop._maybe_compile, which should return None (which 
means incomplete) when the SyntaxError comes as a result of a nonlocal binding 
not existing.

--

___
Python tracker 

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



[issue41084] Signify that a SyntaxError comes from an fstring in the error message

2020-06-29 Thread Lysandros Nikolaou


Change by Lysandros Nikolaou :


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



[issue41084] Signify that a SyntaxError comes from an fstring in the error message

2020-06-29 Thread Lysandros Nikolaou


Lysandros Nikolaou  added the comment:

Thanks, Victor!

The fix is merged, so I'm closing this again.

--

___
Python tracker 

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



[issue39672] Segmentation fault on shutdown with shelve & c pickle

2020-06-29 Thread Andrei Daraschenka


Andrei Daraschenka  added the comment:

Hello zd nex

After a little research, it became clear that this drop is due to vague garbage 
collection behavior. As you know, method `__del__` is called by the garbage 
collector and when this happens there is no guarantee that the rest of the 
objects are not yet cleaned.

def __del__(self):
if not hasattr(self, 'writeback'):
return
self.close()

But in the `close` method, synchronization with the disk occurred and objects 
were created for modules that were no longer in memory and, as a result, method 
`dump` fell with an error, because when trying to get module `pickle` it was 
already gone (due to the garbage collector).

Modules/_pickle.c

4353 PickleState *st = _Pickle_GetGlobalState();


But `_Pickle_GetGlobalState` can't return right result because pickle module 
was gone from memory by garbage collector.

In this case, you encountered a problem when the C code tried to use a module 
that was no longer in memory since this module deleted the garbage collector.

--

___
Python tracker 

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



[issue39672] Segmentation fault on shutdown with shelve & c pickle

2020-06-29 Thread zd nex


zd nex  added the comment:

Hello, 
ok but it seems to me that this segfault happens always (it is not random)? So 
I guess that there should be way how fix C pickle, no? Or something else should 
be done with __del__ method of shelve. Because in Python2 this was normally 
working. It seems to me that when user just reads data of shelve and then exit 
happens this can happen.

Why Python2 normally worked?

--

___
Python tracker 

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



[issue39701] Azure Pipelines PR broken

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

This appears to be fixed now.

--
status: open -> closed

___
Python tracker 

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



[issue40223] Add -fwrapv for new icc versions

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

icc does not like the label reordering from:

   ddd1949fea59f256e51191540a4446f75ed608fa


This is one step further, but not much. Possibilities are still:

   1) The reordering exposes an overflow.

   2) The new ordering is not supported by icc, it introduces UB
  that is masked by -fwrapv (again, does -fwrapv only disable
  a single optimization? My guess is that it disables several).


This was found by automated bisecting, I still have no time to really
investigate what is going on.

--

___
Python tracker 

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



[issue40223] Add -fwrapv for new icc versions

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

cc Benjamin, in case he has any ideas:  icc does not like the label
reordering in ceval.c, but that can be anything from an icc issue
to an actual overflow in ceval.c.

--
nosy: +benjamin.peterson

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Anthony Sottile


Anthony Sottile  added the comment:

this breaks builds for ubuntu, I'd suggest reverting this (especially because 
it appears to build fine without this patch)

2020-06-29T08:52:56.8303672Z x86_64-linux-gnu-gcc -pthread -fPIC -Wdate-time 
-D_FORTIFY_SOURCE=2 -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 
-Wall -g -fdebug-prefix-map=/tmp/code=. 
-specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector -Wformat 
-Werror=format-security -std=c99 -Wextra -Wno-unused-result 
-Wno-unused-parameter -Wno-missing-field-initializers 
-Werror=implicit-function-declaration -fvisibility=hidden -I../Include/internal 
-DCONFIG_64=1 -DASM=1 -I../Include -IObjects -IPython -I. 
-I/usr/include/x86_64-linux-gnu -I/tmp/code/Include -I/tmp/code/build-static -c 
/tmp/code/Modules/_decimal/_decimal.c -o 
build/temp.linux-x86_64-3.9/tmp/code/Modules/_decimal/_decimal.o
2020-06-29T08:52:56.9003112Z /tmp/code/Modules/_decimal/_decimal.c:40:4: error: 
#error "libmpdec version >= 2.5.0 required"
2020-06-29T08:52:56.9005053Z#error "libmpdec version >= 2.5.0 required"
2020-06-29T08:52:56.9006190Z ^

--
nosy: +Anthony Sottile

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Anthony Sottile


Anthony Sottile  added the comment:

especially this late in the beta period for 3.9 -- it would be unfortunate for 
3.10 but it's an explicit break of feature freeze for 3.9

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

Ubuntu is my main system, and it does not break the build.

If you use --with-system-libmpdec, you need to keep in sync with
the external libmpdec.

--

___
Python tracker 

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



[issue5004] socket.getfqdn() doesn't cope properly with purely DNS-based setups

2020-06-29 Thread Jan Hudec


Jan Hudec  added the comment:

Confirming the fixed version linked in previous comment by Thomas Waldmann is 
correct and matches what `hostname -f` does.

--
nosy: +bulb
versions: +Python 3.10, Python 3.5, 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



[issue41159] Nested async dict comprehension fails with SyntaxError

2020-06-29 Thread Hrvoje Nikšić

New submission from Hrvoje Nikšić :

Originally brought up on StackOverflow, 
https://stackoverflow.com/questions/60799366/nested-async-comprehension :

This dict comprehension parses and works correctly:

async def bar():
return {
n: await foo(n) for n in [1, 2, 3]
}

But making it nested fails with a SyntaxError:

async def bar():
return {
i: {
n: await foo(n) for n in [1, 2, 3]
} for i in [1,2,3]
}

The error reported is:

  File "", line 0
SyntaxError: asynchronous comprehension outside of an asynchronous function

--
components: Interpreter Core
messages: 372582
nosy: hniksic
priority: normal
severity: normal
status: open
title: Nested async dict comprehension fails with SyntaxError
type: behavior
versions: Python 3.8

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Anthony Sottile


Anthony Sottile  added the comment:

reverting this patch passes all the tests, what's the motivation and why were 
there no code reviews for this?

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

Please name a buildbot that does not pass.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

Or is this CoC bait again?

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Anthony Sottile


Anthony Sottile  added the comment:

I package pythons for ubuntu:

https://github.com/deadsnakes/python3.9-nightly/actions/runs/151286686
https://github.com/deadsnakes/python3.10-nightly/actions/runs/151287821

--

___
Python tracker 

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



[issue41159] Nested async dict comprehension fails with SyntaxError

2020-06-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

This is a duplicate of issue33346.

--
nosy: +serhiy.storchaka
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> Syntax error with async generator inside dictionary 
comprehension

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

If Python is packaged with **system** libmpdec, you can only use
the official Ubuntu Python/libmpdec version combination.

Which are packaged by Matthias Klose, who is on the CC list here.


Otherwise, why use the system libmpdec at all and not the version
shipped with Python?


If I install into a venv, I also don't use the system libmpdec.

--

___
Python tracker 

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



[issue41160] Cross-compiling for GNU/Hurd fails

2020-06-29 Thread Marius Bakke


New submission from Marius Bakke :

Attempting to cross-compile for i586-pc-gnu fails with the following message:

  checking MACHDEP... configure: error: cross build not supported for 
i586-pc-gnu

Adding a trivial case for it in the configure script is sufficient.

--
components: Build
messages: 372590
nosy: mbakke
priority: normal
severity: normal
status: open
title: Cross-compiling for GNU/Hurd fails

___
Python tracker 

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



[issue41160] Cross-compiling for GNU/Hurd fails

2020-06-29 Thread Marius Bakke


Change by Marius Bakke :


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

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Anthony Sottile


Anthony Sottile  added the comment:

> Otherwise, why use the system libmpdec at all and not the version
shipped with Python?

the packages are faithful reproductions of upstream packages, deviating from 
those introduces surprises for downstreams


> If I install into a venv, I also don't use the system libmpdec.

that's simply not true:

$ python3.9 -m venv vvv
$ vvv/bin/python -c 'import _decimal, subprocess; subprocess.check_call(("ldd", 
_decimal.__file__))'
linux-vdso.so.1 (0x7fff429ec000)
libmpdec.so.2 => /lib/x86_64-linux-gnu/libmpdec.so.2 
(0x7fcaeae03000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 
(0x7fcaeade)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x7fcaeabee000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x7fcaeaa9f000)
/lib64/ld-linux-x86-64.so.2 (0x7fcaeae7f000)

--

___
Python tracker 

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



[issue33346] Syntax error with async generator inside dictionary comprehension

2020-06-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

What can I do to move this issue forward?

We already missed 3.7, 3.8 and 3.9.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

You are talking to the author of libmpdec *and* the _decimal module.
Perhaps this problem has occurred to me, too:


$ diff -ur mpdecimal-2.5.0/libmpdec cpython-commit/Modules/_decimal/libmpdec/
Only in mpdecimal-2.5.0/libmpdec: .objs
Only in mpdecimal-2.5.0/libmpdec: Makefile.in
Only in mpdecimal-2.5.0/libmpdec: Makefile.vc
diff -ur mpdecimal-2.5.0/libmpdec/README.txt 
cpython-commit/Modules/_decimal/libmpdec/README.txt
--- mpdecimal-2.5.0/libmpdec/README.txt 2020-06-27 21:41:49.0 +0200
+++ cpython-commit/Modules/_decimal/libmpdec/README.txt 2020-06-29 
13:46:45.379299458 +0200
@@ -8,6 +8,9 @@
 Mike Cowlishaw/IBM's General Decimal Arithmetic Specification.
 
 
+Files required for the Python _decimal module
+=
+
   Core files for small and medium precision arithmetic
   
 
Only in mpdecimal-2.5.0/libmpdec: bench.c
Only in mpdecimal-2.5.0/libmpdec: bench_full.c
Only in mpdecimal-2.5.0/libmpdec: examples
Only in cpython-commit/Modules/_decimal/libmpdec/: mpdecimal.h
Only in mpdecimal-2.5.0/libmpdec: mpdecimal.h.in
Only in mpdecimal-2.5.0/libmpdec: mpdecimal32vc.h
Only in mpdecimal-2.5.0/libmpdec: mpdecimal64vc.h
Only in mpdecimal-2.5.0/libmpdec: mpsignal.c



You are the one here who wants to ship a non-recommended libmpdec
version with Python-3.9.

--

___
Python tracker 

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



[issue39085] Improve docs for await expression

2020-06-29 Thread Bill Wallace


Bill Wallace  added the comment:

There are a few other places on the documentation that are imprecise or 
misleading for await. While the information needed is scattered around the 
docs, I think these can also be improved. I'm pretty sure these fit with this 
issue.

Developing with asyncio guide:
https://docs.python.org/3/library/asyncio-dev.html#concurrency-and-multithreading
 - first paragraph, "When a Task executes an await expression, the running Task 
gets suspended, and the event loop executes the next Task."  Taken by itself it 
isn't clear that execution of the awaitable starts immediately without 
intervention from the event loop. A possible fix might be to add "If the 
awaited expression is a coroutine its execution begins immediately and the  
running Task will not suspend till the awaited expression stalls waiting for a 
result." 

The same sentence is found in the Task documentation: 
https://docs.python.org/3/library/asyncio-task.html#task-object

--
nosy: +wwallace

___
Python tracker 

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



[issue29778] _Py_CheckPython3 uses uninitialized dllpath when embedder sets module path with Py_SetPath

2020-06-29 Thread Steve Dower


Steve Dower  added the comment:

> I understand that LoadLibraryExW() must not be attempted if _Py_dll_path is 
> empty, or if Py_GetPrefix() is empty. Am I right?

More likely those should never be empty. Perhaps sys.prefix is optional, but 
the DLL path is the current executing module, and should always be set.

I suspect you're right, that 3.7 is also affected. But earlier versions would 
only _not_ fill the DLL path for static (non-shared) builds.

It looks like Py_SetPath in 3.7 started clearing it unnecessarily, so that may 
be the cause.

--
stage: resolved -> needs patch

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Christian Heimes


Change by Christian Heimes :


--
nosy: +christian.heimes
priority: normal -> release blocker

___
Python tracker 

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



[issue29778] _Py_CheckPython3 uses uninitialized dllpath when embedder sets module path with Py_SetPath

2020-06-29 Thread Steve Dower


Steve Dower  added the comment:

Sorry, I take that back. Earlier versions would indeed skip initialization in 
some cases.

I propose we deprecate the dll_path field in PathConfig and just get the path 
directly in the three places it's necessary. The path calculations have 
security exposure, so let's just avoid trying to manage additional state around 
it unnecessarily.

I'll work on a patch this week unless someone else gets to it first.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

This is no release blocker. Version 2.5.0 has been in 3.9 for a long time, and 
people should use the correct version.

--
priority: release blocker -> normal

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

--with-system-libmpdec is a **long term** tool for distributions.

Pinning the version number ensures that they use the correct version.

--

___
Python tracker 

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



[issue41155] Tkinter -postoffset not working for TCombobox

2020-06-29 Thread E. Paine


E. Paine  added the comment:

This is a strange bug, as the fix is simply to explicitly give the style 
(`style='TCombobox'`). This is, however, a Tcl/Tk issue as it can be reproduced 
in wish (I used the script attached). I therefore ask you close this issue as 
third party (you can take it up with the Tcl team if you want).

--
nosy: +epaine
Added file: https://bugs.python.org/file49275/postoffset.tcl

___
Python tracker 

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



[issue41161] libmpdec-2.5.0 update is missing news entry

2020-06-29 Thread Christian Heimes


New submission from Christian Heimes :

libmpdec was updated in bpo-40874 but there is no entry in the changelog. Every 
non-trivial change should be accompanied by a Misc/NEWS.d/ blurb. Please update 
the changelog manually.

--
assignee: skrah
components: Documentation
keywords: 3.9regression
messages: 372600
nosy: christian.heimes, skrah
priority: normal
severity: normal
stage: needs patch
status: open
title: libmpdec-2.5.0 update is missing news entry
type: enhancement
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



[issue41162] Clear audit hooks after destructors

2020-06-29 Thread Steve Dower


New submission from Steve Dower :

Because of when _Py_ClearAuditHooks is called during finalization, it is 
possible that __del__ destructors will be called after hooks have been cleared. 
Audit events that would be raised here are dropped.

We should ensure these events are received by any known hooks for the 
interpreter (Python) or the runtime (C).

(Thanks to Frank Li for the report.)

--
components: Interpreter Core
messages: 372601
nosy: christian.heimes, steve.dower
priority: normal
severity: normal
stage: needs patch
status: open
title: Clear audit hooks after destructors
type: security
versions: Python 3.10, 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



[issue35975] Put back the ability to parse files where async/await aren't keywords

2020-06-29 Thread Guido van Rossum


Guido van Rossum  added the comment:

Fixed again. Thanks Stefan for finding this! I apologize for the bug.

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



[issue40275] test.support has way too many imports

2020-06-29 Thread hai shi


Change by hai shi :


--
pull_requests: +20371
pull_request: https://github.com/python/cpython/pull/21219

___
Python tracker 

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



[issue41154] test_pkgutil:test_name_resolution fails on some platforms

2020-06-29 Thread Vinay Sajip

Vinay Sajip  added the comment:

The problem appears to be in importlib. I put in a breakpoint in the test just 
before it tries to import the module é. (At this point it has successfully 
imported a module called वमस in an earlier loop iteration.)

Then, in a different terminal console, I cd'd to the test directory and tried 
the import directly:
$ ls -l
total 0
drwxr-xr-x  3   x  102 29 Jun 17:55 é
drwxr-xr-x  4   x  136 29 Jun 17:55 वमस
$ ~/projects/cpython/python.exe
Python 3.10.0a0 (heads/master:a3ad95d, Jun 29 2020, 17:50:09)
[Clang 8.0.0 (clang-800.0.42.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import वमस
>>> import é
Traceback (most recent call last):
  File "", line 1, in 
ModuleNotFoundError: No module named 'é'

So for some reason, importlib is failing to import the é module. (The 
é/__init__.py is a zero-byte file.)

Adding Brett to nosy.

--
nosy: +brett.cannon

___
Python tracker 

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



[issue40884] Added defaults parameter for logging.Formatter

2020-06-29 Thread Vinay Sajip


Change by Vinay Sajip :


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



[issue34360] urllib.parse doesn't fully comply to RFC 3986

2020-06-29 Thread Rahul Jha


Change by Rahul Jha :


--
nosy: +RJ722

___
Python tracker 

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



[issue29753] Ctypes Packing Bitfields Incorrectly - Linux

2020-06-29 Thread Antoine Pitrou


Change by Antoine Pitrou :


--
versions: +Python 3.8, Python 3.9 -Python 2.7, Python 3.4, 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



[issue19335] codeop misclassifies incomplete code with 'nonlocal'

2020-06-29 Thread Rahul Jha


Rahul Jha  added the comment:

> That may actually be another alternative: instead of doing the "try
> appending newlines and see if it works or generates different errors",
> we may be able to switch to the tokenizer if the initial compilation
> fails and check for hanging INDENT tokens (i.e. INDENTS without a
> corresponding DEDENT). That would get us much closer to what the real
> eval loop is doing.

>From what I understand, "checking for two or more hanging INDENTS" and, 
>"hardcoding a check for nonlocal SyntaxErrors in codeop._maybe_compile" are 
>two different solutions, right?  If yes, do we have an answer to which one of 
>them is more cleaner, and henceforth, the preferable solution?

I, personally, like the idea of checking INDENTS primarily because of it's 
reduced specificity, but I am in no position to comment on this (I already 
kinda did ':D), and you folks know better! For all we know, we should be 
optimizing for specificity.

Also, reading Nick's comments and the comc's code, gives me the feeling that a 
fix for this wouldn't require drastic changes.  I'm slowly starting my journey 
with CPython, and I'd like to contribute a patch if that is the case. Thanks!

--

___
Python tracker 

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



[issue41163] test_weakref hangs

2020-06-29 Thread Peter Kuťák

New submission from Peter Kuťák :

Command make hangs on test_weakref 
I compile python 3.6.11 (latest compatible with my settings raspbian jessie)
I compile on OrangePi i96 - single core ARM 

I think it is same problem as Issue29796

--
components: Tests
messages: 372605
nosy: Peter Kuťák
priority: normal
severity: normal
status: open
title: test_weakref hangs
type: compile error
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



[issue41004] Hash collisions in IPv4Interface and IPv6Interface

2020-06-29 Thread Eric V. Smith


Eric V. Smith  added the comment:


New changeset b30ee26e366bf509b7538d79bfec6c6d38d53f28 by Ravi Teja P in branch 
'master':
bpo-41004: Resolve hash collisions for IPv4Interface and IPv6Interface 
(GH-21033)
https://github.com/python/cpython/commit/b30ee26e366bf509b7538d79bfec6c6d38d53f28


--

___
Python tracker 

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



[issue41004] Hash collisions in IPv4Interface and IPv6Interface

2020-06-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +20373
pull_request: https://github.com/python/cpython/pull/21221

___
Python tracker 

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



[issue41004] Hash collisions in IPv4Interface and IPv6Interface

2020-06-29 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 6.0 -> 7.0
pull_requests: +20372
pull_request: https://github.com/python/cpython/pull/21220

___
Python tracker 

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



[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)

2020-06-29 Thread Andrew


Andrew  added the comment:

Thanks for your reply Ned.

I think you are right about mac OS sandboxes messing something up. Python 
builds most of the extension modules fine if I do a straightforward build in 
the /tmp directory like you said.

Do you know of any easy ways to disable mac OS sandboxes from being used in the 
python build from the command line? Alternatively, how do I open the python 
project in xcode11 GUI? I think I might be able to disable sandboxes from 
there. If you are not very familiar with mac OS sandboxes like me, feel free to 
leave that up to me to figure out.

Regarding you question about my command line tools version:

I upgraded the my xcode command line tools installation to 11.4 - I believe 
this is the latest version that's supported on mac 10.15.1

I still get the same error behavior though when building outside of /tmp.

In this case, here is the compiler that's getting used.

% gcc --version
Configured with: --prefix=/Library/Developer/CommandLineTools/usr 
--with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/4.2.1
Apple clang version 11.0.3 (clang-1103.0.32.29)
Target: x86_64-apple-darwin19.3.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

--
status: pending -> open

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Łukasz Langa

Łukasz Langa  added the comment:

Stefan brought libmpdec-2.5.0 to 3.9 shortly before Beta 2. Due to us being 
busy with the importlib fiasco, this went under our radar. It shouldn't have. 
It's a large chunk of refactored code merged without review after the beta 
freeze. Betas aren't for changing style guides and language standards, etc. etc.

Sadly, given that this already got released as part of Beta 2 and Beta 3 
shortly after, I think at this point it's pointless to revert it. And the new 
PR simply requires a shared version to match the one that we are bundling now 
in sources, reverting just this one is out of the question.


> Or is this CoC bait again?

Stefan, please, don't be like that. What purpose does this serve?

Anthony noted a new failure related to your unreviewed and under-documented 
commit. You slipped in libmpdec-2.5.0 during the beta freeze without any 
discussion. It catches up to you right now. No reason to shoot the messenger.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Anthony Sottile

Anthony Sottile  added the comment:

Łukasz: what would you recommend for downstream packagers?

I have essentially two options (assuming this isn't reverted in cpython master 
which I believe makes the most sense since cpython still works fine with older 
libmpdec):

- revert this individual commit as a patch
- fork further from debian's packaging and use the vendored libmpdec (this 
potentially carries other negative side-effects since it makes the packages 
unlike upstream's -- and potentially susceptible to vendor/security drift since 
we don't carry patches for vendored components (but would get them from system 
libmpdec))

I'd rather not carry that patch indefinitely if possible -- especially when 
this cannot be built in a compatible way on software that's a mere 2 months old 
(ubuntu 20.04).  For similar libraries (ssl, ffi, etc.) this would be a very 
major break in building.

--

___
Python tracker 

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



[issue41162] Clear audit hooks after destructors

2020-06-29 Thread JIanqiu Tao


JIanqiu Tao  added the comment:

Patch attached below works well, but with less functionality for users' audit 
hook.
Pure Python audit hook implement looks safe enough.
Should we need call _PySys_ClearAuditHooks earlier for more functionality?

--
keywords: +patch
nosy: +zkonge
Added file: https://bugs.python.org/file49276/clearaudithook.patch

___
Python tracker 

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



[issue41004] Hash collisions in IPv4Interface and IPv6Interface

2020-06-29 Thread miss-islington


miss-islington  added the comment:


New changeset dc8ce8ead182de46584cc1ed8a8c51d48240cbd5 by Miss Islington (bot) 
in branch '3.8':
bpo-41004: Resolve hash collisions for IPv4Interface and IPv6Interface 
(GH-21033)
https://github.com/python/cpython/commit/dc8ce8ead182de46584cc1ed8a8c51d48240cbd5


--

___
Python tracker 

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



[issue41004] Hash collisions in IPv4Interface and IPv6Interface

2020-06-29 Thread miss-islington


miss-islington  added the comment:


New changeset 9a646aa82dfa62d70ca2a99ada901ee6cf9f82bd by Miss Islington (bot) 
in branch '3.9':
bpo-41004: Resolve hash collisions for IPv4Interface and IPv6Interface 
(GH-21033)
https://github.com/python/cpython/commit/9a646aa82dfa62d70ca2a99ada901ee6cf9f82bd


--

___
Python tracker 

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



[issue41004] Hash collisions in IPv4Interface and IPv6Interface

2020-06-29 Thread Eric V. Smith


Change by Eric V. Smith :


--
assignee:  -> eric.smith
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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

> Anthony noted a new failure related to your unreviewed and under-documented 
> commit.

He claimed a failure in Ubuntu (in a manner that I took as petulant),
which isn't the case.  It is a failure in a custom Ubuntu distro
that uses --with-system-libmpdec in an unintended way.


> You slipped in libmpdec-2.5.0 during the beta freeze without any discussion.

I did not slip it in at all. You were on the nosy list from the
very start of this issue, and so was Matthias.


> It catches up to you right now. No reason to shoot the messenger.


It catches up to people who use --with-system-libmpdec in an
unintended manner.

It is intended for a scenario like merging Python 3.9 into Sid,
then testing, then stable.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

> unreviewed and under-documented commit.

libmpdec has been one of the few zero fault areas of Python.
Please stop spreading FUD.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Christian Heimes


Christian Heimes  added the comment:

> > unreviewed and under-documented commit.
>
> libmpdec has been one of the few zero fault areas of Python.
> Please stop spreading FUD.

This has nothing to do with your excellent fault rate (lack of any issues).

The commit had no Misc/NEWS.d blurb and therefore was undocumented. I have 
opened bpo-41161 to address the issue. There was also no approval or review 
from another core dev on GH-20652.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah

Stefan Krah  added the comment:

> This has nothing to do with your excellent fault rate (lack of any issues).

I sounds like that though for random people who read this issue and think
that Łukasz is the grand release manager who puts a person in his place.

That was incredibly inappropriate.  libmpdec has **found** issues in
decNumber that were acknowledged by Cowlishaw.

If one's reputation is questioned every time one opens an issue here
(notably by people who are not subject experts at all), then I *have*
to respond in no uncertain terms.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

> I have opened bpo-41161 to address the issue.

Thanks, that is a more considerate approach, I'll add the note!

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

Also note that people did not react at all to the fact that
coroutine storage was not thread safe across several releases.

No one asked for News entry.

But "breaking" a fringe distro seems to be a major disaster.

--

___
Python tracker 

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



[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)

2020-06-29 Thread Ned Deily


Ned Deily  added the comment:

> Do you know of any easy ways to disable mac OS sandboxes from being used in 
> the python build from the command line?

Please show the exact steps you used to build this, in particular, the full 
./configure statement and any relevant env variable settings. I don't know how 
to disable the sandboxes because I've never seen something like this before and 
I don't know for sure how to reproduce. If I had to take a guess, I suspect it 
has to do with the location of your source tree which looks like it might be at 
a unconventional location at the root level: /mathworks/devel.  As you may 
know, macOS 10.15 Catalina has made a lot of under the cover changes to file 
system structure including the splitting of / into immutable and mutable 
subvolumes (/System/Volumes/Data). You may want to try moving /mathworks to 
another location rather than directly under /, perhaps under /opt or under 
/Users.

--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Christian Heimes


Christian Heimes  added the comment:

> Also note that people did not react at all to the fact that
> coroutine storage was not thread safe across several releases.

That's whataboutism.

> No one asked for News entry.

The bot did ask you to add a news entry. According to 
https://devguide.python.org/triaging/#github-labels-for-prs the "skip news" 
label should only be used in trivial cases like fixing a typo.

> But "breaking" a fringe distro seems to be a major disaster.

I find your choice of words hurtful and it demeaning.

Other core developer go through great length to keep backwards compatibility 
for older or less commonly used systems. In bpo-40810 Erlend researched SQLite 
version numbers before support for support for ancient SQLite was dropped. I'm 
spending a considerable effort to keep Python working with unsupported but 
still widely used OpenSSL and LibreSSL versions.

--

___
Python tracker 

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



[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)

2020-06-29 Thread Ned Deily


Ned Deily  added the comment:

PS. Or try doing an out-of-tree build. Perhaps the problem is just due to 
trying to do the build under that unconventional location under /.  

cd ~/build
./path/to/sourcetree/configure ...
make ...

--

___
Python tracker 

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



[issue37999] No longer use implicit convertion to int with loss

2020-06-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset e67f7db3c34f70536f36c56bb82e33c3512a53a3 by Serhiy Storchaka in 
branch 'master':
bpo-37999: Simplify the conversion code for %c, %d, %x, etc. (GH-20437)
https://github.com/python/cpython/commit/e67f7db3c34f70536f36c56bb82e33c3512a53a3


--

___
Python tracker 

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



[issue40874] Update to libmpdec-2.5.0

2020-06-29 Thread Stefan Krah


Stefan Krah  added the comment:

> The bot did ask you to add a news entry.

And I deliberately did not, out of politeness. Two release managers
were added and they did not ask.

> Other core developer go through great length to keep backwards compatibility 
> for older or less commonly used systems.

Ok, I take that back then.  I go through great lengths to keep
libmpdec and Python in sync.

--

___
Python tracker 

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



[issue41154] test_pkgutil:test_name_resolution fails on some platforms

2020-06-29 Thread Brett Cannon


Brett Cannon  added the comment:

I wonder if it's a problem from Unicode representation since I don't think 
importlib tries to have a standard normalization form of Unicode. I could see 
that leading to how the file system encoded something differing from how it was 
encoded in the test file, leading to a claim the file doesn't exist.

And thanks to binary file paths that isn't necessarily a wrong result. :P

--

___
Python tracker 

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



[issue41162] Clear audit hooks after destructors

2020-06-29 Thread JIanqiu Tao


Change by JIanqiu Tao :


--
pull_requests: +20374
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/21222

___
Python tracker 

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



[issue41046] unittest: make skipTest a classmethod

2020-06-29 Thread Andrei Daraschenka


Andrei Daraschenka  added the comment:

Hello and thanks for your issue. Can you explain why we need to make method as 
`classmethod` because in your example you don't provide argument for 
`cls.skipTest()`.

--
nosy: +dorosch

___
Python tracker 

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



  1   2   >