[issue33844] Writing capital letters with csvwriter.writerow changes the csv file format

2018-06-13 Thread Stefan Vasilev


Stefan Vasilev  added the comment:

Ah, I see now. What a coincidence :)
Thank you for explaining that!

--
resolution: not a bug -> works for me

___
Python tracker 

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



[issue33850] Json.dump() bug when using generator

2018-06-13 Thread Clément Boyer

New submission from Clément Boyer :

I use a class to write easily json when having generator.
```python
class StreamArray(list):
def __init__(self, generator):
super().__init__()
self.generator = generator
def __iter__(self):
return self.generator
def __len__(self):
return 1
```
Below a test comparing json.dump and json.dumps.
```
>>> import json
>>> class StreamArray(list):
... def __init__(self, generator):
... super().__init__()
... self.generator = generator
... def __iter__(self):
... return self.generator
... def __len__(self):
... return 1
... 
>>> g = (i for i in range(0))
>>> json.dumps({"a": StreamArray(g)})
'{"a": []}'
>>> f = open("/tmp/test.json", "w+")
>>> g = (i for i in range(0))
>>> json.dump({"a": StreamArray(g)}, f)
>>> f.close()
>>> print(open("/tmp/test.json").read())
{"a": ]}
```
I don't know if it's me or if there is actually a problem, could you help me ?

--
components: Library (Lib)
messages: 319436
nosy: biloup
priority: normal
severity: normal
status: open
title: Json.dump() bug when using generator
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



[issue33836] [Good first-time issue] Recommend keyword-only param for memoization in FAQ

2018-06-13 Thread Jason


Jason  added the comment:

Hey Zach,

Can I get this one? I haven't contributed anything yet.


Cheers,
Jason

--
nosy: +codecamelot

___
Python tracker 

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



[issue27777] cgi.FieldStorage can't parse simple body with Content-Length and no Content-Disposition

2018-06-13 Thread Chris Eykamp


Chris Eykamp  added the comment:

This also manifests itself when using web.py: if the underlying code throws an 
exception, this is emitted:

  File "/usr/local/lib/python3.5/dist-packages/web/webapi.py", line 364, in 
input
out = rawinput(_method)
  File "/usr/local/lib/python3.5/dist-packages/web/webapi.py", line 341, in 
rawinput
a = cgi.FieldStorage(fp=fp, environ=e, keep_blank_values=1)
  File "/usr/lib/python3.5/cgi.py", line 561, in __init__
self.read_single()
  File "/usr/lib/python3.5/cgi.py", line 740, in read_single
self.read_binary()
  File "/usr/lib/python3.5/cgi.py", line 762, in read_binary
self.file.write(data)
TypeError: write() argument must be str, not bytes

--

___
Python tracker 

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



[issue31378] Missing documentation for sqlite3.OperationalError

2018-06-13 Thread Berker Peksag


Berker Peksag  added the comment:


New changeset 71ede00f140fa6b67a8ac17df68b80079efa8dc2 by Berker Peksag 
(Zackery Spytz) in branch 'master':
bpo-31378: Document sqlite3.OperationalError exception (GH-7677)
https://github.com/python/cpython/commit/71ede00f140fa6b67a8ac17df68b80079efa8dc2


--

___
Python tracker 

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



[issue31378] Missing documentation for sqlite3.OperationalError

2018-06-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +7290

___
Python tracker 

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



[issue31378] Missing documentation for sqlite3.OperationalError

2018-06-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +7291

___
Python tracker 

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



[issue31378] Missing documentation for sqlite3.OperationalError

2018-06-13 Thread miss-islington


miss-islington  added the comment:


New changeset 961332dfd3dbff4c63ed4d9f8b5de937aa63475b by Miss Islington (bot) 
in branch '3.6':
bpo-31378: Document sqlite3.OperationalError exception (GH-7677)
https://github.com/python/cpython/commit/961332dfd3dbff4c63ed4d9f8b5de937aa63475b


--

___
Python tracker 

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



[issue31378] Missing documentation for sqlite3.OperationalError

2018-06-13 Thread miss-islington


miss-islington  added the comment:


New changeset eea4f149717cc83038641ca53f6f74be785de6f1 by Miss Islington (bot) 
in branch '3.7':
bpo-31378: Document sqlite3.OperationalError exception (GH-7677)
https://github.com/python/cpython/commit/eea4f149717cc83038641ca53f6f74be785de6f1


--
nosy: +miss-islington

___
Python tracker 

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



[issue31378] Missing documentation for sqlite3.OperationalError

