[issue36684] codecov.io code coverage has not updated since 2019-04-13

2019-05-05 Thread Inada Naoki


Inada Naoki  added the comment:

FYI, https://github.com/python/cpython/pull/7773#issuecomment-398262396

--
nosy: +inada.naoki

___
Python tracker 

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



[issue36799] Typo in ctypes documentation

2019-05-05 Thread sehnsucht13


sehnsucht13  added the comment:

I have made a PR for this. The only delay is that my CLA needs to be approved.

--
nosy: +sehnsucht13

___
Python tracker 

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



[issue36799] Typo in ctypes documentation

2019-05-05 Thread sehnsucht13


Change by sehnsucht13 :


--
keywords: +patch
pull_requests: +13016
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



[issue36809] Crash for test test_importlib

2019-05-05 Thread Furzoom


Furzoom  added the comment:

Thread 1 (Thread 0x2b2679113e00 (LWP 22373)):
#0  0x2b2679c56c37 in __GI_raise (sig=sig@entry=6) at 
../nptl/sysdeps/unix/sysv/linux/raise.c:56
#1  0x2b2679c5a028 in __GI_abort () at abort.c:89
#2  0x004571ef in fatal_error (prefix=prefix@entry=0x5d4190 
<__func__.13297> "_PySys_BeginInit", msg=msg@entry=0x5d3d4f "can't initialize 
sys module", status=status@entry=-1)
at Python/pylifecycle.c:2179
#3  0x0045747c in _Py_FatalInitError (err=...) at 
Python/pylifecycle.c:2198
#4  0x0056c372 in pymain_init (pymain=pymain@entry=0x7fffb85610a0) at 
Modules/main.c:3001
#5  0x0056cc79 in pymain_main (pymain=pymain@entry=0x7fffb85610a0) at 
Modules/main.c:3033
#6  0x0056d38c in _Py_UnixMain (argc=, argv=) at Modules/main.c:3073
#7  0x2b2679c41f45 in __libc_start_main (main=0x4a2790 , argc=6, 
argv=0x7fffb85611e8, init=, fini=, 
rtld_fini=, stack_end=0x7fffb85611d8)
at libc-start.c:287
#8  0x0056a0b6 in _start ()

--

___
Python tracker 

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



[issue36809] Crash for test test_importlib

2019-05-05 Thread Furzoom


New submission from Furzoom :

0:06:04 load avg: 0.73 [185/416] test_importlib
Fatal Python error: Segmentation fault

Current thread 0x2b774411ee40 (most recent call first):
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/support/__init__.py", line 
1543 in gc_collect
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/test_importlib/test_locks.py", 
line 132 in test_all_locks
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/case.py", line 615 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/case.py", line 663 in 
__call__
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 122 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 84 in 
__call__
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 122 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 84 in 
__call__
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 122 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 84 in 
__call__
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 122 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 84 in 
__call__
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 122 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/unittest/suite.py", line 84 in 
__call__
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/support/testresult.py", line 
162 in run
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/support/__init__.py", line 
1899 in _run_suite
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/support/__init__.py", line 
1995 in run_unittest
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/runtest.py", line 
178 in test_runner
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/runtest.py", line 
182 in runtest_inner
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/runtest.py", line 
137 in runtest
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/main.py", line 408 
in run_tests_sequential
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/main.py", line 515 
in run_tests
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/main.py", line 619 
in _main
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/main.py", line 586 
in main
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/libregrtest/main.py", line 640 
in main
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/regrtest.py", line 46 in _main
  File "/home/mn/Downloads/Python-3.7.3/Lib/test/regrtest.py", line 50 in 

  File "/home/mn/Downloads/Python-3.7.3/Lib/runpy.py", line 85 in _run_code
  File "/home/mn/Downloads/Python-3.7.3/Lib/runpy.py", line 193 in 
_run_module_as_main

--
components: Tests
files: import_test.log
messages: 341481
nosy: furzoom
priority: normal
severity: normal
status: open
title: Crash for test test_importlib
type: crash
versions: Python 3.7
Added file: https://bugs.python.org/file48301/import_test.log

___
Python tracker 

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



[issue36789] Unicode HOWTO incorrectly states that UTF-8 contains no zero bytes

2019-05-05 Thread Ezio Melotti


Change by Ezio Melotti :


--
nosy: +ezio.melotti
type:  -> enhancement

___
Python tracker 

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



[issue36807] IDLE doesn't call os.fsync()

2019-05-05 Thread Guido van Rossum


Guido van Rossum  added the comment:

If/when you accept this we should also backport it as far as we can.

