[issue19553] PEP 453: "make install" and "make altinstall" integration

2013-11-22 Thread Ned Deily

Ned Deily added the comment:

The proposed patch with minor changes is now pushed.  I believe all of the 
review points have either been resolved or are covered by separate pip issues 
with the exception of item 8.  For item 6 (permissions not being forced), I 
decided that there are so many other files that are also not having permissions 
forced that it is silly to single out ensurepip.  Issue15890 should cover a 
comprehensive solution for all files.  In the meantime, the solution remains to 
set umask appropriately (e.g. 022) before running "make install" or "make 
altinstall".  I'm removing "release blocker" status and propose closing this 
issue once a decision about and/or home for item 8 is found.

--
priority: release blocker -> 
resolution:  -> fixed
stage: patch review -> committed/rejected
status: open -> pending

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Victor, you can propose whatever you like for 3.5, but I'm not adding new
interpreter state two days before feature freeze when we don't have to.
Looking up the private CodecInfo attribute is still O(1) anyway.

--

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Claudiu.Popa

Changes by Claudiu.Popa :


--
nosy: +Claudiu.Popa

___
Python tracker 

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



[issue17457] Unittest discover fails with namespace packages and builtin modules

2013-11-22 Thread Claudiu.Popa

Claudiu.Popa added the comment:

Hello! Attached patch which uses ModuleSpec, tested with 
http://hg.python.org/features/pep-451/ repo.

--
Added file: http://bugs.python.org/file32771/unittest_discovery_spec2.patch

___
Python tracker 

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



[issue19550] PEP 453: Windows installer integration

2013-11-22 Thread Ned Deily

Ned Deily added the comment:

If it is acceptable for the "Remove" option to be somewhat unpredictable in the 
case where pip or setuptools was already installed and not by the installer, 
would "python -m pip uninstall --yes pip setuptools" work?  If not, should a 
new issue be opened to find a solution?

--
nosy: +ned.deily

___
Python tracker 

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



[issue19599] Failure of test_async_timeout() of test_multiprocessing_spawn: TimeoutError not raised

2013-11-22 Thread Richard Oudkerk

Changes by Richard Oudkerk :


--
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue19550] PEP 453: Windows installer integration

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

I think "Off by default" is a reasonable solution for the beta (and
even 3.4 final), but a separate issue explaining *why* it's off by
default would be good. I can then ping the pip folks to ask for
suggestions - if they come up with something workable, we may be able
to have it turned on by default in 3.4 final.

--

___
Python tracker 

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



[issue19557] ast - docs for every node type are missing

2013-11-22 Thread anatoly techtonik

anatoly techtonik added the comment:

Neither you nor docs answer the question when Assign node gets Tuple as 
argument, when List and when Subscript.

While it is obvious to you, I personally don't know what a Subscript is. This 
is the kind of stuff that I'd like to see documented.

--

___
Python tracker 

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



[issue19555] "SO" config var not getting set

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

Test is failing on Windows:

http://buildbot.python.org/all/builders/x86%20Windows%20Server%202003%20%5BSB%5D%203.x/builds/1758/steps/test/logs/stdio

==
ERROR: test_SO_in_vars (test.test_sysconfig.TestSysConfig)
--
Traceback (most recent call last):
  File 
"E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\test_sysconfig.py",
 line 388, in test_SO_in_vars
self.assertIsNotNone(vars['SO'])
KeyError: 'SO'

==
FAIL: test_SO_value (test.test_sysconfig.TestSysConfig)
--
Traceback (most recent call last):
  File 
"E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\test_sysconfig.py",
 line 382, in test_SO_value
sysconfig.get_config_var('EXT_SUFFIX'))
AssertionError: None != '.pyd'

--
nosy: +haypo
resolution: fixed -> 
status: closed -> open

___
Python tracker 

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



[issue17134] Use Windows' certificate store for CA certs

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

The test is failing:

http://buildbot.python.org/all/builders/x86%20Windows%20Server%202003%20%5BSB%5D%203.x/builds/1758/steps/test/logs/stdio

==
FAIL: test_enum_certificates (test.test_ssl.BasicSocketTests)
--
Traceback (most recent call last):
  File 
"E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\test_ssl.py",
 line 553, in test_enum_certificates
self.assertIn(serverAuth, names)
AssertionError: '1.3.6.1.5.5.7.3.1' not found in {'1.3.6.1.5.5.7.3.3', 
'1.3.6.1.4.1.311.10.3.5', '2.16.840.1.113730.4.1', '2.16.840.1.113733.1.8.1'}

--

--
nosy: +haypo
resolution: fixed -> 
status: closed -> open

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

- switched to LookupError for the dedicated exception
- default value moved to a CodecInfo class attribute
- new private APIs guarded by PY_LIMITED_API
- used repr formatting where appropriate in the tests
- cleaned up the tests a bit by using encodings.normalize_encoding
- new test to ensure the codec output type checks are still exercised
- backwards compatibility tweaks for raw tuples returned from the codec 
registry lookup (uncovered by the full test suite run)

I'll be committing this version after a final local run of "make test" and a 
refleak check on test_codecs, test_charmapcodec and test_unicode (the latter 
two are the ones that found the backwards compatibility issue with the 
attribute lookup).

--
Added file: 
http://bugs.python.org/file32772/issue19619_blacklist_transforms_py34_postreview.diff

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Marc-Andre Lemburg

Marc-Andre Lemburg added the comment:

Nick: I've had a look at your second patch. A couple of notes:

 * I think you should add the flag to the constructor of the CodecInfo
   tuple subclass and then set this in the resp. codecs. The extra
   constructor class method looks too much like a hack and is
   not needed.

 * The comment in codecs.h should read:

   """
   Checks the encoding against a list of codecs which do not
   implement a str<->bytes encoding before attempting the
   operation.

   Please note that these APIs are internal and should not
   be used in Python C extensions.
   """

Regarding Victor's suggestion to use a separate registry dict
for this: I'm definitely -1 on this.

The black listing is a very special case only used for the
.encode()/.decode() methods and otherwise doesn't have anything to do
with the codecs sub-system. It doesn't make sense to change the design
of the registry just to implement this one special case.

--

___
Python tracker 

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



[issue19685] open() fails to autodetect utf-8 if LANG=C

2013-11-22 Thread Curtis Doty

New submission from Curtis Doty:

I first stumbled across this bug attempting to install use pip's cool editable 
mode:

$ pip install -e git+git://github.com/appliedsec/pygeoip.git#egg=pygeoip
Obtaining pygeoip from git+git://github.com/appliedsec/pygeoip.git#egg=pygeoip
  Cloning git://github.com/appliedsec/pygeoip.git to ./src/pygeoip
  Running setup.py egg_info for package pygeoip
Traceback (most recent call last):
  File "", line 16, in 
  File "/home/curtis/python/3.3.3/lib/python3.3/encodings/ascii.py", line 
26, in decode
return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1098: 
ordinal not in range(128)
Complete output from command python setup.py egg_info:
Traceback (most recent call last):

  File "", line 16, in 

  File "/home/curtis/python/3.3.3/lib/python3.3/encodings/ascii.py", line 26, 
in decode

return codecs.ascii_decode(input, self.errors)[0]

UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1098: 
ordinal not in range(128)


Cleaning up...
Command python setup.py egg_info failed with error code 1 in 
/home/curtis/python/2013-11-20/src/pygeoip
Storing complete log in /home/curtis/.pip/pip.log


It turns out this is related to a local LANG=C environment. If I set 
LANG=en_US.UTF-8, the problem goes away. But it seems pip/python3 open() should 
be more intelligently handling this.

Worse, the file in this case 
https://github.com/appliedsec/pygeoip/blob/master/setup.py already has a source 
code decorator *declaring* it as utf-8.

Ugly workaround patch is to force pip to always use 8-bit encoding on setup.py:

--- pip.orig/req.py 2013-11-19 15:53:49.0 -0800
+++ pip/req.py  2013-11-20 16:37:23.642656132 -0800
@@ -281,7 +281,7 @@ def replacement_run(self):
 writer(self, ep.name, os.path.join(self.egg_info,ep.name))
 self.find_sources()
 egg_info.egg_info.run = replacement_run
