[issue10120] concurrent.futures module is not installed properly

2010-10-16 Thread Neil Muller

New submission from Neil Muller :

with make install (r85564), lib/python3.2/concurrent is created, but the 
futures module is not installed there. The attached trivial patch fixes this 
here.

--
files: futures-Makefile.diff
keywords: patch
messages: 118858
nosy: Neil Muller
priority: normal
severity: normal
status: open
title: concurrent.futures module is not installed properly
Added file: http://bugs.python.org/file19249/futures-Makefile.diff

___
Python tracker 

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



[issue10119] test_urllibnet failure when using support.transient_internet

2010-10-16 Thread Senthil Kumaran

Senthil Kumaran  added the comment:

Actually, this is not related to transient_internet call. Just that file handle 
not behaving as expected due to some delays.

--

___
Python tracker 

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



[issue10120] concurrent.futures module is not installed properly

2010-10-16 Thread Neil Muller

Neil Muller  added the comment:

There isn't an entry for anyone in maintainers.rst for concurrent.futures 
either. That should probably also be fixed.

--
nosy: +bquinlan

___
Python tracker 

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



[issue1343] XMLGenerator: nice elements

2010-10-16 Thread Neil Muller

Neil Muller  added the comment:

So what still needs to happen to get this in? 

Patch still applies to current python 3.2 trunk (r85564).

--

___
Python tracker 

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



[issue10120] concurrent.futures module is not installed properly

2010-10-16 Thread Brian Quinlan

Brian Quinlan  added the comment:

I added myself as the maintainer of concurrent.futures.

I'll look at the patch now.

--
assignee:  -> bquinlan

___
Python tracker 

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



[issue2775] Implement PEP 3108

2010-10-16 Thread Retro

Retro  added the comment:

My patch "zipfile-patch.diff" was sent to python-dev. Please act on it as you 
see fit. Thank you.

--

___
Python tracker 

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



[issue10120] concurrent.futures module is not installed properly

2010-10-16 Thread Brian Quinlan

Brian Quinlan  added the comment:

Patch committed in r85567.

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

___
Python tracker 

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



[issue10114] compile() doesn't support the PEP 383 (surrogates)

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

> Here is a new patch [code_encoding.patch] implementing this idea:
> - Use filesystem encoding (and surrogateescape) to encode/decode
> paths in compile() and the parser, instead of utf-8 in strict mode
> (...)
> The patch restores the situation before #6543.

