[issue23914] pickle fails with SystemError

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Great! I afraid there were no buildbots with 2.4 and 2.5 for testing 
test_xpickle. Thank you Zachary!

--

___
Python tracker 

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



[issue23914] pickle fails with SystemError

2015-11-26 Thread Zachary Ware

Zachary Ware added the comment:

This broke test_xpickle with python 2.4 and 2.5 due to 'b' prefixes and an 
import that's not actually used in the 2.7 patch; now fixed.  The 
ware-gentoo-x86 buildslave now has pythons 2.4, 2.5, and 2.6 installed for 
test_xpickle to use.

--
nosy: +zach.ware

___
Python tracker 

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



[issue23914] pickle fails with SystemError

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 322060740b64 by Zachary Ware in branch '2.7':
Issue #23914: Fix test_xpickle with python 2.4 and 2.5
https://hg.python.org/cpython/rev/322060740b64

--

___
Python tracker 

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



[issue25660] tabs don't work correctly in python repl

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

Yury or anyone else: can you confirm if the patch works properly with a proper 
OS X or BSD libedit (rather than my questionable Linux version?). If so, I 
think it is okay to ignore my Linux problems, and I could look at fixing the 
compatibility when the readline module is not available.

Another way to look at this may be to fix the Editline (libedit) library to 
more faithfully emulate the Gnu version.

--

___
Python tracker 

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



[issue25740] multiple issues in http.client

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

