[issue35357] unittest.mock.call can't represent calls to a method called 'parent'

2018-11-29 Thread Chris Withers


New submission from Chris Withers :

While working on https://bugs.python.org/issue35226, I stumbled upon this:

>>> from unittest.mock import call
>>> call.parent()
Traceback (most recent call last):
  File "", line 1, in 
TypeError: 'NoneType' object is not callable

Guess we need to make .parent and friends more uniquely named ;-)

--
assignee: cjw296
messages: 330757
nosy: cjw296, mariocj89, michael.foord
priority: normal
severity: normal
status: open
title: unittest.mock.call can't represent calls to a method called 'parent'

___
Python tracker 

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



[issue35356] A possible reference leak in the nis module

2018-11-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10057

___
Python tracker 

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



[issue35356] A possible reference leak in the nis module

2018-11-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset a2e3585e79c93b2372dbad46a744e28fcc6dad6d by Serhiy Storchaka 
(Zackery Spytz) in branch 'master':
bpo-35356: Fix a possible reference leak in nis.maps(). (GH-10808)
https://github.com/python/cpython/commit/a2e3585e79c93b2372dbad46a744e28fcc6dad6d


--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue35356] A possible reference leak in the nis module

2018-11-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10056

___
Python tracker 

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



[issue35356] A possible reference leak in the nis module

2018-11-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10055

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Ezio Melotti


Change by Ezio Melotti :


--
nosy:  -asdwqii

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Ezio Melotti


Ezio Melotti  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

(Karthikeyan is having trouble posting, so I'm trying on his behalf.)

--
nosy: +ezio.melotti

___
Python tracker 

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



[issue2771] Test issue

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue2771] Test issue

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

test comment

--
nosy: +xtreak

___
Python tracker 

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



[issue35356] A possible reference leak in the nis module

2018-11-29 Thread Zackery Spytz


Change by Zackery Spytz :


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

___
Python tracker 

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



[issue35356] A possible reference leak in the nis module

2018-11-29 Thread Zackery Spytz


New submission from Zackery Spytz :

In nis_maps(), the result of PyUnicode_FromString() is leaked if the 
PyList_Append() call fails.

--
components: Extension Modules
messages: 330747
nosy: ZackerySpytz
priority: normal
severity: normal
status: open
title: A possible reference leak in the nis module
versions: Python 2.7, 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



[issue31956] Add start and stop parameters to the array.index()

2018-11-29 Thread Ryan G.


Ryan G.  added the comment:

This functionality is useful to me. Is this issue still alive? If not, how can 
I help?

--
nosy: +Ryan G.

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue31177] unittest mock's reset_mock throws an error when an attribute has been deleted

2018-11-29 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +cjw296, mariocj89

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were similar 
to the original report.

--

___
Python tracker 

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



[issue31177] unittest mock's reset_mock throws an error when an attribute has been deleted

2018-11-29 Thread Eli_B


Change by Eli_B :


--
pull_requests: +10053

___
Python tracker 

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



[issue31177] unittest mock's reset_mock throws an error when an attribute has been deleted

2018-11-29 Thread Eli_B


Eli_B  added the comment:

I suggest that after reset_mock(), deleted attributes should be available 
again. In other words, their deletion is reset.

I'm opening a PR to this effect.

