[issue10359] ISO C cleanup

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset fe0972e102cd by Éric Araujo in branch '3.2':
Make C code in one distutils test comply with ISO C (#10359).
http://hg.python.org/cpython/rev/fe0972e102cd

New changeset 9ded1f21f0fd by Éric Araujo in branch 'default':
Make C code in one packaging test comply with ISO C (#10359).
http://hg.python.org/cpython/rev/9ded1f21f0fd

--

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



[issue11171] Python 2.7.1 does not start when ./configure is used with --prefix != --exec-prefix

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 6542e4028ed2 by Éric Araujo in branch '3.2':
As it turns out, this bug was already in the tracker: #11171
http://hg.python.org/cpython/rev/6542e4028ed2

--
nosy: +python-dev

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



[issue10526] Minor typo in What's New in Python 2.7

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset c52bac35b498 by Éric Araujo in branch 'default':
Merge fixes for #10526, #10359, #11254, #9100 and the bug without number
http://hg.python.org/cpython/rev/c52bac35b498

--
nosy: +python-dev

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



[issue10536] Enhancements to gettext docs

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset e48e6e9bdef6 by Éric Araujo in branch '3.2':
Fix a typo and a broken link (part of #10536).
http://hg.python.org/cpython/rev/e48e6e9bdef6

--
nosy: +python-dev

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



[issue9100] test_sysconfig fails (test_user_similar)

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 1f8aef75558c by Éric Araujo in branch '3.2':
Fix test_sysconfig when prefix != exec-prefix (#9100).
http://hg.python.org/cpython/rev/1f8aef75558c

--
nosy: +python-dev

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



[issue13114] check -r fails with non-ASCII unicode long_description

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset e16792003597 by Éric Araujo in branch '3.2':
Add tests for Unicode handling in distutils’ check and register (#13114)
http://hg.python.org/cpython/rev/e16792003597

--
nosy: +python-dev

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



[issue11254] distutils doesn't byte-compile .py files to __pycache__ during installation

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 27a36b05caed by Éric Araujo in branch '3.2':
Fix distutils byte-compilation to comply with PEP 3147 (#11254).
http://hg.python.org/cpython/rev/27a36b05caed

New changeset 651e84363001 by Éric Araujo in branch '3.2':
Fix docstring of distutils.util.byte_compile (followup for #11254)
http://hg.python.org/cpython/rev/651e84363001

New changeset 439f47fadffa by Éric Araujo in branch 'default':
Fix packaging byte-compilation to comply with PEP 3147 (#11254).
http://hg.python.org/cpython/rev/439f47fadffa

--
nosy: +python-dev

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



[issue9100] test_sysconfig fails (test_user_similar)

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 27045f93e4cb by Éric Araujo in branch '2.7':
Fix test_sysconfig when prefix != exec-prefix (#9100).
http://hg.python.org/cpython/rev/27045f93e4cb

--

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



[issue10536] Enhancements to gettext docs

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 1e48a2b484a3 by Éric Araujo in branch '2.7':
Fix a typo and a broken link (part of #10536).
http://hg.python.org/cpython/rev/1e48a2b484a3

--

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



[issue13114] check -r fails with non-ASCII unicode long_description

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 8d837bd8148a by Éric Araujo in branch '2.7':
Fix distutils’ check and register Unicode handling (#13114).
http://hg.python.org/cpython/rev/8d837bd8148a

--

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



[issue10359] ISO C cleanup

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 134b68cae802 by Éric Araujo in branch '2.7':
Make C code in one distutils test comply with ISO C (#10359).
http://hg.python.org/cpython/rev/134b68cae802

--

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



[issue11171] Python 2.7.1 does not start when ./configure is used with --prefix != --exec-prefix

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

 My question was: does distutils.sysconfig._get_makefile_filename have
 the same bug as the one that was fixed in sysconfig._get_makefile_filename?

It does, I fixed it in 9afd3d54c3cb.

--
stage: patch review - committed/rejected

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



[issue11254] distutils doesn't byte-compile .py files to __pycache__ during installation

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Finally fixed.  I fail at boolean logic; removing the “dance around 
imp.cache_from_source that seemed unnecessary” as I called it was a mistake, we 
have to do it, so I restored that part of your original patch.  I’m sorry I 
took so long to fix this, it was straightforward.

--
resolution:  - fixed
stage: commit review - committed/rejected
status: open - closed

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



[issue9100] test_sysconfig fails (test_user_similar)

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Now fixed.

--
resolution:  - fixed
stage:  - committed/rejected
status: open - closed

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



[issue13114] check -r fails with non-ASCII unicode long_description

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Fixed, thanks again!

--
resolution:  - fixed
stage: needs patch - committed/rejected
status: open - closed

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



[issue13086] Update howto/cporting.rst so it talks about Python 3 instead of 3.0

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

+1 ;)

--
nosy: +eric.araujo
title: Update howto/cporting.rst so it talks about 3.x instead of 3.0 - Update 
howto/cporting.rst so it talks about Python 3 instead of 3.0

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



[issue6983] Add specific get_platform() for freebsd

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

This patch was a short-term fix.  Distutils is closed to anything but bug fixes 
and distutils2 can get a better fix.  Objections if I close this?

--
components: +Distutils -Distutils2, Library (Lib)
versions:  -Python 3.2

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



[issue12427] packaging register fails because POST data should be bytes

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Can’t reproduce.

--
assignee: tarek - eric.araujo
resolution:  - out of date
stage:  - committed/rejected
status: open - closed

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



[issue12405] packaging does not record/remove directories it creates

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

 IMO in this situation, a and b were created by the installation and so
 should be removed, unless they contain files not added during installation.

I share that opinion.  So, the first step would be to record created 
directories.  We could extend PEP 376 and write entries without hash nor length 
record for directories in RECORD, or use another file in the dist-info dir.

--
versions: +3rd party

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



[issue13123] bdist_wininst uninstaller does not remove pycache directories

2011-10-09 Thread Paul Moore

Paul Moore p.f.mo...@gmail.com added the comment:

On 9 October 2011 04:21, Éric Araujo rep...@bugs.python.org wrote:

 Éric Araujo mer...@netwok.org added the comment:

 I don’t have a Windows VM set up yet, but I can try to write a patch in the 
 coming weeks and ask you to test it.  Deal?

No problem there!

--

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



[issue6983] Add specific get_platform() for freebsd

2011-10-09 Thread Stef Walter

Stef Walter s...@memberwebs.com added the comment:

Shrug. I guess you can close it.

This is still a bothersome issue, but we've taken to patching every version of 
python downstream before deploying them. All for a simple three line patch.

--

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



[issue12386] packaging fails in install_distinfo when writing RESOURCES

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

I’d like to fix this.  How can I reproduce the bug?

--

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



[issue1109658] distutils dry-run breaks when attempting to bytecompile

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

[Martin]
 Looking at the code, I find it unfortunate that it uses os.path.exists,
 causing a stat call, and then does another stat call to find the time stamp.

Are you noting the inefficiency of doing two stat calls instead of one, or 
saying that it should make none at all in dry-run mode?  My opinion is that a 
dry-run mode should not create any file nor make any changes, but reading files 
and calling processes that give info is fair game.

--

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



[issue7330] PyUnicode_FromFormat: implement width and precision for %s, %S, %R, %V, %U, %A

2011-10-09 Thread lekma

Changes by lekma lekma...@gmail.com:


--
nosy: +lekma

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



[issue13055] Distutils tries to handle null versions but fails

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

The fact that 1) StrictVersion and LooseVersion have None as default argument 
for vstring in __init__ 2) __init__ does not raise an exception if vstring is 
not given makes me think that the intended behavior is that the vstring 
argument is optional.  Making it required would be a behavior change which 
would run contrary to the distutils code freeze*.  I don’t feel that the 
workaround (set self.vstring to '') is okay; I’d rather fix the methods that 
fail when self.vstring is not defined, like __str__, or document the 
limitations.  What is your use case for these classes, and what methods need 
fixing?

* There is a lot of code out there that will break if we start to add and remove
  things, so a freeze was decided and we work on distutils2, a new version.
  distutils only gets fixes for real bugs.

--

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



[issue6164] [AIX] Patch to correct the AIX C/C++ linker argument used for 'runtime_library_dirs'

2011-10-09 Thread Roumen Petrov

Roumen Petrov bugtr...@roumenpetrov.info added the comment:

hmm, and commit that close issue is ?

--

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



[issue13074] Improve documentation of locale encoding functions

2011-10-09 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
nosy: +eric.araujo, haypo, lemburg

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



[issue6164] [AIX] Patch to correct the AIX C/C++ linker argument used for 'runtime_library_dirs'

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

See above: “done in r73490” and “merged in 3.2 in r73647”.

--

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



[issue6164] [AIX] Patch to correct the AIX C/C++ linker argument used for 'runtime_library_dirs'

2011-10-09 Thread Roumen Petrov

Roumen Petrov bugtr...@roumenpetrov.info added the comment:

see above and restore of distutils in trunk abandon it.

--

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



[issue6164] [AIX] Patch to correct the AIX C/C++ linker argument used for 'runtime_library_dirs'

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

This was supposed to be added to 3.1 but we missed it.

--

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



[issue13030] Be more generic when identifying the Windows main dir in installation doc

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

 The table headings 'Standard installation location' (of what?)
Of software projects using distutils.

 and 'Default value' (for what program?)
For a CPython without changes to the default build configuration.

 both seem a bit ambiguous, or rather they seem reversed to me. I
 would label the columns 'Default module directory' and 'Standard
 Python location'.
Well, no: the first column does not contain real paths, but templates with 
placeholders like prefix and X.Y.  The second column gives the path with the 
placeholders replaced by their default value.

 That said, I hope that the actual default module installation
 directory for install is the actual site-packages directory on
 my machine, based on where I actually put python,
Yes.

 and not the non-existent standard location, which I did not use
 but which is what the text seems to say (but which would be a
 behavior design bug to me).
“Default” means “if you haven’t made any change to the build/install 
configuration of Python”.

Do these replies make sense?  If so, I can rephrase them as a doc patch.

--

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



[issue13094] Need Programming FAQ entry for the behavior of closures

2011-10-09 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
assignee:  - docs@python
components: +Documentation -None
nosy: +eric.araujo
versions: +Python 3.2, Python 3.3

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



[issue6164] [AIX] Patch to correct the AIX C/C++ linker argument used for 'runtime_library_dirs'

2011-10-09 Thread Roumen Petrov

Roumen Petrov bugtr...@roumenpetrov.info added the comment:

For protocol blibpath is not in any release  - get download and check content . 
Did you apply a different fix ?

--

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



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

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

So.  This was reverted before 3.2 was out, right?  What is the status for 3.3?

--
components:  -2to3 (2.x to 3.0 conversion tool), Documentation

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



[issue12386] packaging fails in install_distinfo when writing RESOURCES

2011-10-09 Thread Vinay Sajip

Vinay Sajip vinay_sa...@yahoo.co.uk added the comment:

I got the problem when installing a package with resources using pysetup3. 
Here's the relevant part of the console session:

(venv) vinay@eta-natty:~/projects$ pysetup3 install nemo
Installing from source directory: /home/vinay/projects/nemo
running install_dist
running build
running build_py
running build_scripts
running install_lib
creating /tmp/venv/lib/python3.3/site-packages
creating /tmp/venv/lib/python3.3/site-packages/virtualenvwrapper
byte-compiling 
/tmp/venv/lib/python3.3/site-packages/virtualenvwrapper/hook_loader.py to 
hook_loader.pyc
byte-compiling 
/tmp/venv/lib/python3.3/site-packages/virtualenvwrapper/user_scripts.py to 
user_scripts.pyc
byte-compiling 
/tmp/venv/lib/python3.3/site-packages/virtualenvwrapper/__init__.py to 
__init__.pyc
byte-compiling /tmp/venv/lib/python3.3/site-packages/nemo.py to nemo.pyc
running install_scripts
changing mode of /tmp/venv/bin/nemo to 755
running pre_hook hooks.pre_install_data for command install_data
running install_data
running install_distinfo
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/METADATA
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/INSTALLER
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/REQUESTED
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/RESOURCES
Traceback (most recent call last):
  File /tmp/venv/bin/pysetup3, line 6, in module
rc = packaging.run.main() # None interpreted as 0
  File /usr/local/lib/python3.3/packaging/run.py, line 653, in main
return dispatcher()
  File /usr/local/lib/python3.3/packaging/run.py, line 642, in __call__
return func(self, self.args)
  File /usr/local/lib/python3.3/packaging/run.py, line 91, in wrapper
return f(*args, **kwargs)
  File /usr/local/lib/python3.3/packaging/run.py, line 164, in _install
return not install_local_project(target)
  File /usr/local/lib/python3.3/packaging/install.py, line 122, in 
install_local_project
return _run_install_from_dir(path)
  File /usr/local/lib/python3.3/packaging/install.py, line 160, in 
_run_install_from_dir
func(source_dir)
  File /usr/local/lib/python3.3/packaging/install.py, line 87, in 
_run_packaging_install
dist.run_command('install_dist')
  File /usr/local/lib/python3.3/packaging/dist.py, line 709, in run_command
cmd_obj.run()
  File /usr/local/lib/python3.3/packaging/command/install_dist.py, line 508, 
in run
self.run_command(cmd_name)
  File /usr/local/lib/python3.3/packaging/command/cmd.py, line 330, in 
run_command
self.distribution.run_command(command)
  File /usr/local/lib/python3.3/packaging/dist.py, line 709, in run_command
cmd_obj.run()
  File /usr/local/lib/python3.3/packaging/command/install_distinfo.py, line 
113, in run
writer.writerow(row)
TypeError: 'str' does not support the buffer interface

This is the relevant code in install_distinfo.run():

resources_path = os.path.join(self.distinfo_dir,
  'RESOURCES')
logger.info('creating %s', resources_path)
if not self.dry_run:
#with open(resources_path, 'w', encoding='utf-8') as f:
with open(resources_path, 'wb') as f:
writer = csv.writer(f, delimiter=',',
lineterminator='\n',
quotechar='')
for row in install_data.get_resources_out():
writer.writerow(row)

If I substitute the commented out line above which replaces 'wb' with 'w' and 
encoding, I get this result:

(venv) vinay@eta-natty:~/projects$ pysetup3 install nemo
Installing from source directory: /home/vinay/projects/nemo
running install_dist
running build
running build_py
running build_scripts
running install_lib
byte-compiling 
/tmp/venv/lib/python3.3/site-packages/virtualenvwrapper/hook_loader.py to 
hook_loader.pyc
byte-compiling 
/tmp/venv/lib/python3.3/site-packages/virtualenvwrapper/user_scripts.py to 
user_scripts.pyc
byte-compiling 
/tmp/venv/lib/python3.3/site-packages/virtualenvwrapper/__init__.py to 
__init__.pyc
byte-compiling /tmp/venv/lib/python3.3/site-packages/nemo.py to nemo.pyc
running install_scripts
changing mode of /tmp/venv/bin/nemo to 755
running pre_hook hooks.pre_install_data for command install_data
running install_data
running install_distinfo
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/METADATA
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/INSTALLER
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/REQUESTED
creating /tmp/venv/lib/python3.3/site-packages/nemo-0.1.dist-info/RESOURCES
creating 

[issue6164] [AIX] Patch to correct the AIX C/C++ linker argument used for 'runtime_library_dirs'

2011-10-09 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Ah, I thought it was missing only in 3.1.  I will reapply the patch.

--
assignee: tarek - eric.araujo
components: +Distutils2
nosy: +alexis
resolution: fixed - 
stage: committed/rejected - patch review
status: closed - open
versions: +3rd party, Python 3.3

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



[issue12405] packaging does not record/remove directories it creates

2011-10-09 Thread Vinay Sajip

Vinay Sajip vinay_sa...@yahoo.co.uk added the comment:

 I share that opinion.  So, the first step would be to record created 

 directories.  We could extend PEP 376 and write entries without hash nor 
 length 
 record for directories in RECORD, or use another file in the dist-info dir.

IMO using RECORD would be preferable to another file, otherwise RECORD is not a 
complete record :-(

--

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



[issue13133] FD leaks in ZipFile.read(), ZipFile.extract() and also using explicit arc_member.close()

2011-10-09 Thread Valery Khamenya

Valery Khamenya khame...@gmail.com added the comment:

Amaury, I followed your advice. All relevant changes of 3.2 are backported via 
the patch attached.

P.S. now I can install Twisted using pypy too. pypy setup.py install works 
fine for me.

--
keywords: +patch
status: pending - open
Added file: http://bugs.python.org/file23354/zipfile.patch

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



[issue13134] speed up finding of one-character strings

2011-10-09 Thread Marc-Andre Lemburg

Marc-Andre Lemburg m...@egenix.com added the comment:

[Posted the reply to the right ticket; see issue13136 for the original
 post to the wrong ticket]

Antoine Pitrou wrote:
 
 Antoine Pitrou pit...@free.fr added the comment:
 
 Before going further with this, I'd suggest you have a look at your
 compiler settings.
 
 They are set by the configure script:
 
 gcc -pthread -c -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall
 -Wstrict-prototypes-I. -I./Include-DPy_BUILD_CORE -o
 Objects/unicodeobject.o Objects/unicodeobject.c

Which gcc version are you using ?
Is it possible that you have -fno-builtin enabled ?

 Such optimizations are normally performed by the
 compiler and don't need to be implemented in C, making maintenance
 harder.
 
 The fact that the glibc includes such optimization (in much more
 sophisticated form) suggests to me that many compilers don't perform
 these optimizations automically.

When using gcc, the glibc functions are usually not used at all,
since gcc comes with a (rather large) set of builtins which are
inlined directly, if you have optimizations enabled and inlining
is found to be more efficient than calling the glibc function:

http://gcc.gnu.org/onlinedocs/gcc/Other-Builtins.html

glibc includes the optimized versions since it has to implement
C library (obviously) and for cases where inlining does not
happen.

 I tested using memchr() when writing those naive loops.
 
 memchr() is mentioned in another issue, #13134.
 
 memchr()
 is inlined by the compiler just like the direct loop
 
 I don't think so. If you look at the glibc's memchr() implementation,
 it's a sophisticated routine, not a trivial loop. Perhaps you're
 thinking about memcpy().

See http://gcc.gnu.org/onlinedocs/gcc/Other-Builtins.html and the
assembler output. If it's not inlined, then something must be
preventing this and it would be good to find out why.

 and the generated
 code for the direct version is often easier to optimize for the compiler
 than the memchr() one, since it receives more knowledge about the used
 data types.
 
 ?? Data types are fixed in the memchr() definition, there's no knowledge
 to be gained by inlining.

There is: the compiler will have alignement information available and
can also benefit from using registers instead of the stack, knowledge
about processor cache lines, etc. Such information is lost when calling
a function. The function call itself will also create some overhead.

BTW: You should not only test the optimization with long strings, but also
with short ones (e.g. 2-15 chars) - which is a much more common case
in practice.

--
nosy: +lemburg

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



[issue12779] Update packaging documentation

2011-10-09 Thread Paul Moore

Changes by Paul Moore p.f.mo...@gmail.com:


--
nosy: +pmoore

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



[issue13136] speed-up conversion between unicode widths

2011-10-09 Thread Marc-Andre Lemburg

Marc-Andre Lemburg m...@egenix.com added the comment:

Antoine Pitrou wrote:
 
 I tested using memchr() when writing those naive loops.
 
 memchr() is mentioned in another issue, #13134.

Looks like I posted the comment to the wrong ticket.

--

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



[issue13053] Add Capsule migration documentation to cporting

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset d0af22b65889 by Larry Hastings in branch '2.7':
Issue #13053: Added section on migrating from CObject to Capsule
http://hg.python.org/cpython/rev/d0af22b65889

--
nosy: +python-dev

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



[issue12753] \N{...} neglects formal aliases and named sequences from Unicode charnames namespace

2011-10-09 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

Here is a new patch that stores the names of aliases and named sequences in the 
Private Use Area.

To summarize a bit, this is what we want:
| 6.0.0 | 3.2.0 |
+---+---+
\N{...} |   A   |   -   |
.name   |   -   |   -   |
.lookup |  A,NS |   -   |

I.e., \N{...} should only support aliases, unicodedata.lookup should support 
aliases and named sequences, unicodedata.name doesn't support either, and when 
3.2.0 is used nothing is supported.

The function calls involved for these 3 functions are:

\N{...} and .lookup:
  _getcode
_cmpname
  _getucname
_check_alias

.name:
  _getucname

My patch adds an extra arg to _getcode and _getucname (I hope that's fine -- or 
are they public?).

_getcode is called by \N{...} and .lookup; both support aliases, so _getcode 
now resolves aliases by default.  Since only .lookup wants named sequences, 
_getcode now accepts an extra 'with_named_seq' arg and looks up named sequences 
only when its value is 1.  .lookup passes 1, gets the codepoint, and converts 
it to a sequence.  \N{...} passes 0 and doesn't get named sequences.

_getucname is called by .name and indirectly (through _cmpname) by .lookup and 
\N{...}.  Since _getcode takes care of deciding who gets aliases and sequences, 
_getucname now accepts an extra 'with_alias_and_seq' arg and looks up aliases 
and named sequences only when its value is 1.  _cmpname passes 1, gets aliases 
and named sequences and then lets _getcode decide what to do with them.  .name 
passes 0 and doesn't get aliases and named sequences.

All this happens on 6.0.0 only, when self != NULL (i.e. we are using 3.2.0) 
named sequences and aliases are ignored.

The patch doesn't include the changes to unicodename_db.h -- run 
makeunicodedata.py to get them.
I also added more tests to make sure that the names added in the PUA don't 
leak, and that ucd_3_2_0 is not affected.

--
Added file: http://bugs.python.org/file23355/issue12753-4.diff

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



[issue13055] Distutils tries to handle null versions but fails

2011-10-09 Thread Ben Gamari

Ben Gamari bgam...@gmail.com added the comment:

The bug was encountered while trying to install a package. As it turns out, a 
dependency was incorrectly installed, resulting in a null version being passed 
around which quickly caused a crash in setup.py. While this is definitely not a 
normal circumstance, the fact that this bug existed made finding the issue 
substantially more time consuming. If the constructor of the LooseVersion can 
accept None, then so should its other members.

--

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



[issue11457] os.stat(): add new fields to get timestamps as Decimal objects with nanosecond resolution

2011-10-09 Thread Larry Hastings

Larry Hastings la...@hastings.org added the comment:

Can I get some thoughts / votes on whether to
a) check in with the current performance regression, or
b) do the work to make it lazy-created?

--

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



[issue13096] ctypes: segfault with large POINTER type names

2011-10-09 Thread Brian Brazil

Brian Brazil brian.bra...@gmail.com added the comment:

The problem is around line 1734 of callproc.c in tip:

} else if (PyType_Check(cls)) {
typ = (PyTypeObject *)cls;
buf = alloca(strlen(typ-tp_name) + 3 + 1);
sprintf(buf, LP_%s, typ-tp_name);   -- segfault is here

Replacing the alloca with a malloc fixes it, so I presume it's hitting the 
stack size limit as 2^25 is 32MB (my stack limit is 8MB).

--
nosy: +bbrazil

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



[issue13096] ctypes: segfault with large POINTER type names

2011-10-09 Thread Meador Inge

Meador Inge mead...@gmail.com added the comment:

Yup, it is the 'alloca' call.  This issue and issue13097 are both 
'alloca' related as mentioned in issue12881.

--

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



[issue13097] ctypes: segfault with large number of callback arguments

2011-10-09 Thread Meador Inge

Meador Inge mead...@gmail.com added the comment:

As mentioned in issue12881, this issue is a result of an unbounded 'alloca' 
call that trashes the stack.

--

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



[issue13050] RLock support the context manager protocol but this is not documented

2011-10-09 Thread Brian Brazil

New submission from Brian Brazil brian.bra...@gmail.com:

This is already documented:

http://docs.python.org/library/threading.html#using-locks-conditions-and-semaphores-in-the-with-statement

--
nosy: +bbrazil

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



[issue8668] Packaging: add a 'develop' command

2011-10-09 Thread higery

higery shoulderhig...@gmail.com added the comment:

 higery, can you give us a status update?  Do you have the time to ...

Sorry to reply to you so late, I will read carefully these reviews asap and try 
to make an updated patch before 12th.

--

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



[issue12753] \N{...} neglects formal aliases and named sequences from Unicode charnames namespace

2011-10-09 Thread Tom Christiansen

Tom Christiansen tchr...@perl.com added the comment:

Ezio Melotti rep...@bugs.python.org wrote
   on Sun, 09 Oct 2011 13:21:00 -: 

 Here is a new patch that stores the names of aliases and named
 sequences in the Private Use Area.

Looks good!  Thanks!

--tom

--
title: \N{...} neglects formal aliases and named sequences from Unicode 
charnames namespace - \N{...} neglects formal aliases and named sequences from 
Unicode charnames namespace

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



[issue11457] os.stat(): add new fields to get timestamps as Decimal objects with nanosecond resolution

2011-10-09 Thread Raymond Hettinger

Raymond Hettinger raymond.hettin...@gmail.com added the comment:

[Arfrever Frehtes Taifersar Arahesis]
 I suggest to have low-level, POSIX-compatible, 
 (int, int)-based interface in os module and add 
 high-level, decimal.Decimal-based interface in 
 shutil module.

I agree that this is the cleanest approach.
Ideally, the os module stays as close as possible
to the underlying structures.  Also, it is desirable
to keep it fast (not importing a pure python decimal
module as a side-effect of checking the a timestamp
-- making everyone pay the cost for a feature that
few people will want or need).

With respect to the options suggested by MvL,
I support adding new named fields and opposed
to using a flag to indicate a type change (that
would be error-prone).

If new fields as added, their names need to follow
the existing naming convention (st_variable).

-1 on the patch as currently proposed.  I don't
think the performance impact is acceptable.

--
nosy: +rhettinger

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



[issue13062] Introspection generator and function closure state

2011-10-09 Thread Meador Inge

Meador Inge mead...@gmail.com added the comment:

Here is an updated patch with error handling.  One other thought is that 
'getclosure' should be called something like 'getclosureenv' since 
technically a closure is a function plus its environment and our 
implementation only returns the environment.  But that may be converging 
on pedantic.

--
Added file: http://bugs.python.org/file23356/issue13062-2.patch

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



[issue11457] os.stat(): add new fields to get timestamps as Decimal objects with nanosecond resolution

2011-10-09 Thread Raymond Hettinger

Changes by Raymond Hettinger raymond.hettin...@gmail.com:


--
assignee:  - rhettinger

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



[issue12436] Missing items in installation/setup instructions

2011-10-09 Thread Mike Hoy

Mike Hoy mho...@gmail.com added the comment:

Here is what I have so far:

 For Windows users, added a section about how to use a terminal

How to use a terminal

Open a command prompt:

* On Windows Vista or Windows 7: click on the Start menu (the Windows logo in 
the lower left of the screen), type cmd into the Search field directly above 
the Start menu button, and click on cmd in the search results above the 
Search field.

* On Windows XP: click on the Start menu (the Windows logo in the lower left of 
the screen), click on Run..., type cmd into the text box, and hit enter.

Commands used in terminal

* cd C:\ - Puts you in the root directory of the C drive.
* cd Python32 - Puts you in the directory where Python 3.2 is installed.
* dir - This command lists the contents of the Python32 directory.
* python - This command will invoke python.exe and bring up the interpreter.

 a link to PowerShell 

Windows PowerShell

Windows PowerShell is a task-based command-line shell and scripting language 
designed for system administration. It can be obtained here: 
http://technet.microsoft.com/en-us/library/bb978526.aspx.

--

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



[issue12923] test_urllib fails in refleak mode

2011-10-09 Thread Brian Brazil

Brian Brazil brian.bra...@gmail.com added the comment:

This appears to fail every 9th, 19th, 29th, etc. repetition of the test. 

This seems to be something to do with the reference counting/close logic of the 
FakeSocket but I haven't managed to figure out what.

--
nosy: +bbrazil

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



[issue13086] Update howto/cporting.rst so it talks about Python 3 instead of 3.0

2011-10-09 Thread Larry Hastings

Larry Hastings la...@hastings.org added the comment:

Attached is my first revision patch.  I did some other editing for
clarity / 80 columns, though I can back those out from this patch (and put in 
another) if that's best.

Patch is against the 2.7 branch; once this goes in I'll port all my recent 
cporting.rst changes to 3.2 and trunk.

--
keywords: +patch
Added file: http://bugs.python.org/file23357/larry.cporting.to.python.3.r1.diff

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



[issue13050] RLock support the context manager protocol but this is not documented

2011-10-09 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

Hmm.  But what I did was look up the RLock section of the manual to answer the 
question does this support the context manager protocol, and the answer 
appeared to be no.  In a reference manual I would expect all the important 
features of an object to be described in that object's documentation, or linked 
to therefrom.

--

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



[issue13086] Update howto/cporting.rst so it talks about Python 3 instead of 3.0

2011-10-09 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

 Attached is my first revision patch.

LGTM

 I did some other editing for clarity / 80 columns, though I can back 
 those out from this patch (and put in another) if that's best.

That's fine with me, and while you are at it, you could fix this too when you 
commit:
+   the many Python level changes made leaving Python 2's API intact
s/Python level/Python-level/

 Patch is against the 2.7 branch; once this goes in I'll port all my 
 recent cporting.rst changes to 3.2 and trunk.

Remember to convert things like :cmacro: to :c:macro: when you port it.

--
stage: needs patch - patch review

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



[issue12923] test_urllib fails in refleak mode

2011-10-09 Thread Brian Brazil

Brian Brazil brian.bra...@gmail.com added the comment:

The actual problem is that FancyURLOpener self.tries isn't being reset if the 
protocol is file://

I've attached a patch that'll help improve the test at least.

--
keywords: +patch
Added file: http://bugs.python.org/file23358/12923-unittest-improvement.patch

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



[issue12923] test_urllib fails in refleak mode

2011-10-09 Thread Brian Brazil

Brian Brazil brian.bra...@gmail.com added the comment:

Here's a path to fix the problem.

--
Added file: http://bugs.python.org/file23359/12923-maxtries-reset.patch

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



[issue3902] Packages containing only extension modules have to contain __init__.py

2011-10-09 Thread Mike Hoy

Mike Hoy mho...@gmail.com added the comment:

Submitted v2 of my patch after reading Éric's review of my first.

--
Added file: http://bugs.python.org/file23360/apiref-setupscript-v2.diff

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



[issue13140] ThreadingMixIn.daemon_threads is not honored when parent is daemon

2011-10-09 Thread Florent Xicluna

New submission from Florent Xicluna florent.xicl...@gmail.com:

I use the socketserver.ThreadingMixIn to create a TCPServer.

I set the server thread as daemon (t.daemon=True).
But I want the client threads to run as non-daemon.
According to the documentation, the daemon_threads class attribute should do 
the trick.

But it fails: if server is daemon, the clients are daemon too, even if 
daemon_threads=False.

Demo attached.

--
components: Library (Lib)
files: test_socketserver.py
messages: 145273
nosy: flox
priority: normal
severity: normal
stage: needs patch
status: open
title: ThreadingMixIn.daemon_threads is not honored when parent is daemon
type: behavior
versions: Python 2.6, Python 2.7, Python 3.2, Python 3.3
Added file: http://bugs.python.org/file23361/test_socketserver.py

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



[issue13141] get rid of old threading API in the examples

2011-10-09 Thread Florent Xicluna

New submission from Florent Xicluna florent.xicl...@gmail.com:

http://docs.python.org/dev/library/socketserver.html#asynchronous-mixins

Still there's getName or setDaemon in some example.

--
assignee: docs@python
components: Documentation
messages: 145274
nosy: docs@python, flox
priority: low
severity: normal
stage: needs patch
status: open
title: get rid of old threading API in the examples
type: behavior
versions: Python 2.7, Python 3.3

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



[issue13139] multiprocessing.map skips finally blocks

2011-10-09 Thread Florent Xicluna

Florent Xicluna florent.xicl...@gmail.com added the comment:

Same behavior on Python 3.2 with this code:


from multiprocessing import Pool
from time import sleep

def Process(x):
try:
print(x)
sleep(.6-x/10.)
raise Exception('Exception: %d' % x)
finally:
print('Finally: %d' % x)

Pool(3).map(Process, [1, 2, 3])

--
components: +Library (Lib) -None
nosy: +flox
versions: +Python 3.2, Python 3.3

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



[issue13138] ElementTree's Element.iter() lacks versionadded

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 0f0a5d1c7a93 by Ezio Melotti in branch '2.7':
#13138: add missing versionadded.  Patch by Andreas Stührk.
http://hg.python.org/cpython/rev/0f0a5d1c7a93

--
nosy: +python-dev

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



[issue13138] ElementTree's Element.iter() lacks versionadded

2011-10-09 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 66d01b252b9a by Ezio Melotti in branch '3.2':
#13138: add missing versionadded.
http://hg.python.org/cpython/rev/66d01b252b9a

New changeset 2580e642e2ee by Ezio Melotti in branch 'default':
#13138: merge with 3.2.
http://hg.python.org/cpython/rev/2580e642e2ee

--

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



[issue13138] ElementTree's Element.iter() lacks versionadded

2011-10-09 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

Fixed, thanks for the report and the patch!

--
assignee: docs@python - ezio.melotti
nosy: +ezio.melotti
resolution:  - fixed
stage:  - committed/rejected
status: open - closed

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



[issue13126] find() slower than rfind()

2011-10-09 Thread Florent Xicluna

Changes by Florent Xicluna florent.xicl...@gmail.com:


--
nosy: +flox

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



[issue13119] Newline for print() is \n on Windows, and not \r\n as expected

2011-10-09 Thread Florent Xicluna

Changes by Florent Xicluna florent.xicl...@gmail.com:


--
nosy: +flox

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



[issue13134] speed up finding of one-character strings

2011-10-09 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

  Before going further with this, I'd suggest you have a look at your
  compiler settings.
  
  They are set by the configure script:
  
  gcc -pthread -c -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall
  -Wstrict-prototypes-I. -I./Include-DPy_BUILD_CORE -o
  Objects/unicodeobject.o Objects/unicodeobject.c
 
 Which gcc version are you using ?

$ gcc -v
Utilisation des specs internes.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-mageia-linux-gnu/4.5.2/lto-wrapper
Target: x86_64-mageia-linux-gnu
Configuré avec: ../configure --prefix=/usr --libexecdir=/usr/lib
--with-slibdir=/lib64 --with-bugurl=http://bugs.mageia.org/
--mandir=/usr/share/man --infodir=/usr/share/info
--enable-checking=release --enable-languages=c,c
++,ada,fortran,objc,obj-c++,java --build=x86_64-mageia-linux-gnu
--host=x86_64-mageia-linux-gnu --with-cpu=generic --with-system-zlib
--enable-threads=posix --enable-shared --enable-objc-gc
--enable-long-long --enable-__cxa_atexit --disable-libunwind-exceptions
--enable-clocale=gnu --enable-java-awt=gtk
--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre
--with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-gtk-cairo
--disable-libjava-multilib --enable-ssp --disable-libssp
--disable-werror --with-ppl --with-cloog
--with-python-dir=/lib/python2.7/site-packages --enable-lto
Modèle de thread: posix
gcc version 4.5.2 (GCC) 

 Is it possible that you have -fno-builtin enabled ?

Why would it be enabled? It is not on the command line.

  Such optimizations are normally performed by the
  compiler and don't need to be implemented in C, making maintenance
  harder.
  
  The fact that the glibc includes such optimization (in much more
  sophisticated form) suggests to me that many compilers don't perform
  these optimizations automically.
 
 When using gcc, the glibc functions are usually not used at all,
 since gcc comes with a (rather large) set of builtins which are
 inlined directly, if you have optimizations enabled and inlining
 is found to be more efficient than calling the glibc function:

What would that change? Whether the optimized memchr() comes from gcc or
the glibc is not relevant here.

 There is: the compiler will have alignement information available and
 can also benefit from using registers instead of the stack, knowledge
 about processor cache lines, etc. Such information is lost when calling
 a function. The function call itself will also create some overhead.
 
 BTW: You should not only test the optimization with long strings, but also
 with short ones (e.g. 2-15 chars) - which is a much more common case
 in practice.

With very short strings, the runtimes tend to be identical, which is
understandable.

--

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



[issue13139] multiprocessing.map skips finally blocks

2011-10-09 Thread Daniel Wagner-Hall

Daniel Wagner-Hall dawag...@gmail.com added the comment:

Explanation of behaviour at 
http://stackoverflow.com/questions/7700929/python-multiprocessing-map-if-one-thread-raises-an-exception-why-arent-other

tl;dr SIGTERM kills subprocesses and finally blocks aren't called.

I still consider this a bug, though

--

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



[issue10444] A mechanism is needed to override waiting for Python threads to finish

2011-10-09 Thread Florent Xicluna

Florent Xicluna florent.xicl...@gmail.com added the comment:

Antoine wrote:
 You could instead enumerate() all threads and set their daemon flag
 to False, before shutting down the interpreter.

If it is intended to work this way, it should be mentioned in the documentation.

Currently the documentation for Thread.daemon says:
“This must be set before start() is called, otherwise RuntimeError is raised.”

--
nosy: +flox

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



[issue13127] xml.dom.Attr.name is not labeled as read-only

2011-10-09 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

localName is defined with defproperty() in Lib/xml/dom/minidom.py:464 and 
looking at the definition of defproperty() in  Lib/xml/dom/minicompat.py:97 I 
think this is supposed to raise an xml.dom.NoModificationAllowedErr exception 
when someone tries to write on the attribute.  This doesn't seem to happen 
though.
OTOH 'name' doesn't use defproperty(), so technically it's writable, expect 
that writing on it has no effect.
This should still be documented, and it would also be good to figure out what's 
going on with defproperty().

--
components: +Library (Lib)
keywords: +easy
nosy: +ezio.melotti
stage:  - test needed
versions: +Python 2.7

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



[issue11813] inspect.getattr_static doesn't get module attributes

2011-10-09 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
priority: normal - high

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



[issue13142] Add support for other HTTP methods in urllib.request

2011-10-09 Thread Patrick Westerhoff

New submission from Patrick Westerhoff patrickwesterh...@gmail.com:

Hey,

I would like to request the support of other HTTP methods (other than GET and 
POST) in urllib.request. While it’s actually simple enough to override the 
Request class to add such a possibility, I think it is far too simple to leave 
it out of the standard library.

I’ve attached a patch that adds the functionality with a simple `method` 
property. The `get_method` function then simply looks if a custom method was 
entered, and otherwise falls back to the default behaviour.

Thanks a lot!

Patrick Westerhoff

Btw. Being a Git user, I hope the patch is actually useful ;)

--
components: Library (Lib)
files: urllib.patch
keywords: patch
messages: 145283
nosy: poke
priority: normal
severity: normal
status: open
title: Add support for other HTTP methods in urllib.request
type: feature request
versions: Python 3.2, Python 3.3, Python 3.4
Added file: http://bugs.python.org/file23362/urllib.patch

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



[issue13142] Add support for other HTTP methods in urllib.request

2011-10-09 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

This is a duplicate of #1673007, and it also has the same patch you wrote.

--
nosy: +ezio.melotti
resolution:  - duplicate
stage:  - committed/rejected
status: open - closed
superseder:  - urllib2 requests history + HEAD support
versions:  -Python 3.2, Python 3.4

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



[issue13142] Add support for other HTTP methods in urllib.request

2011-10-09 Thread Patrick Westerhoff

Patrick Westerhoff patrickwesterh...@gmail.com added the comment:

Oh sorry, I didn’t see that one. :)

--

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



[issue1673007] urllib2 requests history + HEAD support

2011-10-09 Thread Patrick Westerhoff

Changes by Patrick Westerhoff patrickwesterh...@gmail.com:


--
nosy: +poke

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



[issue12436] Missing items in installation/setup instructions

2011-10-09 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

 Open a command prompt:
Another alternative is win+r - type 'cmd' - hit enter.  This should work on 
all the Windows versions.

 * cd C:\ - Puts you in the root directory of the C drive.
 * cd Python32 - Puts you in the directory where Python 3.2 is installed.

What if it's not installed there?  Maybe it's better to say something like use 
the 'cd' command to move to the directory where Python is installed possibly 
mentioning the default installation directory and  'cd ..'.

 * dir - This command lists the contents of the Python32 directory.
 * python - This command will invoke python.exe and bring up the 
interpreter.

If the dir is already added to the PATH 'python' will work already without 
having to navigate to the installation dir.
Also if the user installed Python there should be a Python (command line) 
entry in the start menu that brings up the interpreter.

--

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



[issue13107] Text width in optparse.py can become negative

2011-10-09 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
nosy: +aronacher, bethard

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



[issue11489] json.dumps not parsable by json.loads (on Linux only)

2011-10-09 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
nosy: +pitrou, tchrist
versions:  -Python 2.6

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



[issue11489] json.dumps not parsable by json.loads (on Linux only)

2011-10-09 Thread Raymond Hettinger

Changes by Raymond Hettinger raymond.hettin...@gmail.com:


--
assignee:  - rhettinger
priority: high - normal

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



[issue11457] os.stat(): add new fields to get timestamps as Decimal objects with nanosecond resolution

2011-10-09 Thread Raymond Hettinger

Raymond Hettinger raymond.hettin...@gmail.com added the comment:

One other thought:  it would be useful to research how nanosecond-resolution 
timestamps are going to be supported in other languages.

--

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



[issue12602] Missing cross-references in Doc/using

2011-10-09 Thread Mike Hoy

Changes by Mike Hoy mho...@gmail.com:


--
nosy:  -mikehoy

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



[issue5322] Python 2.6 object.__new__ argument calling autodetection faulty

2011-10-09 Thread Benjamin Peterson

Benjamin Peterson benja...@python.org added the comment:

I think it needs tests.

--
nosy: +benjamin.peterson

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



[issue13143] os.path.islink documentation is ambiguous

2011-10-09 Thread Garen

New submission from Garen garen.par...@gmail.com:

The documentation for os.path.islink says:

Return True if path refers to a directory entry that is a symbolic link. 
Always False if symbolic links are not supported.

But what does supported mean?  Supported by what?  Supported by the OS, or 
supported by the Python runtime?  Because clearly there is a difference, which 
surprised me:

PythonWin 2.7.2 (default, Jun 24 2011, 12:21:10) [MSC v.1500 32 bit (Intel)] on 
win32.
Portions Copyright 1994-2008 Mark Hammond - see 'Help/About PythonWin' for 
further copyright information.
 import os
 os.path.islink(rC:\Users\Garen\dev\pypy.exe)
False
 os.path.islink(rC:\Users\Garen\dev\abspypy.exe)
False

Whereas if I use 3.2.x, I get the right answers:
ActivePython 3.2.2.3 (ActiveState Software Inc.) based on
Python 3.2.2 (default, Sep  8 2011, 10:56:38) [MSC v.1500 32 bit (Intel)] on 
win32
Type copyright, credits or license() for more information.
 import os
 os.path.islink(rC:\Users\Garen\dev\pypy.exe)
True
 os.path.islink(rC:\Users\Garen\dev\abspypy.exe)
True

An additional surprise is that in other places of the Python runtime, if 
functionality is not implemented for Windows, an exception of type 
NotImplementedError is raised--but not in this case with os.path.islink().

This all makes it a hairy mess to properly detect symlinks--from the client 
code perspective, now one has to check for specific versions of python, 
specific versions of Windows, and possibly which file-system is being used (FAT 
vs NTFS) just to be able to determine if islink() is silently failing or not.  
After which the client side will want to add clarifying comments to compensate 
for what's missing from the official docs (as opposed to posting a link to the 
docs in a comment).

As a user from the client side, I would only expect os.path.islink() to return 
False if the underlying OS/filesystem didn't support symlinks; if the 
underlying OS/filesystem did suport symlinks but support was missing, I'd 
expect to see a NoteImplementedError raised.  

In any case, where behavior for os.path.islink() (and related routines) 
deviates from the above pattern, I'd expect documentation that indicates what 
those deviations are--in this case, that False means unsupported by the Python 
runtime regardless of whether the OS/filesystem provides that functionality.

--
messages: 145290
nosy: Garen
priority: normal
severity: normal
status: open
title: os.path.islink documentation is ambiguous
versions: Python 2.7, Python 3.2

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