--

___
Python tracker 

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



[issue36808] Understanding "cannot import name" exception

2019-05-05 Thread Eryk Sun


Eryk Sun  added the comment:

The issue tracker is not the right forum for questions about Python development 
or CPython internals. You can ask for help on the python-list mailing list.

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



[issue36808] Understanding "cannot import name" exception

2019-05-05 Thread Arthur Goldberg


New submission from Arthur Goldberg :

I'm attempting to better understand an
ImportError: cannot import name ''
error by reading the cpython source. But I cannot find this error in the 
source. The closest I find is in cpython/Python/ceval.c, lines 5060 & 5068, but 
they both say:
cannot import name %R from %R (*)
and my message doesn't include the 'from ...'.

I'm using:
Python 3.6.5 (default, Sep 14 2018, 14:56:31) 
[GCC 7.3.0] on linux

Thanks, Arthur

--
components: Interpreter Core
messages: 341478
nosy: ArthurGoldberg
priority: normal
severity: normal
status: open
title: Understanding "cannot import name" exception
type: behavior
versions: Python 3.6

___
Python tracker 

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



[issue36789] Unicode HOWTO incorrectly states that UTF-8 contains no zero bytes

2019-05-05 Thread Josh Rosenberg


Josh Rosenberg  added the comment:

Minor bikeshed: If updating the documentation, refer to U+ as "the null 
character" or "NUL", not "NULL". Using "NULL" allows for confusion with NULL 
pointers; "the null character" (the name used in the Unicode standard) or "NUL" 
(the official three letter abbreviation in ASCII, Unicode too I think) has no 
such opportunity for confusion.

--
nosy: +josh.r

___
Python tracker 

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



[issue36781] Optimize sum() for bools

2019-05-05 Thread Josh Rosenberg


Change by Josh Rosenberg :


--
nosy: +josh.r

___
Python tracker 

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



[issue36793] Do not define unneeded __str__ equal to __repr__

2019-05-05 Thread Josh Rosenberg


Josh Rosenberg  added the comment:

I like this. Always annoying to explicitly override both __repr__ and __str__ 
on subclasses of stuff like int when they should be the same. Patch looks good 
to me; I was originally wondering why some classes were replacing:

__str__ = __repr__

with:

__str__ = object.__str__

but checking their inheritance chains, it's clear *some* overload is needed for 
consistency, and using object.__str__ means reverting to the default case where 
subclasses only need to overload __repr__, rather than forcing all subclasses 
to overload both.

--
nosy: +josh.r

___
Python tracker 

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



[issue33725] Python crashes on macOS after fork with no exec

2019-05-05 Thread Barry A. Warsaw


Barry A. Warsaw  added the comment:

On May 5, 2019, at 11:44, Davin Potts  wrote:
> 
> Victor raises an important question:  should the *default* start behavior be 
> made consistent across platforms?

Yes, I think it should.  The pros of consistency and correctness outweigh the 
breaking change IMHO.

--

___
Python tracker 

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



[issue36807] IDLE doesn't call os.fsync()

2019-05-05 Thread Guido van Rossum


New submission from Guido van Rossum :