I reported this issue to testing-cabal's mock repo in May 2016 
(https://github.com/testing-cabal/mock/pull/361), but my original PR there just 
avoided an exception without reinstating the deleted attribute.

--
nosy: +Eli_B

___
Python tracker 

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



[issue35325] imp.find_module() return value documentation discrepancy

2018-11-29 Thread Windson Yang


Windson Yang  added the comment:

If I understand correctly, this may be better.

Try to find the module name. If path is omitted or None, the list of directory 
names given by sys.path is searched. If path is built-in or frozen modules, 
return None instead.

BTW, the dosstring should also be updated, I will not continue search the path 
if the path in build-in or frozen. and this module is deprecated since version 
3.4

--
nosy: +Windson Yang
versions: +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



[issue35348] Problems with handling the file command output in platform.architecture()

2018-11-29 Thread Windson Yang


Windson Yang  added the comment:

I agreed with Serhiy. I also found the function decode the output with latin-1, 
I think it will be better to use utf-8 instead.

--
nosy: +Windson Yang

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

> Now in order to keep the module more or less up-to-date, it still
> required regular updates, so the plan was to have it updated in the
> current versions of Python, but allow it to be used in older Python
> versions as well. That was the compromise to have it in the stdlib
> and not external. Otherwise, I would have not added it to the stdlib.

I don't understand if you are describing the current status or the history 
here. Do you know users who don't use platform form the stdlib, but use a more 
recent copy?

These users cannot get a more recent version of Python?

When you talk about copying Lib/platform.py from master to Python 2.7, are you 
talking about the ability to copy platform.py from master into an application 
to get a more recent version on Python 2.7? If yes, I don't understand how you 
plan to add back the linux_distribution() feature?

Sorry, I'm still lost :-(

--

___
Python tracker 

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



[issue35190] collections.abc.Sequence cannot be used to test whether a class provides a particular interface (doc issue)

2018-11-29 Thread Ivan Levkivskyi


Ivan Levkivskyi  added the comment:

I would propose to keep this one open as a superseding 
https://bugs.python.org/issue23864 and close the latter (assuming we are not 
going to make all classes protocols, we I think we really shouldn't, and 
instead we should improve the docs).

--

___
Python tracker 

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



[issue35336] Bug in C locale coercion with PYTHONCOERCECLOCALE=1

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


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

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread Marc-Andre Lemburg


Marc-Andre Lemburg  added the comment:

Ok, let me add some history here:

When I created the platform module it was clear that this would be
a module which will frequently need updates, since platforms evolve
faster than Python does.

I had developed this with a larger number of contributors outside
the stdlib for a while and then there was a request to add it to the
stdlib.

Now in order to keep the module more or less up-to-date, it still
required regular updates, so the plan was to have it updated in the
current versions of Python, but allow it to be used in older Python
versions as well. That was the compromise to have it in the stdlib
and not external. Otherwise, I would have not added it to the stdlib.

This is why it has a special status and keep backwards compatibility
much longer than other code in the stdlib.

This worked quite well, but for some systems such as the Linux
distros, it was impossible to keep up with the development in that
mode. Well, actually, there were multiple reasons why this part
failed: 1. Linux distros didn't not have a standard when I added
the code, 2. Then some distros started two or three different ones,
3. Distros started to use multiple standards with conflicting data,
4. New distros became popular more often than we could update the
code.

That's why I was fine with removing the code again and leaving this
part to a PyPI package.

Does it make more sense now ?

--

___
Python tracker 

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



[issue34021] [2.7] test_regrtest: test_env_changed() fails on x86 Windows XP VS9.0 2.7

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


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



[issue34021] [2.7] test_regrtest: test_env_changed() fails on x86 Windows XP VS9.0 2.7

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset f681e93e46925e862a8b0fa4b6e9e341fd8de3c2 by Victor Stinner in 
branch '2.7':
bpo-34021: Windows skips test_regrtest.test_env_changed() (GH-10804)
https://github.com/python/cpython/commit/f681e93e46925e862a8b0fa4b6e9e341fd8de3c2


--

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

> Please keep Python 2.7 compatibility. It should be possible to copy the 
> module back into Python 2.7 and use it there.

I don't understand why someone would like to copy Lib/platform.py from the 
master branch to Python 2.7? Python 2.7 already provides the platform module, 
it's part of its standard library.

platform.linux_distribution() function has been removed from master, so you 
cannot simply copy platform.py from master and use it in Python 2.7: it has a 
different API.

--

___
Python tracker 

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



[issue34021] [2.7] test_regrtest: test_env_changed() fails on x86 Windows XP VS9.0 2.7

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

Five months later nobody has any kind of clue explaining why the test randomly 
fails on this specific buildbot, whereas it's reliable on all other buildbots 
and all Python 3.x versions. So I wrote PR 10804 to skip the test on Windows. 
The feature will remain to be tested on all other platforms, and it's still 
tested on Windows on Python 3.x.

--

___
Python tracker 

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



[issue34021] [2.7] test_regrtest: test_env_changed() fails on x86 Windows XP VS9.0 2.7

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


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

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread Marc-Andre Lemburg


