[issue35207] Disallow expressions like (a) = 42

2018-11-11 Thread Mark Dickinson


Change by Mark Dickinson :


--
nosy: +mark.dickinson

___
Python tracker 

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



[issue35149] pip3 show causing Error for ConfigParaser

2018-11-11 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

Sorry I overlooked the part where it says this works with command line but 
throws an error on batch script.

--

___
Python tracker 

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



[issue35200] Range repr could be better

2018-11-11 Thread Nick Coghlan


Nick Coghlan  added the comment:

I agree with Steven and Raymond on this one: changing __repr__ on ranges in a 
way that breaks round-tripping through eval would be problematic, especially as 
I'd expect that to be an issue in doctests as well.

However, I also like the idea of having easier access to a more list-like 
representation that shows the actual range endpoints, not just the inputs used 
to calculate them, and like Steven, I'm more comfortable with changing __str__ 
than I am with changing __repr__.

That would give:

>>> range(10)
range(0, 10)
>>> print(range(10))


--
nosy: +ncoghlan

___
Python tracker 

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



[issue21622] ctypes.util incorrectly fails for libraries without DT_SONAME

2018-11-11 Thread Javier Castillo II


Change by Javier Castillo II :


--
pull_requests: +9734

___
Python tracker 

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



[issue21622] ctypes.util incorrectly fails for libraries without DT_SONAME

2018-11-11 Thread Javier Castillo II


Change by Javier Castillo II :


--
pull_requests: +9735

___
Python tracker 

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



[issue21622] ctypes.util incorrectly fails for libraries without DT_SONAME

2018-11-11 Thread Javier Castillo II


Change by Javier Castillo II :


--
pull_requests: +9736

___
Python tracker 

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



[issue35212] Expressions with format specifiers in f-strings give wrong code position in AST

2018-11-11 Thread Arminius


New submission from Arminius :

ast.parse() will give a wrong code position for an expression inside an 
f-string when the expression is using a format specifier.

Compare the trees of f'{a}' and f'{a:b}' :

>>> ast.parse("f'{a}'")
Module(
body=[
Expr(
lineno=1,
col_offset=0,
value=JoinedStr(
lineno=1,
col_offset=0,
values=[
FormattedValue(
lineno=1,
col_offset=0,
value=Name(lineno=1, col_offset=3, id='a', ctx=Load()),
conversion=-1,
format_spec=None,
),
],
),
),
],
)

>>> ast.parse("f'{a:b}'")
Module(
body=[
Expr(
lineno=1,
col_offset=0,
value=JoinedStr(col_offset=0,
lineno=1,
col_offset=0,
values=[
FormattedValue(
lineno=1,
col_offset=0,
value=Name(lineno=1, col_offset=1, id='a', ctx=Load()),
conversion=-1,
format_spec=JoinedStr(
lineno=1,
col_offset=0,
values=[Str(lineno=1, col_offset=0, s='b')],
),
),
],
),
),
],
)

In both examples, the name "a" is at the same position in the source code, 
however the parsed ASTs yield two different offsets,

Name(lineno=1, col_offset=3, id='a', ctx=Load())

and

Name(lineno=1, col_offset=1, id='a', ctx=Load())

.

Expected behavior: col_offset=3 for name "a" in both f-strings.

(In my specific use case, this breaks a semantic highlighting plugin for vim.)

--
components: Interpreter Core
messages: 329672
nosy: arminius
priority: normal
severity: normal
status: open
title: Expressions with format specifiers in f-strings give wrong code position 
in AST
type: behavior
versions: Python 3.7

___
Python tracker 

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



[issue35212] Expressions with format specifiers in f-strings give wrong code position in AST

2018-11-11 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +eric.smith

___
Python tracker 

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



[issue35212] Expressions with format specifiers in f-strings give wrong code position in AST

2018-11-11 Thread Eric V. Smith


Change by Eric V. Smith :


--
assignee:  -> eric.smith

___
Python tracker 

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



[issue35203] Windows Installer Ignores Launcher Installer Options Where The Python Launcher Is Already Present

2018-11-11 Thread Steve Dower


Steve Dower  added the comment:

Does it actually try to upgrade the launcher? This is a case that was 
deliberately designed and tested before release, though it's possible that 
there's some mix of versions that is new.

