[issue14810] Bug in tarfile

2012-05-17 Thread Lars Gustäbel

Changes by Lars Gustäbel l...@gustaebel.de:


--
assignee:  - lars.gustaebel

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Martin v . Löwis

Martin v. Löwis mar...@v.loewis.de added the comment:

 Perhaps you know what revision that patch was against?

I wish people would stop using git-style diffs, then the patch would actually 
say. However, it applied cleanly to tip at the time it was submitted, so you 
should be able to go by that.

--

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



[issue14839] xml.sax.make_parser() returns No parsers found

2012-05-17 Thread Robert Koziol

New submission from Robert Koziol rkozi...@gmail.com:

Hi all,

It seems a little weird for me but I can not find this bug created. So I create 
one.

Invoking xml.sax.make_parser() returns an Exception - as in the following 
example:

Python 2.7.3rc2 (default, Mar 21 2012, 06:59:11)
[GCC 4.6.3] on linux2
Type help, copyright, credits or license for more information.
 import xml.sax
 xml.sax.make_parser()
Traceback (most recent call last):
  File stdin, line 1, in module
  File /usr/lib/python2.7/xml/sax/__init__.py, line 93, in make_parser
raise SAXReaderNotAvailable(No parsers found, None)
xml.sax._exceptions.SAXReaderNotAvailable: No parsers found


Kind regards,
Rob

--
components: XML
messages: 160954
nosy: rkoziol7
priority: normal
severity: normal
status: open
title: xml.sax.make_parser() returns No parsers found
type: behavior
versions: Python 2.7

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



[issue14836] Add next(iter(o)) to set.pop, dict.popitem entries.

2012-05-17 Thread Nadeem Vawda

Nadeem Vawda nadeem.va...@gmail.com added the comment:

 popitem() 
 Remove and return an arbitrary (key, value) pair from the dictionary. Raises 
 KeyError if the dict is empty. Use next(iter(d)) to return an arbitrary pair 
 without removing it.

Actually, next(iter(d)) on a dict returns an arbitrary *key*; if you want
a pair, you need next(iter(d.items())).

--
nosy: +nadeem.vawda

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



[issue14835] plistlib: output empty elements correctly

2012-05-17 Thread Hynek Schlawack

Changes by Hynek Schlawack h...@ox.cx:


--
nosy: +hynek
stage:  - patch review
versions:  -Python 3.1, Python 3.4

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



[issue14835] plistlib: output empty elements correctly

2012-05-17 Thread Hynek Schlawack

Changes by Hynek Schlawack h...@ox.cx:


--
nosy: +ned.deily

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



[issue1663329] subprocess/popen close_fds perform poor if SC_OPEN_MAX is hi

2012-05-17 Thread sorin

sorin sorin.sbar...@gmail.com added the comment:

Am I wrong or we should reopen this bug. Try `ulimit -n unlimited` and you'll 
make python code that does popen practically blocking.

--
nosy: +sorin
type:  - performance

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



[issue13934] sqlite3 test typo

2012-05-17 Thread poq

poq p...@gmx.com added the comment:

Now with proper skipping.

--
Added file: http://bugs.python.org/file25622/sqlite3-test-hooks.v2.patch

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



[issue14798] pyclbr raises KeyError when the prefix of a dotted name is not a package

2012-05-17 Thread Xavier de Gaye

Xavier de Gaye xdeg...@gmail.com added the comment:

Hi Petri
I have just sent the Contributor Agreement to PSF.

--

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Kristján Valur Jónsson

Kristján Valur Jónsson krist...@ccpgames.com added the comment:

Hi, I'll see what went wrong, I admit not trying 64 bit before creating the 
patch.
Martin, I´m using MercurialHQ and exporting a patch.  It is set up to use GIT 
format diffs, which I think is recommended in the Python developer FAQ.  Is 
this wrong?  (I'm still a relative Hg newbie)

--

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Martin v . Löwis

Martin v. Löwis mar...@v.loewis.de added the comment:

 Is this wrong?  (I'm still a relative Hg newbie)

It's an ongoing discussion. Some people favor git diffs because
it supports renaming and binaries, I prefer Mercurial diffs, because
it includes the base revision number against the patch was made.

--

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Kristján Valur Jónsson

Kristján Valur Jónsson krist...@ccpgames.com added the comment:

That sounds reasonable.  So, can't we come up with a diff that does both?  The 
base revision sounds like a completely necessary piece of info.

--

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Kristján Valur Jónsson

Kristján Valur Jónsson krist...@ccpgames.com added the comment:

I wish MS could come up with a property editor that could show you _only_ the 
properties that are non-default:
1) view all properties
2) view set and inherited non-defaults
3) view properties set here only.

It would make debugging settings _so_ much easier.  I'll suggest that to the VS 
team, all the good that will do.

--

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Martin v . Löwis

Martin v. Löwis mar...@v.loewis.de added the comment:

 That sounds reasonable.  So, can't we come up with a diff that does  
 both?  The base revision sounds like a completely necessary piece of  
 info.

I believe there is a bug report against Mercurial to include the base
revision even in git-style diffs, not sure what the status is. git itself
includes the base revision in its diffs; I believe that Mercurial didn't
dare to use the same syntax since the Mercurial hash wouldn't be a valid
git hash.

--

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



[issue14838] IDLE Will not load on reinstall

2012-05-17 Thread Anthony Kong

Anthony Kong anthony.hw.k...@gmail.com added the comment:

Which os? windows or linux or osx? 