About Python 3.1 compatibility: Python 3.1 doesn't support non-ascii paths with 
a locale different than utf-8 (see issue #8611), so it doesn't change anything 
for Python 3.1 (it doesn't work anyway, with utf-8 or filesystem encoding).

--

___
Python tracker 

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



[issue10114] compile() doesn't support the PEP 383 (surrogates)

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

Oh, I just realized that Python 3.1.2 (last Python 3.1 release) was released 
the 21st March, whereas r82063 (commit for #6543) was made the 17st June. So 
the encoding change was not released yet.

--

___
Python tracker 

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



[issue10121] test_multiprocessing stuck in test_make_pool if run in a loop

2010-10-16 Thread Sandro Tosi

New submission from Sandro Tosi :

Hello,
when trying to see if issue6661 was still valid, I run test_multiprocessing in 
a tight loop and I got it reproducibly stuck on test_make_pool:

...

test_imap_unordered (test.test_multiprocessing.WithManagerTestPool) ... ok
test_make_pool (test.test_multiprocessing.WithManagerTestPool) ... 

when I enter Ctrl+C here's the traceback (on 2.7 HEAD):

test_make_pool (test.test_multiprocessing.WithManagerTestPool) ... ^CProcess 
PoolWorker-5:3:
Traceback (most recent call last):
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
232, in _bootstrap
Process PoolWorker-5:2:
Traceback (most recent call last):
Process PoolWorker-5:4:
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
232, in _bootstrap
Traceback (most recent call last):
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
232, in _bootstrap
Process PoolWorker-5:1:
Traceback (most recent call last):
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
232, in _bootstrap
Process PoolWorker-79:
Process PoolWorker-80:
Traceback (most recent call last):
Traceback (most recent call last):
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
232, in _bootstrap
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
232, in _bootstrap
self.run()
self.run()
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
88, in run
  File 
"/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/process.py", line 
88, in run
self._target(*self._args, **self._kwargs)
self._target(*self._args, **self._kwargs)
  File "/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/pool.py", 
line 59, in worker
  File "/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/pool.py", 
line 59, in worker
task = get()
task = get()
  File "/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/queues.py", 
line 352, in get
  File "/home/morph/python-dev/release2.7-maint/Lib/multiprocessing/queues.py", 
line 350, in get

Test suite interrupted by signal SIGINT.
1 test omitted:
test_multiprocessing

and on py3k:

test_make_pool (test.test_multiprocessing.WithProcessesTestPool) ... ^CProcess 
PoolWorker-5:1:
Process PoolWorker-3:
Process PoolWorker-5:3:
Process PoolWorker-5:4:
Process PoolWorker-5:2:
Process PoolWorker-4:
Process PoolWorker-2:
Process PoolWorker-1:
Traceback (most recent call last):
Traceback (most recent call last):
Traceback (most recent call last):
Traceback (most recent call last):
Traceback (most recent call last):
Traceback (most recent call last):
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
Traceback (most recent call last):
Traceback (most recent call last):
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap
Process PoolWorker-29:
Traceback (most recent call last):
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 233, 
in _bootstrap

Test suite interrupted by signal SIGINT.
1 test omitted:
self.run()
self.run()
self.run()
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 88, 
in run
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 88, 
in run
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 88, 
in run
self._target(*self._args, **self._kwargs)
self._target(*self._args, **self._kwargs)
self._target(*self._args, **self._kwargs)
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/pool.py", line 59, in 
worker
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/pool.py", line 59, in 
worker
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/pool.py", line 59, in 
worker
self.run()
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 88, 
in run
self._target(*self._args, **self._kwargs)
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/pool.py", line 59, in 
worker
self.run()
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 88, 
in run
self.run()
  File "/home/morph/python-dev/py3k/Lib/multiprocessing/process.py", line 88, 
in run
self._target(*self._args, **self._kwargs)
  File "/home/morph

[issue10114] compile() doesn't support the PEP 383 (surrogates)

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

Commited to 3.2 (r85569+r85570). I wait for the buildbot before porting the 
patch to 3.1 and close the issue. There is already a regression on Gentoo 
buildbot with ascii locale encoding, test_doctest test_zipimport_support:

http://www.python.org/dev/buildbot/all/builders/AMD64%20Gentoo%20Wide%203.x/builds/106

--

___
Python tracker 

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



[issue10122] Documentation typo fix and a side question

2010-10-16 Thread Retro

New submission from Retro :

Please read the first sentence of the docs for the built-in function getattr() 
here: http://docs.python.org/library/functions.html?highlight=getattr#getattr

Fix the word 'attributed' to 'attribute', because the former is a typo.



A side question. When you document an object's API in the docstring, you write 
it like this:
getattr(object, name[, default]) -> value

Don't you find it nicer if that would look like this:
getattr(object, name, [default]) -> value

Note the cosmetic fix between the arguments 'name' and 'default'. Do you find 
my fix acceptable? If yes, please fix docstrings in Python that document the 
object's API from the '...name[, default]...' format to '...name, [default]...' 
format.

--
assignee: d...@python
components: Documentation
messages: 118869
nosy: Retro, d...@python
priority: normal
severity: normal
status: open
title: Documentation typo fix and a side question
versions: 3rd party, Python 2.5, Python 2.6, Python 2.7, Python 3.1, Python 
3.2, Python 3.3

___
Python tracker 

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



[issue10123] test_doctest failure with ASCII filesystem encoding

2010-10-16 Thread STINNER Victor

New submission from STINNER Victor :

In #10114, I changed parser filename encoding from utf-8/strict to the 
filesystem encoding/surrogateescape. With C locale, the filesystem encoding is 
ASCII and test_doctest fails because it uses an unencoable filename 
(foo-b...@baz.py).

A solution is to write a test specific to non-ascii filenames and skip it if 
the filename is not encodable (try if os.fsencode() raises an 
UnicodeEncodeError or not), and use only ascii filenames in the other tests.

--
components: Tests, Unicode
messages: 118870
nosy: haypo
priority: normal
severity: normal
status: open
title: test_doctest failure with ASCII filesystem encoding
versions: Python 3.2

___
Python tracker 

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



[issue10114] compile() doesn't support the PEP 383 (surrogates)

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

I created #10123 for the test_doctest regression.

--

___
Python tracker 

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



[issue9807] deriving configuration information for different builds with the same prefix

2010-10-16 Thread Barry A. Warsaw

Barry A. Warsaw  added the comment:

Interestingly enough, the distutils failure that dmalcolm found was present in 
the trunk even before my patch.  If you build Python with --enable-shared, that 
distutils test fails because of the default path used for the -L option.  I 
fixed that in my patch, but it was unrelated to the changes I made to expose 
sys.abiflags.

I wonder if we should try to get a buildbot up that uses --enable-shared?

--

___
Python tracker 

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



[issue10098] intermittent failure in test_os

2010-10-16 Thread Hirokazu Yamamoto

Hirokazu Yamamoto  added the comment:

Sorry about this. And thank you for fix.

--

___
Python tracker 

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



[issue5736] Add the iterator protocol to dbm modules

2010-10-16 Thread Akira Kitada

Changes by Akira Kitada :


Removed file: http://bugs.python.org/file13673/issue5736.diff

___
Python tracker 

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



[issue5736] Add the iterator protocol to dbm modules

2010-10-16 Thread Akira Kitada

Changes by Akira Kitada :


Removed file: http://bugs.python.org/file13674/issue5736.diff

___
Python tracker 

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



[issue5736] Add the iterator protocol to dbm modules

2010-10-16 Thread Akira Kitada

Changes by Akira Kitada :


Removed file: http://bugs.python.org/file13682/test_issue5736.diff

___
Python tracker 

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



[issue5736] Add the iterator protocol to dbm modules

2010-10-16 Thread Akira Kitada

Changes by Akira Kitada :


Removed file: http://bugs.python.org/file13676/issue5736.diff

___
Python tracker 

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



[issue5736] Add the iterator protocol to dbm modules

2010-10-16 Thread Akira Kitada

Akira Kitada  added the comment:

This patch just uses PyObject_GetIter to get an iter.
(I just copied the idea from issue9523)

--
nosy: +ysj.ray
versions: +Python 3.2 -Python 2.7
Added file: http://bugs.python.org/file19250/issue5736.diff

___
Python tracker 

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



[issue10124] obvious typo in cporting HOWTO

2010-10-16 Thread Paul Bolle

New submission from Paul Bolle :

0) There's an obvious typo in the cporting HOWTO:

[...] It’s also important to remember that PyBytes and PyUnicode in 3.0 are not 
interchangeable like PyString and PyString are in 2.x. [...]

That PyString and PyString are interchangeable is obviously not what the author 
wanted to tell.

1) I'll attach a patch to change this into what I suppose the author had in 
mind. (If I knew for sure I wouldn't have read that HOWTO in the first place.)

--
assignee: d...@python
components: Documentation
files: python-2.7-Doc-pystring.patch
keywords: patch
messages: 118875
nosy: d...@python, pebolle
priority: normal
severity: normal
status: open
title: obvious typo in cporting HOWTO
Added file: http://bugs.python.org/file19251/python-2.7-Doc-pystring.patch

___
Python tracker 

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



[issue10122] Documentation typo fix and a side question

2010-10-16 Thread R. David Murray

R. David Murray  added the comment:

No, that would be incorrect syntax (if you omit the optional argument you 
should also omit the comma that precedes it).

--
nosy: +r.david.murray

___
Python tracker 

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



[issue10122] Documentation typo fix and a side question

2010-10-16 Thread R. David Murray

Changes by R. David Murray :


--
type:  -> behavior
versions:  -3rd party, Python 2.5, Python 2.6, Python 3.3

___
Python tracker 

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



[issue10125] Closing a file within its writelines method causes segfault

2010-10-16 Thread intuited

New submission from intuited :

Discovered when using the current Ubuntu 10.04 package of Python: 2.6.5-0ubuntu1

Reproducible with ::

outfile = open("tmpout", "w")
outfile.writelines(f() or "line" for f in (outfile.close,))

This problem is probably most likely to be encountered when using the 
``fileinput`` module, because of the way it abstracts away the closing of 
files.  E.G.::

from fileinput import input
lines = input("tmpout", inplace=1)
first = lines.next()
from sys import stdout
stdout.writelines(lines)

Both of the above pieces of code cause Segmentation Faults.

It looks like in line 1779 of ``Objects/fileobject.c``, ``f->fp`` is being 
passed to ``fwrite`` as 0.  I guess this happens because no check is done after 
the call to ``PyIter_Next`` on line 1730 to see if the file is still open.

I don't see this as a big issue, though it is annoying that it seemingly 
prevents generators from being used with the `fileinput` module.  Doing so 
would be a bit awkward and hacky anyway though.

--
components: IO
messages: 118877
nosy: intuited
priority: normal
severity: normal
status: open
title: Closing a file within its writelines method causes segfault
type: crash
versions: Python 2.6

___
Python tracker 

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



[issue9308] Remove redundant coding cookies from 3.x stdlib

2010-10-16 Thread R. David Murray

R. David Murray  added the comment:

I yhink you need to add an svnignore property to that directory for __pycache__.

--
nosy: +r.david.murray

___
Python tracker 

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



[issue10089] Add support for arbitrary -X options

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

Here is a new patch renaming the attribute to sys._xoptions, and adding some 
docs.

--
Added file: http://bugs.python.org/file19252/xopts2.patch

___
Python tracker 

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



[issue10122] Documentation typo fix and a side question

2010-10-16 Thread Georg Brandl

Georg Brandl  added the comment:

Typo fixed in r85572.  Otherwise, as David says.

--
nosy: +georg.brandl
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue10124] obvious typo in cporting HOWTO

2010-10-16 Thread Georg Brandl

Georg Brandl  added the comment:

I don't think this is what was intended; rather str and unicode.  Fixed in 
r85573.

--
nosy: +georg.brandl
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue10125] Closing a file within its writelines method causes segfault