I missed seeing the _get_hostport() change in the commit. So you are saying 
that values out of range 1–65535 should raise InvalidURL("nonnumeric port . . 
."). The error message isn’t quite right.

--

___
Python tracker 

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



[issue25740] multiple issues in http.client

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

Thanks for these fixes. It might be better to open other report(s) for the 
FIXME comments, so you can explain them better, and propose any ideas or 
possible solutions. For some of them, it may be more appropriate to just fix 
them in the next (3.6) release, such as the method case insensitivity thing (to 
minimize backwards compatibility problems).

It would be good to have regression test cases for each bug fixed.

Regarding folded header field values, I think there was some discussion about 
deprecating that ability in Issue 22928. Definitely needs a separate report.

See Issue 23740 about various quirks with what objects and automatic encodings 
are accepted when sending a request. It is already a can of worms; I suggest 
not to make it any more complicated.

Can you elaborate on accepting invalid ports? Is this related to Issue 24169?

--
nosy: +martin.panter
stage:  -> patch review
type:  -> behavior
versions: +Python 2.7, Python 3.4, Python 3.5, Python 3.6

___
Python tracker 

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



[issue25738] http.server doesn't handle RESET CONTENT status correctly

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

I left some comments about the tangential changes on Git Hub.

Can you write a test case for this?

--
nosy: +martin.panter
stage:  -> patch review
type:  -> behavior

___
Python tracker 

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



[issue25739] Add PAYLOAD_TOO_LARGE / URI_TOO_LONG (new name in RFC 7231)

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

In general, I’m not sure it is worth adding aliases for various names used in 
different RFCs. But you could argue that this is appropriate because the old 
names are unnecessarily long. Another example would be 
HTTPStatus.REQUESTED_RANGE_NOT_SATISFIABLE vs “Range Not Satisfiable” 
.

If we were to go ahead with this, it would need a documentation update. A test 
case would also be nice, ensuring that the new name is the “one true” name, and 
the old name is an alias.

--
nosy: +martin.panter
stage:  -> patch review
type:  -> enhancement
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



[issue25739] Add PAYLOAD_TOO_LARGE / URI_TOO_LONG (new name in RFC 7231)

2015-11-26 Thread SpaceOne

SpaceOne added the comment:

Also URI_TOO_LONG has been changed.

https://tools.ietf.org/html/rfc7231#section-6.5.11
https://tools.ietf.org/html/rfc7231#section-6.5.12

--
title: Add PAYLOAD_TOO_LARGE (new name in RFC 7231) -> Add PAYLOAD_TOO_LARGE / 
URI_TOO_LONG (new name in RFC 7231)

___
Python tracker 

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



[issue25740] multiple issues in http.client

2015-11-26 Thread SpaceOne

New submission from SpaceOne:

* RESET_CONTENT not evaluated
* negative chunk size accepted
* invalid ports accepted
* success status !== 200 ignored

Patch: 
https://github.com/spaceone/cpython/commit/3289080306408db971f8b816d3e9f0ab44ed392b

Part of github Pull Request https://github.com/python/cpython/pull/19 from 
July. Should I split this up into multiple bugtracker issues?

--
components: Library (Lib)
messages: 255445
nosy: spaceone
priority: normal
severity: normal
status: open
title: multiple issues in http.client

___
Python tracker 

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



[issue25739] Add PAYLOAD_TOO_LARGE (new name in RFC 7231)

2015-11-26 Thread SpaceOne

New submission from SpaceOne:

Add PAYLOAD_TOO_LARGE status code to http package.
Patch: 
https://github.com/spaceone/cpython/commit/5d9427a07bde43b523386322b1fc377618eadb76

--
components: Library (Lib)
messages: 255444
nosy: spaceone
priority: normal
severity: normal
status: open
title: Add PAYLOAD_TOO_LARGE (new name in RFC 7231)

___
Python tracker 

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



[issue25738] http.server doesn't handle RESET CONTENT status correctly

2015-11-26 Thread SpaceOne

New submission from SpaceOne:

The status 205 RESET CONTENT is not correctly evaluated by http.server.
It MUST NOT write a response body to the client.
 
Patch: 
https://github.com/spaceone/cpython/commit/17048e2e7349cc4861c7fe90299f2c092b8e1604

--
components: Library (Lib)
messages: 255443
nosy: spaceone
priority: normal
severity: normal
status: open
title: http.server doesn't handle RESET CONTENT status correctly

___
Python tracker 

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



[issue25723] ConfigParser should never write broken configurations

2015-11-26 Thread SpaceOne

SpaceOne added the comment:

Of course both of you have reasonable arguments.
For compatibility with overridden SECTRE attributes it should not raise 
ValueError for characters like [ and ]. (too bad that SECTRE is a public 
attribute otherwise it could also be used to validate the name 
(SECTRE.match('[%s]')). What if somebody changed SECTRE to multiline? Then even 
rejecting '\n' would break compatibility.
But: How often does this happen? In open source projects it seems none. A 
nullege.com and google search exposed that no project does this.

Terry, I completely agree with your argument "that blindly inserting external 
input into a database is bad idea". But in the real world it happens that there 
are many applications out which doesn't validate what they pass into 
.add_section(). (Do you want me to give you a list of python projects which are 
either broken or vulnerable?). In my opinion this is dangerous, as well as not 
validating HTTP/Mail/MIME headers for such characters and so on.
What's the goal of python here? Giving programmers nice utilities which have 
security considerations in its software design by default or giving everything 
up to the programmer which is forced to never trust the stdlib and always have 
to read the source code it uses?

As I understand when I read the documentation is that config parser is loosely 
based on M$ INI files and as the name says it is for configuration files. 
Usually(!) configuration files are human readable files editable with an 
editor. Disallowing non-printable characters would have been the best option in 
the first release of config parser.
>From my experience it is good to restrict things from the beginning and make 
>them overrideable to be more relaxed if this is really needed.

And regarding issue20923: I think it would be a great feature to include the 
code change instead of changing the documentation. In my research about 
add_section() I found some projects which uses URI's as section name. As you 
know the WWW is evolving and actually http://[::1]/ is a valid URI nowadays. If 
this would be changed these implementations will not have to overwrite SECTRE 
in the future and they also won't run into that bug one day.

I adapted my commit to only disallow \r \n and \x00. [ ] are allowed for 
customization of SECTRE.
https://github.com/spaceone/cpython/commit/a0cdb85e4c7c4dd71a87b1f6c4d9d92ece2dde15

--

___
Python tracker 

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



[issue25464] Tix HList header_exists should be "exist"

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
assignee:  -> serhiy.storchaka

___
Python tracker 

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



[issue24960] Can't use pip or easy_install with embeddable zip file.

2015-11-26 Thread Florian Hassanen

Florian Hassanen added the comment:

got this traceback:

Traceback (most recent call last):
  File "setup.py", line 169, in 
dist = setuptools.setup(**setup_params)
  File "distutils\core.py", line 134, in setup
  File "...\setuptools\setuptools\dist.py", line 299, in parse_command_line
result = _Distribution.parse_command_line(self)
  File "distutils\dist.py", line 469, in parse_command_line
  File "...\setuptools\setuptools\dist.py", line 679, in handle_display_options
return _Distribution.handle_display_options(self, option_order)
  File "distutils\dist.py", line 672, in handle_display_options
  File "...\setuptools\setuptools\dist.py", line 439, in print_commands
cmdclass = ep.resolve()
  File "...\setuptools\pkg_resources\__init__.py", line 2383, in resolve
module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "...\setuptools\setuptools\command\build_py.py", line 10, in 
from setuptools.lib2to3_ex import Mixin2to3
  File "...\setuptools\setuptools\lib2to3_ex.py", line 12, in 
from lib2to3.refactor import RefactoringTool, get_fixers_from_package
  File "", line 969, in _find_and_load
  File "", line 958, in _find_and_load_unlocked
  File "", line 664, in _load_unlocked
  File "", line 634, in _load_backward_compatible
  File "lib2to3\refactor.py", line 27, in 
  File "", line 969, in _find_and_load
  File "", line 958, in _find_and_load_unlocked
  File "", line 664, in _load_unlocked
  File "", line 634, in _load_backward_compatible
  File "lib2to3\fixer_util.py", line 9, in 
  File "", line 969, in _find_and_load
  File "", line 958, in _find_and_load_unlocked
  File "", line 664, in _load_unlocked
  File "", line 634, in _load_backward_compatible
  File "lib2to3\pygram.py", line 32, in 
  File "lib2to3\pgen2\driver.py", line 121, in load_grammar
  File "lib2to3\pgen2\pgen.py", line 385, in generate_grammar
  File "lib2to3\pgen2\pgen.py", line 15, in __init__
FileNotFoundError: [Errno 2] No such file or directory: 
'...\\python-3.5.0-embed-amd64\\python35.zip\\lib2to3\\Grammar.txt'


triggered e.g. by "python setup.py --help-commands" (when building setuptools)

workaround is to extract "...\python-3.5.0-embed-amd64\python35.zip" into a 
__directory__ named exactly the same (hence a directory named "python35.zip" 
which replaces the original zip file)

--
nosy: +Florian Hassanen

___
Python tracker 

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



[issue22233] http.client splits headers on non-\r\n characters

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

For the record, this is a simplified version of the original scenario, showing 
the low-level HTTP protocol:

>>> request = (
... b"GET /%C4%85 HTTP/1.1\r\n"
... b"Host: graph.facebook.com\r\n"
... b"\r\n"
... )
>>> s = create_connection(("graph.facebook.com", HTTPS_PORT))
>>> with ssl.wrap_socket(s) as s:
... s.sendall(request)
... response = s.recv(3000)
... 
50
>>> pprint(response.splitlines(keepends=True))
[b'HTTP/1.1 404 Not Found\r\n',
 b'WWW-Authenticate: OAuth "Facebook Platform" "not_found" "(#803) Some of the '
 b'aliases you requested do not exist: \xc4\x85"\r\n',
 b'Access-Control-Allow-Origin: *\r\n',
 b'Content-Type: text/javascript; charset=UTF-8\r\n',
 b'X-FB-Trace-ID: H9yxnVcQFuA\r\n',
 b'X-FB-Rev: 2063232\r\n',
 b'Pragma: no-cache\r\n',
 b'Cache-Control: no-store\r\n',
 b'Facebook-API-Version: v2.0\r\n',
 b'Expires: Sat, 01 Jan 2000 00:00:00 GMT\r\n',
 b'X-FB-Debug: 07ouxMl1Z439Ke/YzHSjXx3o9PcpGeZBFS7yrGwTzaaudrZWe5Ef8Z96oSo2dINp'
 b'3GR4q78+1oHDX2pUF2ky1A==\r\n',
 b'Date: Thu, 26 Nov 2015 23:03:47 GMT\r\n',
 b'Connection: keep-alive\r\n',
 b'Content-Length: 147\r\n',
 b'\r\n',
 b'{"error":{"message":"(#803) Some of the aliases you requested do not exist: '
 b'\\u0105","type":"OAuthException","code":803,"fbtrace_id":"H9yxnVcQFuA"}}']

In my mind, the simplest way forward would be to change the “email” module to 
only parse lines using the “universal newlines” algorithm. The 
/Lib/email/feedparser.py module should use StringIO(s, newline="").readlines() 
rather than s.splitlines(keepends=True). That would mean all email parsing 
behaviour would change; for instance, given the following message:

>>> m = email.message_from_string(
... "WWW-Authenticate: abc\x85\r\n"
... "\r\n"
... )

instead of the current behaviour:

>>> m.items()
[('WWW-Authenticate', 'abc\x85')]
>>> m.get_payload()
'\r\n\r\n'

it would change to:

>>> m.items()
[('WWW-Authenticate', 'abc\x85')]
>>> m.get_payload()
''

--

___
Python tracker 

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



[issue4712] Document pickle behavior for subclasses of dicts/lists

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
nosy: +alexandre.vassalotti, pitrou

___
Python tracker 

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



[issue4712] Document pickle behavior for subclasses of dicts/lists

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

The order in copy was changed by issue1100562.

--

___
Python tracker 

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



[issue1100562] deepcopying listlike and dictlike objects

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Note that this change added discrepancy between pickle and copy modules and 
broke deepcopying of minidom documents (issue10131).

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue10131] deepcopying an xml.dom.minidom.Document generates an invalid XML document

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> fixed
stage: test needed -> 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



[issue10131] deepcopying an xml.dom.minidom.Document generates an invalid XML document

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Thank you Marian for your patch. Committed modified patch with tests. For 
compatibility with data pickled by unpatched Python we have to keep 
__setstate__.

The discrepancy between pickle and copy module is different not easy issue.

--

___
Python tracker 

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



[issue10131] deepcopying an xml.dom.minidom.Document generates an invalid XML document

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 0eea57ddb75f by Serhiy Storchaka in branch '2.7':
Issue #10131: Fixed deep copying of minidom documents.  Based on patch
https://hg.python.org/cpython/rev/0eea57ddb75f

New changeset aa304ad32292 by Serhiy Storchaka in branch '3.4':
Issue #10131: Fixed deep copying of minidom documents.  Based on patch
https://hg.python.org/cpython/rev/aa304ad32292

New changeset 5d6b2dc7e3d0 by Serhiy Storchaka in branch '3.5':
Issue #10131: Fixed deep copying of minidom documents.  Based on patch
https://hg.python.org/cpython/rev/5d6b2dc7e3d0

New changeset 9fcfdb53e8af by Serhiy Storchaka in branch 'default':
Issue #10131: Fixed deep copying of minidom documents.  Based on patch
https://hg.python.org/cpython/rev/9fcfdb53e8af

--
nosy: +python-dev

___
Python tracker 

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



[issue25677] Syntax error caret confused by indentation

2015-11-26 Thread Martin Panter

Changes by Martin Panter :


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



[issue25677] Syntax error caret confused by indentation

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

Michael, see the review comments if you already haven’t. There is an unused 
variable “p” in the last two patches.

--

___
Python tracker 

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



[issue10131] deepcopying an xml.dom.minidom.Document generates an invalid XML document

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
assignee:  -> serhiy.storchaka
nosy: +alexandre.vassalotti, pitrou, serhiy.storchaka
versions: +Python 3.4, Python 3.5, Python 3.6 -Python 3.2, Python 3.3
Added file: http://bugs.python.org/file41170/copying_NodeList.patch

___
Python tracker 

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



[issue4712] Document pickle behavior for subclasses of dicts/lists

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

The copy module uses the same __reduce__ protocol, but reconstruct the object 
in different order, first set state, then add items. This discrepancy causes a 
difference between results of pickle/unpickle and copy operations. Example:

>>> class L(list):
... def __getstate__(self):
... return list(self)
... def __setstate__(self, state):
... self[:] = state
... 
>>> import copy, pickle
>>> pickle.loads(pickle.dumps(L([1, 2])))
[1, 2]
>>> copy.deepcopy(L([1, 2]))
[1, 2, 1, 2]

This was happened with xml.dom.minicompat.NodeList (issue10131).

Definitely one of pickle's or copy's behavior should be changed. But what?

--
nosy: +serhiy.storchaka
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



[issue18911] minidom does not encode correctly when calling Document.writexml

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
keywords: +easy
stage:  -> needs patch
versions: +Python 3.5, Python 3.6 -Python 3.3

___
Python tracker 

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



[issue25736] smtplib can't send 8bit encoded utf-8 message

2015-11-26 Thread Ervin Hegedüs

Ervin Hegedüs added the comment:

David,

many thanks for your information.

I think my e-mail format was correct - I've copied it from a maildir, as an 
"email file".

As I wrote, there is a solution: before the code passes the 'msg' argument to 
sendmail() function, it needs to encode() it as "utf-8", then it will be a 
bytestream, instead of unicode (which is the default type of any string in 
Py3). Meanwhile I realized it :).