It actually sounds like a support question. You probably should take the 
question to the python newsgroup 
(https://groups.google.com/forum/?fromgroups#!forum/comp.lang.python).

--
nosy: +Anthony.Kong

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



[issue13210] Support Visual Studio 2010

2012-05-17 Thread Kristján Valur Jónsson

Kristján Valur Jónsson krist...@ccpgames.com added the comment:

This is fun.
the reason why linking is failing for some projects in x64 mode is:
the SolutionDir (or maybe current dir) is implicitly part of the library search 
path.  Therefore, when looking for python33_d.lib, it will find the one in 
PCbuild, and look into that, and ignore the one in PCbuidl\amd64.

Some projects have references to the pythoncore project.  This is a .NET 
feature and not really useful for normal projects, but it does put an explicit 
link referrence to the correct .lib file into the linker's input arguments.  
This is why _testcapi works, and not _testbuffer (try diffing the two .vcxproj 
files).

All of this stems from my patch removing explicit link references to the 
correct .lib file.  Perhaps I can reintroduce that, but in a .props file.

--

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



[issue12932] dircmp does not allow non-shallow comparisons

2012-05-17 Thread Lennart Regebro

Lennart Regebro rege...@gmail.com added the comment:

filecmp is still there in Python 3.3 Alpha 3. I can't find any reference to it 
being deprecated.

--
nosy: +lregebro

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



[issue11880] add a {dist-info} category to distutils2

2012-05-17 Thread Daniel Holth

Daniel Holth dho...@fastmail.fm added the comment:

Fixed closure mistake in remote tip

--
hgrepos: +126

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



[issue11880] add a {dist-info} category to distutils2

2012-05-17 Thread Daniel Holth

Changes by Daniel Holth dho...@fastmail.fm:


--
keywords: +patch
Added file: http://bugs.python.org/file25623/50a0da981b7e.diff

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



[issue14823] Simplify threading.Lock.acquire() description

2012-05-17 Thread Roundup Robot

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

New changeset 6ab4128a by R David Murray in branch '3.2':
#14823: Simplify threading.Lock.acquire argument discussion.
http://hg.python.org/cpython/rev/6ab4128a

New changeset b5e95bb79ba3 by R David Murray in branch 'default':
#14823: Simplify threading.Lock.acquire argument discussion.
http://hg.python.org/cpython/rev/b5e95bb79ba3

New changeset 251463919f3c by R David Murray in branch '2.7':
#14823: Simplify threading.Lock.acquire argument discussion.
http://hg.python.org/cpython/rev/251463919f3c

--
nosy: +python-dev

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



[issue14823] Simplify threading.Lock.acquire() description

2012-05-17 Thread R. David Murray

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

Instead I decided to go ahead and document the argument as True/False.  That 
something else is accepted is a CPython implementation detail that shouldn't be 
depended on.

By the way, I couldn't actually use your patch file, since it wasn't against 
the threading.rst file from the repository.

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

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



[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2012-05-17 Thread Andrej A Antonov

Andrej A Antonov polymor...@gmail.com added the comment:

Jeff McNeil (mcjeff) I would think it might make more sense just to make the 
change to the Transport object. Since there's an argument for a transport on 
ServerProxy already, that seems more straightforward and keeps the network 
layer isolated.

in theoretical-side -- this layer isolation may be good and clean.

but in practical-side -- situation is next:

there are 3 alternative-variants of using timeout parameter in XMLRPC-Client:

situation 1. programmer (who makes script or program) -- using XMLRPC-Client 
*WITH* timeout parameter, because timeout parameter should be using in his 
program. program runs in regular environment.

situation 2. programmer (who makes script or program) -- using XMLRPC-Client 
*WITHOUT* timeout parameter, because XMLRPC-connection runs in localhost 
environment.

situation 3. programmer (who makes script or program) -- using XMLRPC-Client 
*WITHOUT* timeout parameter, because he makes mistake.

situation 1 -- very often. (or must be very often).

situation 2 -- very rare.

situation 3 -- leads to possible cases of freezing program/script or 
resource-leak.

if we will try to hide timeout parameter (in other layer), then situation 3 
will be more than situation 1

# p.s.: sorry for my bad english

--

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



[issue14652] Better error messages for wsgiref validator failures

2012-05-17 Thread Sidney San Martín

Sidney San Martín s...@sidneysm.com added the comment:

Thanks Jeff, I’m actually a relatively new Python developer and got the 
impression that it was best practice to always use a tuple for string 
formatting, for consistency.

Here’s an updated patch which drops the tuples for those cases.

--
Added file: http://bugs.python.org/file25624/ssm_validate.patch

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



[issue1757118] utilize 2.5 try/except/finally in contextlib

2012-05-17 Thread Fyrn Jilot

Changes by Fyrn Jilot fyrn7...@yahoo.com:


Added file: http://bugs.python.org/file25625/1.html

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



[issue3931] codecs.charmap_build is untested and undocumented

2012-05-17 Thread Serhiy Storchaka

Changes by Serhiy Storchaka storch...@gmail.com:


--
versions: +Python 3.3 -Python 2.7, Python 3.2

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



[issue3931] codecs.charmap_build is untested and undocumented

2012-05-17 Thread Serhiy Storchaka

Changes by Serhiy Storchaka storch...@gmail.com:


--
versions: +Python 2.7, Python 3.2

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



[issue14715] test.support.DirsOnSysPath should be replaced by importlib.test.util.import_state

2012-05-17 Thread Brett Cannon

Brett Cannon br...@python.org added the comment:

sys.modules is tricky thanks to built-in modules not liking to be re-imported 
(and why import_state in importlib.test didn't reset it).

If only one test fails because of my assumption, then I guess blanking them out 
really isn't as important as I thought. And if you have to blank everything out 
for a test, then you are just careful to blank everything out, no matter how 
verbose it gets.

--

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



[issue14823] Simplify threading.Lock.acquire() description

2012-05-17 Thread Éric Araujo

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

I suspect the patch was made against the source files served by Sphinx with a 
txt extension.

--
nosy: +eric.araujo

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



[issue14657] Avoid two importlib copies

2012-05-17 Thread Brett Cannon

Brett Cannon br...@python.org added the comment:

Realized that any decorator or context manager that is created for swapping 
_frozen_importlib/importlib._bootstrap should also verify no module is left in 
sys.modules with a bad loader and that sys.path_importer_cache doesn't have a 
bad finder (I would say that this would go into test.support.regrtest's state 
checks, but that seems overkill for only two tests).

And this might be worth doing as a decorator (method or class) to make it 
easier to make sure the requisite tests always run with both versions (or 
copying what test_warnings does). I don't want to do anything in a module's 
test_main() as that precludes using unittest's test discovery for running tests.

--

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



[issue1635217] Warn against using requires/provides/obsoletes in setup.py

2012-05-17 Thread Éric Araujo

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

Again, the stdlib docs do not document third-party projects.  Use the pip doc 
if you use pip.

--

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



[issue14818] C implementation of ElementTree causes regressions

2012-05-17 Thread Ezio Melotti

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

The attached patch adds support for keyword args to find, findtext, findall, 
and iterfind.  iter and itertext don't seem to accept a namespace argument.  
The patch includes minimal tests.

The name I used for the kwargs are the same of the Python version.  The 
documentation uses different names, and extra args (like namespaces) are not 
even documented.

I didn't have time yet to double-check if other functions needs to be updated 
and to add better tests that actually check for specific namespaces.

--
keywords: +patch
stage: needs patch - patch review
Added file: http://bugs.python.org/file25626/issue14818.diff

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



[issue14817] pkgutil.extend_path has no tests

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue14838] IDLE Will not load on reinstall

2012-05-17 Thread Martin v . Löwis

Martin v. Löwis mar...@v.loewis.de added the comment:

Please run, from the command line, in the Python installation

  python.exe Lib\idlelib\idle.py

and report any output you get.

--
nosy: +loewis

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



[issue14715] test.support.DirsOnSysPath should be replaced by importlib.test.util.import_state

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue14815] random_seed uses only 32-bits of hash on Win64

2012-05-17 Thread Raymond Hettinger

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


--
assignee:  - rhettinger

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



[issue14839] xml.sax.make_parser() returns No parsers found

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com added the comment:

Your Python is missing pyexpat.so module, which is built only when expat 
library has been found. Check build log of Python to see why pyexpat.so is not 
available. (Maybe expat headers are not installed.)

--
nosy: +Arfrever
resolution:  - invalid
status: open - closed

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



[issue14818] C implementation of ElementTree: Some functions should support keyword arguments

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
title: C implementation of ElementTree causes regressions - C implementation 
of ElementTree: Some functions should support keyword arguments

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Charles-François Natali

Charles-François Natali neolo...@free.fr added the comment:

 I guess this is the magic in mkdir -p:

 mkdir(expert, 0755)                   = -1 EACCES (Permission denied)
 chdir(expert)                         = 0
 mkdir(tmp, 0755)                      = -1 EEXIST (File exists)

 I'm not sure how I feel about that. I think we have more or less a policy in 
 os  shutil not to change directories unless really necessary (like 
 make_archive).

Calling chdir() should be avoided, as it is not thread safe.

Actually, the real problem is that stat() alone doesn't trigger
automount, to avoid mount storms e.g. when using find, see:
https://bugzilla.redhat.com/show_bug.cgi?id=497830
http://lkml.indiana.edu/hypermail/linux/kernel/1109.1/00100.html

Since calling chdir() is not an option, if we want to fix this, I
guess the way to go would be to open() the directory, and not use
path.exists().

But I find really uncomfortable with adding such a kludge, especially
since this problem is probably present in many different places
throughout the stdlib.

Furthermore, it seems that kernel from 2.6.38 do trigger automount
upon stat() (see
http://lkml.indiana.edu/hypermail/linux/kernel/1109.1/00210.html), so
I'd suggest to drop this as won't fix.

--

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Serhiy Storchaka

Serhiy Storchaka storch...@gmail.com added the comment:

Looks like issue14738 fixes this bug for Python 3.3.

 print(ascii(b\xc2\x41\x42.decode('utf8', 'replace')))
'\ufffdAB'
 print(ascii(b\xf1ABCD.decode('utf8', 'replace')))
'\ufffdABCD'

--
nosy: +storchaka

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



[issue10530] distutils2 should allow the installing of python files with invalid syntax

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue13849] Add tests for NUL checking in certain strs

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Ezio Melotti

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

The original bug should be fixed already in 3.3 and there should be tests 
(unless they got removed/skipped after we changed unicode implementation).
The only issue left was about the number of U+FFFD generated with invalid 
sequences in some cases.
My last patch has extensive tests for this, so you could try to apply it (or 
copy the tests) and see if they all pass.  FWIW this should be already fixed on 
PyPy.

--

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



[issue14840] Tutorial: Add a bit on the difference between tuples and lists

2012-05-17 Thread Zachary Ware

New submission from Zachary Ware zachary.w...@gmail.com:

I was looking through the documentation source files for things I might be able 
to fix, and stumbled across XXX Add a bit on the difference between tuples and 
lists. in Doc\tutorial\datastructures.rst. So I took a stab at adding some 
prose to address that comment, reproduced here:


Though tuples may seem very similar to lists, their immutability makes them
ideal for fundamentally different usage.  In typical usage, tuples are a
heterogenous structure, whereas lists are a homogenous sequence.  This tends to
mean that, in general, tuples are used as a cohesive unit while lists are used
one member at a time.


Have I missed anything important (like the whole point) or is there anything I 
could phrase better?

Should this be applied to the tutorials of previous versions?

--
assignee: docs@python
components: Documentation
files: tuple vs list.patch
keywords: patch
messages: 160982
nosy: docs@python, zach.ware
priority: normal
severity: normal
status: open
title: Tutorial: Add a bit on the difference between tuples and lists
type: enhancement
versions: Python 3.3
Added file: http://bugs.python.org/file25627/tuple vs list.patch

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



[issue9260] A finer grained import lock

2012-05-17 Thread Roundup Robot

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

New changeset edb9ce3a6c2e by Antoine Pitrou in branch 'default':
Issue #9260: A finer-grained import lock.
http://hg.python.org/cpython/rev/edb9ce3a6c2e

--
nosy: +python-dev

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



[issue9548] locale can be imported at startup but relies on too many library modules

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue9260] A finer grained import lock

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue9260] A finer grained import lock