2010-10-16 Thread Benjamin Peterson

Benjamin Peterson  added the comment:

r85574

--
nosy: +benjamin.peterson
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue9807] deriving configuration information for different builds with the same prefix

2010-10-16 Thread Éric Araujo

Éric Araujo  added the comment:

> I fixed that in my patch, but it was unrelated to the changes I made to 
> expose sys.abiflags.

Would you mind committing that part independently of the rest?

> I wonder if we should try to get a buildbot up that uses --enable-shared?

If the option has significant use, why not.

--

___
Python tracker 

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



[issue8845] Expose sqlite3 connection inTransaction as read-only in_transaction attribute

2010-10-16 Thread Bill Janssen

Bill Janssen  added the comment:

PPC Tiger is using Python 2.7, so it's 3.6.11.

Python 3.X also seems to be failing the sqlite tests on PPC Leopard.  Is the 
required version # different between 3.1 and 3.x?

--

___
Python tracker 

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



[issue10115] accept4 can fail with errno 90

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

> Weekend is coming, so I can lend a hand in implementing whatever you
> choose.

I don't have any strong opinion about it, so it's whichever you prefer really :)

--

___
Python tracker 

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



[issue9807] deriving configuration information for different builds with the same prefix

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

(barry)
> I wonder if we should try to get a buildbot up that uses --enable-
> shared?
(éric)
> If the option has significant use, why not.