2018-06-13 Thread Berker Peksag


Change by Berker Peksag :


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



[issue33844] Writing capital letters with csvwriter.writerow changes the csv file format

2018-06-13 Thread Eric V. Smith


Change by Eric V. Smith :


--
resolution: works for me -> not a bug

___
Python tracker 

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



[issue27777] cgi.FieldStorage can't parse simple body with Content-Length and no Content-Disposition

2018-06-13 Thread STINNER Victor


Change by STINNER Victor :


--
nosy:  -vstinner

___
Python tracker 

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



[issue33850] Json.dump() bug when using generator

2018-06-13 Thread Eric V. Smith


Eric V. Smith  added the comment:

You should ask your question on this mailing list: 
https://mail.python.org/mailman/listinfo/python-list

The bug tracker is not a place for asking how to use Python. If you actually 
find a bug in Python, you can re-open this issue. I do not believe that what 
you show here is a Python bug.

Good luck!

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



[issue27777] cgi.FieldStorage can't parse simple body with Content-Length and no Content-Disposition

2018-06-13 Thread Berker Peksag


Berker Peksag  added the comment:

Thank you for the ping, Chris. I will try to combine Bert's and Julien's 
patches and prepare a PR this weekend.

--
versions: +Python 3.8 -Python 3.5

___
Python tracker 

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



[issue32356] asyncio: Make transport.pause_reading()/resume_reading() idempotent; add transport.is_reading()

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 142e3c08a40c75b5788474b0defe7d5c0671f675 by Victor Stinner in 
branch '3.6':
[3.6] bpo-32356: idempotent pause_/resume_reading (GH-4914) (GH-7629)
https://github.com/python/cpython/commit/142e3c08a40c75b5788474b0defe7d5c0671f675


--
nosy: +vstinner

___
Python tracker 

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



[issue33748] test_discovery_failed_discovery in test_unittest modifies sys.path

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

Note: Python 2.7 doesn't have the 
test_discovery_from_dotted_namespace_packages() test, so no backport to 2.7 is 
needed.

--
nosy: +vstinner

___
Python tracker 

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



[issue15533] subprocess.Popen(cwd) documentation: Posix vs Windows

2018-06-13 Thread Damon Atkins


Damon Atkins  added the comment:

I see from this. That this is still an issue
https://github.com/python/cpython/blob/master/Lib/subprocess.py#L1146

Is it not a solution to
save current directory location
chdir(cwd) before calling  _winapi.CreateProcess()
restore the original directory.

This will result in the cwd being searched for the executable, which most 
people would expect to happen.  It seems CreateProcess does not change to cwd 
until after the file is checked for existence or loaded.

--
nosy: +Damon Atkins

___
Python tracker 

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



[issue15533] subprocess.Popen(cwd) documentation: Posix vs Windows

2018-06-13 Thread Damon Atkins


Damon Atkins  added the comment:

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

--

___
Python tracker 

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



[issue33625] Release GIL for grp.getgr{nam, gid} and pwd.getpw{nam, uid}

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I think this change is too large for bugfix. It is a performance enhancement, 
but doing it right needs non-trivial rewriting of the code.

--

___
Python tracker 

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



[issue33625] Release GIL for grp.getgr{nam, gid} and pwd.getpw{nam, uid}

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

For a recent example of change releasing the GIL, see bpo-32186 which has been 
backported up to 2.7.

--

___
Python tracker 

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



[issue33694] test_asyncio: test_start_tls_server_1() fails on Python on x86 Windows7 3.7 and 3.x

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

New changeset 142e3c08a40c75b5788474b0defe7d5c0671f675 by Victor Stinner in 
branch '3.6':
[3.6] bpo-32356: idempotent pause_/resume_reading (GH-4914) (GH-7629)
https://github.com/python/cpython/commit/142e3c08a40c75b5788474b0defe7d5c0671f675

--

___
Python tracker 

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



[issue33351] Support compiling with clang-cl on Windows

2018-06-13 Thread Ethan Smith


Change by Ethan Smith :


--
pull_requests: +7292

___
Python tracker 

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



[issue27777] cgi.FieldStorage can't parse simple body with Content-Length and no Content-Disposition

2018-06-13 Thread Chris Eykamp


Chris Eykamp  added the comment:

I've already got a PR based on the patch listed under the Files section (it's 
prepared, not yet submitted), but if you want to do something more, I'll step 
back and let you do it.

--

___
Python tracker 

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



[issue1529353] Squeezer - squeeze large output in the interpreter