2012-05-17 Thread Antoine Pitrou

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

I have now pushed the patch.

--
resolution:  - fixed
status: open - pending

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



[issue9260] A finer grained import lock

2012-05-17 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
stage: patch review - committed/rejected
status: pending - open

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



[issue9260] A finer grained import lock

2012-05-17 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
status: open - pending

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



[issue14840] Tutorial: Add a bit on the difference between tuples and lists

2012-05-17 Thread Ezio Melotti

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

I personally like your suggested text, but there have been some discussion on 
the topic (on python-ideas iirc) and some people think that it's ok to use 
tuples like immutable lists, rather than just structures with heterogeneous 
elements similar to C's structs.

--
nosy: +ezio.melotti
stage:  - patch review
versions: +Python 2.7, Python 3.2

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



[issue14840] Tutorial: Add a bit on the difference between tuples and lists

2012-05-17 Thread R. David Murray

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

I don't think that the suggested text contradicts that.  (Especially the 
wording tends to.)  So I think this might be a reasonable addition, but I can 
see that some people might get upset :)

--
nosy: +r.david.murray

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



[issue14840] Tutorial: Add a bit on the difference between tuples and lists

2012-05-17 Thread Zachary Ware

Zachary Ware zachary.w...@gmail.com added the comment:

Perhaps an added line at the end, something like 'Of course, should you need an 
immutable list, tuples are quite handy for that, too.'?