Well, it's all the more significant that most Linux distros use shared 
libraries, so they will use that option.
I'll look into changing a buildbot to use --enable-shared, then.

--

___
Python tracker 

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



[issue10089] Add support for arbitrary -X options

2010-10-16 Thread Georg Brandl

Georg Brandl  added the comment:

I'd prefer "-X key[=val]" without the possibility to mention multiple key=val 
pairs, so that val can contain anything (commata in particular).

Otherwise, the change looks fine to me.

--
nosy: +georg.brandl

___
Python tracker 

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



[issue9807] deriving configuration information for different builds with the same prefix

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

I've done so on one of the stable buildbots. Let's see how it behaves:

http://www.python.org/dev/buildbot/builders/x86%20Ubuntu%20Shared%203.x/

--

___
Python tracker 

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



[issue5729] Allows tabs for indenting JSON output

2010-10-16 Thread Antoine Pitrou

Changes by Antoine Pitrou :


--
assignee: bob.ippolito -> 
nosy: +rhettinger

___
Python tracker 

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



[issue9308] Remove redundant coding cookies from 3.x stdlib

2010-10-16 Thread Alexander Belopolsky

Alexander Belopolsky  added the comment:

On Sat, Oct 16, 2010 at 1:34 PM, R. David Murray  wrote:
..
> I yhink you need to add an svnignore property to that directory for 
> __pycache__.