The box is checked to indicate that the launcher will be installed at the end 
of setup, but not necessarily that the installer is going to try and install 
the launcher. This is the usual convention for this scenario.

If you're getting install failures, please attach the log file linked at the 
end of the install. We'll need that to diagnose the scenario.

--

___
Python tracker 

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



[issue35140] encoding problem: coding:gbk cause syntaxError

2018-11-11 Thread Steve Dower


Steve Dower  added the comment:

Yes, seems like we should be opening the file in binary mode, though I haven't 
tried it. The CRT's interpretation of text mode really isn't compatible with 
Python's own interpretation of text mode, and chaining them makes even less 
sense.

--

___
Python tracker 

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



[issue34864] In Idle, Mac tabs make editor status line disappear.

2018-11-11 Thread Tal Einat


Change by Tal Einat :


--
pull_requests: +9737

___
Python tracker 

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



[issue34864] In Idle, Mac tabs make editor status line disappear.

2018-11-11 Thread Tal Einat


Tal Einat  added the comment:

See PR GH-10464, which warns if "Prefer tabs when opening documents" is set to 
"Always".

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth


bob moth  added the comment:

looking at the screen snapshot 'life.py alt-q once.jpg' -- the
turtle code keeps running even though System.exit has been completed,
and notice the traceback display in the shell caused by the alt-Q.

a second press of alt-Q terminates the shell and the turtle code.

--
Added file: https://bugs.python.org/file47924/lify.py alt-q once.jpg

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth


bob moth  added the comment:

I rewrote the life2.py using a class in order to eliminate global
variable declarations, and some other things, such as bringing
freegames.util#square() instream to be independent of freegames,
carefully accounting for every pixel output, etc. 

Works a little better but alt-Q has no effect whatsoever and 
it is necessary to Force Quit (mac terminology) or to switch to
the shell window and quit that first. 

Once this bug is fixed, wherever that might be, you might look into
using mylife.py as an turtle example -- with whatever changes you
like -- because it is interesting to use and it exercises the turtle
and tkinter very strenuously. (just leave my name off it...)

Thanks for your hard work.

--
Added file: https://bugs.python.org/file47925/mylife.py

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread miss-islington


Change by miss-islington :


--
pull_requests: +9738

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread miss-islington

miss-islington  added the comment:


New changeset b086c8afdb8c862011e3e27d4c8f6833749f2c56 by Miss Islington (bot) 
(Andrés Delfino) in branch 'master':
bpo-33699: Describe try's else clause with the rest of the try clause (GH-7252)
https://github.com/python/cpython/commit/b086c8afdb8c862011e3e27d4c8f6833749f2c56


--
nosy: +miss-islington

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread miss-islington


Change by miss-islington :


--
pull_requests: +9739

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread Mariatta Wijaya


Mariatta Wijaya  added the comment:

Just need a manual backport to 2.7, which I'm not doing :) 

If no one is motivated enough to backport to 2.7, I'm fine with that. Otherwise 
this issue can be closed.

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread miss-islington


miss-islington  added the comment:


New changeset 7d7ff672dfe93a50053166798cdc0fbc86ea63e3 by Miss Islington (bot) 
in branch '3.7':
bpo-33699: Describe try's else clause with the rest of the try clause (GH-7252)
https://github.com/python/cpython/commit/7d7ff672dfe93a50053166798cdc0fbc86ea63e3


--

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread miss-islington


miss-islington  added the comment:


New changeset 3f6a0a292e12f737448a11660da0c880e8f972be by Miss Islington (bot) 
in branch '3.6':
bpo-33699: Describe try's else clause with the rest of the try clause (GH-7252)
https://github.com/python/cpython/commit/3f6a0a292e12f737448a11660da0c880e8f972be


--

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread Andrés Delfino

Andrés Delfino  added the comment:

I'm doing the 2.7 backport right now :)

--

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread Andrés Delfino

Change by Andrés Delfino :


--
pull_requests: +9740

___
Python tracker 

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



[issue33699] Don't describe try's else clause in a footnote

2018-11-11 Thread miss-islington

miss-islington  added the comment:


New changeset fb8eb2c2776efb34523e0a616c6f845a6b975e38 by Miss Islington (bot) 
(Andrés Delfino) in branch '2.7':
[2.7] bpo-33699: Describe try's else clause with the rest of the try clause 
(GH-7252) (GH-10469)
https://github.com/python/cpython/commit/fb8eb2c2776efb34523e0a616c6f845a6b975e38