--

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



[issue14841] os.get_terminal_size() should check stdin as a fallback

2012-05-17 Thread Arfrever Frehtes Taifersar Arahesis

New submission from Arfrever Frehtes Taifersar Arahesis 
arfrever@gmail.com:

$ stty size | cat
46 157
$ python3.3 -c 'import os; print(os.get_terminal_size())' | cat
Traceback (most recent call last):
  File string, line 1, in module
OSError: [Errno 22] Invalid argument

Redirection to `less` are often used.

A proposed patch was attached by Victor Stinner in issue #13609.

--
messages: 160988
nosy: Arfrever, denilsonsa, haypo, zbysz
priority: normal
severity: normal
status: open
title: os.get_terminal_size() should check stdin as a fallback
versions: Python 3.3

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Serhiy Storchaka

Serhiy Storchaka storch...@gmail.com added the comment:

 The only issue left was about the number of U+FFFD generated with invalid 
 sequences in some cases.
 My last patch has extensive tests for this, so you could try to apply it (or 
 copy the tests) and see if they all pass.

Tests fails, but I'm not sure that the tests are correct.

b'\xe0\x00' raises 'unexpected end of data' and not 'invalid
continuation byte'. This is terminological issue.

b'\xe0\x80'.decode('utf-8', 'replace') returns one U+FFFD and not two. I
don't think that is right.

--
title: str.decode('utf8',   'replace') -- conformance with Unicode 5.2.0 - 
str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Saul Spatz

Saul Spatz saul.sp...@gmail.com added the comment:

b'\xe0\x80'.decode('utf-8', 'replace') returns one U+FFFD and not two. I
don't think that is right.

I think that one U+FFFD is correct.  The on;y error is a premature end of
data.
On Thu, May 17, 2012 at 12:31 PM, Serhiy Storchaka
rep...@bugs.python.orgwrote:


 Serhiy Storchaka storch...@gmail.com added the comment:

  The only issue left was about the number of U+FFFD generated with
 invalid sequences in some cases.
  My last patch has extensive tests for this, so you could try to apply it
 (or copy the tests) and see if they all pass.

 Tests fails, but I'm not sure that the tests are correct.

 b'\xe0\x00' raises 'unexpected end of data' and not 'invalid
 continuation byte'. This is terminological issue.

 b'\xe0\x80'.decode('utf-8', 'replace') returns one U+FFFD and not two. I
 don't think that is right.

 --
 title: str.decode('utf8',   'replace') -- conformance with Unicode
 5.2.0 - str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

 ___
 Python tracker rep...@bugs.python.org
 http://bugs.python.org/issue8271
 ___


--

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Ezio Melotti

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

 Tests fails, but I'm not sure that the tests are correct.

 b'\xe0\x00' raises 'unexpected end of data' and not 'invalid
 continuation byte'. This is terminological issue.

This might be just because it first checks if there two more bytes before 
checking if they are valid, but 'invalid continuation byte' works too.

 b'\xe0\x80'.decode('utf-8', 'replace') returns one U+FFFD and not
 two. I don't think that is right.

Why not?

--

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



[issue13031] small speed-up for tarfile.py when unzipping tarballs

2012-05-17 Thread Roundup Robot

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