This came up during today's final PyCon keynote -- IDLE was called out
as one of the two editors *not* to use when live-coding on Adafruit's
Circuit Playground Express (https://www.adafruit.com/product/).

I *think* that the problem referred to is that IDLE doesn't guarantee
that the bits are actually flushed to disk -- they may linger in the
OS filesystem cache.

--
assignee: terry.reedy
components: IDLE
messages: 341474
nosy: gvanrossum, terry.reedy
priority: normal
severity: normal
stage: patch review
status: open
title: IDLE doesn't call os.fsync()
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



[issue36807] IDLE doesn't call os.fsync()

2019-05-05 Thread Guido van Rossum


Change by Guido van Rossum :


--
keywords: +patch
pull_requests: +13015

___
Python tracker 

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



[issue36806] Forbid creating of stream objects outside of asyncio

2019-05-05 Thread Andrew Svetlov


Change by Andrew Svetlov :


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

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Jeremy Kloth


Jeremy Kloth  added the comment:

Related to issue bpo-36319

--
nosy: +jkloth

___
Python tracker 

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



[issue36806] Forbid creating of stream objects outside of asyncio

2019-05-05 Thread Andrew Svetlov


New submission from Andrew Svetlov :

They were intended to be used by asyncio factories like open_connection from 
the very beginning but internals was leaked into asyncio top-level namespace.

The idea is: 
1. provide `_asyncio_internal` keyword-only parameter to leaked classes 
constructor 
2. have it False by default
3. Use `_asyncio_internal=True` when called from asyncio code.
3. Raise DeprecationWarning if `_asyncio_internal` is False

--
components: asyncio
messages: 341472
nosy: asvetlov, yselivanov
priority: normal
severity: normal
status: open
title: Forbid creating of stream objects outside of asyncio
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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Eric V. Smith


Eric V. Smith  added the comment:

I agree with Serhiy about the need to update PEP 572 to mention this.

--
keywords: +easy
stage:  -> needs patch

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Charlie Clark


Charlie Clark  added the comment:

winver tells me I have 1809. I'm only using Windows in a VM so I'm not that 
familiar with its innards.

Also get the error with WinPython 3.6:

Windows fatal exception: code 0xc374

Current thread 0x10c0 (most recent call first):
  File "C:\Users\charlieclark\WPy64-3680\python-3.6.8.amd64\lib\zipfile.py", 
line 1658 in writestr
  File "", line 1 in 

--

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

And I think that PEP 572 should be updated too. This is a corner case that was 
omitted at initial consideration of the PEP.

--

___
Python tracker 

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



[issue36800] Invalid coding error hidden on Windows

2019-05-05 Thread Eryk Sun


Eryk Sun  added the comment:

> Note I am aware the actual problem is "utf8" vs "utf-8". 

That shouldn't be an issue since "utf8" is an alias. 

The fact that your test file has LF line endings is an issue. It should be 
fixed in 3.7.4. See issue 20844.

--
nosy: +eryksun
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> SyntaxError: encoding problem: iso-8859-1 on Windows

___
Python tracker 

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



[issue36805] Don't close subprocess stream if it's stdin is closed

2019-05-05 Thread Andrew Svetlov


New submission from Andrew Svetlov :

Closing stdin FD by child stream is a legal operation, there is no reason to 
close entire subprocess transport immediately.

--
components: asyncio
messages: 341467
nosy: asvetlov, yselivanov
priority: normal
severity: normal
status: open
title: Don't close subprocess stream if it's stdin is closed
type: behavior
versions: Python 3.8

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Eric V. Smith


Eric V. Smith  added the comment:

Because of the backward compatibility issues, I'm not going to change the 
f-string parser for this. We'll just need to document the requirements for 
using parens if you want to use :=. This is similar to the existing 
documentation about lambdas and f-strings in 
https://docs.python.org/3/reference/lexical_analysis.html#formatted-string-literals

Patches welcome!

To be clear: like lambdas, this is just limitation of embedding expressions 
inside strings, and it's also a limitation because format specs can start with 
equal signs. It's not a restriction because I think f-strings shouldn't contain 
"top-level" := expressions.

--
assignee: eric.smith -> 
components: +Documentation -Interpreter Core
priority: release blocker -> normal

___
Python tracker 

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



[issue36774] f-strings: Add a !d conversion for ease of debugging

2019-05-05 Thread Eric V. Smith


Change by Eric V. Smith :


--
nosy: +barry

___
Python tracker 

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



[issue36801] Wait for connection_lost in StreamWriter.drain

2019-05-05 Thread Andrew Svetlov


Change by Andrew Svetlov :


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



[issue36804] Python for Windows installer Repair option does not repair PIP

2019-05-05 Thread Mark Green


New submission from Mark Green :

After installing Python for Windows using the standard installer, run "pip 
install --upgrade pip", which will damage pip as a result of running through 
pip.exe rather than python.exe. Both pip and python -m pip will now fail.

Rerunning the Python Installer and choosing the Repair option will list PIP as 
a component, but will not repair it. Using the Modify option will state that 
PIP is already installed and will thus do nothing if told to install it. The 
only option is to uninstall and reinstall again.

--

___
Python tracker 

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



[issue36804] Python for Windows installer Repair option does not repair PIP

2019-05-05 Thread Mark Green


Change by Mark Green :


--
components: +Installation, Windows
nosy: +paul.moore, steve.dower, tim.golden, zach.ware
title: Pythonr fo -> Python for Windows installer Repair option does not repair 
PIP
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



[issue36804] Pythonr fo

2019-05-05 Thread Mark Green


Change by Mark Green :


--
nosy: Mark Green
priority: normal
severity: normal
status: open
title: Pythonr fo

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Manjusaka


Manjusaka  added the comment:

copy that

I will reset my locale setting to figure it out

--

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Stefan Behnel


Stefan Behnel  added the comment:

FWIW, I think it's equally reasonable to allow assignment expressions directly 
in f-strings, as it is to require parentheses with a reference to the 
invalidity of top-level expressions.

That makes me lean towards adding a parse-time error message that suggests the 
right way to do it, and leave it out as a feature for now, because it risks 
conflicting with ":" as format separator. We do not know yet if we will really 
need this feature. It's easier to add the feature later, than to remove it 
again in case we find that it gets in the way more than it helps.

--
nosy: +scoder

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Dominik Geldmacher


Dominik Geldmacher  added the comment:

Enterprise 1809 and Professional 1803 (german localized) both reproduce the 
issue

--

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Emily Morehouse


Emily Morehouse  added the comment:

Ah yes, that's what I meant. I was thinking about the confusion between 
f-strings (evaluated immediately and stored as a string) vs other versions of 
string formatting which are evaluated when used. I've seen the mix of the two 
confuse people when evaluating performance. I don't think this is particularly 
relevant to this issue though, so we can ignore it :)