2018-06-13 Thread Cheryl Sabella


Cheryl Sabella  added the comment:

6.  Sorry about being so vague.  I was referring to the configuration page 
having an option to hide/show the tooltip.  I wasn't sure if that was a 
necessary config option.

--

___
Python tracker 

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



[issue33671] Efficient zero-copy for shutil.copy* functions (Linux, OSX and Win)

2018-06-13 Thread Giampaolo Rodola'


Change by Giampaolo Rodola' :


--
pull_requests: +7293

___
Python tracker 

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



[issue33851] 3.7 regression: ast.get_docstring() for a node that lacks a docstring

2018-06-13 Thread Marius Gedminas


New submission from Marius Gedminas :

Python 3.7 removes an isinstance(node.body[0], Expr) check ast.get_docstring() 
that makes it crash when you pass in AST nodes of modules or functions that do 
not have docstrings.

Steps to reproduce:

- git clone https://github.com/mgedmin/findimports
- cd findimports
- tox -e py37

The failure looks like this:

Traceback (most recent call last):
  ...
  File "/home/mg/src/findimports/findimports.py", line 337, in 
find_imports_and_track_names
visitor.visit(root)
  File "/home/mg/opt/python37/lib/python3.7/ast.py", line 262, in visit
return visitor(node)
  File "/home/mg/src/findimports/findimports.py", line 169, in 
visitSomethingWithADocstring
self.processDocstring(ast.get_docstring(node, clean=False), lineno)
  File "/home/mg/opt/python37/lib/python3.7/ast.py", line 211, in 
get_docstring
node = node.body[0].value
AttributeError: 'Import' object has no attribute 'value'

--
components: Library (Lib)
messages: 319453
nosy: mgedmin
priority: normal
severity: normal
status: open
title: 3.7 regression: ast.get_docstring() for a node that lacks a docstring
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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread Charalampos Stratakis


Charalampos Stratakis  added the comment:

The latest stable Fedora's have glibc >= 2.26

Maybe the buildbot needs to be updated?

--
nosy: +cstratak

___
Python tracker 

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



[issue33851] 3.7 regression: ast.get_docstring() for a node that lacks a docstring

2018-06-13 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


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

___
Python tracker 

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



[issue33851] 3.7 regression: ast.get_docstring() for a node that lacks a docstring

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I think this fix is worth cherry-picking in 3.7.0.

--
nosy: +ned.deily, serhiy.storchaka
priority: normal -> release blocker
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



[issue33851] 3.7 regression: ast.get_docstring() for a node that lacks a docstring

2018-06-13 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
nosy: +inada.naoki