Thanks again, and sorry for my mistake.

--

___
Python tracker 

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



[issue25194] Opt-in motivations & affiliations page for core contributors

2015-11-26 Thread R. David Murray

R. David Murray added the comment:

As I finalized my entry it occurred to me that in fact the PSF has expressed 
willingness to pay me for some contract work around the tracker, but I haven't 
managed to make the proposal yet.  The good news in that is that in fact I have 
a good bit of open source work filling my schedule right now...

--

___
Python tracker 

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



[issue25106] Hash computation speedup for {buffer, string, unicode}object

2015-11-26 Thread Gregory P. Smith

Gregory P. Smith added the comment:

Reopen this if you find a reproducible way for this patch to prove useful.

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

___
Python tracker 

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



[issue23513] Add support for classes/object model in multiprocessing/pickle

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Support of pickling nested classes and methods with all protocols was added in 
issue23611.

--
resolution:  -> out of date
stage:  -> resolved
status: pending -> closed

___
Python tracker 

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



[issue25194] Opt-in motivations & affiliations page for core contributors

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset b360bad24805 by R David Murray in branch 'default':
#25194: add my entry to 'motivations'.
https://hg.python.org/devguide/rev/b360bad24805

New changeset 2d4907e5b51c by R David Murray in branch 'default':
#25194: Fix indentation in Nick's entry.
https://hg.python.org/devguide/rev/2d4907e5b51c

