[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread miss-islington


miss-islington  added the comment:


New changeset 0ef61ee7b194a1c15747d6bca3cf30a5c581e7e3 by Miss Islington (bot) 
in branch '3.6':
bpo-34457: Python/ast.c: Add missing NULL check to alias_for_import_name(). 
(GH-8852)
https://github.com/python/cpython/commit/0ef61ee7b194a1c15747d6bca3cf30a5c581e7e3


--

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread miss-islington


miss-islington  added the comment:


New changeset b8e7319d39bf44355bf60f9bbec07cfbbe56739d by Miss Islington (bot) 
in branch '3.7':
bpo-34457: Python/ast.c: Add missing NULL check to alias_for_import_name(). 
(GH-8852)
https://github.com/python/cpython/commit/b8e7319d39bf44355bf60f9bbec07cfbbe56739d


--
nosy: +miss-islington

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread miss-islington


miss-islington  added the comment:


New changeset b14a68fd7d8f02bd133b59709f969c1c564f5978 by Miss Islington (bot) 
in branch '3.6':
bpo-34456: pickle: Add missing NULL check to save_global(). (GH-8851)
https://github.com/python/cpython/commit/b14a68fd7d8f02bd133b59709f969c1c564f5978


--

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread miss-islington


miss-islington  added the comment:


New changeset 3152bc36fd1a8ab349d6802e9b48dd88a35b3620 by Miss Islington (bot) 
in branch '3.7':
bpo-34456: pickle: Add missing NULL check to save_global(). (GH-8851)
https://github.com/python/cpython/commit/3152bc36fd1a8ab349d6802e9b48dd88a35b3620


--
nosy: +miss-islington

___
Python tracker 

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



[issue34400] Undefined behavior in Parser/parsetok.c

2018-08-21 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset eb9a1c01d07309006ef5544da62ba813685bd098 by Serhiy Storchaka 
(Zackery Spytz) in branch '2.7':
[2.7] bpo-34400: Fix more undefined behavior in parsetok.c (GH-8833). (GH-8849)
https://github.com/python/cpython/commit/eb9a1c01d07309006ef5544da62ba813685bd098


--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8328

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset 28853a249b1d0c890b7e9ca345290bb8c1756446 by Serhiy Storchaka 
(Alexey Izbyshev) in branch 'master':
bpo-34457: Python/ast.c: Add missing NULL check to alias_for_import_name(). 
(GH-8852)
https://github.com/python/cpython/commit/28853a249b1d0c890b7e9ca345290bb8c1756446


--

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8327

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8326

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread miss-islington


Change by miss-islington :


--
pull_requests: +8325

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset f8c06b028036e50596e75d4c9f6b27ba05133efe by Serhiy Storchaka 
(Alexey Izbyshev) in branch 'master':
bpo-34456: pickle: Add missing NULL check to save_global(). (GH-8851)
https://github.com/python/cpython/commit/f8c06b028036e50596e75d4c9f6b27ba05133efe


--

___
Python tracker 

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



[issue34455] Tkinter crashing when pressing Command + ^ (OSX)

2018-08-21 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

PS, When replaying by email, please delete the quoted message, as it is 
redundant in the web page display.

--

___
Python tracker 

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



[issue34455] Tkinter crashing when pressing Command + ^ (OSX)

2018-08-21 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

Please download and run https://bugs.python.org/file47676/tk_scroll.py.  It is 
a very stripped-down version of an IDLE editor window.  After making a couple 
of edits, to make sure it is working, hit the fatal key combination.  Does it 
still crash?

--

___
Python tracker 

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



[issue34410] Segfault/TimeoutError: itertools.tee of multiprocessing.pool.imap_unordered

2018-08-21 Thread Carlo Rosati


Carlo Rosati  added the comment:

If what you've said is correct, would it make the most sense to create a 
Manager method which returns a Proxy to a tee'd iterator?

--

___
Python tracker 

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



[issue34458] No way to alternate options

2018-08-21 Thread Victor Porton


New submission from Victor Porton :

I have:

parser.add_argument('-p', '--preload', help='preload asset', action='append', 
metavar='NAMESPACE')

I want also add:

parser.add_argument('-f', '--file', help='preload file', action='append', 
metavar='FILE', dest='preload')

This way I could specify -p and/or -f options in any order (like: first -p then 
-f then -p again) and store then in 'preload' field in the order which the user 
specified the options.

But I have no way to know if an option is -p or -f :-(

Please add something to argparse to solve this problem.

--
components: Library (Lib)
messages: 323857
nosy: porton
priority: normal
severity: normal
status: open
title: No way to alternate options
versions: Python 3.7

___
Python tracker 

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



[issue34454] datetime: NULL dereference in fromisoformat() on PyUnicode_AsUTF8AndSize() failure

2018-08-21 Thread Paul Ganssle


Paul Ganssle  added the comment:

> Note that technically a difference between C and Python implementation of 
> fromisoformat() will still remain: if a part of the input string before or 
> after the separator contains surrogates, the C code will throw a 
> UnicodeEncodeError while the Python code -- ValueError. But since the former 
> error is a subclass of the latter, I guess it's OK, what do you think?

I think the fact that the unicode string is decoded is an implementation 
detail. I would suggest swallowing the decode error and raising a standard 
ValueError.

--

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


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

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread Alexey Izbyshev


Alexey Izbyshev  added the comment:

The NULL dereference seems to be hard to trigger due to caching for 
one-character Latin-1 strings, but being safe probably won't hurt.

--

___
Python tracker 

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



[issue34457] Missing NULL check in alias_for_import_name() from Python/ast.c

2018-08-21 Thread Alexey Izbyshev


New submission from Alexey Izbyshev :

The return value of PyUnicode_InternFromString() is dereferenced without 
checking at 
https://github.com/python/cpython/blob/ef8861c112ed1dac9351958c121bc24ca4ecdb08/Python/ast.c#L3256

Reported by Svace static analyzer.

--
components: Interpreter Core
messages: 323854
nosy: izbyshev, serhiy.storchaka
priority: normal
severity: normal
status: open
title: Missing NULL check in alias_for_import_name() from Python/ast.c
type: behavior
versions: Python 2.7, Python 3.4, Python 3.5, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


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

___
Python tracker 

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



[issue34456] pickle: Missing NULL check in save_global()

2018-08-21 Thread Alexey Izbyshev


New submission from Alexey Izbyshev :

The return value of Py_BuildValue() is dereferenced without checking at 
https://github.com/python/cpython/blob/ef8861c112ed1dac9351958c121bc24ca4ecdb08/Modules/_pickle.c#L3457

Reported by Svace static analyzer.

--
components: Extension Modules
messages: 323853
nosy: izbyshev, serhiy.storchaka
priority: normal
severity: normal
status: open
title: pickle: Missing NULL check in save_global()
type: behavior
versions: Python 3.5, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue34455] Tkinter crashing when pressing Command + ^ (OSX)

2018-08-21 Thread iPodClassic

iPodClassic  added the comment:

Hello Terry. I installed 3.7 from Python.org
First time it crashed,  I was playing around with some basic code (I’m 
learning), whilst trying to enter [ character (which is option + ^key in 
spanish keyboard), by mistake I pressed command (key next to option) and 
crashed IDLE.
Since I saw the crash report, I tried reproducing in in order to report the 
supposed bug.

Then I restarted IDLE from OSX Spotlight, and successfully crashed it using the 
same key combo several times.

I did not create any custom keyset, just happened by mistake.

Regards,

> El 21 ago 2018, a las 20:02 , Terry J. Reedy  
> escribió:
> 
> 
> Terry J. Reedy  added the comment:
> 
> I believe NSException crashes are due to interaction between tcl/tk and the 
> Mac graphics subsystem, in this case for 10.11.6.
> 
> Did you install 3.7 with the python.org installer or something else?
> How did you start IDLE and what state was it in when you hit command-^?
> 
> Neither of the default Mac key sets use Command-Key-^.  Did you create a 
> custom keyset and bind it to something?
> 
> --
> assignee: terry.reedy ->
> components: +Tkinter, macOS -IDLE
> nosy: +ned.deily, ronaldoussoren
> title: IDLE crashing when pressing Command + ^  (OSX) -> Tkinter crashing 
> when pressing Command + ^  (OSX)
> 
> ___
> Python tracker 
> 
> ___

--

___
Python tracker 

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



[issue34455] Tkinter crashing when pressing Command + ^ (OSX)

2018-08-21 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

I believe NSException crashes are due to interaction between tcl/tk and the Mac 
graphics subsystem, in this case for 10.11.6.

Did you install 3.7 with the python.org installer or something else?
How did you start IDLE and what state was it in when you hit command-^?

Neither of the default Mac key sets use Command-Key-^.  Did you create a custom 
keyset and bind it to something?

--
assignee: terry.reedy -> 
components: +Tkinter, macOS -IDLE
nosy: +ned.deily, ronaldoussoren
title: IDLE crashing when pressing Command + ^  (OSX) -> Tkinter crashing when 
pressing Command + ^  (OSX)

___
Python tracker 

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



[issue34446] ambiguous _max_size parameter in SpooledTemporaryFile

2018-08-21 Thread jcc2220


jcc2220  added the comment:

Here's an example of the inconsistency - if SpooledTemporaryFile is 
instantiated with max_size set to 0, it will not rollover, EXCEPT when truncate 
method is called.  Both write and writelines (public methods) call _check, 
which deals with rollover, but _check will never rollover if max_size is set to 
0.

--

___
Python tracker 

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



[issue34454] datetime: NULL dereference in fromisoformat() on PyUnicode_AsUTF8AndSize() failure

2018-08-21 Thread Alexey Izbyshev


Alexey Izbyshev  added the comment:

I will be glad to rebase my PR and remove the try/except from the test if you 
remove the dependency of separator searching code on PyUnicode_AsUTF8AndSize() 
as you suggest. Or we can go the other way and merge mine first -- whatever you 
prefer.

Note that technically a difference between C and Python implementation of 
fromisoformat() will still remain: if a part of the input string before or 
after the separator contains surrogates, the C code will throw a 
UnicodeEncodeError while the Python code -- ValueError. But since the former 
error is a subclass of the latter, I guess it's OK, what do you think?

Also, note that the other discovered C/Python impl difference (for strftime, 
handled by another try/catch in tests) won't go away, of course, unless someone 
is ready to fix that as well.

--

___
Python tracker 

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



[issue34455] IDLE crashing when pressing Command + ^ (OSX)

2018-08-21 Thread iPodClassic

New submission from iPodClassic :

IDLE crashes when pressing Command (⌘) + ^ 

I have attached the crash report just in case.

--
assignee: terry.reedy
components: IDLE
files: crash report idle.txt
messages: 323848
nosy: iPodClassic, terry.reedy
priority: normal
severity: normal
status: open
title: IDLE crashing when pressing Command + ^  (OSX)
type: crash
versions: Python 3.7
Added file: https://bugs.python.org/file47758/crash report idle.txt

___
Python tracker 

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



[issue14841] os.get_terminal_size() should check stdin as a fallback

2018-08-21 Thread Eryk Sun


Eryk Sun  added the comment:

The Windows implementation shouldn't map file-descriptor values 0, 1, and 2 to 
the process standard handles. fileno(stdout) may not even be 1 in some cases. 
It should use `handle = _get_osfhandle(fd)`, which is more generally correct 
and not limited to hard-coded defaults. 

Regarding this issue, the docs should clarify that the Windows console's input 
buffer cannot be used to get the screen buffer size. Typically the input buffer 
is STDIN_FILENO (0) or opened via  "CONIN$" or "CON" (read mode). Thus there is 
no point to checking stdin in Windows since it will always fail.

I agree that the default behavior should be extended to check a 
platform-dependent tty/console device. In Windows this is `fd = 
_open("CONOUT$", _O_RDWR)`.

--
nosy: +eryksun

___
Python tracker 

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



[issue34454] datetime: NULL dereference in fromisoformat() on PyUnicode_AsUTF8AndSize() failure

2018-08-21 Thread Paul Ganssle


Paul Ganssle  added the comment:

So this is related to something I was actually meaning to fix. When I wrote 
this code I didn't understand the way PyUnicode works, there's actually no need 
to call `PyUnicode_AsUTF8AndSize()` on the entire unicode string.

My understanding is that each glyph in a given PyUnicode object is the same 
size, which means that this section of the code can go: 
https://github.com/python/cpython/blob/master/Modules/_datetimemodule.c#L4862

Instead we can just break the string up as glyphs 0-10 and 11+ and pass them 
on. Since by the contract of the function glyphs 0-10 and 11+ *must* be ASCII, 
we no longer need to worry about *valid* use cases where a character 
un-representable by UTF-8 will lead to anything except an error.

Obviously the null pointer error needs to be fixed since it should raise an 
error and not segfault.

I'd be happy to do the part where the string is broken up *before* being passed 
to PyUnicode_AsUTF8AndSize() if it would make it easier to implement your PR 
(which seems to touch a lot of other parts of the code as well).

--

___
Python tracker 

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



[issue34446] ambiguous _max_size parameter in SpooledTemporaryFile

2018-08-21 Thread Brett Cannon


Brett Cannon  added the comment:

Do realize that anything which starts with an underscore, like _check, is 
considered a private API.

--
nosy: +brett.cannon

___
Python tracker 

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



[issue34454] datetime: NULL dereference in fromisoformat() on PyUnicode_AsUTF8AndSize() failure

2018-08-21 Thread Alexey Izbyshev


Change by Alexey Izbyshev :


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

___
Python tracker 

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



[issue34454] datetime: NULL dereference in fromisoformat() on PyUnicode_AsUTF8AndSize() failure

2018-08-21 Thread Alexey Izbyshev


New submission from Alexey Izbyshev :

A failure of PyUnicode_AsUTF8AndSize() in various fromisoformat() functions in 
Modules/_datetimemodule.c leads to NULL dereference due to the missing check, 
e.g.:

>>> from datetime import date
>>> date.fromisoformat('\ud800')
Segmentation fault (core dumped)

This is similar to msg123474. The missing NULL check was reported by Svace 
static analyzer.

While preparing tests for this issue, I've discovered a deeper problem. The C 
datetime implementation uses PyUnicode_AsUTF8AndSize() in several places, 
making some functions reject strings containing surrogate code points (0xD800 - 
0xDFFF) since they can't be encoded in UTF-8. On the other hand, the 
pure-Python datetime implementation doesn't have this restriction. For example:

>>> import sys
>>> sys.modules['_datetime'] = None # block C implementation
>>> from datetime import time
>>> time().strftime('\ud800')
'\ud800'
>>> del sys.modules['datetime']
>>> del sys.modules['_datetime']
>>> from datetime import time
>>> time().strftime('\ud800')
Traceback (most recent call last):
  File "", line 1, in 
UnicodeEncodeError: 'utf-8' codec can't encode character '\ud800' in position 
0: surrogates not allowed

My PR (coming soon) doesn't address this difference but focuses on fixing the 
immediate problem instead. Suggestions are appreciated.

--
components: Extension Modules
messages: 323844
nosy: belopolsky, izbyshev, p-ganssle, serhiy.storchaka
priority: normal
severity: normal
status: open
title: datetime: NULL dereference in fromisoformat() on 
PyUnicode_AsUTF8AndSize() failure
type: crash
versions: Python 3.7, Python 3.8

___
Python tracker 

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



[issue34453] ipaddress module accepts some strange IPv6 addresses that it shouldn't

2018-08-21 Thread Luke Kenneth Casson Leighton


New submission from Luke Kenneth Casson Leighton :

adding some unit tests to some code being written,
searched randomly on the internet for an IPv6 test
suite and found one in php *shudder*
# https://github.com/gws/ipv6-address-test/blob/master/Tests/Ipv6TestCase.php

converted it to python, and was surprised to find that
there are two cases which the ipaddress.IPv6Address
module accepts, that it should not!

attached is a quick-and-dirty hacked together unit test
which shows the issue.  the full suite may be found
here (over 400 ipv6 addresses to test):

https://github.com/threefoldtech/jumpscale_core/blob/development_dynamic/tests/jumpscale_test/test10_j_data_types.py

--
components: Tests
files: ipv6test.py
messages: 323843
nosy: lkcl
priority: normal
severity: normal
status: open
title: ipaddress module accepts some strange IPv6 addresses that it shouldn't
type: behavior
versions: Python 3.5, Python 3.6
Added file: https://bugs.python.org/file47757/ipv6test.py

___
Python tracker 

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



[issue14841] os.get_terminal_size() should check stdin as a fallback

2018-08-21 Thread Mark Lawrence


Change by Mark Lawrence :


--
nosy:  -BreamoreBoy

___
Python tracker 

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



[issue34452] docs: help text for [>>>] toggle always in English

2018-08-21 Thread Jonathan Fine


Jonathan Fine  added the comment:

Thank you. I've raised
"The help text for [>>>] toggle always in English"
https://github.com/python/python-docs-theme/issues/23

--

___
Python tracker 

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



[issue34452] docs: help text for [>>>] toggle always in English

2018-08-21 Thread Mariatta Wijaya


Change by Mariatta Wijaya :


--
status: pending -> closed

___
Python tracker 

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



[issue34452] docs: help text for [>>>] toggle always in English

2018-08-21 Thread Mariatta Wijaya


Mariatta Wijaya  added the comment:

The help text that says "Show the prompts and output" comes from 
python-docs-theme, and it is tracked in a separate repo: 
https://github.com/python/python-docs-theme/

Not sure if there's any customization that we can do here. I suggest raising 
the issue in python-docs-theme first.

--
nosy: +Mariatta
resolution:  -> third party
stage:  -> resolved
status: open -> pending

___
Python tracker 

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



[issue34452] docs: help text for [>>>] toggle always in English

2018-08-21 Thread Jonathan Fine


New submission from Jonathan Fine :

As subject. Background information in #34451.

See https://docs.python.org/fr/3/tutorial/introduction.html

The hover help text for the [>>>] is in English, not French. Korean and 
Japanese documentation has the same problem.

--
assignee: docs@python
components: Documentation
messages: 323840
nosy: docs@python, jfine2358
priority: normal
severity: normal
status: open
title: docs: help text for [>>>] toggle always in English
type: behavior
versions: Python 3.4, Python 3.5, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue34451] docs: tutorial/introduction doesn't mention toggle of prompts

2018-08-21 Thread Jonathan Fine


New submission from Jonathan Fine :

Interactive code examples need the prompt to be stripped, before 
copy-and-paste. This is explained in 
https://docs.python.org/3/tutorial/introduction.html

But this page does not tell us about the [>>>] prompt-toggle at top of each 
interactive code example. This caused a user error, reported in  
https://mail.python.org/pipermail/python-ideas/2018-August/052869.html.

The [>>>] toggle isn't in the Python 2.7 docs, so nothing to fix there!

--
assignee: docs@python
components: Documentation
messages: 323839
nosy: docs@python, jfine2358
priority: normal
severity: normal
status: open
title: docs: tutorial/introduction doesn't mention toggle of prompts
versions: Python 3.4, Python 3.5, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue34417] imp.find_module reacts badly to iterator