___
Python tracker 

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



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

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I need the glibc version for skipping a test if run with glibc containing a bug 
(see issue31630 and issue33630). platform.libc_ver() is not usable, it always 
returns '2.9' (the version that has bugs), while the actual version on my 
computer is '2.25' (the version that doesn't have these bugs).

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

If we want to support older versions of glibc a temporary (and somewhat 
inelegant) workaround is storing the temporaries in a list that the caller 
passes and destroy the list after calling `posix_spawn`.

--

___
Python tracker 

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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

> If we want to support older versions of glibc a temporary (and somewhat 
> inelegant) workaround is storing the temporaries in a list that the caller 
> passes and destroy the list after calling `posix_spawn`.

Creating a copy seems to be a reasonable tradeoff.

Another option is to detect the bug at runtime and raise an exception if the 
bug is detected. But I dislike this option: I hate when a function is available 
in the os module but calling it raises a NotImplementedError :-( Moreover, 
posix_spawn() seems to be a lot of benefit, so I would like to be able to use 
it on "old" glibc versions.

--

___
Python tracker 

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



[issue33850] Json.dump() bug when using generator

2018-06-13 Thread Walter Dörwald

Walter Dörwald  added the comment:

The problem here is that StreamArray lies about the length of the iterator. 
This confuses json.encoder._make_iterencode._iterencode_list(), (which is 
called by json.dump()), because it first does a check for "if not lst" and then 
assumes in the loop that it will be entered at least once.

(Note that json.dumps() doesn't have that problem, because it calls 
JSONEncoder.encode() with _one_shot=True which leads to a totally different 
code path).

We could declare that bug as "don't do that then", but the problem is easily 
solvable, because we can check whether the loop was entered. The attached patch 
should do the trick.

An even better approach would IMHO be, that the encoder supports a special flag 
that enables JSON serialization of generators directly, so it's no longer 
required to masquerade generators as list

--
keywords: +patch
nosy: +doerwalter
resolution: not a bug -> 
status: closed -> open
Added file: https://bugs.python.org/file47640/json-dump-generators-bug.diff

___
Python tracker 

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



[issue33852] doc Remove parentheses from

2018-06-13 Thread Andrés Delfino

New submission from Andrés Delfino :

I think the idea of having "list" inside parentheses is to document that in 
case of sequences, only "one-expression" expression lists are legal.

That being said, IMHO, explaining that in actual prose would be better, but 
removing the parentheses (taking into account that there's a description of 
what the expected evaluation of sequences subscription expression lists is) is 
enough, plus, it's the production list term's name.

If a prose is considered better, it could read:

"If the primary is a sequence, the expression list must be formed by only one 
expression, and it must evaluate to an integer or a slice (as discussed in the 
following section)."

Couldn't find the original author. It was committed before the move to 
mercurial, and I don't know if there's a subversion repo still available to see 
historical changes.

--
assignee: docs@python
components: Documentation
messages: 319460
nosy: adelfino, docs@python
priority: normal
pull_requests: 7295
severity: normal
status: open
title: doc Remove parentheses from
type: enhancement
versions: Python 2.7, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

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



[issue33850] Json.dump() bug when using generator

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

This is a duplicate of issue27613.

--
nosy: +serhiy.storchaka
resolution:  -> duplicate
status: open -> closed
superseder:  -> Empty iterator with fake __len__ is rendered as a single 
bracket ] when using json's iterencode

___
Python tracker 

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



[issue33852] doc Remove parentheses from sequence subscription description

2018-06-13 Thread Andrés Delfino

Change by Andrés Delfino :


--
title: doc Remove parentheses from -> doc Remove parentheses from sequence 
subscription description

___
Python tracker 

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



[issue33852] doc Remove parentheses from sequence subscription description

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

This wording was introduced in 3a0ad6089bccf0b167fe8ebd2457fedec8f851a3.

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

I have updated the PR with a workaround.

--

___
Python tracker 

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



[issue33836] [Good first-time issue] Recommend keyword-only param for memoization in FAQ

2018-06-13 Thread Zachary Ware


Zachary Ware  added the comment:

Certainly!  Have a look at the devguide to get started.

--

___
Python tracker 

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



[issue33852] doc Remove parentheses from sequence subscription description

2018-06-13 Thread Andrés Delfino

Andrés Delfino  added the comment:

Thanks, Serhiy! Didn't know I should trace the LaTeX version.

Guido, I'm adding you because it seems you authored or at least agreed on the 
current wording. Do you believe this proposal for improvement makes sense?

--
nosy: +gvanrossum

___
Python tracker 

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



[issue33615] test__xxsubinterpreters crashed on x86 Gentoo Refleaks 3.x

2018-06-13 Thread Eric Snow


Eric Snow  added the comment:


New changeset ab4a1988fd4347484a7928394b94e2cdf5f8f2a7 by Eric Snow in branch 
'master':
bpo-33615: Re-enable subinterpreter tests. (#7552)
https://github.com/python/cpython/commit/ab4a1988fd4347484a7928394b94e2cdf5f8f2a7


--

___
Python tracker 

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



[issue15533] subprocess.Popen(cwd) documentation: Posix vs Windows

2018-06-13 Thread Jan Lachnitt


Jan Lachnitt  added the comment:

@eryksun: Sorry for my late reply, apparently I did not have time to reply in 
2017. I see your point, but still I think that Python is conceptually 
multi-platform, so its behavior on Linux and Windows should be as much 
consistent as possible.

I am not the one to decide which one of the two possible behaviors shall be the 
correct one. The current documentation 
 describes 
the behavior on Linux: "In particular, the function looks for executable (or 
for the first item in args) relative to cwd if the executable path is a 
relative path." If this is chosen as the correct behavior, then the behavior on 
Windows is incorrect.

@Damon Atkins: Thank you for reminding this issue, but I suspect your proposed 
solution of being thread-unsafe. I propose another solution: On Windows, Python 
should resolve the executable path itself (taking cwd and env into account) and 
then pass the absolute path to CreateProcess().

--

___
Python tracker 

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



[issue33839] IDLE tooltips.py: refactor and add docstrings and tests

2018-06-13 Thread Tal Einat


Change by Tal Einat :


--
keywords: +patch
pull_requests: +7296
stage: test needed -> patch review

___
Python tracker 

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



[issue33839] IDLE tooltips.py: refactor and add docstrings and tests

2018-06-13 Thread Tal Einat


Tal Einat  added the comment:

The refactoring is done, manual testing with the htests works, and I've added 
automated tests with ~92% code coverage.

Terry, I'd be happy for your review!

--

___
Python tracker 

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



[issue27575] dict viewkeys intersection slow for large dicts

2018-06-13 Thread Forest


Forest  added the comment:

Is there anything helpful I can do to help close this issue? Maybe convert it 
into a github PR?

Since Raymond asked for cases where this issue is a problem, I'll add the case 
that brought me here.

I have an application where I need to do thousands of intersections of 
multisets. I started with the collections.Counter object, but the current 
intersection method is too slow. As Counter is a subclass of dict, I thought 
that I could significantly speed it up by taking advantage of keys 
intersections.

I've been able to verify that if key intersection was roughly similar in speed 
to set intersection, than that would be very helpful. However, the   current 
speed of key intersection does not make that practicable. I can, of course, 
cast the keys to sets before intersecting, but as David points out that casting 
is what is taking significant time.




slow dictionary intersection for becoming larger dicts is becoming a problem 
for me

--
nosy: +fgregg

___
Python tracker 

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



[issue33615] test__xxsubinterpreters crashed on x86 Gentoo Refleaks 3.x

2018-06-13 Thread Eric Snow


Eric Snow  added the comment:

I've re-enabled the subinterpreter tests, but left the one problem test 
(ChannelTests.test_run_string_arg_resolved) disabled.  I also changed all uses 
of %lld to use PRId64 instead.  (Thanks, Victor, for the suggestion.)

The buildbots look good.  I'll keep an eye on "x86 Gentoo Refleaks 3.x" for the 
next time it runs (starts every 24 hours; 10 hours from now).  When that passes 
I'll close this issue.

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

___
Python tracker 

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



[issue33853] test_multiprocessing_spawn is leaking memory

2018-06-13 Thread Pablo Galindo Salgado


New submission from Pablo Galindo Salgado :

The test `test_multiprocessing_spawn` is leaking memory according to the x86 
Gentoo Refleaks 3.x buildbot:


x86 Gentoo Refleaks 3.x
http://buildbot.python.org/all/#/builders/1/builds/253

test_multiprocessing_spawn leaked [1, 2, 1] memory blocks, sum=4
1 test failed again:
test_multiprocessing_spawn


x86 Gentoo Refleaks 3.7
http://buildbot.python.org/all/#/builders/114/builds/135

--
components: Tests
keywords: buildbot
messages: 319471
nosy: pablogsal
priority: normal
severity: normal
status: open
title: test_multiprocessing_spawn is leaking memory
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



[issue33853] test_multiprocessing_spawn is leaking memory

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

Duplicate of bpo-33735.

--
nosy: +vstinner
resolution:  -> duplicate
superseder:  -> test_multiprocessing_spawn leaked [1, 2, 1] memory blocks on 
AMD64 Windows8.1 Refleaks 3.7

___
Python tracker 

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



[issue33735] test_multiprocessing_spawn leaked [1, 2, 1] memory blocks on AMD64 Windows8.1 Refleaks 3.7

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

bpo-33853 has been marked as a duplicate this bug.

--

___
Python tracker 

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



[issue31181] Segfault in gcmodule.c:360 visit_decref (PyObject_IS_GC(op))

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

I am sorry, but without further information, we cannot fix your issue.

Usually, a crash in visit_decref() means that a C extension corrupted a random 
Python object. Try to run your test on Python 3 using PYTHONMALLOC=debug.

--
nosy: +vstinner
resolution:  -> out of date
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



[issue17045] Improve C-API doc for PyTypeObject

2018-06-13 Thread Eric Snow


Eric Snow  added the comment:

@Cheryl, thanks for pointing that out.  I'll take a look.

--

___
Python tracker 

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



[issue23869] Initialization is being done in PyType_GenericAlloc

2018-06-13 Thread Eric Snow


Eric Snow  added the comment:

Thanks for bringing this up, Hristo!

"Initialization" (in this context, and hopefully everywhere in the C-API docs) 
is referring specifically to setting fields on a custom instance, much as you 
would expect in __init__ (or sometimes even __new__).  In that regard 
PyType_GenericAlloc does not do any initialization.  Instead, what it does is 
at a low level which is consistent with allocating a basic object for use in 
the CPython object machinery:

  * allocate the memory
  * NULL out the allocated memory
  * set initial refcount to 1
  * fill in the fundamental PyObject fields (e.g. type)
  * register with GC

Most of that relates directly to memory management and definitely belongs in 
PyType_GenericAlloc.  I suppose you could argue that filling in the fundamental 
PyObject fields could go into PyType_GenericNew.  However, doing so would leave 
the "allocated" object in an inconsistent state for the object machinery, to be 
resolved by the type's tp_new implementation.  This could lead to problems for 
types that have a custom tp_new that does not use PyType_GenericNew.  In that 
case moving anything from PyType_GenericAlloc to PyType_GenericNew would be a 
backward-incompatible change (and add complexity to the object creation 
workflow).  Even though the chance for breakage is small, there would have to 
be a really strong reason to make such a change.

Consequently, there isn't a whole lot to be done here and I'm closing this 
issue.  If I've misunderstood then please let us know.  We can re-open the 
issue then.

FTR, PyType_GenericAlloc is implemented here:

  https://github.com/python/cpython/blob/master/Objects/typeobject.c#L963

--
nosy: +eric.snow
resolution:  -> rejected
stage:  -> resolved
status: open -> closed
versions: +Python 3.7, Python 3.8 -Python 3.2, Python 3.3, Python 3.4

___
Python tracker 

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



[issue23869] Initialization is being done in PyType_GenericAlloc

2018-06-13 Thread Eric Snow


Eric Snow  added the comment:

As to the docs, the entry for tp_alloc in Doc/c-api/typeobj.rst does not 
mention initialization.  The tp_new entry does say that it should call tp_alloc 
and then do the minimum initialization possible.  That implies (weakly) that 
tp_alloc should do the minimum initialization possible.  Could you point me to 
the place where the docs talk about tp_alloc and initialization?  That would be 
useful to see.

Regardless, having the tp_alloc entry explicitly say it shouldn't do any 
initialization does make sense.  Feel free to open a separate issue on that.

--

___
Python tracker 

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



[issue33625] Release GIL for grp.getgr{nam, gid} and pwd.getpw{nam, uid}

2018-06-13 Thread Ned Deily


Ned Deily  added the comment:

> For a recent example of change releasing the GIL, see bpo-32186 which has 
> been backported up to 2.7.

Playing Devil's Advocate here: yes, but that was a far simpler and less 
extensive change.  bpo-32186 did not change configure.ac and pyconfig.h.in and 
I suspect that the impact of the old behavior that bpo-32186 was far more wide 
spread than that of bpo-33625 (stating files on a NFS file system versus doing 
getpwnam/getpwuid's).  Also when Christian made his comment about a bug fix, 
the proposed PR was much simpler in scope.

I am not saying that we definitely should not backport to 3.7 but I don't think 
it is an automatic call as the PR now stands.  In any case, we should first get 
the fix into master and get some exposure there before deciding whether to 
backport.

--

___
Python tracker 

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



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

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I agree that the strategy used for platform.libc_ver() is not perfect. But the 
implementation has bugs that make it useless. The following PR fixes two bugs 
in the implementation:

1) Version numbers compared as strings.
2) Versions that are located on the border of 16 KiB blocks were not recognized 
or were recognized incorrectly.