Marc-Andre Lemburg  added the comment:

Please keep Python 2.7 compatibility. It should be possible to copy the module 
back into Python 2.7 and use it there. This is not hard to do and allows it to 
fulfill its purpose as platform detection module even while part of the stdlib.

--
nosy: +lemburg

___
Python tracker 

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



[issue35217] REPL history is broken when python is invoked with cmd /c

2018-11-29 Thread Eryk Sun


Eryk Sun  added the comment:

The Windows console has a fixed number of history buffers. In Windows 7 the 
default maximum is four history buffers. In this case, if we run a script via 
cmd.exe -> py.exe -> python.exe, then only one history buffer remains for a 
child process. As you've observed, no history buffer is available for the fifth 
process if we run cmd.exe -> python.exe. 

You can increase the default maximum in the console's Alt+Space+D defaults 
dialog, under "Command History" -> "Number of Buffers". This corresponds to the 
"NumberOfHistoryBuffers" value in the registry key "HKCU\Console". 

You can increase the maximum for the current window in the console's 
Alt+Space+P properties dialog. If the current console was allocated by an 
application that was launched from a shortcut (i.e. a .LNK file), this property 
gets persisted in the shortcut itself. Otherwise it gets persisted in a 
registry key under "HKCU\Console" that's named for the startup window title. If 
no title was specified, the default title is the path to the executable, with 
backslashes replaced by underscore and the Windows directory as %SystemRoot%. 
For example, if you run cmd.exe from the Win+R run dialog, its console 
properties are stored in the registry key 
"HKCU\Console\%SystemRoot%_system32_cmd.exe".

--
nosy: +eryksun
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

> Should we keep compatibility with 2.7?

I don't think that the master branch (Python 3.8) has to be compatible with 
Python 2.7.

--

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

Thanks Pablo! I merged your change in 2.7, 3.6, 3.7 and master branches.

To reuse the example of my first message, we now get:

vstinner@apu$ ./python  -W error -m test test_asyncio -m test_no_such_test 
Run tests sequentially
0:00:00 load avg: 1.21 [1/1] test_asyncio
test_asyncio run no tests

== Tests result: NO TEST RUN ==

1 test run no tests:
test_asyncio

Total duration: 347 ms
Tests result: NO TEST RUN

vstinner@apu$ echo $?
0


So the exit status is still a success (code 0), but "Tests result: NO TEST RUN" 
is an hint that no test has been executed.

If we run two files, but one file runs no test, the output now contains "1 test 
run no tests: test_sys":

$ ./python -m test test_os test_sys -m test_access -v
== CPython 3.8.0a0 (heads/platform_popen:4fcc412d3d, Nov 29 2018, 21:21:53) 
[GCC 8.2.1 20181105 (Red Hat 8.2.1-5)]
== Linux-4.19.3-300.fc29.x86_64-x86_64-with-glibc2.28 little-endian
== cwd: /home/vstinner/prog/python/master/build/test_python_18420
== CPU count: 8
== encodings: locale=UTF-8, FS=utf-8
Run tests sequentially
0:00:00 load avg: 1.05 [1/2] test_os
test_access (test.test_os.FileTests) ... ok

--

Ran 1 test in 0.001s

OK
0:00:00 load avg: 1.05 [2/2] test_sys

--

Ran 0 tests in 0.000s

OK
test_sys run no tests

== Tests result: SUCCESS ==

1 test OK.

1 test run no tests:
test_sys

Total duration: 240 ms
Tests result: SUCCESS

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 2.7, 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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

While we are here, look at other outdated code:

* Top-imported warnings is not used.
* struct.calcsize('P') is always success.
* plistlib is always available.

Should we keep compatibility with 2.7?

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue35355] Some Errors involving formatted strings aren't reported in the right place.

2018-11-29 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

Evan, IDLE runs your code with the Python running IDLE.  Bad tracebacks are 
created by Python and are usually, as in this case, the fault of Python.  To 
decide, run your code directly with Python, at a command line, instead of 
indirectly with IDLE, and see if you get the same problem.  

In this case, I ran, on Windows, in Command Prompt, 'py -m a.tem3', where 'py' 
defaults to python 3.7.1 and 'a' is a directory on sys.path.