r85576 (I hope I got it right.)

--

___
Python tracker 

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



[issue10126] test_distutils failure with --enable-shared

2010-10-16 Thread Antoine Pitrou

New submission from Antoine Pitrou :

This happens on Python 3.1:

/usr/bin/ld: cannot find -lpython3.1
collect2: ld returned 1 exit status
test test_distutils failed -- Traceback (most recent call last):
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/unixccompiler.py",
 line 254, in link
self.spawn(linker + ld_args)
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/ccompiler.py", 
line 909, in spawn
spawn(cmd, dry_run=self.dry_run)
  File "/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/spawn.py", 
line 34, in spawn
_spawn_posix(cmd, search_path, dry_run=dry_run)
  File "/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/spawn.py", 
line 138, in _spawn_posix
% (cmd[0], exit_status))
distutils.errors.DistutilsExecError: command 'gcc' failed with exit status 1

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/tests/test_build_ext.py",
 line 321, in test_get_outputs
cmd.run()
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/command/build_ext.py",
 line 347, in run
self.build_extensions()
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/command/build_ext.py",
 line 456, in build_extensions
self.build_extension(ext)
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/command/build_ext.py",
 line 543, in build_extension
target_lang=language)
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/ccompiler.py", 
line 719, in link_shared_object
extra_preargs, extra_postargs, build_temp, target_lang)
  File 
"/srv/buildbot/buildarea/3.1.bolen-ubuntu/build/Lib/distutils/unixccompiler.py",
 line 256, in link
raise LinkError(msg)
distutils.errors.LinkError: command 'gcc' failed with exit status 1

(from 
http://www.python.org/dev/buildbot/builders/x86%20Ubuntu%20Shared%203.1/builds/1132/steps/test/logs/stdio
 )

Since it is on one of the stable buildbots, it might be considered 
release-blocking.

--
components: Tests
messages: 118890
nosy: barry, eric.araujo, pitrou, tarek
priority: high
severity: normal
stage: needs patch
status: open
title: test_distutils failure with --enable-shared
type: behavior
versions: Python 3.1

___
Python tracker 

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



[issue10126] test_distutils failure with --enable-shared

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

Similar failure on 2.7:

/usr/bin/ld: cannot find -lpython2.7
collect2: ld returned 1 exit status
test test_distutils failed -- Traceback (most recent call last):
  File 
"/srv/buildbot/buildarea/2.7.bolen-ubuntu/build/Lib/distutils/tests/test_build_ext.py",
 line 269, in test_get_outputs
cmd.run()
  File 
"/srv/buildbot/buildarea/2.7.bolen-ubuntu/build/Lib/distutils/command/build_ext.py",
 line 340, in run
self.build_extensions()
  File 
"/srv/buildbot/buildarea/2.7.bolen-ubuntu/build/Lib/distutils/command/build_ext.py",
 line 449, in build_extensions
self.build_extension(ext)
  File 
"/srv/buildbot/buildarea/2.7.bolen-ubuntu/build/Lib/distutils/command/build_ext.py",
 line 531, in build_extension
target_lang=language)
  File 
"/srv/buildbot/buildarea/2.7.bolen-ubuntu/build/Lib/distutils/ccompiler.py", 
line 741, in link_shared_object
extra_preargs, extra_postargs, build_temp, target_lang)
  File 
"/srv/buildbot/buildarea/2.7.bolen-ubuntu/build/Lib/distutils/unixccompiler.py",
 line 258, in link
raise LinkError, msg
LinkError: command 'gcc' failed with exit status 1

--
versions: +Python 2.7

___
Python tracker 

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



[issue9807] deriving configuration information for different builds with the same prefix

2010-10-16 Thread Éric Araujo

Éric Araujo  added the comment:

Barry: I had misunderstood your message, so disregard my request for commit 
(since the fix you mention *is* committed).