--

___
Python tracker 

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



[issue23041] csv needs more quoting rules

2019-05-05 Thread tegdev


tegdev  added the comment:

The correct handling of None values belongs to the csv module.

There is a use case to migrate a DB2 database to PostgreSQL.
DB2 has a command line tool "db2 export ..." which produces csv-files.
A row 
  ['Hello', null, 'world'] 
is exported to
  "Hello,,"world".

I would like to read in these exports with python and put it to PostgreSQL.

But with the csv library I can't read it in correctly. The input is converted 
to:
  ['Hello', '', 'world']
It should read as:
  ['Hello', None, 'world']

It is pretty easy to write a correct CSV reader with ANTLR but it's terribly 
slow.

And last but not least: if someone writes a list the reading should the 
identity.
Thats not True for the csv libraray.

Example:

import csv
hello_out_lst = ['Hello', None, 'world']
with open('hello.csv', 'w') as ofh:
writer = csv.writer(ofh, delimiter=',')
writer.writerow(hello_out_lst)

with open('hello.csv', 'r') as ifh:
reader = csv.reader(ifh, delimiter=',')
for row in reader:
hello_in_lst = row

is_equal = hello_out_lst == hello_in_lst
print(f'{hello_out_lst} is equal {hello_in_lst} ?  {is_equal}')

The result is:
['Hello', None, 'world'] is equal ['Hello', '', 'world'] ?  False

--
nosy: +tegdev

___
Python tracker 

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



[issue36800] Invalid coding error hidden on Windows

2019-05-05 Thread Tim Golden


Tim Golden  added the comment:

Python 3.6.6 (v3.6.6:4cf1f54eb7, Jun 27 2018, 03:37:03) [MSC v.1900 64 bit 
(AMD64)] on win32

I can't reproduce this on Windows. And it does seem an unlikely combination of 
effect and cause.

Do I take it that if you take out all the "logging..." lines, the thing works? 
ie you do correctly import threading and it shows a reasonable value when you 
print(threading)?

--

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

f-strings are defined and used at the same place, as any other expression. You 
can not save an f-string to a variable, as you can not save a multiplication. 
But you can save a string which is a result of the f-string evaluation.

Perhaps you were fooled by the name of f-strings. It looks as a special kind of 
strings, but actually it is a kind of expressions, like addition or 
multiplication.

--

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Manjusaka


Manjusaka  added the comment:

Hi  Dominik Geldmacher

May I get your system version? 1809 or 1903?

I guess maybe it's microsoft error

--

___
Python tracker 

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



[issue36793] Do not define unneeded __str__ equal to __repr__

2019-05-05 Thread Gregory P. Smith


Change by Gregory P. Smith :


--
type:  -> enhancement

___
Python tracker 

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



[issue36793] Do not define unneeded __str__ equal to __repr__

2019-05-05 Thread Gregory P. Smith


Change by Gregory P. Smith :


--
nosy: +gregory.p.smith

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Dominik Geldmacher


Dominik Geldmacher  added the comment:

I can reproduce it on Python 3.7.3 german Windows10 enterprise

Windows fatal exception: code 0xc374

Current thread 0x3bc8 (most recent call first):
  File "C:\Python37\lib\zipfile.py", line 1757 in writestr

--
nosy: +Dominik Geldmacher

___
Python tracker 

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



[issue34556] Add --upgrade to venv module

2019-05-05 Thread Cooper Lees


Change by Cooper Lees :


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

___
Python tracker 

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



[issue33725] Python crashes on macOS after fork with no exec

2019-05-05 Thread Davin Potts


Davin Potts  added the comment:

Victor raises an important question:  should the *default* start behavior be 
made consistent across platforms?  Assuming we change it on MacOS, the default 
start behavior on Windows and MacOS will be spawn but the default start 
behavior on Linux and FreeBSD (among others) will be fork.

Reasons to consider such a breaking change:
* This inconsistency in default start behavior on different platforms (Windows 
versus not) has historically been a significant source of confusion for many, 
many users.
* These days, the majority of users are not already familiar with the rule 
"fork-before-creating-threads" and so are surprised and confused when they fork 
a process that already has spun up multiple threads and bad things happen.
* We are changing the default on one platform (MacOS), which should prompt us 
to consider how are defaults are set elsewhere.

Reasons to reject such a breaking change:
* Though changing the default does not break everyone's code everywhere, it 
will require changes to any code that depends upon the default start method AND 
depends upon data/functions/stuff from the parent to also be present in the 
forked child process.

--
nosy: +pablogsal

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Emily Morehouse


Emily Morehouse  added the comment:

My initial reaction is that named expressions should not be valid in f-strings 
and should instead raise an exception, the same way that using `a := 10` does.

>>> a := 10
  File "", line 1
a := 10
  ^
SyntaxError: invalid syntax

It could be expected that named expressions could be used in f-strings in the 
same way as, say, list comprehensions or when used in parenthesis. One of the 
tricky things about named expressions is that the scope of the variable being 
assigned to gets "elevated" to the enclosing scope (this is a slightly 
simplified explanation but applies for most cases).

Since f-strings are executed when defined and not where they are used, this 
could lead to confusing behavior. Is it available only when defined? Would 
users expect a variable to be available again when the f-string if it were 
saved to a variable? Would we modify the expected behavior of named expressions 
to contain scope to only the f-string? I'm not sure that any of these are 
particularly clear in behavior or in the definitions laid out in PEP 572.

--

___
Python tracker 

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



[issue36803] Getting a lot of runtime misaligned address error while building python 2.7.6 with UBSAN

2019-05-05 Thread dibya ranjan mishra


New submission from dibya ranjan mishra :

I downloaded python 2.7.6 source and am trying to build with UBSAN flag 
following the instructions https://devguide.python.org/clang/. But I am getting 
a lot of misaligned address errors when I run make or make test command. Below 
is an example:

Objects/listobject.c:161:5: runtime error: member access within misaligned 
address 0x2adff0773228 for type 'struct (anonymous struct at 
Include/objimpl.h:253:5)', which requires 16 byte alignment


I need this ubsan enabled python 2.7 as a part of my project.

--
components: Build
messages: 341453
nosy: dibya ranjan mishra
priority: normal
severity: normal
status: open
title: Getting a lot of runtime misaligned address error while building python 
2.7.6 with UBSAN
type: behavior
versions: Python 2.7

___
Python tracker 

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



[issue33725] Python crashes on macOS after fork with no exec

2019-05-05 Thread Davin Potts


Davin Potts  added the comment:

I believe we must change the default behavior on MacOS to use spawn instead of 
fork.  Encouraging people to use fork by default on MacOS is encouraging them 
to create something that effectively will not work.  Keeping fork as the 
default behavior when we have already turned off all of the tests of fork 
behavior on MacOS also makes no sense.  Existing Python code that depends upon 
the default behavior (fork) on MacOS has already been broken -- if we make this 
change, we are arguably not breaking anyone's working code.

Users can and will still be able to specify the start mechanism on MacOS, 
including fork.  This empowers users to continue to handle even the most 
esoteric use cases without loss of functionality from multiprocessing.  Though 
admittedly, without an ability to test the behavior of fork, this will need to 
be marked as deprecated.

I will supply a patch making this change and updating the docs shortly after 
PyCon.

--

___
Python tracker 

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



[issue36798] f-strings do not support top-level :=

2019-05-05 Thread Eric V. Smith


Change by Eric V. Smith :


--
title: := breaks f-strings -> f-strings do not support top-level :=

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Eric V. Smith


Eric V. Smith  added the comment:

The fact that adding := support could break existing working code does give me 
pause to make any change here, and does suggest that a deprecation period would 
be needed in order to modify the f-string expression scanning behavior.

One concern I have is that if something akin to PEP 536 is used to implement 
f-strings, then it would require some work (but not be impossible) to avoid 
allowing :=.

In 3.8, := is prohibited in "expression as a statement" mode, but that's not 
the mode that f-strings expressions operate in: they're just normal 
expressions, and I would normally just expect := to work. But the backward 
compatibility break here is the reason to possibly disallow supporting :=, not 
that := should just never work in f-strings without parens.