--

___
Python tracker 

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



[issue11872] cPickle gives strange error for large objects.

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> out of date
stage: needs patch -> resolved
status: pending -> closed

___
Python tracker 

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



[issue12340] Access violation when using the C version of the io module

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> out of date
stage:  -> resolved
status: pending -> closed

___
Python tracker 

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



[issue25106] Hash computation speedup for {buffer, string, unicode}object

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Ping.

--
status: pending -> open

___
Python tracker 

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



[issue25040] xml.sax.make_parser makes bad use of parser_list argument default value

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> not a bug
stage:  -> resolved
status: pending -> closed

___
Python tracker 

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



[issue8426] multiprocessing.Queue fails to get() very large objects

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> not a bug
stage:  -> resolved
status: pending -> closed

___
Python tracker 

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



[issue15504] pickle/cPickle saves invalid/incomplete data

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> out of date
stage:  -> resolved
status: pending -> closed

___
Python tracker 

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



[issue24858] python3 -m test -ugui -v test_tk gives 3 failures under Debian unstable (sid)

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> third party
stage:  -> resolved
status: pending -> closed

___
Python tracker 

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



[issue10942] xml.etree.ElementTree.tostring returns type bytes, expected type str

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> out of date
stage: needs patch -> resolved
status: pending -> closed