--
assignee: terry.reedy -> 
components:  -IDLE
stage:  -> resolved
status: open -> closed

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread miss-islington


miss-islington  added the comment:


New changeset 43d812692f9207520e1169ff88cd8d6c59cc4804 by Miss Islington (bot) 
in branch '3.6':
[3.7] bpo-34279: Synchronize regrtest with master (GH-10800)
https://github.com/python/cpython/commit/43d812692f9207520e1169ff88cd8d6c59cc4804


--
nosy: +miss-islington

___
Python tracker 

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



[issue34605] Avoid master/slave terminology

2018-11-29 Thread miss-islington


miss-islington  added the comment:


New changeset 43d812692f9207520e1169ff88cd8d6c59cc4804 by Miss Islington (bot) 
in branch '3.6':
[3.7] bpo-34279: Synchronize regrtest with master (GH-10800)
https://github.com/python/cpython/commit/43d812692f9207520e1169ff88cd8d6c59cc4804


--

___
Python tracker 

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



[issue34605] Avoid master/slave terminology

2018-11-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10050

___
Python tracker 

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



[issue35355] Some Errors involving formatted strings aren't reported in the right place.

2018-11-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

This looks like a duplicate of issue34364.

--
nosy: +serhiy.storchaka
resolution:  -> duplicate
superseder:  -> problem with traceback for syntax error in f-string

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10049

___
Python tracker 

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



[issue35355] Some Errors involving formatted strings aren't reported in the right place.

2018-11-29 Thread Evan Newman


Change by Evan Newman :


--
title: Some Errors involving  formatted strings aren't reported in the right 
place. -> Some Errors involving formatted strings aren't reported in the right 
place.

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 8a73cac618a050f4e74eb38ff43e48d9957a6dec by Victor Stinner in 
branch '3.7':
[3.7] bpo-34279: Synchronize regrtest with master (GH-10800)
https://github.com/python/cpython/commit/8a73cac618a050f4e74eb38ff43e48d9957a6dec


--

___
Python tracker 

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



[issue34605] Avoid master/slave terminology

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 8a73cac618a050f4e74eb38ff43e48d9957a6dec by Victor Stinner in 
branch '3.7':
[3.7] bpo-34279: Synchronize regrtest with master (GH-10800)
https://github.com/python/cpython/commit/8a73cac618a050f4e74eb38ff43e48d9957a6dec


--

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 36003003f26d0c30fc15ec4dc3b0d7697dff908e by Victor Stinner in 
branch '2.7':
bpo-34279, regrtest: Issue a warning if no tests have been executed (GH-10801)
https://github.com/python/cpython/commit/36003003f26d0c30fc15ec4dc3b0d7697dff908e


--

___
Python tracker 

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



[issue35355] Some Errors involving formatted strings aren't reported in the right place.

2018-11-29 Thread Evan Newman


New submission from Evan Newman :

Formatted strings seem to have some quirks.  
if you try putting in this, for example;
print(f'{0 0}')
; you get a syntax error, which is probably intended, but where the error is 
reported is not always accurate.  for example;
#just a comment, it doesn't matter what it says
print(f'{0 0}')
;will raise the syntax error, and highlight the j,u,and s in the comment!  that 
doesn't help, and makes it look like the comment is the error.  this is a real 
pain to debug if you hadn't known about this.  it took me about 2 hours to 
track down the problem.  seriously, this should be fixed.  I haven't tested the 
problem in any editor but idle, so the cause could be anywhere.  I was first 
using 3.7.0, I've just updated to 3.7.1 to make sure it still happens, and it 
does.

--
assignee: terry.reedy
components: IDLE
files: recreation.py
messages: 330719
nosy: Enewman, terry.reedy
priority: normal
severity: normal
status: open
title: Some Errors involving  formatted strings aren't reported in the right 
place.
type: behavior
versions: Python 3.7
Added file: https://bugs.python.org/file47959/recreation.py

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread Brett Cannon


Brett Cannon  added the comment:

It's because the module was originally kept compatible with Python 1.5.2: 
https://www.python.org/dev/peps/pep-0291/#backward-compatible-packages-modules-and-tools