2018-08-21 Thread Phillip M. Feldman


Phillip M. Feldman  added the comment:

My apologies for the tone of my remark.  I am grateful to you and others
who donate their time to develop the code.

I'm attaching the wrapper code that I created to work around the problem.

Phillip

def expander(paths='./*'):
   """
   OVERVIEW

   This function is a generator, i.e., creates an iterator that recursively
   searches a list of folders in an incremental fashion.  This approach is
   advantageous when the folder tree(s) to be searched are large and the
item of
   interest is likely to be found early in the process.

   INPUTS

   `paths` must be either (a) a list of folder paths (each of which is a
string)
   or (b) a single string containing one or more folder paths separated by
the
   OS-specific path delimiter.

   Each path in `paths` must be either (a) an existing folder or (b) an
existing
   folder followed by '/*' or '\*'.  In case (a), the folder string is
copied
   from the input (`paths`) to the output result verbatim.  In case (b), the
   folder string is replaced by an expanded list that includes not only the
   base (the portion of the path that remains after the '/*' or '\*' has
been
   removed), but all subfolders as well.

   RETURN VALUES

   The returned value is an iterator.

   Invoking the `next` method of the iterator produces one folder path at a
   time.
   """

   if isinstance(paths, basestring):
  paths= paths.split(os.pathsep)

   elif not isinstance(paths, list):
  raise TypeError("`paths` must be either a string or a list of
strings.")

   found= set()

   for path in paths:
  if path.endswith('/*') or path.endswith('\*'):

 # A recursive search of subfolders is required:
 for item in os.walk(path[:-2]):
base= os.path.abspath(item[0])
new= [os.path.join(base, nested) for nested in item[1]]

for item in new:
   if not item in found:
  found.add(item)
  yield item

  else:

 # No recursive search is required:
 if not item in found:
found.add(item)
yield item

   # end for path in paths

def find_module(module_name, in_folders=[]):
   """
   This function finds a module and return the fully-qualified file name.
   Folders from `in_folders`, if specified, are search first, followed by
   folders in the global `import_path` list.

   If any folder name in `in_folders` or `import_path` ends with an
asterisk,
   indicating that a recursive search is required, `files.expander` is
   invoked to create iterators that return one folder at a time, and
   `imp.find_module` is invoked separately for each of these folders.

   EXPLICIT INPUTS

   `module_name` is the unqualified name of the module to be found.

   `in_folders` is an optional list of additional folders to be searched
before
   the folders in `import_path` are searched.

   IMPLICIT INPUTS

   `import_path` is obtained from the global namespace.

   RETURN VALUES

   If `find_module` is able to find the requested module, it returns the
same
   three return values (`f`, `filename`, and `description`) that
   `imp.find_module` would return.
   """

   if isinstance(in_folders, basestring):
  in_folders= [in_folders]
   elif not isinstance(in_folders, list):
  raise TypeError("If specified, `in_folders` must be either a string
or a "
"list of strings.  (A string is wrapped to produce a length-1
list).")

   if any([item.endswith('*') for item in in_folders ]) or \
  any([item.endswith('*') for item in import_path]):

  ex= None

  for folder in itertools.chain(
expander(in_folders), expander(import_path)):
 try:
return imp.find_module(module_name, in_folders + import_path)
 except Exception as ex:
pass

  if ex:
 raise ex

   else:
  return imp.find_module(module_name, in_folders + import_path)

On Tue, Aug 21, 2018 at 10:32 AM Brett Cannon 
wrote:

>
> Brett Cannon  added the comment:
>
> Saying "the available functionality is massively inefficient" is
> unnecessarily hostile towards those of us who actually wrote and maintain
> that code. Without diving into the code, chances are that requirement is
> there so that the C code can use macros to access the list as efficiently
> as possible.
>
> Now if you want to propose specific changes to importlib's code for it to
> work with iterables instead of just lists then we would be happy to review
> the pull request.
>
> --
>
> ___
> Python tracker 
> 
> ___
>

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 

[issue34417] imp.find_module reacts badly to iterator

2018-08-21 Thread Brett Cannon


Brett Cannon  added the comment:

Saying "the available functionality is massively inefficient" is unnecessarily 
hostile towards those of us who actually wrote and maintain that code. Without 
diving into the code, chances are that requirement is there so that the C code 
can use macros to access the list as efficiently as possible.

Now if you want to propose specific changes to importlib's code for it to work 
with iterables instead of just lists then we would be happy to review the pull 
request.

--

___
Python tracker 

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



[issue14841] os.get_terminal_size() should check stdin as a fallback

2018-08-21 Thread Grant Jenks


Grant Jenks  added the comment:

I asked on the ncurses maintainers email list about their logic and was pointed 
to tty_settings.c which checks:

1. stderr
2. stdout
3. stdin
4. open('/dev/tty', 'r+')

I don't know a cross-platform way to check #4 but I think #1-3 are a reasonable 
change to shutil.get_terminal_size().

The current logic checks only stdout. I'd like to amend that to try stderr, 
stdout, and stdin after checking the COLUMNS and LINES env vars. So the new 
logic would be:

1. Check COLUMNS and LINES env vars (for overrides)
2. Check os.get_terminal_size(stderr)
3. Check os.get_terminal_size(stdout)
4. Check os.get_terminal_size(stdin)

--
nosy: +grantjenks
versions: +Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue34400] Undefined behavior in Parser/parsetok.c