___
Python tracker 

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



[issue13275] Recommend xml.etree for XML processing

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


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



[issue14988] _elementtree: Raise ImportError when importing of pyexpat fails

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> fixed
stage: test needed -> resolved
status: pending -> closed

___
Python tracker 

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



[issue25730] invisible sidebar content with code snippets

2015-11-26 Thread R. David Murray

R. David Murray added the comment:

Ah, I see what you mean.  It's still tricky for web stuff, though, because what 
you see can completely depend on things like window size and browser version.  
So a detailed description of how to produce the error would be good, and we'll 
see if we actually can :)

--

___
Python tracker 

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



[issue25736] smtplib can't send 8bit encoded utf-8 message

2015-11-26 Thread R. David Murray

R. David Murray added the comment:

Oh, and as for why this worked in python2: in python2 strings were binary, not 
unicode, so the non-ascii stuff was already in bytes form.

--

___
Python tracker 

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



[issue25736] smtplib can't send 8bit encoded utf-8 message

2015-11-26 Thread R. David Murray

R. David Murray added the comment:

Although that will work for text-only messages if you know what RFC format 
looks like, you really don't want to do that in the general case, since you 
can't express messages that have binary non-text content using unicode.  What 
you want to do is prepare your message in correct RFC form, which is what the 
email library is for.  With the new API (provisional now, but any changes will 
be minor when it becomes final in 3.6), this is even easy (see the 
'contentmanager' docs).  Then you call smtplib.send_message, and the encoding 
to RFC format is taken care of for you.  In 3.5 it even supports SMTPUTF8, if 
you know any servers that do :)