--

___
Python tracker 

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



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

2018-06-13 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


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

___
Python tracker 

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



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

2018-06-13 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
versions: +Python 3.7, Python 3.8 -Python 3.4, Python 3.5

___
Python tracker 

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



[issue27777] cgi.FieldStorage can't parse simple body with Content-Length and no Content-Disposition

2018-06-13 Thread Berker Peksag


Berker Peksag  added the comment:

That's even better! :) Please submit your work as a pull request.

Did you take a look at https://github.com/Pylons/webob/pull/300 as well? Can we 
use the test in the PR? Is it possible to adapt it solve both this and WebOb 
issues?

--

___
Python tracker 

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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
pull_requests: +7298

___
Python tracker 

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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Serhiy commented in the PR:

>__GLIBC__ and __GLIBC_MINOR__ give you the version of glibc used at >compile 
>time. But can not the different version be dynamically linked at >run time?

Should we use the list approach always to avoid problems with this?

--

___
Python tracker 

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



[issue30747] _Py_atomic_* not actually atomic on Windows with MSVC

2018-06-13 Thread Ethan Smith


Ethan Smith  added the comment:

When working on clang-cl support, I was advised here 
https://reviews.llvm.org/D47672#1131325 that we may be using hardware lock 
elision incorrectly. Copying from there:

> I also spoke to Andi Kleen here at Intel to make sure I got these inline 
> assembly versions correct. And he's not sure CPython should be using these 
> the way it is. It looks like they try to use the HLE versions anytime the 
> memory order is acquire/release. But HLE isn't suitable for every 
> acquire/release.

I believe if we just use the simple 
_InterlockedExchange/_InterlockedCompareExchange intrinsics, things should be 
safer.

--
nosy: +Ethan Smith

___
Python tracker 

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



[issue33839] IDLE tooltips.py: refactor and add docstrings and tests

2018-06-13 Thread Tal Einat


Tal Einat  added the comment:

Attaching coverage report for tooltip.py.

The uncovered lines are required to avoid exceptions when closing a windows 
with a tooltip shown.  These are not currently reproduced by test_tooltip.py 
because my attempts to exercise them in automated tests have all failed so far.

The TclError exceptions are reproduced by the htest in tooltip.py.  The 
ValueError exception, however, I've only seen happen when actually running 
IDLE, since it is raised by the MultiCall module.

IMO it's not worth the effort to achieve 100% automated test coverage here.  
It's Terry's decision to make, though.

--
Added file: https://bugs.python.org/file47641/Coverage for 
Lib_idlelib_tooltip.py.png

___
Python tracker 

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