2018-08-21 Thread Zackery Spytz


Change by Zackery Spytz :


--
pull_requests: +8321

___
Python tracker 

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



[issue34450] improve shutil.make_archive

2018-08-21 Thread Emily Morehouse


Emily Morehouse  added the comment:

I'll have to think through this a bit more, but my gut is that it would be much 
more favorable for backwards-compatibility to clarify the documentation instead 
of changing the functionality.

In any case, the change would only take effect in 3.8+, so it sounds like a 
backported documentation update is surely needed.

Thanks for the thorough report! :)

--
components: +Library (Lib)
nosy: +emilyemorehouse
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



[issue34207] test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 3.x (3.8) buildbots

2018-08-21 Thread Łukasz Langa

Łukasz Langa  added the comment:

Looking at what's going on here, this is quite possibly a PEP 538 side-effect 
(I see surrogate escapes).

--

___
Python tracker 

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



[issue34207] test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 3.x (3.8) buildbots

2018-08-21 Thread Łukasz Langa

Change by Łukasz Langa :


--
nosy: +ncoghlan

___
Python tracker 

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



[issue34207] test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 3.x (3.8) buildbots

2018-08-21 Thread Łukasz Langa

Łukasz Langa  added the comment:

I think the root cause is this: the mentioned tests are invalid when no LC_* or 
LANG environment variables are present. Michael's sleuthing in issue34347 might 
provide a way for us to fix those.