New changeset c62fa6892424 by Ross Lagerwall in branch 'default':
Issue #13031: Small speed-up for tarfile when unzipping tarfiles.
http://hg.python.org/cpython/rev/c62fa6892424

--
nosy: +python-dev

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Ezio Melotti

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

Changing from 'unexpected end of data' to 'invalid continuation byte' for 
b'\xe0\x00' is fine with me, but this will be a (minor) deviation from 2.7, 
3.1, 3.2, and pypy (it could still be changed on all these except 3.1 though).

If you make any changes on the tests please let me know.

--

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



[issue13031] small speed-up for tarfile.py when unzipping tarballs

2012-05-17 Thread Ross Lagerwall

Ross Lagerwall rosslagerw...@gmail.com added the comment:

Nice work, thanks!

--
assignee: lars.gustaebel - rosslagerwall
resolution:  - fixed
stage:  - committed/rejected
status: open - closed

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Hynek Schlawack

Hynek Schlawack h...@ox.cx added the comment:

I agree, closing.

Thank you for your valuable assistance Andrew!

--
resolution:  - wont fix
stage: needs patch - 
status: open - closed

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



[issue13849] Add tests for NUL checking in certain strs

2012-05-17 Thread Hynek Schlawack

Hynek Schlawack h...@ox.cx added the comment:

 It appears that os.stat did not check for embedded nulls but just passed the 
 string to Windows.

JFTR, we have fixed it for open() because it's a potential security problem. I 
have implemented a helper function for checking for NUL chars: 
_PyUnicode_HasNULChars

See the already mentioned #13848.

--

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Andrew McNabb

Andrew McNabb amcn...@mcnabbs.org added the comment:

This isn't fixed. All of the examples I've given were with a 3.3.0 kernel. 
Doing a stat would be a fix.

--
status: closed - open

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Serhiy Storchaka

Serhiy Storchaka storch...@gmail.com added the comment:

 I think that one U+FFFD is correct.  The on;y error is a premature end of
 data.

I poorly expressed. I also think that there is only one decoding error,
and not two. I think the test is wrong.

--

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



[issue14840] Tutorial: Add a bit on the difference between tuples and lists

2012-05-17 Thread Ezio Melotti

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

Link to the discussion: 
https://groups.google.com/d/msg/python-ideas/P3lEYU9u0DU/H0gcuAAJvEgJ

The actual discussion about tuples starts on 
https://groups.google.com/d/msg/python-ideas/P3lEYU9u0DU/JW2Lq3KYA4QJ and 
continues with the following posts.

--
nosy: +eric.araujo, terry.reedy

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Serhiy Storchaka

Serhiy Storchaka storch...@gmail.com added the comment:

 This might be just because it first checks if there two more bytes before 
 checking if they are valid, but 'invalid continuation byte' works too.

Yes, this implementation detail. It is much easier and faster. Whether
it is necessary to change it?

 Why not?