--

___
Python tracker 

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



[issue35198] Build issue while compiling cpp files in AIX

2018-11-11 Thread Michael Felt


Michael Felt  added the comment:

Still getting the same errors, even with 64-bit build, so still not close to 
testing the actual problem.
FYI: last time I build pandas the version was 0.19.0 - then it was 'simple'.

Anyway, short of a simple (test) python module that includes c++ code, I'll 
look at changing the pandas build files to force any c++ file to the front.

More - (asap, but still when I have time)

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

There seem to be at least two problems here.

One, you say that running the unmodified life.py requires two Quit keyboard 
shortcuts (usually CMD-Q).  From the shell output you give, that problem is 
most likely due to the use of -i with python:

'/usr/local/bin/python3' -d -i  '/Users/user2/Downloads/life.py'

-i means that the interpreter should enter its interactive mode after the 
script exists.  With tkinter-based graphics apps like turtle, you probably do 
not want to do that as it will inhibit the normal Tk shutdown of the app.

https://docs.python.org/3/using/cmdline.html#cmdoption-i

Without -i, the unmodified life.py terminates fine for me.

Secondly, your modified life2.py does not terminate with a Quit even when 
running without -i.  (Note that it *does* quit if you select Close from the 
applications's File menu or if you click on the red close button on the open 
window.)  From a quick comparison of the unmodified Pygames life.py versus your 
modified life2.py version, it seems you have changed the order of operations in 
such a way that the sequence of turtle operations has changed and likely the 
underlying tkinter event loop is not being called properly thus either ignoring 
or suppressing the effect of the Quit keyboard shortcut.  Suggest you revise 
your program to follow the sequence of turtle calls that the original does and 
be careful if you wish to introduce changes in that.  If you do find what 
appears to be a bug in turtle or elsewhere in Python, feel free to re-open this 
with an example and an explanation.  Good luck!

--
resolution:  -> works for me
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



[issue35140] encoding problem: coding:gbk cause syntaxError

2018-11-11 Thread Emmanuel Arias


Emmanuel Arias  added the comment:

I can not reproduce this issue on my Debian9.

--
nosy: +eamanu

___
Python tracker 

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



[issue35104] IDLE: On macOS, Command-M minimizes & opens "Open Module..."

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

That's a good point. I see that Cmd-Shift-S which is defined as the shortcut 
for "Save As.." seems to have the same effect as Cmd-S "Save".  Also, the 
Cmd-Opt-S shortcut for "Save Copy As.." seems to bring up the save dialog 
window twice, the second after the first closes.  I guess somebody should go 
through and try to see exactly which Tk events IDLE is seeing in these cases 
similar to what Ronald was doing while investigating Issue11055 (referenced in 
Issue21359).

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth

bob moth  added the comment:

hi - i do not use ‘i’...just drag to
launcher...

and sequence of commands is
a good tip but smells like some
kind of bug to me if the commands
follow written rules. 

thanks for looking -

> 
>

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

Alas, the Launcher app can be problematic and doesn't get much love.  If you 
open the Launcher app's Preferences, you'll probably see that the "Interactive 
mode after acript" option is ticked.  Either unselect it or, if you feel 
comfortable using a Terminal window, just launch Python directly from a 
terminal shell:

python3 ~/Downloads/life.py

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth


bob moth  added the comment:

OK, thanks. The generated launcher shell command generated
includes '-d -i' flags...

so I tried running without those and voila, life.py terminates
normally. Yay. :-)

2nd, I reviewed the order of commands and I saw that
life2.py and mylife.py (the +1 version) did not have a
'done()' or 'mainloop()' as the last line of the program.
I added those, to no effect. Does nothing I can see.
The other turtle commands appear to me to be "ok",
given that the algorithm is different. For example,
clear() used to be done every loop -- to erase the
turtle tracks -- but that is now done just at the start
because only changed cells are updated, and 
new life/new dead are just updated. 

So, 50% solved. It is an interesting problem because
*my* code seems to be working and *python* does
not appear to be working right. 

Thanks for the help. I might try pygame for a gui
instead...this is getting weird.

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