--

___
Python tracker 

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



[issue36802] Revert back StreamWriter awrite/aclose but provide await writer.write() and await writer.close()

2019-05-05 Thread Andrew Svetlov


Change by Andrew Svetlov :


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

___
Python tracker 

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



[issue36802] Revert back StreamWriter awrite/aclose but provide await writer.write() and await writer.close()

2019-05-05 Thread Andrew Svetlov


New submission from Andrew Svetlov :

Yuri and I decided that `writer.awrite()` and `writer.aclose()` look ugly.

Instead, we return awaitable object from these methods to allow both 
`writer.write(b'data')` and `await writer.write(b'data')` for the method.

The same for `writer.close()` call.

--
components: asyncio
messages: 341450
nosy: asvetlov, yselivanov
priority: normal
severity: normal
status: open
title: Revert back StreamWriter awrite/aclose but provide await writer.write() 
and await writer.close()
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



[issue36801] Wait for connection_lost in StreamWriter.drain

2019-05-05 Thread Andrew Svetlov


Change by Andrew Svetlov :


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

___
Python tracker 

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



[issue36684] codecov.io code coverage has not updated since 2019-04-13

2019-05-05 Thread Gordon P. Hemsley


Gordon P. Hemsley  added the comment:

It seems the primary cause of the problem is simply that testing crossed the 
boundary of maximum execution time allotted by Travis CI.

I'm experimenting now with ways to speed up testing without losing granularity. 
However, given how long code coverage has been missing, it might be worthwhile 
to move forward on a stopgap solution that at least gets code coverage being 
tracked again, if not comprehensively.

--

___
Python tracker 

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



[issue36654] Add example to tokenize.tokenize

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I do not think a new example is needed. The existing example already 
demonstrates the use of file's readline method.

If you need an example for opening a file, the tokenize module documentation is 
not an appropriate place for this.

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue32424] Synchronize copy methods between Python and C implementations of xml.etree.ElementTree.Element

2019-05-05 Thread Gordon P. Hemsley


Gordon P. Hemsley  added the comment:

It seems the final open question on this is whether the mismatch between the 
Python and C implementations is enough to bypass PendingDeprecationWarning for 
copy() in favor of jumping straight to DeprecationWarning.

--

___
Python tracker 

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



[issue36772] Let lru_cache be used as a decorator with no arguments

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

To clarify, I am not opposing this feature. I had doubts because if the memory 
does not betray me similar propositions for lru_cache or other decorator 
fabrics were rejected in past. But times change.

--

___
Python tracker 

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



[issue36801] Wait for connection_lost in StreamWriter.drain

2019-05-05 Thread Andrew Svetlov


New submission from Andrew Svetlov :

Now `await writer.drain()` performs `await sleep(0)` if underlying transport is 
closing.

It works well only for plain sockets. SSL transport needs more context switches 
to shut down the SSL connection.
Drain wakes up too early to check if the transport is actually closed.

--
components: asyncio
messages: 341445
nosy: asvetlov, yselivanov
priority: normal
severity: normal
status: open
title: Wait for connection_lost in StreamWriter.drain
type: behavior
versions: Python 3.8

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Charlie Clark

Charlie Clark  added the comment:

That's what we thought when we looked at it, but as I said, I couldn't 
reproduce it with just the `time` call or the `ZInfo` instantiation, so 
something odd is happening. I do have a German version of Windows as I suspect 
the original reporter does. You'd think that sort of thing wouldn't matter…

--

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Larry Hastings


Larry Hastings  added the comment:

I'm not sure why Guido's preferences would be relevant.  f-strings support 
expressions, := is a valid expression, f-strings therefore must support it. 
 f-strings expressions are not top-level statements and therefore will not 
require parentheses around :=.

There appears to be some confusion around f-strings' use of : to delimit a 
"format specification".  Supporting := won't break format specifications, 
although it will require some intelligence--if you see a :, you must examine 
the next character to know whether it's := or a format specification.  It is 
not a breaking change.

--

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Manjusaka


Manjusaka  added the comment:

Same environment.

But I still can not reproduce this exception. I guess maybe it's about the 
local time or timezone problem. I will find a way to figure it out

--

___
Python tracker 

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



[issue36781] Optimize sum() for bools

2019-05-05 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


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

___
Python tracker 

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



[issue36799] Typo in ctypes documentation

2019-05-05 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

No problem, I have tagged it as easy and hope someone makes GitHub PR for the 
same.

Thank you for the report.

--

___
Python tracker 

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