[issue33853] test_multiprocessing_spawn is leaking memory

2018-06-13 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


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



[issue33671] Efficient zero-copy for shutil.copy* functions (Linux, OSX and Win)

2018-06-13 Thread Marcos Dione


Marcos Dione  added the comment:

Thanks Gianpaolo for pushing for this. Great job.

--

___
Python tracker 

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



[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Yes, as I wrote on GitHub.

--

___
Python tracker 

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



[issue27575] dict viewkeys intersection slow for large dicts

2018-06-13 Thread Mali Akmanalp


Change by Mali Akmanalp :


--
nosy: +Mali Akmanalp

___
Python tracker 

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



[issue33671] Efficient zero-copy for shutil.copy* functions (Linux, OSX and Win)

2018-06-13 Thread STINNER Victor


STINNER Victor  added the comment:

> Thanks Gianpaolo for pushing for this. Great job.

I concur: great job! Cool optimization.

--

___
Python tracker 

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



[issue33462] reversible dict

2018-06-13 Thread Eric Snow


Eric Snow  added the comment:

Would it be possible to re-use the __reverse__() support that exists for 
OrderedDict?  Doing so could help avoid adding a bunch of duplicated code.

--
nosy: +eric.snow

___
Python tracker 

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



[issue27575] dict viewkeys intersection slow for large dicts

2018-06-13 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

> Is there anything helpful I can do to help close this issue?
> Maybe convert it into a github PR?

Yes, that would be nice.  Also, please verify that the test cases cover all the 
code paths.

--

___
Python tracker 

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



[issue33726] Add short descriptions to PEP references in seealso

2018-06-13 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

My personal opinion is that the PEP title should suffice and that a person can 
click the link for more detail.

--
nosy: +rhettinger

___
Python tracker 

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



[issue33718] Enhance regrtest: meta-ticket for multiple changes

2018-06-13 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +7299

___
Python tracker 

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



[issue33726] Add short descriptions to PEP references in seealso

2018-06-13 Thread Andrés Delfino

Andrés Delfino  added the comment:

Yeah, I think you are right. The motivation for this PR was to not have two 
PEPs references in the same line, because, IMHO, it looks somewhat weird. Now, 
they look like:

"See also: PEP 3115 - Metaclasses in Python 3 PEP 3129 - Class Decorators"

Would a change to make it look like:

"""
See also:

PEP 3115 - Metaclasses in Python 3
PEP 3129 - Class Decorators
"""

be accepted?

--

___
Python tracker 

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



[issue33836] [Good first-time issue] Recommend keyword-only param for memoization in FAQ

2018-06-13 Thread Noah Haasis


Change by Noah Haasis :


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



[issue15533] subprocess.Popen(cwd) documentation: Posix vs Windows

2018-06-13 Thread Damon Atkins


Damon Atkins  added the comment:

>From https://msdn.microsoft.com/en-us/library/windows/desktop/ms682425.aspx

Note Python is using CreateProcess(), consider using CreateProcessW()

The Unicode version of this function, CreateProcessW, can modify the contents 
of this string. Therefore, this parameter cannot be a pointer to read-only 
memory (such as a const variable or a literal string). If this parameter is a 
constant string, the function may cause an access violation.

--

___
Python tracker 

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



[issue33854] doc Add PEP title in seealso of Built-in Types

2018-06-13 Thread Andrés Delfino

New submission from Andrés Delfino :

Add PEP 461 title to Built-in Types seealso.

--
assignee: docs@python
components: Documentation
messages: 319493
nosy: adelfino, docs@python
priority: normal
severity: normal
status: open
title: doc Add PEP title in seealso of Built-in Types
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



[issue33854] doc Add PEP title in seealso of Built-in Types

2018-06-13 Thread Andrés Delfino

Change by Andrés Delfino :


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

___
Python tracker 

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



[issue1529353] Squeezer - squeeze large output in the interpreter

2018-06-13 Thread Tal Einat


Tal Einat  added the comment:

Once the ToolTip is ready, I'll begin working on this.

Summarizing what appear to be agreed-upon changes to be made (keeping original 
numbering for reference):

1. Avoid expanding large output accidentally / too easily. Current suggestions 
are expanding part of the output with a "more..." button, and a confirmation 
dialog e.g. "Are you sure? This could bring IDLE to a halt! Consider other 
methods of viewing the output."

2. Avoid using the middle button. Either use a more commonly accessible 
mouse-click combo, make it a context-menu option, or make it user-configurable.

3. Make the "preview" functionality use our tkTextView (will need testing to 
make sure it performs reasonably).

4. Increase default minimum # lines for auto-squeezing. 50? 100?

7. Change implementation method from an extension to an integrated part of IDLE.

--

___
Python tracker 

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



[issue1529353] Squeezer - squeeze large output in the interpreter

2018-06-13 Thread Tal Einat


Tal Einat  added the comment:

Additional feature discussion:

> 10. The button for 'a'*1 says '(nn lines)'.  It should say '(1 
> chars)' or '(1 line, 1 chars)'.