--

___
Python tracker 

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



[issue10126] test_distutils failure with --enable-shared

2010-10-16 Thread Barry A. Warsaw

Barry A. Warsaw  added the comment:

I fixed this in py3k branch, so you just need to backport that.  I can do if 
you can't get to it in the next day or so.

--

___
Python tracker 

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



[issue10126] test_distutils failure with --enable-shared

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

Le samedi 16 octobre 2010 à 20:43 +, Barry A. Warsaw a écrit :
> Barry A. Warsaw  added the comment:
> 
> I fixed this in py3k branch, so you just need to backport that.  I can
> do if you can't get to it in the next day or so.

I don't know how to do it so, yes, it would be better if you do :)
Thanks for caring!

--

___
Python tracker 

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



[issue8845] Expose sqlite3 connection inTransaction as read-only in_transaction attribute

2010-10-16 Thread R. David Murray

R. David Murray  added the comment:

The attribute and test aren't in 3.1 (or 2.7), so this issue only applies to 
3.x trunk.

--

___
Python tracker 

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



[issue10127] ssl.SSLSocket().close() does not close the connection

2010-10-16 Thread R. David Murray

New submission from R. David Murray :

Quoting PoltoS from issue 8293:

If I do sock.close() (sock is instance of ssl.SSLSocket), the connection is not 
closed: I see it as Established in netstat and nothing is sent over network: 
tcpdump show nothing going thru the network.

--
components: Library (Lib)
messages: 118896
nosy: PoltoS, TTT, amaury.forgeotdarc, dandrzejewski, eric.smith, 
giampaolo.rodola, orsenthil, pitrou, r.david.murray
priority: normal
severity: normal
status: open
title: ssl.SSLSocket().close() does not close the connection
type: behavior
versions: Python 2.6

___
Python tracker 

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



[issue8293] HTTPSConnection.close() does not immediately close the connection.

2010-10-16 Thread R. David Murray

R. David Murray  added the comment:

I opened issue 10127 for the ssl.SSLSocket().close() problem.

--
resolution: works for me -> out of date
stage:  -> committed/rejected
status: open -> closed

___
Python tracker 

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



[issue10127] ssl.SSLSocket().close() does not close the connection

2010-10-16 Thread PoltoS

PoltoS  added the comment:

After some investigations it seems that a dup() is called in ssl wrap_socket(), 
so on sock.close() the socket is not really closed, since there is still one 
more reference (file descriptor) in the kernel's tcp/ip stack. Can someone 
confirm this?

Have not done this, but it is possible to check my supposition using linux lsof 
command before and after .close().

--

___
Python tracker 

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



[issue10127] ssl.SSLSocket().close() does not close the connection

2010-10-16 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

I cannot reproduce with 2.7, 3.1 or 3.2. It seems the issue is obsolete, many 
changes having been made to the ssl module since 2.6.

--
resolution:  -> out of date
status: open -> pending

___
Python tracker 

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



[issue10123] test_doctest failure with ASCII filesystem encoding

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

Failures occurred on:
http://www.python.org/dev/buildbot/builders/AMD64%20Gentoo%20Wide%203.x
http://www.python.org/dev/buildbot/builders/sparc%20solaris10%20gcc%203.x

test_zipimport_support does also fail, but it is linked to test_doctest 
failures.

--

___
Python tracker 

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



[issue10123] test_doctest failure with ASCII filesystem encoding

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

Fixed by r85578.

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

___
Python tracker 

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



[issue5391] mmap: read_byte/write_byte and object type

2010-10-16 Thread benrg

benrg  added the comment:

With this patch, read_byte returns an integer in the range -128 to 127 instead 
of 0 to 255 if char is signed. Python 3.1.2 (r312:79149, Mar 21 2010, 00:41:52) 
[MSC v.1500 32 bit (Intel)] on win32 is affected by this. I think it is a bug. 
The test code would fail if the test string contained any bytes outside the 
ASCII range.

(Did this really go unnoticed for a year and a half? I noticed it the moment I 
first tried to use read_byte (which was just now). I see that read_byte was 
broken in a different way in 3.0. Does anybody actually use it?)

--
nosy: +benrg

___
Python tracker 

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



[issue10073] calendar.isleap() not checking parameter type