May be I'm wrong. I looked in The Unicode Standard, Version
6.0 (http://www.unicode.org/versions/Unicode6.0.0/ch03.pdf), pp. 95-97,
the standard does not categorical in this, but recommends that only
maximal subpart should be replaced by U+FFFD. \xe0\x80 is not maximal
subpart. Therefore, there must be two U+FFFD. In this case, the previous
and the current implementation does not conform to the standard.

--

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Serhiy Storchaka

Serhiy Storchaka storch...@gmail.com added the comment:

 Changing from 'unexpected end of data' to 'invalid continuation byte' for 
 b'\xe0\x00' is fine with me, but this will be a (minor) deviation from 2.7, 
 3.1, 3.2, and pypy (it could still be changed on all these except 3.1 though).

I probably poorly said. Past and current implementations raise
'unexpected end of data' and not 'invalid continuation byte'. Test
expects 'invalid continuation byte'.

--

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Ezio Melotti

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

 \xe0\x80 is not maximal subpart. Therefore, there must be two U+FFFD.

OK, now I get what you mean.  The valid range for continuation bytes that can 
follow E0 is A0-BF, not 80-BF as usual, so \x80 is not a valid continuation 
byte here.  While working on the patch I stumbled across this corner case and 
contacted the Unicode consortium to ask about it, as explained in msg129495.

I don't remember all the details right now, but it that test was passing with 
my patch there must be something wrong somewhere (either in the patch, in the 
test, or in our understanding of the standard).

--

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Hynek Schlawack

Hynek Schlawack h...@ox.cx added the comment:

If I read it correctly, we _do_ a stat:

stat(/net/prodigy, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
mkdir(/net/prodigy/tmp, 0777) = -1 EACCES (Permission denied)

ISTM that this is a different problem altogether, or am I missing something?

If mkdir'ing of deeper directories works, it sounds like a race condition to me.

--

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Ezio Melotti

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

 I probably poorly said. Past and current implementations raise
 'unexpected end of data' and not 'invalid continuation byte'. Test
 expects 'invalid continuation byte'.

I don't think it matters much either way.

--

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



[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2012-05-17 Thread Serhiy Storchaka

Serhiy Storchaka storch...@gmail.com added the comment:

 I don't remember all the details right now, but it that test was passing with 
 my patch there must be something wrong somewhere (either in the patch, in the 
 test, or in our understanding of the standard).

No, test correctly expects two U+FFFD. Current implementation is wrong.
As I understand now, what's the error, I'll try to correct Python 3.3
implementation.

--

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Hynek Schlawack

Hynek Schlawack h...@ox.cx added the comment:

My suspicion re the race condition is that a chdir waits for autofs to mount 
but mkdir doesn't. You could check that yourself if a chdir/sleep would help.

--

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Andrew McNabb

Andrew McNabb amcn...@mcnabbs.org added the comment:

Hmm. Maybe there's a difference between doing stat('/net/prodigy') vs. 
stat('/net/prodigy/tmp'). Just a guess, but maybe the former can succeed before 
the mount completes, but the latter has to wait for the mount to complete.

--

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Andrew McNabb

Andrew McNabb amcn...@mcnabbs.org added the comment:

By the way, if my hunch about the difference in stat of '/net/prodigy' vs. 
'/net/prodigy/tmp' is correct, then this would explain why makedirs on deeper 
directories work. Specifically, one of the shallower stat calls would force the 
mount to complete before proceeding to the next deeper level.

--

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



[issue1635217] Warn against using requires/provides/obsoletes in setup.py

2012-05-17 Thread anatoly techtonik

anatoly techtonik techto...@gmail.com added the comment:

I am trying to get what's the proposed standard for users right now? How are 
you going to define dependencies in distutils2?

--

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



[issue14842] Link to time.time() in the docs of time.localtime() is wrong

2012-05-17 Thread Petri Lehtinen

New submission from Petri Lehtinen pe...@digip.org:

The link currently points to the time module. It should point to the 
time.time() function.

--
assignee: docs@python
components: Documentation
keywords: easy
messages: 161010
nosy: docs@python, petri.lehtinen
priority: normal
severity: normal
status: open
title: Link to time.time() in the docs of time.localtime() is wrong
versions: Python 2.7, Python 3.2, Python 3.3

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



[issue1635217] Warn against using requires/provides/obsoletes in setup.py

2012-05-17 Thread Éric Araujo

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

Right now the standard (i.e. official) way is Requires, which is unusable; the 
de facto standard (but not blessed by any PEP) is setuptools’ install_requires. 
 The new standard is documented in d2 docs and there will be examples 
(http://bugs.python.org/issue1635217#msg112787).

--

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



[issue14776] Add SystemTap static markers

2012-05-17 Thread Dave Malcolm

Dave Malcolm dmalc...@redhat.com added the comment:

Thanks.   I too am wondering where the documentation should go.  We currently 
have several locations for documentation:
  (1) the man page
  (2) the Doc subdirectory aka docs.python.org
  (3) various text files in the source tree, such as Misc/SpecialBuilds.txt
  (4) the devguide
  (5) www.python.org, and other web sites

This feature is about instrumentation of CPython, which is of use to several 
audiences, such as:
  (a) people working on CPython's internals
  (b) Python developers seeking to understand performance issues
  (c) sysadmins trying to tweak the performance of, say, a deployed web app

As I understand it, the devguide is targetting (a), whereas the Doc 
subdirectory of the cpython sources is targetting (b) when they're writing the 
code, but not necessarily when tuning it, and (c) doesn't seem to get covered.

So perhaps there should be a new top-level section of documentation within the 
main Python Doc directory covering instrumentation and performance?  (e.g. 
instrumentation or debugging). If so, these docs could be an entry within 
that section.  Though I don't want to block this feature on writing up a full 
guide to debugging/deploying Python :)

Less ambitiously, we could just add it to the howto section (which appears to 
be something of a dumping ground for docs that didn't fit neatly into the other 
categories).  Would that be acceptable in lieu of a better location?

Or is this something for the python-dev mailing list?
Cheers!

--

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



[issue14776] Add SystemTap static markers

2012-05-17 Thread Antoine Pitrou

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

I think it could go into python setup and usage 
(http://docs.python.org/dev/using/index.html), but that seems target at 
first-time users; or perhaps a HOWTO 
(http://docs.python.org/dev/howto/index.html), but it might make it less 
visible. Or a debug and instrumentation section indeed (we could also put the 
python-gdb doc there).

Perhaps you could ask python-dev indeed.

--

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



[issue14843] support define_macros / undef_macros in setup.cfg

2012-05-17 Thread Daniel Holth

Changes by Daniel Holth dho...@fastmail.fm:


--
assignee: eric.araujo
components: Distutils2
nosy: alexis, dholth, eric.araujo, tarek
priority: normal
severity: normal
status: open
title: support define_macros / undef_macros in setup.cfg
type: enhancement
versions: Python 3.3

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



[issue14843] support define_macros / undef_macros in setup.cfg

2012-05-17 Thread Daniel Holth

New submission from Daniel Holth dho...@fastmail.fm:

from build_ext.py:

# XXX not honouring 'define_macros' or 'undef_macros' -- the
# CCompiler API needs to change to accommodate this, and I
# want to do one thing at a time!

--

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



[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2012-05-17 Thread Jeff McNeil

Jeff McNeil j...@jmcneil.net added the comment:

Yeah, that's a good point too. I still personally favor the transport 
encapsulation and related unit testing, but I think that's a call for someone 
with a snake icon next to their tracker name.

Your English is just fine. =)

--

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



[issue14844] netrc does not handle accentuated characters

2012-05-17 Thread Raphaël Droz

New submission from Raphaël Droz raphael.droz+fl...@gmail.com:

Accentuated characters are not accepted in password.
While it (unicode) was quickly talked about in issue557704 it appears that 
issue1170 aimed to solve this by making shlex unicode-compatible but it does 
not seem to be the case (at least with python 3.2 in the netrc use-case).

On a side note :
- a blank line between two comment lines
 and
- lines starting with a '#' *not* followed by a space
 fail too (shells supports both of them)

--
components: Library (Lib)
messages: 161016
nosy: drzraf
priority: normal
severity: normal
status: open
title: netrc does not handle accentuated characters
versions: Python 3.2

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



[issue14715] test.support.DirsOnSysPath should be replaced by importlib.test.util.import_state

2012-05-17 Thread Eric V. Smith

Eric V. Smith e...@trueblade.com added the comment:

I understand about sys.modules. Maybe I'll create another context manager (say, 
sys_modules_state) that does the same for sys.modules. I can always stack them 
together.

When loading pure-Python namespace packages, I want to make sure they get 
removed before the next test.

--

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Charles-François Natali

Charles-François Natali neolo...@free.fr added the comment:

Yes, creating the directories in a bottom-up way (i.e. '/net', '/net/prodigy', 
'/net/prodigy/foo') could maybe avoid this problem.
But this is definietely an autofs bug, and there are probably many other places 
where such code might break.

--

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



[issue6721] Locks in python standard library should be sanitized on fork

2012-05-17 Thread Antoine Pitrou

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

Should we go forward on this?

--
assignee: gregory.p.smith - 
stage: test needed - patch review
type: behavior - enhancement
versions:  -Python 2.7, Python 3.2

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



[issue2675] Curses terminal resize problems when Python is in interactive mode

2012-05-17 Thread poq

poq p...@gmx.com added the comment:

Just to confirm: curses SIGWINCH handling is still (2.7/3.2) broken after 
importing readline.

Readline seems to set the LINES/COLUMNS environment vars, and this confuses 
curses, even if curses is imported after readline.

Clearing the LINES/COLUMNS vars after import readline fixes the issue:
os.environ['LINES'] = os.environ['COLUMNS'] = ''
or
os.unsetenv('LINES'); os.unsetenv('COLUMNS')
(or other variations).

I spent a couple hours tearing my hair out over this, before I found this 
report.

It may be possible for Python to work around this readline behavior by saving 
LINES/COLUMNS and restoring them after initializing readline.

Or maybe this should just be documented somewhere.

--
nosy: +poq
versions: +Python 3.3 -Python 2.4

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



[issue2675] Curses terminal resize problems when Python is in interactive mode

2012-05-17 Thread poq

poq p...@gmx.com added the comment:

Issue 3948 is almost certainly a duplicate.

--

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



[issue14840] Tutorial: Add a bit on the difference between tuples and lists

2012-05-17 Thread Terry J. Reedy

Terry J. Reedy tjre...@udel.edu added the comment:

Zachary, you are brave/foolhardy to take this on;)

I agree that the XXX comment should be removed. One possible resolution is to 
do just that, replacing it with nothing.

I would note that the fuss over tuples versus lists comes from a time before 
iterators became a common way to pass around and process sequences. This, in a 
sense, makes tuples and lists more similar that they were before in that 
iterators have mostly replaced one of the list uses that made lists different 
from tuples. We do not fuss over whether an iterator is 'homogeneous' or 
'heterogeneous'. Each is, of course, mutable until exhausted.

Another change is that now isinstance(x, object) is True for everything, so 
that one can now view all concrete collections as homogeneous at the Python 
level as well as at the C implementation level. Things were different before 
the unification of types and classes, completed in 3.0.

As to the proposal: I am one of the 'some people'. 'Tends to' helps a lot. Now 
to be picky.

I would say that tuples and list are similar to each other in being concrete 
sequences of objects (instances of class object). I would remove 
'fundamentally'.

The rest of the initial paragraph leaves out the usage of tuples as constant 
sequences (which is to say, immutable 'all the way down'). First is the 
hard-coded constant: consider

 def f(): return (((1,2),(3,4)),((5,6),(7,8)))

 dis(f)
  1   0 LOAD_CONST15 1, 2), (3, 4)), ((5, 6), (7, 8 
  3 RETURN_VALUE  

versus
   
 def fl(): return[[[1,2],[3,4]],[[5,6],[7,8]]]
  
 dis(fl)
  1   0 LOAD_CONST   1 (1) 
  3 LOAD_CONST   2 (2) 
  6 BUILD_LIST   2 
  9 LOAD_CONST   3 (3) 
 12 LOAD_CONST   4 (4) 
 15 BUILD_LIST   2 
 18 BUILD_LIST   2 
 21 LOAD_CONST   5 (5) 
 24 LOAD_CONST   6 (6) 
 27 BUILD_LIST   2 
 30 LOAD_CONST   7 (7) 
 33 LOAD_CONST   8 (8) 
 36 BUILD_LIST   2 
 39 BUILD_LIST   2 
 42 BUILD_LIST   2 
 45 RETURN_VALUE 

Second are sequences used as keys, regardless of 'geneity.

Third are the homogeneous sequences that the language syntax requires to be 
tuples, not lists: except, issubclass, isinstance. There are also the typically 
homogeneous tuples for *args  and possibly homogeneous second argument to % 
interpolation. In other words, the language itself does not support the second 
sentence.

On the other hand, if one has a heterogeneous list, perhaps from a list 
comprehension, that will not be hashed, there may be no need other than 
philosophical purity to convert it to a tuple. Im/mutability is part of the 
definition and operaton of the language. Homo/heter/geneity is not (that I can 
think of at the moment).

I do not especially like the suggested add on sentence as is. 'Immutable list' 
is wrong; a tuple is an immutable sequence, and what one typically needs is a 
constant (hashable) sequence, and if one does, a tuple is essential, not just 
'handy'.

--

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



[issue14845] list(generator expression) != [list comprehension]

2012-05-17 Thread Peter Norvig

New submission from Peter Norvig pnor...@google.com:

PEP 289 says the semantic definition of a list comprehension in Python 3.0 
will be equivalent to list(generator expression).  Here is a counterexample 
where they differ (tested in 3.2):

def five(x):
Generator yields the object x five times.
for _ in range(5):
yield x


# If we ask five() for 10 objects in a list comprehension,
# we get an error:

 F = five('x')
 [next(F) for _ in range(10)]
Traceback (most recent call last):
  File stdin, line 1, in module
StopIteration

# But if we ask five() for 10 objects in a list(generator expr),
# we get five objects, no  error:

 F = five('x')
 list(next(F) for _ in range(10))
['x', 'x', 'x', 'x', 'x']

--
components: None
messages: 161023
nosy: Peter.Norvig
priority: normal
severity: normal
status: open
title: list(generator expression) != [list comprehension]
type: behavior
versions: Python 3.2

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



[issue14845] list(generator expression) != [list comprehension]

2012-05-17 Thread Ezio Melotti

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


--
components: +Interpreter Core -None
nosy: +ezio.melotti
stage:  - needs patch
versions: +Python 3.3

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Hynek Schlawack

Hynek Schlawack h...@ox.cx added the comment:

I sense a very easy fix: just do a stat() on the final path before we do 
anything (and quickly return if present). Moving current makedirs into a 
private _makedirs that gets called if the stat fails.

I'm still feeling uneasy about that though. It _is_ a kludge.

--

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



[issue14842] Link to time.time() in the docs of time.localtime() is wrong

2012-05-17 Thread Ezio Melotti

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


--
nosy: +ezio.melotti
stage:  - needs patch
type:  - enhancement

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



[issue14846] Change in error when sys.path contains a nonexistent folder (importlib)

2012-05-17 Thread Thomas Kluyver

New submission from Thomas Kluyver tak...@gmail.com:

I've come across a difference from 3.2 to 3.3 while running the IPython test 
suite. It occurs when a directory on sys.path has been used for an import, then 
deleted without being removed from sys.path. Previous versions of Python ignore 
the nonexistent folder, but in 3.3 a FileNotFound error appears.

This might be by design (errors should never pass silently), but I haven't 
found it mentioned in the What's New for 3.3.

$ cat import.py
import sys, os, shutil
os.mkdir('foo')
with open('foo/bar.py', 'w'):
pass
sys.path.insert(0, 'foo/')
import bar   # Caches a FileFinder for foo/
shutil.rmtree('foo')
import random   # Comes later on sys.path

$ python3.2 import.py

$ python3.3 import.py
Traceback (most recent call last):
  File import.py, line 8, in module
import random
  File frozen importlib._bootstrap, line 1162, in _find_and_load
  File frozen importlib._bootstrap, line 1124, in _find_and_load_unlocked
  File frozen importlib._bootstrap, line 1078, in _find_module
  File frozen importlib._bootstrap, line 927, in find_module
  File frozen importlib._bootstrap, line 973, in find_module
  File frozen importlib._bootstrap, line 1005, in _fill_cache
FileNotFoundError: [Errno 2] No such file or directory: 'foo/'

The last entry in that traceback is calling _os.listdir(path).

--
components: Interpreter Core
messages: 161025
nosy: takluyver
priority: normal
severity: normal
status: open
title: Change in error when sys.path contains a nonexistent folder (importlib)
type: behavior
versions: Python 3.3

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



[issue14846] Change in error when sys.path contains a nonexistent folder (importlib)

2012-05-17 Thread Eric Snow

Eric Snow ericsnowcurren...@gmail.com added the comment:

...rather, the error caused by your example.  :)

--

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



[issue14846] Change in error when sys.path contains a nonexistent folder (importlib)

2012-05-17 Thread Eric Snow

Eric Snow ericsnowcurren...@gmail.com added the comment:

The caching mechanism is going to check for changes in the directory.  So the 
recommendation is to clear the cache manually:

quote
  The default finders used by import now utilize a cache of what is contained
  within a specific directory. If you create a Python source file or sourceless
  bytecode file, make sure to call importlib.invalidate_caches() to clear out
  the cache for the finders to notice the new file.
/quote

(see http://docs.python.org/dev/whatsnew/3.3.html#porting-python-code)

That section doesn't really talk about the directory side of things, but 
calling importlib.invalidate_caches() works great to eliminate the error in 
your example.

--
nosy: +brett.cannon, eric.snow, pitrou

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



[issue14702] os.makedirs breaks under autofs directories

2012-05-17 Thread Martin v . Löwis

Martin v. Löwis mar...@v.loewis.de added the comment:

I agree that the proposed solutions are hacks, and still propose to close this 
as won't fix.

I think this is a bug in Linux. mkdir(/net/prodigy/tmp) ought to trigger the 
mount, then fail with EEXIST.

--
nosy: +loewis

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



[issue6721] Locks in python standard library should be sanitized on fork

2012-05-17 Thread Gregory P. Smith

Gregory P. Smith g...@krypto.org added the comment:

going forward with reinit_locks.diff makes sense.

I've added comments to it in the code review link.  It is Patch Set 3

--

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



[issue14846] Change in error when sys.path contains a nonexistent folder (importlib)

2012-05-17 Thread Eric V. Smith

Changes by Eric V. Smith e...@trueblade.com:


--
nosy: +eric.smith

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



[issue14838] IDLE Will not load on reinstall

2012-05-17 Thread Roger Serwy

Changes by Roger Serwy roger.se...@gmail.com:


--
nosy: +serwy

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



[issue14845] list(generator expression) != [list comprehension]

2012-05-17 Thread R. David Murray

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

I think the behavior is correct.  next(x) is outside the for expression in the 
list comprehension, but 'list(x)' is an implicit 'for x in exp'.  So I believe 
it is the doc that needs amplification.  The PEP discussion is referring 
specifically to the leaking of the loop variable.

--
nosy: +r.david.murray

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



  1   2   >