IMO that's too much, it leads to "information overload".  Since the number of 
lines shown is the number of "wrapped" lines, e.g. how many visual lines would 
be used, isn't that enough? W ould users really need to also know how many 
characters are there?

While on the subject, the labels are currently not updated when the width of 
the window is changed; this could be a future improvement to make (might need 
to be done in the background).

> 11. Right click should bring up a custom context menu.  It can have 'cut' 
> (delete), 'copy' (to clipboard, eliminating middle click need), 'edit' (IDLE 
> editor if it seems ok), 'view' (ditto for TextView).

'cut' and 'edit' would break the current IDLE shell convention that output 
above the prompt is read-only.  Squeezer currently manipulates such output, but 
essentially keeps it there in a different form.  This seems like a design 
decision you've already made, Terry, but personally I would find this rather 
confusing.

> Is there a standard for simulating left and right click with keys?  

Not that I'm aware of. Squeezer already has an event for expanding the last 
squeezed output; we could improve on the event bindings.  Some keyboards have a 
dedicated key for opening a context menu (used to be common), so for users with 
that having all of the options in the context menu would achieve the 
keyboard-only-usability goal.  We should likely do both, and show the keyboard 
shortcuts in the context menu.

--

___
Python tracker 

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



[issue1529353] Squeezer - squeeze large output in the interpreter

2018-06-13 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

3. It is idlelib's TextView, not tkTextView.  If it is not 'good enough', we 
might improve it.

5. Look at former extensions, like codecontext.py, corresponding parts of 
editor.py.  The key thing for immediate effect is the class reload method, 
called when the module is imported and when ConfigDialog [Apply] or [OK] is 
clicked.  For the latter, the class or its method must added to a list in 
either in ConfigDialog or EditorWindow.

--

___
Python tracker 

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



[issue29750] smtplib doesn't handle unicode passwords

2018-06-13 Thread Tal Einat


Tal Einat  added the comment:

It would be extremely helpful to have some test cases that actually work for 
users but fail with smtplib.  So far we have no actual examples, likely due to 
these being passwords.

> Note: it is definitely the case, regardless of what the RFC says, that binary 
> passwords need to be supported.

I'm not sure what you mean by "binary".  Do you mean 8-bit characters, a.k.a. 
bytes?

> utf-8 should probably be used as the default encoding for string passwords, 
> rather than ascii.

It is also possible that the appropriate encoding here is "latin1" a.k.a. 
ISO-8859-1 encoding.  This specifically includes many specialized versions of 
latin characters, e.g. those with German umlauts as mentioned in the duplicate 
issue #33741.  And it could even be the very common Windows-1252 encoding: "It 
is probably the most-used 8-bit character encoding in the world." (Wikipedia)

--

___
Python tracker 

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