--
nosy: +brett.cannon

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

> I think I have seen this bug reported elsewhere but can't find it now.

Sorry, I was referring to issue6028 and issue32570 that I thought were
similar to the original report.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

I was referring to issue6028 and issue32570.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

I was referring to issue6028 and issue32570.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

I was referring to issue6028 and issue32570.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

I was referring to issue6028 and issue32570.

--

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

I think I have seen this bug reported elsewhere but can't find it now.

A simple reproducer : 

def foo():
try:
raise Exception()
except:
foo()
foo()

Running under gdb on Ubuntu : 

Program received signal SIGABRT, Aborted.
0x77115428 in __GI_raise (sig=sig@entry=6) at 
../sysdeps/unix/sysv/linux/raise.c:54
54  ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.

--
nosy: +xtreak
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



[issue35343] Importlib.reload has different behaviour in script and interactive mode

2018-11-29 Thread Brett Cannon


Brett Cannon  added the comment:

It will because your file change happens so quickly by script that your file 
system isn't leading to a different mtime on the source, and so the bytecode 
isn't being regenerated. When you do it by hand you're physically slow enough 
to have the file copies take long enough for your file system to record the new 
mtime.

You can try using importlib.invalidate_caches() to help with this. Otherwise 
realize that importlib.reload() is really meant for interactive use and not 
script use anyway because it doesn't update old references to the module.

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

___
Python tracker 

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



[issue35354] Generator functions stack overflow

2018-11-29 Thread -

New submission from - :

Gоt `Fatal Python error: Cannot recover from stack overflow.` on Windows 10, 
not tested on other os. Crashed when use undefined variable.

--
components: Interpreter Core
files: crash.py
messages: 330710
nosy: SUHAR1K
priority: normal
severity: normal
status: open
title: Generator functions stack overflow
type: crash
versions: Python 3.7
Added file: https://bugs.python.org/file47958/crash.py

___
Python tracker 

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



[issue35338] set union/intersection/difference could accept zero arguments

2018-11-29 Thread Mark Dickinson


Mark Dickinson  added the comment:

> The intersection of an empty set of sets is either the empty set [...]

Nope, it's never the empty set, unless you're using a *very* unusual definition.

The intersection of a collection X of sets is the set of all x in the universe 
such that x is in S for all S in X. If X is empty, that condition is vacuously 
true, and you simply get the set of all x.

There are universe problems here, but giving the empty set is definitely wrong.

OTOH, the union of an empty collection of sets _is_ unambiguously the empty 
set, and the request for `set.union(*args)` to be valid regardless of the 
length of args seems reasonable to me. Without that validity, there's a 
potential corner-case bug where `set.union(*args)` potentially fails when 
`args` is empty.

--

___
Python tracker 

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



[issue35338] set union/intersection/difference could accept zero arguments

2018-11-29 Thread Mark Dickinson


Mark Dickinson  added the comment:

Some reading: http://mathforum.org/library/drmath/view/62503.html

--

___
Python tracker 

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



[issue35190] collections.abc.Sequence cannot be used to test whether a class provides a particular interface (doc issue)

2018-11-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

This looks like a duplicate of issue23864 and issue25737.

--

___
Python tracker 

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



[issue35349] collections.abc.Sequence isn't an abstract base class for array.array

2018-11-29 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

See issue23864, issue25737 and issue35190.

--
nosy: +serhiy.storchaka
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> array is not a Sequence

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +10048

___
Python tracker 

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



[issue34605] Avoid master/slave terminology

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +10047

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +10046

___
Python tracker 

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



[issue34279] RFC: issue a warning in regrtest when no tests have been executed?

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 9724348b43a9005a449ba532ccd3c6726f031097 by Victor Stinner (Pablo 
Galindo) in branch 'master':
bpo-34279, regrtest: Issue a warning if no tests have been executed (GH-10150)
https://github.com/python/cpython/commit/9724348b43a9005a449ba532ccd3c6726f031097


--

___
Python tracker 

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



[issue35335] msgfmt should be able to merge more than one po file

2018-11-29 Thread SilentGhost


SilentGhost  added the comment:

The test for this part of code are located in Lib/test/test_tools/test_i18n.py 
as you'll quickly notice there aren't any tests specific to msgfmt.py I would 
actually advice to start by writing some tests for existing behaviour, so you'd 
know if (when) you break things.

--

___
Python tracker 

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



[issue35353] Add frame command to pub

2018-11-29 Thread Christian Klein


New submission from Christian Klein :

Add command fr(ame) to jump to a stack frame in the Python debugger

--
components: Library (Lib)
messages: 330703
nosy: cnklein
priority: normal
pull_requests: 10045
severity: normal
status: open
title: Add frame command to pub

___
Python tracker 

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



[issue35349] collections.abc.Sequence isn't an abstract base class for array.array

2018-11-29 Thread Leonard de Ruijter


Leonard de Ruijter  added the comment:

This might be a duplicate of https://bugs.python.org/issue35190

--

___
Python tracker 

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



[issue22543] -W option cannot use non-standard categories

2018-11-29 Thread kernc


Change by kernc :


--
nosy: +kernc

___
Python tracker 

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



[issue35335] msgfmt should be able to merge more than one po file

2018-11-29 Thread s-ball


s-ball  added the comment:

Ok, I have created a fork, and started coding on a local branch. But it will 
take some time, because I assume that I am supposed to write tests for the 
msgfmt module...

--

___
Python tracker 

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



[issue22543] -W option cannot use non-standard categories

2018-11-29 Thread Gerrit Holl


Gerrit Holl  added the comment:

There is a thread on StackOverflow related to this problem:

https://stackoverflow.com/q/42495641/974555

The (currently only and accepted) answer proposes as a workaround to set the 
PYTHONPATH variable, as the contents of those apparently *are* already in 
sys.path at the time warnings._processoptions is called, unlike site-packages.  
So manually adding site-packages to the PYTHONPATH variable does circumvent 
this problem (tested in Python 3.7.1).

--
nosy: +Gerrit.Holl
versions: +Python 3.6, Python 3.7

___
Python tracker 

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



[issue35352] test_asyncio fails on RHEL8

2018-11-29 Thread Charalampos Stratakis


Change by Charalampos Stratakis :


Added file: https://bugs.python.org/file47957/asyncio_failures_3.6.log

___
Python tracker 

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



[issue35352] test_asyncio fails on RHEL8

2018-11-29 Thread Charalampos Stratakis


Charalampos Stratakis  added the comment:

Seems that 3.8 and 3.7 get the same failures, while 3.6 gets 14 instead of 8.

--

___
Python tracker 

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



[issue35352] test_asyncio fails on RHEL8

2018-11-29 Thread Charalampos Stratakis


New submission from Charalampos Stratakis :

When compiling python3 on RHEL8 and run the tests, test_asyncio fails with 8 
failures (and more on older branches).

openssl version is 1.1.1

Attaching the failures for the various branches.

--
components: Tests, asyncio
files: asyncio_failures_3.8.log
messages: 330698
nosy: asvetlov, cstratak, yselivanov
priority: normal
severity: normal
status: open
title: test_asyncio fails on RHEL8
versions: Python 3.6, Python 3.7, Python 3.8
Added file: https://bugs.python.org/file47955/asyncio_failures_3.8.log

___
Python tracker 

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



[issue35352] test_asyncio fails on RHEL8

2018-11-29 Thread Charalampos Stratakis


Change by Charalampos Stratakis :


Added file: https://bugs.python.org/file47956/asyncio_failures_3.7.log

___
Python tracker 

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



[issue35351] LTOFLAGS are passed to BASECFLAGS when using LTO

2018-11-29 Thread Charalampos Stratakis


Change by Charalampos Stratakis :


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

___
Python tracker 

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



[issue35351] LTOFLAGS are passed to BASECFLAGS when using LTO

2018-11-29 Thread Charalampos Stratakis


New submission from Charalampos Stratakis :

Through configure.ac and this change [0] LTOFLAGS and more specifically -flto 
is baked into BASECFLAGS when using link time optimizations, which will make 
this flag propagate to distutils.

[0] 
https://github.com/python/cpython/commit/69a3f153a92fd8c86080e8da477ee50df18fc0d1#diff-67e997bcfdac55191033d57a16d1408aL1350