As a workaround in the mean time, if this is an option on your system, set 
LC_ALL=en_US.UTF8, the three failing tests pass now.

--

___
Python tracker 

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



[issue34207] test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 3.x (3.8) buildbots

2018-08-21 Thread Łukasz Langa

Łukasz Langa  added the comment:

This is definitely dependent on the environment. I can reproduce exactly the 
same failures on a CentOS 7 box at work, too.

--
nosy: +lukasz.langa

___
Python tracker 

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



[issue34347] AIX: test_utf8_mode.test_cmd_line fails

2018-08-21 Thread Łukasz Langa

Change by Łukasz Langa :


--
keywords: +3.7regression

___
Python tracker 

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



[issue34403] test_utf8_mode.test_cmd_line() fails on HP-UX due to false assumptions

2018-08-21 Thread Łukasz Langa

Change by Łukasz Langa :


--
keywords: +3.7regression
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



[issue34207] test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 3.x (3.8) buildbots

2018-08-21 Thread Łukasz Langa

Change by Łukasz Langa :


--
keywords: +3.7regression
versions: +Python 3.7

___
Python tracker 

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



[issue34403] test_utf8_mode.test_cmd_line() fails on HP-UX due to false assumptions

2018-08-21 Thread Łukasz Langa

Change by Łukasz Langa :