[issue36799] Typo in ctypes documentation

2019-05-05 Thread Reuben Thomas


Reuben Thomas  added the comment:

No, as I'm not an active Python contributor, do not aspire to be one, and don't 
really want to have to learn yet another contribution system to a major project 
just to fix a trivial typo. Sorry!

--

___
Python tracker 

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



[issue36799] Typo in ctypes documentation

2019-05-05 Thread Karthikeyan Singaravelan

Karthikeyan Singaravelan  added the comment:

Reuben, would you like to make a PR for this change? The change needs to be 
done in https://github.com/python/cpython/blob/master/Doc/library/ctypes.rst

➜  cpython git:(master) ✗ rg 'It is possible to defined'
Doc/library/ctypes.rst
2379:  It is possible to defined sub-subclasses of structure types, they 
inherit
2427:   It is possible to defined sub-subclasses of structures, they inherit the

--
keywords: +easy
nosy: +xtreak
stage:  -> needs patch

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Charlie Clark


Charlie Clark  added the comment:

Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 21:26:53) [MSC v.1916 32 bit 
(Intel)] on win32

--

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Manjusaka


Manjusaka  added the comment:

Or would you share the Exception with us ?

I guess it's caused by system setting

--

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Note that Guido prefers to use parentheses around the assignment operator even 
if the grammar does nor require this. He used this style in What's New.

--

___
Python tracker 

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



[issue36792] zipfile.writestr causes a Python crash on Windows if the locale is set

2019-05-05 Thread Manjusaka


Manjusaka  added the comment:

I can't reproduce this error on my system by using the same code.

Could you share the system info with us?

--
nosy: +Manjusaka

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

There was a note on PEP 572 
(https://www.python.org/dev/peps/pep-0572/#exceptional-cases) to prohibit as a 
top level expression and a discussion on the issue also didn't agree with it 
https://bugs.python.org/issue35224#msg339098 . It might cause confusion to 
users due to this difference inside and outside of f-strings.

--
nosy: +xtreak

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Allowing it at the top level is a breaking change. It should not be done 
without deprecation. And I think that it is better to use parenthesis around 
the assignment operator (or better do not use it in f-strings at all) that 
deprecate the "=" alignment.

--

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Eric V. Smith


Eric V. Smith  added the comment:

Correct about the parens. I'm just going to fix it a the top level, without 
parens. There's no reason it shouldn't work, the fact that it doesn't work now 
is just an accident of implementation.

I'll fix it by adding a special test, the same way that != has a special test.

For those who say it shouldn't be allowed at the top level anyway, but should 
be allowed in parens: if we decide that (which I disagree with), then it should 
not be disallowed because of an accidental interaction with format specs. It 
should be explicitly checked for and disallowed. Again, I am not planning on 
making that change. I'm just going to allow it.

--

___
Python tracker 

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



[issue36773] Race condition during pickle.load()

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

It should be fixed in 3.7.3.

https://docs.python.org/3.7/whatsnew/changelog.html#python-3-7-3-release-candidate-1

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue36791] sum() relies on C signed overflow behaviour

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset 29500737d45cbca9604d9ce845fb2acc3f531401 by Serhiy Storchaka in 
branch 'master':
bpo-36791: Safer detection of integer overflow in sum(). (GH-13080)
https://github.com/python/cpython/commit/29500737d45cbca9604d9ce845fb2acc3f531401


--

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

You can use it in parenthesis:

>>> f'{(x:=10)}'
'10'

It should be explicitly documented, that what looks like the assignment 
operator is not always the assignment operator in f-strings.

>>> x = 10
>>> f'{x:=10}'
'10'

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Eric V. Smith


Eric V. Smith  added the comment:

f-strings are not going to take a position on what a "good" expression is, and 
what is and isn't allowed. If it's a Python expression that could possibly be 
parsed in the f-string context, f-strings will allow it. This is clearly a bug 
in 3.8. I'll have a PR today or during the sprints.

--

___
Python tracker 

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



[issue33530] Implement Happy Eyeball in asyncio

2019-05-05 Thread Andrew Svetlov


Change by Andrew Svetlov :


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



[issue33530] Implement Happy Eyeball in asyncio

2019-05-05 Thread miss-islington


miss-islington  added the comment:


New changeset 88f07a804a0adc0b6ee87687b59d8416113c7331 by Miss Islington (bot) 
(twisteroid ambassador) in branch 'master':
bpo-33530: Implement Happy Eyeballs in asyncio, v2 (GH-7237)
https://github.com/python/cpython/commit/88f07a804a0adc0b6ee87687b59d8416113c7331