--
components: Build, Extension Modules
messages: 330697
nosy: cstratak
priority: normal
severity: normal
status: open
title: LTOFLAGS are passed to BASECFLAGS when using LTO
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



[issue35350] importing "ctypes" immediately causes a segmentation fault

2018-11-29 Thread David


New submission from David :

~Environment

Cross compiled Python 2.7.15 for ARM Cortex-A7 target, Linux Kernel 4.18

uname -a: Linux Test-0002 4.18.13 #1 SMP Wed Oct 31 11:20:07 CET 2018 armv7l 
GNU/Linux

~Description of the problem

Importing the "ctypes" module in order to load shared libraries causes a 
segmentation fault:

root [ /tmpfs/root ] $ python
Python 2.7.15 (default, Nov 29 2018, 13:57:56)
[GCC 8.2.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import ctypes
Segmentation fault

I have found a similiar issue here:
https://bugs.python.org/issue11048
But the changes are already applied in 2.7.15.

Here is the GDB output similiar to the link I posted:

(gdb) file python2.7
Reading symbols from python2.7...done.
(gdb) run -c "import ctypes"
Starting program: /usr/bin/python2.7 -c "import ctypes"
warning: Unable to find libthread_db matching inferior's thread library, thread 
debugging will not be available.

Program received signal SIGSEGV, Segmentation fault.
0x76a4fa94 in CThunkObject_dealloc (_self=0x76adb920) at 
/home/user/ARM_Linux/src/Python-2.7.15/Modules/_ctypes/callbacks.c:25
25  /home/user/ARM_Linux/src/Python-2.7.15/Modules/_ctypes/callbacks.c: No 
such file or directory.
(gdb)

>From what I can see it tries to use the path from the host I cross compiled 
>for the callbacks.c. Is this the cause of the segmentation fault? If yes, how 
>can I correct the path during compilation?

I also attached the strace log of the command 'python -c "import ctypes"'

Thank you in advance!

--
components: ctypes
files: strace_python.log
messages: 330696
nosy: n0s69z
priority: normal
severity: normal
status: open
title: importing "ctypes" immediately causes a segmentation fault
type: crash
versions: Python 2.7
Added file: https://bugs.python.org/file47954/strace_python.log

___
Python tracker 

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



[issue35349] collections.abc.Sequence isn't an abstract base class for array.array

2018-11-29 Thread Leonard de Ruijter


New submission from Leonard de Ruijter :

array.array seems to have all the abstract methods of a 
collections.abc.Sequence and all the classes it inherits from, still the 
following returns False:
`isinstance(array.array("u"), collections.abc.Sequence)`

--
messages: 330695
nosy: Leonard de Ruijter
priority: normal
severity: normal
status: open
title: collections.abc.Sequence isn't an abstract base class for array.array
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



[issue33944] Deprecate and remove pth files

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



[issue35131] Cannot access to customized paths within .pth file

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



[issue31625] stop using ranlib

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

clang LTO fix: bpo-28015

--

___
Python tracker 

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



[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 77000bbb104021b89368b9f7cab6f1417794e348 by Victor Stinner in 
branch '3.6':
bpo-33012: Fix more invalid function cast warnings with gcc 8. (GH-10751) 
(GH-10796)
https://github.com/python/cpython/commit/77000bbb104021b89368b9f7cab6f1417794e348


--

___
Python tracker 

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



[issue31625] stop using ranlib

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

Maybe it would be possible to keep ranlib in Python 3.6, but it seems safe to 
remove it. The master doesn't use ranlib and the compilation is fine in our 
large fleet of buildbot workers.

I chose to backport the change to be able to backport the clang LTO fix.

--
resolution:  -> fixed
status: open -> closed
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



[issue31625] stop using ranlib

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset e1b210342fa08685bf9b24eb449a2f079f1b50f5 by Victor Stinner 
(stratakis) in branch '3.6':
[3.6] bpo-31625: Stop using ranlib (GH-10417)
https://github.com/python/cpython/commit/e1b210342fa08685bf9b24eb449a2f079f1b50f5


--

___
Python tracker 

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



[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-11-29 Thread miss-islington


miss-islington  added the comment:


New changeset 1659c08d5d17357597f220c4d297b19e7a59737c by Miss Islington (bot) 
in branch '3.7':
bpo-33012: Fix more invalid function cast warnings with gcc 8. (GH-10751)
https://github.com/python/cpython/commit/1659c08d5d17357597f220c4d297b19e7a59737c


--

___
Python tracker 

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



[issue35348] Problems with handling the file command output in platform.architecture()

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

Why does platform has to analyze sys.executable binary to check if it's 32 or 
64 bits? Can't we use sizeof(void*) for example? Is it something related to FAT 
binary on macOS? (single binary for 32 and 64 bits, or single binary for PPC 
and x86)

--

___
Python tracker 

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



[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-11-29 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +10043

___
Python tracker 

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



[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-11-29 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10042

___
Python tracker 

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



[issue35338] set union/intersection/difference could accept zero arguments

2018-11-29 Thread Rémi Lapeyre

Rémi Lapeyre  added the comment:

The intersection of an empty set of sets is either the empty set or the 
universe sets so if set.union() is defined to support set.union(*sequence), 
wouldn't it be less surprising for set.intersection() to return the empty set 
too?

--
nosy: +remi.lapeyre

___
Python tracker 

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



[issue35338] set union/intersection/difference could accept zero arguments

2018-11-29 Thread Mark Dickinson


Mark Dickinson  added the comment:

What would the intersection of zero sets be? The only reasonable mathematical 
answer is either "not defined", or "the universe" - i.e., the set containing 
everything, but what would "everything" be in a Python context?

I also don't see how a difference of zero sets makes any sense; you need a set 
to start subtracting items from.

So I think this feature request only really applies to union.

--
nosy: +mark.dickinson

___
Python tracker 

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



[issue24412] setUpClass equivalent for addCleanup

2018-11-29 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
pull_requests: +10041

___
Python tracker 

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



[issue35346] Modernize Lib/platform.py code

2018-11-29 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
dependencies: +Problems with handling the file command output in 
platform.architecture()

___
Python tracker 

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



[issue35348] Problems with handling the file command output in platform.architecture()

2018-11-29 Thread Serhiy Storchaka


New submission from Serhiy Storchaka :

The code of _syscmd_file() in the platform module does not match the docstring. 
The "-b" option was removed in 685fffa (issue16112), and this leads to 
inclusion the executable path in the file command output. If the executable 
path contains some key strings like "32-bit" or "PE", platform.architecture() 
can return an incorrect result. I think that the "-b" option should be restored.

$ python3 -c 'import platform; 
print(platform.architecture("/usr/bin/python3.6"))'
('64bit', 'ELF')
$ cp /usr/bin/python3.6 /tmp/32-bitPE
$ python3 -c 'import platform; print(platform.architecture("/tmp/32-bitPE"))'
('32bit', 'ELF')

Other problem is that the code tests if the string "executable" is contained in 
the file command output. But it is not always contained for executables on 
Linux.

$ file python
python: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically 
linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 3.2.0, 
BuildID[sha1]=d3cfa06c2bdcbf7b6af9e4e6be5061cb8398c086, with debug_info, not 
stripped
$ file /usr/bin/python2.7
/usr/bin/python2.7: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), 
dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 
3.2.0, BuildID[sha1]=fd3904306c73383fb371287416257b82d6a3363b, stripped
$ file /usr/bin/python3.6
/usr/bin/python3.6: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), 
dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 
3.2.0, BuildID[sha1]=9dae0eec9b3f9cb82612d20dc0c3088feab9e356, stripped

--
components: Library (Lib)
messages: 330686
nosy: lemburg, serhiy.storchaka, vstinner
priority: normal
severity: normal
status: open
title: Problems with handling the file command output in platform.architecture()
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



[issue27903] Avoid ResourceWarnings from platform._dist_try_harder

2018-11-29 Thread STINNER Victor


STINNER Victor  added the comment:

No problem, thanks for "cc-ing" me ;-)

--

___
Python tracker 

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



[issue27903] Avoid ResourceWarnings from platform._dist_try_harder

2018-11-29 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

Ah sorry I forgot the previous versions that had this code. Thanks for the 
catch and PR victor :)

--

___
Python tracker 

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



  1   2   >