--
nosy: +r.david.murray
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



[issue25723] ConfigParser should never write broken configurations

2015-11-26 Thread R. David Murray

R. David Murray added the comment:

I view this as similar to the corresponding issue with email headers, where we 
fixed a similar security issue.  The special danger of \n is that it allows you 
to create a *new* header, or in this case section, with an arbitrary value, 
possibly overriding an existing section and thus changing the behavior of the 
program in an exploitable way.  This is *far* easier to exploit than the 
ability to introduce arbitrary data into the section name itself.  Good 
security involves concentric rings of defense, and one should almost always be 
more secure by default when it has a small usability impact.  In this case, 
there is no legitimate use for \n in a section name, so the only usability 
impact would be if some weird program out there was actually making use of this 
for some reason, against all reasonable logic :).  Which is why we are 
suggesting changing it only in 3.6.

\x00 is problematic (though somewhat less so) for the same reason, as many file 
readers will treat it as equivalent to end of line and allow a similar exploit. 
 \r, \f, and \x1c-\x1e should also be blocked, but otherwise we should probably 
ignore non-printables for backward compatibility reasons (there we move further 
into the usability impact area).

--

___
Python tracker 

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



[issue25528] Attempt to further increase test coverage of calendar module

2015-11-26 Thread Stéphane Wirtel

Stéphane Wirtel added the comment:

Sure,

But the patch is correct.

Now, you are right, we have to ask him a new patch where the function is really 
tested.

--

___
Python tracker 

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



[issue13330] Attempt full test coverage of LocaleTextCalendar.formatweekday

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

And it looks that only empty locale works on Windows (issue21731).

--

___
Python tracker 

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



[issue12568] Add functions to get the width in columns of a character

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I think this function would be very useful in many parts of interpreter core 
and standard library. From displaying tracebacks to formatting helps.

Otherwise we are doomed to implement imperfect variants in multiple places.

--
resolution: out of date -> 
status: closed -> open
versions: +Python 3.6 -Python 3.3

___
Python tracker 

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



[issue25730] invisible sidebar content with code snippets

2015-11-26 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I intentionally said 'test' rather than 'unittest' or 'automated test' to allow 
for the possibility of a human-operated view test script posted here on the 
issue.  

IDLE now has a view test framework to run tests for either one or all modules 
with visual displays.  For all:
  python -m idlelib.idle_test.htest
This has been very useful when modifying files.

--

___
Python tracker 

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



[issue13330] Attempt full test coverage of LocaleTextCalendar.formatweekday

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

The test depends on the en_US locale. Only existing of POSIX locale is 
guarantied. The test should be skipped instead of failed if the en_US locale is 
not available. It would be nice to test also with other locales. For example 
with de_DE, fr_FR, tr_TR, ps_AF - these locales are used also in other tests.

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue25677] Syntax error caret confused by indentation

2015-11-26 Thread Michael Layzell

Michael Layzell added the comment:

Martin's solution seemed like the least work, so that's what I ended up using. 
I also switched over to assertRegex, and I agree that it produces better error 
messages.

I added a comment to explain the use of the ugly multiline regex, and removed 
some of its unnecessary parts.

--
Added file: http://bugs.python.org/file41169/cpython25677.patch

___
Python tracker 

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



[issue25528] Attempt to further increase test coverage of calendar module

2015-11-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