You may might try asking on the freegames issue tracker or, better, on a more 
general support forum like Stackoverflow or Python-list. Because of the volume 
of issues reported here (and we are all volunteers), we really can't spend a 
lot of time helping debug individual programs.  Sorry!

https://www.python.org/about/help/
https://stackoverflow.com
https://mail.python.org/mailman/listinfo/python-list

--

___
Python tracker 

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



[issue35204] Disable thread and memory sanitizers for address_in_range()

2018-11-11 Thread miss-islington


Change by miss-islington :


--
pull_requests: +9741

___
Python tracker 

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



[issue35204] Disable thread and memory sanitizers for address_in_range()

2018-11-11 Thread Benjamin Peterson


Benjamin Peterson  added the comment:


New changeset fd3a91cbf93dd7bd97f01add9c90075d63cd7316 by Benjamin Peterson 
(Alexey Izbyshev) in branch 'master':
closes bpo-35204: Disable thread and memory sanitizers for address_in_range(). 
(GH-10442)
https://github.com/python/cpython/commit/fd3a91cbf93dd7bd97f01add9c90075d63cd7316


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



[issue35204] Disable thread and memory sanitizers for address_in_range()

2018-11-11 Thread miss-islington


Change by miss-islington :


--
pull_requests: +9742

___
Python tracker 

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



[issue35081] Move internal headers to Include/internal/

2018-11-11 Thread STINNER Victor

STINNER Victor  added the comment:

> Python/pystate.c:968:1: warning: no previous prototype for ‘_PyGILState_Init’ 
> [-Wmissing-prototypes]
 _PyGILState_Init(PyInterpreterState *i, PyThreadState *t)
 ^~~~

Oh, I never saw this warning before. It seems to not be included in -Wall. 
Would you mind to open a new issue to discuss it?

I will try to fix the regressions that I introduced, but I'm interested by a 
more general discussion on this issue.

--

___
Python tracker 

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



[issue35204] Disable thread and memory sanitizers for address_in_range()

2018-11-11 Thread miss-islington


miss-islington  added the comment:


New changeset 1ec5781a097f4d4d988e0dd7f51ee203dc639df2 by Miss Islington (bot) 
in branch '3.7':
closes bpo-35204: Disable thread and memory sanitizers for address_in_range(). 
(GH-10442)
https://github.com/python/cpython/commit/1ec5781a097f4d4d988e0dd7f51ee203dc639df2


--
nosy: +miss-islington

___
Python tracker 

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



[issue35204] Disable thread and memory sanitizers for address_in_range()

2018-11-11 Thread miss-islington


miss-islington  added the comment:


New changeset eff1c983eb0cc9bc01e8eba07a42522cee57 by Miss Islington (bot) 
in branch '3.6':
closes bpo-35204: Disable thread and memory sanitizers for address_in_range(). 
(GH-10442)
https://github.com/python/cpython/commit/eff1c983eb0cc9bc01e8eba07a42522cee57


--

___
Python tracker 

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



[issue35177] Add missing dependencies between AST/parser header files

2018-11-11 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 5f2df88b63e50d23914e97ec778861a52abdeaad by Victor Stinner in 
branch 'master':
bpo-35177: Add dependencies between header files (GH-10361)
https://github.com/python/cpython/commit/5f2df88b63e50d23914e97ec778861a52abdeaad


--

___
Python tracker 

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