--
dependencies: +test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 
3.x (3.8) buildbots

___
Python tracker 

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



[issue34347] AIX: test_utf8_mode.test_cmd_line fails

2018-08-21 Thread Łukasz Langa

Change by Łukasz Langa :


--
dependencies: +test_cmd_line test_utf8_mode test_warnings fail in all FreeBSD 
3.x (3.8) buildbots

___
Python tracker 

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



[issue34347] AIX: test_utf8_mode.test_cmd_line fails

2018-08-21 Thread Łukasz Langa

Łukasz Langa  added the comment:

I have no idea what's going on here yet but just wanted to report that we are 
seeing this issue on one FreeBSD buildbot, too:

https://buildbot.python.org/all/#/builders/124/builds/508/steps/4/logs/stdio

I can also reproduce on CentOS 7.

Could this be related to LC_ALL= or related environment variables?

--
nosy: +lukasz.langa

___
Python tracker 

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



[issue34194] test_ssl, AIX, and defaults for _ssl connections

2018-08-21 Thread Michael Felt

Michael Felt  added the comment:

On 21/08/2018 09:46, Michael wrote:
> On 04/08/2018 16:37, Michael Felt wrote:
>> Some help would really be appreciated!
> Gotten a bit further :)

A little bit more:

Modules/_ssl.c

 +3707  fprintf(stderr,"load_cert_chain():certfile:%s\n", (char *)
PyBytes_AS_STRING(certfile_bytes));
 +3708  PySSL_BEGIN_ALLOW_THREADS_S(pw_info.thread_state);
 +3709  r = SSL_CTX_use_certificate_chain_file(self->ctx,
 +3710  PyBytes_AS_STRING(certfile_bytes));
 +3711  PySSL_END_ALLOW_THREADS_S(pw_info.thread_state);
 +3712  if (r != 1) {
 +3713  fprintf(stderr,"load_cert_chain():r:%d: errno:%d
ERR_peek_last_error():%d\n", r, errno, ERR_peek_last_error());

load_cert_chain():certfile:/data/prj/python/git/python3-3.8/Lib/test/XXXnonexisting.pem
load_cert_chain():r:0: errno:2 ERR_peek_last_error():0
load_cert_chain():certfile:/data/prj/python/git/python3-3.8/Lib/test/nullcert.pem
load_cert_chain():r:0: errno:0 ERR_peek_last_error():0

Note: I swapped BADCERT and NULLCERT, so now above shows with NULLCERT,
while below

* Below: the first failure - is an OSError (file does not exist, and
passes the test). The second test is "badcert" and AIX is not reporting
the error via ERR_peek_last_error(), but is does seem there is an error
that 'openssl' does return. The third is just to show a connection where
CAfile provides the needed data (for comparison)

FIRST: works as expected

root@x066:[/data/prj/python/python3-3.8]openssl s_client -quiet -connect
www.mindrot.org:443 -CAfile
/data/prj/python/git/python3-3.8/Lib/test/XXXnonex>
804401144:error:02001002:system library:fopen:No such file or
directory:bss_file.c:175:fopen('/data/prj/python/git/python3-3.8/Lib/test/XXXnonexisting.pem','r')
804401144:error:2006D080:BIO routines:BIO_new_file:no such
file:bss_file.c:182:
804401144:error:0B084002:x509 certificate
routines:X509_load_cert_crl_file:system lib:by_file.c:253:
depth=1 C = US, O = Let's Encrypt, CN = Let's Encrypt Authority X3
verify error:num=20:unable to get local issuer certificate

SECOND: there are errors, but not one reported by ERR_peek_last_error()?

BADCERT
root@x066:[/data/prj/python/python3-3.8]openssl s_client -quiet -connect
www.mindrot.org:443 -CAfile
/data/prj/python/git/python3-3.8/Lib/test/badcert.>
804401144:error:0906D064:PEM routines:PEM_read_bio:bad base64
decode:pem_lib.c:830:
804401144:error:0B084009:x509 certificate
routines:X509_load_cert_crl_file:PEM lib:by_file.c:259:
depth=1 C = US, O = Let's Encrypt, CN = Let's Encrypt Authority X3
verify error:num=20:unable to get local issuer certificate

NULLCERT
root@x066:[/data/prj/python/python3-3.8]openssl s_client -quiet -connect
www.mindrot.org:443 -CAfile
/data/prj/python/git/python3-3.8/Lib/test/nullcert>
depth=1 C = US, O = Let's Encrypt, CN = Let's Encrypt Authority X3
verify error:num=20:unable to get local issuer certificate

THIRD: working as expected, for comparison

root@x066:[/data/prj/python/python3-3.8]openssl s_client -quiet -connect
www.mindrot.org:443 -CAfile /var/ssl/cacert.pem
depth=2 O = Digital Signature Trust Co., CN = DST Root CA X3
verify return:1
depth=1 C = US, O = Let's Encrypt, CN = Let's Encrypt Authority X3
verify return:1
depth=0 CN = mindrot.org
verify return:1

Again - help requested!!!

Michael

--

___
Python tracker 

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



[issue34450] improve shutil.make_archive

2018-08-21 Thread iMath

New submission from iMath :

The current behavior of shutil.make_archive caused many issues , the problem is 
mainly on the extracted archive directory hierarchy. These are the proofs:
https://stackoverflow.com/questions/51914467/directory-hierarchy-issue-when-using-shutil-make-archive

https://stackoverflow.com/questions/32640053/compressing-directory-using-shutil-make-archive-while-preserving-directory-str

https://stackoverflow.com/questions/41624800/shutil-make-archive-issue-dont-want-directories-included-in-zip-file

https://stackoverflow.com/questions/50156657/unexpected-file-using-shutil-make-archive-to-compress-file
For example , if I want to create a zip archive of the pip package (path 
specified by pip.__path__[0])), and need a directory named pip to hold the  
files and folders which originally reside in the pip package when unpacking the 
archive, then I need give root_dirparameter of shutil.make_archive the parent 
directory of the pippackage path (root_dir=Path(pip.__path__[0]).parent), and 
then the base_dir parameter the final path component of the pip package 
path(base_dir=Path(pip.__path__[0]).name) , so it is os.path.join(root_dir, 
base_dir) that specified the directory to archive , so weird !!!
I suggest to change shutil.make_archive(base_name, format[, root_dir[, 
base_dir]]) to shutil.make_archive(base_name, format[, archived_dir[, 
archive_prfix]]) where archived_dirdenotes the path to be archived and 
archive_prfix denotes the common prefix of all files and directories in the 
archive (it is just a path component and we shouldn’t assume the existence of 
it on the file system).

If the current behavior of shutil.make_archive won’t be changed , I’d suggest 
improve its doc, because  so many people couldn’t grasp the use of 
shutil.make_archive even consulting the doc , these are the proofs:
https://stackoverflow.com/questions/45245079/python-how-to-use-shutil-make-archive
https://stackoverflow.com/questions/30049201/how-to-compress-a-file-with-shutil-make-archive-in-python

--
messages: 323829
nosy: redstone-cold
priority: normal
severity: normal
status: open
title: improve  shutil.make_archive

___
Python tracker 

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



[issue34434] Removal of kwargs for built-in types not covered with "changed in Python" note in documentation

2018-08-21 Thread Louis Sautier


Change by Louis Sautier :


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

___
Python tracker 

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



[issue34410] Segfault/TimeoutError: itertools.tee of multiprocessing.pool.imap_unordered

2018-08-21 Thread Xiang Zhang


Xiang Zhang  added the comment:

Ahh, the infinite iterator could also releases GIL in `PyIter_Next`.

--

___
Python tracker 

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



[issue34449] HP aCC complains about invalid -fPIC on HP-UX

2018-08-21 Thread Michael Osipov


Change by Michael Osipov <1983-01...@gmx.net>:


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

___
Python tracker 

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



[issue34449] HP aCC complains about invalid -fPIC on HP-UX

2018-08-21 Thread Michael Osipov


New submission from Michael Osipov <1983-01...@gmx.net>:

The compiler (HP aCC) says:

> /opt/aCC/bin/cc -Ae -b -L/usr/local/lib/hpux32 
> build/temp.hp-ux-B.11.31-ia64-3.8-pydebug/var/osipovmi/cpython/Modules/_ctypes/_ctypes.o
>  
> build/temp.hp-ux-B.11.31-ia64-3.8-pydebug/var/osipovmi/cpython/Modules/_ctypes/callbacks.o
>  
> build/temp.hp-ux-B.11.31-ia64-3.8-pydebug/var/osipovmi/cpython/Modules/_ctypes/callproc.o
>  
> build/temp.hp-ux-B.11.31-ia64-3.8-pydebug/var/osipovmi/cpython/Modules/_ctypes/stgdict.o
>  
> build/temp.hp-ux-B.11.31-ia64-3.8-pydebug/var/osipovmi/cpython/Modules/_ctypes/cfield.o
>  -L/usr/local/lib/hpux64 -L/usr/lib/hpux32 -L/usr/lib/hpux64 -L/usr/lib 
> -L/lib -L/usr/local/lib/hpux32 -L/usr/local/lib -lffi -ldl -o 
> build/lib.hp-ux-B.11.31-ia64-3.8-pydebug/_ctypes.so -fPIC
> cc: warning 901: unknown option: `-fPIC': use +help for online documentation.

On clang or GCC this is a compile time option, never a link option. For HP aCC 
objects must be compiled with +z -- which actually happens -- and linked with 
+b to a shared library -- which also happens here --. One can safely drop this 
switch from setup.py.

--
components: Build
messages: 323827
nosy: michael-o
priority: normal
severity: normal
status: open
title: HP aCC complains about invalid -fPIC on HP-UX
type: behavior
versions: Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue34404] test_time incorrectly defined

2018-08-21 Thread Michael Osipov


Change by Michael Osipov <1983-01...@gmx.net>:


--
versions: +Python 3.6, Python 3.8

___
Python tracker 

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



[issue34448] incomplete/missing message from configure.ac for usable wchar_t

2018-08-21 Thread Michael Osipov


Change by Michael Osipov <1983-01...@gmx.net>:


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



[issue34401] Make test_gdb work on HP-UX

2018-08-21 Thread Michael Osipov


Change by Michael Osipov <1983-01...@gmx.net>:


--
versions: +Python 3.6, Python 3.8

___
Python tracker 

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



[issue34403] test_utf8_mode.test_cmd_line() fails on HP-UX due to false assumptions

2018-08-21 Thread Michael Osipov


Change by Michael Osipov <1983-01...@gmx.net>:


--
versions: +Python 3.6, Python 3.8

___
Python tracker 

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



[issue34448] incomplete/missing message from configure.ac for usable wchar_t

2018-08-21 Thread Michael Osipov


Change by Michael Osipov <1983-01...@gmx.net>:


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

___
Python tracker 

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



[issue34448] incomplete/missing message from configure.ac for usable wchar_t

2018-08-21 Thread Michael Osipov


New submission from Michael Osipov <1983-01...@gmx.net>:

If the wchar_t is usable on a system we get the following:

> checking for UCS-4 tcl... no
> checking whether wchar_t is signed... no
> yes
> checking whether byte ordering is bigendian... yes
> checking ABIFLAGS... dm
> checking SOABI... cpython-38dm

Yes -- that is a simple 'yes'. Dangling.

A PR is in preparation.

--
components: Build
messages: 323826
nosy: michael-o
priority: normal
severity: normal
status: open
title: incomplete/missing message from configure.ac for usable wchar_t
type: enhancement
versions: Python 3.7, Python 3.8

___
Python tracker 

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



[issue26544] platform.libc_ver() returns incorrect version number

2018-08-21 Thread Matthias Klose


Matthias Klose  added the comment:

+1

--

___
Python tracker 

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



[issue34194] test_ssl, AIX, and defaults for _ssl connections

2018-08-21 Thread Michael Felt

Michael Felt  added the comment:

On 04/08/2018 16:37, Michael Felt wrote:
> Some help would really be appreciated!

Gotten a bit further :)

While it does not affect the 'failures', this change decreases 'errors'
by 8 (skipped +1).

I do not expect this to be 'acceptable' - however, I hope this helps an
expert come with some advice.

I played around with defining either OPENSSL_NO_SSL2 or
OPENSSL_VERSION_1_1. However, I do not think the latter is correct (AIX
still goes it - externally, openssl.1.0.2., not openssl.1.1.Y.)
and I felt
the configure process was attempting to use a dynamic process to
establish OPENSSL_NO_SSL2
rather than a definition being added to CFLAGS.

Again - help appreciated!

Before:
FAILED (failures=13, errors=11, skipped=10)
test test_ssl failed

After:
FAILED (failures=13, errors=2, skipped=11)
test test_ssl failed

diff --git a/Modules/_ssl.c b/Modules/_ssl.c
index 2bce4816d2..5fa442cedf 100644
--- a/Modules/_ssl.c
+++ b/Modules/_ssl.c
@@ -5790,9 +5790,11 @@ PyInit__ssl(void)

 /* protocol versions */
 #ifndef OPENSSL_NO_SSL2
+#ifndef _AIX
 PyModule_AddIntConstant(m, "PROTOCOL_SSLv2",
 PY_SSL_VERSION_SSL2);
 #endif
+#endif
 #ifndef OPENSSL_NO_SSL3
 PyModule_AddIntConstant(m, "PROTOCOL_SSLv3",
 PY_SSL_VERSION_SSL3);

--

___
Python tracker 

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



[issue26544] platform.libc_ver() returns incorrect version number

2018-08-21 Thread Marc-Andre Lemburg


Marc-Andre Lemburg  added the comment:

I added a comment to the PR, but other than that I think it's good to go.

--

___
Python tracker 

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



[issue34443] enum repr should use __qualname__

2018-08-21 Thread underscore_asterisk


underscore_asterisk  added the comment:

Hi,
I would like to work on this issue. I can submit a PR by tomorrow (or maybe 
even later today).

--
nosy: +underscore_asterisk

___
Python tracker 

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