The problem with Rohit's patch is that it throws out existing test case.

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue25528] Attempt to further increase test coverage of calendar module

2015-11-26 Thread Stéphane Wirtel

Stéphane Wirtel added the comment:

no problem about the second patch of Rohit.

pass the test with default and I have tested the code in the REPL.

--
nosy: +matrixise

___
Python tracker 

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



[issue25737] array is not a Sequence

2015-11-26 Thread Eryk Sun

Eryk Sun added the comment:

This is a duplicate of issue 23864, i.e. only the "one-trick ponies" work:

>>> issubclass(array.array, abc.Sized)
True
>>> issubclass(array.array, abc.Iterable)
True
>>> issubclass(array.array, abc.Container)
True

--
nosy: +eryksun
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> issubclass without registration only works for "one-trick pony" 
collections ABCs.

___
Python tracker 

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



[issue25737] array is not a Sequence

2015-11-26 Thread berdario

berdario added the comment:

Ok, basically `Sequence` does not implement `__subclasshook__` and is manually 
hardcoded to

```
Sequence.register(tuple)
Sequence.register(str)
Sequence.register(range)
Sequence.register(memoryview)
```


This is not by design, is it?

--

___
Python tracker 

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



[issue25737] array is not a Sequence

2015-11-26 Thread Ezio Melotti

Changes by Ezio Melotti :


--
nosy: +ezio.melotti, rhettinger, stutzbach
type:  -> behavior

___
Python tracker 

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



[issue25737] array is not a Sequence

2015-11-26 Thread berdario

New submission from berdario:

>>> from array import array
>>> from collections.abc import Sequence
>>> isinstance(array('I', [1]), Sequence)
False

--
components: Interpreter Core
messages: 255413
nosy: berdario
priority: normal
severity: normal
status: open
title: array is not a Sequence
versions: Python 3.5

___
Python tracker 

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



[issue25622] Enable ctypes.test.test_values.Win_ValuesTestCase for non-Windows

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

The buildbots don’t seem to be having any troubles with test_ctypes, so I 
assume my change is good.

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



[issue21668] The select and time modules uses libm functions without linking against it

2015-11-26 Thread Chi Hsuan Yen

Chi Hsuan Yen added the comment:

Well, the hg revision of Python in two tests are different, because I `hg pull 
-u` each time I build.

--

___
Python tracker 

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



[issue21668] The select and time modules uses libm functions without linking against it

2015-11-26 Thread Chi Hsuan Yen

Chi Hsuan Yen added the comment:

Bump. For rev c6930661599b timemodule.c and selectmodule.c no longer calls libm 
functions, while audioop.c and _ctypes_test.c still do. I have my updated patch 
here based on previous patches. Note that the introduction of 
detect_math_libs() is my naive try. Its naming and position in setup.py may 
need more consideration.

Here's the result before and after my patch.