--
nosy: +miss-islington

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread SilentGhost


SilentGhost  added the comment:

> The point is that := is valid expression syntax in Python 3.8, but you can't 
> use it in an f-string.

Good? Allowing walrus operator in the f-strings will just lead to the debugging 
hell.

--

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread Larry Hastings


Larry Hastings  added the comment:

The point is that := is valid expression syntax in Python 3.8, but you can't 
use it in an f-string.  The fact that the error is the same in 3.6 and 3.7 is 
irrelevant because := was not valid syntax in those versions.

--

___
Python tracker 

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



[issue36773] Race condition during pickle.load()

2019-05-05 Thread papad


papad  added the comment:

In what version should this be fixed? I see https://bugs.python.org/issue34572 
says the fix is in version 3.7, while I'm experiencing this on python 3.7.3, 
which version should I check?

--

___
Python tracker 

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



[issue36798] := breaks f-strings

2019-05-05 Thread SilentGhost


SilentGhost  added the comment:

This doesn't seem at all related to walrus operator, I can reproduce this error 
on 3.6.7 and 3.7.3, given that format call returns exactly the same error, it 
seems like '=' is simply not a valid alignment for strings.

I'm not saying that walrus operator did not introduce any errors, but those 
could be perhaps best tested using the following code:

f'{x:=^10}'

--
nosy: +SilentGhost

___
Python tracker 

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



[issue36800] Invalid coding error hidden on Windows

2019-05-05 Thread SilentGhost


Change by SilentGhost :


--
type: compile error -> behavior

___
Python tracker 

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



[issue34915] LWPCookieJar.save() creates *.lwp file in 644 mode

2019-05-05 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

Martin, any thoughts on this change?

--
nosy: +martin.panter

___
Python tracker 

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



[issue36800] Invalid coding error hidden on Windows

2019-05-05 Thread Yuval Greenfield


Yuval Greenfield  added the comment:

Note I am aware the actual problem is "utf8" vs "utf-8". But for some reason on 
Windows the exception does not reflect that.

--

___
Python tracker 

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



[issue36800] Invalid coding error hidden on Windows

2019-05-05 Thread Yuval Greenfield


New submission from Yuval Greenfield :

These lines fail on Windows in a surprising way:

# -*- coding: utf8 -*-
import threading
print("threading %s" % threading)


Normally they would throw this:

  ```File 
"C:\Python36\Lib\site-packages\missinglink_kernel\callback\log_monitor.py", 
line 1
SyntaxError: encoding problem: utf8```

But attached is a file that throws this instead:

```
Traceback (most recent call last):
  File 
"C:\Python36\Lib\site-packages\missinglink_kernel\callback\log_monitor.py", 
line 2, in 
import threading
NameError: name 'threading' is not defined
```

It seems that the amount of lines in the file will cause the exception hiding 
bug to manifest.

This issue did reproduce on my Windows machine here:

* Python 3.6.4 (v3.6.4:d48eceb, Dec 19 2017, 06:54:40) [MSC v.1900 64 bit 
(AMD64)] on win32
* Python 3.7.1 (default, Dec 10 2018, 22:54:23) [MSC v.1915 64 bit (AMD64)] :: 
Anaconda, Inc. on win32
* Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 21:26:53) [MSC v.1916 32 bit 
(Intel)] on win32

It did NOT reproduce on my Mac at all:

It does not repro on my mac at all:
* Python 3.7.1 (default, Dec 14 2018, 13:28:58)  [Clang 4.0.1 
(tags/RELEASE_401/final)] :: Anaconda, Inc. on darwin
* Python 3.6.5 |Anaconda, Inc.| (default, Apr 26 2018, 08:42:37) [GCC 4.2.1 
Compatible Clang 4.0.1 (tags/RELEASE_401/final)] on darwin

--
components: Windows
files: log_monitor.py
messages: 341420
nosy: paul.moore, steve.dower, tim.golden, ubershmekel, zach.ware
priority: normal
severity: normal
status: open
title: Invalid coding error hidden on Windows
type: compile error
versions: Python 3.7
Added file: https://bugs.python.org/file48300/log_monitor.py

___
Python tracker 

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



[issue36799] Typo in ctypes documentation

2019-05-05 Thread Reuben Thomas

New submission from Reuben Thomas :

"It is possible to defined" → "It is possible to define"

--
assignee: docs@python
components: Documentation
messages: 341419
nosy: docs@python, rrt
priority: normal
severity: normal
status: open
title: Typo in ctypes documentation
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