-exec(compile(open(__file__).read().replace('\\r\\n', '\\n'), __file__, 'exec'))
+exec(compile(open(__file__,encoding='utf_8').read().replace('\\r\\n', '\\n'), 
__file__, 'exec'))
 """
 
 def egg_info_data(self, filename):
@@ -687,7 +687,7 @@ exec(compile(open(__file__).read().repla
 ## FIXME: should we do --install-headers here too?
 call_subprocess(
 [sys.executable, '-c',
- "import setuptools; __file__=%r; 
exec(compile(open(__file__).read().replace('\\r\\n', '\\n'), __file__, 
'exec'))" % self.setup_py]
+ "import setuptools; __file__=%r; 
exec(compile(open(__file__,encoding='utf_8').read().replace('\\r\\n', '\\n'), 
__file__, 'exec'))" % self.setup_py]
 + list(global_options) + ['develop', '--no-deps'] + 
list(install_options),
 
 cwd=self.source_dir, filter_stdout=self._filter_install,


But that only treats the symptom. Root cause appears to be in python3 as 
demonstrated by this simple script:

wrong-codec.py:
#! /bin/env python3
from urllib.request import urlretrieve
urlretrieve('https://raw.github.com/appliedsec/pygeoip/master/setup.py', 
filename='setup.py')

# if LANC=C then locale.py:getpreferredencoding()->'ANSI_X3.4-1968'
foo= open('setup.py')

# bang! ascii_decode() cannot handle the unicode
bar= foo.read()


This does not occur in python2. Is this bug in pip or python3?

--
components: Unicode
messages: 203673
nosy: GreenKey, ezio.melotti, haypo
priority: normal
severity: normal
status: open
title: open() fails to autodetect utf-8 if LANG=C
type: crash
versions: Python 3.3

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Marc-Andre Lemburg

Marc-Andre Lemburg added the comment:

On 22.11.2013 12:24, Marc-Andre Lemburg wrote:
> 
> Nick: I've had a look at your second patch. A couple of notes:
> 
>  * I think you should add the flag to the constructor of the CodecInfo
>tuple subclass and then set this in the resp. codecs. The extra
>constructor class method looks too much like a hack and is
>not needed.

Like this:

_is_text_encoding = True # Assume codecs are text encodings by default

def __new__(cls, encode, decode, streamreader=None, streamwriter=None,
incrementalencoder=None, incrementaldecoder=None, name=None,
_is_text_encoding=None):
self = tuple.__new__(cls, (encode, decode, streamreader, streamwriter))
self.name = name
self.encode = encode
self.decode = decode
self.incrementalencoder = incrementalencoder
self.incrementaldecoder = incrementaldecoder
self.streamwriter = streamwriter
self.streamreader = streamreader
if _is_text_encoding is not None:
self._is_text_encoding = _is_text_encoding
return self

--

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

- switched the private flag from being set in a class method to using a keyword 
only parameter to __init__
- updated the codecs.h comment as MAL suggested

--
Added file: 
http://bugs.python.org/file32773/issue19619_blacklist_transforms_py34_keyword_only_param.diff

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

If _is_text_encoding may change in Python 3.5, you should add a comment to warn 
users to not use it and explain its purpose, maybe with a reference to this 
issue.

--

We have talking about a very few codecs:

* base64: bytes => bytes
* bz2: bytes => bytes
* hex: bytes => bytes; decode supports also ASCII string (str) => bytes
* quopri: bytes => bytes
* rot_13: str => str
* uu: bytes => bytes
* zlib: bytes => bytes

I suppose that supporting ASCII string input to the hex decoder is a border 
effect of its implementation. I don't know if it is expected *for the codec*.

If we simplify the hex decoder to reject str types, all these codecs would have 
simply one type: same input and output type. Anyway, if you want something 
based on types, the special case for the hex decoder cannot be expressed with a 
type nor ABC. "ASCII string" is not a type.

So instead of  _is_text_encoding=False could be transform=bytes or 
transform=str. (I don't care of the name: transform_type, type, codec_type, 
data_type, etc.)

I know that bytes is not exact: bytearray, memoryview and any bytes-like object 
is accepted, but it is a probably enough for now.

--

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Marc-Andre Lemburg

Marc-Andre Lemburg added the comment:

On 22.11.2013 12:43, STINNER Victor wrote:
> 
> STINNER Victor added the comment:
> 
> If _is_text_encoding may change in Python 3.5, you should add a comment to 
> warn users to not use it and explain its purpose, maybe with a reference to 
> this issue.

+1

> --
> 
> We have talking about a very few codecs:
> 
> * base64: bytes => bytes
> * bz2: bytes => bytes
> * hex: bytes => bytes; decode supports also ASCII string (str) => bytes
> * quopri: bytes => bytes
> * rot_13: str => str
> * uu: bytes => bytes
> * zlib: bytes => bytes
> 
> I suppose that supporting ASCII string input to the hex decoder is a border 
> effect of its implementation. I don't know if it is expected *for the codec*.
> 
> If we simplify the hex decoder to reject str types, all these codecs would 
> have simply one type: same input and output type. Anyway, if you want 
> something based on types, the special case for the hex decoder cannot be 
> expressed with a type nor ABC. "ASCII string" is not a type.
> 
> So instead of  _is_text_encoding=False could be transform=bytes or 
> transform=str. (I don't care of the name: transform_type, type, codec_type, 
> data_type, etc.)
> 
> I know that bytes is not exact: bytearray, memoryview and any bytes-like 
> object is accepted, but it is a probably enough for now.

I think it's better to go with something that's explicitly internal
now than to fix a public API in form of a constructor parameter
this late in the release process.

For 3.5 it may make sense to declare a few codec feature flags which
would then make lookups such as the one done for the blacklist easier
to implement and faster to check as well.

Such flags could provide introspection at a higher level than what
would be possible with type mappings (even though I still like the
idea of adding those to CodecInfo at some point).

One possible use for such flags would be to declare whether a
codec is reversible or not - in other words, whether .decode(.encode(x))
works for all possible inputs x. This flag could then be used to
quickly check whether a codec would fail on a Unicode str which
has non-Latin-1 code points or to create a list of valid encodings
for certain applications, e.g. a list which only contains reversible
Unicode encodings such as the UTF ones.

Anyway: Thanks to Nick for implementing this, to Serhiy for the black
list idea and Victor for the attribute idea :-)

--

___
Python tracker 

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



[issue19660] decorator syntax: allow testlist instead of just dotted_name

2013-11-22 Thread Eric V. Smith

Eric V. Smith added the comment:

While I think that the dotted_name restriction should be relaxed and it should 
instead be a style guide issue, I have to agree with Benjamin here: the 
difference in grammar complexity is zero and shouldn't drive the decision.

--

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

2013/11/22 Marc-Andre Lemburg :
> Anyway: Thanks to Nick for implementing this, to Serhiy for the black
> list idea and Victor for the attribute idea :-)

In fact, the attribute idea comes from you :-)
http://bugs.python.org/issue7475#msg96374

--

___
Python tracker 

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



[issue19686] possible unnecessary memoryview copies?

2013-11-22 Thread Stefan Krah

Stefan Krah added the comment:

David is correct:  No data is copied, but new memoryview objects with different 
shape and strides are created. That is relatively cheap.

--
nosy: +skrah
resolution:  -> invalid
stage:  -> committed/rejected
status: open -> closed
type: enhancement -> behavior

___
Python tracker 

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



[issue19553] PEP 453: "make install" and "make altinstall" integration

2013-11-22 Thread Donald Stufft

Donald Stufft added the comment:

I'm honestly not sure what to do about #8 on your list. It's sort of a really 
wierd edge case as far as pip is concerned right now because the support for 
the versioned commands and differing them is sort of a hack job while we wait 
for proper support from a PEP.

Probably long term wise once there's support for this in a PEP pip will gain 
some sort of regenerate scripts commands that could handle this case better.

I'm struggling to come up with a good solution in the interim though :(

--
status: pending -> open

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

It turns out the codec cache and the refleak hunting mechanism in regrtest 
*really* don't like each other if you use closures to implement your test 
codecs :)

Anyway, the attached patch tweaks the tests to handle refleak hunting (and 
running the refleak hunter indicates there aren't any leaks). I'll be 
committing this one immediately after posting this.

And like MAL, I'm keen to stick with a fully private API at this point, as I 
believe we need to get the status quo clearly documented before we can start 
talking about making changes to the public APIs.

I think both this issue and issue 7475 show that until we have a common 
understanding amongst the core development team of what's possible now, it's 
hard to discuss:

- what's currently possible that we would like to deprecate? (opinions differ 
strongly on this one - MAL and I think the status quo is mostly OK, but could 
use some better type inference support, Victor would like to see support for 
anything beyond text encodings, binary transforms and text transforms 
deprecated)
- what's not possible that we would like to make possible? (e.g. removing 
cached codecs, removing search functions, reordering search functions, type 
inference through the codec machinery)
- what's already possible that we would like to make easier? (e.g. registering 
new codecs)

--
Added file: 
http://bugs.python.org/file32774/issue19619_blacklist_transforms_py34_refleak_hunting.diff

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Well, that patch minus the debugging print that was still in there :)

--

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d68df99d7a57 by Nick Coghlan in branch 'default':
Issue #19619: Blacklist non-text codecs in method API
http://hg.python.org/cpython/rev/d68df99d7a57

--
nosy: +python-dev

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

3.4 has been dealt with. A similar functional patch should work in 3.3, but the 
test changes will be different (since those test cases don't exist yet in 3.3, 
and the wrapping ones aren't relevant at all).

--
versions:  -Python 3.4

___
Python tracker 

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



[issue7475] codecs missing: base64 bz2 hex zlib hex_codec ...

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

The 3.4 portion of issue 19619 has been addressed, so removing it as a 
dependency again.

--
dependencies:  -Blacklist base64, hex, ... codecs from bytes.decode() and 
str.encode()

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 1e3b8601b098 by Nick Coghlan in branch 'default':
Issue #19619: Update What's New for codec blacklist
http://hg.python.org/cpython/rev/1e3b8601b098

--

___
Python tracker 

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



[issue19685] pip: open() uses the locale encoding to parse Python script, instead of the encoding cookie

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Upstream: https://github.com/pypa/pip/pull/816

--
resolution:  -> invalid
stage:  -> committed/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



[issue17134] Use Windows' certificate store for CA certs

2013-11-22 Thread Christian Heimes

Christian Heimes added the comment:

That's strange. It looks like the Win2k box has no root CA certs for serverAuth 
installed whatsoever. I'm adding Matthias to this ticket.

--
nosy: +doko

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

The initial concern was a denial of service. Nick, can you backport your 
changeset to Python 3.3?

> This issue should avoid the denial of service attack when a compression codec 
> is used, see:
> https://mail.python.org/pipermail/python-dev/2013-November/130188.html

--

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

Can we now remove wrap_codec_error()? And maybe more changes which were done to 
workaround issues with non-Unicode codecs. bytes.decode/str.encode should no 
more raise a TypeError with codecs of the Python standard library.

Related changesets:


changeset:   87267:04e1f701aeaa
user:Nick Coghlan 
date:Tue Nov 19 22:33:10 2013 +1000
files:   Lib/test/test_codecs.py Objects/exceptions.c
description:
Also chain codec exceptions that allow weakrefs

The zlib and hex codecs throw custom exception types with
weakref support if the input type is valid, but the data
fails validation. Make sure the exception chaining in the
codec infrastructure can wrap those as well.


changeset:   87109:4ea622c085ca
user:Nick Coghlan 
date:Fri Nov 15 21:47:37 2013 +1000
files:   Lib/test/test_codecs.py Python/codecs.c
description:
Close 19609: narrow scope of codec exc chaining


changeset:   87084:854a2cea31b9
user:Nick Coghlan 
date:Wed Nov 13 23:49:21 2013 +1000
files:   Doc/whatsnew/3.4.rst Include/pyerrors.h Lib/test/test_codecs.py 
Misc/NEWS Objects/exceptions.c Objects/unicodeobject.c Python/codecs.c
description:
Close #17828: better handling of codec errors

- output type errors now redirect users to the type-neutral
  convenience functions in the codecs module
- stateless errors that occur during encoding and decoding
  will now be automatically wrapped in exceptions that give
  the name of the codec involved

--

___
Python tracker 

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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

> A few weeks ago I suggested the addition of
> ssl.create_default_context() to the stdlib. The patch implements my
> proposal. It replaces code in several of modules with one central
> function. The patch also removes ssl.wrap_socket() in favor for a
> SSLContext object.

Can you call it create_default_client_context() (a bit long) and/or
stress that it's for client use?

Or will it be ok for server purposes too, i.e. do you promise that it'll
never get CERT_REQUIRED by default?

--

___
Python tracker 

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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Christian Heimes

Christian Heimes added the comment:

Good point!

We need a purpose flag anyway in order to load the appropriate root CA certs. 
The purpose flag can be used for purpose-specific verify mode:

SERVER_AUTH = _ASN1Object('1.3.6.1.5.5.7.3.1')
CLIENT_AUTH = _ASN1Object('1.3.6.1.5.5.7.3.2')

if isinstance(purpose, str):
purpose = _ASN1Object.fromname(purpose)
if verify_mode is None:
if purpose == SERVER_AUTH:
# authenticate a TLS web server (for client sockets). The default 
# setting may change in the future.
verify_mode = CERT_NONE
elif purpose == CLIENT_AUTH:
# authenticate a TLS web client (for server sockets). The default
# setting is guaranteed to be stable and will never change.
verify_mode = CERT_NONE
else:
# other (code signing, S/MIME, IPSEC, ...), default may change.
verify_mode = CERT_NONE
context.verify_mode = verify_mode

--

___
Python tracker 

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



[issue19552] PEP 453: venv module and pyvenv integration

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Since ensurepip needs to manipulate sys.path, I ended up running the "-m 
ensurepip" using the venv Python in a subprocess. This both avoids side effects 
on the current process and gets ensurepip the right target directory settings 
automatically.

--
keywords: +patch
nosy: +dstufft, ned.deily, vinay.sajip
Added file: http://bugs.python.org/file32775/issue19552_venv_module_api.diff

___
Python tracker 

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



[issue19552] PEP 453: venv module and pyvenv integration

2013-11-22 Thread Donald Stufft

Donald Stufft added the comment:

That's similar to how virtualenv does it, so it's probably pretty reasonable.

--

___
Python tracker 

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



[issue19661] AIX: Python: RuntimeError "invalid slot offset when importing a module" in _ssl module

2013-11-22 Thread dellair jie

dellair jie added the comment:

Folks,

Is there a patch to apply on this, I tried to search online, found one similar 
post but was solved until the poster switched to another version of xlc. Do we 
need to use another compiler(I will have to build though)?

Please don't hesitate to contact me if further information is needed for 
analysis.

Thanks,

--

___
Python tracker 

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



[issue19691] Weird wording in RuntimeError doc

2013-11-22 Thread Antoine Pitrou

New submission from Antoine Pitrou:

The RuntimeError documentation has a strange sentence embedded in it:

"""This exception is mostly a relic from a previous version of the interpreter; 
it is not used very much any more"""

http://docs.python.org/dev/library/exceptions.html#RuntimeError

That's quite wrong. RuntimeError may not be raised inside the interpreter core, 
but it's raised by a bunch of stdlib modules.

--
assignee: docs@python
components: Documentation
messages: 203763
nosy: docs@python, neologix, pitrou
priority: normal
severity: normal
status: open
title: Weird wording in RuntimeError doc
type: behavior
versions: Python 2.7, 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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

> SERVER_AUTH = _ASN1Object('1.3.6.1.5.5.7.3.1')
> CLIENT_AUTH = _ASN1Object('1.3.6.1.5.5.7.3.2')

That's a bit ugly. How about an enum?

--

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread Antoine Pitrou

New submission from Antoine Pitrou:

Py_SAFE_DOWNCAST's name is a bit misleading: it isn't safe except in debug 
mode. I propose to rename it to Py_DOWNCAST, so that developers are reminded 
that the burden of the sanity checks is on them.

--
components: Interpreter Core
messages: 203764
nosy: christian.heimes, haypo, pitrou, tim.peters
priority: normal
severity: normal
status: open
title: Rename Py_SAFE_DOWNCAST
type: enhancement
versions: Python 3.4

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread Christian Heimes

Christian Heimes added the comment:

+1

--

___
Python tracker 

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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Christian Heimes

Christian Heimes added the comment:

In my opinion enums are for a closed batch of known entities. There are at 
least 20-30 purpose flags, maybe more. Everybody is allowed to define their own 
OIDs, too.

--

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

I like Py_DOWNCAST name.

--

___
Python tracker 

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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

> In my opinion enums are for a closed batch of known entities. There
> are at least 20-30 purpose flags, maybe more. Everybody is allowed to
> define their own OIDs, too.

Well, how many purposes are we going to expose? I don't think users
should know what ASN1 objects are, and a nice repr() is really useful.

(but there's no reason an enum cannot have 20 or 30 members)

--

___
Python tracker 

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



[issue19552] PEP 453: venv module and pyvenv integration

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 57fbab22ab4e by Nick Coghlan in branch 'default':
Close #19552: venv and pyvenv ensurepip integration
http://hg.python.org/cpython/rev/57fbab22ab4e

--
nosy: +python-dev
resolution:  -> fixed
stage: needs patch -> committed/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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Christian Heimes

Christian Heimes added the comment:

The objects already have a (more or less) nice representation:

>>> ssl._ASN1Object.fromname("1.3.6.1.5.5.7.3.1")
_ASN1Object(nid=129, shortname='serverAuth', longname='TLS Web Server 
Authentication', oid='1.3.6.1.5.5.7.3.1')
>>> ssl._ASN1Object.fromname("1.3.6.1.5.5.7.3.2")
_ASN1Object(nid=130, shortname='clientAuth', longname='TLS Web Client 
Authentication', oid='1.3.6.1.5.5.7.3.2')
>>> ssl._ASN1Object.fromname("1.3.6.1.5.5.7.3.8")
_ASN1Object(nid=133, shortname='timeStamping', longname='Time Stamping', 
oid='1.3.6.1.5.5.7.3.8')

--

___
Python tracker 

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



[issue19693] "make altinstall && make install" behaviour differs from "make install"

2013-11-22 Thread Nick Coghlan

New submission from Nick Coghlan:

>From issue #19553:

8. "make install" is a superset of "make altinstall" and one would expect the 
results of (a) "make install" to be the same as (b) "make altinstall && make 
install".  However (b) results in "python -m ensurepip --altinstall --upgrade 
&& python -m ensurepip --upgrade" which results in no unversioned pip files 
being installed as the second call to pip does nothing:

Requirement already up-to-date: setuptools in 
/py/dev/3x/root/uxd/lib/python3.4/site-packages
Requirement already up-to-date: pip in 
/py/dev/3x/root/uxd/lib/python3.4/site-packages

We may need some magic on the pip side when ENSUREPIP_OPTIONS is set to make 
this behave consistently.

--
components: Library (Lib)
messages: 203771
nosy: dstufft, larry, ncoghlan, ned.deily
priority: high
severity: normal
stage: needs patch
status: open
title: "make altinstall && make install" behaviour differs from "make install"
type: behavior
versions: Python 3.4

___
Python tracker 

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



[issue19347] PEP 453 implementation tracking issue

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Issue 19693 covers an anomaly where "make altinstall && make install" doesn't 
quite do the same thing as "make install" (the "pip3" script will be missing in 
the former case)

--

___
Python tracker 

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



[issue19553] PEP 453: "make install" and "make altinstall" integration

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

I moved the "make altinstall && make install" problem out to its own issue 
(issue 19693)

--
status: open -> closed

___
Python tracker 

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



[issue19407] PEP 453: update the "Installing Python Modules" documentation

2013-11-22 Thread Nick Coghlan

Changes by Nick Coghlan :


--
priority: release blocker -> deferred blocker

___
Python tracker 

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



[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-22 Thread Nick Coghlan

Changes by Nick Coghlan :


--
assignee:  -> ncoghlan

___
Python tracker 

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



[issue19689] ssl.create_default_context()

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Ok. Note that as long as they aren't actually passed to OpenSSL, they don't 
need to be ASN1 objects at all, i.e. if it's only a parameter to 
create_default_context(), it can perfectly well be a str or enum.

--

___
Python tracker 

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



[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d71251d9fbbe by Nick Coghlan in branch 'default':
Close #17916: dis.Bytecode based replacement for distb
http://hg.python.org/cpython/rev/d71251d9fbbe

--
nosy: +python-dev
resolution:  -> fixed
stage: needs patch -> committed/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



[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Thank you for the patch! It's nice to have this included for the initial 
general availability of the new disassembly API :)

--

___
Python tracker 

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



[issue19555] "SO" config var not getting set

2013-11-22 Thread Barry A. Warsaw

Changes by Barry A. Warsaw :


--
assignee:  -> barry

___
Python tracker 

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



[issue19669] remove mention of the old LaTeX docs

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Done in 33f58b469a4d (forgot to mention the issue id there).

--
resolution:  -> fixed
stage: needs patch -> committed/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



[issue19347] PEP 453 implementation tracking issue

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Issue 19694 is a new issue for one of the buildbots objecting to the new venv 
tests.

--

___
Python tracker 

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



[issue19694] test_venv failing on one of the Ubuntu buildbots

2013-11-22 Thread Nick Coghlan

New submission from Nick Coghlan:

pip still relies on imp (due to cross-version compatibility requirements), so 
it may trigger a pending deprecation warning, and potentially return a non-zero 
return code:

http://buildbot.python.org/all/builders/AMD64%20Ubuntu%20LTS%203.x/builds/3142/steps/test/logs/stdio

--
components: Library (Lib)
keywords: buildbot
messages: 203778
nosy: larry, ncoghlan
priority: release blocker
severity: normal
stage: needs patch
status: open
title: test_venv failing on one of the Ubuntu buildbots
type: behavior
versions: Python 3.4

___
Python tracker 

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



[issue19552] PEP 453: venv module and pyvenv integration

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Rather than reopening this (which is part of tracking the feature integration 
for the beta), I opened issue 19694 to cover the stable buildbot that is 
objecting to the new venv test (most of the others seem happy with it)

--

___
Python tracker 

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



[issue17134] Use Windows' certificate store for CA certs

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset de65df13ed50 by Christian Heimes in branch 'default':
Issue #17134: check certs of CA and ROOT system store
http://hg.python.org/cpython/rev/de65df13ed50

--

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Actually, _Py_DOWNCAST may be better (not a public API).

--

___
Python tracker 

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



[issue19695] Clarify how to use various import-related locks

2013-11-22 Thread Brett Cannon

New submission from Brett Cannon:

While working on the PEP 451 code I realized that the way we are handling the 
global import lock along with the per-module lock is a little ad-hoc. For 
instance, what are we wanting to use the global lock for these days? Mutations 
of anything off of sys? Reading anything from sys as well? Just to create the 
module-level locks?

And the per-module lock expects the global lock to be held already, but then 
does a release implicitly. That seems like the wrong way to structure the 
context managers; maybe pass in the lock global lock as proof it's being held? 
Or if we switch to much finer granularity for dealing with sys.modules 
(especially if it is only for mutation) then we can lock and unlock the global 
lock entirely within the per-module lock context manager.

At worst I think we should clearly document in the docstrings for the global 
and per-module context managers what we expect the lock to be used for and then 
really go through the import code to make sure we are holding it where we want 
but no more.

To start the conversation, I say the global lock is just to get the per-module 
locks. The per-module locks are held when finding/loading modules to prevent 
threading issues of requesting an incomplete module or thinking it isn't being 
imported when it actually is (which implicitly means holding it when 
accessing/mutating sys.modules for any module, e.g. trying to fetch a parent 
module).

--
components: Interpreter Core
messages: 203783
nosy: brett.cannon, eric.snow, ncoghlan, pitrou
priority: low
severity: normal
stage: needs patch
status: open
title: Clarify how to use various import-related locks
type: enhancement
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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

No, we can't remove wrap_codec_error, as it is still needed in order
to cover direct use of the codec machinery and to handle non-text
codecs registered by third parties (the tests cover both these cases).

--

___
Python tracker 

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



[issue19448] SSL: add OID / NID lookup

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 7d914d4b05fe by Christian Heimes in branch 'default':
Issue #19448: report name / NID in exception message of ASN1Object
http://hg.python.org/cpython/rev/7d914d4b05fe

--

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

> No, we can't remove wrap_codec_error, as it is still needed in order
> to cover direct use of the codec machinery and to handle non-text
> codecs registered by third parties (the tests cover both these cases)

I searched on the WWW for third party codecs, I only found Unicode encodings 
(str => bytes).

I don't think that we need all these tricks to provide more informations on 
transform codecs and transform codecs are not used.

--

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread Martin v . Löwis

Martin v. Löwis added the comment:

-1. The macro name doesn't claim the cast to be safe, i.e. it's not 
"Py_SAFELY_DOWNCAST", but "safe downcast", i.e. it's an assertion that the cast 
actually has been verified as being safe.

--
nosy: +loewis

___
Python tracker 

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



[issue19619] Blacklist base64, hex, ... codecs from bytes.decode() and str.encode()

2013-11-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Victor, the general purpose codec infrastructure is more than a decade
old, and supported in both Python 2 and Python 3, so you're not going
to get it deprecated in the last few days before the 3.4 feature
freeze. You've already succeeded in inconveniencing affected users
migrating from Python 2 for another release by blocking the
restoration of the transform codec aliases, but I'm definitely not
going to revert any of the other already implemented codec handling
improvements without a direct request from Larry as release manager or
Guido as BDFL.

If you propose a new codec architecture as a PEP for Python 3.5 and
get it accepted, then *that* would be the appropriate time to remove
these improvements to the existing architecture. Until such a PEP is
put forward and accepted, I will continue to work on documenting the
status quo as clearly as I can (especially since the only thing I see
wrong with it is the challenges it poses for type inference, and
that's a pretty minor gripe in a language as resistant to static
analysis as Python).

I've tried to persuade you that lowering the barriers to adoption for
Python 3 is a more significant concern than a mythical nirvana of
conceptual purity that *runs directly counter to the stated intent of
the creator of the current codec architecture*, but if you wish to
exercise your core developer veto and deliberately inconvenience
users, even though the original problems cited in issue 7475 have all
been addressed, that's your choice. Just don't expect me to try to
defend that decision to any users that complain, because I think it's
completely the wrong thing to do.

--

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

> -1. The macro name doesn't claim the cast to be safe, i.e. it's not
> "Py_SAFELY_DOWNCAST", but "safe downcast", i.e. it's an assertion that
> the cast actually has been verified as being safe.

It's not an assertion, it's a cast.
Otherwise it should be named Py_ASSERT_SAFE_DOWNCAST (and it should only
do the assertion, not the cast).

--

___
Python tracker 

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



[issue19692] Rename Py_SAFE_DOWNCAST

2013-11-22 Thread Tim Peters

Tim Peters added the comment:

Goodness.  Name it

_Py_DOWNCAST_AND_IN_DEBUG_MODE_ASSERT_UPCASTING_THE_RESULT_COMPARES_EQUAL_TO_THE_ORIGINAL_ARGUMENT

;-)

--

___
Python tracker 

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



[issue19673] PEP 428 implementation

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Updated patch addressing review comments.

--
nosy: +neologix

___
Python tracker 

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



[issue19673] PEP 428 implementation

2013-11-22 Thread Antoine Pitrou

Changes by Antoine Pitrou :


Added file: http://bugs.python.org/file32776/pathlib3.patch

___
Python tracker 

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



[issue19696] Merge all (non-syntactic) import-related tests into test_importlib

2013-11-22 Thread Brett Cannon

New submission from Brett Cannon:

E.g. test_namespace_pkgs should be under test_importlib and so should 
test_namespace_pkgs. test_import can conceivably stay out if it's updated to 
only contain syntactic tests for the import statement.

This is so that it's easier to run import-related tests when making changes to 
importlib (otherwise one has to run the whole test suite or memorize the name 
of every test suite related to import/importlib).

--
components: Tests
keywords: easy
messages: 203792
nosy: brett.cannon
priority: low
severity: normal
stage: needs patch
status: open
title: Merge all (non-syntactic) import-related tests into test_importlib
type: enhancement
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



[issue19555] "SO" config var not getting set

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 331b7a8bb830 by Barry Warsaw in branch 'default':
A fix for issue 19555 on Windows.
http://hg.python.org/cpython/rev/331b7a8bb830

--

___
Python tracker 

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



[issue19673] PEP 428 implementation

2013-11-22 Thread Antoine Pitrou

Changes by Antoine Pitrou :


Removed file: http://bugs.python.org/file32776/pathlib3.patch

___
Python tracker 

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



[issue19673] PEP 428 implementation

2013-11-22 Thread Antoine Pitrou

Changes by Antoine Pitrou :


Added file: http://bugs.python.org/file32777/pathlib3.patch

___
Python tracker 

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



[issue19555] "SO" config var not getting set

2013-11-22 Thread Barry A. Warsaw

Changes by Barry A. Warsaw :


--
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue19673] PEP 428 implementation

2013-11-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

I plan to commit soon, if there are no further comments.
Remember the pathlib API is provisional, so API changes can still be made later 
if deemed necessary.

--

___
Python tracker 

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



[issue19292] Make SSLContext.set_default_verify_paths() work on Windows

2013-11-22 Thread Guido van Rossum

Guido van Rossum added the comment:

So do you need anything on *this* issue?

(And are you asking me to review/approve the other issue? I haven't kept
track carefully enough for that, and the beta is looming.)

--

___
Python tracker 

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



[issue19697] refactor pythonrun.c to make use of specs (__main__.__spec__)

2013-11-22 Thread Brett Cannon

New submission from Brett Cannon:

So that e.g. __main__.__spec__.name is the actual name of the module being 
executed.

--
components: Interpreter Core
messages: 203796
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: test needed
status: open
title: refactor pythonrun.c to make use of specs (__main__.__spec__)
type: enhancement
versions: Python 3.4

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +refactor pythonrun.c to make use of specs (__main__.__spec__)

___
Python tracker 

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



[issue19698] Implement _imp.exec_builtin and exec_dynamic

2013-11-22 Thread Brett Cannon

New submission from Brett Cannon:

Since _imp.init_builtin and _imp.load_dynamic don't take in a module to load, 
need to create new functions which do. Afterwards can deprecate init_builtin, 
load_dynamic, and init_frozen (the latter having been worked around thanks to 
get_frozen_object).

--
components: Interpreter Core
messages: 203798
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: test needed
status: open
title: Implement _imp.exec_builtin and exec_dynamic
versions: Python 3.4

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Implement _imp.exec_builtin and exec_dynamic

___
Python tracker 

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



[issue19674] Add introspection information for builtins

2013-11-22 Thread Larry Hastings

Larry Hastings added the comment:

Anybody have a better name for __textsig__ ?

--

___
Python tracker 

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



[issue19699] Update zipimport for PEP 451

2013-11-22 Thread Brett Cannon

New submission from Brett Cannon:

Need to add find_spec and exec_module (or move over to a pure Python zipfile 
importer).

--
components: Library (Lib)
messages: 203799
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: test needed
status: open
title: Update zipimport for PEP 451
type: behavior
versions: Python 3.4

___
Python tracker 

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



[issue19700] Update runpy for PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
components: Library (Lib)
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: test needed
status: open
title: Update runpy for PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread STINNER Victor

STINNER Victor added the comment:

Your commit doesn't compile on Windows.

CategoryNone
Changed by  Eric Snow 
Changed at  Fri 22 Nov 2013 16:17:09
Branch  default
Revision07229c6104b16d0ab7cc63f3306157d3d2819fed
Comments

Implement PEP 451 (ModuleSpec).


http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%203.x/builds/3348/steps/compile/logs/stdio

--
nosy: +haypo

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Brett Cannon added the comment:

No longer blocking b1, now just blocking rc1.

--
dependencies: +Update zipimport for PEP 451
priority: release blocker -> deferred blocker

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Update runpy for PEP 451

___
Python tracker 

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



[issue19701] Update multiprocessing for PEP 451

2013-11-22 Thread Brett Cannon

New submission from Brett Cannon:

Specifically Lib/multiprocessing/spawn.py:import_main_path()

--
components: Library (Lib)
messages: 203802
nosy: brett.cannon
priority: normal
severity: normal
stage: test needed
status: open
title: Update multiprocessing for PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Update multiprocessing for PEP 451

___
Python tracker 

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



[issue19702] Update pickle to PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
components: Library (Lib)
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: test needed
status: open
title: Update pickle to PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue19703] Upate pydoc to PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
components: Library (Lib)
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
status: open
title: Upate pydoc to PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Upate pydoc to PEP 451, Update pickle to PEP 451

___
Python tracker 

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



[issue19704] Update test.test_threaded_import to PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
components: Tests
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: needs patch
status: open
title: Update test.test_threaded_import to PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Update test.test_threaded_import to PEP 451

___
Python tracker 

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



[issue19705] Update test.test_namespace_pkgs to PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
components: Tests
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
stage: needs patch
status: open
title: Update test.test_namespace_pkgs to PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue19673] PEP 428 implementation

2013-11-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 43377dcfb801 by Antoine Pitrou in branch 'default':
Issue #19673: Add pathlib to the stdlib as a provisional module (PEP 428).
http://hg.python.org/cpython/rev/43377dcfb801

--
nosy: +python-dev

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Update test.test_namespace_pkgs to PEP 451

___
Python tracker 

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



[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
dependencies: +Check if inspect needs updating for PEP 451

___
Python tracker 

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



[issue19706] Check if inspect needs updating for PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
status: open
title: Check if inspect needs updating for PEP 451
versions: Python 3.4

___
Python tracker 

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



[issue19707] Check if unittest.mock needs updating for PEP 451

2013-11-22 Thread Brett Cannon

Changes by Brett Cannon :


--
components: Library (Lib)
nosy: brett.cannon, eric.snow, ncoghlan
priority: normal
severity: normal
status: open
title: Check if unittest.mock needs updating for PEP 451
versions: Python 3.4

___
Python tracker 

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



  1   2   3   4   >