Before:
shell@GT-N7000:/data/local/tmp $ python3
Python 3.6.0a0 (default:6a8fbb97c8d8+, Nov 26 2015, 18:42:29) 
[GCC 4.9 20140827 (prerelease)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import select 
>>> import time
>>> import audioop
Traceback (most recent call last):
  File "", line 1, in 
ImportError: dlopen failed: cannot locate symbol "floor" referenced by 
"audioop.cpython-36m-arm-linux-gnueabi.so"...
>>> import _ctypes_test
Traceback (most recent call last):
  File "", line 1, in 
ImportError: dlopen failed: cannot locate symbol "sqrt" referenced by 
"_ctypes_test.cpython-36m-arm-linux-gnueabi.so"...
>>> 

After:

shell@GT-N7000:/data/local/tmp $ python3
Python 3.6.0a0 (default:c6930661599b+, Nov 26 2015, 19:10:15) 
[GCC 4.9 20140827 (prerelease)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import time
>>> import selectr
Traceback (most recent call last):
  File "", line 1, in 
ImportError: No module named 'selectr'
>>> import select 
>>> import audioop
>>> import _ctypes_test
>>> 

Tested on Samsung Galaxy Note GT-N7000 with my custom build of CyanogenMod 11.0

--
nosy: +Chi Hsuan Yen
Added file: http://bugs.python.org/file41168/python-hg-modules-link-libm.patch

___
Python tracker 

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



[issue25622] Enable ctypes.test.test_values.Win_ValuesTestCase for non-Windows

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 7b12b04f4f18 by Martin Panter in branch '2.7':
Issue #25622: Rename to PythonValuesTestCase and enable for non-Windows
https://hg.python.org/cpython/rev/7b12b04f4f18

--

___
Python tracker 

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



[issue22989] HTTPResponse.msg not as documented

2015-11-26 Thread Martin Panter

Martin Panter added the comment:

The documentation now mentions the “msg” quirk and the info() method.

--
resolution:  -> fixed
stage:  -> resolved
status: open -> closed
versions: +Python 3.5, Python 3.6

___
Python tracker 

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



[issue21228] Missing enumeration of HTTPResponse Objects methods of urllib.request.urlopen's http.client.HTTPResponse?

2015-11-26 Thread Martin Panter

Changes by Martin Panter :


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



[issue21228] Missing enumeration of HTTPResponse Objects methods of urllib.request.urlopen's http.client.HTTPResponse?

2015-11-26 Thread Martin Panter

Changes by Martin Panter :


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



[issue22989] HTTPResponse.msg not as documented

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset fa3c9faabfb0 by Martin Panter in branch '3.4':
Issues #22989, #21228: Document HTTP response object for urlopen()
https://hg.python.org/cpython/rev/fa3c9faabfb0

New changeset b55c006b79bc by Martin Panter in branch '3.5':
Issue #22989, #21228: Merge urlopen() doc from 3.4 into 3.5
https://hg.python.org/cpython/rev/b55c006b79bc

New changeset c6930661599b by Martin Panter in branch 'default':
Issue #22989, #21228: Merge urlopen() doc from 3.5
https://hg.python.org/cpython/rev/c6930661599b

--
nosy: +python-dev

___
Python tracker 

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



[issue21228] Missing enumeration of HTTPResponse Objects methods of urllib.request.urlopen's http.client.HTTPResponse?

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset fa3c9faabfb0 by Martin Panter in branch '3.4':
Issues #22989, #21228: Document HTTP response object for urlopen()
https://hg.python.org/cpython/rev/fa3c9faabfb0

New changeset b55c006b79bc by Martin Panter in branch '3.5':
Issue #22989, #21228: Merge urlopen() doc from 3.4 into 3.5
https://hg.python.org/cpython/rev/b55c006b79bc

New changeset c6930661599b by Martin Panter in branch 'default':
Issue #22989, #21228: Merge urlopen() doc from 3.5
https://hg.python.org/cpython/rev/c6930661599b

--
nosy: +python-dev

___
Python tracker 

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



[issue25622] Enable ctypes.test.test_values.Win_ValuesTestCase for non-Windows

2015-11-26 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 0325eca1927e by Martin Panter in branch '3.4':
Issue #25622: Rename to PythonValuesTestCase and enable for non-Windows
https://hg.python.org/cpython/rev/0325eca1927e

New changeset 18a74ef65d3f by Martin Panter in branch '3.5':
Issue #25622: Merge ctypes test from 3.4 into 3.5
https://hg.python.org/cpython/rev/18a74ef65d3f

New changeset 38f749f0a1bd by Martin Panter in branch '3.5':
Issue #25622: Use repr(bytes) to avoid BytesWarning
https://hg.python.org/cpython/rev/38f749f0a1bd

--

___
Python tracker 

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



[issue25707] Add the close method for ElementTree.iterparse() object

2015-11-26 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
dependencies: +Verify the etree_parse and etree_iterparse benchmarks are 
working appropriately

___
Python tracker 

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



[issue25730] invisible sidebar content with code snippets

2015-11-26 Thread hiroaki itoh

hiroaki itoh added the comment:

Because there are a couple of ways (places) to fix this, I'll try them, so 
please wait. For testing, I think we can only visit all htmls manually and I'll 
make an effort.

--

___
Python tracker 

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



[issue25736] smtplib can't send 8bit encoded utf-8 message

2015-11-26 Thread Ervin Hegedüs

Ervin Hegedüs added the comment:

Here is a workaround:

server.sendmail(mailfrom, rcptto, msg.encode("utf8"))

May be this would be better inside of smtplib?

--

___
Python tracker 

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