2010-10-16 Thread Retro

Retro  added the comment:

Please leave this function as is because it works just fine.

>>> calendar.isleap(2011)
False


The argument for isleap() must not be in quotes. That's all.

--
nosy: +Retro

___
Python tracker 

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



[issue10073] calendar.isleap() not checking parameter type

2010-10-16 Thread Retro

Retro  added the comment:

I would just add an exception to the isleap() function.

def isleap(year):
"""Return 1 for leap years, 0 for non-leap years."""
try:
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
except TypeError:
# somehow inform the user that the argument 'year' must be an integer

--

___
Python tracker 

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



[issue5729] Allows tabs for indenting JSON output

2010-10-16 Thread Raymond Hettinger

Changes by Raymond Hettinger :


--
assignee:  -> rhettinger

___
Python tracker 

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



[issue10128] multiprocessing.Pool throws exception with __main__.py

2010-10-16 Thread Michael Olson

New submission from Michael Olson :

In an application with an entry point of __main__.py, multiprocessing.Pool 
throws the following:

Traceback (most recent call last):
  File "", line 1, in 
  File "D:\Dev\Python27\lib\multiprocessing\forking.py", line 346, in main
prepare(preparation_data)
  File "D:\Dev\Python27\lib\multiprocessing\forking.py", line 454, in prepare
assert main_name not in sys.modules, main_name
AssertionError: __main__

These messages repeat as long as the application is running.

Demonstration Code, must be in file named __main__.py:

import multiprocessing
import time

if __name__ == '__main__':
pool = multiprocessing.Pool()
time.sleep(2)


--
components: Library (Lib)
messages: 118905
nosy: Michael.Olson
priority: normal
severity: normal
status: open
title: multiprocessing.Pool throws exception with __main__.py
type: behavior
versions: Python 2.7

___
Python tracker 

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



[issue10115] accept4 can fail with errno 90

2010-10-16 Thread Vetoshkin Nikita

Vetoshkin Nikita  added the comment:

Made a proof of concept patch (no doc updates yet). Decided to implement 
separate accept4() method, cause we have already spent enough time dealing with 
it and rollback would be pity.

--
keywords: +patch
Added file: http://bugs.python.org/file19253/issue10115_first_attempt.diff

___
Python tracker 

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



[issue10052] Python/dtoa.c:158: #error "Failed to find an exact-width 32-bit integer type" (FreeBSD 4.11 + gcc 2.95.4)

2010-10-16 Thread Akira Kitada

Akira Kitada  added the comment:

This patch is specifically targeted at FreeBSD 4.
tested on FreeBSD 4.11 and OS X 10.6.4

I don't know how to accommodate SGI IRIX's case.

--
keywords: +patch
Added file: http://bugs.python.org/file19254/issue10052.diff

___
Python tracker 

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



[issue8611] Python3 doesn't support locale different than utf8 and an non-ASCII path (POSIX)

2010-10-16 Thread STINNER Victor

STINNER Victor  added the comment:

Status of this issue, 5 months later: most tests pass except test_gc test_gdb 
test_runpy test_sys test_wsgiref test_zipimport. Said differently, 95% of the 
task (or more?) is done. It's possible to run Python installed in a non-ascii 
directory with any locale (I tested ascii, iso-8859-1 and utf-8).

--

___
Python tracker 

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



[issue1533105] NetBSD build with --with-pydebug causes SIGSEGV

2010-10-16 Thread Gregory P. Smith

Gregory P. Smith  added the comment:

I don't see this issue on netbsd 5.0.2 i386 in the py3k branch.

--
nosy: +gregory.p.smith

___
Python tracker 

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



[issue5510] patches for Modules/socketmodule.c for NetBSD

2010-10-16 Thread Gregory P. Smith

Gregory P. Smith  added the comment:

netbsd-wizs-mod.patch applied in 85587.

--
assignee:  -> gregory.p.smith
nosy: +gregory.p.smith
resolution:  -> accepted
stage:  -> committed/rejected
status: open -> closed

___
Python tracker 

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



[issue8845] Expose sqlite3 connection inTransaction as read-only in_transaction attribute

2010-10-16 Thread Ned Deily

Ned Deily  added the comment:

FYI, in a recent py3k installer build test using the same installer image 
(2-way i386/ppc universal with statically linked sqlite 3.6.11), the test fails 
on ppc G3 (10.4), ppc g4 (10.5) but passes on i386 (10.6) so I'd go along with 
Bill's big- vs little-endian hypothesis.

--
nosy: +ned.deily

___
Python tracker 

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



[issue10128] multiprocessing.Pool throws exception with __main__.py

2010-10-16 Thread Ned Deily

Changes by Ned Deily :


--
nosy: +jnoller

___
Python tracker 

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



[issue10128] multiprocessing.Pool throws exception with __main__.py

2010-10-16 Thread R. David Murray

Changes by R. David Murray :


--
nosy: +asksol

___
Python tracker 

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



[issue3482] re.split, re.sub and re.subn should support flags

2010-10-16 Thread R. David Murray

R. David Murray  added the comment:

For reference, the py3k rev was r70091.

--
nosy: +r.david.murray
resolution:  -> accepted
stage: needs patch -> committed/rejected
status: open -> closed

___
Python tracker 

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



[issue10090] python -m locale fails on OSX

2010-10-16 Thread R. David Murray

Changes by R. David Murray :


--
nosy: +lemburg

___
Python tracker 

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



[issue10129] Curious 'name not defined error' with 'python -m'

2010-10-16 Thread Andreas Kloeckner

New submission from Andreas Kloeckner :

$ python3.1 -m a b.py

results in

Traceback (most recent call last):
  File "/usr/lib/python3.1/runpy.py", line 128, in _run_module_as_main
"__main__", fname, loader, pkg_name)
  File "/usr/lib/python3.1/runpy.py", line 34, in _run_code
exec(code, run_globals)
  File "/home/andreas/tmp/python-mbug/a.py", line 6, in 
main()
  File "/home/andreas/tmp/python-mbug/a.py", line 3, in main
exec(compile(open(sys.argv[1]).read(), sys.argv[1], 'exec'))
  File "b.py", line 8, in 
sys.exit(main())
  File "b.py", line 5, in main
argv = sys.argv[1:]
NameError: global name 'sys' is not defined

a.py --
def main():
import sys
exec(compile(open(sys.argv[1]).read(), sys.argv[1], 'exec'))

if __name__=='__main__':
main()
---

b.py --
import sys

def main():
  sys.argv[1:]

if __name__ == "__main__":
  main()
---

--
components: Interpreter Core
messages: 118913
nosy: inducer
priority: normal
severity: normal
status: open
title: Curious 'name not defined error' with 'python -m'
type: behavior
versions: Python 2.6, Python 3.1

___
Python tracker 

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



[issue4949] Constness in PyErr_NewException

2010-10-16 Thread Andreas Kloeckner

Andreas Kloeckner  added the comment:

ping?

--

___
Python tracker 

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



[issue10129] Curious 'name not defined error' with 'python -m'

2010-10-16 Thread Georg Brandl

Georg Brandl  added the comment:

(This is not specific to running with -m, it occurs as well when you do "python 
a.py b.py".)

The issue here is your call to exec() does not execute the code as its own 
module.  It executes the code as part of the main() function in a.py, with 
(since you don't give a global namespace argument) the same global namespace as 
that of a.main(), and there is no "sys" in that namespace.  Further, the 
compiler cannot treat b.main like a nested function of a.main (which would then 
create a closure over the "sys" imported inside a.main).  Therefore, the 
reference to sys is treated as a global and not found.

If you give the exec() function an explicit dictionary as the globals argument, 
this "works":

def main():
d = {'__name__': '__main__'}
exec(compile(open(sys.argv[1]).read(), sys.argv[1], 'exec'), d)

--
nosy: +georg.brandl
resolution:  -> wont fix
status: open -> closed

___
Python tracker 

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



[issue10058] C-API Intro should be more explicit about error return codes

2010-10-16 Thread Georg Brandl

Georg Brandl  added the comment:

Committed a change in that spirit in r85606.  Thanks!

--

___
Python tracker 

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



[issue10024] Outdated advice in C-API tutorial?

2010-10-16 Thread Georg Brandl

Changes by Georg Brandl :


--
resolution:  -> wont fix
status: open -> closed

___
Python tracker 

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