[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-11-11 Thread Julien Palard


Julien Palard  added the comment:


New changeset 082875dcd6d482558e5f1da97a1c801d60b3ed5b by Julien Palard in 
branch 'master':
bpo-33878: Doc: Fix missing case by simplifying. (GH-7762)
https://github.com/python/cpython/commit/082875dcd6d482558e5f1da97a1c801d60b3ed5b


--

___
Python tracker 

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



[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-11-11 Thread miss-islington


Change by miss-islington :


--
pull_requests: +9744

___
Python tracker 

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



[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-11-11 Thread miss-islington


Change by miss-islington :


--
pull_requests: +9743

___
Python tracker 

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



[issue34160] ElementTree not preserving attribute order

2018-11-11 Thread STINNER Victor


STINNER Victor  added the comment:

I like the idea of having an opt-in option to get Python 3.7 behavior in Python 
3.8, sort=True. It would be a new parameter in Python 3.8, right?

It makes sense to me to ask explicitly to sort attributes, especially since 
Python decided to no longer sort by default :-)

Maybe some people prefer sorting to get a more deterministic output for things 
like https://reproducible-builds.org/

--

___
Python tracker 

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



[issue35177] Add missing dependencies between AST/parser header files

2018-11-11 Thread STINNER Victor


STINNER Victor  added the comment:

This change doesn't try to fix "all dependencies issues", but it fix a few of 
them :-) See bpo-35197 for another example of funny header issue.

Please open a new issues if you see other header dependencies issues. I close 
this one since the initial bug has been fixed.

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



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

2018-11-11 Thread STINNER Victor


Change by STINNER Victor :


--
title: collections.abc.Sequence cannot be used to test whether a class provides 
a particular interface -> collections.abc.Sequence cannot be used to test 
whether a class provides a particular interface (doc issue)

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth


bob moth  added the comment:

Thanks. I appreciate the time and effort. 

But I disagree with the characterization of
this problem as 'Resolved'. Turtle is
supposed to be simple enough for children yet 
no one can fix simple turtle code and stop
an endless loop? 

What is the rush to close issues?

--

___
Python tracker 

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



[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-11-11 Thread Julien Palard


Julien Palard  added the comment:


New changeset aa493b5c18463ab45c087564e287643606f004ca by Julien Palard (Miss 
Islington (bot)) in branch '3.7':
bpo-33878: Doc: Fix missing case by simplifying. (GH-7762)
https://github.com/python/cpython/commit/aa493b5c18463ab45c087564e287643606f004ca


--

___
Python tracker 

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



[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-11-11 Thread Julien Palard


Julien Palard  added the comment:


New changeset d0ebbf4895439233c8398dbdd0456d07132b2a6f by Julien Palard (Miss 
Islington (bot)) in branch '3.6':
bpo-33878: Doc: Fix missing case by simplifying. (GH-7762)
https://github.com/python/cpython/commit/d0ebbf4895439233c8398dbdd0456d07132b2a6f


--

___
Python tracker 

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



[issue35201] Recursive '**' matches non-existent directories.

2018-11-11 Thread Daniel Israel


Daniel Israel  added the comment:

In the Bash example, you created the directory empty/.  This bug is 
specifically when the directory in question does not exist.

--

___
Python tracker 

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



[issue35200] Range repr could be better

2018-11-11 Thread Julien Palard


Julien Palard  added the comment:

I understand we like round-tripping represnetations, I think we like them 
because in much cases it's immediatly and unambiguously understandable by a 
Python developer.

It's the best representation as it's the one conveying the most information. 
But `range(0, 10)` convery very few information, one may forget the "begin 
included, end excluded" rule (or even if the 2nd one is the end of the length). 
I think the following is more usefull:

>>> range(10)

>>> range(10, 2)

>>> range(2, 10)

>>> range(2, 10, 2)

>>> 



@steven:

I dont think moving this to __str__ would help someone: I've never seen any 
student try `str(range(10))` in the repl, they all naturally try the bare 
`range(10)` and they're all presented with un-informative information. If 
someone is here to teach them to try with str, better try with list(range(10)) 
or *range(10).

As for repr(range(0)) == repr(range(2, 2)) == repr(range(1, 5, -1)) I do not 
consider this a bug, they are all strictly equivalent as being the empty range 
(when speaking of a mathematical object, maybe not the in-memory struct).


@raymond:

I'm also not OK to teach `*repr(10)` during the first class. I personally go 
for `list(range(10))`, but I can only because I'm physically available when 
they ask why the information displayed is not what they expect. A lot of people 
are learning Python at home and they're probably just lost while being 
presented with the round-tripping representation.


I don't really agree that changing the repr could break code doing 
`eval(repr(range(10)))`, is it really something people do?


@nick:

I agree changing the repr could break some doctests on function returning 
ranges, on the other hand I've never seen a function returning a range.

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

Sorry, there isn't a particular rush to close issues as some of them stay open 
for years. And that's not good for anyone.  "resolved" on the issue tracking 
does not necessarily mean a problem is resolved to everyone's satisfaction, it 
just means that it is no longer active in our backlog (which currently numbers 
over 6000).  I don't claim to be a turtle expert but the bit of time I spent 
looking into this issue and my years of triaging Python issues lead me to 
conclude this is almost certainly a problem with your program and not with 
Python itself.  We could leave it open but the chances that any other core 
developer would spend time looking further at it are slim.  That's why I 
suggested asking on user forums where you are much more likely to get useful 
and more rapid feedback.  And as I earlier suggested, if it *does* turn out to 
be a demonstrable problem with turtle or elsewhere in Python, you can easily 
reopen the issue and we can go from there. I hope that makes some sense!

--

___
Python tracker 

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



[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-11-11 Thread Julien Palard


Change by Julien Palard :


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

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

And, by the way, if it turns out that the problem could have been avoided by 
better documentation, another option is to re-open the issue with suggested doc 
changes.  Patches welcome!

--

___
Python tracker 

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



[issue35200] Range repr could be better

2018-11-11 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

> I've never seen any student try `str(range(10))` in the repl

I never suggested that students would try calling str() directly. That 
would be silly. They would use print(), as I'm sure many of them are 
already doing.

After 20+ years of using Python, I still sometimes use print in the 
interactive interpreter when I don't need to.

> they all naturally try the bare `range(10)` and they're all presented 
> with un-informative information.

It isn't un-informative information. Its very informative, and useful, 
but perhaps not the information you are trying to teach your students 
*at that moment*. But they will have potentially decades of use of 
Python, long after they have learned that range() is half-open, and the 
long  form is no 
longer necessary, and perhaps even an annoyance.

(It certainly annoys *me*. The existing short form is usually better for 
my needs, and I think I'm more representative of the average Python 
coder over their career than beginners during their first few weeks.)

> As for repr(range(0)) == repr(range(2, 2)) == repr(range(1, 5, -1)) I 
> do not consider this a bug

I didn't say it was a bug. But it reduces the utility of the display, as 
you cannot tell the difference between any two empty range objects. And 
that can be important when trying to work out why your range object is 
unexpectedly empty.

> I don't really agree that changing the repr could break code doing 
> `eval(repr(range(10)))`, 

That's not something up for debate. Whether you "really agree" or not, 
it is a fact that your proposed repr is not legal Python code and 
therefore it will break code doing eval() on it.

> is it really something people do?

It is a backwards-incompatible change of behaviour, therefore we must 
assume it will break someone's code and treat it as a major change. 
That's not to say that we can't change the repr, but we don't do it 
lightly.

Personally, making a change for the sake of beginners during their first 
few weeks of learning the language, but inconveniences them for the 
remaining 95% of their career as a Python coder, does not sound like a 
good trade-off to me.

That's why I suggest that print(range_obj) is a good compromise. 
Lots of beginners already do this, and for those who don't, print is a 
good diagnostic tool which they should be taught early.

And yes, changing the __str__ is a backwards-incompatible change too, 
but the potential negative consequences are smaller and the work-arounds 
are easier.

--

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth


bob moth  added the comment:

Apparently the draw() function must call itself via ontimer.

That is not in the docs. But 56 variations later...I just copied
Grant Jenks. Apparently he knows what's what.

And done() must be the last line.

If first omitted, only one draw loop executed, but it quits itself.
With done(), it loops via ontimer().


def draw():
myDrawCells()
update()
myComputeOneStep()
ontimer(draw, LOOP_TIMER)
setup(BOARD_SIDE, BOARD_SIDE, None, None)
hideturtle()
tracer(False)
clear()
myInitialize()
draw()
done()


So now alt-Q works in life2DEBUG.py. attached.

--
Added file: https://bugs.python.org/file47926/life2DEBUG.py

___
Python tracker 

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



[issue35211] Turtle Shutdown Problem(s)

2018-11-11 Thread bob moth


bob moth  added the comment:

Here is a debugged version of mylife, which cloned life2.py to
use a class for turtle-ing. Note the difficulties at the
end of the code -- ontimer(fun, delay) calls for a zero arg
function, so draw() cannot be inside the class. Greatly annoying.
But now we know.

mylife3.py is a suitable example, I think. If cleaned up to
standards. I noticed there is a curses life.py example, which
is very interesting and fun, but mylife3.py is more fun...and
it has 2 different board topologies! And
it would make a very good test program. Note that it sets
the random seed which establishes the Cell patterns, so a
test ought to be repeatable, at least on a given machine.
I plan to use mylife3.py instead of a space heater this winter :)

--
Added file: https://bugs.python.org/file47927/mylife3.py

___
Python tracker 

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



[issue34864] In Idle, Mac tabs make editor status line disappear.

2018-11-11 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

I will leave macosx alone at least until after 3.6.8.  But I plan to merge some 
modules and want to be able to rename others.  #33906 changed windows.py to 
window.py for 3.7.1 (and 3.6.7).  The 3.7.1 Windows installer deleted 
windows.py; the macOS installer did not.  Tal, do you have a Linux 3.7.1 
upgrade of 3.7.0?  What is the downside of the old, dead version?

I could, for the maintenance version, add back a file containing
"# renamed xyz.py" or "# merged into abc.py".  An possible example of the 
latter is merging autocomplete_w.py into autocomplete.py.  (I strongly suspect 
that the split was for a Java-esque one-class per module rule.)  Can modules be 
made system specific without great hassle?

--

___
Python tracker 

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



[issue35209] Crash with tkinter text on osx

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

Good to hear you have worked around the crash.  Regarding keyboard 
accelerators, I'm not aware of any 3.7.1 regressions but there could be issues 
with the bundled version of Tk 8.6.8.  If you want to pursue the issue, please 
supply a test case that demonstrates the misbehavior and reopen this issue.

--
resolution:  -> third party
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



[issue34864] In Idle, Mac tabs make editor status line disappear.

2018-11-11 Thread Ned Deily


Ned Deily  added the comment:

By default, macOS installers just install the files included in a package.  For 
macOS Python installer packages, the problem arises if a particular file is 
deleted or renamed in a maintenance release and a user has already installed an 
earlier version of that release family.  It's possible for a post-install 
script to be added to the macOS installer to deal with particular files but 
that doesn't happen automatically.  On Linux and other OSes, it would depend 
how the third-party distributor's packaging system works; some would detect a 
changed or missing file name, some likely wouldn't.  And there's always the 
possibility that third-party packages or users are using or modifying standard 
library files.  It's just best to avoid the problem altogether unless there is 
some really compelling reason.  Of course renames or deletes for the initial 
release of a feature branch (e.g. 3.8.0) generally aren't a problem.

--

___
Python tracker 

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



[issue35213] IDLE: use 'macOS' where appropriate.

2018-11-11 Thread Terry J. Reedy


New submission from Terry J. Reedy :

'maxOS' is Apple's current name for the Mac operating system.  See 
https://en.wikipedia.org/wiki/MacOS, Contents, Release History.

The module name macosx.py is currently left as is.  Within that, 'Mac OS X' is 
correct for 10.6 for 10.8.

--
assignee: terry.reedy
components: IDLE
messages: 329713
nosy: terry.reedy
priority: normal
severity: normal
stage: needs patch
status: open
title: IDLE: use 'macOS' where appropriate.
type: enhancement
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



[issue34864] In Idle, Mac tabs make editor status line disappear.

2018-11-11 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

See #35213 for 'macOS' changes.

--

___
Python tracker 

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



[issue35213] IDLE: use 'macOS' where appropriate.

2018-11-11 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

This issue is a spinoff of #34864.

--
nosy: +ned.deily

___
Python tracker 

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



[issue35213] IDLE: use 'macOS' where appropriate.

2018-11-11 Thread Terry J. Reedy


Change by Terry J. Reedy :


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

___
Python tracker 

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



[issue20198] xml.etree.ElementTree.ElementTree.write attribute sorting

2018-11-11 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

dictionary's insertion order is preserved in 3.6 and above. Hence sorting by 
lexical order was removed in issue34160 and there is a discussion in the same 
issue to add an option to provide sorted output.

As part of triaging I propose closing this issue since the changes were made in 
issue34160.

$ ./python.exe
Python 3.8.0a0 (heads/master:cd449806fa, Nov 12 2018, 09:51:24)
[Clang 7.0.2 (clang-700.1.81)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from xml.etree.ElementTree import Element, tostring
>>> from collections import OrderedDict
>>> e = Element("tag", OrderedDict([("a", "a"), ("c", "c"), ("b", "b")]))
>>> tostring(e)
b''
>>> e = Element("tag", dict([("a", "a"), ("c", "c"), ("b", "b")]))
>>> tostring(e)
b''

--
nosy: +xtreak

___
Python tracker 

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



[issue34864] In Idle, Mac tabs make editor status line disappear.

2018-11-11 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

Changing only master could make backports difficult to impractical.  (Pure 
module name changes would be an exception if gits keep track of them and 
reverses them for a backport.)

If a module is touched, user changes to that module get wiped out when the 
module is replaced.  Aside from that, most of idlelib was declared private and 
'subject to change' to allow refactoring.  The only problem I have heard about 
is that 3.6 broke IDLEX (as I expected).  IDLEX which made changes far beyond 
the narrow extension protocol.  Roger solved that by incorporating a private 
copy of 3.5 IDLE with whatever modifications he wants.  This is exactly what 
Nick said people should do, in the 3.6 alpha discussion, if they wanted frozen 
IDLE.

--

___
Python tracker 

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



[issue35196] IDLE text squeezer is too aggressive and is slow

2018-11-11 Thread Tal Einat


Tal Einat  added the comment:

> By the way, I really appreciate the work you all are putting into IDLE.  It 
> can definitely benefit from some love and attention.

Thanks for the kind words, Raymond!

--

___
Python tracker 

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



[issue35151] Python 2 xml.etree.ElementTree documentation tutorial uses undocumented arguments

2018-11-11 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +xtreak

___
Python tracker 

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



[issue33196] SEGV in mp.synchronize.Lock.__repr__ in spawn'ed proc if ctx mismatched

2018-11-11 Thread Tal Einat


Tal Einat  added the comment:

On Win10 I've also failed to reproduce the reported issue with the supplied 
script.  I tried with Python versions 3.6.3, 3.7.0, and a recent build of the 
master branch (to be 3.8).

Can someone try to reproduce this on Fedora?

--

___
Python tracker 

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



[issue21603] IDLE: Document SaveAs extension display on Mac

2018-11-11 Thread Tal Einat


Tal Einat  added the comment:

+1 for closing this either way, preferably with a note in the docs.

I'd add the notes about extensions in one set of parenthesis at the end, but 
that's likely just a matter of taste.

--

___
Python tracker 

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



[issue31541] Mock called_with does not ensure self/cls argument is used

2018-11-11 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

mock can only verify if the function is called with the correct number of 
arguments as you have passed spec. It doesn't verify whether the function 
implementation is correct like calling Something.foobar() because it's not 
designed to verify the function implementation. It wouldn't raise an exception 
even when self.foo(1, 2) is called inside x.bar because runtime code is not 
executed and only the signature is checked with mock. I think this is an 
expected behavior and not a bug.

--

___
Python tracker 

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



[issue35198] Build issue while compiling cpp files in AIX

2018-11-11 Thread Ayappan


Ayappan  added the comment:

The PR 10437 worked !!!. 
Now i am able to compile pandas-0.23.4


Michael Felt,

About the re-declaration issues you are facing, that is because of the "#define 
_LARGE_FILES 1" in pyconfig-ppc64.h file.
For 64bit build we actually don't need it.
For 32bit build, we need it and also we have to pass the flag "-D_LARGE_FILES" 
through the _sysconfigdata_m_aix6_.py , otherwise one will get this 
re-declaration error.

--

___
Python tracker 

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



[issue35214] Get the test suite passing with clang Memory Sanitizer enabled

2018-11-11 Thread Gregory P. Smith


New submission from Gregory P. Smith :

clang's memory sanitizer (-fsanitize=memory) turns up useful problems in code.  
I'm working on getting a CPython buildbot running it setup but would like our 
build to be cleaner to start with before I run that.

These are the initial fixes required for most of CPython to pass in an msan 
build.  We've been using these with our interpreters at Google.  (PR coming)

--
assignee: gregory.p.smith
components: Build, Extension Modules, Interpreter Core, Tests
messages: 329723
nosy: gregory.p.smith, twouters
priority: normal
severity: normal
stage: patch review
status: open
title: Get the test suite passing with clang Memory Sanitizer enabled
type: security
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



[issue35214] Get the test suite passing with clang Memory Sanitizer enabled

2018-11-11 Thread Gregory P. Smith


Change by Gregory P. Smith :


--
keywords: +patch
pull_requests: +9746

___
Python tracker 

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